Lune

ICLR2024Top-tier venue

Understanding In-Context Learning from Repetitions

Jianhao Yan, Jin Xu, Chiyu Song, Chenming Wu, Yafu Li, Yue Zhang

Abstract

This paper explores the elusive mechanism underpinning in-context learning in Large Language Models (LLMs). Our work provides a novel perspective by examining in-context learning via the lens of surface repetitions. We quantitatively investigate the role of surface features in text generation, and empirically establish the existence of token co-occurrence reinforcement, a principle that strengthens the relationship between two tokens based on their contextual co-occurrences. By investigating the dual impacts of these features, our research illuminates the internal workings of in-context learning and expounds on the reasons for its failures. This paper provides an essential contribution to the understanding of in-context learning and its potential limitations, providing a fresh perspective on this exciting capability.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

11 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Measuring Massive Multitask Language Understanding cites Language Models are Few-Shot Learners
  • Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order Sensitivity cites Language Models are Few-Shot Learners
  • Parallel Structures in Pre-training Data Yield In-Context Learning cites Language Models are Few-Shot Learners
  • Parallel Structures in Pre-training Data Yield In-Context Learning cites Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When cites Parallel Structures in Pre-training Data Yield In-Context Learning
  • From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When cites Language Models are Few-Shot Learners
  • Unraveling the Mechanics of Learning-Based Demonstration Selection for In-Context Learning cites Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order Sensitivity
  • Unraveling the Mechanics of Learning-Based Demonstration Selection for In-Context Learning cites Language Models are Few-Shot Learners
  • Language Models are Few-Shot Learners cites The Curious Case of Neural Text Degeneration
  • Unveiling Attractor Cycles in Large Language Models: A Dynamical Systems View of Successive Paraphrasing cites Language Models are Few-Shot Learners
  • Unveiling Attractor Cycles in Large Language Models: A Dynamical Systems View of Successive Paraphrasing cites The Curious Case of Neural Text Degeneration
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers11

  1. Unraveling the Mechanics of Learning-Based Demonstration Selection for In-Context LearningHui Liu, Wenya Wang, Hao Sun, Chris Xing Tian et al.ACL 2025 · 13 citations
  2. From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and WhenKevin Christian Wibisono, Yixin WangNeurIPS 2024 · 5 citations
  3. Unveiling Attractor Cycles in Large Language Models: A Dynamical Systems View of Successive ParaphrasingZhilin Wang, Yafu Li, Jianhao Yan, Yu Cheng et al.ACL 2025 · 3 citations
  4. FIRE-Bench: Evaluating AI Agents on the Rediscovery of Scientific InsightsZhen Wang, Fan Bai, Zhongyan Luo, Jinyan Su et al.ICML 2026 · 2 citations
  5. Parallel Structures in Pre-training Data Yield In-Context LearningYanda Chen, Chen Zhao, Zhou Yu, Kathleen R. McKeown et al.ACL 2024 · 1 citation

Builds on20

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
  2. Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma et al.NeurIPS 2022 · 22,562 citations
  3. Measuring Massive Multitask Language UnderstandingDan Hendrycks, Collin Burns, Steven Basart, Andy Zou et al.ICLR 2021 · 7,905 citations
  4. The Curious Case of Neural Text DegenerationAri Holtzman, Jan Buys, Li Du, Maxwell Forbes et al.ICLR 2020 · 4,112 citations
  5. Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order SensitivityYao Lu, Max Bartolo, Alastair Moore, Sebastian Riedel et al.ACL 2022 · 1,494 citations

Related papers

  1. Improving Input-label Mapping with Demonstration Replay for In-context LearningZhuocheng Gong, Jiahao Liu, Qifan Wang, Jingang Wang et al.EMNLP Findings 2023
  2. Towards Auto-Regressive Next-Token Prediction: In-context Learning Emerges from GeneralizationZixuan Gong, Xiaolin Hu, Huayi Tang, Yong LiuICLR 2025
  3. Task Descriptors Help Transformers Learn Linear Models In-ContextRuomin Huang, Rong GeICLR 2025
  4. Sparse Autoencoders Reveal Temporal Difference Learning in Large Language ModelsCan Demircan, Tankred Saanum, Akshay Kumar Jagadish, Marcel Binz et al.ICLR 2025 · 1 citation
  5. Label Words are Anchors: An Information Flow Perspective for Understanding In-Context LearningLean Wang, Lei Li, Damai Dai, Deli Chen et al.EMNLP 2023 · 26 citations
Dusk over the sea between two cliffs drawn in fine vertical lines