MDN: Parallelizing Stepwise Momentum for Delta Linear Attention

Yulong Huang, Xiang Liu, Hongxiang Huang, Xiaopeng Lin, Zunchang Liu, Xiaowen Chu, Zeke Xie, Bojun Cheng

Abstract

Momentum DeltaNet (MDN) introduces a novel method for integrating momentum-based optimization into Linear Attention, significantly enhancing the memory and retrieval capabilities of Large Language Models (LLMs). By developing a chunkwise parallel algorithm and applying dynamical systems theory to ensure stability, MDN achieves Transformer-level performance while maintaining the efficiency of linear-time models.

Introduction: The Bottleneck of Linear Attention

While standard Transformers remain the gold standard for language modeling, their core "self-attention" mechanism suffers from a well-known flaw: computational cost grows quadratically with sequence length. Linear Attention (LA) models, such as Mamba2 and Gated DeltaNet (GDN), address this by utilizing a recurrent update rule that functions as a "fast weight" memory.

However, these models typically rely on a simple update rule mathematically equivalent to Stochastic Gradient Descent (SGD). Just as SGD in standard neural network training can be slow to converge and prone to "forgetting" past states, SGD-based Linear Attention struggles to capture fine-grained historical details. This leads to suboptimal performance on tasks requiring long-term context retrieval, often referred to as the "Needle-In-A-Haystack" problem.

While momentum is the classic optimization remedy for SGD's shortcomings, adding it to a recurrent model typically breaks the ability to train in parallel, rendering it too slow for large-scale LLM training. This paper bridges that gap.

Methodology: Momentum DeltaNet (MDN)

The authors introduce MDN, which seamlessly incorporates a "stepwise momentum" rule into the Linear Attention framework. The architecture is built on three technical pillars:

1. Chunkwise Parallelization

To ensure training efficiency, the authors developed a mathematical technique to decouple the momentum update coefficients. By geometrically reordering these updates, they created a chunkwise parallel algorithm. Implemented using high-performance Triton kernels, this approach achieves training speeds comparable to state-of-the-art linear models without sacrificing the benefits of momentum.

2. Second-Order Dynamical Systems

Analyzing the momentum rule through the lens of dynamical systems reveals a profound shift in model behavior. While standard LA models operate as "first-order" systems (characterized by simple exponential decay), introducing momentum creates a second-order system. This allows for complex conjugate eigenvalues, meaning the model's memory can exhibit "damped oscillatory behavior"—a significantly more sophisticated mechanism for retaining information than simple fading. This "phase-aware" memory helps the model distinguish between similar tokens appearing at different times.

3. Stability-Aware Gating

Second-order systems are notoriously prone to instability, which can lead to "NaN" errors during training. To counteract this, the authors derived specific "Quadrant Constraints" (e.g., $\beta_t \le 1 - \alpha_t$) to ensure the model's internal states remain stable while still harnessing the expressive power of momentum.

Experimental Setup

The MDN model was trained and evaluated at the 400M and 1.3B parameter scales. The training regimen utilized a 100-billion token subset of the SlimPajama dataset. Evaluation spanned several rigorous benchmarks:

  • Synthetic Retrieval: MQAR (Multi-Query Associative Recall) to test foundational memory.
  • Downstream Tasks: Standard reasoning benchmarks including HellaSwag, ARC, and WinoGrande.
  • Long Context: LongBench and RULER (Needle-In-A-Haystack) to evaluate retrieval across sequences up to 32k tokens.

Key Insights and Results

Viewing the hidden state of a language model as a "latent objective" being optimized in real-time is a profound conceptual shift. By upgrading the recurrence optimizer from SGD to Momentum, the model's memory naturally becomes more robust. Furthermore, MDN maintains strict causality via stepwise momentum, ensuring identical behavior during both training and inference.

Empirical results demonstrate MDN's superiority over strong baselines like Mamba2 and GDN:

  • Retrieval Power: On the RULER benchmark (multi-needle retrieval at an 8k context window), MDN outperformed the strongest baseline by a massive 8.9 to 13.4 points.
  • Language Modeling: At the 1.3B scale, MDN achieved the lowest perplexity (14.87 on Lambada) and the highest average score on commonsense reasoning tasks (58.82) among competing linear models.
  • Efficiency: Despite the added mathematical complexity of momentum, MDN maintains linear complexity relative to sequence length. Its decoding latency is nearly identical to GDN, and its training throughput remains highly competitive with Mamba2.

Limitations and Future Work

While MDN is highly effective, tracking two internal states (the fast weight and the momentum) introduces a slight overhead, making its training throughput marginally lower than the absolute simplest linear models.

Additionally, current experiments are capped at the 1.3B parameter scale. The scaling laws for momentum-based attention at the 7B or 70B scale remain an open question. Future research will likely explore even more advanced optimizers (such as Adam or Nesterov momentum) and investigate MDN's applicability to other data modalities, including video and genomics.

Summary updated

BibTeX
@inproceedings{huang2026mdn,
  author = {Yulong Huang and Xiang Liu and Hongxiang Huang and Xiaopeng LIN and Zunchang Liu and Xiaowen Chu and Zeke Xie and Bojun Cheng},
  title = {{MDN: Parallelizing Stepwise Momentum for Delta Linear Attention}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=Sh3rKEAxlW},
}
Figure