Which model for each step of your agent
Everyone publishes “the best model for coding”. Almost nobody publishes the thing people actually build: a workflow with several steps, a different model on each, and what one run costs. A planner called once and an implementer called twelve times have almost nothing in common — but most agents run both on whatever model the team picked first.
Below are four setups with the model each step should use, and the same workflow priced with one frontier model doing everything. Every figure is computed from today’s prices at the cheapest major provider — nothing here is hand-written.
Coding agent
Plan once with a frontier model, implement and review with cheaper ones.
The shape almost every coding agent converges on. Planning is one expensive call where being wrong is costly, so it gets a frontier model. Implementation is dozens of calls where a good mid-tier coding model is indistinguishable in the diff, and the final summary is nearly free. Running all four steps on the planner's model is the version most people ship by accident.
| Step | Needs | Model | Arena | Calls | $ / run |
|---|---|---|---|---|---|
Plan the change Read the task and the relevant code, decide the approach and the files to touch. | Agentic / tool use ≥ 1394 tools · reasoning · 200K ctx One call, and every later step inherits its mistakes. This is where frontier quality is worth paying for — and it needs a big context window to hold the code it is reasoning about. | Gemini 2.5 Pro Google · 9 qualified | 1425 | 1 | $0.0575 |
Write the code Produce the actual edits, one call per file or hunk. | Coding ≥ 1478 tools The bulk of the spend — twelve calls against the planner's one. A competent coding model produces the same diff here, so this is the step where the cheaper choice actually pays. | DeepSeek V4 Flash via OpenRouter · 36 qualified | 1579 | 12 | $0.0144 |
Review the diff Check the changes against the plan and flag mistakes before a human sees them. | Coding ≥ 1545 reasoning Catching a bad edit is cheaper than shipping it, so the bar is higher than for writing — but it is only a couple of calls, so the price barely moves. | GLM-5.2 via DeepInfra · 4 qualified | 1587 | 2 | $0.0265 |
Summarise for the human Write the PR description and what changed. | Overall ≥ 1053 Prose from a diff. Almost any model does this well, and paying frontier rates for it is pure waste. | Llama 3.2 1B Instruct Meta · 177 qualified | 1055 | 1 | $0.00007 |
Research agent
Cheap fan-out for gathering, one strong model for the synthesis.
Research inverts the coding shape: the many calls come first. Fetching and extracting from twenty sources is high-volume, low-judgement work, while the synthesis at the end is a single call that determines whether the output is worth reading. Spending frontier money on extraction is the classic mistake here.
| Step | Needs | Model | Arena | Calls | $ / run |
|---|---|---|---|---|---|
Decide what to look for Turn the question into concrete sub-questions and search targets. | Agentic / tool use ≥ 1336 tools · reasoning Cheap in tokens but sets the direction, so it is worth a capable model. | DeepSeek V4 Pro DeepSeek · 17 qualified | 1380 | 1 | $0.00157 |
Read and extract Pull the relevant facts out of each fetched source. | Overall ≥ 1128 128K ctx Twenty calls over long documents — by far the largest token bill. This is mechanical extraction, so it needs context length far more than it needs intelligence. | GPT OSS 20B OpenAI · 165 qualified | 1288 | 20 | $0.00940 |
Write the answer Reconcile the extracts, resolve contradictions, produce the output. | Overall ≥ 1444 reasoning · 200K ctx The only step a reader actually sees, and the one that has to notice when two sources disagree. Frontier quality, once. | MiMo-V2.5-Pro Xiaomi · 11 qualified | 1465 | 1 | $0.0200 |
Document processing pipeline
Classify cheaply at volume, extract carefully only where it matters.
A high-volume back-office shape: thousands of documents in, structured data out. The trick is that most documents need almost nothing done to them. Classifying first with a cheap model, then spending real money only on the ones that need extraction, is the difference between a viable pipeline and an unaffordable one.
| Step | Needs | Model | Arena | Calls | $ / run |
|---|---|---|---|---|---|
Classify the document Decide what kind of document this is and whether it needs full extraction. | Overall ≥ 978 Runs on every single document, so unit price dominates everything else. A short label from a cheap model is all this needs. | Llama 3.2 1B Instruct Meta · 177 qualified | 1055 | 1 | $0.00003 |
Extract the fields Pull structured fields out of the documents that warrant it. | Overall ≥ 1324 tools Getting a field wrong is expensive downstream, so the bar rises — but tool use for schema-shaped output matters more here than raw intelligence. | GPT OSS 120B OpenAI · 142 qualified | 1366 | 1 | $0.00042 |
Verify the doubtful ones Re-check extractions that look inconsistent or incomplete. | Overall ≥ 1429 reasoning Only about one document in seven reaches this step, which is what makes a frontier model affordable at fifty thousand runs a month. | Hunyuan Hy3 via OpenRouter · 16 qualified | 1441 | 15% | $0.00021 |
Customer support triage
Route everything cheaply; answer well only when a human isn't taking over.
The highest-volume shape of the four, and the most sensitive to unit price. Every incoming message gets classified; only a fraction get a drafted answer. The economics live entirely in keeping the per-message step cheap.
| Step | Needs | Model | Arena | Calls | $ / run |
|---|---|---|---|---|---|
Triage the message Categorise, detect urgency and decide whether a human is needed. | Overall ≥ 978 Two hundred thousand calls a month. A cent of difference per call is two thousand dollars, so this step is chosen on price almost alone. | Llama 3.2 1B Instruct Meta · 177 qualified | 1055 | 1 | $0.00001 |
Draft the reply Write a grounded answer using the knowledge base. | Overall ≥ 1354 tools · 128K ctx The customer reads this, so quality matters — but only about 40% of messages get an automated reply at all, which keeps the cost of a better model in reach. | Qwen3.5 Flash Alibaba · 121 qualified | 1398 | 40% | $0.00022 |
Summarise for escalation Hand a human the context they need without making them read the thread. | Overall ≥ 1053 Internal-facing prose on a small share of messages. Cheap is fine. | Llama 3.2 1B Instruct Meta · 177 qualified | 1055 | 15% | $0.00001 |
Token costs only, at today’s prices, for the token volumes and call counts shown — a fractional call count means only that share of runs reaches the step. Excluded: your infrastructure, vector storage, the tool and API calls the agent makes, and retries. Arena scores are shown so you can see what each cheaper step trades away; the top overall score we track is 1504. The quality bar per step is our judgement, not a measurement — it is printed on every row so you can substitute your own.
Intelligence scores are community Arena ratings from LMArena / arena.ai, used under CC BY 4.0. Snapshot last refreshed 27 August 2026. Scores are a relative signal, not an absolute measure of capability. A Measured score was voted on directly; an Estimated score is inherited from an identical base model (a regional/creator-prefixed hosting duplicate). See our methodology.
FAQ
Why use different models in one workflow?
Because the steps have completely different requirements. A planner is called once and every later step inherits its mistakes, so frontier quality pays for itself. An implementer or classifier is called dozens or thousands of times and a mid-tier model produces the same result. Sizing each step separately is where the cost difference on this page comes from.
How are the models chosen?
For each step we take every model that clears a quality bar in the arena that matters for that job — and meets its tool-use, reasoning and context requirements — then pick the cheapest of those, priced at the cheapest major provider selling it. The bar per step is our editorial judgement, stated on each row so you can disagree with it.
Is the comparison against one model fair?
It is the baseline most teams actually run: pick the best model and use it for everything. Nobody should run a spam classifier on a frontier model, and that is exactly the point — the saving is large because the default is wasteful, not because the mixed setup cuts corners on the steps that matter.
Do these numbers include anything besides tokens?
No. These are input and output token costs at current prices for the token volumes shown. They exclude your own infrastructure, vector storage, tool and API calls made by the agent, and retries. Treat them as the model bill, not the total cost of ownership.
What quality signal is used?
Arena Elo from LMArena, the same source used across this site. Coverage differs by arena — overall 152, coding 94, math & reasoning 38, agentic / tool use 24 models scored — and the agentic arena is the thinnest, so where a step needs a broader pool we widen to the overall arena and label the row.
Related
- Best value LLMs — the full ranking these picks come from.
- Which model should I use? — set your own bar and requirements for a single step.
- Plan smart, build cheap — the two-model version, with your own token mix.
- AI agent cost calculator — price your own step counts and token volumes.