QMP: Q-switch Mixture of Policies for Multi-Task Behavior Sharing

Grace Zhang, Ayush Jain, Injune Hwang, Shao-Hua Sun, Joseph J. Lim

TL;DR

QMP (Q-switch Mixture of Policies) is a new framework for multi-task reinforcement learning that speeds up training by selectively sharing behavioral policies across tasks during data collection. By using a task's own Q-function to "switch" between available policies, the agent gathers higher-quality training data without the negative interference or bias common in traditional multi-task methods.

What Problem Does This Paper Address?

Multi-task reinforcement learning (MTRL) is the "holy grail" of efficient robotics: why learn to open a door and a drawer as two completely separate problems when they both involve the same fundamental "grasping" and "pulling" behaviors?

Traditional MTRL methods usually share information in two ways:

  1. Parameter Sharing: Using the same neural network backbone for all tasks. This can lead to "negative interference," where learning one task actively hurts performance on another.
  2. Data Relabeling: Taking a trajectory from Task A and pretending it was for Task B by recalculating the rewards. This is powerful but requires knowing the reward functions for every task upfront.

The authors of QMP identify a third, under-explored avenue: Behavior Sharing. The challenge here is selectivity. If a robot learning to "open a door" blindly copies a policy for "walking," it will just waste time. The paper addresses how to principledly select which behaviors to borrow from other tasks to make data collection more informative.

Methods

The core contribution is the Q-switch Mixture of Policies (QMP). Instead of collecting data using only the current task's policy ($\pi_i$), QMP uses a mixture of all policies currently being learned $\{\pi_1, \dots, \pi_N\}$.

Figure 2: Our method (QMP) shares behavior between task policies in the data collection phase using a mixture of these policies. For example, in Task 1, each task policy proposes an action aj. The task-specific Q-switch evaluates each Q1(s, aj) and selects the best scored policy to gather reward-labeled data to train Q1 and π1. Thus, Task 1 will be boosted by incorporating high-reward shareable behaviors into π1 and improving Q1 for subsequent Q-switch evaluations.

The "Q-switch" is the selection mechanism. At every state $s$, it evaluates the action proposals from all task policies using the current task's Q-function ($Q_i$). It chooses the policy $\pi_j$ that maximizes: $$\arg \max_{\pi_j} \mathbb{E}_{a \sim \pi_j}[Q_i(s, a)] + \alpha H[\pi_j]$$ (where $H$ is an entropy term to encourage diversity).

Crucially, QMP is an off-policy data collection strategy. The "foreign" behaviors are used only to fill the replay buffer. The actual task policy $\pi_i$ is still trained to be optimal for its specific task using standard algorithms like Soft Actor-Critic (SAC). This ensures that even if a shared behavior is used for exploration, it doesn't bias the final learned policy.

Datasets

The authors evaluated QMP across seven diverse multi-task designs:

  • Multistage Reacher: A 6-DoF Jaco arm performing 5 tasks with ordered subgoals.
  • Maze Navigation: 10 tasks involving a point mass navigating a complex maze to different goals.
  • Meta-World: The standard MT10 (10 tasks) and MT50 (50 tasks) benchmarks, plus a custom "CDS" setup where objects are placed side-by-side.
  • Walker2D: 4 locomotion tasks (walking forward/backward, balancing, crawling).
  • Franka Kitchen: 10 manipulation tasks in a realistic kitchen environment.

Key Insights and Ideas

  • Bridging the Suboptimality Gap: In algorithms like SAC, the policy often "lags" behind the Q-function during training. QMP uses other tasks' policies to find actions that the current Q-function already knows are good, but the current policy hasn't learned to produce yet. This effectively "bridges the gap" and accelerates policy improvement.
  • Selective vs. Uniform Sharing: Unlike prior work that regularizes all tasks toward a single "mean" policy (which causes bias), QMP is purely selective. If Task A has nothing useful for Task B, the Q-switch simply ignores Task A's proposals.
  • Naturally Diminishing Sharing: As a task policy becomes proficient, its own Q-function will naturally start preferring its own actions over those of other tasks. Sharing is most intense early in training when it's needed most.
Figure 3: QMP generalized policy iteration

Key Results

  • Complementary Gains: QMP isn't just a standalone method; it provides additive performance boosts when combined with parameter sharing and data relabeling.
  • Outperforming Baselines: In the Multistage Reacher, QMP reached a >90% success rate in 0.5 million steps, while the next best behavior-sharing baseline took three times as long to converge.
  • Scalability: In Meta-World, the performance gap between QMP and standard methods actually increased as the number of tasks grew from 10 to 50. More tasks mean a richer "library" of behaviors to draw from.
  • Handling Conflict: In experiments with explicitly conflicting tasks (e.g., one task says "go to goal" and another says "stay still"), QMP successfully identified and ignored the conflicting behaviors.

Limitations and Future Work

  • Off-Policy Constraint: Because QMP relies on the ability to learn from data generated by "other" policies, it is currently limited to off-policy RL algorithms. It cannot be directly applied to on-policy methods like PPO without modification.
  • Computational Cost: Evaluating $N$ policies and $N$ Q-functions at every step adds overhead. While the authors show this is negligible with parallelization, it could become a bottleneck for extremely large task sets (e.g., thousands of tasks).
  • Temporal Extension: The current version switches policies at every single timestep. The authors suggest that switching at a lower frequency (temporally extended sharing) might lead to even more coherent and useful trajectories.

Summary updated

BibTeX
@inproceedings{zhang2025qmp,
  author = {Grace Zhang and Ayush Jain and Injune Hwang and Shao-Hua Sun and Joseph J. Lim},
  title = {{QMP: Q-switch Mixture of Policies for Multi-Task Behavior Sharing}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=aUZEeb2yvK},
}
Figure