Source-linked AI summary

EngramRAG: Dynamic Usage-Weighted Topology and Synaptic Consolidation for Multi-Hop Agentic Memory

Bhavyateja Potineni, Lohit Giri, Anu Jain, Vadim Kutsyy, Rajasekhar Pentakota

arXiv:2609.32049v1cs.AIcs.CLcs.IRcs.MA

TL;DR

Long-term conversational agents need memory that supports multi-hop relations, preserves foundational facts, and adapts to usage and mutations. EngramRAG combines usage-modulated graph retrieval, topology-aware retention, mutation filtering, and asynchronous consolidation; its LoCoMo evaluation reports stronger results on temporal reasoning and multi-session reasoning than dense-vector retrieval.

  • Problem

    Long-term agent memory faces associative blindness, scaffolding amnesia, and static graph topology across multi-session conversations.

    Source: §I · p. 1
  • Method

    EngramRAG couples usage-modulated Hebbian graph retrieval and macro-hub identification with topology-aware retention and a two-state memory lifecycle.

    Source: §I · pp. 1–2, B. Usage-Modulated Personalized… · p. 4, C. Epistemic Macro-Hub Identification · p. 4
  • Results

    EngramRAG achieves 62.33% Recall@5 in temporal reasoning versus 45.66% for Dense Vector, and 25.25% in multi-session reasoning versus 19.47% for Dense Vector.

    Source: B. Overall Benchmark Results · p. 5
  • Takeaways & Limitations

    The LoCoMo evaluation reports statistically significant gains over dense vector, BM25, and static graph baselines while maintaining a 26.21ms retrieval reflex.

    Source: §VII · p. 8

Abstract

from arXiv · show

As autonomous LLM agents are deployed across multi-session environments, conventional memory architectures suffer from Associative Blindness (inability to traverse multi-hop relational dependencies), Scaffolding Amnesia (temporal decay evicting core persona invariants), and Static Topology Stagnation (immutable graphs ignoring usage dynamics). Grounded in Complementary Learning Systems (CLS) principles, we propose EngramRAG, an adaptive memory architecture coupling a low-latency Waking State reflex with an asynchronous background Dreaming State consolidation cycle. EngramRAG introduces: (1) Usage-Modulated Personalized PageRank (U-PPR), where transition probabilities adapt via Hebbian plasticity to promote persistent entities into high-centrality Epistemic Macro-Hubs; (2) Consolidation-Activated Topology Decay (CATD), which scales retention half-life by topological load-bearing weight rather than wall-clock recency, protected by a cold-start grace period (N_grace >= 4); (3) Directed SUPERSEDES DAG filtering to suppress obsolete state during fact mutations; and (4) Triple-source hybrid retrieval fusing dense vectors, BM25, and U-PPR via dynamic Reciprocal Rank Fusion (RRF). Evaluating on all 1,982 QA pairs across 10 long-term conversations in the LoCoMo benchmark, EngramRAG achieves +38.9% relative improvement in Recall@5 (53.21% vs. 38.29%, p < 0.001) and +43.1% in MRR (0.4203 vs. 0.2937) over dense vector RAG, significantly outperforming Okapi BM25 (48.66%) and isolated static graph retrieval (8.50%). On temporal reasoning, EngramRAG reaches 62.33% Recall@5 (+16.67 points over dense vectors). In controlled mutation tests, SUPERSEDES suppresses split-brain hallucinations from 70.0% to 0.0%, while 90-day simulations show 100.0% scaffolding retention under a 26.21ms interactive retrieval reflex.

I. INTRODUCTION

Existing agent-memory approaches struggle with multi-hop links, preserving foundational facts, and adapting graph structure to usage or mutations. EngramRAG combines usage-sensitive retrieval, topology-aware retention, and mutation filtering in a dual-state architecture.

