Concept
Context window
You might say: context budget, working context
Everything the model sees on each model provider request. It is finite and is the only surface through which the model perceives.
- What it does
- Carries a run's working state from turn to turn. A fresh run can start with an empty window, so sizing a task to one session keeps it in the sharpest part of the session.
- Ask
- What must this run see now, and what can it leave behind?
- Trouble
- Quality drops as the window fills. Attention degrades, and compaction or autocompact can lose detail; clearing discards the working state.
What to look for
- A context meter fills as messages, model responses, and tool results accumulate
- A compaction or autocompact event replaces history with a summary
- A new session opens with an empty context window
Connections
- See also: Instructions
- See also: Tool access
Sources
- Matt Pocock, AI Coding Dictionary, Context window
Everything the model sees on each model provider request. Finite, model-specific, and the only surface through which the model perceives anything.
- Matt Pocock, AI Coding Dictionary, Context window
Finite means it fills up. Every turn appends more — your messages, the model's responses, tool results — and a long session will eventually hit the limit, forcing compaction or clearing.
- Matt Pocock, AI Coding Dictionary, Clearing
The next message begins with an empty session and an empty context window.
- Matt Pocock, AI Coding Dictionary, Smart zone
Doing one task per session gives each task the sharpest part of the session.
- Matt Pocock, AI Coding Dictionary, Smart zone
Early in a session the agent is sharp and focused. As the session grows it drifts into a dumb zone: sloppier, forgetful, more mistakes.
- Matt Pocock, AI Coding Dictionary, Attention degradation
As a session grows, each token's attention budget is spread across more competitors. The signal on any one meaningful relationship shrinks; noise from irrelevant context crowds in.
- Matt Pocock, AI Coding Dictionary, Compaction
Whatever didn't make it into the summary is gone from the context.
- Matt Pocock, AI Coding Dictionary, Autocompact
Compaction is lossy, and autocompact is lossy at a moment you didn't choose.
- Matt Pocock, AI Coding Dictionary, Clearing
What's gone is the agent's working state: the model is stateless, so the new session knows nothing the old one knew.
Use it on your project
teardown-apply: hold "Context window" (context-window) from the teardown at https://teardownatlas.com/software-factory/ against my project
Paste it into a coding agent that has the teardown skills.
An AI agent wrote this map with the teardown skill. It can contain errors: check the sources before you rely on a part. About and legal