arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2305.14210cs.CLcs.AI
收藏

面向上下文学习的基于技能的少样本选择方法

Skill-Based Few-Shot Selection for In-Context Learning

Microsoft(微软);Northeastern University(东北大学);Microsoft Corporation(微软公司)

Shengnan An, Bo Zhou, Zeqi Lin, Qiang Fu, Bei Chen, Nanning Zheng, Weizhu Chen, Jian-Guang Lou

AI总结:

针对上下文学习中少样本选择易受表层特征干扰、难适配动态示例库的问题,提出无需训练微调的Skill-KNN方法,通过技能化描述消除冗余特征,在多数据集和骨干模型上性能显著优于现有方法。

摘要:

上下文学习是通过提供少量示例使大语言模型适配下游任务的范式。少样本选择——即为每个测试实例分别选取合适的示例——对上下文学习至关重要。本文提出Skill-KNN,一种面向上下文学习的基于技能的少样本选择方法。Skill-KNN的核心优势包括:(1)解决了现有基于预训练嵌入的方法易受对目标任务不重要的自然语言表层特征偏差影响的问题;(2)无需对任何模型进行训练或微调,适用于频繁扩展或变更的示例库。其核心思路是优化输入嵌入模型的内容,而非调整模型本身。技术上,Skill-KNN通过预处理少样本提示为每个测试用例和候选示例生成基于技能的描述,以此消除不重要的表层特征。在5个跨领域语义解析数据集和6个骨干模型上的实验结果表明,Skill-KNN显著优于现有方法。

英文摘要:

In-context learning is the paradigm that adapts large language models to downstream tasks by providing a few examples. Few-shot selection -- selecting appropriate examples for each test instance separately -- is important for in-context learning. In this paper, we propose Skill-KNN, a skill-based few-shot selection method for in-context learning. The key advantages of Skill-KNN include: (1) it addresses the problem that existing methods based on pre-trained embeddings can be easily biased by surface natural language features that are not important for the target task; (2) it does not require training or fine-tuning of any models, making it suitable for frequently expanding or changing example banks. The key insight is to optimize the inputs fed into the embedding model, rather than tuning the model itself. Technically, Skill-KNN generates the skill-based descriptions for each test case and candidate example by utilizing a pre-processing few-shot prompting, thus eliminating unimportant surface features. Experimental results across five cross-domain semantic parsing datasets and six backbone models show that Skill-KNN significantly outperforms existing methods.

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

↑