What happens when episodic memory makes a coding agent worse?

Tobias Lindenbauer et al. · 1 authors · School of Computation, Information and Technology, Technical University of Munich · 2025 · arXiv:2505.23422

What happens when episodic memory makes a coding agent worse?

Opening

The intuition behind cross-task memory is hard to argue with: an agent that fixed a similar bug last week should not start from zero today, and the reasoning frameworks existing software engineering agents rely on throw away everything they learned after a single task instance. So the authors of CTIM-Rover gave a repository-level memory to an existing coding agent and tested whether the intuition holds on real repository work. It did not.

What the paper does

CTIM-Rover extends AutoCodeRover, an AI agent for software engineering, with a Cross-Task-Instance Memory that exists at two levels: general-purpose and repository-level, built on the experiential learning approach ExpeL with a Mixture-of-Experts-inspired design. The hypothesis was that software engineering is especially well positioned to benefit, because identifying every location a patch must touch needs repository-level understanding. The team then compared memory-equipped configurations against the memory-free baseline and analyzed why the results moved the way they did.

Findings

  1. Baseline agents discard their lessons — the reasoning frameworks that existing SE agents build on inefficiently discard their long-term memory after a single task instance, which is exactly why a cross-task memory looked worth building.

all of these reasoning and planning frameworks inefficiently discard their long-term memory after a single task instance

  1. What was added — the agent extends agentic reasoning frameworks with an episodic memory, specifically a general and repository-level Cross-Task-Instance Memory (CTIM).

extends agentic reasoning frameworks with an episodic memory, more specifically, a general and repository-level Cross-Task-Instance Memory (CTIM)

  1. The memory never beat the baseline — in no configuration did CTIM-Rover outperform AutoCodeRover, and the authors conclude that neither ExpeL nor DoT-Bank scale to real-world SE problems.

CTIM-Rover does not outperform AutoCodeRover in any configuration

  1. The cause is noise, not too little memory — the analysis points to noise introduced by distracting CTIM items or exemplar trajectories as the likely source of the performance degradation.

noise introduced by distracting CTIM items or exemplar trajectories as the likely source of the performance degradation

Caveat

One repository-level setup against one baseline agent, so the result argues against this episodic-memory design rather than against episodic memory in general.

What this means for 5ac

A support agent whose memory is full of “similar past tickets” can end up worse than the same agent with memory off, because irrelevant exemplars compete with the evidence actually in front of it. The discipline this paper buys you is an A/B habit: run the agent with memory disabled before you pay to store anything, and ship the memory layer only when it beats the empty-store baseline on your own tasks. When it loses, the paper’s diagnosis becomes a checklist: inspect which retrieved items distracted the agent, prune by relevance to the repository or account rather than by recency alone, and remember that the conclusion scales to experience replay in general only after your own baseline run says so.

Source