Agents & Tools
When Agents Fail
10 min+110 XPStep 1/11
Failure mode 1: the loop that won't die
Agents get stuck: the same failing tool call, retried forever. No exit, no progress — and every spin costs a full model call against a growing context. Teams have watched agents retry a dead endpoint dozens of times until the token cap saved them — burning dollars to produce nothing.
Every agent needs hard budgets:
- Max steps — 10–25 covers most tasks
- Token/cost cap per run
- Wall-clock timeout
- Loop detection — same tool + same args twice = kill
warning
An agent without a step limit isn't an agent — it's a bill. The failure mode isn't 'wrong answer', it's 'no answer, $3 later'.