Source-linked AI summary

Reward learning from human preferences and demonstrations in Atari

Borja Ibarz, Jan Leike, Tobias Pohlen, Geoffrey Irving, Shane Legg, Dario Amodei

arXiv:1811.06521v1cs.LGcs.AIcs.NEstat.ML

TL;DR

The paper asks how reinforcement learning can handle tasks without manually specified rewards, where preference-only learning suffers from exploration and information-efficiency problems. It combines expert demonstrations with trajectory preferences, trains a neural reward model, and uses its predictions to train a DQN-based agent. Across nine Atari games, the combined approach outperforms imitation learning in seven games and reaches superhuman performance on Pong and Enduro, while frozen reward models can exhibit reward hacking.

  • Problem

    Many reinforcement-learning tasks have goals that are difficult to specify as hard-coded rewards, while preference-only learning has poor state coverage and inefficient human information transfer.

  • Method

    The method initializes a policy from expert demonstrations and jointly trains a neural reward model from trajectory preferences and demonstrations to guide DQN-based reinforcement learning.

  • Results

    The combined approach outperforms imitation learning in 7 out of 9 games and achieves superhuman performance on Pong and Enduro without using game rewards.

  • Takeaways & Limitations

    Demonstrations provide exploration guidance and substantially complement preference feedback, especially in exploration-heavy Atari games.

  • Takeaways & Limitations

    Persistent reward hacking was found when preference feedback was frozen, indicating that fixed reward models can be exploited through undesired behaviors.

Abstract

from arXiv · show

To solve complex real-world problems with reinforcement learning, we cannot rely on manually specified reward functions. Instead, we can have humans communicate an objective to the agent directly. In this work, we combine two approaches to learning from human feedback: expert demonstrations and trajectory preferences. We train a deep neural network to model the reward function and use its predicted reward to train an DQN-based deep reinforcement learning agent on 9 Atari games. Our approach beats the imitation learning baseline in 7 games and achieves strictly superhuman performance on 2 games without using game rewards. Additionally, we investigate the goodness of fit of the reward model, present some reward hacking problems, and study the effects of noise in the human labels.

1 Introduction

The paper addresses reinforcement-learning tasks whose goals are difficult to encode as rewards by combining expert demonstrations with trajectory preferences. This combination reduces the burdens of imitation and preference-based learning while enabling evaluation on Atari.

  • Hard-to-specify goals motivate communicating task objectives through demonstrations, policy feedback, or trajectory preferences.
  • Imitation learning requires demonstrators to understand how to perform the task, whereas preference feedback only requires judging outcomes.
  • Random exploration guided only by preferences provides poor state-space coverage and limits the diversity of trajectories available for meaningful feedback.
  • Preference queries provide only a few hundred bits per hour per human, making them inefficient for soliciting information.
  • The approach combines imitation learning for policy initialization with a reward model trained from trajectory preferences and expert demonstrations.
  • Atari supplies difficult, diverse environments with well-specified true rewards for objective evaluation and rapid synthetic-preference experimentation.

2 Method

The method uses demonstrations to initialize a policy and online pairwise preferences to train a neural reward model, whose predictions guide reinforcement learning. The policy and reward model are trained jointly with DQfD-based optimization and regularization against overfitting.

  • 2.1 Setting: The setting replaces directly available environment rewards with demonstrations and pairwise preferences supplied by a human in the loop.
  • 2.1 Setting: Demonstrations are available initially, while preferences are collected during training as the agent interacts with the environment.
  • 2.1 Setting: The agent imitates demonstrations and maximizes a reward inferred from preferences and demonstrations.
  • 2.2 Training protocol: The training system jointly trains an expert-guided policy and a reward model from annotator preferences and, optionally, demonstrations.
  • 2.2 Training protocol: The protocol pretrains the policy on demonstrations, generates trajectories, collects clip comparisons, and adds automatically labeled demonstration pairs when enabled.
  • 2.3 Training the policy: DQfD trains a deep action-value network using a prioritized dueling double Q-loss, an expert large-margin loss, and L2 regularization.
  • 2.4 Training the reward model: The convolutional reward model maps observations to estimated rewards and learns indirectly from judgments on 25-step trajectory clips.
  • 2.4 Training the reward model: Preference probabilities depend exponentially on summed predicted rewards, and cross-entropy trains the model against annotator labels under a Bradley-Terry interpretation.

3 Experimental results

