Case file AI3

Working Context

Context is a finite resource.

Even at a million tokens, the agent's context window is finite and the failure modes get worse, not better, as it fills up. Manage the surface like RAM: compact, clear, fork.

ByAdam LewisPublished3 May 2026Revised13 Oct 2026Reading13 minVersionv1.2ConfidenceHigh
§0b

Opinion

The 1M-token context window is the most misread feature of the year. The lay reading is “paste in anything”; the literature reads it as “the room to design a context that fits.” Anthropic's own phrase is the right one: context as a precious, finite resource.1 A model running near its window limit makes worse decisions than the same model running at half the window with the right tokens in the right order. Bigger windows did not retire the problem. They enlarged the surface across which the problem operates.

Drew Breunig's catalogue of context failures is the cleanest taxonomy in print: poisoning (a hallucination becomes load-bearing because it sits in the transcript), distraction (volume overwhelms the training signal), confusion (irrelevant tokens skew the response), clash (parts of the context disagree, and the model is dragged along by the wrong part).2 The long agent sessions I've sat with manifest the same shapes: usually three of the four, sometimes all of them. The fix is the discipline Anthropic built into Claude Code as /compact and /clear: when the context starts working against the agent, take an action.

The other half of the rule is the surface itself. Anthropic's engineering team wrote it down explicitly: “The only content you pass from parent to subagent is the Agent tool's prompt string, so include any file paths, error messages, or decisions the subagent needs directly in that prompt.”3 Translate: anything outside the surface is outside the agent's mind. AI2 Persistent Brief goes into every session. Volatile per-feature scratch comes out at the boundary. Tools belong inside the surface so the agent never has to leave it (MCP-first). The merged principle is the discipline that makes the rest of the AI pillar work.

Copy a note and link

Grab this short comment and drop it into a PR comment or an LLM chat to prompt the right change.

Context is a finite resource, even at 1M tokens. Compact, clear, or fork when the context starts working against you. Bring tools to the agent rather than switching the agent to other surfaces. Spawn subagents for parallel or large-output work so the orchestrator's window stays clean.

/tenet/working-context/AI3
Copy for paste
§0c

AI eyes only

Rule: context is a finite resource. Compact, fork, or delegate before it works against you.

Reject: continuing in a transcript past the compact threshold. Reject: doing long-running or large-output work in the orchestrator's window. Reject: context-switching to surfaces the agent cannot observe.

Generate: offer to compact at the threshold. Spawn a subagent for parallel, long-running, or large-output work and return only the summary. Use MCP tools so results return to the same surface, not a different chat.

Diagnostic: estimate the working-set tokens for the next step. If they exceed half the window, route the step to a subagent.

§0d

Why?

  • Names the failure modes. Poisoning, distraction, confusion, clash: once teams have the vocabulary, they can spot the bug in the moment instead of blaming “the model got tired”.
  • Three verbs cover it. Compact when the transcript bloats. Clear when the next task is unrelated. Fork into a subagent when the work will produce a wall of output. No further abstractions needed.
  • Bring the tool to the agent. MCP servers for GitHub, Figma, the database, the linter mean the agent never has to be told to look outside its surface: the result is in the transcript and the next turn can reason about it.
  • Subagent isolation is the modern session boundary. Heavy work runs in a child agent with its own clean context. Only the summary returns. The orchestrator stays sharp.
  • Compounds with AI2 Persistent Brief. The brief loads on every session. Per-feature context is volatile and disposable. Two halves of the same context-engineering discipline.
  • Survives the next window-size jump. The principle is the property (signal-to-noise) rather than the prescription (one feature per session). Whatever the window is next year, the rule still applies.
  • Aligned with Anthropic's first-party engineering posts. The vocabulary, the verbs and the subagent boundary all come from Effective Context Engineering, not Prickles inventions.
The receipts
Origins, quoted passages, evidence, the strongest counter-argument and the reply.
§1

Origins

The first version of this discipline was “one feature per session”: the pre-2025 idea when context windows were small and agents drifted predictably as the transcript grew. The idea held for the 8K and 32K-token era. It held less well for the 128K era. By the time Claude 4.5 shipped 1M tokens it had become anachronistic. The agent could hold the entire feature plus the brief plus the plan plus the test output without coming close to the limit.

Drew Breunig's two-part essay on context failure (June 2025) is the work that reframed the problem.2 Long contexts don't fail because they hit the limit. They fail because the training signal degrades as irrelevant tokens accumulate. Breunig catalogues four mechanisms: poisoning (a hallucination earlier in the context becomes a load-bearing fact for later turns), distraction (the context grows long enough that the model over-focuses on it and neglects what it learned in training), confusion (the model overweights tokens that are unrelated to the task), clash (later instructions contradict earlier ones and the model picks the wrong one). All four get worse with session length, not better and they get worse faster than the context window grows.

