Vai al contenuto
AI.info

Research

Kalman Delta Networks: Uncertainty-aware Associative Memory

Kalman Delta Networks: Uncertainty-aware Associative Memory Overview Research area: Machine learning — efficient sequence modeling, specifically linear attention and recurrent associative memory for l

Kalman Delta Networks: Uncertainty-aware Associative Memory

In inglese

arXiv
2609.07816
Published
2026-09-07
Authors
Ngoc Bui, Tinglin Huang, Rex Ying

AI summary

Kalman Delta Networks: Uncertainty-aware Associative Memory

Overview

Research area: Machine learning — efficient sequence modeling, specifically linear attention and recurrent associative memory for long-context language models.

Technical level: Advanced. The paper combines linear–Gaussian state-space modeling, Kalman filtering, online mean-field variational inference, and GPU-parallel associative scans, and it assumes familiarity with DeltaNet-family architectures and the Mamba state-space lineage.

Scope (one sentence): The paper reformulates recurrent associative memory as a linear–Gaussian state-space model so that memory uncertainty becomes an explicit tracked state variable, then derives two scan-compatible approximations — Diagonal KDN and Isotropic KDN — and pretrains them at 750M and 1.3B parameters against state-of-the-art linear-attention baselines.

What This Paper Is About

Linear attention compresses the token history into a fixed-size recurrent state, so at every token the model must decide what to write and how strongly to overwrite existing associations — before it knows which information future queries will need. Delta-rule models (DeltaNet, Gated DeltaNet, KDA) predict this write strength from the current token embedding, but they never track how confident the memory actually is, so a large residual cannot be discounted when an association has already been confirmed repeatedly. The paper's goal is to make that confidence an explicit, efficiently computable part of the recurrent state.

Key Contributions

  1. A principled state-space view of delta-based models. The authors cast the delta rule as an innovation update inside a linear–Gaussian state-space model, connecting delta-based recurrent mixers to the Mamba lineage. DeltaNet, Gated DeltaNet, and KDA are shown to use identity, scalar, and diagonal transitions respectively, and to share a residual key-conditioned correction with a token-predicted rather than covariance-derived gain.

  2. A hardware-efficient algorithm for uncertainty-aware associative memory. Diagonal KDN is derived through online variational inference, and an Isotropic variant is introduced as well; they carry O(d_k) and O(1) uncertainty state per head. Their uncertainty updates admit an associative gain scan followed by the usual affine memory scan.

  3. Overwrite analysis and empirical evidence. The authors identify how the diagonal uncertainty approximation can underprotect stored key directions under reverse-KL mean-field projection, introduce an information-scaling factor to control future overwrite, and report improvements over evaluated state-of-the-art delta-rule models and Mamba-3 variants in reported perplexities and mean six-task zero-shot accuracy.

Main Findings

  • The Kalman filter is the optimal estimator for the proposed formulation. Under the linear–Gaussian assumptions of the paper, the Kalman filter computes the posterior mean of the latent memory exactly, and its update retains the residual delta-write form while weighting new evidence by memory uncertainty and observation reliability.

  • Delta-rule mixers are fixed-gain special cases. Discarding the covariance recursion and substituting an isotropic surrogate for the predicted covariance collapses the Kalman gain to the scalar write strength β_t used by the delta-rule family (for normalized keys), with DeltaNet, Gated DeltaNet, and KDA differing only in their process model (identity, scalar, and diagonal transitions).

  • Exact covariance tracking is impractical for linear attention. The exact update carries a dense d_k × d_k covariance per head and follows a state-dependent Riccati recurrence that is poorly suited to GPU-parallel scans, motivating the two approximations.

  • The variational projection preserves the exact posterior mean. The Diagonal KDN mean-field projection onto the diagonal Gaussian family is shown to keep the exact one-step Kalman posterior mean conditional on the diagonal predictive prior, while replacing the shared dense key-space covariance with a diagonal state.

  • Uncertainty recurrences are Möbius maps. Substituting the diagonal updates yields a per-channel Möbius recurrence, which can be represented by 2 × 2 matrices so that composition becomes matrix multiplication — enabling associative scans with logarithmic parallel depth.

  • Information scaling controls overwrite. Reverse-KL mean field inherits coordinatewise overconfidence and can trigger excessively strong residual writes, so the authors apply a scale μ only to the post-write precision increment, leaving the current write unchanged while reducing later effective writes β^eff = k^T κ. Setting μ = 1 recovers the variational update, and for a normalized dense key μ = d_k compensates the 1/d_k dilution of each channel's information increment.

  • KDN variants beat the evaluated baselines. Under parameter-matched recurrent-only pretraining on FineWeb-Edu at 750M/50B and 1.3B/100B, both KDN variants achieve lower WikiText and LAMBADA perplexity and higher mean six-task zero-shot accuracy than every evaluated state-of-the-art linear-time recurrent mixer, including Mamba-3, KDA, and GDN-2.

  • Best reported long-context aggregate. Diagonal KDN achieves the highest observed 14-cell RULER aggregate at both the 750M and 1.3B scales.

  • Not reported in the supplied content. The specific perplexity values, downstream accuracy numbers, and RULER scores are not included in the provided text, which truncates at Proposition 4.2; only the direction and ranking of the results are stated.

Methodology in Plain English

The authors start by asking what a recurrent memory would look like if it were treated as a statistician's tracking problem. They define a latent "key–value map" that drifts over time — some associations persist, some decay, and drift that deterministic decay cannot explain is modeled as process noise. Each token is treated as one noisy measurement of that map along one key direction, where the value may contain contextual noise that should not be stored as clean fact. Setting up the problem this way makes the Kalman filter the optimal recursive estimator, and it naturally produces two quantities per token: a memory estimate and a covariance describing how confident the model should be in it. The residual write of delta-rule models falls out as a special case once you throw the covariance away and replace it with a single scalar guess.

