CORTEXA
← Browse
arxivcs.AIcs.CL2026-07-07

When Does In-Context Search Help? A Sampling-Complexity Theory of Reflection-Driven Reasoning

Yotam Wolf, Noam Wies, Amnon Shashua

Training large language models (LLMs) with extended reasoning has enabled in-context search, in which models iteratively generate, critique, and revise solution attempts. We provide a theoretical analysis of in-context search by modeling it as approximate inference over reasoning traces, where the base model defines a prior and self-reflection provides feedback for posterior updates, and study the resulting inference-time sampling complexity - the number of sequential attempts needed to achieve high success probability. We show that when reflections reliably localize early mistakes, in-context search can yield exponential improvements over the base model, solving problems with exponentially small zero-shot pass rates using only a polynomial number of sequential attempts, whereas when this property fails, conditioning on past attempts offers no asymptotic benefit over parallel sampling. We further show that these gains are robust and learnable: approximate posterior updates suffice, and cross-entropy training on search rollouts recovers the required behavior with polynomial sample complexity. Finally, we show that under a stagewise abstraction of reinforcement learning with verifiable rewards, the optimal policy extension implements the same posterior reweighting rule. We validate key qualitative predictions of the theory on real large reasoning models.

View free PDFSource page

Related papers

arxivcs.CLcs.AI2026-06-28

LC-ICL: Label-Guided Contrastive In-Context Learning for Robust Information Extraction

Xiao You, Tianwei Yan, Shan Zhao

There has been increasing interest in exploring the capabilities of advanced large language models (LLMs) in the field of information extraction (IE), specifically focusing on tasks related to named entity recognition (NER) and relation extraction (RE).Although researchers are ex…

View free PDFSource page
arxivcs.CLcs.AI2026-07-10

WildTrace: Benchmarking Natural Evidence Trails in Long-Context Reasoning

Zixin Chen, Peng Liu, Haobo Li, Rui Sheng, Jianhong Tu, Xiaodong Deng, et al.

Answering complex questions over long documents frequently requires integrating evidence that the source itself disperses naturally across distant passages. In an incident report, the operating condition, design flaw, and missed safety check that jointly explain a disaster may ap…

View free PDFSource page
arxivcs.CLcs.AIcs.LG2026-06-29

MATCH: Modulating Attention via In-Context Retrieval for Long-Context Transformers

Linrui Ma, Chun Hei Lo, Xinyu Wang, Peng Lu, Xihao Yuan, Hanting Chen, et al.

The quadratic computational cost of traditional attention mechanisms poses a major bottleneck to the scalability and practical deployment of large language models (LLMs), particularly in long-context scenarios. To improve efficiency, existing approaches often enforce rigid struct…

View free PDFSource page
arxivcs.CLcs.AI2026-07-21

Copy Less, Ground More: Overcoming Repetitive Copying in Long-Context Reasoning via Evidence-Aware Reinforcement Learning

Lizhe Fang, Weizhou Shen, Tianyi Tang, Yisen Wang

Large language models that generate step-by-step reasoning traces have achieved strong performance on complex tasks, and extending them to long-context settings has emerged as an important frontier. However, we identify a critical failure mode in this regime: \emph{repetitive cop…

View free PDFSource page
arxivcs.CLcs.AI2026-07-03

The Role of Prompt Language and Translation-Theory-Driven Prompts in Large Language Models: A Case Study on Spanish-Chinese Journalistic Translation

Haohong Lai, Weijia Li

This study examines how prompt language and translation theory-driven prompt design influence the quality of Spanish-Chinese journalistic translations generated by GPT-5.2. A parallel corpus of four editorials from El Pais was translated under 48 experimental conditions (4 prompt…

View free PDFSource page