I. INTRODUCTION

  • Associative blindness, scaffolding amnesia, and static topology stagnation limit conventional memory across long-term conversational deployments.The cited approaches include flat vector retrieval, OS-inspired paging, and static knowledge-graph retrieval.Source: §I · p. 1
  • EngramRAG uses co-retrieval and operational access signals to strengthen edges between co-activated concepts.Source: §I · p. 1
  • U-PPR combines query semantics with access intensity to identify Epistemic Macro-Hubs.Source: §I · p. 2
  • CATD scales memory half-life by structural load-bearing centrality, while SUPERSEDES DAG filtering suppresses obsolete state during fact mutations.Source: §I · p. 2
  • Evaluation across 1,982 LoCoMo questions reports gains under a 26.21ms interactive reflex.The taxonomy lists dynamic Hebbian plasticity, consolidation-activated retention, asynchronous processing, and directed mutation tracking under sub-30ms retrieval budgets.Source: §I · p. 2, Table I · p. 2

II. RELATED WORK

Prior memory systems use vector, paging, or static-graph approaches, while EngramRAG adds adaptive topology and pruning. Its architecture separates live ingestion and hybrid retrieval from asynchronous consolidation.

II. RELATED WORK

  • Dense vectors and BM25 support complementary retrieval, while RRF combines their ordinal ranks because their raw scores are incomparable.Dense-vector search uses HNSW, BM25 is Okapi retrieval, and RRF aggregates ranks.Source: §II · p. 2
  • HippoRAG and GraphRAG [3] use graph-based memory, but the cited systems lack operational usage feedback, dynamic plasticity, and active pruning.The comparison describes HippoRAG’s OpenIE graph and Personalized PageRank, and GraphRAG’s community summaries [10].Source: §II · p. 2

III. THE ENGRAMRAG ARCHITECTURE

  • EngramRAG couples a low-latency Waking State reflex with asynchronous Dreaming State consolidation.This separates the interactive retrieval path from background work.Source: §III · p. 2, §II · p. 2

A. Waking State: Ingestion and Retrieval Reflex

  • The Waking State triages utterances, deduplicates incoming facts, writes asynchronously to vector and graph stores, and fuses dense, BM25, and U-PPR retrieval with dynamic RRF.Source: A. Waking State: Ingestion and… · p. 2

B. Dreaming State: Offline Synaptic Consolidation

Dreaming State performs graph consolidation asynchronously, including clustering, community partitioning, macro-hub detection, and CATD pruning. The accompanying storage design separates vector and document retrieval from relational graph operations and background event processing.

B. Dreaming State: Offline Synaptic Consolidation

C. Distributed Systems Architecture & Storage Engine Specs

  • The storage design assigns real-time vectors and BM25 indexes to Redis Stack, typed relational edges to Neo4j, and ingestion events to asynchronous Redis Streams.The clustering engine uses SCAN with HNSW acceleration and consolidates clusters using historical access counts and stationary PageRank centrality.Source: C. Distributed Systems Architecture &… · p. 3

IV. MATHEMATICAL FORMULATION

EngramRAG updates graph-edge weights through conversational co-activation, then uses query-personalized PageRank and a two-phase lifecycle to retrieve and consolidate memory.

A. Dynamic Hebbian Usage Plasticity

  • Co-retrieved entity pairs update directed edge weights through Hebbian co-activation, with structural relation priors and episode timestamps contributing to the weighting.The weighting hyperparameters are α = 0.4, β = 0.4, and γ = 0.2; SUPERSEDES has a structural prior of 2.5.Source: A. Dynamic Hebbian Usage Plasticity · p. 3

B. Usage-Modulated Personalized PageRank (U-PPR)

  • The transition matrix row-normalizes graph weights, while query personalization balances semantic relevance with historical access and access recency.A uniform fallback is used if the query denominator vanishes.Source: B. Usage-Modulated Personalized… · pp. 3–4
  • The waking reflex retrieves vector, BM25, and graph contexts, filters superseded graph nodes, and ranks the combined candidates with reciprocal-rank fusion.The algorithm returns the top-K contexts and an updated graph.Source: B. Usage-Modulated Personalized… · p. 4
  • The dreaming cycle processes queued mutations, deduplicates entities, merges clusters by access count and PageRank, and updates global macro-hubs.It also partitions the graph with Louvain and applies topology-based decay and eviction after the grace period.Source: B. Usage-Modulated Personalized… · p. 4
  • U-PPR obtains a query-conditioned stationary probability distribution by solving its fixed-point equation with damping factor d = 0.85.The solution uses power iteration.Source: B. Usage-Modulated Personalized… · p. 4
  • Logarithmic access scaling and temporal discounting limit runaway hub capture, while the semantic prior preserves exploration entropy.The passage describes this as entropy regularization against “rich-get-richer” effects.Source: B. Usage-Modulated Personalized… · p. 4