Anthropic's Effective Context Engineering for AI Agents (September 2025) is the first-party version of the same insight. The paper introduces the statement that drives the headline of this tenet: “context as a finite resource.”1 The same paper documents three primary tools for managing the surface: the committed brief loaded up front. Primitives like glob and grep for just-in-time retrieval. And a memory tool (public beta) that stores information “outside the context window through a file-based system.”4

The other half of the merged tenet, the surface itself, comes from the multi-tool tradition that built up around MCP and subagents. Anthropic's subagent documentation is explicit: “subagents use their own isolated context windows, and only send relevant information back to the orchestrator.”3 The Agent SDK paper makes the prompt-string-as-only-channel claim that gives the surface its operational meaning: tools live inside the agent's surface, or they live in a place the agent can't reach. There is no third option.

§2

Quotes

Each subagent might explore extensively, using tens of thousands of tokens or more, but returns only a condensed, distilled summary of its work (often 1,000-2,000 tokens). … But even as capabilities scale, treating context as a precious, finite resource will remain central to building reliable, effective agents.

Anthropic · Effective Context Engineering for AI Agents (September 2025)

But in reality, longer contexts do not generate better responses. … Contexts can become poisoned, distracting, confusing, or conflicting.

Drew Breunig · How Long Contexts Fail (June 2025)

The only content you pass from parent to subagent is the Agent tool’s prompt string, so include any file paths, error messages, or decisions the subagent needs directly in that prompt.

Anthropic · Building Agents with the Claude Agent SDK

If you treat your context like a junk drawer, the junk will influence your response.

Drew Breunig · How to Fix Your Context (June 2025)
§3

Evidence

15 external sources, ranked by author authority. The first five are the canon; expand to see the rest, including the qualifiers and the named opposers. Each links out to its primary source.

  1. 01
    Anthropic · 2025
    The first-party statement of the headline phrase: context as a precious, finite resource. Source for the persistent-brief / just-in-time-retrieval / memory-tool triad.
  2. 02
    Drew Breunig · 2025
    Names the four failure modes: Poisoning, Distraction, Confusion, Clash. The taxonomy practitioners use to spot the bug in real sessions.
  3. 03
    Drew Breunig · 2025
    Companion piece to How Long Contexts Fail. Documents the verbs: Quarantine (subagents), Pruning, Summarization, Offloading (memory tools, RAG).
  4. 04
    Drew Breunig · 2025
    Presents the discipline as the next layer past prompt engineering. The argument that context is the right unit of design for agentic work.
  5. 05
    Anthropic · 2025
    Subagent isolation as the modern session boundary. The only channel between parent and child is the prompt string: the surface-as-discipline reading at architectural scale.
  1. 06
    Anthropic · 2025
    Each subagent runs in its own context window with a custom system prompt, specific tool access, and independent permissions. Reference for how to fork operationally, not just theoretically.
  2. 07
    Anthropic · 2025
    The 1M-token announcement. Useful precisely because it sits alongside the context-engineering paper: bigger windows are not a replacement for the discipline.
  3. 08
    LangChain · 2025
    Cross-framework survey of context-engineering practice. The patterns generalise beyond Anthropic: same verbs, same failure modes, different SDKs.
  4. 09
    Liu et al. · 2023
    Stanford / Berkeley study showing capability degrades when relevant information sits in the middle of a long context. Empirical grounding for the Distraction and Confusion failure modes.
  5. 10
    Bai et al. · 2024
    Benchmark suite that demonstrates measurable degradation with context length even in models advertised for long context. Evidence the Breunig failure modes are not folklore.
  6. 11
    Anthropic · 2024
    The standard that lets you bring tools into the agent's surface instead of switching the agent out of it. Direct enabler of the MCP-first half of the merged tenet.
  7. 12
    Anthropic · 2025
    First-party verbs for managing the surface. /compact summarises the transcript; /clear resets it. Reference for the operational meaning of compact / clear / fork.
  8. 13
    Andrej Karpathy · 2026
    Software 3.0: the context window as the new program. Karpathy's framing that the programmer increasingly orchestrates agents, and that the context window rather than the source file is the thing being programmed.
  9. 14
    Hubinger et al. · 2024
    Background safety case for keeping the working surface small and inspectable. The risk of poisoning by adversarial earlier-context content amplifies the case for compact / clear.
  10. 15
    Cursor · 2025
    Cursor's per-conversation context controls and multi-pane workflow. Different surface, same discipline: the IDE makes context-management an everyday workflow concern.

Fifteen sources. The supporters cluster on Anthropic's engineering posts (Effective Context Engineering, Claude Agent SDK) and on Drew Breunig's three-essay series on context failure and repair. The qualifiers further down frame the same ideas in framework-neutral terms. The opposing voice (that the 1M-token window has retired the problem) is the reply's primary target.

§4b

Enforcement

Viewing: TypeScript.

