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

从错误中进行上下文原则学习

In-Context Principle Learning from Mistakes

UC Berkeley(加州大学伯克利分校);Carnegie Mellon University(卡内基梅隆大学);Google DeepMind(谷歌DeepMind);AI2(艾伦人工智能研究所)

Tianjun Zhang, Aman Madaan, Luyu Gao, Steven Zheng, Swaroop Mishra, Yiming Yang, Niket Tandon, Uri Alon

AI总结:

本文提出LEAP框架,通过故意诱导模型在少样本示例上犯错并反思学习任务特定原则,在不增加输入的情况下显著提升了GPT-4等LLMs在多跳问答、文本问答、推理和数学问题等基准上的性能。

摘要:

上下文学习(ICL,也称为少样本提示)一直是将LLMs适应到下游任务的标准方法,通过从少量输入-输出示例中学习。然而,所有基于ICL的方法仅从正确的输入-输出对中学习。在本文中,我们重新审视这一范式,通过从给定的少量输入-输出示例中学习更多。我们引入了Learning Principles(LEAP):首先,我们故意诱导模型在这些少量示例上犯错;然后我们反思这些错误,并从中学习显式的任务特定“原则”,这些原则有助于解决类似问题并避免常见错误;最后,我们提示模型使用原始的少样本示例和这些学到的通用原则来回答未见过的测试问题。我们在广泛的基准上评估LEAP,包括多跳问答(Hotpot QA)、文本问答(DROP)、Big-Bench Hard推理和数学问题(GSM8K和MATH);在所有这些基准中,LEAP改进了可用的最强LLMs,如GPT-3.5-turbo、GPT-4、GPT-4 turbo和Claude-2.1。例如,使用GPT-4时,LEAP在DROP上比标准少样本提示提高了7.5%,在HotpotQA上提高了3.3%。重要的是,LEAP不需要比标准少样本提示设置更多的输入或示例。

英文摘要:

In-context learning (ICL, also known as few-shot prompting) has been the standard method of adapting LLMs to downstream tasks, by learning from a few input-output examples. Nonetheless, all ICL-based approaches only learn from correct input-output pairs. In this paper, we revisit this paradigm, by learning more from the few given input-output examples. We introduce Learning Principles (LEAP): First, we intentionally induce the model to make mistakes on these few examples; then we reflect on these mistakes, and learn explicit task-specific "principles" from them, which help solve similar problems and avoid common mistakes; finally, we prompt the model to answer unseen test questions using the original few-shot examples and these learned general principles. We evaluate LEAP on a wide range of benchmarks, including multi-hop question answering (Hotpot QA), textual QA (DROP), Big-Bench Hard reasoning, and math problems (GSM8K and MATH); in all these benchmarks, LEAP improves the strongest available LLMs such as GPT-3.5-turbo, GPT-4, GPT-4 turbo and Claude-2.1. For example, LEAP improves over the standard few-shot prompting using GPT-4 by 7.5% in DROP, and by 3.3% in HotpotQA. Importantly, LEAP does not require any more input or examples than the standard few-shot prompting settings.

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

↑