paper-with-me

홈 › Papers

ToolkenGPT: Augmenting Frozen Language Models with Massive Tools via Tool Embeddings

2023-05-19 · NeurIPS 2023 11 · Shibo Hao, Tianyang Liu, Zhen Wang, Zhiting Hu

Augmenting large language models (LLMs) with external tools has emerged as a promising approach to solving complex problems. However, traditional methods, which finetune LLMs with tool demonstration data, can be both costly and restricted to a predefined set of tools. Recent in-context learning paradigm alleviates these issues, but the limited context length only allows for a few shots of demonstrations, leading to suboptimal understandings of the tools. Moreover, when there are numerous tools to choose from, in-context learning could completely fail to work. In this paper, we propose an alternative approach, $\textbf{ToolkenGPT}$, which combines the benefits of both sides. Our approach represents each $\underline{tool}$ as a to$\underline{ken}$ ($\textit{toolken}$) and learns an embedding for it, enabling tool calls in the same way as generating a regular word token. Once a toolken is triggered, the LLM is prompted to complete arguments for the tool to execute. ToolkenGPT offers the flexibility to plug in an arbitrary number of tools by expanding the set of toolkens on the fly. In addition, it improves tool use by allowing extensive demonstration data for learning the toolken embeddings. In diverse domains, including numerical reasoning, knowledge-based question answering, and embodied plan generation, our approach effectively augments LLMs with tools and substantially outperforms various latest baselines. ToolkenGPT demonstrates the promising ability to use relevant tools from a large tool set in complex scenarios.

📄 PDF Abstract BibTeX arXiv:2305.11554

Code (2)

Ber666/ToolkenGPT 공식 구현 pytorch
lichenghaobuaa/tokenlearning pytorch

Tasks

In-Context LearningQuestion Answering

Similar Papers 제목 키워드 기반

Toolken+: Improving LLM Tool Usage with Reranking and a Reject Option

2024-10-15 · Konstantin Yakovlev, Sergey Nikolenko, Andrey Bout

The recently proposed ToolkenGPT tool learning paradigm demonstrates promising performance but suffers from two major issues: first, it cannot benefit from tool documentation, and second, it often makes mistakes in wheth…

Reranking

Chain-of-Tools: Utilizing Massive Unseen Tools in the CoT Reasoning of Frozen Language Models

2025-03-21 · Mengsong Wu, Tong Zhu, Han Han, Xiang Zhang 외

Tool learning can further broaden the usage scenarios of large language models (LLMs). However most of the existing methods either need to finetune that the model can only use tools seen in the training data, or add tool…

GSM8KQuestion Answering

Re-Initialization Token Learning for Tool-Augmented Large Language Models

2025-06-17 · Chenghao Li, Liu Liu, Baosheng Yu, Jiayan Qiu 외

Large language models have demonstrated exceptional performance, yet struggle with complex tasks such as numerical reasoning, plan generation. Integrating external tools, such as calculators and databases, into large lan…

GSM8KQuestion Answering

Middleware for LLMs: Tools Are Instrumental for Language Agents in Complex Environments

2024-02-22 · Yu Gu, Yiheng Shu, Hao Yu, Xiao Liu 외

The applications of large language models (LLMs) have expanded well beyond the confines of text processing, signaling a new era where LLMs are envisioned as generalist agents capable of operating within complex environme…

$α$-LoRA: Effective Fine-Tuning via Base Model Rescaling

2025-10-24 · Aymane El Firdoussi, El Mahdi Chayti, Mohamed El Amine Seddik, Martin Jaggi arxiv

Fine-tuning has proven to be highly effective in adapting pre-trained models to perform better on new desired tasks with minimal data samples. Among the most widely used approaches are reparameterization methods, which u…

Binary ClassificationTransfer Learning