Blog

Why your AI agents repeat the same mistake

Most advice says give the agent memory. Sometimes that is the fix. Often the mistake is somewhere memory cannot reach: in what no single session can see, in notes that have gone bad, or in a tool the agent calls.

Melvin Salas2 December 20264 min readUpdated 3 December 2026Verified 2 December 2026

Our reading, from running AI agents across client ad accounts every day: an agent repeats a mistake for one of four reasons. It never kept the lesson, no single session can see the mistake is a pattern, the notes it reads have gone bad, or the mistake was never in the agent at all but in a tool it calls. Each needs a different fix, and only two of them are about memory.

It never kept the lesson

Anthropic's documentation says each Managed Agents session starts with a fresh context by default, and when a session ends, any state the agent built up is gone. Its memory stores exist to carry information across sessions, and it lists prior mistakes among the things they carry.

Our reading: if your agent has no memory at all, this is the whole answer. Give it a place to write corrections, and make it read that place before it starts. Most teams asking this question already have that, and the mistake repeats anyway.

No single session can see the pattern

In our experience, a mistake that happens once in each of five sessions looks like a one-off five times. The agent that made it may even mention it in its end-of-task reflection, but a reflection describes one session, and nothing inside any single session says the problem is a pattern.

Anthropic makes a similar point about its dreaming feature, which it says surfaces patterns that a single agent can't see on its own, including recurring mistakes.

The fix is cross-session learning: something that reads many sessions together. At Riibon, a nightly review reads the last seven days of every agent's tool calls and reflections, and counts a pattern only when it appears in at least three separate sessions, because one bad session is an anecdote.

The notes have gone bad

Memory does not only fail by being empty. Anthropic's dreams page says that over many sessions a memory store accumulates duplicates, contradictions and stale entries. Our reading: an agent that reads two notes saying opposite things has to pick one, and a note that was true in October is still read as true in December unless something retires it.

The fix is memory consolidation: merge the duplicates, settle the contradictions that can be settled, and retire what has expired. Our rule is that when two contradicting notes have no clear winner, nothing changes, because a guess written into memory is read as a fact by every session after it.

The mistake is in the tool, not the agent

In our experience, the repeated failures that cost the most time are often not reasoning mistakes at all. A tool rejects a date format, a data pull times out on its first try and works on the second, a lookup takes far longer than it should. Every session copes, and coping is what hides it.

An illustrative example, not a real incident: a data pull times out on its first try in a dozen sessions a week. No agent got anything wrong and no note would help, yet every one of those sessions loses time to it.

Our reading: teaching every agent to work around a broken tool is a patch. Fix the tool and the mistake disappears for every agent at once. At Riibon, a pattern that is plainly a tool bug becomes an engineering bug with the sessions and error text attached, not a lesson. One thing we learned building this: a failure that carries no error text cannot be learned from by anyone, so the error text has to be captured before any of this works.

Which one you have

Our own triage, not a platform's: the symptom points to the cause, and the cause decides whether the fix is memory at all.
What you seeLikely causeFix
The agent repeats a mistake you corrected in an earlier sessionThe correction was never saved, or is saved where the next session does not read itSave corrections to memory the agent reads at the start of every session
The same mistake shows up in many sessions but no session flags itNothing reads the sessions togetherA cross-session review of tool calls and reflections
The agent acts on an old or contradictory factDuplicate, contradicting or expired notesMemory consolidation, with every change logged and reversible
The same tool error or retry appears in many sessionsA broken or confusing toolFix the tool; do not teach every agent to work around it
Our own triage, not a platform's: the symptom points to the cause, and the cause decides whether the fix is memory at all.

Keeping the fix from becoming the next mistake

Our reading: a lesson an agent reads every morning becomes its habit, so a wrong lesson is worse than none. At Riibon, every proposed lesson carries the sessions it came from, a separate checker rules on it before it is saved, and every automatic change is logged and can be undone. A lesson only travels to other clients once names, figures, links and quotes are stripped out, and an agent may only edit its own client's memory.

Why does my AI agent keep making the same mistake?

Our reading: for one of four reasons. It never kept the lesson, no single session can see the mistake is a pattern, its notes have gone stale or contradict each other, or the mistake is in a tool it calls. Only the first and third are fixed by memory.

Will giving the agent memory stop repeated mistakes?

Only the ones caused by a lesson that was never kept, in our experience. A mistake that recurs across sessions needs something that reads the sessions together, and a broken tool needs fixing rather than remembering.

Does an agent learn by retraining the model?

Not in the setups described here. The agent improves because it reads better notes before it starts; the model itself does not change.

This is how we work, not only what we write about

Riibon's AI surfaces what it finds with the evidence attached, and a person decides. Recommendations are stress-tested before anyone acts on them, and every change is recorded with what happened afterwards.

Ask the Riibon app what changed in your account, and what happened next. Access starts with a short call: we look at your ads together, then run them for you or set the app up with you.

← All posts
Share this pageLinkedIn