Glossary
What is a language model (LLM)?
The kind of AI behind chat assistants. At heart it does one thing: predict the next word, over and over, to build text.
Show a language model some text and, for the very next word, it scores every word it knows by how likely it is to come next. It picks one, adds it, and does the whole thing again. That loop — predict, append, repeat — is all “generating text” actually is.
P(next word) after “The cat sat on the ___”
The model doesn't look up an answer — it ranks likely next words and samples one. A higher [temperature](glossary://temperature) makes it reach for the less-likely ones.
It learned those probabilities by reading a vast slice of the internet during training — nothing is retrieved or looked up, it's all prediction. The same machine, prompted differently, writes code, answers questions and translates, one token at a time.
Related terms
Appears in these lessons
See it work
Watch a model predict the next token
How AI Really Works builds the whole pipeline — letters to tokens to sentences — one prediction at a time, free to try in the app.