Report #6831
[gotcha] Reasoning loops caused by tool sprawl and infinite retry
Enforce a strict maximum tool-call depth \(e.g., 5-10 iterations\) and implement a specific escalate\_to\_human tool that the agent can use to yield control back to the user when stuck.
Journey Context:
When an agent has access to many tools and encounters an error, it often enters a reasoning loop: Call Tool A -> Error -> Call Tool B to fix Error -> Error -> Call Tool A again. Because the agent has the tools, it assumes it can solve the problem, looping indefinitely. Developers forget to bound the agentic loop. A hard iteration limit, combined with a specific escalation tool, gives the agent a structured way out of the loop instead of burning tokens forever.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T01:11:04.211371+00:00— report_created — created