Table of Contents
Fetching ...

MAGMA: A Multi-Graph based Agentic Memory Architecture for AI Agents

Dongming Jiang, Yi Li, Guanpeng Li, Bingzhe Li

TL;DR

MAGMA tackles the challenge of long-horizon reasoning in LLMs by introducing a multi-graph agentic memory that disentangles semantic, temporal, causal, and entity relations. It employs a dual-stream architecture to decouple lightweight memory ingestion from heavy relational inference, enabling millisecond-level responsiveness while progressively enriching memory structure via asynchronous consolidation. The adaptive traversal policy guides retrieval across orthogonal graphs, yielding transparent reasoning paths and reduced token usage. Empirical results on LoCoMo and LongMemEval show MAGMA outperforms state-of-the-art memory systems in accuracy and efficiency, with strong temporal grounding and robustness to adversarial queries. The approach offers a scalable, interpretable memory substrate for AI agents, with open-source implementation for broader adoption.

Abstract

Memory-Augmented Generation (MAG) extends Large Language Models with external memory to support long-context reasoning, but existing approaches largely rely on semantic similarity over monolithic memory stores, entangling temporal, causal, and entity information. This design limits interpretability and alignment between query intent and retrieved evidence, leading to suboptimal reasoning accuracy. In this paper, we propose MAGMA, a multi-graph agentic memory architecture that represents each memory item across orthogonal semantic, temporal, causal, and entity graphs. MAGMA formulates retrieval as policy-guided traversal over these relational views, enabling query-adaptive selection and structured context construction. By decoupling memory representation from retrieval logic, MAGMA provides transparent reasoning paths and fine-grained control over retrieval. Experiments on LoCoMo and LongMemEval demonstrate that MAGMA consistently outperforms state-of-the-art agentic memory systems in long-horizon reasoning tasks.

MAGMA: A Multi-Graph based Agentic Memory Architecture for AI Agents

TL;DR

MAGMA tackles the challenge of long-horizon reasoning in LLMs by introducing a multi-graph agentic memory that disentangles semantic, temporal, causal, and entity relations. It employs a dual-stream architecture to decouple lightweight memory ingestion from heavy relational inference, enabling millisecond-level responsiveness while progressively enriching memory structure via asynchronous consolidation. The adaptive traversal policy guides retrieval across orthogonal graphs, yielding transparent reasoning paths and reduced token usage. Empirical results on LoCoMo and LongMemEval show MAGMA outperforms state-of-the-art memory systems in accuracy and efficiency, with strong temporal grounding and robustness to adversarial queries. The approach offers a scalable, interpretable memory substrate for AI agents, with open-source implementation for broader adoption.

Abstract

Memory-Augmented Generation (MAG) extends Large Language Models with external memory to support long-context reasoning, but existing approaches largely rely on semantic similarity over monolithic memory stores, entangling temporal, causal, and entity information. This design limits interpretability and alignment between query intent and retrieved evidence, leading to suboptimal reasoning accuracy. In this paper, we propose MAGMA, a multi-graph agentic memory architecture that represents each memory item across orthogonal semantic, temporal, causal, and entity graphs. MAGMA formulates retrieval as policy-guided traversal over these relational views, enabling query-adaptive selection and structured context construction. By decoupling memory representation from retrieval logic, MAGMA provides transparent reasoning paths and fine-grained control over retrieval. Experiments on LoCoMo and LongMemEval demonstrate that MAGMA consistently outperforms state-of-the-art agentic memory systems in long-horizon reasoning tasks.
Paper Structure (32 sections, 8 equations, 3 figures, 9 tables, 3 algorithms)

This paper contains 32 sections, 8 equations, 3 figures, 9 tables, 3 algorithms.

Figures (3)

  • Figure 1: High-Level Architecture of Memory-Augmented Generation (MAG).
  • Figure 2: Architectural Overview of MAGMA. The system is composed of three layers: (1) A Query Process that routes and synthesizes context; (2) A Data Structure Layer organizing memory into Relation Graphs and a Vector Database; and (3) A Write/Update Process utilizing a dual-stream mechanism for fast ingestion and asynchronous consolidation.
  • Figure 3: Query process with adaptive hybrid retrieval pipeline. (1) Query Analysis detects intent and fuses signals to find Anchors. (2) Adaptive Traversal navigates specific graph views (Causal, Temporal) based on the policy weights.