Proximal Policy Optimization (PPO)

Proximal Policy Optimization (PPO)


PPO is a reinforcement learning algorithm that improves a model's behaviour in small steps. The word proximal carries the idea: every update has to stay close to the version that came before it. A policy that swings too far in one step tends to collapse, so PPO clips how far the change is allowed to go.

It runs as a loop. The model samples outputs under its current policy, each sample earns a reward, and those rewards are used to update the policy parameters. During the update PPO computes the ratio between the new policy and the old one and refuses to let that ratio leave a set range. The clipping is what stops a single high-reward sample from throwing the model off a cliff.

With language models it shows up most often inside RLHF. A reward model trained on human preferences scores the responses, and PPO uses those scores to make the language model more helpful and more faithful to instructions. A penalty on the distance from the reference model usually rides alongside it so the model does not lose its fluency.

A concrete case: an assistant refuses about half the reasonable questions it gets. The reward model scores answered-and-useful outputs highly, PPO pulls the policy that way over a few hundred updates, and the refusal rate drops.

The known difficulty with PPO is sensitivity. Clip range, learning rate and penalty coefficient interact, so most of the settings are found by experiment.

From generative AI strategy to custom agent development and retrieval architectures, we help you scale AI responsibly.
Discuss your AI project