Diffusion Policies for Risk-Averse Behavior Modeling in Offline Reinforcement Learning

Xiaocong Chen, Siyu Wang, Tong Yu, Lina Yao

TL;DR

This paper introduces UDAC, a novel offline reinforcement learning (RL) algorithm that uses diffusion models to learn risk-averse policies. By simultaneously addressing both epistemic uncertainty (from limited data) and environmental stochasticity (inherent randomness), UDAC achieves superior risk-aware decision-making in safety-critical scenarios.

What Problem Does This Paper Address?

Offline Reinforcement Learning (RL) aims to train agents using pre-collected datasets, avoiding the need for risky online exploration. However, in safety-critical applications, simply maximizing expected rewards isn't enough; policies must also be risk-averse. This means accounting for the unpredictability of the environment and the potential for adverse outcomes, especially when the training data itself might be noisy or come from suboptimal behavior policies. Existing risk-averse methods often struggle with these challenges, either by relying too heavily on imitating existing behaviors or by not fully capturing the distribution of possible outcomes.

Methods

The core of UDAC lies in its novel integration of diffusion models within an actor-critic framework.

  • Uncertainty-Aware Distributional Actor-Critic (UDAC): This is the overarching algorithm.
  • Diffusion Models for Behavior Policy Modeling: Instead of traditional imitation learning, UDAC uses a denoising diffusion probabilistic model (DDPM) to learn a more robust and expressive representation of the behavior policy from the dataset. This allows it to capture the full distribution of actions taken by the original agents, even if those agents were suboptimal.
  • Risk-Sensitive Actor: The actor policy is designed to balance imitation of the learned behavior policy with risk-averse perturbations. A hyperparameter ($\lambda$) controls this trade-off: low $\lambda$ favors imitation, while high $\lambda$ allows for more risk-averse exploration but can lead to bootstrapping errors.
  • Distributional Critic: The critic learns the distribution of discounted cumulative rewards, not just the expected value. This is achieved using quantile regression and a quantile Huber loss, which is crucial for understanding the range of potential outcomes.
  • Classifier for Controlled Diffusion: To further refine risk-aversion, a classifier is introduced to guide the diffusion process, steering it away from risky actions.

Datasets

The paper evaluates UDAC on several benchmarks:

  • Risk-Sensitive D4RL: This benchmark modifies standard D4RL datasets (Hopper, Walker2d, HalfCheetah) by introducing stochastic rewards that penalize undesirable behaviors (e.g., unnatural gaits, high velocities). This makes it suitable for evaluating risk-averse policies.
  • Risky Robot Navigation: This includes two environments (Risky Ant and Risky PointMass) where an agent must navigate to a goal while avoiding a high-cost "risky area."
  • Risk-Neutral D4RL: Standard D4RL datasets are used to demonstrate that UDAC maintains competitive performance even when the primary objective is maximizing expected return.

Key Insights and Ideas

  • Diffusion Models as a Powerful Tool for Behavior Modeling: The paper highlights that diffusion models can go beyond simple imitation, capturing richer distributions of past behaviors, which is critical for robust offline RL.
  • Unified Framework for Risk and Uncertainty: UDAC's strength lies in its ability to simultaneously address both environmental stochasticity and epistemic uncertainty within a single, coherent framework.
  • The Importance of Balancing Imitation and Risk Aversion: The hyperparameter $\lambda$ in the actor reveals a crucial trade-off. Too much imitation leads to poor risk-aversion, while too much risk-averse perturbation can lead to performance degradation due to bootstrapping errors. Finding the right balance is environment-dependent.
  • Zero Violations in Novel Risky Scenarios: A particularly impressive finding is UDAC's ability to learn to completely avoid risky regions in the Risky PointMass environment, even when such behavior was not present in the training data. This suggests strong generalization capabilities for risk avoidance.

Key Results

  • Superior Risk-Sensitive Performance: UDAC consistently outperforms state-of-the-art risk-sensitive algorithms (like CODAC and O-RAAC) on risk-sensitive D4RL benchmarks, particularly in terms of CVaR$_{0.1}$ returns.
  • Effective Risk Avoidance in Navigation: In the Risky Robot Navigation tasks, UDAC significantly reduces violations of risky areas compared to baselines, demonstrating its ability to learn safe policies. For instance, it achieved zero violations in the Risky PointMass environment.
  • Competitive Risk-Neutral Performance: UDAC achieves comparable, and in some cases superior, performance to leading algorithms on risk-neutral D4RL benchmarks, showing its versatility.
  • Longer Episode Durations: In environments where policies can terminate due to failure, UDAC often achieves longer episode durations, indicating more stable and successful task completion.

Limitations and Future Work

  • Hyperparameter Sensitivity: The paper acknowledges that the optimal value of the $\lambda$ hyperparameter (balancing imitation and risk aversion) is environment-dependent and requires careful tuning.
  • Sampling Speed of Diffusion Models: The authors suggest that optimizing the sampling speed of diffusion models could further improve UDAC's efficiency.
  • Classifier-Free Guidance: Investigating classifier-free diffusion guidance is proposed as a future direction for enhancing control over the diffusion process.
  • Online Adaptation: While the paper focuses on offline RL, the authors mention that the $\beta$ component (behavioral policy) can be removed to adapt UDAC for online settings.

Summary updated

BibTeX
@inproceedings{chen2024diffusion,
  author = {Xiaocong Chen and Siyu Wang and Tong Yu and Lina Yao},
  title = {{Diffusion Policies for Risk-Averse Behavior Modeling in Offline Reinforcement Learning}},
  booktitle = {IEEE/RSJ International Conference on Intelligent Robots and Systems},
  year = {2024},
}
Figure