THESIS

Working premise

Dynamic routing changes which model serves a task based on cost, latency, capacity, or complexity. It should be observable as a policy decision, not hidden as an implementation detail.

CONTEXT

Operational context

Dynamic routing is a production policy that decides which model handles a task based on cost, latency, capacity, region, risk, or predicted complexity. The selected route and reason should be observable on the trace so outcomes can be attributed to policy rather than only to the final provider.

Offline evaluation establishes eligibility, but production routing changes the traffic mix. Stable cohorts and segment analysis are required to distinguish model behavior from route selection. Fallbacks, quota events, and provider outages should be measured as policy outcomes, not hidden infrastructure details.

Routing optimization needs guardrails. A lower-cost route may concentrate quality loss in long-tail or multilingual traffic, while a high-quality route may violate latency or regional constraints. Policy changes should be versioned, reviewed, staged, and reversible.

INQUIRY

Questions to resolve first

Q1

Which objectives and constraints determine route eligibility and selection?

Q2

Can every trace show policy version, candidates, selected model, reason, and fallback path?

Q3

Which segments may be disproportionately affected by cost- or capacity-led routing?

Q4

What happens when price, quota, latency, provider availability, or quality changes?

PROTOCOL

Recommended method

  1. P1

    Record routing policy, candidate models, selected model, and reason on the trace.

  2. P2

    Measure outcomes by route, segment, release, and fallback path.

  3. P3

    Run offline comparisons before changing thresholds.

  4. P4

    Use stable cohorts during rollout so routing effects remain interpretable.

FAILURE

Common failure modes

Hidden router

Outcomes are attributed to models without recording why different traffic received each model.

Unqualified fallback

Outage logic sends work to a model that has not passed the relevant evaluation suite.

Aggregate optimization

Portfolio cost improves while a particular language, feature, or customer segment loses quality.

CONTROL

Control points

  • Prevent routing to models that have not passed the relevant eval suite.
  • Define behavior when price, quota, latency, or provider availability changes.
  • Monitor segment-level quality so low-cost routes do not concentrate harm.
  • Preserve manual override and rollback.
DEPLOY

Implementation sequence

  1. S1

    Define route objectives, eligibility rules, constraints, fallback order, and manual override.

  2. S2

    Instrument policy version, candidates, selection reason, route changes, and confirmed outcome.

  3. S3

    Evaluate eligible models offline and use stable production cohorts during policy rollout.

  4. S4

    Review quality, latency, cost, fallback, and segment effects together with explicit rollback thresholds.

MEASURE

Measures worth reviewing

Monitor route share, fallback and override rates, quality and success by route, latency, cost delta, and policy exceptions. Segment analysis is essential because aggregate routing performance can hide concentrated harm.

Route shareFallback rateQuality by routeCost deltaLatency by routePolicy exceptions
SOURCES

Primary references

This note is an editorial synthesis of public standards, primary institutional guidance, and common engineering control patterns. It is intended to support engineering design and review. It is not a substitute for legal, security, safety, audit, or other professional advice for a specific system.