How Much Memory Does Your Agent Actually Need?
How Much Memory Does Your Agent Actually Need?
你的智能体到底需要多少记忆?
In our previous post, we compared ALTK-Evolve with ACE and showed that how you deliver an agent’s self-distilled guidelines — a few retrieved per task vs. the whole set injected — drives both accuracy and cost. This post steps back to the question that comes before it: how much should you give it? 在上一篇文章中,我们对比了 ALTK-Evolve 和 ACE,并展示了交付智能体自提炼指南的方式(按任务检索少量指南 vs. 注入全套指南)如何影响准确性和成本。本文将退后一步,探讨一个更基础的问题:你应该给它多少记忆?
Equipping an agent with agentic memory sounds simple: distill lessons from its past work, put them back in context, and more experience should mean better performance. It doesn’t always work that way. When we scaled the evaluation to eight models — from a 30B dense model to frontier proprietary systems — one finding stood out: Agentic memory is not a feature you switch on. It’s a dose you calibrate to the model. 为智能体配备“智能体记忆”听起来很简单:从过去的工作中提炼经验,将其放回上下文中,更多的经验应该意味着更好的表现。但事实并非总是如此。当我们把评估范围扩大到八个模型(从 30B 稠密模型到前沿的专有系统)时,一个发现脱颖而出:智能体记忆不是一个可以随意开关的功能,而是一个需要根据模型进行校准的“剂量”。
TL;DR
简而言之
ALTK-Evolve lets an agent learn from its own past trajectories: distilling reusable guidelines and injecting them back at inference time, with no weight updates and no human annotation. The right dose differs by model tier: strong models with headroom want the full guideline set, weaker models do best with a compact core plus per-task retrieval, and saturated models show no measurable gain. Curated retrieval can be both the most accurate and the cheapest option: gpt-oss-120b gained +16.1pp task completion at only +5% tokens — and prompt caching keeps even the full guideline set affordable in production. ALTK-Evolve 让智能体能够从自身的历史轨迹中学习:在推理时提炼可重用的指南并将其注入,无需更新权重,也无需人工标注。合适的剂量取决于模型层级:拥有余力的强模型需要全套指南;较弱的模型在“精简核心 + 按任务检索”的模式下表现最好;而已饱和的模型则没有明显的提升。精选检索(Curated retrieval)既能实现最高准确率,也是成本最低的选择:gpt-oss-120b 在仅增加 5% token 的情况下,任务完成率提升了 16.1 个百分点,且通过提示词缓存(prompt caching),即使是全套指南在生产环境中也依然经济实惠。
The Key Insight: Dosage Depends on Capability
核心洞察:剂量取决于能力
Not every model benefits from the same amount of memory. Across eight models spanning the capability spectrum, we saw three recurring patterns: 并非所有模型都能从相同数量的记忆中获益。在涵盖不同能力水平的八个模型中,我们观察到了三种反复出现的模式:
-
Strong models with headroom want the full guideline set — every guideline, including rare edge-case lessons. They have the capacity to absorb and apply all of it. DeepSeek-V3.2 (671B MoE) climbed +9.5 percentage points in task completion when given its full self-mined guideline set. 拥有余力的强模型需要全套指南——包括每一条指南,甚至是罕见的边缘案例经验。它们有能力吸收并应用所有内容。DeepSeek-V3.2 (671B MoE) 在获得其完整自提炼指南集后,任务完成率提升了 9.5 个百分点。
-
Smaller or weaker models get drowned by a large guideline set. For these, a tight, high-confidence core plus a handful of task-relevant guidelines retrieved per task works best. gpt-oss-120b (117B MoE) gained +16.1pp with this selective approach — while the full guideline set gained less and cost ~50% more tokens. 较小或较弱的模型会被庞大的指南集淹没。 对于这些模型,一个紧凑、高置信度的核心,加上针对每个任务检索的少量相关指南,效果最好。gpt-oss-120b (117B MoE) 通过这种选择性方法提升了 16.1 个百分点,而使用全套指南时提升较小,且成本增加了约 50% 的 token。
-
Already-saturated models show no measurable gain. We call this the saturated pattern — the label describes what we observed, not a proven cause. The model may already have been near its ceiling on these tasks, the guidelines may not have addressed its remaining failures, or it may not have applied the guidance effectively. GLM-5 (745B MoE) sat here in our runs. 已饱和的模型没有表现出可衡量的增益。 我们称之为“饱和模式”——这个标签描述了我们的观察结果,而非已证实的成因。模型可能已经在这些任务上接近其性能上限,指南可能未能解决其剩余的失败点,或者模型未能有效地应用这些指导。在我们的测试中,GLM-5 (745B MoE) 属于此类。
What puts a model into one pattern rather than another isn’t simply parameter count. Benchmark headroom, context-window size, architecture, guideline quality, and task distribution all appear to shape where a model lands, and separating those factors is ongoing work. The practical takeaway holds either way: the right dose of memory depends on the model, and we can calibrate it. 决定模型属于哪种模式的因素不仅仅是参数量。基准测试余力、上下文窗口大小、架构、指南质量以及任务分布似乎都在影响模型的表现,而分离这些因素仍是正在进行的工作。无论如何,实际的结论是明确的:合适的记忆剂量取决于模型本身,且我们可以对其进行校准。
Learning happens around the model, not inside it
学习发生在模型之外,而非模型之内
“Memory” here doesn’t mean replaying a past transcript. It means a guideline set — strategies that worked, mistakes to avoid, and edge cases — distilled from the agent’s own prior trajectories. The loop is straightforward: 这里的“记忆”并不意味着重放过去的记录,而是指从智能体自身历史轨迹中提炼出的指南集——包括有效的策略、需要避免的错误以及边缘案例。这个循环很简单:
- The agent attempts tasks and produces trajectories. 智能体尝试任务并产生轨迹。
- ALTK-Evolve extracts behavioral guidelines from both its successful and unsuccessful runs. ALTK-Evolve 从成功和失败的运行中提取行为指南。
- It consolidates those guidelines into a reusable set. 它将这些指南整合为一个可重用的集合。
- At inference time, the agent receives either the full guideline set or a task-relevant selection of it. 在推理时,智能体接收全套指南或按任务筛选出的相关指南。
No model weights are updated. The learning loop changes the guidance available to the agent, not the underlying model — which is exactly why it’s cheap to adopt and portable across the eight models we tested. 模型权重不会被更新。学习循环改变的是提供给智能体的指导,而不是底层模型本身——这正是它易于采用且在我们测试的八个模型中具有可移植性的原因。