RL^2
Recurrent policy that learns a fast reinforcement learning algorithm in its weights.
Reinforcement learning and control · 31 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
At a glance
- Parameters
- 447.8K
- Operations
- 31
- Framework
- PyTorch
- Recurrent
- No
- Published
- arXiv (submitted to ICLR 2017)
- Cited by
- 457 (as of 27 October 2026)
- Authors
- Yan Duan, John Schulman, Xi Chen and others
- License
- MIT
- Checked
- Passed: the trace was replayed operation by operation and matched the model's own output for this input.
Files
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
Details
- Stable ID
- m19665
- Graph hash
- b3f5936eb88b3ebaae753d55f7f6bbdcc275c3234f4251d19c818e3d437b8fa6
- Skeleton hash
- 60609970046411b64b0a831f60879934df93443ef500e3c4cf3f22878176b776
- Architecture hash
- eaa93020c5cf1e9ebe26c49791af1263efc4626d31046cc4f8ae0e79ef8c9854
- Diagram SHA-256
- 629ed9ad716e129575cf876fe6e93fd0bae13fdc4a2c127b97a93074392b89fb
- TorchLens version
- 2.36.0
- Renderer
- graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
- Check
- Forward pass replayed in PyTorch
What it is
RL^2 is a reinforcement learning agent that learns how to learn: the authors do not design a fast learning algorithm by hand, but represent it as a recurrent neural network (RNN) and learn it from data. Their motivation is that deep reinforcement learning requires a huge number of trials. Animals, in contrast, can learn new tasks in just a few trials by drawing on prior knowledge about the world.
The fast algorithm is encoded in the weights of the RNN, which are learned slowly by a general-purpose reinforcement learning algorithm. The RNN receives everything a typical reinforcement learning algorithm would receive (observations, actions, rewards and termination flags) and keeps its state across episodes in a given Markov Decision Process (MDP). Its activations therefore store the state of the fast algorithm on the current, previously unseen MDP.
On randomly generated multi-arm bandit problems and finite MDPs, the paper reports that the trained agent performs close to human-designed algorithms with optimality guarantees on new MDPs. It also reports a vision-based navigation task as evidence that the approach scales up to high-dimensional problems. The model on this page comes from a PyTorch implementation of the idea that applies it to the Meta World benchmark.
Key idea. The paper represents a fast reinforcement learning algorithm as a recurrent neural network whose weights are learned slowly by a general-purpose reinforcement learning algorithm.
- RL^2
- RL2
- Fast Reinforcement Learning via Slow Reinforcement Learning
- meta reinforcement learning
- learning to learn
- recurrent policy
- Meta World
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
Cite the paper
@misc{duan2016rl2fastreinforcementlearning,
title={RL$^2$: Fast Reinforcement Learning via Slow Reinforcement Learning},
author={Yan Duan and John Schulman and Xi Chen and Peter L. Bartlett and Ilya Sutskever and Pieter Abbeel},
year={2016},
eprint={1611.02779},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/1611.02779},
}