# What is reinforcement learning: AI that learns by trial and reward

> Agents, environments, rewards and policies in plain words, the Atari and AlphaGo results, and how RLHF and verifiable rewards train today's language models.

URL: https://claudegpt.si/news/what-is-reinforcement-learning  
Published: 2026-11-15T02:55:23.250Z  
Author: ClaudeGPT Si Newsroom  
Section: Research  
Topics: Reinforcement learning, RLHF, Reasoning models, Research  
Publisher: ClaudeGPT Si

## Key takeaways

- Reinforcement learning trains an agent by trial and error: it acts in an environment, gets a numerical reward, and improves its policy to collect more reward.
- DeepMind's DQN learned 49 Atari games from pixels and score in 2015, and AlphaGo beat Lee Sedol 4 games to 1 in March 2016.
- Language models use RL in post-training: RLHF rewards answers people prefer, and RL with verifiable rewards took DeepSeek-R1-Zero from 15.6% to 77.9% on AIME 2024.

Reinforcement learning is a way of training AI by trial and error: a program tries actions, gets a score for how each one turned out, and gradually changes what it does to collect more reward. It is the technique behind DeepMind's Atari player and AlphaGo, and today it is the step that teaches language models to follow instructions and to reason through math and code.

The standard textbook, [Reinforcement Learning: An Introduction](http://incompleteideas.net/book/the-book-2nd.html) by Richard Sutton and Andrew Barto (MIT Press, 2018), [defines it](http://incompleteideas.net/book/ebook/node7.html) as learning how to map situations to actions so as to maximize a numerical reward.

## The four words that explain reinforcement learning

Picture a program learning a video game.

- **Agent**: the learner and decision-maker. Here, the program pressing the buttons.
- **Environment**: everything the agent acts on. Here, the game: the screen the agent sees and the rules that decide what happens next.
- **Reward**: a single number the environment hands back after an action, here the change in score. Sutton and Barto [write](http://incompleteideas.net/book/ebook/node9.html) that the agent's "sole objective" is to maximize the total reward it receives in the long run.
- **Policy**: the agent's way of behaving, a mapping from what it sees to what it does. Training means improving the policy. In modern systems it is a neural network.

The loop: the agent sees the state of the environment, picks an action with its policy, gets a reward and a new state, and adjusts the policy so actions that led to more reward become more likely.

Every agent also has to balance **exploration and exploitation**: repeat what has worked, or try something new that might work better.

## How reinforcement learning differs from supervised learning

Most machine learning is supervised. The model gets examples with the right answers attached, such as photos labeled "cat" or "dog", and learns to reproduce them.

Reinforcement learning has no answer key. The agent gets a score, not a correction, and the reward for a good move may arrive many steps later, as when a game is won at the end. Sutton and Barto name these two features, trial-and-error search and delayed reward, as what sets RL apart.

| | Supervised learning | Reinforcement learning |
| --- | --- | --- |
| Learns from | Examples with correct answers | Rewards for its own actions |
| Feedback | The right answer, every time | A score, often delayed |
| Main difficulty | Collecting labeled data | Designing the reward, exploring enough |

## The results that made reinforcement learning famous

**DQN plays Atari (2015).** A DeepMind team led by Volodymyr Mnih published [Human-level control through deep reinforcement learning](https://www.nature.com/articles/nature14236) in Nature in February 2015. Their deep Q-network, or DQN, saw only the screen pixels and the game score. Across 49 Atari 2600 games, with the same algorithm, network and settings for all of them, it beat every earlier algorithm and reached a level the paper calls comparable to a professional human games tester. The new part was letting a deep neural network learn straight from raw images.

**AlphaGo wins at Go (2016).** DeepMind's [AlphaGo paper](https://www.nature.com/articles/nature16961) (Silver et al., Nature, January 2016) combined a "policy network" that picks moves with a "value network" that judges board positions. Both were trained first by supervised learning on human expert games, then by reinforcement learning from games AlphaGo played against itself. It won 99.8% of its games against other Go programs and beat the European champion 5 games to 0, the first time a program had beaten a human professional on a full-size board. In March 2016 in Seoul it beat Lee Sedol, a player with 18 world titles, 4 games to 1, in a match DeepMind says [over 200 million people watched](https://deepmind.google/research/alphago/).

## How reinforcement learning trains today's language models

A language model first learns to predict the next word across huge amounts of text. RL comes afterwards, in what labs call post-training, to shape how it behaves. The language model is the agent, the prompt is its environment, writing a response is the action, and a score for the response is the reward.

### RLHF: rewards from human preferences

Reinforcement learning from human feedback was laid out for instruction-following models in OpenAI's [InstructGPT paper](https://arxiv.org/abs/2203.02155) (Ouyang et al., March 2022):

1. Fine-tune GPT-3 on answers written by human labelers.
2. Have labelers rank 4 to 9 of the model's answers to the same prompt, and train a separate "reward model" to predict which answer people prefer.
3. Use RL, with an algorithm called PPO, to push the model toward answers the reward model scores highly, with a penalty for drifting far from the fine-tuned version.

People preferred answers from the 1.3 billion parameter InstructGPT over those of the 175 billion parameter GPT-3, a model more than 100 times larger. The paper notes the models still made up facts. More in our explainer [What is RLHF](https://claudegpt.si/news/what-is-rlhf).

### RL with verifiable rewards: how reasoning models are trained

The weak point of RLHF is the reward model. It is a neural network too, and a policy trained against it can learn to fool it, which researchers call reward hacking.

For math and code there is a cleaner option: check the answer. Ai2 named this reinforcement learning with verifiable rewards, or RLVR, in its [Tülu 3 paper](https://arxiv.org/abs/2411.15124) in November 2024. The reward comes from a rule: the answer matches or it doesn't, the code passes the tests or it fails.

DeepSeek's [R1 paper](https://arxiv.org/abs/2501.12948) (January 2025) showed how far this goes. The team trained DeepSeek-R1-Zero from its DeepSeek-V3-Base model with RL alone, without human-written reasoning examples. It used two rule-based rewards: one for a correct answer, checked by rule for math and by test cases for code, and one for putting the reasoning between thinking tags. The authors say they avoided neural reward models because those are open to reward hacking at large scale. Their algorithm, GRPO, scores each of a group of answers to the same question against the group's average, which drops the separate value network PPO needs.

On the AIME 2024 math competition, R1-Zero's average pass@1 score, the share of problems solved on the first try, rose from 15.6% to 77.9% during RL, and to 86.7% with majority voting. Without being told to, it learned to write longer answers and re-check its own work. Its output was hard to read and mixed English and Chinese, so the released DeepSeek-R1 added a small set of human-style examples and more training stages. See also [How do reasoning models work](https://claudegpt.si/news/how-do-reasoning-models-work).

## Why the reward is the hard part

An RL agent optimizes exactly what it is rewarded for, not what its designers meant. A game score is a clean reward; "a helpful answer" is not. That is why reasoning models made their biggest gains in math and code, where a program can check the answer. The DeepSeek authors write that tasks without a reliable checker, such as writing, are hard to train with pure RL.

## Where to learn more

Sutton and Barto's book is the standard reference and is [free online](http://incompleteideas.net/book/the-book-2nd.html). For a hands-on start, Aatish Bhatia and Arkarup Banerjee's interactive essay [Watch a Brain Learn](https://aatishb.com/myriad/how-brains-learn/) lets you tune a tiny creature's brain by hand, then watch it learn from reward.

## Frequently asked questions

### What is reinforcement learning from human feedback?

RLHF trains a reward model on human rankings of a language model's answers, then uses reinforcement learning to push the model toward answers that reward model scores highly. OpenAI's InstructGPT paper from March 2022 laid out the method.

### What is reinforcement learning with verifiable rewards?

RLVR gives the reward from a rule instead of a learned model: the math answer is correct or the code passes its tests. Ai2 named it in its Tülu 3 paper, and DeepSeek used rule-based rewards like these to train its R1 reasoning models.

### What is an example of reinforcement learning?

DeepMind's DQN learned to play 49 Atari 2600 games using only the screen pixels and the game score as its reward. AlphaGo used reinforcement learning from games against itself to beat professional Go players.

### What is the best book on reinforcement learning?

The standard textbook is Reinforcement Learning: An Introduction by Richard Sutton and Andrew Barto. The second edition (MIT Press, 2018) is free as a PDF on the authors' site, incompleteideas.net.

## Sources

- [Reinforcement Learning: An Introduction, second edition](http://incompleteideas.net/book/the-book-2nd.html), Richard S. Sutton and Andrew G. Barto, MIT Press
- [1.1 Reinforcement Learning (Sutton and Barto, first edition online)](http://incompleteideas.net/book/ebook/node7.html), Richard S. Sutton and Andrew G. Barto
- [1.3 Elements of Reinforcement Learning (Sutton and Barto, first edition online)](http://incompleteideas.net/book/ebook/node9.html), Richard S. Sutton and Andrew G. Barto
- [Human-level control through deep reinforcement learning](https://www.nature.com/articles/nature14236), Nature (Mnih et al., 2015)
- [Mastering the game of Go with deep neural networks and tree search](https://www.nature.com/articles/nature16961), Nature (Silver et al., 2016)
- [Training language models to follow instructions with human feedback](https://arxiv.org/abs/2203.02155), arXiv (Ouyang et al., OpenAI, 2022)
- [DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learning](https://arxiv.org/abs/2501.12948), arXiv (DeepSeek-AI, 2025)
- [Tulu 3: Pushing Frontiers in Open Language Model Post-Training](https://arxiv.org/abs/2411.15124), arXiv (Ai2, 2024)
- [Deep Reinforcement Learning](https://deepmind.google/discover/blog/deep-reinforcement-learning/), Google DeepMind
- [AlphaGo](https://deepmind.google/research/alphago/), Google DeepMind
- [Watch a Brain Learn: a visual explanation of reinforcement learning](https://aatishb.com/myriad/how-brains-learn/), Aatish Bhatia and Arkarup Banerjee
