Combining Modular Skills in Multitask Learning

Edoardo Maria Ponti, Alessandro Sordoni, Siva ReddyarXiv 2022

Abstract

Multitask learning (MTL) often faces a fundamental trade-off between the interference seen in fully shared models and the data-inefficiency of task-specific ones. This paper introduces SKILLED, a latent-skill framework that automatically decomposes complex tasks into a set of reusable, modular skills. By learning a task-skill allocation matrix alongside parameter-efficient adaptations, the model achieves superior sample efficiency in reinforcement learning and enhanced few-shot generalization in natural language processing (NLP) compared to standard baselines.

Introduction

In traditional MTL, researchers typically choose between two extremes: fully shared models, which suffer from "negative interference" where learning one task degrades another, and task-specific models, which fail to share knowledge and generalize poorly to new domains.

Inspired by the modularity of human intelligence, the authors propose that models should disentangle facets of knowledge and recombine them to solve novel problems. The challenge lies in automatically discovering a discrete inventory of skills and determining the optimal combination for any given task without relying on manual, expert-defined labels.

The SKILLED Framework

The proposed framework, SKILLED, operates through several key components:

  1. Skill Inventory: The model maintains a fixed set of parameter-efficient adaptations (such as LoRA or sparse fine-tuning) that represent individual "skills."
  2. Task-Skill Allocation Matrix ($Z$): A binary matrix where each row represents a task and each column a skill. A value of "1" indicates that a specific skill is active for that task.
  3. Differentiable Learning: To optimize the discrete binary matrix, the authors utilize a Gumbel-sigmoid relaxation, allowing the allocation to be learned via standard gradient descent.
  4. Parameter Composition: For a specific task, the model averages the parameters of all active skills and integrates them into a frozen base model.
The SKILLED architecture: Tasks select a subset of modular skills from an inventory, which are then composed to adapt the base model layers.

To ensure modularity, the authors introduce an Indian Buffet Process (IBP) prior to encourage sparsity and a two-speed learning approach, where the allocation matrix $Z$ is updated faster than the skill parameters themselves. This forces the model to commit to a modular structure early in the training process.

Experimental Evaluation

The model was evaluated in two distinct domains:

  • Reinforcement Learning (BabyAI): A grid-world environment for grounded instruction following across 8 levels of increasing complexity.
  • Natural Language Processing (CrossFit): A benchmark of 160 diverse NLP tasks (QA, sentiment, etc.) used to test few-shot adaptation to 20 held-out tasks.

Key Results

Sample Efficiency in RL

On the BabyAI benchmark, the SKILLED model demonstrated remarkable sample efficiency. It reached a 99% success rate in approximately 2.2 million episodes, significantly faster than the shared baseline (3.5 million) and even the expert-labeled baseline (4.6 million). This suggests that the model discovers synergies and sub-skills that human experts might overlook.

Success rate comparison on BabyAI: The SKILLED model (red dashed line) achieves higher success rates faster than shared, private, or expert-labeled baselines.

Few-Shot Generalization in NLP

In the CrossFit NLP benchmark, SKILLED achieved an average score of 56.9, outperforming the state-of-the-art HyperFormer (52.7) and standard shared baselines (53.9). The model naturally learned a hierarchy where complex tasks activated supersets of skills used in simpler tasks. Furthermore, the learned allocation matrices were highly discretized, showing that the model makes clear binary choices about skill utility.

Discussion and Limitations

While SKILLED provides a robust path toward modular MTL, it currently requires the number of skills to be set as a fixed hyperparameter. Future work may explore dynamic skill inventories and the application of this modularity to continual learning settings where tasks are added over time. Despite these constraints, the ability to learn interpretable, reusable skills represents a significant step toward more flexible and efficient artificial intelligence.

Summary updated

BibTeX
@misc{ponti2022combining,
  author = {Edoardo Maria Ponti and Alessandro Sordoni and Siva Reddy},
  title = {{Combining Modular Skills in Multitask Learning}},
  year = {2022},
  eprint = {2202.13914},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2202.13914},
}
Figure