arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2311.09606cs.CL
收藏

GistScore:利用Gist瓶颈学习更好的上下文示例选择表示

GistScore: Learning Better Representations for In-Context Example Selection with Gist Bottlenecks

University of California, Irvine(加利福尼亚大学欧文分校);ASAPP(ASAPP公司)

Shivanshu Gupta, Clemens Rosenbaum, Ethan R. Elenberg

AI总结:

本文提出Example Gisting方法,通过注意力瓶颈训练示例编码器并构建GistScore指标,用于上下文学习中的示例选择,在21个数据集上取得最先进性能,多任务模型可免训练泛化且速度提升三个数量级。

摘要:

上下文学习(In-Context Learning,ICL)是大语言模型(Large Language Models,LLMs)在给定包含少量任务示例的提示时执行新任务的能力。然而,ICL性能可能对示例的选择极为敏感。为了为每个测试输入动态选择最佳示例,我们提出了Example Gisting,这是一种通过监督微调训练示例编码器的新方法,并在输入和输出之间引入注意力瓶颈。这些gist模型构成了GistScore的基础,GistScore是一种用于评分和选择信息丰富示例的新指标。此外,我们实验了两种变体:(1)为每个数据集微调gist模型;(2)在大量数据集集合上多任务训练单一模型。后者可直接用于新任务,无需额外训练,从而实现免训练的ICL流程。在涵盖9个任务和8个不同LLM的21个数据集上的评估表明,我们微调的模型取得了最先进的ICL性能,比现成的检索器绝对提升超过20%,比之前最好的方法提升5%。此外,我们的多任务模型能很好地泛化到新任务、新数据集和新提示模板。使用该模型进行示例选择与先前方法相当或更优,同时比最强的免训练基线快三个数量级。

英文摘要:

In-context Learning (ICL) is the ability of Large Language Models (LLMs) to perform new tasks when conditioned on prompts comprising a few task examples. However, ICL performance can be critically sensitive to the choice of examples. To dynamically select the best examples for every test input, we propose Example Gisting, a novel approach for training example encoders through supervised fine-tuning with an attention bottleneck between the inputs and outputs. These gist models form the basis for GistScore, a novel metric for scoring and selecting informative examples. Further, we experiment with two variations: (1) fine-tuning gist models for each dataset and (2) multi-task training a single model on a large collection of datasets. The latter can be used for new tasks out-of-the-box, enabling a training-free ICL pipeline. Evaluations with 21 datasets spanning 9 tasks and 8 diverse LLMs show that our fine-tuned models get state-of-the-art ICL performance with over 20% absolute gain over off-the-shelf retrievers and 5% over the best prior methods. Further, our multi-task model generalizes well to new tasks, datasets, and prompt templates. Selection using this model matches or outperforms prior methods while being three orders of magnitude faster than the strongest training-free baseline.

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

↑