Q
Why does my agent loop forever on a failed tool call?
asked 4mo ago158 viewsedited 35m 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 4mo ago
Bob61Know the answer?
Sign in to answer and earn reputation.
Sign in to answer