The experiments compare preference learning, imitation, demonstrations, annotation schedules, and human versus synthetic feedback across 9 Atari games. Combining demonstrations with preferences generally improves performance, particularly in exploration-heavy games, but feedback quality and frozen reward models introduce important failure modes.

  • Preferences versus imitation: The combined approach outperforms imitation learning in 8 of 9 games, with Private Eye as the exception.In 6 games, this advantage holds under every tested feedback condition, including the smallest amount of feedback.
  • Effect of demonstrations: Demonstrations provide the largest gains in exploration-heavy games, including Hero, Montezuma’s Revenge, Private Eye, and Q*bert.With only 20% of the demonstrations, performance already improves significantly; benefits appear to saturate quickly because 50% produced scores similar to full demonstrations.
  • Human versus synthetic feedback: Human feedback is usually comparable to synthetic feedback but is clearly inferior in Breakout, Montezuma’s Revenge, and Pong.The paper attributes these differences to reward-shaping misalignment and, in Montezuma’s Revenge, sensitivity to labeling errors.
  • Automatic labels: Automatic labels from demonstrations improve performance in Private Eye, Hero, and Montezuma’s Revenge, where exploration is difficult.Most games show no significant difference, while low-quality Breakout demonstrations hurt performance when used for automatic labeling.
  • Reward hacking: Frozen reward models can be exploited: predicted reward rises while true game performance plummets in Hero, Montezuma, and Private Eye.Online training can address exploitative behaviors interactively by annotating them when they become prominent in the agent’s policy.

4 Discussion

Combining demonstrations with trajectory preferences outperforms either feedback source alone and can exceed imitation performance, while frozen reward models expose reward-hacking risks.

  • Combining preferences and demonstrations outperforms either source in isolation and provides guidance without explicit reward.
  • About 1000 preference comparisons outperform imitation learning in 7 of 9 games.
  • Demonstrations typically halve the human time required to reach the same performance and especially improve exploration-heavy games.
  • Superhuman performance is achieved on Pong and Enduro, beyond what perfect imitation can attain.
  • Human preference feedback can create reward pits, whereas demonstrations provide consistent exploration guidance.
  • The authors report no significant gains from several alternative modeling, training, and annotation strategies.
  • The method was also tested with DQN/DQfD rather than A3C, supporting feasibility across two different RL algorithms.
  • Frozen reward models can be exploited through loopholes that increase predicted reward while reducing true score, especially in Hero, Montezuma, and Private Eye.

A Experimental details

The experiments use standardized Atari preprocessing, DQfD policies, and a convolutional reward model trained on clip preferences under explicit regularization and label-noise assumptions.

  • The Arcade Learning Environment uses 18 actions, initial no-ops, frame pooling and skipping, four-frame stacking, and 84x84 grayscale observations.
  • Episode boundaries and score information are removed, while synthetic oracle feedback adds an end-of-game penalty except in Pong.
  • All experiments use the same expert-game-tester demonstrations previously used by Hester et al. (2018).
  • Policies are optimized with DQfD using dueling double Q-learning, target networks, multi-step returns, prioritized replay, and permanent demonstrations.
  • The DQfD policy uses epsilon-greedy exploration with epsilon annealed from 0.1 to 0.01 during the first 105 actor steps.
  • The reward model maps four stacked 84x84 frames through four convolutional layers and a fully connected layer to a scalar reward, without using the agent action.
  • A fraction of 1/e of the data is held out for validation, with adaptive L2 regularization responding to validation-training loss gaps.
  • The reward model adds a squared-reward prior, input noise, batch normalization, dropout, and a 10% uniform-random annotator-error assumption.

A.4 Training protocol

Training begins with demonstration-based policy pretraining, then alternates trajectory collection, annotation, and reward-model-guided learning across fixed-reward iterations.

  • The protocol runs 500 iterations of 10^5 agent steps, keeping the reward model fixed within each iteration.
  • Each iteration collects trajectories and randomly selects 25-step clips for annotation, adding synthetic labels immediately when applicable.
  • A pretraining phase first trains the agent from demonstrations before the main training iterations begin.
  • Demonstration pretraining combines imitation and Q losses, while initially noisy reward-based Q targets act as a regularizer.

B Performance as a function of human effort

