Reproduce “Efficient Attention via Control Variates” on OpenResearch
Run Claude Code, Codex or any coding agent as a research agent: literature, hypotheses and experiments on your laptop, cluster or cloud GPUs.
Universal app for Apple silicon and Intel. Requires macOS 11 or later.
About this paper
Lin Zheng, Jianbo Yuan, Chong Wang, Lingpeng Kong
Efficient attention via control VAriates (EVA) introduces a new mechanism that re-interprets random-feature-based attention (RFA) using control variates, demonstrating that exact softmax attention can be recovered under optimal conditions. This approach yields linear computational complexity and consistently outperforms prior linear attention methods, often matching or exceeding the performance of exact softmax attention on various vision and language tasks.
Key insights
- Random-Feature-Based Attention (RFA) can be precisely decomposed into a sum of localized control variate estimators, offering a granular perspective on its mechanics.
- Exact softmax attention is theoretically recoverable from RFA if each local control variate estimator utilizes its optimally derived coefficient, directly explaining the approximation gap in standard RFA.
- Partitioning the input sequence and applying locally shared control variate coefficients for these partitions provably leads to a lower or equal weighted mean squared error compared to using a single global coefficient.
Summary by alphaXiv.
Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.