Making Language Models Better Tool Learners with Execution Feedback

Shuofei Qiao, Honghao Gui, Chengfei Lv, Qianghuai Jia, Huajun Chen +1 more
5/22/2023
cs.CLcs.AIcs.HC

Official code: zjunlp/TRICE (43 stars, MIT, last commit 2024-03-14).

Abstract

Tools serve as pivotal interfaces that enable humans to understand and reshape the environment. With the advent of foundation models, AI systems can utilize tools to expand their capabilities and interact with the real world. Existing tool learning methodologies, encompassing supervised fine-tuning and prompt engineering approaches, often induce large language models to utilize tools indiscriminately, as complex tasks often exceed their own competencies. However, introducing tools for simple tasks, which the models themselves can readily resolve, can inadvertently propagate errors rather than enhance performance. This leads to the research question: can we teach language models when and how to use tools? To meet this need, we propose Tool leaRning wIth exeCution fEedback (TRICE), a two-stage end-to-end framework that enables the model to continually learn through feedback derived from tool execution, thereby learning when and how to use tools effectively. Experimental results, backed by further analysis, show that TRICE can make the large language model selectively use tools by improving the accuracy of tool usage while enhancing insufficient tool learning and mitigating excessive reliance on tools. Code is available at https://github.com/zjunlp/TRICE.

View on arXivView PDF

Code Implementations(1)

zjunlp/TRICEOfficial100%
MIT

[NAACL 2024] Making Language Models Better Tool Learners with Execution Feedback

433PythonApr 28, 20232 years agoMIT
agentexecutionfeedbackknowlmlarge-language-models+7 more

Similar Papers

Cite this paper

@article{qiao2023making,
  title  = {Making Language Models Better Tool Learners with Execution Feedback},
  author = {Shuofei Qiao and Honghao Gui and Chengfei Lv and Qianghuai Jia and Huajun Chen and Ningyu Zhang},
  year   = {2023},
  eprint = {2305.13068},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2305.13068v3}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2305.13068.svg)](https://codeofpaper.com/paper/2305.13068)

Discussion