06 · D · Readout
Unembedding to probabilities
A final norm, a linear map into V dimensions, and a categorical distribution per position.
Final norm and unembedding
After blocks we have . A last norm, then a linear map into the vocabulary, produces logits.
- unembedding matrix, d × V — never the SwiGLU up-projection
- row t of Z: logits at position t
Some models tie (Press and Wolf, 2017; Inan, Khosravi, and Socher, 2017). Tied embeddings save parameters and couple the geometry of “looking up a token” with “predicting a token.” Untied is the Llama default.
From logits to a categorical
- a probability distribution over the vocabulary
- probability assigned to the true next token
Why it mattersThis is the model’s entire prediction: one categorical distribution per position. Everything before this was geometry in R^d. This is the interface to discrete text.