What is it?
PPO teaches an agent by repeatedly trying behaviours and nudging its policy toward those that earned more reward — but it refuses to change too much at once, which keeps learning from going off the rails. It is a workhorse algorithm in RL.
Also known as: PPO, proximal policy optimisation, clipped surrogate objective, actor critic, policy gradient, TRPO, GAE.
Technical definition
PPO (Schulman et al., 2017) optimises a clipped surrogate objective on the probability ratio between new and old policies, using advantage estimates (typically GAE) from a learned value function, and multiple epochs of minibatch updates per batch of on-policy data. In RLHF it optimises a policy against a learned reward model with a KL penalty to a reference model. Practical stability depends on many implementation details (advantage normalisation, value clipping, learning-rate schedules).
Entity type: technique · Freshness class: evolving.
When should I use it?
Consider for continuous-control RL or when online RL against a reward signal is required; for preference alignment consider Preference Optimization (Aligning Models from Human or AI Preferences) methods first.
Implementation patterns
- Collect on-policy rollouts, compute advantages, update with clipped objective for a few epochs.
- KL penalty against a reference model in RLHF.
- Normalise advantages and observations.
- Evaluate on held-out environments or prompts.
Technologies and frameworks
Commonly associated: Stable-Baselines3, TRL, OpenRLHF, RLlib. Names are examples of what exists, not recommendations, and projects change quickly.
Practical guide
- Use a vetted implementation.
- Reproduce a known baseline first.
- Log KL, reward, entropy and value loss.
- Inspect generations regularly in RLHF.
Common failure modes
- Sensitive to implementation details and hyperparameters.
- Reward hacking against the reward model.
- Memory and compute heavy in LLM RLHF (policy, reference, reward and value models).
- Instability from poor KL control.
Troubleshooting
- Reward rises, human quality falls — Increase KL penalty, refresh the reward model, audit samples.
- Training diverges — Lower learning rate, check advantage normalisation, use known-good implementation settings.
Contrasted with
- Direct Preference Optimization (DPO) — PPO is online RL with a reward model and sampling; DPO trains directly on preference pairs without sampling or a separate reward model.
- Deep Q-Networks (DQN) and Q-Learning — DQN is value-based for discrete actions; PPO is policy-based and handles continuous actions.
Questions this page answers
- What is PPO?
- How does PPO work in RLHF?
- What is a policy gradient?
- What is the difference between PPO and DPO?
- What is an actor-critic?
Typical goals: understand the algorithm used in RLHF; choose an RL algorithm; compare PPO and GRPO.
Sources and verification
Status: not independently verified. This entry was authored on 2026-10-06 from general technical knowledge, without live checking of the sources below. Treat every source as a lead to confirm (identifier, title, authorship, current version) before publication or citation.
Freshness class: evolving — Established techniques whose best practice shifts as research and tooling move. Re-review every 6 months.
Canonical sources (unverified leads):
- Schulman et al., Proximal Policy Optimization Algorithms (2017) — arXiv:1707.06347
- Ouyang et al., Training language models to follow instructions with human feedback (2022) — arXiv:2203.02155