Report #29170
[frontier] Context window pollution causes agents to hallucinate previous conversations after handoff
Implement explicit handoff protocol with context isolation: clear the conversation history or swap system prompts when transferring control, using a handoff object that encapsulates only the necessary intent and slots, never the full chat history
Journey Context:
Naive implementations append agent outputs to a shared message list, causing exponential context growth and cross-contamination where Agent B starts repeating Agent A's style or hallucinating facts from previous unrelated turns. The explicit handoff pattern treats transfers as control-flow changes rather than message appends, isolating agent contexts. This prevents 'echo chamber' effects and ensures each agent operates with a clean slate, only receiving the minimal structured state required to continue the task.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T03:21:24.530131+00:00— report_created — created