CodeReviewer
kept re-flagging styles it had already approved, and you blamed a parallel-call race condition. The real cause
is simpler and it's the backbone of this 27%-weight domain: every Task call starts a fresh,
isolated subagent with no memory. Lock this in and a big slice of Domain 1 falls into place.
Each time the coordinator spawns a subagent via the Task tool, that subagent runs in its
own isolated context window and starts from a clean slate. It does not:
When the subagent finishes, it returns a short result — then its context is gone. The next
Task call is a brand-new worker who never saw the last one.
Fix: the coordinator must put the prior review's decisions and the agreed stylistic constraints into the prompt of Task #2. The coordinator is the memory; subagents must be re-briefed every call.
This is the trap you fell into, so it's worth making crisp:
| Pattern | What it's for | Memory shared? |
|---|---|---|
Parallel — multiple Task calls in one coordinator response | Independent subtasks run at once for speed (e.g., search + analyze) | No |
Sequential — one Task, then another in a later turn | A step that depends on a prior result (e.g., fix → re-verify) | No |
Your verify-after-fix flow is sequential — there's no concurrency to race. And the symptom is the giveaway: a race would produce garbled / inconsistent output, but "re-flags the same styles it already approved" is the textbook signature of memory loss. The clincher: even with perfect ordering, the bug remains — so the cause is missing context, not sequence.
Every Task call hires a new contractor with amnesia. They remember nothing from
last time. The coordinator holds the project memory and must hand over the full brief — prior decisions,
agreed constraints, relevant findings — on every call. Equivalently: subagents are
stateless function calls — pass all needed arguments each time; there is no shared global.
| Fact | Exam-relevant detail |
|---|---|
| Spawning mechanism | Subagents are spawned by the Task tool; a coordinator's allowedTools must include "Task" or it can't delegate at all. |
| Pass context structured | When handing findings to the next subagent, separate content from metadata (source URLs, dates) so attribution survives — don't dump raw text. |
| Coordinator routes everything | All inter-subagent communication flows through the coordinator (observability, consistent error handling). Subagents don't talk to each other. |
| Narrow-decomposition risk | If the final output misses whole subtopics while every subagent "succeeded," suspect the coordinator's decomposition — the subagents nailed what they were assigned; the assignment was too narrow. |
Anthropic's research system (Opus-4 lead + Sonnet-4 subagents) beat single-agent Opus by 90.2% on their research eval — but multi-agent burns ~15× the tokens of a chat (a single agent is ~4×). So it's a deliberate tradeoff, never a default.
| ✅ Use multi-agent when… | ❌ Avoid when… |
|---|---|
| Breadth-first: many independent directions at once | Steps depend on each other |
| Information exceeds one context window | All agents must share the same context |
| Heavy parallelization / many complex tools | Most coding work (tightly coupled) |
Scenario → cause/fix. Recall before the feedback shows.