让大模型更精准地挑选任务相关示例,提升少样本学习效果。
TDR: Task-Decoupled Retrieval with Fine-Grained LLM Feedback for In-Context Learning
- 将不同任务的示例解耦,提升检索针对性
- 利用大模型细粒度反馈指导检索训练,准确率显著提升
- 无需改动模型即可接入,适合各类大模型使用
少样本学习(ICL)依赖输入输出示例的质量。现有方法虽提升了检索能力,但仍面临两大挑战:跨任务数据分布难以区分,以及检索结果与大模型反馈之间的细粒度关联不足。本文提出TDR框架,通过解耦多任务数据中的不同任务示例,使检索模块能从混合数据中精准定位目标任务的示例。同时,TDR建模大模型的细粒度反馈,用于监督和引导检索模块训练,从而提升检索质量。我们在30个NLP任务上进行了广泛实验,结果表明TDR在所有数据集上均实现一致提升,达到当前最优性能。该方法为即插即用设计,可适配多种大模型,有效增强ICL的示例检索能力。代码已开源。
原文摘要 · Abstract (English)
In-context learning (ICL) has become a classic approach for enabling LLMs to handle various tasks based on a few input-output examples. The effectiveness of ICL heavily relies on the quality of these examples, and previous works which focused on enhancing example retrieval capabilities have achieved impressive performances. However, two challenges remain in retrieving high-quality examples: (1) Difficulty in distinguishing cross-task data distributions, (2) Difficulty in making the fine-grained connection between retriever output and feedback from LLMs. In this paper, we propose a novel framework called TDR. TDR decouples the ICL examples from different tasks, which enables the retrieval module to retrieve examples specific to the target task within a multi-task dataset. Furthermore, TDR models fine-grained feedback from LLMs to supervise and guide the training of the retrieval module, which helps to retrieve high-quality examples. We conducted extensive experiments on a suite of 30 NLP tasks, the results demonstrate that TDR consistently improved results across all datasets and achieves state-of-the-art performance. Meanwhile, our approach is a plug-and-play method, which can be easily combined with various LLMs to improve example retrieval abilities for ICL. The code is available at https://github.com/Nnn-s/TDR.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。