The Shared Dictionary

In lesson 1, text went into the model and text came out, one token at a time.

What the picture shows

Lesson 1’s picture again: the question ‘What is the capital of France?’ goes into the closed box, Qwen3.5-4B, and the reply ‘The capital of France is **Paris**.’ comes out token by token. Then the lid comes off to show what the box is made of: numbers, drawn as 32 columns of points, one per layer, labelled 4,205,751,296 numbers.

The next-token loop of mlx-community/Qwen3.5-4B-4bit on the question “What is the capital of France?” wrapped in the chat template, 19 tokens: “<|im_start|>” (special token), “user”, line break, “What”, space, “is”, space, “the”, space, “capital”, space, “of”, space, “France”, “?” (punctuation or formatting), “<|im_end|>” (special token), line break, “<|im_start|>” (special token), “assistant”, line break, “<think>” (special token), 2 line breaks, “</think>”, 2 line breaks. At each step, the three most likely next tokens: step 1: “The” 100%, “**” (punctuation or formatting) <0.1%, “Paris” <0.1%; chose “The”; step 2: space, “capital” 100%, space, “national” <0.1%, space, “**” (punctuation or formatting) <0.1%; chose space, “capital”; step 3: space, “of” 100%, space, “city” <0.1%, space, “and” <0.1%; chose space, “of”; step 4: space, “France” 100%, space, “**” (punctuation or formatting) <0.1%, space, “the” <0.1%; chose space, “France”; step 5: space, “is” 100%, space, “(” (punctuation or formatting) <0.1%, “,” (punctuation or formatting) <0.1%; chose space, “is”; step 6: space, “**” (punctuation or formatting) 100%, space, “Paris” 0.2%, space, “the” <0.1%; chose space, “**” (punctuation or formatting); step 7: “Paris” 100%, space, “Paris” <0.1%, “巴黎” (Chinese characters) <0.1%; chose “Paris”; step 8: “**.” (punctuation or formatting) 95%, “**” (punctuation or formatting) 4.7%, “**,” (punctuation or formatting) <0.1%; chose “**.” (punctuation or formatting).

Qwen3.5-4B: 32 layers, 2560 numbers wide, 248,077 tokens in its vocabulary, 4,205,751,296 parameters in 2,367,118,848 bytes, quantised to 4 bits in groups of 64.

Where this comes from

flipbook-france-chat-qwen Measurement

The next-token loop: the model's probabilities for the next token (the softmax of its final logits at the last position, over every row of its output table) at each step of greedy decoding, the top 10 with the probability of everything else.

Model
mlx-community/Qwen3.5-4B-4bit, quantised: 4-bit, groups of 64
Built by
lab/precompute/next-token-flipbook.py
Commit
5f8af57
From stored results
No: a fresh run
Inputs
sha256:7e714f39738b3c1a8c0906d010ee1c9b8f1ee51277935668a5ec3fe9a3443122
Made
2026-10-15

model-card-qwen Measurement

The model's specifications, computed from its config.json, tokenizer and weights: parameters and bytes count the language model only, without the vision encoder; a quantised weight counts at its unpacked size.

Model
mlx-community/Qwen3.5-4B-4bit, quantised: 4-bit, groups of 64
Built by
lab/precompute/next-token-flipbook.py
Commit
5f8af57
From stored results
No: a fresh run
Inputs
sha256:6710545c77d59f772adbd96e4626fda9a8caa218848e3989cdd758056d06fedb
Made
2026-10-15

Glossary