The exact covariance recursion is too expensive: it is a dense matrix per head with a state-dependent Riccati recursion that does not parallelize well. So the authors constrain the covariance. Diagonal KDN restricts the transition, process noise, and predictive covariance to be diagonal, but the exact posterior after a rank-one update is still dense. They therefore project the posterior back onto the diagonal family after each token using online mean-field variational inference that minimizes reverse KL, and show this projection keeps the exact one-step posterior mean. Because each channel then evolves independently, the covariance update becomes a Möbius map, which the authors encode as a 2 × 2 matrix and compose with an associative scan of logarithmic parallel depth. Isotropic KDN goes further, tying all channels to a single uncertainty scalar per head.

One complication: mean-field projection discards cross-channel correlations, which makes the model overconfident along jointly observed key directions and can cause an overly strong overwrite. To counteract this, the authors introduce an information scale μ applied only to the post-write precision increment — this leaves the current write unchanged but damps later effective writes. They then run controlled, parameter-matched recurrent-only pretraining at 750M and 1.3B parameters on FineWeb-Edu, evaluating WikiText and LAMBADA perplexity, mean six-task zero-shot accuracy, and RULER.

Why This Matters

Impact on research. The paper supplies a unifying lens for a family of architectures that previously mixed two explanatory frames — state-space dynamics for the transition and online gradient descent for the write. Recasting DeltaNet, Gated DeltaNet, and KDA as fixed-gain Kalman filters makes the missing state variable (confidence in the stored association) explicit and testable, and it connects the delta-rule lineage directly to the Mamba state-space lineage under one probabilistic model. It also shows that a classical, decades-old estimator can be made compatible with modern GPU-parallel scan training once you approximate the covariance carefully, which suggests a general recipe for inserting probabilistic structure into efficient sequence layers.

Real-world applications (implied by the settings the paper targets):

  • Long-context language model inference, where constant-memory decoding and sub-quadratic attention costs are the binding constraint.
  • Streaming or conversational agents that must keep a fixed-size memory of an evolving discourse state, where the paper's framing of drift and forgetting maps directly onto entities and facts changing over time.
  • Deployment in memory-constrained environments such as on-device or edge inference, where the ability to trade O(1) versus O(d_k) uncertainty state per head gives an explicit cost/capability knob.
  • Non-stationary or continually shifting data streams, where the process-noise term is intended to represent drift that deterministic decay cannot capture.

Industry relevance. Frontier language models increasingly use linear attention for efficient long-context inference, and the baselines in this paper (KDA from Kimi Team, GDN-2, Mamba-3) are current industry-scale architectures. A modification that improves perplexity and mean zero-shot accuracy at equal parameter count and adds only O(d_k) or O(1) auxiliary state per head, while preserving associative-scan parallelism, is directly compatible with existing training and serving stacks.

Future Directions

  • Characterizing the diagonal approximation's failure modes. The authors identify that reverse-KL mean field can underprotect stored key directions; how far the information-scale μ can be pushed, and whether a principled schedule for it exists, remains open.
  • Beyond diagonal and isotropic covariances. Both approximations discard most of the covariance structure. Low-rank or block-structured covariance families might recover more of the exact Kalman update while remaining scan-compatible.
  • Scaling and architecture integration. The reported pretraining is at 750M/50B and 1.3B/100B with recurrent-only mixers; whether the gains persist at frontier scale, in hybrid attention stacks, or under longer-context training is not established in the supplied content.
  • Where uncertainty is actually used. The paper's central claim is that confidence in the memory should govern write strength; probing whether the learned uncertainty correlates with human-interpretable notions of memory reliability would test the interpretation directly.

Target Audience

This paper is for researchers and engineers working on efficient sequence modeling and long-context language models — particularly those already familiar with DeltaNet-style delta-rule mixers, the Mamba state-space family, and associative-scan training. Readers interested in probabilistic or Bayesian treatments of neural memory will also find the state-space framing useful. It is not an introductory paper: the derivations assume comfort with Gaussian conditioning, Kalman filtering, variational inference, and parallel scan algorithms.

Authors’ abstract

Linear attention is increasingly used in frontier language models for efficient long-context inference and constant-memory decoding. Its fixed-size recurrent memory, however, requires an online decision at each token: what to write and how strongly to overwrite existing associations before knowing which information future queries will require. Delta-rule models learn this strength from the current token embedding but do not track confidence in the memory estimate, preventing each write from adapting to accumulated evidence. To represent this uncertainty explicitly, we reformulate recurrent associative memory as a linear--Gaussian state-space model, for which the Kalman filter is the optimal recursive estimator, and introduce a new family of models, Kalman Delta Networks (KDNs). Within KDNs, the transition propagates both the memory state and its uncertainty, allowing the Kalman gain to weight each residual write by accumulated evidence and observation reliability. Under this formulation, Delta-style updates emerge as a special case that substitutes a token-wise isotropic surrogate for predictive covariance and omits covariance tracking. Exact tracking, however, entails a dense, state-dependent Riccati recursion that is poorly suited to GPU-parallel linear-attention scans. To address this issue, we introduce two scan-compatible KDN approximations. Diagonal KDN projects each one-step posterior onto the diagonal Gaussian family through online mean-field variational inference, whereas Isotropic KDN uses an isotropic approximation with a single uncertainty scalar per head. Their uncertainty recurrences are Mobius maps, enabling associative scans with logarithmic parallel depth. Across controlled pretraining at 750M and 1.3B parameters, KDN variants consistently improve perplexity and mean downstream accuracy over state-of-the-art linear-attention models.

Read the original paper