Combating Instruction Conflict via Energy-Driven Latent Conflict Detection
作者: Mingyu Ma, Yuxin Wu, Jingbo Wang, Tianxiao Huang, Leixin Sun, Xiaochuan Shi
分类: cs.CL
发布日期: 2026-09-08
备注: 15 pages, 2 figures, 5 tables
💡 一句话要点
提出ELCD以解决大语言模型中的指令冲突问题
🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)
关键词: 指令冲突 潜在检测 响应漂移 大型语言模型 安全性 验证机制
📋 核心要点
- 现有方法主要依赖静态输入检查,无法有效检测响应漂移现象,导致模型输出可能违反系统约束。
- 本文提出ELCD,通过构建复合隐藏状态表示,优化潜在空间中的合规与漂移响应的区分。
- 实验结果显示,ELCD在多个主流LLMs上显著提升性能,尤其在PR-AUC和假阳性率方面表现优异。
📝 摘要(中文)
大型语言模型(LLMs)在使用层级指令时,容易出现用户指令与系统约束之间的冲突。现有的防御机制主要集中在静态输入检查,未能有效检测响应漂移现象,即模型最终响应违反系统约束。为此,本文提出了ELCD,一种用于生成后、交付前验证的响应级潜在冲突检测器。ELCD通过将最终标记嵌入与均值池化的响应嵌入连接,构建复合隐藏状态表示,并优化成对边际排名目标,以在潜在空间中区分合规和漂移响应。通过对五种主流LLMs的广泛实验,ELCD显著优于竞争基线,尤其在Llama-2-7B上提高了约30个百分点的PR-AUC,并将Mistral-7B在95% TPR下的假阳性率降低至2.67%。这些结果表明,ELCD为开放权重或自托管LLM部署中的潜在指令冲突检测提供了有前景的方法。
🔬 方法详解
问题定义:本文旨在解决大型语言模型中的指令冲突问题,现有方法无法有效检测响应漂移,导致模型输出不符合系统约束。
核心思路:ELCD通过构建复合隐藏状态表示,结合最终标记嵌入和均值池化的响应嵌入,优化潜在空间中的合规与漂移响应的区分,从而实现有效的冲突检测。
技术框架:ELCD的整体架构包括生成后、交付前的验证阶段,主要模块包括隐藏状态表示构建和边际排名优化。
关键创新:ELCD的主要创新在于其响应级潜在冲突检测方法,区别于传统的静态输入检查,能够动态识别潜在的指令冲突。
关键设计:在设计中,ELCD采用了成对边际排名损失函数,确保合规响应与漂移响应在潜在空间中的有效分离,同时优化了网络结构以提高检测精度。
🖼️ 关键图片
📊 实验亮点
实验结果表明,ELCD在Llama-2-7B上提高了约30个百分点的PR-AUC,并在Mistral-7B上将95% TPR下的假阳性率降低至2.67%。这些显著的性能提升表明ELCD在潜在指令冲突检测中的有效性,超越了现有的竞争基线。
🎯 应用场景
该研究的潜在应用领域包括开放权重和自托管的大型语言模型部署,尤其在需要严格遵循系统约束的场景中,如自动化客服、智能助手等。ELCD的引入将提升这些系统的安全性和可靠性,减少潜在的指令冲突风险。未来,随着LLMs的广泛应用,ELCD可能成为标准的冲突检测工具。
📄 摘要(原文)
Large Language Models (LLMs) are increasingly deployed with hierarchical instructions, yet they remain vulnerable to conflicts in which user directives override system-level constraints. Existing defense mechanisms predominantly focus on static input inspection and therefore fail to detect Response Drift, a phenomenon in which the model's final response violates system-level constraints despite seemingly compliant inputs. To bridge this gap, we introduce ELCD, a response-level latent conflict detector for post-generation, pre-delivery verification. Given the full generated output, ELCD constructs a composite hidden-state representation by concatenating the final-token embedding with the mean-pooled response embedding. It then optimizes a pairwise margin ranking objective to separate compliant and drifting responses in latent space. Extensive experiments across five mainstream LLMs ranging from 1.5B to 14B parameters demonstrate that ELCD significantly outperforms competitive baselines. Notably, it improves the PR-AUC on Llama-2-7B by approximately 30 percentage points and reduces the False Positive Rate at 95% TPR (FPR95) on Mistral-7B to 2.67%. These results suggest that ELCD provides a promising approach for latent instruction-conflict detection in open-weight or self-hosted LLM deployments.