How does a machine finish your sentence?

A hands-on tour of what’s inside a large language model. No equations, no code: every idea is a toy you can poke.

live · a model’s entire job, on loop

That’s the whole trick: guess the next word, append it, repeat. Everything below explains how the guessing gets so good.

The journey

  1. TokensChopping language into pieces a machine can count.
  2. Meaning as a mapEvery word gets coordinates. Nearby means similar.
  3. AttentionEvery word looks back and decides what matters.
  4. Neurons & layersTiny pattern detectors, stacked until they understand.
  5. Prediction & samplingTurning hunches into words: temperature, top-p, and dice.
  6. A sense of orderHow a model knows “dog bites man” isn’t “man bites dog”.
  7. Mixture of ExpertsA committee of specialists, and only two get to speak.
  8. Speed tricksKV caches, shrunken numbers, and guessing ahead.
  9. TrainingWhere the knowledge comes from, and why models make things up.