TL;DR
This paper introduces the Forward-Backward (FB) representation, a novel unsupervised reinforcement learning framework that learns the dynamics of an environment without needing a reward signal. Once trained, it can derive near-optimal policies for any reward function specified later—whether it's reaching a goal, avoiding obstacles, or maximizing dense rewards—instantly and without additional planning.
What Problem Does This Paper Address?
In standard Reinforcement Learning (RL), an agent learns a policy to maximize a specific reward. If the reward changes, the agent usually has to start over. Goal-oriented RL (like Hindsight Experience Replay) improves this by learning to reach any state, but it struggles with complex rewards, such as "reach the goal while avoiding the red zones" or "find the nearest of three possible targets," unless those specific scenarios were anticipated during training.
Model-based RL attempts to solve this by learning the environment's physics, but planning a path through a learned model is computationally expensive and prone to compounding errors over long distances.
The authors ask: Can we learn a compact "summary" of the environment's dynamics that allows us to compute the optimal policy for any reward function immediately, without planning?
Methods
The authors propose the Forward-Backward (FB) representation. The core idea relies on decomposing the successor measure—a mathematical description of how much time an agent expects to spend in future states.
- The Representations: They learn two functions, $F$ (Forward) and $B$ (Backward).
- $F(s, a, z)$: Represents the "future" of a state-action pair under a policy parameterized by $z$.
- $B(s, a)$: Represents the "ways to reach" a state.
- The Policy: The policy is defined simply as $\pi_z(s) = \arg \max_a F(s, a, z)^\top z$.
- The Reward Link: When a reward function $r(s, a)$ is finally provided, the agent computes a task-specific vector $z_R$ by averaging the $B$ representations weighted by the reward. The optimal Q-function for that reward then becomes a simple dot product: $Q(s, a) \approx F(s, a, z_R)^\top z_R$.
- Training: They use a Temporal Difference (TD) learning algorithm adapted from recent work on successor measures. Crucially, this training is unsupervised; the agent just needs to observe transitions $(s, a, s')$ to learn how the world is connected.
Datasets
The authors evaluated their approach on four diverse environments:
- Discrete Maze: A classic 2D gridworld with four rooms.
- Continuous Maze: A 2D environment with impassable walls and stochastic (noisy) movement.
- FetchReach: A simulated 7-DOF robotic arm task where the end-effector must reach a target in 3D space.
- Ms. Pacman (Atari): A complex, pixel-based environment. The authors defined 148 reachable coordinates as potential goals to test the agent's ability to navigate the maze while avoiding monsters.
Key Insights and Ideas
- Linearizing the Q-Function: The most powerful insight is that the Q-function can be expressed as a linear product between a forward-looking representation and a reward-dependent vector. This turns the complex problem of "planning" into a simple "projection."
- Occupancy vs. Synthesis: Unlike model-based RL, which tries to "imagine" or synthesize future frames (which is hard for pixels), FB learns a predictive occupancy map. It learns where it will be, not necessarily what the state will look like.
- Zero-Shot Adaptation: Because the $B$ representation encodes how to reach every part of the state space, you can combine these "reachability" vectors to create new tasks. For example, to avoid a state, you simply subtract its $B$ vector from your target $z_R$.
Key Results
- Competitive with SOTA: In goal-reaching tasks, FB performed as well as or better than DQN and DQN+HER (Hindsight Experience Replay). In Ms. Pacman, FB successfully learned to navigate the maze from pixels, while standard DQN failed without the help of HER.
- Complex Task Generalization: The authors demonstrated that an agent trained only to "reach states" could immediately solve a task like "reach target A while avoiding zone B" just by adjusting the $z_R$ vector at test time. This is something standard goal-oriented agents cannot do without retraining.
- Scaling with Dimension: The quality of the policy improves as the dimensionality ($d$) of the representation increases. Even with $d=100$, the agent could navigate complex pixel-based environments.
Limitations and Future Work
- Exploration: The FB method doesn't solve the "exploration problem." It assumes the agent has access to a good exploration strategy or a diverse replay buffer to learn the environment's layout initially.
- Spatial Blurring: When the representation dimension $d$ is too low, the agent experiences "spatial blurring." It might get close to a goal but stop slightly short because the low-rank approximation "smears" the reward over a small area.
- Computational Cost: While the policy derivation is fast, training $F$ and $B$ requires handling $d \times d$ matrices, which could become expensive for very high-dimensional latent spaces. The authors suggest exploring ways to decouple these updates in future work.
Summary updated