Composing Task Knowledge With Modular Successor Feature Approximators

Wilka Torrico Carvalho, Angelos Filos, Richard Lewis, Honglak Lee, Satinder Singh

Introduction

In Reinforcement Learning (RL), a long-standing goal is to train agents that can learn a set of basic skills—such as picking up an object or navigating a room—and seamlessly combine them to solve novel, composite tasks. A popular framework for achieving this is Successor Features and Generalized Policy Improvement (SF&GPI). By learning predictive representations (Successor Features) of the environment, an agent can transfer its knowledge to new tasks using GPI.

However, SF&GPI has a significant limitation: it typically relies on humans to manually define "cumulants," which are the specific state features the agent needs to track (e.g., "did I touch a dish?"). If the environment changes or these features are poorly designed, the agent's performance degrades. Furthermore, standard RL models use monolithic architectures that struggle to generalize when visual layouts or object combinations change.

To address this, researchers have developed Modular Successor Feature Approximators (MSFA). This novel architecture allows agents to discover which parts of their environment are important to track, enabling them to generalize to novel situations in a zero-shot manner without relying on hand-designed features.

The MSFA Architecture

MSFA merges modular neural networks with the SF&GPI framework to automate feature discovery and improve generalization.

Comparison of architectures: MSFA uses independent modules to discover and predict useful features, contrasting with monolithic approaches.

The architecture is built on several key components:

  1. Modular State Representation: Instead of a single, monolithic network, MSFA employs several independent modules. These modules communicate via a sparse attention mechanism, ensuring they share only the most relevant information.
  2. Reward-Driven Discovery: Each module is responsible for learning its own "modular cumulants" (identifying what to look for) and "modular successor features" (predicting when those events will occur).
  3. Decomposed Learning: The agent learns by attempting to reconstruct the environment's overall reward as a sum of the outputs from its individual modules. This architectural bias forces different modules to specialize in distinct aspects of the task, such as tracking specific objects or avoiding hazards.
Detailed computation of Successor Features in MSFA and how they are transferred to new tasks via Generalized Policy Improvement.

At test time, the agent leverages GPI for Zero-Shot Transfer. It can instantly re-weight its learned modules to solve a completely new task vector (e.g., "collect two apples and avoid all poison") without requiring any additional training.

Experimental Evaluation and Results

The researchers evaluated MSFA across three increasingly complex benchmarks:

  • BabyAI: A grid-world environment requiring the agent to navigate to specific objects while avoiding others.
  • Procgen (Fruitbot): A procedurally generated side-scroller with diverse visual layouts, testing the agent's robustness to unseen backgrounds.
  • Minihack: A complex, NetHack-based environment featuring traps, monsters, and partial visibility.

Key Findings

  • Matching the Oracle: In the BabyAI environment, MSFA matched the performance of the "Oracle" baseline (USFA), which relied on human-provided features. This demonstrates that MSFA can effectively replace tedious manual feature engineering.
  • Outperforming Monolithic Baselines: MSFA significantly outperformed state-of-the-art monolithic networks that attempt to learn features simultaneously. Monolithic models often failed to distinguish between objects to approach and objects to avoid, whereas MSFA's isolated modules naturally disentangled these elements.
  • Visual Robustness: In the visually noisy Procgen environment, MSFA was the only architecture that maintained high performance as the number of objects to collect increased. This highlights its superior ability to compose knowledge in randomized settings.
  • Modularity as an Inductive Bias: Even when the task-combining mechanism (GPI) was disabled, the modular architecture itself generalized better to new layouts than standard recurrent neural networks (LSTMs). The modular design helps the agent filter out environmental noise.

Limitations and Future Directions

While MSFA represents a significant step forward, the authors note a few limitations. Currently, the agent receives tasks as simple vectors (e.g., [1, -1, 0]). Future work could explore more complex task descriptions, such as natural language instructions. Additionally, while the modular bias is powerful, the feature discovery method relies on relatively simple reward regression. Integrating sophisticated techniques like meta-gradients or intrinsic motivation could further enhance robustness. Finally, scaling these modular successor features from 2D environments to high-dimensional 3D spaces or complex robotic manipulation remains an exciting open challenge.

Summary updated

BibTeX
@inproceedings{carvalho2023composing,
  author = {Wilka Torrico Carvalho and Angelos Filos and Richard Lewis and Honglak Lee and Satinder Singh},
  title = {{Composing Task Knowledge With Modular Successor Feature Approximators}},
  booktitle = {International Conference on Learning Representations},
  year = {2023},
  url = {https://openreview.net/forum?id=DrtSx1z40Ib},
}
Figure