Meta AI Innovates with a Memory Agent for Complex Tasks

Le brief IA que les pros lisent chaque soir
Les 7 actus IA du jour, décryptées en 5 min. Gratuit.
Inclus dès l'inscription : notre sélection des meilleurs guides & comparatifs IA.
Choisis ton rythme
Gratuit · Pas de spam · Désabonnement en 1 clic
Meta AI Innovates with a Memory Agent for Complex Tasks
Meta AI employs a second AI agent as a memory trainer to stay on track during long tasks.
During prolonged tasks, AI agents often forget constraints, repeat failed commands, and rediscover errors they have already diagnosed. The memory module proposed by Meta AI tracks this information and decides when it is necessary to recall these elements.
In a new paper, researchers from Meta AI describe how these failures manifest. An agent recognizes a constraint at the beginning but later violates it while fixing an unrelated bug. It notes that a command has failed, then tries an almost identical version shortly after. It diagnoses an error pattern but later treats the same pattern as new.
The authors call this "behavioral state degradation." The state that guides the agent's decisions becomes dispersed across an increasing task history. It can be buried deep within the context window or completely outside of it. Even when the information remains in the transcript or context window, it may no longer reliably influence the agent's behavior. Meta AI asserts that simply providing access to longer histories does not solve the problem.
Deciding When Memory is Important
Existing memory systems focus on storing, updating, and retrieving information. According to the paper, this works well for personalization and recall between sessions. However, agents working on a task face a different problem. The system must decide when a memory is useful enough to be recalled. Too few recalls lead to repeated errors, while too many recalls add latency, consume tokens, and distract the agent from its current work.
This goes beyond summarization: a summarizer simply decides which information to keep, while Meta's system decides whether a stored execution state should influence the agent's next decision. Given that failure modes vary widely by task, a fixed summarization rule cannot reliably make this choice.
A Second Agent Decides When to Intervene
The proposed system pairs an unmodified "action agent" with a distinct "memory agent." At fixed intervals, the memory agent examines a sliding window of the most recent steps and updates a structured memory bank. It then decides whether to add a brief reminder to the next call of the action agent or to remain silent.
The authors claim that the module can work with existing agents and integrates as a plug-and-play component. Unlike a general advisory model, it provides only memory-based reminders and does not offer broader strategic advice.
The memory bank has three sections. A private state field tracks ongoing progress and risks and is never shown to the action agent. The knowledge memory stores stable facts such as requirements, file paths, and configurations. Procedural memory records what the agent has tried and what happened, including failed commands, successful fixes, and rejected hypotheses.
At each memory step, the agent can update the bank only through predefined tool calls rather than freely rewriting its content. It then decides whether to reactivate a stored state and, if necessary, drafts a targeted reminder. Choosing not to intervene is part of the policy.
Selective Reminders Improve Scores on Two Benchmarks
Researchers tested the system on Terminal-Bench 2.0, which evaluates autonomous agents in realistic command-line environments. They also used tau2-Bench, which tests the use of conversational tools in the aviation, retail, and telecommunications sectors. Claude Opus 4.6 served as the memory agent, although the model has since received several updates.
With the older Claude Sonnet 4.5 as the action agent, the system solved 46% of Terminal-Bench tasks on its first attempt. The baseline solved 38%. On tau2-Bench, the weighted average of tasks increased from 55% to 62%.
Results varied by domain. Scores for aviation and retail tasks each increased by about 10 percentage points, while telecommunications only progressed by 3 points. Researchers assert that the uneven gains suggest the memory agent intervenes at different rates depending on the task rather than applying a fixed aggregation rule.
The gains were more significant for the weaker agent but did not disappear with a stronger model. Opus 4.6 improved its performance by 2.4 percentage points on Terminal-Bench and 2.5 points on tau2-Bench. This result suggests that the memory system does more than compensate for the limited capacity of a weaker model.
Selective Intervention Works Better Than Constant Recall
The team removed one capability at a time to determine which parts of the system led to the gains. When the action agent received the complete memory bank at each step, performance fell below that of the full system. A version without the "silence" option, which returned a memory at each step, remained competitive but produced less consistent gains across domains.
A counselor-style version without a persistent memory bank helped in some areas but hurt performance in others. The complete design, which combines a maintained memory bank with selective reminders, yielded the best results.
The approach also outperformed Mem0, a production memory layer that retrieves records through search. The difference lies not only in the records that the system retrieves. The memory agent also decides whether and how a stored state should enter the loop as a targeted reminder.
An example from the "Aviation" domain of tau2-Bench illustrates how this works. A user claimed Gold status, but the tool identified them as a regular customer. The baseline granted compensation based on the user's claim. The memory agent instead issued a reminder to rely on the tool's verified data.
Most remaining errors concerned calibration rather than memory. In some cases, for instance, the memory agent treated a speculative inference with too much confidence.
Smaller Open Models Need Training to Manage Memory Well
The main version does not require a specially trained model and operates more like a guest agent. The team also tested whether it could teach the intervention policy to an open model. They trained the smallest Qwen3.5-27B as a memory agent while keeping a much larger action model frozen.
Without training, the smaller memory agent reduced performance. Supervised fine-tuning recovered this loss, and subsequent reinforcement learning improved its decisions regarding when to recall a stored state.
Meta AI lists several open questions, including training memory and action agents together, teaching the system to invoke memory when needed rather than following a fixed schedule, and determining when literal memories work better than task-specific abstractions.
Meta AI has released the project's code on GitHub.
Meta is not alone in facing this issue, and the industry still lacks a standard approach. The open-source framework Mastra uses two agents in the background that monitor and compress a conversation instead of retaining the full history in the context window. The GAM system aims to prevent "context degradation" in long discussions and, like Meta's approach, compares its results with the Mem0 memory layer. Other researchers are designing long-term AI memory systems that can actively add, revise, and forget knowledge.
Brief IA — L'actualité IA en français
L'essentiel de l'actualité de l'intelligence artificielle, décrypté et expliqué chaque jour.