← Writing

Large language models · Book Animated · Chapter 1 of 12 · 14 steps

An Introduction to Large Language Models

From Hands-On Large Language Models by Jay Alammar and Maarten Grootendorst (O'Reilly Media, 2024) · book code ·

Step through with the arrows inside, or click the animation and use ← →

Open on its own

This chapter is built for a larger screen. Turn your phone sideways, open it on a computer or tablet, or open it on its own.

In this chapter · 14 steps

The book’s history of Language AI, from counting words to today’s large language models, in five parts. Choose a part to jump to it.

  1. AStep 1 What is Language AI? GPT-2, ChatGPT, and why 2023 changed the field.
  2. BSteps 2–4 Representing language Bag-of-words, word2vec, and what embeddings capture.
  3. CSteps 5–7 Context and attention Recurrent networks, attention, and the Transformer.
  4. DSteps 8–10 Encoders and decoders BERT, GPT, and the year of generative AI.
  5. ESteps 11–14 Training and using LLMs Pretraining, fine-tuning, responsible use, and a first generated text.

Cite this chapter

If you use or reference this animation or its figures, please cite it:

Guo, J. (2026). An Introduction to Large Language Models [Interactive animation]. Book Animated: Jay Alammar and Maarten Grootendorst, Hands-On Large Language Models, Chapter 1. University at Buffalo. https://jue-guo.com/writing/hands-on-llms-01-introduction/

BibTeX
@misc{guo2026handsonllms01introduction,
  author       = {Guo, Jue},
  title        = {An Introduction to Large Language Models},
  year         = {2026},
  howpublished = {Interactive animation, University at Buffalo},
  url          = {https://jue-guo.com/writing/hands-on-llms-01-introduction/},
  note         = {Book Animated: Jay Alammar and Maarten Grootendorst, \textit{Hands-On Large Language Models}, Chapter 1}
}

The animation and its figures are my own walk through the chapter; the book is the source. Questions, corrections, or a chapter you would like next? Write to me. New chapters are announced in the feed.