Zeroth-Order Policy Gradient for Reinforcement Learning from Human Feedback without Reward Inference

Qining Zhang, Lei Ying · DOI

Abstract

Reinforcement Learning from Human Feedback (RLHF) is a cornerstone of modern Large Language Model (LLM) alignment. However, traditional methods rely on an intermediate reward model, which introduces significant overhead and potential for overfitting. While Direct Preference Optimization (DPO) eliminates the reward model, it is theoretically limited to deterministic or bandit settings. This paper introduces Zeroth-Order Policy Gradient (ZPG) and its block-coordinate variant (ZBCPG), which optimize policies directly from human preferences in general stochastic environments without reward inference.

Introduction

The standard RLHF pipeline typically involves three distinct stages: pre-training, reward model training from human preferences, and policy optimization via Reinforcement Learning (e.g., PPO). This multi-step process is often brittle; the reward model can be sensitive to distribution shifts and requires careful hyperparameter tuning.

Overview of standard RLHF pipelines including PPO-based reward inference and Direct Preference Optimization (DPO).

Recently, Direct Preference Optimization (DPO) emerged as a popular alternative that skips reward modeling. However, DPO relies on a closed-form relationship between the optimal policy and the reward function that holds only in deterministic or bandit-like settings. In complex, multi-step reasoning tasks or stochastic environments, this assumption fails. This research addresses the "stochasticity gap" by proposing a zeroth-order optimization approach for general Markov Decision Processes (MDPs).

Methodology: Zeroth-Order Optimization

The proposed algorithms, ZPG and ZBCPG, treat policy optimization as a zeroth-order (ZO) problem. Instead of computing gradients directly, the methods estimate them by observing how small perturbations in policy parameters affect human preference outcomes.

Zeroth-Order Policy Gradient (ZPG)

ZPG operates by sampling a random perturbation vector from a unit sphere to create a "perturbed" policy. Human evaluators compare trajectories generated by the original policy and the perturbed one. Using a link function (such as the Bradley-Terry model), these preferences are converted into a local gradient estimate. This allows the policy to move "upward" in the preference landscape without ever mapping the entire reward function.

Zeroth-Order Block-Coordinate Policy Gradient (ZBCPG)

To scale these methods to LLMs with billions of parameters, the authors introduced ZBCPG. This variant perturbs only a subset (block) of parameters at a time. This approach is significantly more memory-efficient and facilitates parallelization, making it compatible with Parameter-Efficient Fine-Tuning (PEFT) techniques.

Experimental Evaluation

The authors evaluated ZPG and ZBCPG in a Stochastic GridWorld environment—a $5 \times 5$ grid where actions are reversed with a 40% probability. This setup intentionally introduces the stochasticity that challenges DPO.

Key Results

  • Performance in Stochasticity: In the GridWorld environment, ZPG and ZBCPG achieved cumulative returns between 1.9 and 2.1, consistently outperforming the RM+PPO baseline (1.7–1.8).
  • DPO Limitations: Vanilla DPO failed significantly in this stochastic setting, often yielding negative returns, confirming the theoretical "stochasticity gap."
  • Scalability: ZBCPG demonstrated that increasing the number of parallel blocks leads to faster convergence, suggesting high utility for large-scale distributed training.
  • Robustness: The algorithms remained stable even when the number of human queries was reduced by an order of magnitude (from 1000 to 100).

Discussion and Future Work

While ZPG/ZBCPG offer a robust path forward for RLHF in complex environments, they are "query-hungry," requiring numerous trajectory samples for accurate gradient estimation. Furthermore, the current implementation lacks a built-in exploration mechanism, which may hinder performance in environments with sparse rewards.

Future research directions include integrating AI Feedback (RLAIF) to mitigate the query cost and incorporating momentum-based optimization to improve sample efficiency by reusing feedback from previous iterations. By bypassing the reward model entirely, ZPG provides a theoretically grounded and practically viable framework for aligning agents in the real, stochastic world.

Summary updated

BibTeX
@inproceedings{zhang2025zeroth,
  author = {Qining Zhang and Lei Ying},
  title = {{Zeroth-Order Policy Gradient for Reinforcement Learning from Human Feedback without Reward Inference}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=cmYScmfu4Q},
}
Figure