TANSAR: Editable and Attributable Correlation Matrix Memories under Correlated Keys, with Rule-Constrained Multi-Hop Knowledge Editing

Abdulhady Abas Abdulla, Jiyan Salim Mahmud, Fatemeh Daneshfar, Hussein Mohammed Ali, Mourad Oussalah, Muhammad BilalarXiv 2026

TL;DR

TANSAR is a neuro-symbolic framework that provides a precise, attributable, and editable external memory for frozen Large Language Models (LLMs). By combining Correlation Matrix Memories (CMMs) with symbolic rule pruning, it virtually eliminates contradictions in multi-hop reasoning and enables exact, instant knowledge deletion without retraining.

What Problem Does This Paper Address?

Updating the knowledge within an LLM—a process called knowledge editing—is notoriously difficult. Current methods often struggle with two main issues:

  1. Multi-hop Consistency: If you update a fact (e.g., "The CEO of X is now Alice"), the model might still use stale information for related questions (e.g., "Who is Alice's predecessor?").
  2. Exact Unlearning: Most models cannot "forget" a specific fact perfectly; removing one piece of information often subtly corrupts others.

While Correlation Matrix Memories (CMMs) offer a potential solution due to their additive nature (allowing for exact deletion), their classical theory assumes that "keys" are random and orthogonal. In reality, semantic embeddings are highly correlated, leading to "crosstalk" or interference that degrades memory performance. This paper bridges the gap between CMM theory and the reality of correlated semantic keys.

Methods

The authors introduce TANSAR (Topology-Aware Neuro-Symbolic Associative Retrieval), which treats memory as a dynamic, verifiable graph rather than a static lookup table.

Figure 1: Overview of TANSAR. The language-model state is mapped by the learned alignment A to a query q that addresses the explicit associative memory: a CMM of rank-one associations (C = P

Key components include:

  • CMM Storage: Associations are stored as rank-one outer products. This allows a new fact to be added by simple addition and removed by simple subtraction.
  • Retrieval Engine: Instead of a simple similarity search, TANSAR uses Graph Diffusion to find paths of related facts. It then applies Constraint Pruning using symbolic logic (ground Horn clauses) to filter out any paths that contradict known rules or newly edited facts.
  • Query-Key Alignment: A contrastively trained linear map (using InfoNCE loss) aligns the LLM's internal hidden states with the semantic key space of the memory.
  • Calibrated Gating: A "transparency gate" uses a Clopper–Pearson selective-risk certificate to decide whether the retrieved information is reliable enough to inject into the LLM's residual stream.

Datasets

The researchers evaluated TANSAR using several benchmarks:

  • ProofWriter: Used to test symbolic rule verification across 600 theories.
  • FOLIO: A natural language reasoning dataset used to test agreement with gold labels.
  • Custom Multi-hop Benchmark (E6): A structured fact graph with 1,200 entities and 3,000 facts, specifically designed to test how edits propagate through multi-step reasoning chains.

Key Insights and Ideas

  • The Capacity of Correlated Keys: The authors provide new theoretical bounds proving that CMMs have a fundamental capacity limit even with correlated keys. Crucially, they show that mean-centering keys (subtracting the average embedding) significantly reduces crosstalk and improves capacity.
  • Deletion Safety: A major "aha" moment is the proof that in a CMM, deleting one association is guaranteed never to invalidate other previously certified associations. This is a property that softmax-based memories (like modern Hopfield networks) do not share.
  • Neuro-Symbolic Synergy: Neural retrieval provides the "candidates," but symbolic logic provides the "truth." The paper shows that symbolic pruning is the critical component that prevents the model from hallucinating stale, retracted knowledge during multi-hop reasoning.

Key Results

TANSAR demonstrates state-of-the-art performance in controlled knowledge editing scenarios:

  • Contradiction Reduction: In multi-hop tasks, TANSAR reduced answer contradictions from 25.1% down to just 0.5%.
  • Efficiency: Edit transactions are incredibly fast, requiring only 13.6 ms on a standard CPU and 2.37 ms on a GPU, making it viable for real-time applications.
  • Reasoning Accuracy: The system achieved 100% accuracy on ProofWriter and 94% on FOLIO, demonstrating that the symbolic component is robust.
  • Design Superiority: As shown in the design comparison table, TANSAR is the only method that satisfies requirements for gradient-free updates, exact deletion, additive decomposition, and explicit constraint checking simultaneously.
Design-level comparison of TANSAR against other knowledge editing and memory methods.

Limitations and Future Work

  • Worst-Case Bounds: The theoretical coherence bounds are conservative; the system often performs better in practice than the "guaranteed" limits suggest.
  • Grounding Complexity: The symbolic component currently uses ground Horn clauses. While efficient, scaling this to massive first-order logic rule sets requires significant grounding overhead.
  • Fixed-Path Decoding: The retrieval path is selected based on the initial prompt. If the LLM's generation diverges significantly from that path later in the sequence, the injected memory may become less relevant.
  • Scaling: While tested with up to 20,000 associations, future work is needed to evaluate hierarchical routing for even larger-scale "life-long" memories.

Summary updated

Abstract

Correlation Matrix Memories (CMMs) store associations as sums of rank-one outer products, providing closed-form addressability, exact deletion, and linear attribution. While classical analyses assume random, orthogonal keys, semantic encoders produce correlated representations. We analyse CMMs under correlated keys using frame-theoretic coherence: (i) capacity bounds yielding an encoder-independent limit $n \le d(1+\varepsilon^2)$ for mean squared crosstalk $\varepsilon^2$; (ii) an exact characterisation of the collateral effect of deleting an association, guaranteeing that deletion never invalidates certified associations; and (iii) a geometric transparency bound demonstrating why attribution requires candidate sets of centred keys. On this basis, we introduce Topology-Aware Neuro-Symbolic Associative Retrieval (TANSAR). TANSAR traverses a directed acyclic association graph, prunes invalid paths via sound ground Horn constraints, and injects a representation derived strictly from the verified path into the residual stream of a frozen language model, guarded by a Clopper--Pearson selective-risk gate. Controlled experiments confirm all theoretical bounds. In multi-hop knowledge editing, Horn pruning reduces answer contradictions from 25.1% to 0.5%, whereas Hopfield retrieval incurs 24% contradictions when stale associations remain stored (and 0% if stale associations are removed). An end-to-end edit transaction requires 13.6 ms on a standard CPU and 2.37 ms on GPU. The symbolic component matches gold labels across all 600 ProofWriter theories and achieves 94.0% agreement on FOLIO, demonstrating sound and efficient multi-hop associative retrieval with exact unlearning.
BibTeX
@misc{abdulla2026tansar,
  author = {Abdulhady Abas Abdulla and Jiyan Salim Mahmud and Fatemeh Daneshfar and Hussein Mohammed Ali and Mourad Oussalah and Muhammad Bilal},
  title = {{TANSAR: Editable and Attributable Correlation Matrix Memories under Correlated Keys, with Rule-Constrained Multi-Hop Knowledge Editing}},
  year = {2026},
  eprint = {2611.12374},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.12374},
}
Figure