Toolformer: Language Models Can Teach Themselves to Use Tools
Timo Schick, Jane Dwivedi-Yu, Roberto Dessì, Roberta Raileanu, Maria Lomeli, Eric Hambro, Luke Zettlemoyer, Nicola Cancedda, Thomas Scialom
摘要
Language models (LMs) exhibit remarkable abilities to solve new tasks from just a few examples or textual instructions, especially at scale. They also, paradoxically, struggle with basic functionality, such as arithmetic or factual lookup, where much simpler and smaller models excel. In this paper, we show that LMs can teach themselves to use external tools via simple APIs and achieve the best of both worlds. We introduce Toolformer, a model trained to decide which APIs to call, when to call them, what arguments to pass, and how to best incorporate the results into future token prediction. This is done in a self-supervised way, requiring nothing more than a handful of demonstrations for each API. We incorporate a range of tools, including a calculator, a Q&A system, two different search engines, a translation system, and a calendar. Toolformer achieves substantially improved zero-shot performance across a variety of downstream tasks, often competitive with much larger models, without sacrificing its core language modeling abilities.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 673 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Improving Language Models by Retrieving from Trillions of Tokens 引用了 Retrieval Augmented Language Model Pre-Training
- Gorilla: Large Language Model Connected with Massive APIs 引用了 PAL: Program-aided Language Models
- Gorilla: Large Language Model Connected with Massive APIs 引用了 HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face
- Reflexion: language agents with verbal reinforcement learning 引用了 HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face
- AgentVerse: Facilitating Multi-Agent Collaboration and Exploring Emergent Behaviors 引用了 Reflexion: language agents with verbal reinforcement learning
- ToolLLM: Facilitating Large Language Models to Master 16000+ Real-world APIs 引用了 Gorilla: Large Language Model Connected with Massive APIs
- ToolLLM: Facilitating Large Language Models to Master 16000+ Real-world APIs 引用了 Reflexion: language agents with verbal reinforcement learning
- ToolLLM: Facilitating Large Language Models to Master 16000+ Real-world APIs 引用了 HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face
- HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face 引用了 PAL: Program-aided Language Models
引用它的顶会 Paper673
- Reflexion: language agents with verbal reinforcement learningNoah Shinn, Federico Cassano, Ashwin Gopinath, Karthik Narasimhan 等NeurIPS 2023 · 5,828 次引用
- HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging FaceYongliang Shen, Kaitao Song, Xu Tan, Dongsheng Li 等NeurIPS 2023 · 1,778 次引用
- Gorilla: Large Language Model Connected with Massive APIsShishir G. Patil, Tianjun Zhang, Xin Wang, Joseph E. GonzalezNeurIPS 2024 · 1,715 次引用
- ToolLLM: Facilitating Large Language Models to Master 16000+ Real-world APIsYujia Qin, Shihao Liang, Yining Ye, Kunlun Zhu 等ICLR 2024 · 1,469 次引用
- AgentVerse: Facilitating Multi-Agent Collaboration and Exploring Emergent BehaviorsWeize Chen, Yusheng Su, Jingwei Zuo, Cheng Yang 等ICLR 2024 · 594 次引用
它引用的 Paper13
- Retrieval Augmented Language Model Pre-TrainingKelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat 等ICML 2020 · 2,937 次引用
- Improving Language Models by Retrieving from Trillions of TokensSebastian Borgeaud, Arthur Mensch, Jordan Hoffmann, Trevor Cai 等ICML 2022 · 1,629 次引用
- STaR: Bootstrapping Reasoning With ReasoningEric Zelikman, Yuhuai Wu, Jesse Mu, Noah D. GoodmanNeurIPS 2022 · 1,126 次引用
- PAL: Program-aided Language ModelsLuyu Gao, Aman Madaan, Shuyan Zhou, Uri Alon 等ICML 2023 · 700 次引用
- Distilling Knowledge from Reader to Retriever for Question AnsweringGautier Izacard, Edouard GraveICLR 2021 · 317 次引用
相关 Paper
- Tool Learning in the Wild: Empowering Language Models as Automatic Tool AgentsZhengliang Shi, Shen Gao, Lingyong Yan, Yue Feng 等WWW 2025 · 59 次引用
- GenTool: Enhancing Tool Generalization in Language Models through Zero-to-One and Weak-to-Strong SimulationJie He, Jennifer Neville, Mengting Wan, Longqi Yang 等ACL Findings 2025
- Small LLMs Are Weak Tool Learners: A Multi-LLM AgentWeizhou Shen, Chenliang Li, Hongzhan Chen, Ming Yan 等EMNLP 2024 · 18 次引用
- Self-Guided Function Calling in Large Language Models via Stepwise Experience RecallSijia Cui, Aiyao He, Shuai Xu, Hongming Zhang 等EMNLP Findings 2025 · 2 次引用
- Finetuned Language Models are Zero-Shot LearnersJason Wei, Maarten Bosma, Vincent Y. Zhao, Kelvin Guu 等ICLR 2022 · 4,966 次引用
