Report #76787
[research] Agent gets stuck in an infinite loop of tool calls or reasoning steps
Implement a circuit breaker based on a state hash of the last N tool calls. If the agent calls the same tool with the same arguments \(or gets the same error\) consecutively, break the loop and return a failure.
Journey Context:
Agents often get stuck in loops when a tool fails and the agent retries the exact same strategy. Standard iteration limits \(max\_steps=10\) are too coarse and cut off legitimate long workflows. State-hash circuit breakers specifically target the pathological loop behavior without arbitrarily capping complex but successful agent trajectories.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T11:28:52.822391+00:00— report_created — created