通过调整隐向量实现大模型情感生成的精准控制。
Controllable Affective Generation via Latent Vector Steering

- 从情绪化与中性回复中提取情感方向向量,实现情感调控。
- 在3个模型、8种情绪上提升情感表现力,保持语义连贯性。
- 无需更新权重,适合部署后实时调节情感强度,适用客服等场景。
大型语言模型(LLMs)在对齐后常产生情感平淡的回应,限制了其在情感敏感场景中的应用。本文提出EmoVec,一种基于隐向量调制的轻量级情感可控生成框架。EmoVec利用对比激活叠加方法,从成对的中性与情绪化回复中提取特定情感方向,并通过任务特异性去偏和主子空间移除进一步优化。推理时,将这些向量注入最终残差流,采用静态或情境自适应缩放,实现情感强度的连续控制,无需更新模型权重。在三个LLM和八种情绪上的实验表明,EmoVec能持续增强情感显著性,同时基本保持语义内容、流畅性和连贯性。消融实验与人工评估进一步验证了向量净化和自适应缩放的有效性,确立EmoVec作为部署后大模型情感控制的实用推理级方法。
原文摘要 · Abstract (English)
Large Language Models (LLMs) often produce emotionally flattened responses after alignment, limiting their effectiveness in affect-sensitive applications. In this paper, we propose EmoVec, a lightweight framework for controllable affective generation via latent vector steering. EmoVec extracts emotion-specific directions from paired neutral and emotion-conditioned responses using contrastive activation addition, and further refines them through task-specific debiasing and principal subspace removal. During inference, these vectors are injected into the final residual stream with static or scenario-adaptive scaling, enabling continuous control over emotional intensity without updating model weights. Experiments across three LLMs and eight emotions show that EmoVec consistently improves emotional salience while largely preserving semantic content, fluency, and coherence. Ablation studies and human evaluation further confirm the effectiveness of vector purification and adaptive scaling, establishing EmoVec as a practical inference-time method for affective control in deployed LLMs.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。