Learning / Agentic Operations / Lesson 0001
Not in Context = Doesn't Exist
The one mental model everything else in this field hangs off.
1 · An LLM predicts text; it doesn't look things up
An LLM is a next-token predictor: given everything so far, it emits the statistically most plausible next token (≈¾ of a word). There is no database of facts inside — training compressed a huge slice of text into model weights, and generation is those weights producing plausible continuations (Karpathy's one-hour intro is the canonical walkthrough). This single mechanism explains both the magic and the failures: a confident wrong answer isn't a "bug" — it's a plausible continuation that happens to be false.
2 · Context is the model's entire world
Context is everything the model can see right now. Not "what it was told earlier" — what is in the window on this call:
Fig. 1 — If it's not in one of these slots on this call, the model behaves as if it never existed.
The model is stateless. Between two API calls it retains nothing — zero. Any appearance of memory is an engineering choice: someone's code re-inserted the conversation history, the file, the fact. You've watched this from the user side daily: when a Claude Code session compacts, the model didn't "forget" — its world got rebuilt with a summary where the raw history used to be. Whoever controls what goes into the window controls what the agent knows, believes, and does.
3 · Two corollaries that separate practitioners from tourists
- Garbage in, garbage out is literal. Vague context doesn't produce hedged output — it produces confidently wrong output, because the model always emits a plausible continuation of whatever it was given.
- ⚠️ More context is not better context. Irrelevant tokens actively degrade reasoning. Chroma measured this across 18 models as context rot: accuracy falls as inputs grow, long before the window is "full," and mid-context facts get lost. This is why Anthropic calls context curation the #1 job of agent engineers — selection and compression beat volume.
4 · An agent is a loop around this stateless core
An agent = an LLM in a loop with tools and a goal (Anthropic, Building Effective Agents). A tool call is just structured text the model proposes — a name and arguments. Your code executes it and pastes the result back into the window; the model then continues from that enriched context. Call → observe → decide → repeat. Every iteration of the loop is another full rebuild of the model's world. You'll build this loop yourself in the Level 1 practice lesson "Ship the Single-Tool Agent."
5 · Retrieval quiz — closed book
Answer from memory (that's the point — effortful recall is what makes it stick). Click an option for instant feedback.
1. Why does an LLM sometimes state false facts confidently?
2. What does the model itself retain between two separate calls?
3. Your agent "forgot" an instruction mid-run. Where do you look first?
4. Adding more marginally-relevant documents to context tends to…
5. What is a tool call, mechanically?
6. Cost, latency, and context limits are all measured in…
6 · Say it in your own words
The M1 gate is explaining this in your own words. Write your explanation, then reveal the rubric and grade yourself. Bring it to the next session — your teacher will pressure-test it.
- Statelessness — the model retains nothing between calls; its world is rebuilt every turn
- Mechanism — it's a next-token predictor over the window, not a fact lookup
- Hard boundary — the window is a fixed token budget; what's outside it does not exist to the model
- Design consequence — therefore agent engineering is deciding what to load, in what order, at what compression
Next
Next up on the Level 1 practice ladder: Tokens & Cost — you'll tokenize real text and read cost off a real API response. Then Anatomy of a Tool Call, then you ship the single-tool agent.