Safe Reinforcement Learning with Receding-Horizon Safety Critic and Differentiable Action Shields
Organizations: Department of Computer Science, Technical University of Darmstadt, Germany. · Hessian.AI. · German Research Center for AI (DFKI), Research Department: Systems AI for Robot Learning. · Robotics Institute Germany (RIG).
Abstract
Despite the Markov assumption, safety failures in robot reinforcement learning rarely occur instantaneously; they typically emerge over several steps as the policy enters unfamiliar states under disturbances and domain shift. We address this limitation by learning a receding-horizon safety critic that predicts whether a state will remain non-terminating over the next receding horizon, enabling anticipatory detection of impending locomotion failures. The critic is trained from rollout-derived horizon labels with a composite objective that combines horizon classification, control-barrier-function-inspired temporal consistency, and smoothness regularization, and we aggregate an ensemble of critics with a conservative Conditional Value at Risk estimate to account for uncertainty. Building on the learned critic, we derive a closed-form, differentiable CBF-style safety filter that minimally modifies the policy action to improve predicted safety, and integrate it into PPO with an anticipation loss to reduce policy-filter mismatch during training. In simulated quadruped locomotion, our method improves robustness under action noise, external perturbations, and terrain shifts, reducing catastrophic failures while maintaining competitive returns.
Figures & tables
| Hyperparameter | Symbol | Value |
|---|---|---|
| Safety prediction horizon | 5 | |
| Safety margin (threshold) | 0.5 | |
| Unsafe-label discount | 0.95 | |
| CVaR tail probability | 0.4 | |
| Ensemble size | 5 | |
| CBF gain (for ) | 0.5 |
| Metric | Experiment | State-Action Safety Critic | SafeFall |
|---|---|---|---|
| Accuracy | Perturbation - Flat Terrain | 0.6160 0.0200 | 0.6200 0.0265 |
| Accuracy | Perturbation - Heightfield Terrain | 0.5800 0.0254 | 0.5480 0.0232 |
| False Positives | Perturbation - Flat Terrain | 0.0800 0.0086 | 0.1680 0.0171 |
| False Positives | Perturbation - Heightfield Terrain | 0.1760 0.0197 | 0.2480 0.0113 |
| False Negatives | Perturbation - Flat Terrain | 0.0736 0.0053 | 0.0160 0.0020 |
| False Negatives | Perturbation - Heightfield Terrain | 0.0612 0.0071 | 0.0129 0.0014 |
Safe RL
Safe reinforcement learning studies how agents can learn and act while respecting safety constraints and limiting harmful outcomes.
See all 217 papers