Skip to content
Blog8 min read

Multi-model routing: the cheapest AI optimization nobody ships

Most products send every request to one frontier model. Routing by capability class typically cuts LLM spend 30–60% with no quality loss. Here's the architecture.

AILLMcost optimizationarchitecture

Look at your LLM traffic honestly and a pattern appears: a large share of requests are classification, extraction, reformatting, or short contextual answers — tasks where a model a tenth the price performs indistinguishably from a frontier model. Sending everything to the flagship is paying reasoning prices for regex work.

Capability classes, not model names

The unlock is refusing to write model names in application code. Code declares intent — 'extract fields from this document', 'long-context synthesis', 'low-latency chat' — and a routing layer owns the mapping from intent to model. That mapping becomes config: reviewable, testable, and changeable in minutes when pricing or model quality shifts.

  • Route by cost ceiling and latency budget per class, with live provider health in the loop
  • Failover replays the request against the next candidate — a provider outage becomes a log line, not an incident
  • Per-feature cost attribution turns 'the AI bill went up' into 'this specific feature's cost went up 3×'
  • Evals per class catch quality drift when a cheaper model gets promoted

Why the routing layer should be yours

A hosted router sees every prompt your product sends — your internals, your customers' data — and its pricing sits between you and every model call, a margin that scales with your success. Self-hosting the router keeps the traffic in your network and turns usage data into your asset: a queryable record of what quality costs, per feature, per model, over time.

Vyom is our implementation of this argument: OpenRouter-compatible API, self-hosted, flat-priced by volume tier, with the models billing you directly. The routing intelligence is the product; the tokens are none of our business.

Have the problem this post describes? The AI Architect will match it to a product or practice — with a price.

Run the AI Architect