C. Epistemic Macro-Hub Identification

Epistemic Macro-Hubs are highly central, sufficiently connected nodes that act as structural transit anchors during spreading activation.

C. Epistemic Macro-Hub Identification

  • Nodes whose global stationary centrality exceeds the population mean by the stated threshold and have degree at least 3 qualify as Epistemic Macro-Hubs.The population mean is computed over nodes’ global stationary centralities.Source: C. Epistemic Macro-Hub Identification · p. 4
  • Global stationary centrality is computed over the graph using a uniform teleportation prior.The identified nodes are selected for centrality above the population mean together with requisite degree connectivity.Source: C. Epistemic Macro-Hub Identification · p. 4
  • The degree and centrality cutoffs are empirical heuristics that isolate the top 5–8% of structural transit anchors.The stated purpose is to preserve global semantic cohesion during spreading activation.Source: C. Epistemic Macro-Hub Identification · p. 5

D. Consolidation-Activated Topology Decay (CATD)

CATD applies decay during consolidation and adjusts effective decay rates using each node’s topological load-bearing score, with a cold-start grace period before eviction.

D. Consolidation-Activated Topology Decay (CATD)

  • Decay occurs strictly during consolidation cycles rather than continuously with wall-clock time.This design is intended to protect foundational knowledge from wall-clock amnesia.Source: D. Consolidation-Activated Topology… · p. 5
  • The topology score combines relative global centrality with a fact-type prior, which assigns identity, preference, and episodic facts values of 1.0, 0.8, and 0.2.The expected relative centrality ratio is 1.0.Source: D. Consolidation-Activated Topology… · p. 5
  • The effective decay rate is λeff(v) = λbase(type(v)) · exp(−2.0 · Scoretopology(v)), reducing decay as topological load-bearing score rises.The base rate is parameterized by fact type.Source: D. Consolidation-Activated Topology… · p. 5
  • The decay weights are empirically parameterized, and learning retention policies from user corrections is identified as a natural extension.Base rates are 0.0001 for identity, 0.0008 for preference, and 0.08 for episodic facts.Source: D. Consolidation-Activated Topology… · p. 5
  • Physical eviction is protected by an Ngrace ≥4 cycle cold-start grace period.The algorithm checks that a node’s age exceeds the grace period before eviction.Source: D. Consolidation-Activated Topology… · p. 5

E. Computational Complexity and Scaling Analysis

The reported waking reflex averages 26.21 ms, while graph propagation and storage costs are reported separately for synthetic scaling and multi-year histories.

E. Computational Complexity and Scaling Analysis

  • 26.21 ms is the average complete interactive reflex latency, within the stated sub-30ms budget.The reflex includes embedding, HNSW, BM25, and U-PPR.Source: E. Computational Complexity and… · p. 5
  • U-PPR graph propagation takes 4–6 ms at |V| = 1,000 and approximately 50 ms at |V| = 10,000 with 59,980 edges on a single-thread CPU.The isolated propagation test reports sub-10 ms performance at 1,000 nodes.Source: E. Computational Complexity and… · p. 5
  • Incremental HNSW-DBSCAN uses O(N log N), Louvain uses O(|E|), and multi-year histories consume under 50 MB in the reported storage setup.Node embeddings use O(|V|·dembed) storage and dynamic adjacency uses O(|E|) sparse representation.Source: E. Computational Complexity and… · p. 5

V. EXPERIMENTAL EVALUATION

The evaluation tests retrieval across LoCoMo’s multi-session tasks against dense-vector, BM25, and static-graph baselines.

A. LoCoMo Benchmark Setup

  • The benchmark covers 1,982 questions from 10 multi-session dialogues across factual, temporal, multi-session, multi-hop, and conversational tasks.Comparisons include Dense Vector RAG, BM25, and a static Personalized PageRank graph baseline without online plasticity or hybrid fusion.Source: A. LoCoMo Benchmark Setup · p. 5
  • Table II reports retrieval performance on all 1,982 questions, with paired significance tests against Dense Vector and BM25 and errors clustered by dialogue trajectory.The supplied table description does not provide the performance values.Source: Table II · p. 5
  • Table III presents category-wise Recall@5 across the full benchmark and marks the top-performing model in each category.The supplied table description does not provide the category values.Source: Table III · p. 5

