JPMorganChase’s artificial intelligence chief, Teresa Heitsenrether, will retire from the company at the end of the year.