EMNLP Findings2023
How Many Demonstrations Do You Need for In-context Learning?
Jiuhai Chen, Lichang Chen, Chen Zhu, Tianyi Zhou
摘要
Large language models (LLMs) are capable to perform complex reasoning by in-context learning (ICL) when provided with a few inputoutput demonstrations (demos) and more powerful when intermediate reasoning steps ("chain of thoughts (CoT)") of the demos are given. Is it necessary to use multi-demo in ICL? In this paper, we study ICL using fewer demos for each test query on the tasks in (Wei et al., 2022). Surprisingly, we do not observe significant degradation when using only one randomly chosen demo. To study this phenomenon, for each test query, we categorize demos into "positive demos" leading to the correct answer, and "negative demos" resulting in wrong answers. Our analysis reveals an inherent bias in those widely studied datasets and the redundancy of demos: most demos are positive for a majority of test queries, which explains the good performance of ICL with one random demo. Moreover, ICL (with and w/o CoT) using only one positive demo significantly outperforms multidemo ICL adopted by most previous works, indicating the weakness of LLMs in finding positive demo(s) for input queries, which is difficult to evaluate on the biased datasets. Furthermore, we observe a counterintuitive behavior of ICL using multi-demo, i.e., its accuracy degrades(improves) when given more positive(negative) demos. This implies that ICL can be easily misguided by interference among demos and their spurious correlations. Our analyses highlight several fundamental challenges that need to be addressed in LLMs training, ICL, and benchmark design.
问 Lune
尽管问,回答会引用原文。
Lune 会读完全文和相关的 Paper,每个回答都附上所依据的原文段落。
引用它的顶会 Paper12
- Cost-Effective In-Context Learning for Entity Resolution: A Design Space ExplorationMeihao Fan, Xiaoyue Han, Ju Fan, Chengliang Chai 等ICDE 2024 · 40 次引用
- Quantifying Uncertainty in Answers from any Language Model and Enhancing their TrustworthinessJiuhai Chen, Jonas MuellerACL 2024 · 21 次引用
- ICL-Router: In-Context Learned Model Representations for LLM RoutingChenxu Wang, Hao Li, Yiqun Zhang, Linyao Chen 等AAAI 2026 · 11 次引用
- MP: Endowing Large Language Models with Lateral ThinkingTian Bai, Yongwang Cao, Yan Ge, Haitao YuAAAI 2025 · 4 次引用
- Disentangling Latent Shifts of In-Context Learning with Weak SupervisionJosip Jukic, Jan SnajderNeurIPS 2025 · 3 次引用
它引用的 Paper8
- Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma 等NeurIPS 2022 · 22,562 次引用
- Calibrate Before Use: Improving Few-shot Performance of Language ModelsZihao Zhao, Eric Wallace, Shi Feng, Dan Klein 等ICML 2021 · 1,843 次引用
- Self-Consistency Improves Chain of Thought Reasoning in Language ModelsXuezhi Wang, Jason Wei, Dale Schuurmans, Quoc V. Le 等ICLR 2023 · 681 次引用
- Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?Sewon Min, Xinxi Lyu, Ari Holtzman, Mikel Artetxe 等EMNLP 2022 · 634 次引用
- Automatic Chain of Thought Prompting in Large Language ModelsZhuosheng Zhang, Aston Zhang, Mu Li, Alex SmolaICLR 2023 · 234 次引用
相关 Paper
- Task-Level Thinking Steps Help Large Language Models for Challenging Classification TaskChunhui Du, Jidong Tian, Haoran Liao, Jindou Chen 等EMNLP 2023 · 2 次引用
- The Impact of Reasoning Step Length on Large Language ModelsMingyu Jin, Qinkai Yu, Dong Shu, Haiyan Zhao 等ACL Findings 2024 · 39 次引用
- Towards Understanding Chain-of-Thought Prompting: An Empirical Study of What MattersBoshi Wang, Sewon Min, Xiang Deng, Jiaming Shen 等ACL 2023 · 100 次引用
- In-Context Learning with Iterative Demonstration SelectionChengwei Qin, Aston Zhang, Chen Chen, Anirudh Dagar 等EMNLP Findings 2024 · 19 次引用
- Revisiting Demonstration Selection Strategies in In-Context LearningKeqin Peng, Liang Ding, Yancheng Yuan, Xuebo Liu 等ACL 2024
