cs.LGOct 16, 2026

Out of Support, Not Out of Reach: In-Context Learning with Unsupported Instructions and Composed Tasks

Authors: Xuhan Tong, Yuchen Zeng, Jiawei Zhang

Organizations: Department of Computer Sciences, University of Wisconsin–Madison. · Microsoft Research.

Abstract

In-Context Learning (ICL) enables pretrained LLMs to adapt to downstream tasks from a small set of input-output demonstrations, without parameter updates. Yet existing theory primarily explains ICL as identifying a latent task already represented in pretraining, leaving unclear whether ICL can succeed when either the instruction or the target task falls outside the pretraining support. We develop a theoretical framework under mild assumptions that separates these two forms of distribution shift. For target tasks represented in pretraining, we show that demonstrations can identify the task and reduce sensitivity to pretrain-supported prompt templates as their number increases. For an unsupported instruction, we show that under a fixed model-induced reference extension, demonstration evidence can dominate an NN-independent instruction shift while preserving the exponential identification rate. We then use the same ICL framework as an interpretive lens for long-horizon target tasks that are not represented in pretraining but admit a plan that decomposes them into pretraining-supported subtasks. Applying the supported-task analysis step by step yields a standard accumulated-error bound and clarifies how invoking familiar subtasks along an intermediate-state trajectory can avoid directly selecting the unsupported complete task. Together, our results characterize when demonstrations, instructions, and task decomposition can support ICL beyond the corresponding pretraining supports.

Figures & tables

Appendix figures & tables16 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. Demonstrations, CoT, and Prompting: A Theoretical Analysis of ICL

    Mar 20, 2026Xuhan Tong, Yuchen Zeng, Jiawei ZhangIn-Context LearningCoT Reasoning

  2. Capturing In-Context Learning Dynamics with Task Operators

    Oct 1, 2026Guangzhi Xiong, Zhenghao He, Bohan Liu +3Transformer InterpretabilityIn-Context Learning

  3. When Correct Demonstrations Hurt: Rethinking the Role of Exemplars in In-Context Learning

    May 25, 2026Chenghao Qiu, Chunli Peng, Yufeng Yang +2In-Context Learning