Fast inference and transfer of compositional task structures for few-shot task generalization

Sungryull Sohn, Hyunjae Woo, Jongwook Choi, Lyubing Qiang, Izzeddin Gur, Aleksandra Faust, Honglak Lee

Abstract

We tackle real-world problems with complex structures beyond the pixel-based game or simulator. We formulate it as a few-shot reinforcement learning problem where a task is characterized by a subtask graph that describes the dependencies between subtasks. We propose a Multi-Task Subtask Graph Inferencer (MTSGI) that can quickly infer the subtask graph of a new task by leveraging a library of previously learned graphs.

Introduction: The Challenge of Compositional Tasks

In many real-world domains, tasks are inherently compositional. Completing a goal requires executing a sequence of subtasks with specific dependencies. For example, in web navigation, a user cannot submit an order without first providing shipping information and payment details. While humans excel at transferring knowledge of these structures across different websites, standard Reinforcement Learning (RL) agents often struggle.

Figure 1: Compositional task structures in web navigation. The agent must learn dependencies between subtasks like entering names, emails, and payment info across different environments.

Most Meta-RL approaches rely on unstructured "task embeddings"—black-box vectors that require vast amounts of data to generalize. This paper addresses the challenge of few-shot task generalization: how can an agent solve a brand-new, complex task with sparse rewards after only a handful of interactions? The authors introduce MTSGI (Multi-Task Subtask Graph Inferencer), a framework designed to explicitly model these dependencies as logical subtask graphs.

Methodology: Multi-Task Subtask Graph Inferencer (MTSGI)

MTSGI shifts the focus from learning latent weights to inferring explicit logic. The framework operates in three distinct phases:

  1. Meta-Training (Building the Library): The agent interacts with various training environments. Using Inductive Logic Programming (ILP), it identifies preconditions for each subtask and constructs a "subtask graph." These graphs, along with the trajectories used to discover them, are stored in a Prior Set.
  2. Prior Sampling: When encountering a new, unseen task, the agent identifies the most relevant prior from its library based on subtask overlap (using an F-score metric).
  3. Meta-Testing and Adaptation: The agent uses the sampled prior to guide its initial exploration via a Multi-Task Upper Confidence Bound (MTUCB) strategy. It then refines this knowledge by combining the prior graph with real-time observations to infer the specific structure of the new environment.
Figure 4: The MTSGI framework overview. It illustrates the pipeline from meta-training (inferring graphs from trajectories) to meta-testing (adapting to a new environment using a prior set).

The agent employs GRProp (Graph-Reward Propagation), an ensemble policy that balances prior knowledge with current evidence to make optimal decisions even with minimal interaction.

Experimental Evaluation

The researchers tested MTSGI on two complex domains:

  • Mining: A grid-world environment where agents must gather resources and craft items following multi-step recipes (e.g., smelting iron requires a furnace and coal).
  • SymWoB (Symbolic World of Bits): A benchmark involving the checkout processes of 15 real-world websites (e.g., Amazon, BestBuy, Walmart). This domain tests the agent's ability to handle form-filling, page transitions, and distractor elements.

Key Results

  • Zero-Shot Generalization: On the SymWoB domain, MTSGI achieved a success rate of over 75% on unseen websites without any prior interaction, significantly outperforming baselines that start from scratch.
  • Sample Efficiency: In the Mining domain, the explicit use of subtask graphs allowed for near-optimal performance in a fraction of the steps required by standard hierarchical or meta-RL methods.
  • Robustness: Ablation studies confirmed that even a small library of priors provides a substantial boost in adaptation speed compared to heuristic-based exploration.

Conclusion and Future Work

MTSGI demonstrates that explicit structural modeling is a powerful tool for few-shot RL. By treating tasks as logical graphs rather than black-box embeddings, agents can "understand" the rules of a new environment much like a human would.

Current limitations include the reliance on pre-learned low-level options and high-level state descriptions. Future research aims to extend this framework to raw visual inputs, enabling agents to discover both the subtasks and their logical dependencies directly from pixels.

Summary updated

BibTeX
@inproceedings{sohn2022fast,
  author = {Sungryull Sohn and Hyunjae Woo and Jongwook Choi and Lyubing Qiang and Izzeddin Gur and Aleksandra Faust and Honglak Lee},
  title = {{Fast inference and transfer of compositional task structures for few-shot task generalization}},
  booktitle = {Conference on Uncertainty in Artificial Intelligence},
  year = {2022},
  url = {https://openreview.net/forum?id=zWBXBsKiAZL},
}
Figure