Recent studies have demonstrated that In-Context Learning (ICL), through the use of specific demonstrations, can align Large Language Models (LLMs) with human preferences known as In-Context Alignment (ICA), indicating that models can comprehend human instructions without requiring parameter adjustments. However, the exploration of the mechanism and applicability of ICA remains limited. In this paper, we begin by dividing the context text used in ICA into three categories: format, system prompt, and example. Through ablation experiments, we investigate the effectiveness of each part in enabling ICA to function effectively. We then examine how variants in these parts impact the model's alignment performance. Our findings indicate that the example part is crucial for enhancing the model's alignment capabilities, with changes in examples significantly affecting alignment performance. We also conduct a comprehensive evaluation of ICA's zero-shot capabilities in various alignment tasks. The results indicate that compared to parameter fine-tuning methods, ICA demonstrates superior performance in knowledge-based tasks and tool-use tasks. However, it still exhibits certain limitations in areas such as multi-turn dialogues and instruction following.
翻译:近期研究表明,通过使用特定示例,上下文学习(ICL)能够将大语言模型(LLM)与人类偏好对齐,即上下文对齐(ICA),这表明模型无需调整参数即可理解人类指令。然而,关于ICA机制与适用性的探索仍较为有限。本文首先将ICA中使用的上下文文本划分为三类:格式、系统提示和示例。通过消融实验,我们研究了各部分在实现ICA有效运作中的作用。随后,我们探究了这些部分的变体如何影响模型的对齐性能。研究结果表明,示例部分对于提升模型对齐能力至关重要,示例的改动会显著影响对齐效果。我们还对ICA在各种对齐任务中的零样本能力进行了全面评估。结果显示,与参数微调方法相比,ICA在知识型任务和工具使用任务中表现出更优性能,但在多轮对话和指令遵循等领域仍存在一定局限性。