让智能体通过记忆更精准使用工具,无需微调模型。
MemToolAgent: Leveraging Memory for Tool Using Agents Based on Environment and User Feedback

- 用历史对话和环境反馈提取结构化记忆,提升工具使用能力。
- 在多个基准上相对基线提升最高达80%,显著改善任务完成率。
- 适合需要个性化交互与长期学习的智能体应用,如客服、助手。
现代大型语言模型(LLM)代理可通过外部工具协助用户解决复杂任务。然而,对于需要从长期历史事件或过往人机交互中学习的问题,代理需依赖记忆机制存储和检索经验。尽管对话代理已有复杂记忆系统,但少有研究实证探讨如何通过过往用户-代理对话提升工具使用能力。本文提出 MemToolAgent 框架,通过记忆管理优化工具使用。其包含一个记忆提取模块,将历史经验转化为结构化记忆条目;以及一个检索模块,动态选择存储的记忆子集。该方法无需微调大模型,即可实现更个性化、准确的响应,与用户偏好和反馈对齐。主要贡献包括:(1) 统一的记忆条目格式,支持通用与个性化工具使用而无需微调;(2) 基于反思的记忆提取,利用环境与用户反馈将错误执行提炼为批判性记录;(3) 根据记忆相似度分布动态决定使用多少历史经验。在 WorkBench、NESTFUL 与 PEToolBench 基准上,相对强基线分别取得 29%、80% 和 17% 的相对提升。
原文摘要 · Abstract (English)
Modern large language model (LLM) agents can use external tools to help users solve complex tasks. However, for problems that require learning from long-term historical events or from previous agent-environment interactions, LLM agents are required to use memory mechanisms to store and retrieve experiences. While sophisticated memory systems exist for dialogue agents, few studies have empirically examined how to improve agents' tool-using capabilities through past user-agent conversations. We propose MemToolAgent, a framework that improves tool use through memory management. Our approach contains a memory extraction module that processes past experiences into structured memory entries, and a retrieval module that dynamically selects a subset of the stored memory entries. This enables more personalized and accurate responses aligned with user preferences and feedback without requiring LLM fine-tuning. In summary, this work has three main contributions: (1) a unified memory entry format that improves both general-purpose and personalized tool use without LLM fine-tuning, (2) a reflection-based memory extraction that uses environment and user feedback to distill wrong executions into critiques to store, and (3) a retrieval module that chooses how many past experiences to use based on the memory similarity distribution. MemToolAgent achieves 29%, 80%, and 17% relative improvements compared to strong baselines on the WorkBench, NESTFUL, and PEToolBench benchmarks, respectively.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。