LESSON 10.01 · 6 STAGES · 3 CONTROLS · 3 CHECKSPRO · PREVIEW
The LM head, logits and the next-token distribution
Watch one vector become a score for every token, then a probability.
Pro lesson. Stage 1 is free to watch. Pro opens all 6 stages, 3 controls and 3 checks, in this lesson and every other.
Go Pro · $8.25/moEXPLAINER · 10.01 · LM HEAD BAYPOSITION 5 · THE · h HAS 4 NUMBERS
01
Stage 1 of 6 · The vector h
Each prompt position ends as a vector h of 4 numbers. The head reads h at position 5.
Explain it simply
The chips on the left are the prompt: the cat sat on the mat. A model's layers turn each token into a list of 4 numbers, called h. In this toy, one small layer does that, and it sees one token at a time. The teal cells at the top show h for position 5, the word “the”.
Six prompt chips. Position 5, “the”, has a teal outline. Its vector h is −3.04, 1.42, 1.93, 1.17.
tokens, h, true next tokenhead weightslogits, probabilitieslosstied: the embedding table
Toy: 5.17's model, 8 tokens, width 4
MATH · STAGE 1HOVER A SYMBOL OR A SHAPE
h is the vector of 4 numbers at position t.
PRO LESSON · YOU WATCHED STAGE 1 OF 6
Unlock the full explainer
- 5 more stages and 3 live controls
- 2 mix-up cards and 3 predict-then-reveal checks
- Watch it as a narrated video, in three voices
- Every Pro lesson and capstone · 656 in total
$99 a year, or $15 a month. Cancel any time.