Lune

ICLR2026顶会

Sublinear Time Quantum Algorithm for Attention Approximation

Zhao Song, Jianfei Xue, Jiahao Zhang, Lichen Zhang

2026年份
2被引次数
1顶会引用

摘要

Given the query, key and value matrices Q,K,V∈Rn×dQ, K, V\in \mathbb{R}^{n\times d}, the attention module is defined as Att(Q,K,V)=D−1AV\mathrm{Att}(Q, K, V)=D^{-1}AV where A=exp⁡(QK⊤/d)A=\exp(QK^\top/\sqrt{d}) with exp⁡(⋅)\exp(\cdot) applied entrywise, D=diag(A1n)D=\mathrm{diag}(A{\bf 1}_n). The attention module is the backbone of modern transformers and large language models, but explicitly forming the softmax matrix D−1AD^{-1}A incurs Ω(n2)\Omega(n^2) time, motivating numerous approximation schemes that reduce runtime to O~(nd)\widetilde O(nd) via sparsity or low-rank factorization. We propose a quantum data structure that approximates any row of Att(Q,K,V)\mathrm{Att}(Q, K, V) using only row queries to Q,K,VQ, K, V. Our algorithm preprocesses these matrices in O~(ϵ−1n0.5(sλ2.5+sλ1.5d+α0.5d))\widetilde{O}\left( \epsilon^{-1} n^{0.5} \left( s_\lambda^{2.5} + s_\lambda^{1.5} d + \alpha^{0.5} d \right) \right) time, where ϵ\epsilon is the target accuracy, sλs_\lambda is the λ\lambda-statistical dimension of the exponential kernel defined by QQ and KK, and α\alpha measures the row distortion of VV that is at most d/srank(V)d/{\rm srank}(V), the stable rank of VV. Each row query can be answered in O~(sλ2+sλd)\widetilde{O}(s_\lambda^2 + s_\lambda d) time. To our knowledge, this is the first quantum data structure that approximates rows of the attention matrix in sublinear time with respect to nn. Our approach relies on a quantum Nyström approximation of the exponential kernel, quantum multivariate mean estimation for computing DD, and quantum leverage score sampling for the multiplication with VV.

问问这篇 Paper

智能体会读完全文。

Lune 把这篇 Paper 索引到了最后一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。

可以从这些问题问起

智能体调用

Luneget_paper_fulltext

在 Lune 里问

免费开始,无需绑卡

lune papers fulltext 67e362e5-454e-4e44-8f6e-37243cbc06cf

引用它的顶会 Paper1

问问它们各自怎么用它

它引用的顶会 Paper34

相关 Paper

黄昏的海面,两侧是细线勾勒的悬崖