Small models vs frontier models: what drives agent cost per task

The short answer

An agent's cost per completed task is the number of model calls, times the tokens in each call, times the price of the model that takes the call, divided by the share of tasks that finish correctly. A small model is enough for steps with a narrow, checkable output, such as classifying a document or extracting fields against a schema. Keep the frontier model for the few steps that need judgment.

In this guide

  • The cost formula, term by term
  • Which steps a small model can take, and which it cannot
  • Static routing, dynamic routing and escalation
  • A worked example: a 40-step credit memo workflow, priced two ways
  • What self-hosting does to the math

What actually sets the cost of one agent task?

Four terms. Most budget surprises come from the two that nobody watches.

Cost per completed task = (calls × tokens per call × price per token) ÷ completion rate

  • Calls. Every time the agent reads, plans, calls a tool or checks its own work, that is a model call.
  • Tokens per call. Agents re-send context. If step 25 carries the transcript of steps 1 to 24, input tokens grow with every step.
  • Price per token. The spread between model tiers is wide. On Anthropic's public price list on 2026-12-01, Claude Fable 5.2 was listed at $8 per million input tokens and Claude Haiku 5.5 at $0.10 for prompts up to 100,000 tokens, an 80 times difference (Anthropic pricing).
  • Completion rate. A task that fails at step 38 has already spent the money. If 80% of runs finish correctly, every completed task carries the cost of 1.25 attempts.

Price per token is the term everyone negotiates. Calls and completion rate usually hide the larger savings, because a step that runs as code costs close to nothing.

When is a small model enough?

A small model is enough when the output space is narrow and a machine can check the answer.

StepExampleModel tierHow you check it
Classify into fixed labelsIs this attachment an ACORD 125, a loss run or a W-9?SmallLabel must be in the allowed list; spot-check against expert labels
Extract against a schemaDate of loss, policy number, estimate totalSmallTyped fields, range checks, cross-check against a second document
Look up, calculate, apply a written ruleNet leverage against a 3.5x covenantNone: codeUnit tests
Reconcile conflicting evidenceEstimate and photos disagree on damageFrontierExpert review
Interpret ambiguous policy languageDoes this exclusion apply to this loss?Frontier, then a personExpert review, approval gate

Two tests help. Can you write the output as a schema? Can you write a validator that rejects a wrong answer without a person? If both are yes, try the small model first.

How should you route steps between models?

Anthropic's guide to agent patterns describes routing as classifying an input and sending it to a specialised follow-up, and gives the example of sending easy, common questions to a smaller model and hard ones to a more capable model (Building effective agents). In an operations workflow there are three ways to do it.

  1. Static routing by step. You decide at design time which model each step uses. Extraction always goes to the small model, the coverage note always goes to the frontier model.
  2. Dynamic routing by difficulty. A classifier looks at the input and picks the tier. A two-page typed estimate goes small. A 60-page handwritten file goes large.
  3. Escalation on failure. The small model tries first. If its output fails the schema, fails a cross-check, or disagrees with a second small-model pass, the step is re-run on the larger model or sent to a person.

Start with static routing plus escalation. Use the escalation rate as a metric: if 30% of extractions escalate, the small model is not ready for that document type.

Before you move a step to a smaller model, replay it on closed cases. See how to evaluate agents on your own closed cases.

What does the math look like on a real workflow?

This example is fictional. The prices are round numbers chosen for easy arithmetic, not any vendor's price list.

A lender prepares a commercial credit memo with an agent. One case takes 40 model calls. Illustrative prices: the frontier model costs $10 per million input tokens and $50 per million output tokens. The small model costs $0.50 and $2.50.

Setup A: every call on the frontier model. Each call averages 12,000 input tokens and 600 output tokens.

  • Input: 40 × 12,000 = 480,000 tokens, which costs $4.80
  • Output: 40 × 600 = 24,000 tokens, which costs $1.20
  • Cost per attempt: $6.00
  • 80% of attempts finish correctly, so cost per completed task is $6.00 ÷ 0.80 = $7.50

Setup B: same workflow, routed. Of the 40 steps, 18 are lookups, calculations, rule checks and system writes, and now run as code. 16 are classification and extraction steps on the small model, with trimmed context. 6 judgment steps stay on the frontier model.

TierCallsInput tokens eachOutput tokens eachCost
Code1800$0.00
Small model164,000300$0.032 + $0.012 = $0.044
Frontier model610,000800$0.60 + $0.24 = $0.84
Total per attempt40$0.884

Coded steps do not fail at random, so the completion rate rises to 92%. Cost per completed task is $0.884 ÷ 0.92 = $0.96, about 0.13 times Setup A.

The small model's line is 4 cents. The primary savings came from removing 18 model calls entirely and trimming the context carried by each remaining call. Putting a cheaper model on the six judgment steps would save little and risk the memo.

Does self-hosting a small model change the math?

Self-hosting changes the math because costs shift from per-token to per-hour. A GPU server costs the same whether it handles 60 calls an hour or 600.

Illustrative numbers again: a server that costs $4.00 an hour and handles 600 small-model calls an hour costs $4.00 ÷ 600 = $0.0067 per call. The same server at 60 calls an hour costs $0.067 per call, ten times more. Utilisation decides whether self-hosting is cheaper than an API.

Self-hosting also adds staff, an eval set to re-run on every model change, and spare capacity for peaks. See the air-gapped deployment guide.

Where it goes wrong

  • Counting cost per call, not per completed task. A cheap model completing 60% of cases costs more once you include rework.
  • Putting the small model on a judgment step. The saving is cents. The cost is an expert rebuilding the file.
  • Changing the model without re-running the evals. A new model version is a change to the workflow. Test it like one.

How Context Labs fits in

Context Labs (thecontextlabs.com) is an AI workforce platform for insurance, banking and private equity. It pairs AI judgment with deterministic execution: validated steps become fixed code, and AI is kept for judgment calls. In Context Labs' internal benchmark, cost per completed task fell to 0.06× of a frontier API baseline (1.00×) as smaller 32B and 8B models took on workflows they could reliably handle, and steps per task fell 61%.

FAQ

Are small language models accurate enough for regulated work?

For narrow steps with checkable outputs, often yes. Classification into fixed labels and extraction against a schema are the usual candidates. Accuracy is a property of the model on your documents, not of the model in general, so measure it per step on your own closed cases before you route live work to it.

How much cheaper is a small model than a frontier model?

It depends on the provider and the date, and the gap is large. On Anthropic's public price list on 2026-12-01, the smallest model's input price was 80 times lower than the top model's. Per-token price is only one term, though. Step count, context size and completion rate often move the total more.

What is model routing in an AI agent?

Routing means deciding which model handles each step. Static routing fixes the choice per step at design time. Dynamic routing picks a tier from the input's difficulty. Escalation starts small and moves up when a check fails. Static routing plus escalation is the easiest combination to audit.

Should we fine-tune a small model or just prompt it?

Start by prompting it with a tight schema and good examples, and measure. Fine-tuning can raise accuracy on a narrow task, but it adds a training pipeline, a new artefact to version and validate, and a retraining job each time the task changes.

Does a cheaper model mean lower quality for the customer?

Not if routing is done by evidence. The customer-facing outcome depends on the judgment steps and the approval gates, which stay on the stronger model and with your people. What moves to small models and code is the routine reading, checking and calculating, where a validator can confirm the answer.

Sources

Book a demo

Frontier Intelligence in your hands.

Book a demo