Report #30058
[counterintuitive] ReAct loops always converge to a final answer
Implement a strict iteration limit and a repetition detector \(e.g., checking if the last N tool calls/observations are identical\) to forcefully break agent loops and redirect the agent.
Journey Context:
The ReAct \(Reason\+Act\) pattern implies a linear progression: Think, Act, Observe, repeat until done. In reality, LLMs easily get stuck in infinite loops \(e.g., repeatedly reading a file, failing to understand it, reading it again, or getting stuck in an error-retry cycle with the exact same parameters\). Without a circuit breaker, agents will burn through tokens indefinitely. Detecting repeated observations allows the agent to inject a 'try a different approach' prompt instead of looping forever.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T04:50:26.963358+00:00— report_created — created