Research

MachinoAI Research

EMERGINGAI Agents

ReasoningBank: Scaling Agent Self-Evolving with Reasoning Memory

ReasoningBank turns agent successes and failures into reusable reasoning strategies that improve future tasks without updating model weights.

Siru Ouyang, Jun Yan, I-Hung Hsu, Yanfei Chen, Ke Jiang, Zifeng Wang, Rujun Han, Long T. Le, Samira Daruki, Xiangru Tang, Vishy Tirumalashetty, George Lee, Mahsan Rofouei, Hangfei Lin, Jiawei Han, Chen-Yu Lee, Tomas PfisterMar 16, 2026ICLR 202612 min read
AI Agentsagent memoryself-evolving agentstest-time learningtest-time scalingweb agentssoftware engineeringreasoning memoryfailure learningmemory retrieval

TL;DR

The system retrieves relevant memory, judges outcomes, extracts strategy or failure lessons, and consolidates them into an evolving memory bank; MaTTS makes additional test-time exploration feed higher-quality memories back into the loop.

Why It Matters

Persistent agents need a learning substrate between model weights and raw logs. ReasoningBank shows how structured memory can convert experience—including failures—into reusable operational knowledge and combine with test-time scaling.

Research Brief

The shortest useful explanation.

The system retrieves relevant memory, judges outcomes, extracts strategy or failure lessons, and consolidates them into an evolving memory bank; MaTTS makes additional test-time exploration feed higher-quality memories back into the loop.

reasoning memoryfailure learningmemory retrievalmemory consolidationMaTTSexperience scalingagent memoryself-evolving agents

Core Explanation

ReasoningBank distills reusable reasoning strategies from both successful and failed agent trajectories, retrieves relevant memories for future tasks, and consolidates new memory items after each task. MaTTS extends test-time scaling by using multiple or sequential trajectories as contrastive signals for better memory construction.

Why It Matters

Persistent agents need a learning substrate between model weights and raw logs. ReasoningBank shows how structured memory can convert experience—including failures—into reusable operational knowledge and combine with test-time scaling.

ReasoningBank induces reusable reasoning strategies and increases cumulative successful tasks.

ReasoningBank cumulative improvement

Original arXiv figure showing ReasoningBank cumulative successful tasks compared with no memory.

ReasoningBank retrieves memory, judges trajectories, extracts strategies, and consolidates memory items.

ReasoningBank closed loop

Original arXiv figure showing memory retrieval, extraction, LLM judging, and consolidation.

MaTTS uses self-contrast for parallel trajectories and self-refinement for sequential scaling.

MaTTS

Original arXiv figure comparing vanilla test-time scaling with parallel and sequential memory-aware scaling.

Section 01

Problem

01. Problem

Persistent agents repeatedly encounter related tasks but usually do not convert experience into reusable reasoning knowledge. Raw trajectories are long and noisy, while success-only workflow memory discards lessons contained in failures. ReasoningBank addresses the missing learning layer by distilling strategies and failure lessons into structured memory items.

1Agents repeat mistakes across tasks.2Raw trajectory memory is too detailed and noisy.3Success-only memory misses failure-derived guardrails.

Section 02

How It Works

03. How It Works

For each streaming task, the agent retrieves top-k relevant memory items using embedding similarity and injects them into the system instruction. After completion, an LLM-as-a-judge labels the trajectory as success or failure. Successful trajectories yield validated strategies; failures yield pitfalls and counterfactual lessons. The resulting items are consolidated into the memory bank. MaTTS performs parallel self-contrast or sequential self-refinement so extra trajectories create stronger memory.

1Retrieve top-k memories before acting.2Judge trajectory outcome without external ground-truth labels.3Extract strategies from successes and pitfalls from failures.4Consolidate new memory items.5Use MaTTS parallel contrast or sequential refinement to improve memory induction.

Section 03

Architecture

05. Architecture

ReasoningBank has three operational stages around each task: memory retrieval, memory extraction, and memory consolidation. The stored item has title, description, and content. The implementation intentionally keeps retrieval as embedding-based top-k similarity and consolidation simple to isolate memory-content quality. MaTTS adds either parallel self-contrast or sequential self-refinement.

1Memory store: structured strategy items.2Retriever: embedding similarity top-k.3Agent: receives retrieved items as system context.4Judge: self-evaluates success/failure.5Extractor: produces reusable reasoning items.6Consolidator: updates the memory repository.

Section 04

Experiments

06. Experiments

The authors evaluate on WebArena, Mind2Web, and SWE-Bench-Verified using Gemini-2.5 and Claude-3.7. WebArena covers Shopping, Admin, GitLab, Reddit, and Multi subsets. Metrics include success rate and average steps. The paper reports consistent gains across backbone models and datasets.

1WebArena Gemini-2.5-Flash overall: No Memory 40.5 SR/9.7 steps; ReasoningBank 48.8 SR/8.3 steps; MaTTS k=5 51.8 SR/7.9 steps.2WebArena Gemini-2.5-Pro overall: No Memory 46.7/8.8; ReasoningBank 53.9/7.4; MaTTS k=5 56.3/7.1.3SWE-Bench-Verified Gemini-2.5-Flash: No Memory 34.2 resolve rate/30.3 steps; ReasoningBank 38.8/27.5.4SWE-Bench-Verified Gemini-2.5-Pro: No Memory 54.0/21.1; ReasoningBank 57.4/19.8.5Gemma-3-12B WebArena-Shopping: No memory 17.1% SR/13.7 steps; ReasoningBank 24.1%/11.8.

Formulas

Agent policy with memory

pimathcalL(cdotmathcalM,mathcalA)\\pi_{\\mathcal L}(\\cdot|\\mathcal M,\\mathcal A)

The agent policy is parameterized by the backbone LLM and conditioned on the memory module and available actions.

Aaction space
Lbackbone language model
MReasoningBank memory

Environment transition

mathcalT(st+1st,at)\\mathcal T(s_{t+1}|s_t,a_t)

The environment transition maps the current state and chosen action to the next state.

Tenvironment transition function
a_taction selected at time t
s_tstate at time t

MaTTS scaling factor

k=textnumberoftrajectoriesforparallelscalingorrefinementstepsforsequentialscalingk=\\text{number of trajectories for parallel scaling or refinement steps for sequential scaling}

k controls how much additional test-time experience is generated for memory-aware scaling.

kparallel trajectory count or sequential refinement count

Related Research

References