liveBook · Manning

Routing

As explained in Vibe Engineering

Model routing is the selective assignment of requests to different AI models according to task requirements such as complexity, quality, and cost.

Model routing assigns requests to different models according to task demands. Measure quality on your own work—for example, by developer acceptance—and weigh it against cost and latency. Trivial tasks may show little difference between models, while complex tasks can expose large quality gaps. section 9.2.4 section 9.5.4

Route by workflow rather than choosing one model for everything:

  • Use lower-cost, faster models where quality differences are small, such as tab completion or a first-pass review. section 9.2.4 section 9.5.4
  • Reserve stronger models for tasks where the measured quality advantage matters, such as complex debugging or deep review. section 9.2.4 section 9.5.4
  • Treat provider-managed routing as a convenience, not a dependency; keep a fallback selection strategy. section 9.5.4

Two-pass CI review

A first pass with Haiku caught about 60% of review comments at one-tenth the cost; a Sonnet deep pass reduced monthly review costs from $1,400 to $620. But files cleared by Haiku could contain issues that never reach Sonnet. Sample some cleared files for full review and log disagreements before trusting the savings. section 9.2.4

Table 9.1 Change of costs between models
Task Type
Sonnet
Haiku
GPT-4.1-mini
 
Model to be selected
Tab completion
94%
93%
92%
Any (≈)
Import statements
97%
96%
96%
Any (≈)
Boilerplate generation
91%
88%
87%
Any (≈)
Unit test scaffolding
89%
82%
80%
Sonnet*
Inline refactoring
90%
83%
81%
Sonnet*
Function implementation
88%
74%
72%
Sonnet
Complex debugging
85%
61%
58%
Sonnet
Multi-file refactoring
82%
52%
49%
Sonnet
Architecture planning
79%
41%
38%
Sonnet

Compare reported model acceptance by task type; the results are specific to one team's codebase and workflow. section 9.2.4

Table 9.7 Matching model to the usecase
Technique
Properties
Model
Interactive pair-programming
Latency + Quality
Sonnet, agent mode
Tab completion
Cost + Latency
Haiku or local model
Background refactoring
Cost + Quality
Sonnet, async/batch
CI review (first pass)
Cost + Latency
Haiku, immediate
CI review (deep pass)
Cost + Quality
Sonnet, batch API
Test generation
Cost + Quality
Sonnet, overnight
Documentation
Cost + Latency
Haiku, on-demand

See example model and tradeoff choices across seven development workflows. section 9.5.4

How Vibe Engineering covers it

How deep it goes
Measures task-level acceptance and CI savings, then flags routing false negatives; it does not claim two-pass review catches every issue.
Examples
Compares model tiers across coding tasks and uses a two-pass CI review with sampled checks for missed issues.
What it assumes
Assumes access to real workflow tasks and a way to assess output quality, such as developer acceptance.
What you can do after
Configure model choices per workflow and sample filtered requests to check for routing misses.
How it connects
Connects model selection with CI review and latency-cost-quality tradeoffs.

Also explained in

Compare how 34 books explain routing →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Vibe Engineering. The section links point to the parts of the book it draws on.