Understanding the Differences in Foundation Models: Attention, State Space Models, and Recurrent Neural Networks
Jerome Sieber, Carmen Amo Alonso, Alexandre Didier, Melanie N. Zeilinger, Antonio Orvieto
Abstract
Softmax attention is the principle backbone of foundation models for various artificial intelligence applications, yet its quadratic complexity in sequence length can limit its inference throughput in long-context settings. To address this challenge, alternative architectures such as linear attention, State Space Models (SSMs), and Recurrent Neural Networks (RNNs) have been considered as more efficient alternatives. While connections between these approaches exist, such models are commonly developed in isolation and there is a lack of theoretical understanding of the shared principles underpinning these architectures and their subtle differences, greatly influencing performance and scalability. In this paper, we introduce the Dynamical Systems Framework (DSF), which allows a principled investigation of all these architectures in a common representation. Our framework facilitates rigorous comparisons, providing new insights on the distinctive characteristics of each model class. For instance, we compare linear attention and selective SSMs, detailing their differences and conditions under which both are equivalent. We also provide principled comparisons between softmax attention and other model classes, discussing the theoretical conditions under which softmax attention can be approximated. Additionally, we substantiate these new insights with empirical validations and mathematical arguments. This shows the DSF's potential to guide the systematic development of future more efficient and scalable foundation models.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
12 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Vision Mamba: Efficient Visual Representation Learning with Bidirectional State Space Model cites Efficiently Modeling Long Sequences with Structured State Spaces
- VMamba: Visual State Space Model cites Vision Mamba: Efficient Visual Representation Learning with Bidirectional State Space Model
- VMamba: Visual State Space Model cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- VMamba: Visual State Space Model cites Efficiently Modeling Long Sequences with Structured State Spaces
- LaTIM: Measuring Latent Token-to-Token Interactions in Mamba Models cites Efficiently Modeling Long Sequences with Structured State Spaces
- Efficiently Modeling Long Sequences with Structured State Spaces cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- Exploring the Limitations of Mamba in COPY and CoT Reasoning cites Vision Mamba: Efficient Visual Representation Learning with Bidirectional State Space Model
- Exploring the Limitations of Mamba in COPY and CoT Reasoning cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- Exploring the Limitations of Mamba in COPY and CoT Reasoning cites Efficiently Modeling Long Sequences with Structured State Spaces
- Block-Biased Mamba for Long-Range Sequence Processing cites Vision Mamba: Efficient Visual Representation Learning with Bidirectional State Space Model
- Block-Biased Mamba for Long-Range Sequence Processing cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- Block-Biased Mamba for Long-Range Sequence Processing cites Efficiently Modeling Long Sequences with Structured State Spaces
- A Theoretical Analysis of Mamba’s Training Dynamics: Filtering Relevant Features for Generalization in State Space Models cites VMamba: Visual State Space Model
- A Theoretical Analysis of Mamba’s Training Dynamics: Filtering Relevant Features for Generalization in State Space Models cites Efficiently Modeling Long Sequences with Structured State Spaces
- SAS: Simulated Attention Score cites Efficiently Modeling Long Sequences with Structured State Spaces
Cited by top-tier papers12
- Block-Biased Mamba for Long-Range Sequence ProcessingAnnan Yu, N. Benjamin ErichsonNeurIPS 2025 · 10 citations
- Exploring the Limitations of Mamba in COPY and CoT ReasoningRuifeng Ren, Zhicong Li, Yong LiuEMNLP 2025 · 6 citations
- A Theoretical Analysis of Mamba’s Training Dynamics: Filtering Relevant Features for Generalization in State Space ModelsMugunthan Shandirasegaran, Hongkang Li, Songyang Zhang, Meng Wang et al.ICLR 2026 · 3 citations
- SAS: Simulated Attention ScoreChuanyang Zheng, Jiankai Sun, Yihang Gao, Yuehao Wang et al.NeurIPS 2025 · 3 citations
- LaTIM: Measuring Latent Token-to-Token Interactions in Mamba ModelsHugo Pitorro, Marcos Vinícius TrevisoACL 2025 · 2 citations
Builds on28
- Efficiently Modeling Long Sequences with Structured State SpacesAlbert Gu, Karan Goel, Christopher RéICLR 2022 · 3,482 citations
- VMamba: Visual State Space ModelYue Liu, Yunjie Tian, Yuzhong Zhao, Hongtian Yu et al.NeurIPS 2024 · 3,199 citations
- Transformers are RNNs: Fast Autoregressive Transformers with Linear AttentionAngelos Katharopoulos, Apoorv Vyas, Nikolaos Pappas, François FleuretICML 2020 · 2,665 citations
- Pythia: A Suite for Analyzing Large Language Models Across Training and ScalingStella Biderman, Hailey Schoelkopf, Quentin Gregory Anthony, Herbie Bradley et al.ICML 2023 · 1,822 citations
- Vision Mamba: Efficient Visual Representation Learning with Bidirectional State Space ModelLianghui Zhu, Bencheng Liao, Qian Zhang, Xinlong Wang et al.ICML 2024 · 1,725 citations
Related papers
- MetaLA: Unified Optimal Linear Approximation to Softmax Attention MapYuhong Chou, Man Yao, Kexin Wang, Yuqi Pan et al.NeurIPS 2024 · 22 citations
- Sequence Accumulation and Beyond: Infinite Context Length on Single GPU and Large ClustersWeigao Sun, Yongtuo Liu, Xiaqiang Tang, Xiaoyu MoAAAI 2025 · 3 citations
- On Structured State-Space DualityJerry Yao-Chieh Hu, Xiwen Zhang, Ali ElSheikh, Weimin Wu et al.ICML 2026
- Random Feature AttentionHao Peng, Nikolaos Pappas, Dani Yogatama, Roy Schwartz et al.ICLR 2021 · 425 citations
- On the Expressiveness and Length Generalization of Selective State Space Models on Regular LanguagesAleksandar Terzic, Michael Hersche, Giacomo Camposampiero, Thomas Hofmann et al.AAAI 2025 · 8 citations
