arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2306.05301cs.CL
收藏

ToolAlpaca:基于3000个模拟案例的语言模型泛化工具学习

ToolAlpaca: Generalized Tool Learning for Language Models with 3000 Simulated Cases

Chinese Information Processing Laboratory(中文信息处理实验室);University of Chinese Academy of Sciences(中国科学院大学)

Qiaoyu Tang, Ziliang Deng, Hongyu Lin, Xianpei Han, Qiao Liang, Boxi Cao, Le Sun

AI总结:

本文提出ToolAlpaca框架,通过多智能体模拟环境自动生成包含3938个实例的多样化工具使用语料库,微调紧凑语言模型实现泛化工具使用能力,证明小模型无需特定工具训练即可达到与GPT-3.5相当的效果。

摘要:

使大型语言模型能够有效利用现实世界工具对于实现具身智能至关重要。现有的工具学习方法要么主要依赖如GPT-4等超大型语言模型以零样本方式获得泛化工具使用能力,要么利用监督学习在紧凑模型上训练有限范围的工具。然而,较小的语言模型能否在没有特定工具训练的情况下实现泛化工具使用能力仍不确定。为了解决这个问题,本文引入了ToolAlpaca,这是一个新颖的框架,旨在自动生成多样化的工具使用语料库,并在紧凑语言模型上以最少的人工干预学习泛化工具使用能力。具体而言,ToolAlpaca首先通过构建多智能体模拟环境自动创建高度多样化的工具使用语料库。该语料库包含来自50个不同类别、超过400个现实世界工具API的3938个工具使用实例。随后,使用构建的语料库微调紧凑语言模型,分别得到两个模型,即ToolAlpaca-7B和ToolAlpaca-13B。最后,我们评估这些模型在没有特定训练的情况下使用先前未见工具的能力。实验结果表明,ToolAlpaca实现了与GPT-3.5等超大型语言模型相当的有效泛化工具使用能力,证明紧凑语言模型学习泛化工具使用能力是可行的。

英文摘要:

Enabling large language models to utilize real-world tools effectively is crucial for achieving embodied intelligence. Existing approaches to tool learning have either primarily relied on extremely large language models, such as GPT-4, to attain generalized tool-use abilities in a zero-shot manner, or utilized supervised learning to train limited scopes of tools on compact models. However, it remains uncertain whether smaller language models can achieve generalized tool-use abilities without tool-specific training. To address this question, this paper introduces ToolAlpaca, a novel framework designed to automatically generate a diverse tool-use corpus and learn generalized tool-use abilities on compact language models with minimal human intervention. Specifically, ToolAlpaca first automatically creates a highly diversified tool-use corpus by building a multi-agent simulation environment. The corpus contains 3938 tool-use instances from more than 400 real-world tool APIs spanning 50 distinct categories. Subsequently, the constructed corpus is employed to fine-tune compact language models, resulting in two models, namely ToolAlpaca-7B and ToolAlpaca-13B, respectively. Finally, we evaluate the ability of these models to utilize previously unseen tools without specific training. Experimental results demonstrate that ToolAlpaca achieves effective generalized tool-use capabilities comparable to those of extremely large language models like GPT-3.5, demonstrating that learning generalized tool-use ability is feasible for compact language models.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