Abstract
Standard Multi-Agent Reinforcement Learning (MARL) algorithms often struggle with generalization, failing when the agent population size changes between training and deployment. We present Meta Representations for Agents (MRA), a framework that decouples game-common skills from game-specific strategies. By employing hierarchical latent variables and a diversity-driven objective, MRA enables agents to discover multiple strategic modes and adapt rapidly to novel social structures. Our evaluation across diverse environments demonstrates that MRA significantly outperforms existing baselines in zero-shot transfer and learning efficiency.
Introduction
In Multi-Agent Reinforcement Learning (MARL), agents are typically trained for a fixed Markov Game (MG) with a static number of participants. However, real-world scenarios often involve dynamic populations where the "social structure"—the strategic relationships between agents—can shift. Most current algorithms are "brittle" in these settings; a team trained for three-player coordination often fails when scaled to six players.
This failure stems from the tendency of MARL models to learn a single, unimodal policy that cannot capture the diversity of behaviors required for different population sizes. To address this, we propose Meta Representations for Agents (MRA). MRA moves beyond learning a single way to play, instead developing a set of strategic "modes" that can be quickly swapped or adapted when the environment's population varies.
Methodology: Meta Representations for Agents (MRA)
The core philosophy of MRA is the decomposition of agent knowledge into two distinct components: game-common knowledge (general skills) and game-specific knowledge (contextual strategies).
Architecture
MRA utilizes a hierarchical architecture to manage these two types of knowledge. As shown in Figure 1, the system incorporates:
- Latent Variable ($z$): A high-level selector that determines the current strategic "mode."
- Multi-Head Attention: Different attention heads represent distinct relational graphs ($g$). The latent variable $z$ selects which relational graph to employ, effectively deciding which other agents are most relevant in a given scenario.
- Decentralized Actor and Centralized Critic: The actor uses the selected relational graph to generate actions based on local observations, while the critic evaluates these actions during training.
Diversity and Adaptation
To ensure the discovered strategic modes are diverse and non-overlapping, MRA maximizes the mutual information (MI) between the latent strategies and the resulting actions. This unsupervised objective forces the model to learn distinct behaviors without human labeling.
For fast adaptation to new games, MRA employs a first-order meta-learning technique inspired by the Reptile algorithm. By leveraging its pre-trained "game-common" knowledge, an agent can rapidly identify an appropriate "game-specific" relational graph through a few gradient updates, facilitating efficient transfer to unseen populations.
Experiments and Results
We evaluated MRA against baselines like MADDPG and EPC in three environments within the Particle-World framework: Treasure Collection, Resource Occupation, and a Pacman-like World.
Generalization Performance
A key test involved training agents on small populations (e.g., 3 or 6 agents) and evaluating them on significantly larger or imbalanced ones (e.g., 24 agents). MRA demonstrated superior generalization, achieving higher mean returns in zero-shot transfers compared to standard algorithms.
Key Findings
- Strategic Modes as Options: The relational graphs act as "strategic options" (e.g., focusing on teammates vs. enemies), which agents learn to deploy based on the population context.
- Exploration Efficiency: In imbalanced scenarios (e.g., 8 ghosts vs. 2 Pac-Men), where standard agents often fail to receive reward signals before being eliminated, MRA's meta-knowledge provides a "warm start" that enables survival and subsequent learning.
- Sample Efficiency: As seen in Figure 3, MRA agents reach peak performance levels with fewer training episodes than baseline models trained from scratch on specific tasks.
Discussion and Future Work
MRA provides a theoretically grounded approach to population-invariant MARL, proving that a sufficiently large latent space can contain a Nash Equilibrium for a wide range of evaluation games. However, practical challenges remain, such as manually tuning the dimension of the latent space $z$ and calculating distance metrics between complex game environments.
Future research could extend MRA to highly heterogeneous teams where every agent has a unique role, moving beyond the current "role-symmetric" assumption. Additionally, exploring objectives beyond Nash Equilibrium, such as social welfare or correlated equilibrium, could further enhance the framework's applicability to complex multi-agent systems.
Summary updated