mlsanityData to 14 Oct 2026

Distilling LLM Agent into Small Models with Retrieval and Code Tools

arXiv 2505.17612 ↗First posted 23 May 2025cs.CL cs.AIcited by 47

On the map: LLM reasoning → Reasoning for agents, planning and code

also in 2 more
Abstract (arXiv)

Large language models (LLMs) excel at complex reasoning tasks but remain computationally expensive, limiting their practical deployment. To address this, recent works have focused on distilling reasoning capabilities into smaller language models (sLMs) using chain-of-thought (CoT) traces from teacher LLMs. However, this approach struggles in scenarios requiring rare factual knowledge or precise computation, where sLMs often hallucinate due to limited capability. In this work, we propose Agent Distillation, a framework for transferring not only reasoning capability but full task-solving behavior from LLM-based agents into sLMs with retrieval and code tools. We improve agent distillation along two complementary axes: (1) we introduce a prompting method called first-thought prefix to enhance the quality of teacher-generated trajectories; and (2) we propose a self-consistent action generation for improving test-time robustness of small agents. We evaluate our method on eight reasoning tasks across factual and mathematical domains, covering both in-domain and out-of-domain generalization. Our results show that sLMs as small as 0.5B, 1.5B, 3B parameters can achieve performance competitive with next-tier larger 1.5B, 3B, 7B models fine-tuned using CoT distillation, demonstrating the potential of agent distillation for building practical, tool-using small agents. Our code is available at https://github.com/Nardien/agent-distillation.

Key facts. Cited by 47 papers in the map (data through 14 Oct 2026). Placed in Reasoning for agents, planning and code, one of 17 directions in LLM reasoning. Builds on 74 of its 85 references that are in the map. First posted on arXiv 23 May 2025.

Builds on

74 of 85 references.

Closest ancestors · 3

Same direction, newest first

  1. 2025Agentic Reasoning and Tool Integration for LLMs via Reinforcement Learning28 Apr
  2. 2024Qwen2.5-Coder Technical Report18 Sep
  3. 2024Enhancing the General Agent Capabilities of Low-Parameter LLMs through Tuning and Multi-Branch Reasoning29 Mar

Other references · 71

  1. 2023GPT-4 Technical Reportcited by 18,396
  2. 2024The Llama 3 Herd of Modelscited by 14,715
  3. 2021LoRA: Low-Rank Adaptation of Large Language Modelscited by 14,380
  4. 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,459
  5. 2015Distilling the Knowledge in a Neural Networkcited by 10,324
  6. 2024DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Modelscited by 9,379
  7. 2020Retrieval-Augmented Generation for Knowledge-Intensive NLP Taskscited by 9,297
  8. 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,695
  9. 2023Judging LLM-as-a-Judge with MT-Bench and Chatbot Arenacited by 8,626
  10. 2022Self-Consistency Improves Chain of Thought Reasoning in Language Modelscited by 5,708
  11. 2021Measuring Mathematical Problem Solving With the MATH Datasetcited by 5,371
  12. 2024Qwen2.5 Technical Reportcited by 4,942
