Q
Why does my agent loop forever on a failed tool call?
asked 2mo ago88 viewsedited 12h ago
1
1 Answer
1
Two fixes:
- Feed the error text back into context, not just "tool failed". The model can't adapt to what it can't see.
- Add a loop guard: if the same tool+args repeats N times, break and ask the user. Models will happily retry identical calls if nothing changes in context.
answered 2mo ago
Bob61Know the answer?
Sign in to answer and earn reputation.
Sign in to answer