解构上下文学习:通过破坏理解提示词
Deconstructing In-Context Learning: Understanding Prompts via Corruption
AI总结:
本研究通过分解提示词的四个组件并施加结构与语义破坏,评估了1.5B至70B规模模型在十个数据集上的性能,发现重复文本可提升性能,大模型对语义更敏感,且添加任务与内联指令即使受损也能提升性能。
摘要:
大型语言模型(LLMs)基于提供的提示词进行“上下文学习”的能力,促使其使用量爆炸式增长,最终导致 ChatGPT、Claude 和 Bard 等 AI 助手的激增。这些 AI 助手对微小的提示词修改具有鲁棒性,这主要归功于使用人类反馈的对齐技术。相比之下,它们作为骨干的底层预训练 LLMs 在这方面则显得脆弱。构建高质量骨干模型仍是一项核心挑战,评估其质量的常见方法是进行少样本评估。此类评估因对微小的提示词修改以及特定上下文示例的选择高度敏感而声名狼藉。先前的工作研究了修改提示词的不同元素如何影响模型性能。然而,这些早期研究往往集中于有限的特定提示词属性,且常产生相互矛盾的结果。此外,以往的研究要么专注于参数少于 150 亿的模型,要么专门研究如 GPT-3 或 PaLM 等黑盒模型,使得复现具有挑战性。在本研究中,我们将整个提示词分解为四个组件:任务描述、示例输入、标签,以及为每个示例提供的内联指令。我们研究了这些元素的结构和语义破坏对模型性能的影响。我们研究了规模从 1.5B 到 70B 的模型,使用了涵盖分类和生成任务的十个数据集。我们发现,在提示词中重复文本能提升模型性能,而更大的模型(≥30B)对提示词的语义更敏感。最后,我们观察到,即使指令在语义上被破坏,在示例中添加任务和内联指令也能提升模型性能。
英文摘要:
The ability of large language models (LLMs) to $``$learn in context$"$ based on the provided prompt has led to an explosive growth in their use, culminating in the proliferation of AI assistants such as ChatGPT, Claude, and Bard. These AI assistants are known to be robust to minor prompt modifications, mostly due to alignment techniques that use human feedback. In contrast, the underlying pre-trained LLMs they use as a backbone are known to be brittle in this respect. Building high-quality backbone models remains a core challenge, and a common approach to assessing their quality is to conduct few-shot evaluation. Such evaluation is notorious for being highly sensitive to minor prompt modifications, as well as the choice of specific in-context examples. Prior work has examined how modifying different elements of the prompt can affect model performance. However, these earlier studies tended to concentrate on a limited number of specific prompt attributes and often produced contradictory results. Additionally, previous research either focused on models with fewer than 15 billion parameters or exclusively examined black-box models like GPT-3 or PaLM, making replication challenging. In the present study, we decompose the entire prompt into four components: task description, demonstration inputs, labels, and inline instructions provided for each demonstration. We investigate the effects of structural and semantic corruptions of these elements on model performance. We study models ranging from 1.5B to 70B in size, using ten datasets covering classification and generation tasks. We find that repeating text within the prompt boosts model performance, and bigger models ($\geq$30B) are more sensitive to the semantics of the prompt. Finally, we observe that adding task and inline instructions to the demonstrations enhances model performance even when the instructions are semantically corrupted.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。