Lune

NeurIPS2024顶会

In-Context Learning with Transformers: Softmax Attention Adapts to Function Lipschitzness

Liam Collins, Advait Parulekar, Aryan Mokhtari, Sujay Sanghavi, Sanjay Shakkottai

摘要

A striking property of transformers is their ability to perform in-context learning (ICL), a machine learning framework in which the learner is presented with a novel context during inference implicitly through some data, and tasked with making a prediction in that context. As such, that learner must adapt to the context without additional training. We explore the role of softmax attention in an ICL setting where each context encodes a regression task. We show that an attention unit learns a window that it uses to implement a nearest-neighbors predictor adapted to the landscape of the pretraining tasks. Specifically, we show that this window widens with decreasing Lipschitzness and increasing label noise in the pretraining tasks. We also show that on low-rank, linear problems, the attention unit learns to project onto the appropriate subspace before inference. Further, we show that this adaptivity relies crucially on the softmax activation and thus cannot be replicated by the linear activation often studied in prior theoretical analyses.

问 Lune

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

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

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

可以从这些问题问起

Lune 可以查阅

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

获取答案

免费开始,无需绑卡

脉络

  • Fine-grained Analysis of In-context Linear Estimation: Data, Architecture, and Beyond 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • Fine-grained Analysis of In-context Linear Estimation: Data, Architecture, and Beyond 引用了 Language Models are Few-Shot Learners
  • Fine-grained Analysis of In-context Linear Estimation: Data, Architecture, and Beyond 引用了 Transformers Learn In-Context by Gradient Descent
  • Fine-grained Analysis of In-context Linear Estimation: Data, Architecture, and Beyond 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • Towards Understanding How Transformers Learn In-context Through a Representation Learning Lens 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • Towards Understanding How Transformers Learn In-context Through a Representation Learning Lens 引用了 Language Models are Few-Shot Learners
  • Towards Understanding How Transformers Learn In-context Through a Representation Learning Lens 引用了 Transformers Learn In-Context by Gradient Descent
  • Towards Understanding How Transformers Learn In-context Through a Representation Learning Lens 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • An Explanation of In-context Learning as Implicit Bayesian Inference 引用了 Language Models are Few-Shot Learners
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When 引用了 An Explanation of In-context Learning as Implicit Bayesian Inference
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When 引用了 Language Models are Few-Shot Learners
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When 引用了 Transformers Learn In-Context by Gradient Descent
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When 引用了 What Can Transformers Learn In-Context? A Case Study of Simple Function Classes
  • 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
  • What Can Transformers Learn In-Context? A Case Study of Simple Function Classes 引用了 Are Transformers universal approximators of sequence-to-sequence functions?
  • From Condensation to Rank Collapse: A Two-Stage Analysis of Transformer Training Dynamics 引用了 Language Models are Few-Shot Learners
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper12

  1. Towards Understanding How Transformers Learn In-context Through a Representation Learning LensRuifeng Ren, Yong LiuNeurIPS 2024 · 26 次引用
  2. Fine-grained Analysis of In-context Linear Estimation: Data, Architecture, and BeyondYingcong Li, Ankit Singh Rawat, Samet OymakNeurIPS 2024 · 24 次引用
  3. From Condensation to Rank Collapse: A Two-Stage Analysis of Transformer Training DynamicsZheng-An Chen, Tao LuoNeurIPS 2025 · 13 次引用
  4. On the Power of Convolution-Augmented TransformerMingchen Li, Xuechen Zhang, Yixiao Huang, Samet OymakAAAI 2025 · 7 次引用
  5. From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and WhenKevin Christian Wibisono, Yixin WangNeurIPS 2024 · 5 次引用

它引用的 Paper35

  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. Are Transformers universal approximators of sequence-to-sequence functions?Chulhee Yun, Srinadh Bhojanapalli, Ankit Singh Rawat, Sashank J. Reddi 等ICLR 2020 · 481 次引用

相关 Paper

  1. Transformers Efficiently Perform In-Context Logistic Regression via Normalized Gradient DescentChenyang Zhang, Yuan CaoICML 2026 · 1 次引用
  2. The Closeness of In-Context Learning and Weight Shifting for Softmax RegressionShuai Li, Zhao Song, Yu Xia, Tong Yu 等NeurIPS 2024 · 53 次引用
  3. One-Layer Transformer Provably Learns One-Nearest Neighbor In ContextZihao Li, Yuan Cao, Cheng Gao, Yihan He 等NeurIPS 2024 · 25 次引用
  4. How Many Pretraining Tasks Are Needed for In-Context Learning of Linear Regression?Jingfeng Wu, Difan Zou, Zixiang Chen, Vladimir Braverman 等ICLR 2024 · 94 次引用
  5. In-Context Linear Regression Demystified: Training Dynamics and Mechanistic Interpretability of Multi-Head Softmax AttentionJianliang He, Xintian Pan, Siyu Chen, Zhuoran YangICML 2025
黄昏的海面,两侧是细线勾勒的悬崖