研究与学习 4.0 · 优秀 2026-07-29 · 论文

On-Policy Distillation for LLM Safety: A Routing Approach to Template-Robust Realignment

下游微调可把有害行为嵌进专业语料现有安全重对齐常遗忘专业能力对攻击者提示模板不可见时失效且易被系统提示切换再越狱ROPD用路由式on-policy蒸馏建模对齐与被污染输出分布差,而非拟合特定模板;跨三数据集三基座优于四类基线,模板失配时更稳且能力保留更好

打开原文回到归档

On-Policy Distillation for LLM Safety: A Routing Approach to Template-Robust Realignment

Authors: Yongjian Guo, Wanlun Ma, Lingyu Shen, Xi Xiao, Sheng Wen
Published: 2026-07-29
Categories: cs.AI, cs.CL, cs.CR, cs.LG
arXiv: 2607.27081

Abstract

Fine-tuning is the dominant paradigm for specializing large language models (LLMs), yet it exposes a critical vulnerability: malicious data providers can embed harmful behaviors into downstream corpora, creating models that retain professional skills while violating human values on demand. Existing safety-realignment defenses often fail in practice due to three key limitations: they frequently cause catastrophic forgetting of specialized skills; their effectiveness collapses when the defender cannot observe the attacker's prompt template; and successfully realigned models remain susceptible to re-jailbreaking via simple system prompt switches. We propose Routing-based On-Policy Distillation (ROPD), a novel realignment framework that models the divergence between aligned and compromised output probability distributions rather than fitting specific prompt templates. Extensive experiments comparing ROPD against four state-of-the-art baselines across three datasets and three base models demonstrate that ROPD substantially mitigates template-mismatch risks, maintaining superior robustness in both defense effectiveness and capability preservation.

中文概述

这篇论文针对微调后的恶意行为嵌入问题,提出 ROPD(路由式在策蒸馏)重新对齐框架。现有防御存在三大局限:灾难性遗忘专业能力、模板不匹配时效果崩塌、简单系统提示词切换即可重新越狱。ROPD 建模对齐与被篡改输出分布之间的散度,而非拟合特定提示词模板。实验表明 ROPD 在防御有效性和能力保留两方面均优于四个 SOTA 基线。

关键发现

  • 现有安全重对齐的三大局限:灾难性遗忘、模板不匹配失效、简单重越狱
  • ROPD 建模对齐与被篡改输出分布的散度,而非拟合提示词模板
  • 在三个数据集、三个基座模型上优于四个 SOTA 基线
  • 模板偏移下的性能降解可忽略,而现有方法严重退化

信息来源