Interpreting the Repeated Token Phenomenon in Large Language Models
Itay Yona, Ilia Shumailov, Jamie Hayes, Yossi Gandelsman
摘要
Large Language Models (LLMs), despite their impressive capabilities, often fail to accurately repeat a single word when prompted to, and instead output unrelated text. This unexplained failure mode represents a vulnerability, allowing even end users to diverge models away from their intended behavior. We aim to explain the causes for this phenomenon and link it to the concept of "attention sinks", an emergent LLM behavior crucial for fluency, in which the initial token receives disproportionately high attention scores. Our investigation identifies the neural circuit responsible for attention sinks and shows how long repetitions disrupt this circuit. We extend this finding to other nonrepeating sequences that exhibit similar circuit disruptions. To address this, we propose a targeted patch that effectively resolves the issue without negatively impacting the overall performance of the model. This study provides a mechanistic explanation for an LLM vulnerability, demonstrating how interpretability can diagnose and address issues, and offering insights that pave the way for more secure and reliable models. Code is available here.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 11 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Efficient Streaming Language Models with Attention Sinks 引用了 Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing
- Attention Sinks: A 'Catch, Tag, Release' Mechanism for Embeddings 引用了 Efficient Streaming Language Models with Attention Sinks
- Attention Sinks: A 'Catch, Tag, Release' Mechanism for Embeddings 引用了 Unveiling and Harnessing Hidden Attention Sinks: Enhancing Large Language Models without Training through Attention Calibration
- Attention Sinks: A 'Catch, Tag, Release' Mechanism for Embeddings 引用了 Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing
- Unveiling and Harnessing Hidden Attention Sinks: Enhancing Large Language Models without Training through Attention Calibration 引用了 Efficient Streaming Language Models with Attention Sinks
- Attention Sinks and Compression Valleys in LLMs are Two Sides of the Same Coin 引用了 Efficient Streaming Language Models with Attention Sinks
- Attention Sinks and Compression Valleys in LLMs are Two Sides of the Same Coin 引用了 Transformers need glasses! Information over-squashing in language tasks
- Attention Sinks and Compression Valleys in LLMs are Two Sides of the Same Coin 引用了 Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing
- Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-Free 引用了 Efficient Streaming Language Models with Attention Sinks
- Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-Free 引用了 Unveiling and Harnessing Hidden Attention Sinks: Enhancing Large Language Models without Training through Attention Calibration
- Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-Free 引用了 Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing
- The Achilles’ Heel of LLMs: How Altering a Handful of Neurons Can Cripple Language Abilities 引用了 Efficient Streaming Language Models with Attention Sinks
- The Achilles’ Heel of LLMs: How Altering a Handful of Neurons Can Cripple Language Abilities 引用了 Vision Transformers Don't Need Trained Registers
- Vision Transformers Don't Need Trained Registers 引用了 Efficient Streaming Language Models with Attention Sinks
- Vision Transformers Don't Need Trained Registers 引用了 Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing
引用它的顶会 Paper11
- Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-FreeZihan Qiu, Zekun Wang, Bo Zheng, Zeyu Huang 等NeurIPS 2025 · 336 次引用
- Attention Sinks and Compression Valleys in LLMs are Two Sides of the Same CoinEnrique Queipo-de-Llano, Alvaro Arroyo, Federico Barbero, Xiaowen Dong 等ICLR 2026 · 56 次引用
- Vision Transformers Don't Need Trained RegistersNick Jiang, Amil Dravid, Alexei A. Efros, Yossi GandelsmanNeurIPS 2025 · 50 次引用
- Attention Sinks: A 'Catch, Tag, Release' Mechanism for EmbeddingsStephen Zhang, Mustafa Khan, Vardan PapyanNeurIPS 2025 · 18 次引用
- The Achilles’ Heel of LLMs: How Altering a Handful of Neurons Can Cripple Language AbilitiesZixuan Qin, Qingchen Yu, Kunlin Lyu, Zhaoxin Fan 等ICLR 2026 · 10 次引用
它引用的 Paper9
- Efficient Streaming Language Models with Attention SinksGuangxuan Xiao, Yuandong Tian, Beidi Chen, Song Han 等ICLR 2024 · 1,714 次引用
- Quantizable Transformers: Removing Outliers by Helping Attention Heads Do NothingYelysei Bondarenko, Markus Nagel, Tijmen BlankevoortNeurIPS 2023 · 196 次引用
- Transformers need glasses! Information over-squashing in language tasksFederico Barbero, Andrea Banino, Steven Kapturowski, Dharshan Kumaran 等NeurIPS 2024 · 105 次引用
- Unveiling and Harnessing Hidden Attention Sinks: Enhancing Large Language Models without Training through Attention CalibrationZhongzhi Yu, Zheng Wang, Yonggan Fu, Huihong Shi 等ICML 2024 · 63 次引用
- Interpretability in the Wild: a Circuit for Indirect Object Identification in GPT-2 SmallKevin Ro Wang, Alexandre Variengien, Arthur Conmy, Buck Shlegeris 等ICLR 2023 · 50 次引用
相关 Paper
- Attention Sinks as Internal Signals for Hallucination Detection in Large Language ModelsJakub Binkowski, Kamil Adamczewski, Tomasz KajdanowiczICML 2026
- Incomplete Prompt Jailbreaks in Large Language ModelsYeonjea Kim, Bumjin Park, Jaesik ChoiACL Findings 2026
- Exposing Attention Glitches with Flip-Flop Language ModelingBingbin Liu, Jordan T. Ash, Surbhi Goel, Akshay Krishnamurthy 等NeurIPS 2023 · 90 次引用
- Spurious Rewards Paradox: Mechanistically Understanding How RLVR Activates Memorization Shortcuts in LLMsLecheng Yan, Ruizhe Li, Guanhua CHEN, Qing Li 等ICML 2026 · 8 次引用
- A Single Layer to Explain Them All: Understanding Massive Values in Large Language ModelsZeru Shi, Zhenting Wang, Fan Yang, Qifan Wang 等ICML 2026
