RouteLLM: Learning to Route LLMs with Preference Data (arXiv, June 2024)
- Paper: RouteLLM: Learning to Route LLMs with Preference Data
- Link: https://arxiv.org/abs/2406.18665
- Authors: Isaac Ong, Amjad Almahairi, Vincent Wu, Wei-Lin Chiang, Tianhao Wu, Joseph E. Gonzalez, et al. (8 authors total)
- Type: Academic paper (arXiv preprint, June 2024)
- Classic search pipelines (recall → re-ranking → generation) are being reshaped by LLMs, where new variables are inference budget and action space (whether to retrieve, how many times, which tools to call).
- Routing, like cascaded retrieval and early stopping, is a mechanism for allocating compute per query rather than uniformly.
- A unified framework for routing between model tiers, learned from preference signals.
- Decomposition of system components (encoders, retrievers, re-rankers, planners, generators, feedback mechanisms) to ease engineering adoption.
- Discussion of interfaces with LLM tool calling, reinforcement learning, and multi-agent collaboration.
- Open problems: evaluation trustworthiness, latency and cost budgets, hallucination and safety, cross-lingual and multimodal extension.
- Specific benchmark numbers are not reproduced in the post; readers should consult the original PDF at https://arxiv.org/abs/2406.18665 before citing quantitative results.
- Related entries cross-referenced by the post include work on knowledge editing for LLMs, LLM-powered search (INTERS), instruction-following recommendation, generative retrieval, and zero-shot document retrieval.
What the paper is about
RouteLLM studies how to route queries between LLMs of different strengths and costs. Instead of sending every request to a single frontier model, a learned router — trained on human preference data — decides at inference time whether a query requires the stronger (more expensive) model or can be served by a weaker (cheaper) one. This targets the efficiency/cost/quality trade-off that dominates production LLM deployments.
Context in the LLM-era search stack
The forum post situates RouteLLM within the broader evolution of information retrieval and LLM systems:
Points highlighted by the post
Engineering checklist reproduced from the post
| Area | Question | Recommendation | |------|----------|----------------| | Data | PII in training/index data? Version control? | Partitioned indexes, anonymization, rollback-able embedding versions | | Latency | p99 budget? Number of retrieval steps? | Cascades + early stopping, caching hot queries, async re-ranking | | Quality | Do offline gains translate to online satisfaction? | Interleaving experiments, human audits, citation verification | | Safety | Does open retrieval introduce poisoning/bias? | Source allow-lists, adversarial detection, output filtering | | Cost | Per-query token/GPU usage? | Small router models, distillation, hybrid sparse+dense retrieval |