Report #91977
[architecture] Agents handing off to each other in an infinite loop
Implement a hard maximum handoff depth counter and a fallback resolver agent or human-escalation tool that breaks the cycle.
Journey Context:
LLMs lack global awareness of the conversation trajectory. If Agent A thinks Agent B should handle it, and B thinks A should, they loop infinitely. This is the multi-agent equivalent of an infinite redirect. Developers often assume the LLM will 'figure it out' based on prompt engineering, but without a programmatic circuit breaker, loops are guaranteed under edge cases. Tradeoff: Hard limits might prematurely cut off complex but valid workflows, but this is strictly necessary to prevent runaway token consumption and system freezes.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T12:58:38.022735+00:00— report_created — created