Abstract
Multi-agent reinforcement learning (MARL) often struggles with sample inefficiency and a lack of generalization to changing team compositions, known as ad hoc team play. We present Collaborative Q-learning (CollaQ), a framework that addresses these challenges by decomposing an agent's value function into a self-term ($Q^{alone}$) and an interactive term ($Q^{collab}$). This decomposition, combined with an attention-based architecture and a Multi-Agent Reward Attribution (MARA) loss, allows agents to learn generalizable collaborative roles. CollaQ achieves state-of-the-art performance on the StarCraft Multi-Agent Challenge (SMAC), outperforming existing methods by up to 40% and demonstrating superior robustness in ad hoc testing scenarios.
Introduction
Multi-Agent Reinforcement Learning (MARL) has demonstrated remarkable success in complex environments like Dota 2 and StarCraft II. However, two significant hurdles persist: sample inefficiency and poor generalization. Sample inefficiency arises because the joint state-action space grows exponentially with the number of agents. Generalization issues, or the difficulty of "ad hoc team play," occur because agents often overfit to specific team configurations and agent IDs, failing when teammates are added, removed, or modified.
CollaQ aims to overcome these limitations by enabling decentralized policies that are both sample-efficient and robust to changes in team composition.
Methodology
The core of the CollaQ framework is the decomposition of the Q-function. By applying a Taylor expansion, the authors mathematically separate an agent's estimate of future rewards into two components:
- $Q^{alone}$ (The Self-Term): Represents the value of an agent's actions as if it were operating in isolation, depending solely on its local state.
- $Q^{collab}$ (The Interactive Term): Captures the change in value resulting from the presence and actions of nearby teammates.
Multi-Agent Reward Attribution (MARA) Loss
To ensure the integrity of this decomposition, the Multi-Agent Reward Attribution (MARA) loss is introduced. This regularizer forces $Q^{collab}$ to zero when no other agents are within the agent's field of view, preventing the model from leaking self-information into the collaborative term.
Attention-Based Architecture
To accommodate varying team sizes and configurations, CollaQ utilizes an attention mechanism. Instead of fixed-size inputs, agents "attend" to the states of visible teammates. This flexibility allows the model to generalize across different numbers of agents without retraining.
Experimental Evaluation
CollaQ was evaluated on two distinct environments:
- Toy Gridworld: A resource collection task requiring coordination between agents with different expertise.
- StarCraft Multi-Agent Challenge (SMAC): A high-complexity benchmark involving "Hard" and "Super Hard" maps such as
27m_vs_30mandMMM2.
Results and Discussion
CollaQ significantly outperformed state-of-the-art baselines, including QMIX, QTRAN, and VDN. On challenging SMAC maps, CollaQ improved win rates by approximately 40% for the same training budget.
Ad Hoc Generalization and Robustness
In ad hoc testing—where team configurations were altered by swapping unit types or changing team size—CollaQ maintained a performance lead of over 30% compared to previous methods. Furthermore, CollaQ demonstrated remarkable robustness to agent ID shuffling. While baselines like QMIX saw performance halve when IDs were randomized, CollaQ remained stable, indicating that it learns functional collaborative roles rather than ID-specific scripts.
Conclusion
CollaQ introduces a powerful paradigm for MARL by framing collaboration as reward attribution. By learning to handle individual tasks first ($Q^{alone}$) and then adjusting for social context ($Q^{collab}$), agents achieve faster convergence and better generalization. Future work will explore the application of this decomposition to competitive and mixed-motive scenarios, as well as addressing the dependencies on local observation ranges.
Summary updated