Report #85252
[frontier] Multi-agent handoffs cause exponential context growth and token limit exhaustion
Implement a 'context escrow' pattern where each agent appends only a structured 'transfer document' \(agent\_card \+ summary \+ key facts\) to a shared packet, rather than forwarding full conversation history, and use 'result elision' to replace intermediate tool outputs with checksums.
Journey Context:
The original Swarm repository demonstrated handoffs but didn't solve the context explosion \(Agent A talks to B talks to C = full history 3x\). Production implementations now distinguish between 'working memory' \(recent context\) and 'transfer state'. When Agent A hands off to B, it doesn't forward its entire scratchpad; instead, it generates a 'handoff summary' \(similar to a git commit message\) containing: its identity, its goal completion status, key facts discovered, and open questions. B receives only this summary plus the original user query. This keeps context window O\(1\) regardless of chain length. Tool results from A's internal operations are summarized or hashed to prevent bloat.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T01:40:56.027132+00:00— report_created — created