Report #76429
[architecture] Two agents hand off to each other indefinitely creating an infinite loop of API calls
Implement a maximum handoff counter and a TTL \(Time-To-Live\) in the orchestration state, aborting the workflow if either is exceeded.
Journey Context:
Autonomous multi-agent systems can get stuck in loops, especially when instructions are ambiguous. Agent A routes to B, B routes back to A. Without a circuit breaker, this loops infinitely, burning API credits. A simple integer counter in the shared state that increments on every transfer call prevents this. Tradeoff: Might abort complex but valid long chains, so the limit must be tuned to the specific workflow.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T10:52:51.784673+00:00— report_created — created