Training Small Language Models for Transferable Tool Selection

Zhaoyi Zhou, Ayush Jain and colleagues at Meta (with Andrea Zanette, CMU) train small open models with SFT and RL to plan, retrieve and select tools from catalogs of more than ten thousand tools, a role usually given to proprietary LLMs.
Ask this paper
Workflow. Plan-Retrieve-Select: the model decomposes an instruction into substeps, a retriever returns candidates for each, and the model commits one tool per substep.
Training. SFT on 20,093 teacher-curated ToolBench instructions, then RL with a rank-graded recall and precision reward that pushes each substep toward a unique gold tool.
Result. On ToolBench G3, SFT lifts success above 30% at every scale (1.7B to 8B) and RL raises the 8B model from 36.2% to 41.5%, above prompted Llama-4-Maverick (402B).
Transfer. The trained selector works with different retrievers and generalizes to new tool corpora in other domains without retraining.
Abstract
As LLM agents operate over corpora of more than ten thousand tools, selecting the right tool for a complex multi-step user instruction becomes a central bottleneck. Tool descriptions cannot all fit in context, and relevance-based retrievers only rank tools without knowing which are actually needed. Recent work instead leverages proprietary commercial LLMs like Claude or ChatGPT to drive a retriever, decomposing the instruction and selecting over retrieved candidates. We show that a small, open model can be trained via reinforcement learning to perform the same functionality. On ToolBench, a Qwen3-8B model post-trained with our recipe outperforms Llama-4-Maverick (402B). In addition, the trained model transfers directly to different retrievers and generalizes to new tool corpora in different domains.