[论文解读] Chain of Tools: Large Language Model is an Automatic Multi-tool Learner
本文提出 Automatic Tool Chain (ATC),使大型语言模型(LLMs)能够通过编程自动使用一连串工具,并提出一种用于 LLM 学习新工具的黑盒探测方法,在 ToolFlow 和 RestBench 数据集上进行评估。
Augmenting large language models (LLMs) with external tools has emerged as a promising approach to extend their utility, empowering them to solve practical tasks. Existing work typically empowers LLMs as tool users with a manually designed workflow, where the LLM plans a series of tools in a step-by-step manner, and sequentially executes each tool to obtain intermediate results until deriving the final answer. However, they suffer from two challenges in realistic scenarios: (1) The handcrafted control flow is often ad-hoc and constraints the LLM to local planning; (2) The LLM is instructed to use only manually demonstrated tools or well-trained Python functions, which limits its generalization to new tools. In this work, we first propose Automatic Tool Chain (ATC), a framework that enables the LLM to act as a multi-tool user, which directly utilizes a chain of tools through programming. To scale up the scope of the tools, we next propose a black-box probing method. This further empowers the LLM as a tool learner that can actively discover and document tool usages, teaching themselves to properly master new tools. For a comprehensive evaluation, we build a challenging benchmark named ToolFlow, which diverges from previous benchmarks by its long-term planning scenarios and complex toolset. Experiments on both existing datasets and ToolFlow illustrate the superiority of our framework. Analysis on different settings also validates the effectiveness and the utility of our black-box probing algorithm.
研究动机与目标
- 激励让 LLMs 作为自动化的多工具用户使用,超越手工设计的工作流。
- 提出 ATC ,从工具协议生成可执行的工具使用程序。
- 引入一种黑盒探测方法,使 LLMs 能自主记录并掌握新工具。
- 将 ToolFlow 发展为具有长期规划和复杂工具依赖关系的具有挑战性的基准。
- 在各数据集上展示相对于基线的更高效率和工具学习能力。
提出的方法
- 提供包含参数、模式、状态等的详细工具协议,以学习输入输出数据流。
- 指示 LLM 生成一个可执行程序,按顺序调用多个工具以完成任务。
- 引入一种可追溯的反思机制,在执行过程中识别并纠正有问题的工具调用。
- 增加一个黑盒探测组件:LLM 生成测试实例以发现并记录新的工具协议。
- 实现一系列探测算法以处理工具依赖并最大化探测覆盖率。
- 使用现有的 RestBench 数据集和新的 ToolFlow 基准测试进行评估,度量标准包括成功率、路径准确性和工具精确度。
实验结果
研究问题
- RQ1在没有人工设计的控制流的情况下,LLM 是否能通过工具协议理解并使用一连串工具?
- RQ2LLM 生成可执行程序以协调多个工具的能力有多高?
- RQ3LLM 能否通过探测自主发现并记录新的工具协议?
- RQ4所提出的 ATC 框架是否相较基线提高了规划效率和工具覆盖范围?
- RQ5黑盒探测机制在现实设置中如何扩展工具集范围?
主要发现
- LLM 展示了对工具协议的理解以及以编程方式规划一连串工具的能力。
- ATC 实现了多工具管线的自动组合与执行,相较基线具有更高的效率。
- 可追溯的反思机制有助于定位有问题的工具调用并相应修正程序。
- 黑盒探测使 LLM 学习并记录新工具协议,扩展工具覆盖范围。
- ToolFlow 提供了一个具有长期规划和相互依赖的数据流的具有挑战性的环境,验证了该框架的有效性。
- 实验显示 ATC 和探测在多数据集和多骨干网络上具有优越的性能。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。