Apple has been quiet about ChatGPT. Now Tim Cook says its hefty $22.6 billion research spend is down to generative AI.