Softmax Attention with Constant Cost per Token
Not on the map. Why?
Abstract (arXiv)
We propose a simple modification to the conventional attention mechanism applied by Transformers: Instead of quantifying pairwise query-key similarity with scaled dot-products, we quantify it with the logarithms of scaled dot-products of exponentials. Our modification linearizes attention with exponential kernel feature maps, whose corresponding feature function is infinite dimensional. We show that our modification is expressible as a composition of log-sums of exponentials, with a latent space of constant size, enabling application with constant time and space complexity per token. We implement our modification, verify that it works in practice, and conclude that it is a promising alternative to conventional attention.
Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Builds on 14 of its 16 references that are in the map. First posted on arXiv 8 Apr 2024.
Builds on
14 of 16 references.
References · 14
- 2017Attention Is All You Needcited by 60,361
- 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 4,718
- 2021Efficiently Modeling Long Sequences with Structured State Spacescited by 2,465
- 2020The Pile: An 800GB Dataset of Diverse Text for Language Modelingcited by 2,411
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 2,022
- 2019Generating Long Sequences with Sparse Transformerscited by 1,546
- 2020Linformer: Self-Attention with Linear Complexitycited by 1,474
- 2020Efficient Content-Based Sparse Attention with Routing Transformerscited by 471
- 2023Hyena Hierarchy: Towards Larger Convolutional Language Modelscited by 393
- 2021FNet: Mixing Tokens with Fourier Transformscited by 347
- 2024Repeat After Me: Transformers are Better than State Space Models at Copyingcited by 216
- 2017Parallelizing Linear Recurrent Neural Nets Over Sequence Lengthcited by 127
2 more
- 2021An Attention Free Transformercited by 112
- 2023GateLoop: Fully Data-Controlled Linear Recurrence for Sequence Modelingcited by 46
Built on by
Citing papers per year: 2026: 1.
1 paper.