To address intricate real-world tasks, there has been a rising interest in tool utilization in applications of large language models (LLMs). To develop LLM-based agents, it usually requires LLMs to understand many tool functions from different tool documentation. But these documentations could be diverse, redundant or incomplete, which immensely affects the capability of LLMs in using tools. To solve this, we introduce EASYTOOL, a framework transforming diverse and lengthy tool documentation into a unified and concise tool instruction for easier tool usage. EasyTool purifies essential information from extensive tool documentation of different sources, and elaborates a unified interface (i.e., tool instruction) to offer standardized tool descriptions and functionalities for LLM-based agents. Extensive experiments on multiple different tasks demonstrate that EasyTool can significantly reduce token consumption and improve the performance of tool utilization in real-world scenarios. Our code will be available at \url{https://github.com/microsoft/JARVIS/} in the future.
翻译:为应对复杂的现实世界任务,大语言模型在应用中对工具调用的需求日益增长。在构建基于大语言模型的智能体时,需要模型从不同工具文档中理解大量工具函数。然而,这些文档可能存在格式多样、信息冗余或内容不完整等问题,严重制约了大语言模型使用工具的能力。为此,我们提出EASYTOOL框架,该框架将格式各异、篇幅冗长的工具文档转化为统一简洁的工具指令,以降低工具使用难度。EasyTool能够从不同来源的详细工具文档中提取核心信息,并构建统一接口(即工具指令),为基于大语言模型的智能体提供标准化的工具描述与功能定义。在多个不同任务上的大量实验表明,EasyTool能显著减少令牌消耗,并提升现实场景中工具调用的性能。我们的代码将在未来发布于\url{https://github.com/microsoft/JARVIS/}。