PPO is the default policy gradient algorithm for practical RL, including RLHF.
The problem PPO solves: standard policy gradients can make destructively large updates that ruin the policy. Trust region methods (TRPO) constrain the update size but are complex.
PPO-Clip objective:
where is the probability ratio and is the GAE advantage.
The ratio comes from off-policy reuse: rollouts are sampled once from and reused for several gradient steps, with acting as an importance-sampling correction. Clipping keeps the approximation valid as long as hasn't moved too far from .
How clipping works:
- If (good action): is clipped at → limits how much we increase the probability
- If (bad action): is clipped at → limits how much we decrease the probability
- Typical
The four cases (clipping is asymmetric — it only stops you when already moving the way the advantage points):
- → use , gradient 0: stop pushing an already-boosted good action further
- → use , gradient 0: stop pushing an already-suppressed bad action down
- → use , gradient flows: still allowed to correct a bad action
- → use , gradient flows: still allowed to recover a good action
Why PPO is the default:
- Simple to implement (just a clipped objective, no constraint optimization)
- Stable — prevents catastrophic policy collapses
- Good sample efficiency with multiple epochs over the same batch
- Works across diverse domains (games, robotics, LLM alignment)
In RLHF: PPO optimizes the LLM policy against a learned reward model, with a KL Penalty to prevent reward hacking.
See also: Actor-Critic Methods, Policy Gradient Theorem, RLHF Pipeline