# Softmax Attention with Any Temperature in Fixed Dimension: Matching the Best Known Maximum-Inner-Product Bounds

arXiv: https://arxiv.org/abs/2611.06055 · HTML: https://mlsanity.com/paper/2611.06055/

## Key facts

- No citing papers in the map yet (data through 26 Nov 2026).
- Builds on 2 of its 63 references that are in the map.
- Submitted 4 Nov 2026.

## Builds on (most cited first, 2 of 2)

- [Fast Transformer Decoding: One Write-Head is All You Need](https://mlsanity.com/paper/1911.02150/) (2019)
- [Furthest Pair Requires Quadratic Time in Superconstant Dimension under SETH](https://mlsanity.com/paper/2606.25887/) (2026)

## Abstract (arXiv)

Attention is central to modern AI models for language, vision, and scientific modeling. However, direct evaluation compares every query with every key, requiring quadratic time in the context length, which limits its scalability to long contexts. Consequently, characterizing the complexity bounds of attention is of fundamental importance. For every fixed dimension d, we give an algorithm for m queries, n key-value pairs, and additive error varepsilon, with expected time  widetildeObigl((mn)k/(k+1)+m+nbigr),qquad k=lfloor d/2rfloor.  For fixed dimension and a fixed number of value channels, soft-O hides factors of the form operatornamepolydbigl(b,log(m+n),log B,log(1/varepsilon)bigr), where b bounds input encoding lengths and B bounds coordinate and value magnitudes. In particular, the dependence on B and 1/varepsilon is polylogarithmic, which allows arbitrary positive temperature. When m=n and d≥2, the bound is widetildeO(n2-2/(lfloor d/2rfloor+1)): near-linear in dimensions two and three, with exponent 4/3 in dimensions four and five and 3/2 in dimensions six and seven. It improves the previous widetildeO(n2-1/d) upper bound and matches the best known batch maximum-inner-product bound in each fixed dimension. Additionally, we reduce integer batch maximum inner product computation to one attention call with the same dimension and input sizes m,n.
