Amazon wants to dominate the three core layers of artificial intelligence: infrastructure, large language models, and software.