mlsanityData to 7 Oct 2026

In-Context Example Ordering Guided by Label Distributions

arXiv 2402.11447 ↗First posted 18 Feb 2024cs.CLcited by 12

Not on the map. Why?

Abstract (arXiv)

By allowing models to predict without task-specific training, in-context learning (ICL) with pretrained LLMs has enormous potential in NLP. However, a number of problems persist in ICL. In particular, its performance is sensitive to the choice and order of in-context examples. Given the same set of in-context examples with different orderings, model performance may vary between near random to near state-of-the-art. In this work, we formulate in-context example ordering as an optimization problem. We examine three problem settings that differ in the assumptions they make about what is known about the task. Inspired by the idea of learning from label proportions, we propose two principles for in-context example ordering guided by model's probability predictions. We apply our proposed principles to thirteen text classification datasets and nine different autoregressive LLMs with 700M to 13B parameters. We demonstrate that our approach outperforms the baselines by improving the classification accuracy, reducing model miscalibration, and also by selecting better in-context examples.

Key facts. Cited by 12 papers in the map (data through 7 Oct 2026). Builds on 26 of its 48 references that are in the map. First posted on arXiv 18 Feb 2024.

Builds on

26 of 48 references.

References · 26

  1. 2020Language Models are Few-Shot Learnerscited by 32,199
  2. 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
  3. 2023LLaMA: Open and Efficient Foundation Language Modelscited by 13,958
  4. 2022PaLM: Scaling Language Modeling with Pathwayscited by 5,304
  5. 2017On Calibration of Modern Neural Networkscited by 4,860
  6. 2022Large Language Models are Zero-Shot Reasonerscited by 4,323
  7. 2022OPT: Open Pre-trained Transformer Language Modelscited by 3,464
  8. 2015Character-level Convolutional Networks for Text Classificationcited by 2,293
  9. 2017Understanding Black-box Predictions via Influence Functionscited by 1,714
  10. 2022Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?cited by 1,413
  11. 2020Making Pre-trained Language Models Better Few-shot Learnerscited by 1,255
  12. 2021What Makes Good In-Context Examples for GPT-3?cited by 1,184
14 more
  1. 2021Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order Sensitivitycited by 1,122
  2. 2021An Explanation of In-context Learning as Implicit Bayesian Inferencecited by 915
  3. 2020TweetEval: Unified Benchmark and Comparative Evaluation for Tweet Classificationcited by 414
  4. 2013Good Debt or Bad Debt: Detecting Semantic Orientations in Economic Textscited by 310
  5. 2021Surface Form Competition: Why the Highest Probability Answer Isn't Always Rightcited by 256
  6. 2022Selective Annotation Makes Language Models Better Few-Shot Learnerscited by 242
  7. 2021Noisy Channel Language Model Prompting for Few-Shot Text Classificationcited by 163
  8. 2022Self-Adaptive In-Context Learning: An Information Compression Perspective for In-Context Example Selection and Orderingcited by 158
  9. 2022Z-ICL: Zero-Shot In-Context Learning with Pseudo-Demonstrationscited by 70
  10. 2023In-context Example Selection with Influencescited by 60
  11. 2022Data Curation Alone Can Stabilize In-context Learningcited by 58
  12. 2014On Learning from Label Proportionscited by 38
  13. 2019Deep multi-class learning from label proportionscited by 33
  14. 2022Learning from Label Proportions by Learning with Label Noisecited by 30

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2024: 5; 2025: 4; 2026: 3.

12 papers.