SafeDPO: A Simple Approach to Direct Preference Optimization with Enhanced Safety
Geon-Hyeong Kim, Yu Jin Kim, Byoungjip Kim, Honglak Lee, Kyunghoon Bae, Youngsoo Jang, Moontae Lee
Abstract
As Large Language Models (LLMs) are increasingly deployed in real-world applications, balancing helpfulness and safety has become a central challenge. A natural approach is to incorporate safety constraints into Reinforcement Learning from Human Feedback (RLHF), where recent studies have shown promising progress. However, these methods often rely on auxiliary networks or multi-stage pipelines, thereby increasing complexity. In this work, we revisit the original safety alignment objective and show that, under mild assumptions, it admits a closed-form optimal policy. We further derive a provably equivalent and tractable objective, enabling direct optimization. Building on this insight, we propose SafeDPO, a lightweight method that preserves the optimal solution of the underlying safety-constrained objective while requiring only one additional hyperparameter and minimal modifications to existing preference-based training methods. SafeDPO eliminates the need for reward models, cost models, and online sampling, relying only on preference data and safety indicators. Despite its simplicity, SafeDPO achieves competitive safety-helpfulness trade-offs compared to existing safety alignment methods. Experiments on the PKU-SafeRLHF-30K benchmark demonstrate that SafeDPO substantially improves safety while maintaining competitive helpfulness. Ablation studies further show that the additional hyperparameter provides a flexible mechanism to enhance safety while preserving the theoretical optimum, and confirm that SafeDPO scales reliably to LLMs with up to 13B parameters. Overall, our results highlight that a simple, theory-driven objective can provide a lightweight yet effective solution for safety alignment in practice. * Current affiliation: Ministry of Science and ICT (MSIT), Republic of Korea. Work performed while at LG AI Research.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
5 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- PrefGen: A Preference-Driven Methodology for Secure Yet Gas-Efficient Smart Contract Generation cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- AlpacaFarm: A Simulation Framework for Methods that Learn from Human Feedback cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- AlpacaFarm: A Simulation Framework for Methods that Learn from Human Feedback cites Language Models are Few-Shot Learners
- AlpacaFarm: A Simulation Framework for Methods that Learn from Human Feedback cites Training language models to follow instructions with human feedback
- Keep the Best, Forget the Rest: Reliable Alignment with Order-Aware Preference Optimization cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- Keep the Best, Forget the Rest: Reliable Alignment with Order-Aware Preference Optimization cites Training language models to follow instructions with human feedback
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy Optimization cites AlpacaFarm: A Simulation Framework for Methods that Learn from Human Feedback
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy Optimization cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy Optimization cites Training language models to follow instructions with human feedback
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy Optimization cites Safe RLHF: Safe Reinforcement Learning from Human Feedback
- Direct Preference Optimization: Your Language Model is Secretly a Reward Model cites Language Models are Few-Shot Learners
- Direct Preference Optimization: Your Language Model is Secretly a Reward Model cites Training language models to follow instructions with human feedback
- DriveDPO: Policy Learning via Safety DPO For End-to-End Autonomous Driving cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- DriveDPO: Policy Learning via Safety DPO For End-to-End Autonomous Driving cites Training language models to follow instructions with human feedback
- Reducing the Probability of Undesirable Outputs in Language Models Using Probabilistic Inference cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- Reducing the Probability of Undesirable Outputs in Language Models Using Probabilistic Inference cites Training language models to follow instructions with human feedback
- Training language models to follow instructions with human feedback cites Language Models are Few-Shot Learners
- Safe RLHF: Safe Reinforcement Learning from Human Feedback cites Direct Preference Optimization: Your Language Model is Secretly a Reward Model
- Safe RLHF: Safe Reinforcement Learning from Human Feedback cites Language Models are Few-Shot Learners
- Safe RLHF: Safe Reinforcement Learning from Human Feedback cites Training language models to follow instructions with human feedback
Cited by top-tier papers5
- DriveDPO: Policy Learning via Safety DPO For End-to-End Autonomous DrivingShuyao Shang, Yuntao Chen, Yuqi Wang, Yingyan Li et al.NeurIPS 2025 · 49 citations
- Mitigating the Safety Alignment Tax with Null-Space Constrained Policy OptimizationYifan Niu, Han Xiao, Dongyi Liu, Nuo Chen et al.ICLR 2026 · 13 citations
- PrefGen: A Preference-Driven Methodology for Secure Yet Gas-Efficient Smart Contract GenerationZhiyuan Peng, Xin Yin, Zijie Zhou, Chenhao Ying et al.ASE 2025 · 3 citations
- Keep the Best, Forget the Rest: Reliable Alignment with Order-Aware Preference OptimizationJiahui Zhu, Yuanjie Shi, Xiyue Peng, Xin Liu et al.ICLR 2026
- Reducing the Probability of Undesirable Outputs in Language Models Using Probabilistic InferenceStephen Zhao, Aidan Li, Rob Brekelmans, Roger Baker GrosseNeurIPS 2025
Builds on10
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
- Training language models to follow instructions with human feedbackLong Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida et al.NeurIPS 2022 · 24,707 citations
- Direct Preference Optimization: Your Language Model is Secretly a Reward ModelRafael Rafailov, Archit Sharma, Eric Mitchell, Christopher D. Manning et al.NeurIPS 2023 · 10,924 citations
- AlpacaFarm: A Simulation Framework for Methods that Learn from Human FeedbackYann Dubois, Chen Xuechen Li, Rohan Taori, Tianyi Zhang et al.NeurIPS 2023 · 948 citations
- Safe RLHF: Safe Reinforcement Learning from Human FeedbackJosef Dai, Xuehai Pan, Ruiyang Sun, Jiaming Ji et al.ICLR 2024 · 656 citations
Related papers
- Beyond One-Preference-Fits-All Alignment: Multi-Objective Direct Preference OptimizationZhanhui Zhou, Jie Liu, Jing Shao, Xiangyu Yue et al.ACL Findings 2024 · 21 citations
- Enhancing Safety in Reinforcement Learning with Human Feedback via Rectified Policy OptimizationXiyue Peng, Hengquan Guo, Jiawei Zhang, Dongqing Zou et al.NeurIPS 2025 · 9 citations
- Bi-Factorial Preference Optimization: Balancing Safety-Helpfulness in Language ModelsWenxuan Zhang, Philip Torr, Mohamed Elhoseiny, Adel BibiICLR 2025
- Avoiding exp(R) scaling in RLHF through Preference-based ExplorationMingyu Chen, Yiding Chen, Wen Sun, Xuezhou ZhangNeurIPS 2025 · 9 citations
- Back to Basics: Revisiting REINFORCE-Style Optimization for Learning from Human Feedback in LLMsArash Ahmadian, Chris Cremer, Matthias Gallé, Marzieh Fadaee et al.ACL 2024 · 20 citations
