Glossary
Key terms in the book, with the chapter where each first appears.
The fraction of times a model predicts the right next symbol on a piece of text.
A language model run in a loop with external tools and a harness so it can gather information, act on the outside world, and react to the results.
The part of a transformer layer where each token is pulled by the tokens before it, with learned strengths that let it focus on some and ignore others.
A language model that has finished pretraining on raw text and has not yet been taught to follow instructions or hold a conversation.
A system whose inputs and outputs we can see, while the meaning of its internal numbers stays opaque to us.
The stretch of preceding text a language model looks at when predicting the next symbol or token.
A move across the latent space towards a concept in its constellation, applied the same way to any token wherever it sits.
A skill, such as arithmetic or recalling capitals, that appears in larger language models even though they were trained only to predict the next token.
Placing a handful of solved examples in a prompt, followed by an unfinished one, so that a base model continues the pattern without any further training.
Training a pretrained model a little more, on a smaller and more specific set of examples, so that it does one job well.
Making sensible predictions on sequences of text the model never saw during training.
A fluent, confident answer in which a language model invents facts, names or details that are not true, because it predicts plausible text without checking reality.
The surrounding program that runs an agent's loop, intercepts tool calls from the model, executes them, and pastes the results back into the context.
A set of pulls inside a layer that looks back for an earlier occurrence of the current token and copies what followed it.
Fine-tuning a base model on a diverse dataset of prompt-completion pairs so that it favours helpful, direct answers over arbitrary continuations.
The effort to turn the internal positions, parameters and forces of a neural network into explanations humans can understand.
A system that assigns a probability to a piece of text, and can generate new text by predicting what is likely to come next.
The hidden geometric space inside a neural network where tokens sit as points and move from layer to layer.
One step inside a neural network, with its own parameters, that shifts every token to a new position before passing it on.
External notes, files or databases that an agent writes to and reads from across sessions so it can retain information beyond a single chat.
A flexible system of layers and tunable parameters that moves tokens across a latent space so each one lands near the next token in the text.
One of the adjustable numbers inside a model that training tunes to reduce prediction errors.
A measure of how uncertain a language model is, roughly how many symbols it hesitates between at each step (lower is better; 1 means no hesitation).
The extra training stages after pretraining that turn a base model into an assistant able to hold a conversation, follow instructions and reflect human preferences.
Nudging an assistant's parameters from pairwise human choices, so its replies move towards preferred answers and away from rejected ones.
Training a language model on vast amounts of plain text to predict the next token, before adapting it to any specific task.
A tiny neural network trained on the internal positions of another network, to check whether a concept, such as one or more than one, can be read off with a straight cut.
The opening text given to a language model so that the continuation it predicts is the answer or format you want.
Generating text by picking each next symbol at random, giving more probable symbols a higher chance of being chosen.
Making a language model better by growing its training data, its number of parameters and the computation spent training it.
A trend that appears as a straight line on logarithmic axes (a power law), used to predict how much a model improves as its size and data grow.
Packing more concepts than coordinates into a latent space by giving each concept its own direction, accepting small overlaps when concepts rarely co-occur.
A dataset of examples, each an input paired with the target we want for it (a sentence and its translation, a review and its verdict), written or checked by people.
Measuring a trained model on text kept hidden during training, to check how well it generalizes rather than memorizes.
One unit of text in a model's vocabulary, ranging from a single character to a common subword or whole word.
Splitting text into tokens from a fixed vocabulary, commonly built by repeatedly merging the most frequent neighbouring pairs (BPE).
An external action or capability, such as web search, reading a file, or running code, that a language model can invoke to observe or change the world.
Adjusting a model from examples of text, by counting frequencies or nudging parameters, until its predictions improve.
The collection of texts shown to a language model while it is being trained.
The kind of neural network inside every chatbot today, whose layers alternate pulls between tokens (attention) with pushes on each token alone.
The fixed set of symbols or tokens a language model recognizes and can choose from.