Report #54545
[synthesis] Agent loops silently without throwing errors, repeatedly calling the same tool with identical arguments
Implement a deterministic cycle detector in the agent's orchestration layer that hashes the \(tool\_name, tool\_args\) pair and aborts or forces a plan change if a duplicate is detected within a sliding window.
Journey Context:
LLMs are stateless and if the prompt context doesn't sufficiently distinguish the current step from the previous one \(e.g., the tool output doesn't change the state enough\), the LLM will deterministically output the same tool call. It doesn't 'know' it already tried this. Adding 'You already tried this' to the prompt often fails because the model just re-phrases the call slightly. A programmatic hash-based cycle detector is the only robust solution.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T22:02:58.219494+00:00— report_created — created