Introduction
In the quest for "lifelong learning," the goal is to develop agents that do not need to start from scratch every time they encounter a new task. If an agent already knows how to find a "blue square" and a "purple circle," it should ideally be able to find "a blue square OR a purple circle" without hours of retraining. This paper provides a mathematical "recipe" for such zero-shot reinforcement learning (RL) by leveraging the framework of entropy-regularized RL.
Methodology: The Power of Composition
Traditionally, RL is rigid; value functions—which estimate long-term rewards—are tied to specific reward functions. While frameworks like Linearly-solvable MDPs (LMDPs) allow for composition, they have been limited to simple cases with known dynamics. This research brings compositional power to modern deep RL settings where dynamics are unknown and states are complex (e.g., pixels).
The authors build their approach on Entropy-Regularized RL, where agents maximize reward while maintaining policy diversity. The key technical contributions include:
- The Desirability Function: Defined as $Z(s, a) = \exp(Q(s, a)/\tau)$, where $Q$ is the value function and $\tau$ is a temperature parameter.
- Theorem of Optimal Composition: The authors prove that if a library of tasks differs only in rewards at goal states, the optimal desirability function for a composite task is a linear combination of the base functions.
- The "Max" Rule: As temperature $\tau$ approaches zero, the optimal $Q$-function for a union of tasks becomes the maximum of the individual $Q$-functions.
This mathematical "recipe" turns a complex optimization problem into a simple linear algebra problem: while $Q$-functions do not add up linearly, their exponentials (desirability functions) do.
Experimental Setup
The method was evaluated using a custom 2D Grid-World Video Game. The agent learns from raw 84x84 RGB pixel frames, requiring it to navigate based on visual input rather than coordinate lists.
Tasks included base objectives (e.g., "collect any purple object") and composite tasks (e.g., "Purple OR Blue").
Key Results and Insights
The experiments demonstrated that any task within the "span" of the learned library can be solved optimally and immediately.
- Multimodality: Composed value functions naturally handle multiple goals. The value surface (panel a) shows multiple peaks, allowing the agent to dynamically choose the nearest or most rewarding target.
- Optimal Navigation: In "OR" tasks, the agent correctly identifies and navigates to the nearest valid object (panel b).
- Zero-Shot Generalization: In tasks like
PurpleOrBlue, the composed agent achieved rewards identical to an agent trained specifically for that task from scratch (panel c). - Temporal Sequences: The agent successfully solved long-term "collect all" tasks by moving greedily from one item to the next until the board was clear.
Limitations and Future Work
The current proof for Theorem 2 assumes deterministic transitions. While experiments suggest the method works in practice, a formal proof for stochastic environments is a necessary next step. Additionally, the "recipe" currently requires tasks to differ only in rewards at goal states. Finally, while "OR" compositions are mathematically optimal, "AND" compositions (intersections) remain approximations that can sometimes lead to local optima.
Summary updated