Why spawn a subagent at all

Lesson 1 of 5 in Subagents and Context Isolation: The Delegation Move.

The multi-agent module gave you the honest reason to add a second agent: another context window. This module is that reason turned into a working skill — the delegation move. A parent agent spawns a subagent, hands it a brief, and gets back a compressed report. Done well, it is the single highest-leverage act of context engineering an agent can perform. Done carelessly, it is how good runs go quietly wrong.

Start with the accounting. The parent’s context is not just finite — it is load-bearing. It holds the user’s goal, the constraints discovered so far, the plan, the half-finished reasoning. Every token of bulk material you pour into that window sits in front of every decision the parent makes from now on. Context is the scarce resource; everything else in this module follows from that sentence.

Make it concrete. The task needs someone to read fifty source files to answer one question: which of these route handlers is missing an auth check? Read them inline and roughly 80k tokens of file contents move into the parent’s window — and never leave. Every later step now reasons past fifty files of noise, and the run degrades in the familiar ways: vaguer answers, re-fetching things it already saw, forgetting the user’s constraint from turn two.

A subagent can read all fifty files and return one paragraph. Its window fills with the same 80k tokens of bulk — and then the window is thrown away. The finding comes home; the mess does not. The subagent’s context is disposable in a way the parent’s never is: it gets garbage-collected the moment the report returns.

Reading 50 files: inline vs. delegated
Inline — the parent readsDelegated — a subagent reads

What the parent retains

~80k tokens of raw file contents, permanently occupying the window

One paragraph: the finding, plus file paths as evidence

What later steps see

Every subsequent decision reasons past fifty files of noise

A clean window still dominated by the goal and the plan

Total tokens spent

Lower — no second system prompt, no brief, no report

Higher — a fresh context pays its own setup, then does the same reading

When it wins

The parent needs the raw contents verbatim — it is about to edit those files

The parent needs the answer, not the material

Key terms: subagent, context window, context isolation, context engineering, token

Interactive checkpoint quiz (2 questions) — open this page in a browser to take it.