[Paper Review] Active Example Selection for In-Context Learning
This paper proposes a reinforcement learning-based active example selection method for in-context learning, framing example selection as a sequential decision problem to improve model generalization. It achieves a 5.8% average accuracy gain on GPT-2 across unseen tasks and shows small improvements on GPT-3 Ada, with diminishing returns on larger GPT-3 models, highlighting emerging capabilities in larger models.
With a handful of demonstration examples, large-scale language models show strong capability to perform various tasks by in-context learning from these examples, without any fine-tuning. We demonstrate that in-context learning performance can be highly unstable across samples of examples, indicating the idiosyncrasies of how language models acquire information. We formulate example selection for in-context learning as a sequential decision problem, and propose a reinforcement learning algorithm for identifying generalizable policies to select demonstration examples. For GPT-2, our learned policies demonstrate strong abilities of generalizing to unseen tasks in training, with a $5.8\%$ improvement on average. Examples selected from our learned policies can even achieve a small improvement on GPT-3 Ada. However, the improvement diminishes on larger GPT-3 models, suggesting emerging capabilities of large language models.
Motivation & Objective
- To investigate the instability of in-context learning performance due to demonstration example selection.
- To develop a generalizable strategy for selecting effective demonstration examples across diverse tasks.
- To explore whether reinforcement learning can discover systematic, transferable policies for active example selection in low-shot in-context learning.
- To compare the behavior of GPT-2 and larger GPT-3 models in response to example selection, revealing differences in emergent capabilities.
- To provide insights into how large language models acquire information in-context and inform future research in the era of large-scale models.
Proposed method
- Formulates active example selection as a sequential decision-making problem using reinforcement learning.
- Trains a policy network to select unlabeled examples iteratively from a pool, based on predicted model performance.
- Uses a reward signal based on in-context learning accuracy on a validation set during training.
- Applies the trained policy to select examples for new tasks or unlabeled pools, evaluating zero-shot generalization.
- Employs a curriculum-style training setup where the policy learns from progressively complex tasks.
- Validates the policy on GPT-2 using 4-shot in-context learning and evaluates generalization to unseen tasks.
Experimental results
Research questions
- RQ1How does the performance of in-context learning vary with different sets of demonstration examples, especially for GPT-2?
- RQ2Can reinforcement learning discover generalizable policies for selecting demonstration examples that improve in-context learning across diverse tasks?
- RQ3How do the properties of effective demonstration examples differ from human intuitions?
- RQ4How does the performance gain from learned example selection vary across model scale, particularly between GPT-2 and larger GPT-3 models?
- RQ5To what extent do policies trained on GPT-2 generalize to GPT-3 models, and why do gains diminish on larger models?
Key findings
- The performance of in-context learning with GPT-2 shows high variance across different sets of demonstration examples, indicating instability in information acquisition.
- The proposed reinforcement learning-based active example selection policy improves in-context learning accuracy by 5.8% on average across unseen tasks for GPT-2.
- The policy achieves a 12.1% improvement over a max-entropy active learning baseline on a seen task with a labeled dataset for GPT-2.
- Selected examples from the learned policy yield a small but measurable improvement on GPT-3 Ada, suggesting transferability of learned selection strategies.
- The performance gain diminishes significantly on larger GPT-3 models (e.g., Babbage and Curie), indicating emerging capabilities that reduce reliance on curated examples.
- Analysis reveals that useful demonstration examples often deviate from human intuitions, suggesting non-trivial patterns in effective in-context learning.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.