Researchers have proposed RouteFM, a new approach that reframes large language model (LLM) routing as a foundation-model problem rather than a task of repeated local fitting. The work, shared as a paper on Hugging Face, asks whether routing can be learned as a reusable capability that generalizes across tasks, candidate models, and deployment conditions.
Conventional routers are typically optimized for a specific query workload and candidate pool, and often need extra supervision or retraining whenever the routing environment changes. RouteFM takes a different path: instead of binding routing decisions to fixed model identities or a single environment, it learns to characterize anonymous candidate models from behavioral context and infer their target-specific capabilities.
The method relies on episodic pretraining across heterogeneous routing environments. Once pretrained, the routing capability can be reused by a frozen router and adapted to new environments through context alone, according to the paper. The authors report transfer across changes in domains, modalities, candidate pools, and context budgets, with the largest gains observed when behavioral evidence is limited.
On MMR-Bench, a benchmark excluded from pretraining, RouteFM is reported to outperform the strongest baseline by 2.23 quality points using only eight observations per candidate. The authors frame these results as support for moving LLM routing from repeated local fitting toward a "pretrain once, route anywhere" paradigm.
The paper states that the code is publicly available at https://github.com/LAMDA-Model-Reuse/RouteFM.