Offline RL via Feature-Occupancy Gradient Ascent

Gergely Neu, Nneka Okolo

Abstract

We study offline Reinforcement Learning in large infinite-horizon discounted Markov Decision Processes (MDPs) when the reward and transition models are linearly realizable under a known feature map. Starting from the classic linear-program formulation of the optimal control problem in MDPs, we develop a new algorithm that performs a form of gradient ascent in the space of feature occupancies, defined as the expected feature vectors that can potentially be generated by executing policies in the environment. We show that the resulting simple algorithm satisfies strong computational and sample complexity guarantees, achieved under the least restrictive data coverage assumptions known in the literature. In particular, we show that the sample complexity of our method scales optimally with the desired accuracy level and depends on a weak notion of coverage that only requires the empirical feature covariance matrix to cover a single direction in the feature space (as opposed to covering a full subspace). Additionally, our method is easy to implement and requires no prior knowledge of the coverage ratio (or even an upper bound on it), which altogether make it the strongest known algorithm for this setting to date.

Introduction

Offline Reinforcement Learning (ORL) is the challenge of learning an optimal policy from a fixed, static dataset without further environment interaction. This paradigm is crucial for high-stakes fields like autonomous driving, healthcare, and industrial control, where "trial-and-error" exploration is either dangerous or prohibitively expensive.

The fundamental hurdle in ORL is data coverage: an agent can only learn about the dynamics and rewards of the parts of the state-action space visited by the logging policy. In the context of "Linear MDPs"—where transitions and rewards are linear functions of a known feature map—existing algorithms typically suffer from two main drawbacks. First, they often require restrictive assumptions, such as the data covering the entire state-action space or a full feature subspace. Second, they frequently require prior knowledge of the "coverage ratio" (how well the data aligns with the optimal policy) to tune hyperparameters or constrain optimization.

This paper introduces FOGAS (Feature-Occupancy Gradient Ascent), a new algorithm designed to operate under the weakest possible coverage assumptions without requiring prior knowledge of data quality.

The FOGAS Algorithm

FOGAS shifts the optimization paradigm for Linear MDPs. While standard approaches often treat the MDP as a complex saddle-point problem (a "min-max" game between a value-function player and a policy player), FOGAS simplifies this into a primal-only optimization.

Feature-Occupancy Space

Instead of optimizing over every individual state and action, the algorithm optimizes in the space of feature occupancy vectors (denoted as $\lambda$). These vectors represent the expected feature vectors a policy would encounter over an infinite horizon. By starting from the classic Linear Programming (LP) formulation of MDPs and applying a dualization trick, the authors reduce a high-dimensional problem (scaling with the number of states) into a low-dimensional one (scaling with the number of features $d$).

Optimization via Gradient Ascent

The algorithm performs a form of preconditioned gradient ascent directly in this feature occupancy space. Key technical components include:

  • Least-Squares Transition Estimation: FOGAS uses a regularized least-squares estimator ($\widehat{\Psi}$) to construct a model of the environment's transitions from the offline data.
  • The Stabilization Trick: To eliminate the need for prior knowledge of the coverage ratio, the authors incorporate a "stabilization" term in the mirror ascent update. This prevents the optimization from diverging even when losses are technically unbounded, removing the need to "project" variables into a pre-defined bounded set.
  • Danskin’s Theorem: This mathematical tool is used to show that the gradient of the optimized primal function is simply the gradient of the original objective evaluated at the "best-response" value parameters, justifying the primal-only update style.

Theoretical Guarantees

FOGAS is a theoretical contribution focused on providing rigorous mathematical guarantees for sample complexity and convergence.

Weak Coverage Requirements

A primary insight of this work is that weak coverage is sufficient. FOGAS only requires the empirical feature covariance matrix to cover the specific directions in the feature space that the optimal policy visits. It does not need to cover the entire feature subspace, which is a significantly less restrictive requirement than those found in previous literature.

Sample and Computational Complexity

The paper proves that FOGAS finds an $\epsilon$-optimal policy with a sample complexity of: $$O\left(\frac{d^2 \|\lambda^*\|^2_{\Lambda_n^{-1}}}{\epsilon^2 (1-\gamma)^2}\right)$$

This result is significant for several reasons:

  1. Optimal Scaling: The complexity scales optimally with the desired accuracy ($\epsilon^{-2}$).
  2. Refined Data Quality: It depends on the "feature coverage ratio" (|\lambda^*|^2_{\Lambda_n^{-1}}), the most refined measure of data quality for this setting.
  3. Efficiency: The cost of each iteration scales linearly with the number of samples $n$, leading to a total runtime complexity of $O(n^2)$, which is standard for model-based linear MDP methods.

Limitations and Future Work

While FOGAS represents a state-of-the-art approach for Linear MDPs, the authors identify several areas for future research:

  • Statistical Scaling: The current $d^2$ (dimension squared) factor might be improvable to a linear $d$ if a tight upper bound on coverage were known. Whether this can be achieved without prior knowledge remains an open question.
  • Computational Bottlenecks: For massive datasets, the $O(n^2)$ runtime may be restrictive. Future work could explore more efficient matrix-vector product handling for the transition estimator.
  • Non-Linear Extensions: The current theory is strictly tied to linear function approximation. Extending these feature-occupancy concepts to non-linear models, such as neural networks, is a significant remaining challenge.

Summary updated

BibTeX
@inproceedings{neu2025offline,
  author = {Gergely Neu and Nneka Okolo},
  title = {{Offline RL via Feature-Occupancy Gradient Ascent}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2025},
  url = {https://openreview.net/forum?id=Hbwh76xE8S},
}
Figure