arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2504.07952cs.LGcs.CL
收藏

动态备忘单:具有自适应记忆的测试时学习

Dynamic Cheatsheet: Test-Time Learning with Adaptive Memory

Stanford University(斯坦福大学);Together AI

Mirac Suzgun, Mert Yuksekgonul, Federico Bianchi, Dan Jurafsky, James Zou

AI总结:

本文提出动态备忘单(DC)框架,通过测试时自适应记忆让黑盒语言模型存储并复用策略、代码和见解,无需微调即可在数学、推理和知识任务上显著提升准确率。

摘要:

尽管当前的语言模型(LMs)在复杂任务上表现出色,但它们通常在真空中运行:每个输入查询都被单独处理,而不保留先前尝试中的见解。在此,我们提出了动态备忘单(Dynamic Cheatsheet,DC),这是一个轻量级框架,赋予黑盒语言模型一种持久、不断演化的记忆。DC 使模型能够在推理时存储和复用积累的策略、代码片段和通用问题解决见解,而不是反复重新发现或重新犯下相同的解决方案和错误。这种测试时学习在一系列任务上显著提升了性能,而无需显式的真实标签或人类反馈。借助 DC,Claude 3.5 Sonnet 在 AIME 数学考试上的准确率提高了一倍以上,因为它开始跨题目保留代数见解。类似地,GPT-4o 在 Game of 24 上的成功率从 10% 提高到 99%,因为模型发现并复用了基于 Python 的解决方案。在容易出现算术错误的任务中,例如配平方程式,DC 使 GPT-4o 和 Claude 通过回忆先前验证过的代码达到了接近完美的准确率,而它们的基线停滞在约 50%。除了算术挑战之外,DC 在知识密集型任务上也带来了显著的准确率提升。Claude 在 GPQA-Diamond 上取得了 9% 的提升,在 MMLU-Pro 问题上取得了 8% 的提升。至关重要的是,DC 的记忆是自我整理的,专注于简洁、可迁移的片段,而不是整个记录文本。与微调或静态检索方法不同,DC 在不修改底层参数的情况下,动态地调整语言模型的问题解决技能。总体而言,我们的研究结果表明,DC 是一种有前景的方法,可以为语言模型增强持久记忆,弥合孤立的推理事件与人类认知所特有的累积式、经验驱动学习之间的鸿沟。

英文摘要:

Despite their impressive performance on complex tasks, current language models (LMs) typically operate in a vacuum: Each input query is processed separately, without retaining insights from previous attempts. Here, we present Dynamic Cheatsheet (DC), a lightweight framework that endows a black-box LM with a persistent, evolving memory. Rather than repeatedly re-discovering or re-committing the same solutions and mistakes, DC enables models to store and reuse accumulated strategies, code snippets, and general problem-solving insights at inference time. This test-time learning enhances performance substantially across a range of tasks without needing explicit ground-truth labels or human feedback. Leveraging DC, Claude 3.5 Sonnet's accuracy more than doubled on AIME math exams once it began retaining algebraic insights across questions. Similarly, GPT-4o's success rate on Game of 24 increased from 10% to 99% after the model discovered and reused a Python-based solution. In tasks prone to arithmetic mistakes, such as balancing equations, DC enabled GPT-4o and Claude to reach near-perfect accuracy by recalling previously validated code, whereas their baselines stagnated around 50%. Beyond arithmetic challenges, DC yields notable accuracy gains on knowledge-demanding tasks. Claude achieved a 9% improvement in GPQA-Diamond and an 8% boost on MMLU-Pro problems. Crucially, DC's memory is self-curated, focusing on concise, transferable snippets rather than entire transcript. Unlike finetuning or static retrieval methods, DC adapts LMs' problem-solving skills on the fly, without modifying their underlying parameters. Overall, our findings present DC as a promising approach for augmenting LMs with persistent memory, bridging the divide between isolated inference events and the cumulative, experience-driven learning characteristic of human cognition.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