arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2601.07087cs.LG
收藏

在预训练过程中何时引入安全干预

When Should We Introduce Safety Interventions During Pretraining?

Carnegie Mellon University(卡内基梅隆大学)

Dylan Sam, Sachin Goyal, Pratyush Maini, Alexander Robey, J. Zico Kolter

AI总结:

本文研究了在预训练过程中何时引入安全干预以提高模型鲁棒性,发现20%-60%的预训练阶段引入干预效果最佳,且早期干预能更清晰地区分安全与有害内容。

摘要:

先前的研究表明,在预训练过程中应用安全干预,如删除和改写有害内容,可以显著提高最终模型的鲁棒性。在本文中,我们研究了一个先前研究忽视的基本问题:"在预训练过程中何时应引入安全干预?"我们保持底层数据源和预训练干预不变,仅改变干预的开始时间(在预训练token的0%、20%或60%之后)。我们发现,最佳的开始时间并非一刀切:使用标准的top-k解码时,在预训练初期的安全-only阶段之后引入干预(20%-60%)通常会产生最强的鲁棒性,随着下游良性微调的进行,优势最为明显。相比之下,对于安全意识的推理,从开始引入干预会提高生成更安全结果的可控性。最后,我们发现更早的干预会重塑内部表示:线性探针更清晰地将安全与有害示例分开。我们的结果是首次确立干预时间作为安全性的关键课程设计选择。

英文摘要:

Prior work has shown that safety interventions applied during pretraining, such as removing and rephrasing harmful content, can substantially improve the robustness of the resulting models. In this paper, we study the fundamental question that prior work has overlooked: "When during pretraining should safety interventions be introduced?" We keep the underlying data sources and pretraining interventions fixed, varying the intervention start time (after 0%, 20%, or 60% of pretraining tokens). We find that the optimal start time is not one-size-fits-all: with standard top-k decoding, introducing interventions after a short initial phase of safe-only pretraining (20%-60%) often yields the strongest robustness, with the clearest benefits emerging after downstream, benign finetuning. In contrast, for safety-aware inference, interventions starting from the beginning improve steerability towards safer generations. Finally, we observe that earlier interventions reshape internal representations: linear probes more cleanly separate safe vs harmful examples. Our results are the first to establish intervention timing as a key curriculum design choice for safety.

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

↑