MemBuilder: Reinforcing LLMs for Long-Term Memory Construction via Attributed Dense Rewards

AuthorsZhiyu Shen, Ziming Wu, Fuming Lai et al.

2026

TL;DR

MemBuilder uses Attributed Dense Rewards Policy Optimization with multi-dimensional memory to reach 84.23% on LoCoMo, +6.75 points over MIRIX.

SharePost on XLinkedIn

Read our summary here, or open the publisher PDF on the next tab.

THE PROBLEM

Sparse trajectory rewards hide which sessions matter in long-term dialogue

Long-term dialogue agents often receive a single reward at trajectory end, leaving MemBuilder unable to tell which memory operations helped or hurt.

This sparse feedback breaks credit assignment across dozens of sessions, so multi-session QA and temporal reasoning remain unreliable despite large context windows.

HOW IT WORKS

MemBuilder and Attributed Dense Rewards Policy Optimization

MemBuilder combines Multi-Dimensional Memory Architecture, Supervised Fine-Tuning, and Attributed Dense Rewards Policy Optimization so Qwen3-4B can manage Core, Episodic, Semantic, and Procedural memory.

Think of MemBuilder as a hybrid between RAM and a card catalog, where dense questions probe each session’s memory and gradients are scaled by how often components are retrieved.

This design lets MemBuilder build structured external memory that supports cross-session, temporal, and adversarial QA far beyond what a plain context window or naive RAG can handle.

DIAGRAM

Session level training loop with synthetic QA and ADRPO

This diagram shows how MemBuilder uses synthetic session-level QA and Attributed Dense Rewards Policy Optimization to train memory construction.

DIAGRAM

Evaluation pipeline across LongMemEval, LoCoMo, and PerLTQA

This diagram shows how MemBuilder is trained on LongMemEval and evaluated on LoCoMo and PerLTQA with fixed answer models and baselines.

PROCESS

How MemBuilder Handles a Long-Term Dialogue Question Answering Session

  1. 01

    Multi-Dimensional Memory Architecture

    MemBuilder decomposes the dialogue into Core Memory, Episodic Memory, Semantic Memory, and Procedural Memory, structuring events, facts, and routines for later retrieval.

  2. 02

    Supervised Fine-Tuning

    MemBuilder uses expert trajectories from Claude 4.5 Sonnet to learn valid JSON actions and operation types for each memory component before reinforcement learning.

  3. 03

    Attributed Dense Rewards Policy Optimization

    MemBuilder applies ADRPO with synthetic session-level QA, format validity gating, and length penalties to update memory policies using dense rewards.

  4. 04

    Contribution-Aware Gradient Weighting

    MemBuilder scales gradients for Episodic, Semantic, and Procedural Memory based on retrieval counts, amplifying the dominant contributor while keeping Core Memory weight fixed.

KEY CONTRIBUTIONS

Key Contributions

  • 01

    Multi-Dimensional Memory Architecture

    MemBuilder defines Core Memory, Episodic Memory, Semantic Memory, and Procedural Memory, enabling a 4B model to reach 84.23% on LoCoMo with structured external memory.

  • 02

    Attributed Dense Rewards Policy Optimization

    MemBuilder introduces ADRPO with synthetic session-level QA, format validity gating, and length penalties to replace sparse trajectory rewards in long-term dialogue training.

  • 03

    Contribution-Aware Gradient Weighting

    MemBuilder weights gradients by retrieval-based contribution, using α = 4 to raise LoCoMo accuracy from 82.82% to 84.04% in ablations.

RESULTS

By the Numbers

LoCoMo accuracy

84.23%

+6.75 over MIRIX

LongMemEval accuracy

85.75%

+12.75 over RAG Session

PerLTQA accuracy

93.14%

+13.93 over RAG Session

Parameter count

4B

Qwen3 4B Instruct base size for MemBuilder

MemBuilder is trained only on LongMemEval yet evaluated on LoCoMo and PerLTQA, which test multi-session QA, temporal reasoning, and evolving user profiles. The 84.23% LoCoMo result shows MemBuilder can beat prompting frameworks using Claude 4.5 Sonnet while running on a 4B open-source backbone.

BENCHMARK

By the Numbers

MemBuilder is trained only on LongMemEval yet evaluated on LoCoMo and PerLTQA, which test multi-session QA, temporal reasoning, and evolving user profiles. The 84.23% LoCoMo result shows MemBuilder can beat prompting frameworks using Claude 4.5 Sonnet while running on a 4B open-source backbone.

BENCHMARK

LoCoMo benchmark comparison for memory construction methods

Accuracy on LoCoMo multi-session dialogue QA.

KEY INSIGHT

The Counterintuitive Finding

MemBuilder trained with both SFT and RL reaches 84.23% on LoCoMo, while RL alone drops to 79.31%, below the 81.74% SFT-only baseline.

This is surprising because many assume more RL always helps, but MemBuilder shows that dense rewards without a strong supervised cold-start can actually hurt performance.

WHY IT MATTERS

What this unlocks for the field

MemBuilder proves that a 4B open-source model can handle long-term memory construction with dense rewards and multi-dimensional attribution, rivaling closed-source prompting systems.

Builders can now deploy cost-effective agents that maintain structured, evolving memories across thousands of tokens, enabling robust multi-session QA and temporal reasoning without relying on expensive APIs.

~13 min read← Back to papers

Related papers

Agent MemoryLong-Term Memory

Adaptive Memory Admission Control for LLM Agents

Guilin Zhang, Wei Jiang et al.

· 2026

A-MAC scores candidate memories using Utility, Confidence, Novelty, Recency, and Type Prior combined by a learned linear admission policy with Algorithm 1 A-MAC Memory Admission. On the LoCoMo benchmark, A-MAC achieves F1 0.583 and 2644 ms latency, improving F1 by 0.042 and reducing latency by 1187 ms compared to A-mem.

Long-Term Memory

Advancing Open-source World Models

Robbyant Team, Zelin Gao et al.

arXiv 2026 · 2026

LingBot-World combines a Data Engine, Fundamental World Model, Action-Conditioned World Model, and Post-Training causal adaptation to turn a 28B-parameter video generator into a real-time interactive world simulator. On the VBench benchmark, LingBot-World achieves a dynamic degree of 0.8857 versus 0.7612 for Yume-1.5, while also improving imaging quality to 0.6683.

BenchmarkBenchmarkLong-Term Memory

AgenticAI-DialogGen: Topic-Guided Conversation Generation for Fine-Tuning and Evaluating Short- and Long-Term Memories of LLMs

Manoj Madushanka Perera, Adnan Mahmood et al.

· 2026

AgenticAI-DialogGen chains ChatPreprocessor, KnowledgeExtractor, TopicAnalyzer, KnowledgeGraphBuilder, PersonaGenerator, DuelingChat Agent, ConversationValidator, ConversationRefiner, QAGeneration, and PostProcessing to turn raw multi-session chats into topic-guided, persona-grounded conversations with explicit short- and long-term memories. On the TGC / KG memory QA benchmark, Mistral-7B fine-tuned within AgenticAI-DialogGen achieves 87.36 F1, compared to GPT-4’s 83.77 F1 in a zero-shot setting on the same task.

Questions about this paper?

Paper: MemBuilder: Reinforcing LLMs for Long-Term Memory Construction via Attributed Dense Rewards

Answers use this explainer on Memory Papers.

Checking…