AI GLOSSARY · AGENTS AND AGENT TOOLING

Model router (LLM routing)

Markdown version

Definition

A model router is a component that receives each request to a language model and decides which model should answer it, usually trading answer quality against cost or speed. The caller sends one request and the router picks the model.

Also called: LLM router, model routing, LLM routing, AI model router, router model.

In plain language

A model router is a dispatcher in front of several AI models. Some questions are easy and a small, cheap model can answer them. Others need a larger, more expensive one. The router looks at each request and sends it to a suitable model, so you do not pay for the biggest model every time. The risk is a wrong choice: a request sent to a model that is too weak may get a poorer answer, and the router itself adds a step, which can add cost. Teams usually test a router on their own prompts before relying on it.

Technical definition

Routers choose among models per request at inference time. The RouteLLM paper (arXiv 2406.18665) trains router models on human preference data to pick between a stronger, costlier model and a weaker, cheaper one. Microsoft's Foundry model router documentation, dated 2026-11-18, describes a trained routing model that judges how demanding a request is, with Balanced, Quality and Cost modes, and a response field naming the model that answered. OpenRouter's Auto Router page says each request is billed at the price of the model it is routed to; it does not describe how the choice is made.

Worked examples in this catalogue

Catalogue examples point at a skill, guide or coding tool listed on this site, with what to run and what you see. An example marked illustrative describes the item from its own documentation; it was not executed for this page. Platform Scores are our assessment under a published method, not a safety guarantee.

  1. Skill by Skill Almanac · Illustrative, not executed

    llm-cost-estimator 56/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    Turns a usage profile and your own price table into a monthly LLM cost range with cache, batch and subscription effects.
    Why it exercises the concept
    Routing is mostly a cost decision. An estimate shows how much of your spend a cheaper-model path could affect, using your own prices.
  2. Skill by Skill Almanac · Illustrative, not executed

    agent-session-cost-review 58/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    Finds where a coding-agent session spent its tokens, by parsing the saved session transcript.
    Why it exercises the concept
    Before routing steps to different models, you need to know which steps consume the tokens.
  3. Guide · Illustrative, not executed

    Claude Code Pricing: What Drives Cost and Plan Options

    What you see
    An explanation of how Claude Code is priced and what drives usage.
    Why it exercises the concept
    It shows why choosing a model per task matters in a coding tool.
  4. Coding tool · Illustrative, not executed

    Claude Code

    What to try
    /model
    What you see
    Claude Code switches the model used for the session, by hand.
    Why it exercises the concept
    Switching models yourself is manual routing. A model router automates the same decision per request.

How it shows up when you use agents

An agent loop makes many model calls: a quick classification, a file edit, a plan, a hard refactor. Without routing, all of them go to one model. With routing, a cheaper model can take the easy steps and a stronger one the hard steps. Microsoft's documentation describes this use for agents and coding tools, and says each step can get a different model.

You may meet a router as a model name you call, as a gateway in front of several providers, or as a manual habit: in Claude Code the /model command switches the model by hand. The inference cost of a session depends on which model handles which step, and AI pricing models differ by provider.

What breaks when routing is misunderstood:

  • A router is a learned or rule-based guess. A hard request can be judged easy.
  • Different models behave differently, so tool calls and output style can change between steps of one task.
  • The router can add its own fee or latency. The Microsoft page lists a separate routing fee; check the vendor's pricing page.
  • A router limits the models you can pick. The same page notes the effective context window is the smallest among the pool.

Next action: run a sample of your real prompts through the router and through your current model, and compare quality and cost before moving production traffic.

Common confusions

  • Model router versus mixture of experts. A router in the sense used here picks between separate models. A mixture-of-experts model routes tokens inside one model. See Mixture of experts.
  • Model router versus LLM gateway. A gateway is a proxy handling keys, logging and limits. It may include routing, but it need not.
  • Router versus fallback. Failover tries another model after an error. Routing chooses before the call. Some products do both.
  • Myth: routing saves money automatically. Savings depend on your traffic and prices. The RouteLLM abstract reports cost cuts on benchmarks, not on your workload.

More in Agents and agent tooling

Next steps

  1. Claude Code Pricing: What Drives Cost and Plan Options The long-form guide.
  2. llm-cost-estimator A skill that exercises it.
  3. Inference Related term.
  4. Inference cost Related term.
  5. All glossary terms A to Z and by family.

Sources

Definitions are written by Skill Almanac from these sources and were checked against them on 2026-11-24. Wikipedia is never the only source.

Review record

Last verified

Drafted by claude-sonnet-5-5; sources and example targets checked by claude-haiku-5-5 source check; claude-sonnet-5-5 editor pass on 2026-11-24. Last verified .

This entry is still in review, so it is not listed in search engines yet.

Change log (2)
  • : First version.
  • : Verifier pass: replaced unsupported Auto Router claim.