Lune

NeurIPS2025顶会

Attention with Trained Embeddings Provably Selects Important Tokens

Diyuan Wu, Aleksandr Shevchenko, Samet Oymak, Marco Mondelli

摘要

Token embeddings play a crucial role in language modeling but, despite this practical relevance, their theoretical understanding remains limited. Our paper addresses the gap by characterizing the structure of embeddings obtained via gradient descent. Specifically, we consider a one-layer softmax attention model with a linear head for binary classification, i.e., Softmax(p⊤EX⊤)EXv=∑i=1Texp⁡(p⊤Exi)Exi⊤v∑j=1Texp⁡(p⊤Exj)\texttt{Softmax}( p^\top E_X^\top ) E_X v = \frac{ \sum_{i=1}^T \exp(p^\top E_{x_i}) E_{x_i}^\top v}{\sum_{j=1}^T \exp(p^\top E_{x_{j}}) }, where EX=[Ex1,…,ExT]⊤E_X = [ E_{x_1} , \dots, E_{x_T} ]^\top contains the embeddings of the input sequence, pp is the embedding of the ⟨cls⟩\mathrm{\langle cls \rangle} token and vv the output vector. First, we show that, already after a single step of gradient training with the logistic loss, the embeddings EXE_X capture the importance of tokens in the dataset by aligning with the output vector vv proportionally to the frequency with which the corresponding tokens appear in the dataset. Then, after training pp via gradient flow until convergence, the softmax selects the important tokens in the sentence (i.e., those that are predictive of the label), and the resulting ⟨cls⟩\mathrm{\langle cls \rangle} embedding maximizes the margin for such a selection. Experiments on real-world datasets (IMDB, Yelp) exhibit a phenomenology close to that unveiled by our theory.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 2 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • A Capacity-Based Rationale for Multi-Head Attention 引用了 Representational Strengths and Limitations of Transformers
  • Zero-Shot Text-to-Image Generation 引用了 Learning Transferable Visual Models From Natural Language Supervision
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper2

  1. A Capacity-Based Rationale for Multi-Head AttentionMicah AdlerICML 2026 · 2 次引用
  2. Focus and Dilution: The Multi-stage Learning Process of AttentionZheng-An Chen, Pengxiao Lin, Zhi-Qin John Xu, Tao LuoICML 2026

它引用的 Paper24

  1. Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh 等ICML 2021 · 47,906 次引用
  2. Zero-Shot Text-to-Image GenerationAditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray 等ICML 2021 · 6,356 次引用
  3. One Fits All: Power General Time Series Analysis by Pretrained LMTian Zhou, Peisong Niu, Xue Wang, Liang Sun 等NeurIPS 2023 · 1,178 次引用
  4. The emergence of clusters in self-attention dynamicsBorjan Geshkovski, Cyril Letrouit, Yury Polyanskiy, Philippe RigolletNeurIPS 2023 · 163 次引用
  5. Representational Strengths and Limitations of TransformersClayton Sanford, Daniel J. Hsu, Matus TelgarskyNeurIPS 2023 · 162 次引用

相关 Paper

  1. Max-Margin Token Selection in Attention MechanismDavoud Ataee Tarzanagh, Yingcong Li, Xuechen Zhang, Samet OymakNeurIPS 2023 · 67 次引用
  2. On the Dynamics of Training Attention ModelsHaoye Lu, Yongyi Mao, Amiya NayakICLR 2021 · 9 次引用
  3. Learning to Recall with Transformers Beyond Orthogonal EmbeddingsNuri Mert Vural, Alberto Bietti, Mahdi Soltanolkotabi, Denny WuICLR 2026 · 1 次引用
  4. Implicit Optimization Bias of Next-token Prediction in Linear ModelsChristos ThrampoulidisNeurIPS 2024 · 19 次引用
  5. Limitations of Normalization in AttentionTimur Mudarisov, Mikhail Burtsev, Tatiana Petrova, Radu StateNeurIPS 2025
黄昏的海面,两侧是细线勾勒的悬崖