Lune

ICLR2025顶会

Selective induction Heads: How Transformers Select Causal Structures in Context

Francesco D'Angelo, Francesco Croce, Nicolas Flammarion

摘要

Transformers have exhibited exceptional capabilities in sequence modeling tasks, leveraging self-attention and in-context learning. Critical to this success are induction heads, attention circuits that enable copying tokens based on their previous occurrences. In this work, we introduce a novel framework that showcases transformers' ability to dynamically handle causal structures. Existing works rely on Markov Chains to study the formation of induction heads, revealing how transformers capture causal dependencies and learn transition probabilities in-context. However, they rely on a fixed causal structure that fails to capture the complexity of natural languages, where the relationship between tokens dynamically changes with context. To this end, our framework varies the causal structure through interleaved Markov chains with different lags while keeping the transition probabilities fixed. This setting unveils the formation of Selective Induction Heads, a new circuit that endows transformers with the ability to select the correct causal structure in-context. We empirically demonstrate that transformers learn this mechanism to predict the next token by identifying the correct lag and copying the corresponding token from the past. We provide a detailed construction of a 3-layer transformer to implement the selective induction head, and a theoretical analysis proving that this mechanism asymptotically converges to the maximum likelihood solution. Our findings advance the understanding of how transformers select causal structures, providing new insights into their functioning and interpretability.

问 Lune

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

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

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

可以从这些问题问起

Lune 可以查阅

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

获取答案

免费开始,无需绑卡

脉络

  • Data Distributional Properties Drive Emergent In-Context Learning in Transformers 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • An Explanation of In-context Learning as Implicit Bayesian Inference 引用了 Language Models are Few-Shot Learners
  • The emergence of sparse attention: impact of data distribution and benefits of repetition 引用了 Data Distributional Properties Drive Emergent In-Context Learning in Transformers
  • The emergence of sparse attention: impact of data distribution and benefits of repetition 引用了 Language Models are Few-Shot Learners
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 Data Distributional Properties Drive Emergent In-Context Learning in Transformers
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 The emergence of sparse attention: impact of data distribution and benefits of repetition
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 Language Models are Few-Shot Learners
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 Transformers Learn In-Context by Gradient Descent
  • Transformers Learn Latent Mixture Models In-Context via Mirror Descent 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • Incremental Learning of Sparse Attention Patterns in Transformers 引用了 The emergence of sparse attention: impact of data distribution and benefits of repetition
  • Incremental Learning of Sparse Attention Patterns in Transformers 引用了 Transformers Learn Latent Mixture Models In-Context via Mirror Descent
  • Incremental Learning of Sparse Attention Patterns in Transformers 引用了 Transformers Learn In-Context by Gradient Descent
  • Incremental Learning of Sparse Attention Patterns in Transformers 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • Transformers Learn In-Context by Gradient Descent 引用了 Data Distributional Properties Drive Emergent In-Context Learning in Transformers
  • Transformers Learn In-Context by Gradient Descent 引用了 Language Models are Few-Shot Learners
  • Transformers Learn In-Context by Gradient Descent 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • What Can Transformers Learn In-Context? A Case Study of Simple Function Classes 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • What Can Transformers Learn In-Context? A Case Study of Simple Function Classes 引用了 Language Models are Few-Shot Learners
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper9

  1. The emergence of sparse attention: impact of data distribution and benefits of repetitionNicolas Zucchet, Francesco D'Angelo, Andrew Kyle Lampinen, Stephanie ChanNeurIPS 2025 · 28 次引用
  2. Mitigating Conversational Inertia in Multi-Turn AgentsYang Wan, Zheng Cao, Zhenhao Zhang, Zhengwen Zeng 等ICML 2026 · 4 次引用
  3. Transformers Learn Latent Mixture Models In-Context via Mirror DescentFrancesco D'Angelo, Nicolas FlammarionICLR 2026 · 2 次引用
  4. Incremental Learning of Sparse Attention Patterns in TransformersOğuz YükselICML 2026 · 2 次引用
  5. Towards Understanding Transformers in Learning Random WalksWei Shi, Yuan CaoNeurIPS 2025 · 1 次引用

它引用的 Paper17

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
  2. An Explanation of In-context Learning as Implicit Bayesian InferenceSang Michael Xie, Aditi Raghunathan, Percy Liang, Tengyu MaICLR 2022 · 1,030 次引用
  3. What Can Transformers Learn In-Context? A Case Study of Simple Function ClassesShivam Garg, Dimitris Tsipras, Percy Liang, Gregory ValiantNeurIPS 2022 · 883 次引用
  4. Transformers Learn In-Context by Gradient DescentJohannes von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento 等ICML 2023 · 729 次引用
  5. Data Distributional Properties Drive Emergent In-Context Learning in TransformersStephanie C. Y. Chan, Adam Santoro, Andrew K. Lampinen, Jane X. Wang 等NeurIPS 2022 · 407 次引用

相关 Paper

  1. How Transformers Learn Causal Structure with Gradient DescentEshaan Nichani, Alex Damian, Jason D. LeeICML 2024 · 117 次引用
  2. The Evolution of Statistical Induction Heads: In-Context Learning Markov ChainsEzra Edelman, Nikolaos Tsilivis, Benjamin L. Edelman, Eran Malach 等NeurIPS 2024 · 140 次引用
  3. What needs to go right for an induction head? A mechanistic study of in-context learning circuits and their formationAaditya K. Singh, Ted Moskovitz, Felix Hill, Stephanie C. Y. Chan 等ICML 2024 · 77 次引用
  4. Beyond Induction Heads: In-Context Meta Learning Induces Multi-Phase Circuit EmergenceGouki Minegishi, Hiroki Furuta, Shohei Taniguchi, Yusuke Iwasawa 等ICML 2025
  5. Unveiling Induction Heads: Provable Training Dynamics and Feature Learning in TransformersSiyu Chen, Heejune Sheen, Tianhao Wang, Zhuoran YangNeurIPS 2024 · 48 次引用
黄昏的海面,两侧是细线勾勒的悬崖