← All courses LLMs from scratch
18 lessons

How large language models actually work

A slow, visual, hands-on course. It starts with "what is a token" and ends with mixture-of-experts routing, speculative decoding, and RLHF. Every lesson has interactive diagrams you can poke at and exercises that check your answer.

Your progress
Saved in this browser's local storage.

How to use this course

  • Go in order. Each lesson assumes the previous one.
  • Play with every diagram before reading past it. Move the sliders, break things, watch what changes.
  • Do the exercises with the text hidden if you can. Retry as often as you like.
  • Mark a lesson read when you finish it. Progress lives in local storage on this device, so use Export if you want to move it.
  • The ◐ button in the header cycles the theme: follow your system, force light, force dark.