In-Context Example Selection

Overview

The field studies which labeled examples, demonstrations, or other context to place in a model’s prompt so it can generalize to a new query. Common approaches retrieve semantically similar examples, while others optimize for diversity and latent coverage, task-specific utility, decision-boundary cases, or signals from model activations; learned ranking, bandit, and reinforcement-learning methods also refine selections. Methods are evaluated across settings such as classification, reasoning, translation, multimodal tasks, and tabular prediction, often measuring accuracy alongside prompt length, latency, or robustness to noise. A central tension is that similarity is cheap but can miss useful contrasts, while more tailored selection can improve results yet may be costly or fail to transfer across models and tasks.

Latest papers

CardsList

32 papers3 papers in the last four weeks, down 50% on the four weeks before. 0.0% of all new papers.

  1. TabSieve: Explicit In-Table Evidence Selection for Tabular Prediction

    Feb 12, 2026Yongyao Wang, Ziqi Miao, Lu Yang +4In-Context Example SelectionReinforcement Learning

  2. Beyond Semantic Similarity: Reducing Unnecessary API Calls via Behavior-Aligned Retriever

    Aug 20, 2025Yixin Chen, Ying Xiong, Shangyu Wu +4In-Context Example SelectionIn-Context Retrieval