Frequently asked questions
Why are AI agents so expensive?
Agents run in a loop, and each step re-sends the growing history โ system prompt, prior reasoning and every tool result so far. That accumulated context is billed as input again on every step, so a multi-step task costs several times more than a single call, even before counting the extra output.
How do I control agent token costs?
Summarise or truncate the scratchpad instead of carrying full history, cap the number of steps, prune verbose tool outputs before feeding them back, cache the stable system prompt, and use a cheaper model for routine steps. The lever is the re-sent context, which grows every step.