TL;DR — An LLM router is a decision policy that only sees the outcome of the model it picked, which makes it a contextual bandit, not a classifier. Logs from a deterministic router are censored, and retraining on them reinforces the router's own past mistakes. Fix it by logging propensities, paying for a small exploration slice, and evaluating new routers off-policy before they ship.
Most teams build an LLM router the same way. Collect prompts, label which ones a cheap model handles fine, train a small classifier, ship it. The offline numbers look great. Three months later cost is flat, quality complaints are creeping up, and nobody can say why.
The problem is the framing. A router is not a classifier. It is a policy: it takes an action (pick a model), and it observes the consequence of only that action. That is a contextual bandit. Once you see it that way, most routing pathologies stop being mysterious.
You only see the road you took
Suppose your router sends a prompt to the small model. You get the small model's answer, maybe a judge score, maybe a thumbs-up or a retry. You do not learn what the large model would have said. The counterfactual is missing, and it is missing systematically, not randomly.
Now retrain the router on those logs. Every prompt type the router already sends to the small model produces data about the small model only. Every prompt type it sends to the large model produces data about the large model only. The router learns from a dataset shaped by its own previous behavior. If it was wrong about a category, it has almost no evidence to discover that, because the evidence lives on the road it never took.
This is the classic selection-bias loop. The router becomes confident in proportion to how little it has explored.
Three architectures, three kinds of blindness
The patterns differ in what they let you observe, and that matters more than their cost curves.
Router: one arm observed per request. Maximum censoring. Cheapest per request, hardest to learn from.
Cascade: you observe a prefix of the chain. When a request escalates, you see both the cheap answer and the strong answer. But escalation is triggered by the cheap model's own uncertainty signal, so the paired data covers only the cases the cheap model knew it was unsure about. The dangerous region, where the cheap model is confidently wrong, never produces a pair.
System-level mixture: several models answer, and something aggregates or selects. You observe every arm. No censoring, but you pay for every arm on every request.
Put differently: a mixture buys information with compute, a router saves compute by giving up information, and a cascade sits in between with a biased sample. The cascade's confidence signal is the part people forget. It is itself a router, and it is censored in the same way.
What a learnable router logs
If you want a router that can improve, the logging schema is the architecture. A few non-negotiables:
Log the propensity. Record the probability with which the router chose the action it took, not just the action. A deterministic argmax router has propensity one for everything it does and zero for everything else, which is exactly why you cannot learn from it. Sampling from the router's scores, even with a sharp temperature, makes the logs usable later.
Log the router version and features. The policy that generated the data must be reconstructable. Otherwise you cannot correct for it.
Log the reward inputs, not only the reward. Store the judge's raw output, the user signal, latency, and token counts separately. Your definition of reward will change. Your logs should not need to.
Keep an exploration slice. A small, fixed fraction of traffic gets routed independently of the router's opinion, or gets shadow-evaluated by the strong model with the result discarded from the user path. This is the only way to see the roads not taken.
The exploration slice is a line item. Call it a calibration budget and defend it the way you defend an eval budget. If finance asks why you are spending strong-model tokens on traffic the router says is easy, the answer is: because otherwise the router's accuracy claims are unfalsifiable.
Evaluate new routers off-policy
Once you have propensities, you can ask a question that offline accuracy cannot answer: how would a different router have performed on the traffic we actually saw?
The standard tool is inverse propensity weighting. In words: when the old policy happened to pick the same action the new policy would pick, count that outcome, but weight it up by how unlikely the old policy was to pick it. Rare choices carry more information because they are the ones the old policy under-sampled. Doubly robust variants combine this with a learned reward model to cut variance.
Caveats worth stating plainly:
Variance explodes when the new policy wants actions the old one almost never took. That is not a bug in the estimator. It is the estimator telling you the logs cannot support the claim.
The reward is usually a judge or a proxy, and it has its own noise and bias. Off-policy evaluation inherits all of it. Keep a human-audited slice to anchor the judge.
Exploration must be stratified. A uniform random slice will starve rare, high-stakes categories. Sample by cluster or intent so the tails get coverage.
The reward is a policy decision, not a metric
Every router optimizes something like quality minus a weighted cost. That weight is a business decision wearing a hyperparameter's clothes. Pick it implicitly, by tuning a threshold until the bill looks right, and you have encoded a quality-for-cost exchange rate nobody agreed to.
Write it down. Make the exchange rate explicit per route, because a customer-facing legal summary and an internal log classifier should not share one. Then the router's behavior becomes auditable: you can change the rate and predict, from logged data, what traffic moves.
There is also non-stationarity. The arms change underneath you. A provider updates a model, you swap a checkpoint, a prompt template shifts. The reward distribution of each arm moves, and a router trained on stale logs is optimizing a world that no longer exists. Exploration is not a one-time setup cost. It is the mechanism that keeps the router's beliefs current.
The practical stance
A deterministic router with no exploration is a snapshot of your beliefs on the day you trained it, frozen and slowly decaying. It will look excellent on the dashboard it controls, because the dashboard only contains outcomes it chose.
If you take one thing from the bandit view, take this: design the logging before the model. Sample, don't argmax. Record propensities. Reserve a slice for the roads not taken. Evaluate off-policy before promoting a new router. The classifier on top can be as simple as logistic regression over embeddings. The learning loop around it is the part that decides whether the system gets better or merely gets confident.