Skill-based Model-based Reinforcement Learning

Lucy Xiaoyang Shi, Joseph J Lim, Youngwoon Lee

Abstract

Model-based reinforcement learning (RL) is a sample-efficient way of learning complex behaviors by leveraging a learned single-step dynamics model to plan actions in imagination. However, planning every action for long-horizon tasks is not practical, akin to a human planning out every muscle movement. Instead, humans efficiently plan with high-level skills to solve complex tasks. From this intuition, we propose a Skill-based Model-based RL framework (SkiMo) that enables planning in the skill space using a skill dynamics model, which directly predicts the skill outcomes, rather than predicting all small details in the intermediate states, step by step. For accurate and efficient long-term planning, we jointly learn the skill dynamics model and a skill repertoire from prior experience. We then harness the learned skill dynamics model to accurately simulate and plan over long horizons in the skill space, which enables efficient downstream learning of long-horizon, sparse reward tasks. Experimental results in navigation and manipulation domains show that SkiMo extends the temporal horizon of model-based approaches and improves the sample efficiency for both model-based RL and skill-based RL.

Introduction

Traditional Model-Based Reinforcement Learning (MBRL) agents learn to "imagine" the outcomes of their actions using a learned dynamics model. While sample-efficient, these models typically predict the environment's state one tiny step at a time. For long-horizon tasks, such as a robot navigating a building or preparing a meal, this approach faces two critical challenges: compounding error and search complexity. Small inaccuracies in single-step predictions accumulate over hundreds of steps, leading to nonsensical long-term "imaginations." Furthermore, planning every individual motor movement for a multi-minute task is computationally prohibitive.

Comparison of dynamics models: flat models suffer from compounding error, while SkiMo's skill dynamics model enables accurate long-term planning.

To address these issues, we introduce SkiMo (Skill-based Model-based RL). SkiMo combines the planning power of MBRL with the temporal abstraction of skills. By moving the abstraction from just the policy to the model itself, SkiMo predicts "skill outcomes" rather than individual action outcomes, significantly reducing compounding error and planning complexity.

Methods

The SkiMo framework operates in two distinct phases: pre-training from unlabeled offline data and downstream task learning.

The SkiMo framework: (1) Pre-training skills and dynamics from offline data, and (2) Downstream RL using planning in skill space.

1. Pre-training from Unlabeled Offline Data

SkiMo leverages task-agnostic offline datasets to learn a skill repertoire. The core innovation is the joint learning of a Skill Encoder and a Skill Dynamics Model. The Skill Encoder (a Conditional VAE) compresses action sequences into a latent skill $z$. Simultaneously, the saltatory dynamics model learns to "leap" from the current state $s_t$ to the state at the end of the skill's execution $s_{t+H}$. By training these components together, the latent skill space is regularized toward predictability, ensuring the encoder learns skills that the dynamics model can accurately forecast.

2. Downstream Task Learning

When presented with a specific goal, the agent utilizes its pre-trained skills for efficient learning.

  • Planning in Skill Space: The agent employs the Cross-Entropy Method (CEM) to search for optimal sequences of high-level skills in imagination.
  • Policy Optimization: A high-level task policy is trained to select skills that maximize rewards. The skill dynamics model generates "imaginary" trajectories for training, drastically reducing the need for real-world environment interactions.

Experimental Evaluation

SkiMo was evaluated on four challenging long-horizon benchmarks: Maze (navigation), FrankaKitchen (sequential manipulation), Mis-aligned Kitchen (out-of-distribution sequences), and CALVIN (tabletop manipulation).

Key Results

  • Sample Efficiency: In the Kitchen environment, SkiMo achieved performance parity with the best skill-based baseline (SPiRL) while requiring 5x fewer environment interactions.
  • Long-Horizon Success: In the Maze task, SkiMo was the only method capable of consistently reaching the goal. Flat MBRL methods failed as their single-step models could not maintain accuracy over the 1,000+ steps required.
  • Robustness: Even in the "Mis-aligned Kitchen," where the required task sequence was rare in the offline data, the skill dynamics model adapted and planned effectively.

Conclusion

SkiMo demonstrates that coupling skill discovery with dynamics modeling creates a powerful synergy. Predictability serves as a structural prior, preventing the learning of chaotic behaviors that are impossible to plan with. While current limitations include a fixed skill horizon and a reliance on state-based inputs, SkiMo represents a significant step toward enabling robots to solve complex, long-duration tasks with human-like efficiency. Future work will explore variable-length semantic skills and high-dimensional visual inputs.

Summary updated

BibTeX
@inproceedings{shi2022skill,
  author = {Lucy Xiaoyang Shi and Joseph J Lim and Youngwoon Lee},
  title = {{Skill-based Model-based Reinforcement Learning}},
  booktitle = {Conference on Robot Learning},
  year = {2022},
  url = {https://openreview.net/forum?id=iVxy2eO601U},
}
Figure