arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2511.09700cs.CL
收藏

顺序至关重要:重新思考上下文学习中的提示构建

Order Matters: Rethinking Prompt Construction in In-Context Learning

UC San Diego(圣迭戈大学);Cushing Academy(克什克尔学院)

Warren Li, Yiqian Wang, Zihan Wang, Jingbo Shang

AI总结:

本文针对上下文学习中重示例选择轻排序的普遍假设,通过多模型、多任务对照实验发现示例排序对性能的影响与示例选择相当,且可通过开发集识别优质排序,提示设计需同等重视二者。

摘要:

上下文学习(ICL)可让大语言模型通过基于示例序列进行条件设定来执行新任务。此前多数研究出于合理直觉假设,示例选择对性能的影响远大于示例排序方式,因此研究重点集中在示例选择上。我们重新审视这一假设,系统对比了示例选择与排序的效果。我们在分类与生成任务上开展对照实验,覆盖参数量0.5B到27B的多个开源模型族以及GPT-5,发现不同示例排序带来的性能方差,与使用完全不同示例集产生的性能方差相当。此外,我们证明仅使用开发集即可识别出优质排序,其性能接近基于测试标签选择最优排序的预言机(oracle)水平。我们的发现凸显了提示设计中示例选择与排序同等重要且相互交织,呼吁学界重新审视ICL领域的既有假设。

英文摘要:

In-context learning (ICL) enables large language models to perform new tasks by conditioning on a sequence of examples. Most prior work reasonably and intuitively assumes that which examples are chosen has a far greater effect on performance than how those examples are ordered, leading to a focus on example selection. We revisit this assumption and conduct a systematic comparison between the effect of selection and ordering. Through controlled experiments on both classification and generation tasks, using multiple open-source model families (0.5B to 27B parameters) and GPT-5, we find that the variance in performance due to different example orderings is comparable to that from using entirely different example sets. Furthermore, we show that strong orderings can be identified using only a development set, achieving performance close to an oracle that selects the best ordering based on test labels. Our findings highlight the equal and intertwined importance of example selection and ordering in prompt design, calling for a reexamination of the assumptions held in ICL.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