Large Language Models (LLMs) based agents excel at diverse tasks, yet they suffer from brittle procedural memory that is manually engineered or entangled in static parameters. In this work, we investigate strategies to endow agents with a learnable, updatable, and lifelong procedural memory. We propose Memp that distills past agent trajectories into both fine-grained, step-by-step instructions and higher-level, script-like abstractions, and explore the impact of different strategies for Build, Retrieval, and Update of procedural memory. Coupled with a dynamic regimen that continuously updates, corrects, and deprecates its contents, this repository evolves in lockstep with new experience. Empirical evaluation on TravelPlanner and ALFWorld shows that as the memory repository is refined, agents achieve steadily higher success rates and greater efficiency on analogous tasks. Moreover, procedural memory built from a stronger model retains its value: migrating the procedural memory to a weaker model can also yield substantial performance gains. Code is available at https://github.com/zjunlp/MemP.
翻译:基于大语言模型的智能体在多种任务中表现出色,但其程序记忆存在脆弱性——要么依赖手工构建,要么被静态参数束缚。本文研究如何赋予智能体可学习、可更新且终身适应的程序记忆。我们提出Memp方法,将智能体历史轨迹提炼为细粒度的逐步指令和更高层次的脚本式抽象,并探索构建、检索与更新程序记忆的不同策略对效果的影响。结合动态维护机制(持续更新、修正和废弃记忆内容),记忆库会随新经验同步演进。在TravelPlanner和ALFWorld上的实验表明:随着记忆库的优化,智能体在相似任务上的成功率稳步提升,效率也显著提高。此外,由较强模型构建的程序记忆具有迁移价值——将其移植至较弱模型时,也能带来显著的性能增益。代码已开源至https://github.com/zjunlp/MemP。