LLM Capability Density: How Tiered Model Routing Cuts Inference Costs in Half
This article explains why per-token pricing can be misleading for reasoning models and introduces capability density as a better basis for model selection. It breaks down single-task cost into token price and token consumption, then presents a four-layer approach to reducing inference costs: classifying tasks by type and complexity, adding difficulty-based routing with automatic escalation, optimizing prompts and output length, and building measurement systems that track quality and cost. The article also covers practical implementation steps, common pitfalls, and how to use tier-effectiveness curves to find the right reasoning effort level for each task.
The Cost Math Behind LLM Capability Density: How Tiered Routing Cuts Inference Costs
▎A set of numbers that makes model selection harder
A batch of third-party benchmark data has been circulating widely among developers. One new flagship model now scores close to the previous generation’s flagship running at maximum effort on medium-complexity reasoning tasks, while costing roughly half as much per task. But push the new model to its highest effort level, and the per-task cost jumps to more than twice that of the older flagship.
These numbers are striking because they contradict two common assumptions at once. The first is that “newer models are automatically more cost-effective.” The second is that “flagship models are always more expensive.” The reality is more nuanced: the new generation is genuinely stronger at the same effort level, but that strength comes from efficiency rather than raw capability. The reasoning effort level, a dial that’s easy to overlook, has a much bigger impact on the bill than the per-token price alone.
For engineering teams, this means model selection can’t be based on a price sheet alone. A more useful framing is capability density: for the tasks you actually run, which model and which effort level achieves acceptable quality at the lowest cost?
▎Decomposing single-task cost: why unit price misleads
Let’s look at cost structure. The cost of a single call can be approximated as the product of two factors:
Cost per task ≈ Token price × Tokens consumed per task
Most industry discussions focus only on the first factor, the price per million tokens. But with reasoning models, the second factor is where developers actually have control. Reasoning models generate an internal thinking process before producing an answer, and those thinking tokens are billed too. Higher effort levels mean the model “thinks” longer, generating more tokens and driving up total consumption.
Here’s a simplified example to show the scale of the difference. Suppose two models each consume 2,000 output tokens for the same set of tasks:
# Model A: $8 per million tokens (blended input/output), 30,000 total tokens (thinking + output)0.008 × 30 ≈ $0.24 per task# Model B: $15 per million tokens, 5,000 total tokens (thinking + output)0.015 × 5 ≈ $0.075 per task
Model B costs nearly twice as much per token, yet the actual bill is only one-third of Model A’s. The reason is straightforward: thinking tokens have no fixed ceiling, while output tokens do. If you only compare “how much per million tokens,” you’re implicitly assuming all models consume the same number of tokens, and that assumption no longer holds.
This also explains the paradox from earlier. At medium effort, the new flagship model wins on both factors: shorter thinking and lower unit price. But at maximum effort, the second factor explodes, completely erasing the advantage of the first factor and potentially reversing it.
So the metric that actually matters isn’t unit price. It’s the cost of completing a specific type of task at a given effort level. This metric varies by task type and can’t be computed once and for all. Each team needs to sample and measure it for their own workloads.
▎Layer 1: Classifying tasks by type and complexity
Once you have the right cost perspective, the first step is to classify tasks. One of the most common mistakes developers make is applying the same model and same parameters to every scenario, which amounts to using a sledgehammer to crack a nut. A sensible classification covers at least four categories:
| Task Type | Characteristics | Recommended Strategy |
|---|---|---|
| Low-risk, high-frequency | Text classification, extraction, format conversion | Small-parameter model, fixed short template |
| Medium complexity | Summarization, multi-turn Q&A, standard rewriting | Mid-tier model, standard template |
| High-difficulty generation | Long-form writing, solution design, complex reasoning | Flagship model, medium-to-high effort |
| Extremely difficult | Cross-document analysis, hard diagnosis | Flagship model, maximum effort |
The key to classification isn’t guesswork. Build a task profile: measure average input length, output length, frequency, and manual rework rate for each category. High-frequency tasks with high tolerance for error naturally belong in lower tiers. Low-frequency tasks where mistakes are costly are worth the highest tier.
At the code level, classification can be expressed as a routing table:
class TaskProfile:def __init__(self, name, model_tier, effort, max_tokens, retry_budget):self.name = nameself.model_tier = model_tier # 'small' | 'mid' | 'flagship'self.effort = effort # reasoning effortself.max_tokens = max_tokensself.retry_budget = retry_budget # allowed escalation retriesROUTES = [TaskProfile('intent_classify', 'small', 'low', 512, 0),TaskProfile('summarize', 'mid', 'medium', 2048, 1),TaskProfile('solution_design', 'flagship', 'high', 8192, 1),TaskProfile('deep_analysis', 'flagship', 'max', 16384, 2),]
The retry_budget field deserves attention. Automatically escalating and retrying after a lower-tier failure is cheaper than starting at the highest tier, because the vast majority of tasks never reach the retry path.
▎Layer 2: Difficulty routing and adaptive escalation
Task profiles answer “which tier for which type of task,” but difficulty varies even within a single category. A two-page document summary and an eighty-page technical proposal summary shouldn’t go through the same effort level, or the former will waste resources. This calls for a second mechanism: assessing difficulty before or during the call and dynamically adjusting the tier.
There are several common approaches to difficulty assessment, ordered from lowest to highest cost:
- Rule-based features: Input length, number of paragraphs, presence of tables or code blocks, whether it’s a multi-turn follow-up. These features are simple, essentially zero-cost, and can filter out a meaningful portion of obviously simple or obviously complex samples.
- Lightweight classifier: Run a small model first to output a confidence score or self-assessed difficulty. Suitable for scenarios where rules fall short, at the cost of an extra call.
- Execution-feedback-driven: After the first call, check result quality (valid format, required fields present, consistency checks passed) and escalate the tier if it fails. This is the most expensive but also the most precise approach. Use it only as a fallback.
A practical combination is “rules first, feedback as backstop”: use rules to route obviously simple samples to the small model, then validate the first result structurally. Only samples that fail validation or have low confidence get escalated. In code:
def call_with_escalation(profile, prompt, inputs):"""Escalate tier by tier until quality check passes or retry budget is exhausted"""ladder = ['small', 'mid', 'flagship']start = ladder.index(profile.model_tier)for attempt in range(profile.retry_budget + 1):tier = ladder[min(start + attempt, len(ladder) - 1)]resp = client.chat(model=MODEL_ALIAS[tier],reasoning_effort=profile.effort,messages=[{"role": "user", "content": prompt.format(**inputs)}],max_tokens=profile.max_tokens,)if validate(resp, inputs):return resplog_escalation(profile.name, tier, attempt)# Fallback: route to human review or degrade to a conservative templatereturn fallback_handler(prompt, inputs)
A few design points in this code are easy to overlook. First, validate should be as automated as possible, otherwise the escalation logic itself becomes a manual burden. Second, every escalation should be logged, because the escalation rate is the most valuable cost signal. Third, a fallback path must exist to avoid outright failure when the budget is exhausted.
▎Layer 3: Adaptive prompt and parameter engineering
Beyond switching models, there’s substantial room to compress costs within the same tier, mainly from prompt length and output length.
On the prompt side, redundant rule explanations, repeated background context, and overly long examples all consume tokens and crowd out the model’s attention. A practical approach is to split long prompts into a “stable prefix + variable part”: route the stable prefix through caching, and keep the variable part as concise as possible. Periodically measure the token share of different content types in your prompts, and remove fragments that haven’t been referenced in a long time.
On the output side, use max_tokens as a hard constraint, and structure prompts with “conclusions first, then elaboration” so the model puts key information up front. This way, even if the output gets truncated, the essential content survives. For structured scenarios, enforcing a JSON Schema can significantly reduce the rework rate, and rework itself is a hidden cost.
One frequently underestimated optimization point is the non-linear nature of reasoning effort levels. Going from low to medium effort often yields limited capability gains. Going from low to high produces a clear jump in capability but multiplies token consumption. Going from high to maximum typically shows diminishing returns. Teams should build their own “effort-effectiveness curve”: pick a representative set of tasks, run each at multiple effort levels N times, and record pass rates and average cost to find the inflection point. This curve is a team asset, far more useful for decision-making than any benchmark leaderboard.
▎Layer 4: Quality measurement and cost accounting
Tiered routing isn’t a one-time project. It’s a system that needs continuous feedback. Without measurement, you can’t tell whether cost reduction came at the expense of quality.
Build three reports:
- Task–tier matrix: Pass rate and average cost per task for each effort level
- Escalation rate report: Frequency of each routing rule and fallback rate, to identify over- or under-engineering
- Quality regression table: After every model or prompt change, run a fixed evaluation set and compare accuracy, rework rate, and cost
Two measurement traps to watch for. First, don’t use offline benchmark scores as a substitute for production metrics. Benchmarks measure average capability, while production cares about pass rates on a specific distribution. Second, don’t look only at average cost. Long-tail tasks often account for a disproportionate share of spending, so track both P50 and P95.
On the cost control side, several engineering techniques can be layered on top: cache results for repeated requests, batch process tasks that can be combined, switch to batch APIs for non-real-time scenarios, and consider small-parameter models or even traditional solutions as a fallback for high-frequency, low-risk tasks. These techniques are orthogonal to tiered routing and can be used together.
▎Implementation roadmap and common pitfalls
In practice, tiered routing typically unfolds in three steps.
Step 1: Start with just “task classification + fixed tiering” to break out of the one-model-for-everything situation. This step requires minimal investment and delivers the most immediate returns.
Step 2: Add “difficulty routing + automatic escalation and retry” to refine tiering from the category level down to the sample level.
Step 3: Build measurement and regression systems to turn tiering strategy into a sustainable, evolving mechanism rather than a one-time configuration.
A few typical pitfalls to avoid: First, pursuing “full automation” before the evaluation set exists, handing decision-making authority to rules you can’t yet validate. Second, changing too many dimensions at once (model, effort level, template, temperature), making it impossible to isolate the source of quality fluctuations. Third, neglecting the fallback path, causing outright failures when the retry budget runs out, turning a cost problem into a reliability problem.
To return to the numbers at the beginning: the new model is indeed stronger at the same tier and cheaper per token, creating real room for cost reduction. But the fact that its maximum tier still costs more than the old flagship’s is a reminder that improvements in capability density don’t automatically translate into lower bills. What actually drives costs down isn’t a single procurement decision, but treating model calls as an engineering system that can be measured, routed, and iterated. Once tiering, routing, adaptivity, and measurement are in place, the cost curve will keep declining as models evolve, rather than resetting to zero with every new generation.
