MetaTool:通过元任务增强助力大语言模型掌握工具使用
MetaTool: Facilitating Large Language Models to Master Tools with Meta-task Augmentation
AI总结:
针对大语言模型工具使用泛化难、标注成本高的问题,提出MetaTool方法,通过元任务自监督增强生成训练数据,提升开源模型工具使用性能,实现新任务零样本泛化。
摘要:
利用大语言模型(LLMs)使用工具是让AI智能体落地真实世界应用的关键。当前主流方法是采用带示例的少样本提示或基于专家标注的微调。然而,仅靠上下文内的示例可能无法覆盖复杂工具和任务所需的足够知识;基于解决方案路径的训练也受限于专家标注成本高、难以泛化到新工具的问题。可泛化工具使用的核心挑战在于理解工具的“元”本质,即可跨任务迁移的工具根本属性,比如因果关系与约束条件。本文提出MetaTool——一种新型工具学习方法,旨在实现跨任意可复用工具集的泛化。该方法引入了源自一系列元任务的自监督增强技术,具体为预测工具执行过程中的被掩码元素。这种自监督流程可规模化生成高质量问答数据,便于用于监督工具理解。将元任务数据融入面向任务的训练后,该方法显著提升了开源LLMs的性能,在基于工具的规划和对话场景中均取得了与ChatGPT相当的结果。通过大规模指令微调,MetaTool模型在新任务上展现出出色的零样本泛化能力。
英文摘要:
Utilizing tools with Large Language Models (LLMs) is essential for grounding AI agents in real-world applications. The prevailing approach involves few-shot prompting with demonstrations or fine-tuning with expert annotations. However, mere in-context demonstrations may fail to cover sufficient knowledge for complex tools and tasks. Training on solution paths is also hindered by the high cost of expert annotations and generalizing to new tools. A core challenge of generalizable tool use lies in understanding the "meta", or fundamental natures of tools that are transferable across tasks, such as causality and constraints. In this paper, we present MetaTool, a novel tool learning methodology designed to generalize across any reusable toolset. Our approach incorporates a self-supervised augmentation technique derived from a series of meta-tasks. This involves predicting masked elements in the tool execution process. The self-supervised procedure enables scalable generation of high-quality QA data, which is handy for supervising tool understanding. By incorporating meta-task data into task-oriented training, our method significantly enhances the performance of open-source LLMs, achieving results comparable to ChatGPT in both tool-based planning and chatting scenarios. Through large-scale instruction tuning, the MetaTool model demonstrates impressive zero-shot generalizability on new tasks.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。