Cheap-First vs Quality-First: Choosing a Model Routing Policy
Compare cheap-first escalation, quality-first downgrade, and task-based routing, with failure modes, quality measurement, prompt portability, and when not to ro
Three routing policies and their failure modes
A routing policy is a rule that decides which model handles a given request. There are three common shapes, and each one fails in a different way.
Cheap-first with escalation sends every request to the least expensive model that might work, then retries on a stronger model when a check fails. Its weakness is the check. If you detect failure with a JSON schema validator or a regex, you catch malformed output but miss subtly wrong answers. If you detect failure with another model acting as a judge, you have added latency and a second model that can be wrong. Cheap-first also doubles cost on escalated requests, so the savings depend on the escalation rate, which you must measure rather than assume.
Quality-first with downgrade starts on the strongest model and moves easy requests down. It protects the hardest inputs but needs a reliable signal for what counts as easy. Length, presence of code, or a classifier score are common proxies, and all of them misclassify some inputs. The failure mode is silent: a hard request gets a weaker model and a plausible but shallow answer, and nobody notices because nothing errored.
Task-based routing skips per-request guessing. You define request types (for example, extraction, summarization, code edit, open-ended chat) and assign each type a model tier. It is the easiest policy to audit because the mapping is static and reviewable. Its weakness is rigidity: a task that drifts in difficulty keeps its assigned tier until someone updates the map.
- Cheap-first fails when your failure detector is weak; measure escalation rate and false-negative rate.
- Quality-first fails silently when the downgrade signal misclassifies hard inputs.
- Task-based routing fails slowly when task difficulty changes and the map is not revisited.
What to measure before switching models
Do not switch a production route on the basis of a demo or a single prompt. Build a small evaluation set from real traffic first: sample requests per task type, store the inputs, and write down what a correct answer looks like. For open-ended tasks, use a rubric and human review on a sample rather than an automatic score alone.
Then run the candidate model against that set and compare on three axes: task success rate, format compliance, and refusal or hedging behavior. Format compliance matters because a model that produces correct content in the wrong shape breaks your parser. Hedging matters because a model that answers 'it depends' to a factual question is a regression even if the text is fluent.
Track cost per successful request, not cost per token. A cheaper model that needs retries or human cleanup can cost more overall. Also watch the tail: a model that is fine on average but fails on long inputs or non-English text will surface as a support burden. The official provider docs on production practices and error handling are useful for structuring retries and timeouts around whichever model you pick.
- Sample 50 to 200 real requests per task type and label expected outputs.
- Define pass criteria per task: exact match, schema validity, rubric score, or human sign-off.
- Run the current model and the candidate on the same set and diff the results.
- Record cost per successful request, including retries and escalations.
- Ship behind a flag, compare live metrics for a fixed window, then decide.
Prompt portability across families
If your router can send a request to more than one model family, your prompts must work everywhere. That rules out relying on provider-specific features as load-bearing parts of the prompt: tool-call formats, structured output modes, system-prompt conventions, and special tokens differ between families and sometimes between versions of the same family.
Keep the core instruction in plain text and treat structured output as a validation step rather than an assumption. Ask for JSON in the prompt, then validate and repair. Put examples in a consistent format. Avoid instructions that depend on a specific chat template, such as assuming a particular role name is honored.
Test each family you route to with the same eval set. A prompt tuned for one family often underperforms on another by a margin that erases the cost savings. If a prompt needs family-specific tuning, either accept maintaining variants or restrict that task to one family and route elsewhere only for tasks with portable prompts.
When not to route
A router is code you own and must debug. It adds a classification step, an escalation path, and a second set of prompts to maintain. For low-volume products, or products where a wrong answer is expensive, that complexity is often not worth it.
A single strong model is simpler when your traffic is small enough that cost differences do not matter, when your task is uniformly hard, or when you cannot build a reliable failure detector. In those cases, spend the effort on prompt quality and evaluation instead of routing logic.
Also avoid routing when latency budgets are tight. An escalation path means a slow first attempt followed by a second call, and the worst-case latency is the sum of both. If your product has a hard response-time requirement, a fixed model with predictable latency is easier to defend than a router whose tail latency depends on escalation rate.
How to apply this with Admesh
Admesh gives you one API key and one balance across multiple model families, which makes it practical to run a routing policy without managing separate accounts and billing per provider. Point OpenAI-style clients at https://api.admesh.ai/v1 and Anthropic-style clients at https://api.admesh.ai/v1/messages.
Start by browsing the live model catalog at https://admesh.ai/models and the pricing page at https://admesh.ai/pricing to choose candidate tiers for each task type. Do not hardcode assumptions about cost or capability; check the catalog, since available models change.
Implement task-based routing first, because it is the easiest to audit. Map each task type to a model, log which model served each request, and run your eval set against each mapping. Once that is stable, add cheap-first escalation only for tasks where you have a reliable failure check.
Use the console at https://console.admesh.ai to watch spend per model and catch a route that is escalating more than expected. The docs at https://docs.admesh.ai cover request formats and error handling so your retry and escalation logic behaves consistently across families.
A decision checklist
- Can you detect a bad answer automatically for this task? If not, cheap-first escalation will leak errors.
- Is task difficulty stable? If not, task-based routing needs periodic review.
- Do your prompts avoid provider-specific features? If not, restrict routing to one family.
- Is worst-case latency acceptable with a second call? If not, use a fixed model.
- Is cost per successful request lower after routing, including retries? If not, do not route.
FAQ
Is cheap-first routing always cheaper?
How do I know a downgrade did not hurt quality?
Can I use the same prompt across model families?
When is a single strong model the better choice?
References
Call these models through one gateway
Admesh provides a unified OpenAI-compatible API: one Base URL and one key for Claude, GPT, DeepSeek and more. New accounts get trial credit that never expires.
