Routing guide
SearchRouter ranks eligible providers, then executes them in score order with timeouts, fallbacks, and a short-window circuit breaker.
Scoring
Cost and latency are inverted (cheaper / faster scores higher). Freshness, reliability, and quality are used as 0–1 signals from the catalog. The composite score is a weighted sum. A sort override collapses the profile to a single objective (price, latency, throughput, or quality).
Engines
Auto
autoBalanced routing across cost, latency, freshness, reliability, and result quality.
cost 0.22 · latency 0.2 · freshness 0.18 · reliability 0.2 · quality 0.2
Cheap
cheapMinimize credit spend. Prefers low-cost indexes and only falls back when they fail.
cost 0.55 · latency 0.1 · freshness 0.1 · reliability 0.15 · quality 0.1
Fresh
freshPrioritize recency. Routes toward live web indexes over archival or cached corpora.
cost 0.1 · latency 0.15 · freshness 0.5 · reliability 0.1 · quality 0.15
Fast
fastMinimize p50 latency. Favors providers with high throughput and short typical response times.
cost 0.08 · latency 0.5 · freshness 0.1 · reliability 0.2 · quality 0.12
Reliable
reliableMaximize success rate. Prefers providers with strong uptime and conservative circuit behavior.
cost 0.08 · latency 0.12 · freshness 0.1 · reliability 0.5 · quality 0.2
Fallbacks
allow_fallbacks defaults to true. When a provider errors or exceeds timeout_ms, the next candidate runs. Three failures in 30 seconds open a 15-second circuit for that provider. Set providers.only / providers.ignore to pin or exclude adapters.