A token ceiling alone does not stop an agent. An agent can burn wall-clock time waiting on a slow tool, or hammer a database a thousand times with tiny payloads. Three independent counters cover the ways an agent actually spends, and each catches failures the others miss.
| Dimension | Caps | Catches | Blind spot |
|---|---|---|---|
| Tokens (input plus output) | Model consumption per task | Context accumulation, oversized prompts | Tool-side compute, API quotas |
| Tool calls | External invocations per task | Recursive loops, retry storms | Expensive single calls, long waits |
| Wall-clock time | Elapsed execution window | Hung loops, stalled dependencies | Fast loops that burn in seconds |
Production guidance on token budget controls recommends combining several units rather than relying on one token ceiling, because each has a blind spot (Trussed implementation guide). The same source names four patterns behind most uncontrolled spend: recursive tool calls, retry storms, self-invoked sub-agents, and reliance on provider rate limits alone.
The arithmetic matters. A naive agent loop re-bills the entire conversation history on every call, so total input tokens grow with the triangular number of steps rather than linearly, as the worked formula published by Augment Code shows. A per-call max_tokens setting does nothing to stop step forty from re-sending steps one through thirty-nine.
Decision rule: set the token budget from the observed p95 of a successful task of that class, multiplied by 1.5 to allow one recovery attempt. Set the tool budget from the p95 call count plus a small margin, and the time budget from the p99 wall-clock time. If a task class has no history yet, run it in observe-only mode and write the numbers down before enforcing anything.



