TLDR: This research paper by Adrian de Wynter investigates whether In-Context Learning (ICL) in large language models (LLMs) constitutes true learning. Through a large-scale empirical analysis, the study concludes that ICL is a learning mechanism, but it is limited in its ability to generalize to unseen tasks and is brittle to out-of-distribution data. Key findings include that optimal performance often requires 50-100 exemplars, ICL overfocuses on statistical features from the prompt, and performance varies significantly even for closely related tasks. The paper emphasizes the need for robust evaluation methodologies in LLM research.
A recent research paper titled ISIN-CONTEXTLEARNINGLEARNING? by Adrian de Wynter from Microsoft and the University of York delves into a fundamental question surrounding modern AI: does In-Context Learning (ICL) truly constitute ‘learning’ in large language models (LLMs)? This extensive study provides a nuanced answer, suggesting that while ICL is indeed a learning mechanism, it comes with distinct limitations.
In-context learning allows autoregressive models to tackle tasks by predicting the next token, without requiring additional training. This capability has led to claims that these models can ‘learn’ new tasks with just a few examples provided in the prompt. However, the paper argues that deduction isn’t always learning, as ICL doesn’t explicitly encode observations. Instead, models rely on their existing knowledge and the provided examples.
A Deep Dive into ICL’s Mechanisms
The research mathematically posits that ICL does qualify as learning, but its full characterization demands empirical investigation. To this end, the study undertook a large-scale analysis, meticulously examining ICL by accounting for or ablating factors such as memorization, pretraining, shifts in data distribution, and various prompting styles and phrasing.
The experiments involved four different LLMs, nine diverse tasks, and ablations on prompting strategies, training distributions, and exemplar setups, generating a massive 1.89 million predictions per LLM. This makes it one of the most comprehensive empirical explorations of ICL as a learning paradigm to date.
Key Findings and Insights
The study yielded several crucial findings that challenge prevailing notions about ICL:
-
Exemplar Quantity Matters: Contrary to the idea that ‘few-shot’ learning is sufficient, peak average performance was observed with 50-100 exemplars. As the number of exemplars increased, the accuracy gap between different LLMs and prompting strategies narrowed, and all strategies consistently improved accuracy.
-
Distributional Sensitivity: ICL demonstrated robustness to altered training (exemplar) distributions, even when exemplar positions or label proportions were randomized. However, it proved brittle when faced with altered test distributions (out-of-distribution or OOD data), especially with advanced prompting techniques like Chain-of-Thought (CoT) and Automated Prompt Optimization (APO).
-
Task Performance Inconsistency: Closely related tasks did not necessarily show similar performance levels, with accuracy gaps as wide as 31%. In fact, traditional machine learning baselines like decision trees and k-nearest neighbors outperformed ICL in half of the evaluated tasks on average.
-
Lexical Features vs. Data Features: The research found that ‘word salad’ prompts (where natural language descriptions were replaced with random words) eventually matched the performance of non-randomized baselines in the limit. This suggests that LLMs can distinguish data features from lexical relations. However, fully randomized exemplars significantly hampered accuracy, indicating that ICL overfocuses on statistical features from the prompt rather than deeper feature relations within the data.
Also Read:
- Assessing Foundation Models for Planning Assistance
- Small Language Models Show Promise in Formal Logic Reasoning for Ontology Engineering
Implications for LLM Research
The authors conclude that ICL is a legitimate learning mechanism, intrinsically linked to the autoregressive nature of LLMs rather than specific models, training strategies, or prompting styles. However, this learning often involves leveraging and overfocusing on statistical features within the prompt, which limits its ability to generalize across tasks, particularly when not relying on intrinsic knowledge.
The observed brittleness to OOD data highlights a critical point for future LLM research: performance evaluations must be conducted with caution and transparency. Relying on a few prompts or unrepresentative distributions can lead to spurious performance observations. Robust experimental work, therefore, should involve testing multiple prompts, varying numbers of shots, and diverse data distributions to truly characterize LLM capabilities.