B. Overall Benchmark Results

EngramRAG leads on several LoCoMo reasoning categories, retains foundational facts in a 90-day simulation, and suppresses conflicting-state hallucinations in mutation tests.

B. Overall Benchmark Results

  • 62.33% Recall@5 on temporal reasoning and 61.18% on multi-hop inference show EngramRAG outperforming Dense Vector and BM25 on both categories.Dense Vector leads factual recall narrowly at 22.13% versus EngramRAG’s 21.89%.Source: B. Overall Benchmark Results · p. 5

C. Longitudinal Continuous Deployment Simulation (SCDP)

  • 100.0% scaffolding retention preserves medical invariants and core identity while pruning transient debugging noise during the 90-day simulation.Epistemic Macro-Hubs emerge with centrality π*(v) ≈ 0.26 as stable anchors across multi-turn sessions.Source: C. Longitudinal Continuous Deployment… · p. 6

D. Knowledge Update and Contradiction Resolution

E. Downstream Closed-Loop LLM Generation

EngramRAG improves temporal downstream F1, although other generation metrics remain near baseline parity; a multi-session case traces how graph retrieval recovers a dietary constraint missed by vector retrieval.

E. Downstream Closed-Loop LLM Generation

F. Qualitative Dialogue Case Study & Associative Path Tracing

  • Dense Vector RAG ranks the celiac constraint 47th at similarity 0.28, outside the top five, and consequently omits the dietary restriction from its recommendation.The example links a Session 3 health constraint to a Session 28 dining query.Source: F. Qualitative Dialogue Case Study &… · p. 7
  • U-PPR propagates activation from the restaurant query through the User Health Constraints hub to the celiac fact, which reaches rank one via RRF.The generated response cautions that traditional deep-dish pizza contains gluten and suggests verifying gluten-free crust availability.Source: F. Qualitative Dialogue Case Study &… · p. 7

G. Error Analysis and Failure Taxonomy

Error analysis identifies cases favoring exact-match dense retrieval and lexical BM25, while ablations test routing, grace periods, and parameter sensitivity; the conclusion reports significant benchmark gains and flags future work.

G. Error Analysis and Failure Taxonomy

  • 61.18% Recall@5 for EngramRAG exceeds BM25’s 56.58% on multi-hop inference, where rare names and codes benefit from lexical precision combined with graph hops.Dense Vector narrowly leads factual recall, 22.13% to 21.89%, when queries closely match source phrasing.Source: G. Error Analysis and Failure Taxonomy · p. 7
  • 7B instruction readers show a Token F1 plateau despite upstream recall gains, with attention dilution from rich multi-hop graph contexts identified as a challenge.Prioritized linear sub-path formatting is proposed as a future optimization avenue.Source: G. Error Analysis and Failure Taxonomy · p. 7

VI. ABLATION STUDIES

  • Ngrace = 4 yields 96.0% survival, exceeding the 95% safety threshold, whereas Ngrace = 1 yields 42.0% survival before facts can be wired into the graph.The cold-start grace period protects newly introduced facts until a dreaming cycle can connect them.Source: §VI · p. 8
  • Dynamic intent routing raises Multi-Session Recall@5 from 22.75% to 23.53% and Recall@1 from 22.25% to 22.73% versus static RRF weights.Hebbian plasticity’s reported utility is long-term scaffolding stability rather than instantaneous single-turn retrieval.Source: §VI · p. 8
  • Recall@5 stays at 43.39% for damping factors d = 0.65–0.85 and reaches 42.59% at d = 0.95; RRF smoothing is robust across k = 40–100.The chosen default k = 60 reaches 43.39% Recall@5.Source: §VI · p. 8

VII. CONCLUSION

  • The LoCoMo evaluation covers 1,982 questions across 10 conversations and reports significant gains over dense-vector, BM25, and static-graph baselines with a 26.21ms retrieval reflex.The conclusion identifies noisy-retrieval feedback stability, query-conditioned subgraph decomposition, and path-constrained traversal as future work.Source: §VII · p. 8
Loading 2609.32049v1…