38 more
  1. 2022Large Language Models are Zero-Shot Reasonerscited by 4,374
  2. 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,276
  3. 2023Toolformer: Language Models Can Teach Themselves to Use Toolscited by 4,182
  4. 2018HotpotQA: A Dataset for Diverse, Explainable Multi-hop Question Answeringcited by 3,754
  5. 2019The Curious Case of Neural Text Degenerationcited by 2,916
  6. 2023Jailbroken: How Does LLM Safety Training Fail?cited by 1,651
  7. 2025Search-R1: Training LLMs to Reason and Leverage Search Engines with Reinforcement Learningcited by 1,444
  8. 2020Constructing A Multi-hop QA Dataset for Comprehensive Evaluation of Reasoning Stepscited by 1,282
  9. 2022Text Embeddings by Weakly-Supervised Contrastive Pre-trainingcited by 1,253
  10. 2022WebShop: Towards Scalable Real-World Web Interaction with Grounded Language Agentscited by 1,251
  11. 2020ALFWorld: Aligning Text and Embodied Environments for Interactive Learningcited by 1,205
  12. 2024Qwen2.5-Math Technical Report: Toward Mathematical Expert Model via Self-Improvementcited by 1,090
  13. 2022Measuring and Narrowing the Compositionality Gap in Language Modelscited by 1,075
  14. 2024OpenHands: An Open Platform for AI Software Developers as Generalist Agentscited by 1,002
  15. 2023Math-Shepherd: Verify and Reinforce LLMs Step-by-step without Human Annotationscited by 928
  16. 2021MuSiQue: Multihop Questions via Single-hop Question Compositioncited by 916
  17. 2023Distilling Step-by-Step! Outperforming Larger Language Models with Less Training Data and Smaller Model Sizescited by 737
  18. 2022PAL: Program-aided Language Modelscited by 652
  19. 2024Executable Code Actions Elicit Better LLM Agentscited by 564
  20. 2025Phi-4-Mini Technical Report: Compact yet Powerful Multimodal Language Models via Mixture-of-LoRAscited by 521
  21. 2024Safety Alignment Should Be Made More Than Just a Few Tokens Deepcited by 472
  22. 2022Large Language Models Struggle to Learn Long-Tail Knowledgecited by 458
  23. 2025Search-o1: Agentic Search-Enhanced Large Reasoning Modelscited by 433
  24. 2023Orca: Progressive Learning from Complex Explanation Traces of GPT-4cited by 379
  25. 2023AgentTuning: Enabling Generalized Agent Abilities for LLMscited by 338
  26. 2022Large Language Models Are Reasoning Teacherscited by 329
  27. 2023MINT: Evaluating LLMs in Multi-turn Interaction with Tools and Language Feedbackcited by 297
  28. 2022Teaching Small Language Models to Reasoncited by 284
  29. 2023ToRA: A Tool-Integrated Reasoning Agent for Mathematical Problem Solvingcited by 282
  30. 2023FireAct: Toward Language Agent Fine-tuningcited by 256
  31. 2023Specializing Smaller Language Models towards Multi-Step Reasoningcited by 251
  32. 2024MobileLLM: Optimizing Sub-billion Parameter Language Models for On-Device Use Casescited by 223
  33. 2024Small Language Models: Survey, Measurements, and Insightscited by 112
  34. 2024Agent-FLAN: Designing Data and Methods of Effective Agent Tuning for Large Language Modelscited by 100
  35. 2024AgentInstruct: Toward Generative Teaching with Agentic Flowscited by 89
  36. 2025Process Reward Models for LLM Agents: Practical Framework and Directionscited by 85
  37. 2024Critical Tokens Matter: Token-Level Contrastive Estimation Enhances LLM's Reasoning Capabilitycited by 83
  38. 2024AutoAct: Automatic Agent Learning from Scratch for QA via Self-Planningcited by 81

50 most cited of 71 All 71 (JSON)

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2025: 6; 2026: 41.

47 papers.

Sort:

By area:

  1. 2025The Landscape of Agentic Reinforcement Learning for LLMs: A Surveycited by 205
  2. 2025AgentDistill: Training-Free Agent Distillation with Generalizable MCP Boxescited by 30
  3. 2026Adapting the Interface, Not the Model: Runtime Harness Adaptation for Deterministic LLM Agentscited by 27
  4. 2026On-Policy Distillation with Curriculum Turn-level Guidance for Multi-turn Agentscited by 27
  5. 2026SOD: Step-wise On-policy Distillation for Small Language Model Agentscited by 21
  6. 2026Toward Efficient Agents: Memory, Tool learning, and Planningcited by 16
  7. 2025Student-Centered Distillation Narrows the Agentic Gap Between Small and Large LLMscited by 14
  8. 2026AgentArk: Distilling Multi-Agent Intelligence into a Single LLM Agentcited by 13
  9. 2026On Protecting Agentic Systems' Intellectual Property via Watermarkingcited by 8
  10. 2025A Survey on Collaborating Small and Large Language Models for Performance, Cost-effectiveness, Cloud-edge Privacy, and Trustworthinesscited by 7
  11. 2026MemCollab: Cross-Model Memory Collaboration via Contrastive Trajectory Distillationcited by 7
  12. 2025TURA: Tool-Augmented Unified Retrieval Agent for AI Searchcited by 6
