arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2501.15030cs.LGcs.AIcs.CLcs.PF
收藏

OptiSeq:为上下文学习即时排序示例

OptiSeq: Ordering Examples On-The-Fly for In-Context Learning

UC Irvine(加州大学欧文分校);IBM Research AI(IBM研究院人工智能部门)

Rahul Atul Bhope, Praveen Venkateswaran, K. R. Jayaram, Vatche Isahagian, Vinod Muthusamy, Nalini Venkatasubramanian

AI总结:

针对ICL对示例顺序敏感的问题,提出纯推理时、无需数据集的OptiSeq方法,利用输出对数概率剪枝排序搜索空间并推荐最佳顺序,在多任务上提升准确率5.5至10.5个百分点。

摘要:

在应用中使用LLM和基于LLM的智能体的开发者已经提供了大量轶事证据,表明上下文学习(ICL)十分脆弱。本文表明,除示例的数量和质量外,提示中上下文示例的列出顺序也会影响LLM的输出,进而影响其性能。尽管先前工作已探索通过依赖数据集的技术改进ICL,我们提出OptiSeq,这是一种纯推理时、无需数据集的优化方法,可高效确定最佳示例顺序。OptiSeq利用LLM生成输出的对数概率,系统性地剪枝可能排序的搜索空间,并通过区分产生高准确率的排序与表现不佳的排序来推荐最佳顺序。在多个LLM、数据集和提示上的大量实证评估表明,OptiSeq在多个任务中将准确率提高了5.5至10.5个百分点。

英文摘要:

Developers using LLMs and LLM-based agents in their applications have provided plenty of anecdotal evidence that in-context-learning (ICL) is fragile. In this paper, we show that in addition to the quantity and quality of examples, the order in which the in-context examples are listed in the prompt affects the output of the LLM and, consequently, their performance. While prior work has explored improving ICL through dataset-dependent techniques, we introduce OptiSeq, a purely inference-time, dataset-free optimization method that efficiently determines the best example order. OptiSeq leverages log probabilities of LLM-generated outputs to systematically prune the search space of possible orderings and recommend the best order(s) by distinguishing orderings that yield high levels of accuracy and those that underperform. Extensive empirical evaluation on multiple LLMs, datasets, and prompts demonstrate that OptiSeq improves accuracy by 5.5 - 10.5 percentage points across multiple tasks.

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

↑