Apply these rules in eslint.config.mjs. The full enforcement across every tenet lives on the implementation page.

RuleToolCatches
max-linesESLint corefiles that have grown past the model's cheap-edit budget. 150 lines is Prickles' working cap; tune to your team's preferred ceiling.
max-lines-per-functionESLint coremonolithic functions the agent has to read in full to edit safely. Small functions keep context per edit small.
max-paramsESLint corefunctions with too many parameters: high parameter count is a context-hostile signal even when the function body is small.
GitHub Actions: context budgetGitHub ActionsPRs that touch enough files to blow the agent's cheap-context budget. Token counting in CI makes the cost visible.
eslint.config.mjsconfiguration snippet
import { defineConfig } from 'eslint/config';
import tseslint from 'typescript-eslint';

export default defineConfig({
  files: ['**/*.{ts,tsx}'],
  rules: {
    'max-lines': ['error', { max: 150, skipBlankLines: true, skipComments: true }],
    'max-lines-per-function': ['error', { max: 15, skipBlankLines: true, skipComments: true }],
    'max-params': ['error', 3],
  }
});
§4c

AI rules

File.cursor/rules/ai3-working-context.mdc
---
alwaysApply: true
---

## Prickles AI3: Working Context

Treat the agent's context window as a precious, finite resource: Anthropic's own phrase. Context is not free. Tokens that crowd the model degrade its work.

Compact, clear, or fork when the context starts working against you. Long sessions accumulate poisoning, distraction, confusion, and clash (Breunig's four failure modes). The fix is to manage the surface, not to power through.

Bring tools to the agent (MCP-first). Don't context-switch the agent out of its surface. If it can't see the result, it can't reason about it.

Subagents are the modern session boundary. Long-running, large-output, parallel work belongs in a subagent with its own isolated context: only the relevant summary returns to the orchestrator.

Repo layout, CI, and ESLint wiring for these paths live on /implementation, not repeated on every tenet.

§5

Counter-argument

Counter

The honest steelman is that the rule is now anachronistic. Claude 4.5 has 1M tokens, GPT-5 has 400K and Gemini 2.5 Pro has 1M.5 “One feature per session” sounded like wisdom in the 8K-token era. Today the next feature's context fits twenty times over. The agent can hold the persistent brief, the planning thread, the in-flight diff, the test output and the documentation page simultaneously. If the context window has grown faster than the work, the discipline of aggressively pruning it is solving a problem that no longer obtains.

§6

Counter-argument retort

Reply

The 1M-token argument concedes the surface and asks for the discipline to vanish. The surface is the discipline.

Bigger windows did not retire Breunig's four failure modes. They amplified them. A context that is 30% relevant and 70% noise is still 70% noise no matter how much fits inside it. Anthropic's own October 2025 paper is explicit on this point: the recommendation to treat context as a finite resource was written after the 1M window shipped, not before.1 The mechanism that motivates the rule is degradation of the training signal as irrelevant tokens accumulate. That mechanism does not care about the window size.

The empirical evidence is on Anthropic's side. Long-context benchmarks consistently show capability degradation past the “needle in a haystack” level: the model can find a fact in 1M tokens, but reasoning about that fact in the presence of 999,999 other tokens is materially worse than reasoning about it in the presence of a thousand. Hugging Face's benchmark suite, the LongBench papers, and Anthropic's own internal evaluations all point the same way. The window is not the bottleneck. The signal-to-noise ratio inside it is.

The compromise the steelman reaches for, “just paste everything in”, is the failure mode the rule names. Compact, clear, and fork are the verbs that work because they are the verbs that change the ratio. /compact in Claude Code is not arbitrary: the model summarises the transcript so the next turn starts with a higher signal-to-noise ratio than the last turn ended on. Subagents are not decorative. They are how you keep the orchestrator's context clean while the work itself runs in a surface that can absorb the noise. Pair this with AI1 The Intern Pattern and AI2 Persistent Brief and the surface is small, intentional, and reproducible across every session.

§7

Notes

  1. [1]Anthropic: Effective Context Engineering for AI Agents (September 2025). Context as a precious, finite resource. The paper that sets out the idea this tenet is built around: written after the 1M-token window, not before.
  2. [2]Drew Breunig: How Long Contexts Fail (June 2025). Catalogues the four failure modes: Context Poisoning, Context Distraction, Context Confusion, Context Clash. Companion piece How to Fix Your Context (June 2025) lists the verbs: Quarantine, Pruning, Summarization, Offloading.
  3. [3]Anthropic: Building Agents with the Claude Agent SDK. Subagents use their own isolated context windows and only send relevant information back to the orchestrator. The architectural source for the surface-as-discipline reading; the prompt-string-only channel is documented in the Agent SDK subagents reference.
Disagree? Found a hole in the argument? Take issue with this tenet →
Last revised: 2026-10-13