Model Router
You have a $0.001 model and a frontier model. Which requests should each one get? Drop in an eval log, set the quality you need, and get the cheapest routing plan that still meets it, with a statistical guarantee. Everything runs in your browser; nothing is uploaded.
Your eval log
One row per prompt (or per prompt and model): was each model right, and what did it cost.
or .
The file stays in your browser. Prompts and answers are never sent anywhere.
CSV format (two layouts are accepted)
Wide: one row per prompt
prompt_id,prompt,tiny_correct,tiny_cost,tiny_latency,tiny_confidence,frontier_correct,frontier_cost,frontier_latency,frontier_confidence q1,What is 17 times 23?,1,0.00004,310,0.91,1,0.0121,2400,0.98 q2,Summarize this contract clause: ...,0,0.00009,620,0.77,1,0.0263,4100,0.93
Long: one row per prompt and model
prompt_id,model,correct,cost,latency,confidence,prompt q1,tiny,1,0.00004,310,0.91,What is 17 times 23? q1,frontier,1,0.0121,2400,0.98,What is 17 times 23?
- correct
- required. 1 if the model's answer was right, 0 if not (true/false and yes/no work too), or a score between 0 and 1. In the wide layout the column is
<model>_correct;scoreis also accepted. - cost
- required. What that call cost, in any unit you like: dollars, cents or tokens. The report uses the same unit, per 1,000 prompts.
- confidence
- optional, 0 to 1. The model's own estimate that it was right (logprob of the answer, a self-rating, a verifier score). This is what a cascade gates on. Without it, a router is learned from the prompt text instead.
- prompt
- optional. The prompt text, used to learn a router that picks a model before any call is made.
- latency
- optional, any unit. Reported, not optimised.
- prompt_id
- optional in the wide layout, needed in the long one to group a prompt's rows. Prompts without a row for every model are dropped.
Models are ordered by their average cost. Delimiters (comma, semicolon, tab) and quoted fields are detected. Column names are case-insensitive; cost_usd, price, tokens, is_correct, p_correct, question and similar names are recognised.
The plan
Thresholds are tuned on one half of the prompts and the guarantee is measured on the other half, which the tuning never saw.
More settings
| policy | quality | lower bound | cost / 1k | cost bound | latency | traffic per model |
|---|
How to deploy it
Cost against quality
Each single model is a point. The cascade and the router trace a curve as the target moves; the oracle is the floor nobody can beat.
What each model ends up handling
Share of held-out prompts answered by each model, and (for the cascade) the share that reaches each model at all.
The price of each extra point of quality
Held-out cost of the plan tuned for each target. Filled markers are certified at that target; hollow ones fell short of the bound.
Same run as the command-line tool
How it's built, results and limits: How it works →