Performance is evaluated against joint human effort for multiple feedback schedules and learning setups, with demonstrations changing how additional feedback helps across games.

  • Figure 5 relates each game's performance to joint labeling and demonstration effort across four preference schedules and several learning setups.
  • Figure 6 reports the best achievable performance at each effort level with and without demonstrations.
  • Hero, Montezuma’s Revenge, Private Eye, and Q*bert improve with additional feedback when demonstrations are available.
  • Enduro improves with additional feedback only without demonstrations, because the demonstrations work against feedback in this game.
  • Pong is solved with little synthetic feedback, whereas human preferences yield significant gains with additional feedback.
  • Breakout and Seaquest show no clear trend; Seaquest scores remain limited because the agent does not learn to resurface after episode boundaries are removed.

C Reward model training

Reward-model training quality is assessed by comparing cross-entropy loss with the label-entropy lower bound across Atari games. The model can still support successful play when its loss remains substantially above that bound.

  • Training quality: Figure 7 plots reward-model cross-entropy loss against average label entropy during training.Average label entropy is a lower bound for loss and rises with the proportion of indifferent labels.
  • Training quality: Reward-model loss stays near the entropy bound in Beamrider, Breakout, Montezuma’s Revenge, and Private Eye.These games are identified as cases where training behaves as expected.
  • Training quality: In Hero, Q*bert, and Seaquest, loss is 50% to 100% above the entropy bound.
  • Training quality: Enduro’s loss exceeds four times the lower bound, the largest reported gap among the games.The passage notes that this gap can nevertheless be explained by other factors.
  • Training quality: In Enduro, predicted reward remains highly correlated with game score, and the agent learns to play well despite difficulty distinguishing clips with small score differences.

D Reward model alignment

Alignment is evaluated by comparing accumulated true and model rewards for synthetic and human preference feedback. Synthetic preferences generally align well, especially over longer intervals, while several limitations make human alignment and short-horizon predictions less reliable.

  • Alignment evaluation: Synthetic preference models generally align well with true reward, especially over 1000-step intervals rather than 25-step intervals.Figure 8 uses accumulated rewards over sequences of 25 and 1000 agent steps.
  • Alignment limitations: Sparse rewards in Montezuma’s Revenge and Private Eye make preference learning harder by producing fewer informative labels.
  • Alignment limitations: Preferences do not convey precise reward magnitudes, so distinguishing 10 versus 11 is no easier than distinguishing 10 versus 100.Learning intermediate reward differences requires encountering clips linked by those intermediate rewards.
  • Alignment limitations: Coarser short-interval alignment makes the learned model hackable when imprecisely timed rewards can be exploited.
  • Human alignment: Human-preference models fail to align with true reward in Breakout, Montezuma’s Revenge, and Pong.The human’s intended reward can differ from the Atari simulator’s true reward.

E Effects of label noise

Human-label noise is evaluated by varying mislabelling rates in synthetic-feedback experiments and comparing those effects with noise observed in human annotations. Noise is usually minor but substantially harms Montezuma’s Revenge.

  • Observed noise: Human-annotated experiments exhibit mislabelling rates between 5% and 10%.
  • Performance effects: These noise levels have minor impact in most games but are significantly detrimental in Montezuma’s Revenge.
  • Performance effects: Label noise therefore partially accounts for poor results in the human-labeled Montezuma’s Revenge experiments.
  • Evaluation: Figure 9 reports performance across games under different annotator mislabelling rates.The experiments use synthetic feedback with the full label schedule and omit automatic demonstration labels.

G Comparison with DQfD trained from true reward

The comparison examines DQfD trained with true reward versus a learned reward model, while emphasizing that the two settings do not expose the agent to equivalent reward information. The learned-reward method receives preference feedback on less than 1% of experience.

  • Comparison: The comparison uses average scores for DQfD trained from true reward and from the learned reward model.The scores come from full-schedule runs with autolabels.
  • Comparison caveat: The comparison is not like-for-like because a synthetic oracle makes the true reward indirectly available to the agent.
  • Comparison caveat: The learned-reward method uses at most 340,000 preference-labeled agent steps, providing reward feedback on less than 1% of experience.
  • Comparison caveat: Allowing DQfD to see the reward in only 1% of training steps would result in very poor performance, according to unreported results.

H Unsuccessful ideas

The authors report no significant performance improvements from several alternative training and annotation strategies tested alongside the main experiments.

  • The authors also found no significant gains from semi-supervised reward-model training or alternative demonstration annotation strategies.
  • Distributional and quantile distributional RL failed to stabilize training.
  • Weight sharing or copying policy weights into the reward model destabilized training.
  • Pretrained convolutional layers produced only slight sample-efficiency improvements on a few games.
Loading 1811.06521v1…