Algorithm for Constrained Markov Decision Process with Linear Convergence

Egor Gladin, Maksim Lavrik-Karmazin, Karina Zainullina, Varvara Rudenko, Alexander V. Gasnikov, Martin Takác

Abstract

The problem of constrained Markov decision process (CMDP) is considered. An agent aims to maximize the expected accumulated discounted reward subject to multiple constraints on its costs. A new dual approach is proposed with the integration of two ingredients: an entropy-regularized policy optimizer and Vaidya’s dual optimizer, both of which are critical to achieve faster convergence. Despite the challenge of the nonconcave objective subject to nonconcave constraints, the proposed approach is shown to converge with a linear rate to the global optimum. The complexity expressed in terms of the optimality gap and the constraint violation significantly improves upon existing primal-dual approaches.

Introduction

In many real-world reinforcement learning (RL) scenarios, agents must maximize rewards while strictly adhering to safety or resource constraints. These scenarios are modeled as Constrained Markov Decision Processes (CMDPs). A significant challenge in solving CMDPs is their inherent non-concavity in the policy space, which often causes standard optimization tools to converge slowly or get trapped in local optima. Existing state-of-the-art methods typically achieve sub-linear iteration complexity, which can be insufficient for applications requiring high precision with a small number of constraints.

Methodology: The VMDP Algorithm

This research introduces a novel dual approach, termed VMDP, which achieves linear convergence by combining two key components:

  1. Entropy-Regularized Policy Optimizer: By adding an entropy term to the objective function, the researchers ensure the inner optimization problem (finding the best policy for a fixed set of Lagrange multipliers) has a unique solution and the resulting dual function is smooth (Lipschitz continuous gradient).
  2. Vaidya’s Cutting-Plane Method: Instead of standard gradient descent for dual variables (the penalties for violating constraints), the algorithm employs Vaidya’s method. This sophisticated cutting-plane algorithm is particularly effective for problems with a small-to-moderate number of constraints ($m$), as it is robust to inexact gradients from the inner loop and does not accumulate errors over time.

By nesting a Natural Policy Gradient (NPG) optimizer within Vaidya’s dual optimizer, VMDP achieves an iteration complexity of $\tilde{O}(m)$, making it highly efficient for high-precision tasks where the number of constraints is relatively small.

Experimental Evaluation

The VMDP algorithm was evaluated on the Acrobot-v1 benchmark from OpenAI Gym, modified with custom constraints on link swing direction and applied torque to simulate a CMDP environment.

Accumulated reward comparison on Acrobot-v1 between VMDP, AR-CPO, and ARNPG-EPD.

As shown in the reward comparison above, VMDP achieves higher total rewards compared to state-of-the-art methods like AR-CPO and ARNPG-EPD. The algorithm demonstrates superior stability, maintaining low variance across different random seeds while converging rapidly to the optimal policy.

Accumulated cost comparison showing VMDP's ability to satisfy constraints efficiently.

The cost analysis reveals that VMDP effectively reduces accumulated costs below the defined safety thresholds (indicated by the dashed line) more reliably than competing methods. The linear convergence rate proven theoretically is reflected in the steady decrease of constraint violations toward the feasible region.

Discussion and Conclusion

The primary contribution of this work is the demonstration of linear convergence to the global optimum in a non-concave CMDP setting. By shifting the complexity focus to the number of constraints rather than the inverse of error tolerance, VMDP offers a significant practical advantage for safe RL applications requiring high precision.

However, the reliance on Vaidya's method implies that computational overhead may increase if the number of constraints $m$ becomes very large, due to the matrix inversions required. Future work aims to explore alternative dual optimizers, such as the Ellipsoid method, and to relax the "Uniform Ergodicity" assumption currently required for the theoretical proofs.

Summary updated

BibTeX
@inproceedings{gladin2023algorithm,
  author = {Egor Gladin and Maksim Lavrik-Karmazin and Karina Zainullina and Varvara Rudenko and Alexander V. Gasnikov and Martin Takác},
  title = {{Algorithm for Constrained Markov Decision Process with Linear Convergence}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2023},
  url = {https://openreview.net/forum?id=Rmuc2qFbYD},
}
Figure