Forward KL Regularized Preference Optimization for Aligning Diffusion Policies

Zhao Shan, Chenyou Fan, Shuang Qiu, Jiyuan Shi, Chenjia Bai

Abstract

Diffusion models have emerged as a powerful paradigm for offline reinforcement learning (RL), capable of capturing complex, multi-modal behavior distributions. However, aligning these expressive policies with human intent is challenging, as traditional methods often rely on brittle, manually engineered reward functions. While Direct Preference Optimization (DPO) has seen success in aligning Large Language Models, its application to diffusion policies is hindered by mathematical intractability and the tendency of standard reverse KL regularization to generate out-of-distribution (OOD) actions. This paper introduces FKPD (Forward KL regularized Preference optimization for aligning Diffusion policies), a framework that leverages forward KL regularization to anchor the policy to valid behavior distributions. Our evaluation on robotic manipulation and locomotion benchmarks demonstrates that FKPD achieves state-of-the-art performance by effectively balancing preference maximization with physical realism.

Introduction

Aligning embodied agents with human preferences is a core challenge in robotics. Although preference-based learning offers a way to bypass reward engineering, applying it to high-dimensional diffusion policies is non-trivial. Standard DPO objectives utilize reverse KL divergence, which is "mode-seeking" and can lead the policy to exploit reward models by generating physically impossible actions. FKPD addresses this by deriving a tractable DPO objective for diffusion models and substituting reverse KL with forward KL regularization. This approach ensures the agent remains within the support of the original behavior distribution while optimizing for human preferences.

The FKPD Framework

FKPD follows a two-stage pipeline designed to ensure both the validity and the alignment of the learned policy.

The FKPD framework: Phase 1 involves pre-training a base diffusion policy via Behavior Cloning, while Phase 2 aligns the policy using a preference dataset and forward KL regularization.
  1. Phase 1: Behavior Cloning: The model is first trained on a preference-free offline dataset to capture the full distribution of valid actions in the environment.
  2. Phase 2: Alignment: The pre-trained policy is fine-tuned using a preference dataset $\mathcal{D}_{pref}$ consisting of paired trajectories. The authors derive a computable loss function by approximating the intractable reverse diffusion process using the forward diffusion chain and Gaussian reparameterization.

Forward KL vs. Reverse KL Regularization

A critical contribution of this work is the identification of the "OOD problem" in diffusion alignment. In high-dimensional action spaces, reverse KL regularization often causes the policy to collapse into narrow, high-reward regions that are physically unrealistic. In contrast, forward KL regularization is "mass-covering," forcing the aligned policy to stay close to the reference behavior distribution.

Comparison of regularization strategies: Forward KL (center) shifts the distribution toward higher rewards while remaining within the valid action space (blue circles), whereas Reverse KL (right) leads to out-of-distribution behavior.

As illustrated above, forward KL acts as a crucial guardrail, preventing the catastrophic failures associated with unconstrained or reverse-KL-constrained preference optimization.

Experimental Evaluation

The effectiveness of FKPD was validated on the MetaWorld and D4RL benchmarks.

MetaWorld Manipulation Tasks

FKPD consistently outperformed strong baselines, including Supervised Fine-Tuning (SFT) and Contrastive Preference Learning (CPL). For instance, on the DrawerOpen task, FKPD achieved a 90.0% success rate, compared to 83.6% for CPL. Ablation studies showed that removing regularization entirely (NRPD) led to a 42.1% drop in performance, underscoring the importance of the forward KL constraint.

D4RL Locomotion Tasks

In locomotion benchmarks like Walker2d and Hopper, FKPD outperformed the state-of-the-art CPL in 5 out of 6 tasks. It also matched or exceeded the performance of Preference-IQL (P-IQL), which has the advantage of using an explicitly trained reward model, demonstrating the power of direct preference optimization for diffusion policies.

Conclusion

FKPD provides a robust and mathematically grounded framework for aligning diffusion policies with human preferences. By employing forward KL regularization, it successfully mitigates the risk of out-of-distribution action generation, a common failure mode in complex embodied tasks. Future work will explore the application of FKPD to vision-based robotics and multi-task learning scenarios.

Summary updated

BibTeX
@inproceedings{shan2025forward,
  author = {Zhao Shan and Chenyou Fan and Shuang Qiu and Jiyuan Shi and Chenjia Bai},
  title = {{Forward KL Regularized Preference Optimization for Aligning Diffusion Policies}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2025},
  doi = {10.1609/aaai.v39i13.33576},
}
Figure