Offline RL with No OOD Actions: In-Sample Learning via Implicit Value Regularization

Haoran Xu, Li Jiang, Jianxiong Li, Zhuoran Yang, Zhaoran Wang, Victor Wai Kin Chan, Xianyuan Zhan

Tackling one of the most persistent challenges in offline reinforcement learning (RL), this paper addresses the distributional shift caused by out-of-distribution (OOD) actions. The authors introduce Implicit Value Regularization (IVR), a theoretical framework explaining how "in-sample" learning—learning exclusively from actions present in the dataset—implicitly regularizes the policy. Building on this foundation, they propose two novel algorithms: Sparse Q-learning (SQL) and Exponential Q-learning (EQL). These methods demonstrate state-of-the-art performance on complex "stitching" tasks and exhibit remarkable robustness to noisy or limited data.

The Problem: Out-of-Distribution Actions

In offline RL, agents must learn an optimal policy from a fixed, pre-collected dataset without any new environment interaction. Standard off-policy algorithms (like SAC or DQN) typically fail in this setting because they attempt to calculate the value of actions the policy might take. If those actions are not present in the dataset, the Q-function (the "critic") lacks the grounding to evaluate them accurately, often producing wildly over-optimistic value estimates.

Historically, methods have addressed this by either:

  1. Constraining the policy to stay very close to the data (similar to Behavior Cloning).
  2. Adding pessimism by artificially lowering the value of OOD actions (e.g., CQL).

However, both approaches usually require querying the Q-function for unseen actions during training. A newer paradigm called In-sample Learning (exemplified by IQL) avoids OOD actions entirely by only using data points already in the replay buffer. While IQL has proven highly effective in practice, the theoretical "why" behind its success has remained murky. This paper provides that missing theoretical foundation.

Methodology: Implicit Value Regularization

The authors propose the Implicit Value Regularization (IVR) framework. They demonstrate that if a behavior regularizer—a penalty for deviating from the data-collection policy—is added directly to the reward function, the resulting optimal policy has a closed-form solution that depends only on actions found in the dataset.

From this framework, they derive two practical algorithms:

  • Sparse Q-learning (SQL): Utilizes a $\chi^2$-divergence regularizer. This leads to a "sparse" update where actions with low Q-values are assigned exactly zero weight, acting as a hard filter against low-quality data.
  • Exponential Q-learning (EQL): Utilizes a Reverse KL-divergence regularizer, resulting in a smoother, exponential weighting of actions based on their advantage.

Unlike IQL, which relies on expectile regression as a heuristic to stay "in-sample," SQL and EQL are derived directly from first principles of regularization. Furthermore, SQL and EQL are self-consistent: the policy they extract is the exact optimal policy for the value function they learn. Crucially, SQL introduces sparsity, which the authors argue is the key to handling low-quality or noisy datasets.

Experimental Setup and Key Results

The authors evaluated their methods across a wide range of standard and custom benchmarks, including D4RL (MuJoCo locomotion, AntMaze, Adroit/Kitchen), RL Unplugged (Atari), and custom regimes designed to test noise tolerance and data scarcity.

Performance comparison of offline RL algorithms on D4RL datasets.

State-of-the-Art on "Stitching" Tasks

As shown in the performance table, SQL and EQL significantly outperform baselines like IQL and CQL on the most difficult D4RL datasets, particularly AntMaze and Kitchen. These environments require the agent to "stitch" together parts of different sub-optimal trajectories to find a successful path to the goal.

Robustness to Noise and Small Data

A major insight from the paper is the power of sparsity. In IQL, the derivative keeps decreasing even for very bad actions, meaning "bad" data can still negatively impact the value estimate. In contrast, SQL’s derivative becomes zero below a certain threshold, effectively ignoring the noise.

This theoretical advantage translates to empirical robustness. In a custom "Noisy" Walker2d task where the expert data ratio dropped to just 5%, IQL's performance plummeted, whereas SQL and EQL maintained near-expert performance thanks to their sparse filtering. Similarly, in small-data AntMaze experiments, CQL’s Bellman error exploded (indicating value instability), while SQL remained stable and achieved much higher returns.

Limitations and Future Work

While SQL reduces the number of hyperparameters compared to IQL (requiring only one $\alpha$ parameter versus $\tau$ and $\beta$), its performance remains sensitive to the choice of $\alpha$, which controls the degree of sparsity.

Additionally, the current IVR framework focuses on regularizing the action distribution. The authors suggest that future work could extend this to regularize the state occupancy distribution, potentially improving stability in long-horizon tasks. Finally, exploring how these sparse, in-sample updates behave during online fine-tuning remains an open and promising question for future research.

Summary updated

BibTeX
@inproceedings{xu2023offline,
  author = {Haoran Xu and Li Jiang and Jianxiong Li and Zhuoran Yang and Zhaoran Wang and Victor Wai Kin Chan and Xianyuan Zhan},
  title = {{Offline RL with No OOD Actions: In-Sample Learning via Implicit Value Regularization}},
  booktitle = {International Conference on Learning Representations},
  year = {2023},
  url = {https://openreview.net/forum?id=ueYYgo2pSSU},
}
Figure