arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2505.03189cs.AIcs.HC
收藏

对比激活工程(Contrastive Activation Engineering)的模式与机制

Patterns and Mechanisms of Contrastive Activation Engineering

Georgia Institute of Technology(佐治亚理工学院)

Yixiong Hao, Ayush Panda, Stepan Shabalin, Sheikh Abdur Raheem Ali

AI总结:

本文系统分析了对比激活工程(CAE)在分布内与分布外场景下的表现,揭示了其仅在分布内有效、约80个样本后收益递减、易受对抗输入影响、损害模型困惑度以及大模型更具抵抗力等关键机制,并据此提出部署指导原则。

摘要:

控制大型语言模型(LLMs)的行为仍然是一项重大挑战,原因在于其固有的复杂性和不透明性。尽管微调等技术可以修改模型行为,但它们通常需要大量的计算资源。近期工作引入了一类对比激活工程(Contrastive Activation Engineering,CAE)技术,作为通过对模型内部表示进行有针对性的修改来引导 LLM 输出的有前景的方法。CAE 在推理时以零成本应用,有潜力引入一种灵活的、任务特定的 LLM 行为调节新范式。我们分析了 CAE 在分布内和分布外设置中的性能,评估了其缺点,并开始为其有效部署制定全面的指导原则。我们发现:1. CAE 仅在应用于分布内上下文时才可靠有效。2. 增加用于生成引导向量(steering vectors)的样本数量在约 80 个样本时收益递减。3. 引导向量容易受到对抗性输入的影响,这些输入会逆转其所引导的行为。4. 引导向量会损害模型的整体困惑度(perplexity)。5. 更大的模型对引导引起的退化更具抵抗力。

英文摘要:

Controlling the behavior of Large Language Models (LLMs) remains a significant challenge due to their inherent complexity and opacity. While techniques like fine-tuning can modify model behavior, they typically require extensive computational resources. Recent work has introduced a class of contrastive activation engineering (CAE) techniques as promising approaches for steering LLM outputs through targeted modifications to their internal representations. Applied at inference-time with zero cost, CAE has the potential to introduce a new paradigm of flexible, task-specific LLM behavior tuning. We analyze the performance of CAE in in-distribution, out-of-distribution settings, evaluate drawbacks, and begin to develop comprehensive guidelines for its effective deployment. We find that 1. CAE is only reliably effective when applied to in-distribution contexts. 2. Increasing the number of samples used to generate steering vectors has diminishing returns at around 80 samples. 3. Steering vectors are susceptible to adversarial inputs that reverses the behavior that is steered for. 4. Steering vectors harm the overall model perplexity. 5. Larger models are more resistant to steering-induced degradation.

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

↑