35 more
  1. 2026Subliminal Transfer of Unsafe Behaviors in AI Agent Distillationcited by 5
  2. 2026TAPE: Tool-Guided Adaptive Planning and Constrained Execution in Language Model Agentscited by 4
  3. 2026Multi-Agent Transactive Memorycited by 4
  4. 2026Autonomous Knowledge Graph Exploration with Adaptive Breadth-Depth Retrievalcited by 3
  5. 2026RedAct: Redacting Agent Capability Traces for Procedural Skill Protectioncited by 3
  6. 2026SKILL-KD: Contrastive Skill Distillation for LLM Agentscited by 3
  7. 2026Agent Memory Distillation: Empowering Small LLM Agents with Hierarchical Teacher Memorycited by 3
  8. 2026OPDSearch+: On-Policy Distillation with RL Refinement for Search-Augmented Reasoningcited by 3
  9. 2025MENTOR: Reinforcement Learning via Flexible Teacher-Optimized Rewards for Tool-Use Distillationcited by 2
  10. 2026CIRAG: Construction-Integration Retrieval and Adaptive Generation for Multi-hop Question Answeringcited by 2
  11. 2026Search, Do not Guess: Teaching Small Language Models to Be Effective Search Agentscited by 2
  12. 2026DART-SD: Diamond-topology Aware Retrieval and Tuning for Self-Distillation of Multi-Turn Tool-Calling Agentscited by 2
  13. 2026When Agents Look the Same: Quantifying Distillation-Induced Similarity in Tool-Use Behaviorscited by 1
  14. 2026Knowledge Distillation Must Account for What It Losescited by 1
  15. 2026EO-Gym: A Multimodal, Interactive Environment for Earth Observation Agentscited by 1
  16. 2026When Cloud Agents Meet Device Agents: Lessons from Hybrid Multi-Agent Systemscited by 1
  17. 2026AgentBrew: Lifelong Knowledge Brewing from Strong Teachers to Weak LLM Agentscited by 1
  18. 2026From Trajectories to Prefixes: Reusing Teacher Trajectories via Replayed Prefixes and Online Continuationcited by 1
  19. 2026LLM-based Agents for Forecasting and Prediction: Methods, Training, Evaluation, and Applicationscited by 1
  20. 2026Mid-Harness: Scaling Actions Between Model and Harness for Terminal Agentscited by 1
  21. 2026Following the Teacher's Footsteps: Scheduled Checkpoint Distillation for Domain-Specific LLMscited by 0
  22. 2026PaperGuide: Making Small Language-Model Paper-Reading Agents More Efficientcited by 0
  23. 2026Characterize Then Distill: Mechanistic Reasoning in Large Output Spacescited by 0
  24. 2026IAPO: Input Attribution-Aware Policy Optimization for Tool Use in Small Multimodal Agentscited by 0
  25. 2026SkillSmith: Enhancing Locally Deployed Agents via Automatic Skill Construction and Evolutioncited by 0
  26. 2026From Collaboration to Capability: Internalizing Routed LLM Experts into Compact Reasonerscited by 0
  27. 2026Waggle: Learning One Anonymous Local Law for Self-Organizing LLM Swarmscited by 0
  28. 2026Knowing When Thinking Is Not Enough: Teaching Small Reasoning Models to Reason Beyond Their Parametric Knowledgecited by 0
  29. 2026From Migration to Calibration: Aligning Agents with Deployment Requirementscited by 0
  30. 2026Harness-Aware Distillation for Small Language Model Agentscited by 0
  31. 2026Iterate on an LLM, Serve on an SLMcited by 0
  32. 2026Heterogeneous Agentic Coevolutioncited by 0
  33. 2026Avoiding What Your Teacher Already Knows: Entity Familiarity for Deep-Search Distillationcited by 0
  34. 2026Teacher-Guided Tool Learning for Small Language Models via Bidirectional KL Constraintscited by 0
  35. 2026Progress-Aware Distillation for Mitigating Stagnation in Small Language Model Agentscited by 0

Similar, not cited

Close in wording, no citation either way

  1. 2025Structured Agent Distillation for Large Language Model
  2. 2024Sub-goal Distillation: A Method to Improve Small Language Agents
  3. 2025A Survey of Frontiers in LLM Reasoning: Inference Scaling, Learning to Reason, and Agentic Systems
  4. 2024Improving Mathematical Reasoning Capabilities of Small Language Models via Feedback-Driven Distillation
  5. 2024Textualized Agent-Style Reasoning for Complex Tasks by Multiple Round LLM Generation
  6. 2026A Comprehensive Evaluation of LLM Reasoning: From Single-Model to Multi-Agent Paradigms
  7. 2025Agentic Reasoning: A Streamlined Framework for Enhancing LLM Reasoning with Agentic Tools
  8. 2024Beyond Answers: Transferring Reasoning Capabilities to Smaller LLMs Using Multi-Teacher Knowledge Distillation