FREE LLMs & agents LESSON · LLMs & agents
Trace one generated token
Context, attention, residuals, and decoding
The model predicts a distribution, not a fact.
Text becomes tokens, tokens become vectors, and each transformer block updates a residual stream using attention and learned nonlinear transformations. The final state produces logits over the vocabulary; decoding chooses the next token. Attention routes information between positions, but it does not by itself provide truth, memory, or tool authority.
Fluent output is evidence of probable continuation under context—not evidence that a claim was checked.
Context is a contested working memory.
System instructions, user content, retrieved documents, tool results, and prior messages compete inside the same context. Untrusted text can attempt to redirect the model. Separate data from instructions, preserve provenance, minimize context, and enforce policy outside the model so a generated string cannot grant itself authority.
Prompting influences behavior; external controls define permission.