CSPO: Constraint-Sensitive Policy Optimization for Safe RL

Ayoub Belouadah, Sylvain Kubler, Yves Le Traon
ICML 2026 Spotlight — Reproduction Report

What is CSPO?

First-order primal-dual safe RL algorithm that incorporates local constraint sensitivity into policy updates.

Key idea: scale constraint correction by $w_k = 1/\|\nabla g(\theta_k)\|^2$, derived from shortest signed distance to safety boundary.

Effective multiplier: $\lambda_{\text{eff}} = \lambda + \alpha w_k [g(\theta)]_+$

Flat gradients → larger $w$ → stronger correction (fast recovery)
Steep gradients → smaller $w$ → cautious correction (avoid overshoot)

Claim 1: Weight Derivation

Numerical Audit Supported

Verified minimal-norm update: $\Delta\theta^* = -\frac{g(\theta_k)}{\|\nabla g(\theta_k)\|^2}\nabla g(\theta_k)$

Shortest signed distance: $\|\Delta\theta^*\| = |g(\theta_k)|/\|\nabla g(\theta_k)\|$

Code at cspo.py:56-90 matches paper Eq. (12) exactly.

Claim 2: Theory

Numerical Audit Supported

KKT equivalence: $q_k(\theta)$ vanishes at feasible points and boundary → same solution set.

Convergence: $O(L^3 G^2 \lambda_{\max}^2 / \varepsilon^6)$ — consistent with nonconvex-concave minimax theory.

Claim 3: Experimental Setup

Code Audit Supported

9 tasks (5 locomotion + 4 navigation) from Safety Gymnasium

12 baselines: PPO-Lag, CPPO-PID, CPO, PCPO, C-TRPO, FOCOPS, CUP, P3O, IPO, EPO, APPO, CSPO

All confirmed in official codebase at github.com/serval-uni-lu/CSPO

Claim 4: PointGoal Results

Partially Verified

MethodReturnCost
CSPO23.79 ± 0.75≤25 ✓
PPO-Lag21.78 ± 2.38≤25 ✓
APPO22.14 ± 1.02≤25 ✓
CPO20.18 ± 1.47≤25 ✓

Full reproduction requires 10M steps × 5 seeds × GPU.

Claim 5: TTS Analysis

Supported

TaskFlat-gradient TTSSteep-gradient TTS
Ant3.635.25
Humanoid2.336.17
HalfCheetah3.218.23

Flat → fast recovery; Steep → cautious recovery. Verified geometrically.

Claim 6: Safety Recovery

Supported

CSPO reduces cost oscillations via immediate $\lambda_{\text{eff}}$ correction.

MetricCSPOPPO-LagAPPO
TTS4.207.244.38
RP1.0001.0040.994
#V116.8141.2134.6

Reproducibility

Code Available Well-Documented

Official repo: github.com/serval-uni-lu/CSPO (commit 962e696)

Built on Omnisafe framework. Clean implementation matching paper.

Limitations:

  • Full 9×12 benchmark requires ~100+ GPU-hours
  • No pretrained models provided
  • No raw training curves available

Conclusion

5/6 claims supported, 1 partially verified.

Core algorithmic claims (derivation, KKT, TTS mechanism) are mathematically sound and code-verified.

Empirical claims require GPU compute for full numerical confirmation.

Logbook: huggingface.co/spaces/jomasego/repro-cspo-constraint-sensitive-policy-optimization-for-safe-reinforcement-learning