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

更多样本还是更多提示?探索面向LLM少样本提示工程的高效上下文内采样

More Samples or More Prompts? Exploring Effective In-Context Sampling for LLM Few-Shot Prompt Engineering

Rensselaer Polytechnic Institute(伦斯勒理工学院);Northeastern University(东北大学);Tongji University(同济大学);Shanghai Jiao Tong University(上海交通大学);Michigan State University(密歇根州立大学)

Bingsheng Yao, Guiming Chen, Ruishi Zou, Yuxuan Lu, Jiachen Li, Shao Zhang, Yisi Sang, Sijia Liu, James Hendler, Dakuo Wang

AI总结:

本文提出上下文内采样(ICS)技术,通过优化多个ICL提示输入的构建来提升LLM少样本性能,并在多个NLI和QA数据集上验证其有效性,同时探索了基于数据相似度的ICS策略。

摘要:

虽然现有关于LLM提示技术的大多数工作只关注如何在单个提示输入中选择一组更好的数据样本(上下文内学习,即In-Context Learning或ICL),但为什么我们不能设计并联合利用多个提示来进一步提升LLM的性能?在这项工作中,我们提出了上下文内采样(In-Context Sampling,ICS),这是一种低资源的LLM提示技术,通过优化多个ICL提示输入的构建来产生高置信度的预测。在四个NLI数据集(e-SNLI、Multi-NLI、ANLI和Contract-NLI)和一个QA数据集(CommonsenseQA)上,使用三个开源LLM(FlanT5-XL、Mistral-7B和Mixtral-8x7B)进行的大量实验表明,ICS能够持续提升LLM的性能。基于三种数据相似度的ICS策略的深入评估表明,这些策略可以进一步提高LLM的性能,这为未来一个新的且有前景的研究方向提供了启示。

英文摘要:

While most existing works on LLM prompting techniques focus only on how to select a better set of data samples inside one single prompt input (In-Context Learning or ICL), why can not we design and leverage multiple prompts together to further improve the LLM's performance? In this work, we propose In-Context Sampling (ICS), a low-resource LLM prompting technique to produce confident predictions by optimizing the construction of multiple ICL prompt inputs. Extensive experiments with three open-source LLMs (FlanT5-XL, Mistral-7B, and Mixtral-8x7B) on four NLI datasets (e-SNLI, Multi-NLI, ANLI, and Contract-NLI) and one QA dataset (CommonsenseQA) illustrate that ICS can consistently enhance LLMs' performance. An in-depth evaluation with three data similarity-based ICS strategies suggests that these strategies can further elevate LLM's performance, which sheds light on a new yet promising future research direction.

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

↑