Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.Learning alongside others
Two people carrying a sofa through a door must agree on who goes first; if both try to be polite or both push, it fails, even though they want the same thing. Two players of rock–paper–scissors who each adapt to the other’s last habits just chase each other around in circles. Multi-agent learning studies both situations: teammates who must coordinate, and opponents whose best move depends on yours.
Multi-agent RL trains teams of robots and warehouse vehicles, traffic signal controllers, and game agents such as AlphaStar and OpenAI Five; self-play is how AlphaGo Zero learned.
- 1. In multi-agent learning, each agent's environment…
- 2. Teammates with the same reward can still…
- 3. Adapting players in rock–paper–scissors tend to…
Level 1: Beginner
★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.By hand
- Markov (stochastic) game: states, one action per agent, a joint transition, and one reward per agent. A matrix game is the one-state case.
- Cooperative, competitive, mixed: a common reward (team), zero-sum rewards (opponents), or anything in between (general-sum).
- Nash equilibrium: a joint policy where no agent gains by changing its own policy alone. Games may have several; in zero-sum games all have the same value.
- Non-stationarity: from one agent’s point of view, the others’ changing policies make its environment non-stationary, which breaks the assumptions of single-agent convergence results.
- Independent learners: each agent runs its own RL algorithm and treats the others as part of the environment.
- Centralised training, decentralised execution (CTDE): a critic or value function sees everything during training, while each agent acts on its own observations (MADDPG, COMA, VDN, QMIX, MAPPO).
- Self-play and population training: an agent learns against copies or past versions of itself (AlphaGo Zero, AlphaStar’s league).
- 1. A Nash equilibrium is a joint policy where…
- 2. CTDE means…
- 3. Independent learners treat the others as…
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.Coordination in the climbing game
Exercise 1.
- The climbing game (Claus and Boutilier 1998): both agents receive the payoff of the joint action; rows a, b, c are (11, −30, 0), (−30, 7, 6), (0, 0, 5). (a, a) is optimal but next to the −30 penalties.
- Each agent explores with a Boltzmann (softmax) policy whose temperature cools from 10 to 0.05 over 3,000 rounds.
- Independent Q-learners (α = 0.1), optimistic (distributed) Q-learners that keep the best reward seen for each action, and a central learner with one value per joint action.
- Fictitious play in rock–paper–scissors: each player best-responds to the other’s empirical action frequencies; exploitability (the total gain available from best responses) measures distance from the equilibrium.
Practice.
- Try independent learners first: independent PPO (IPPO) and MAPPO are strong baselines in cooperative benchmarks such as SMAC.
- Use a centralised critic when agents need to coordinate: the critic sees every agent’s action, which removes much of the non-stationarity.
- Factorise team values carefully: VDN sums per-agent values and QMIX mixes them monotonically, so each agent’s greedy action is consistent with the team’s, but neither can represent every payoff table.
- For competitive games use self-play with a pool of past opponents, or regret-based methods (CFR) for imperfect-information games like poker.
- Tools: PettingZoo (the multi-agent Gymnasium API), MARLlib, EPyMARL, OpenSpiel for games.
def learn_climbing(method, rng, rounds=3000, alpha=0.1, beta=0.01):
Q1, Q2 = [0.0] * 3, [0.0] * 3
for t in range(rounds):
temp = max(10 * 0.998 ** t, 0.05)
i, j = boltzmann(Q1, temp, rng), boltzmann(Q2, temp, rng)
r = climbing_reward(i, j, rng)
for Q, a in ((Q1, i), (Q2, j)):
if method == "optimistic": Q[a] = max(Q[a], r)
else: Q[a] += (alpha if method == "independent" or r >= Q[a] else beta) * (r - Q[a])
return Q1.index(max(Q1)), Q2.index(max(Q2))- 1. A strong cooperative baseline is…
- 2. QMIX restricts the mixing of agent values to be…
- 3. The multi-agent counterpart of Gymnasium is…
Level 3: Advanced
★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.Theory
Why independent learners miscoordinate. Each agent estimates the average payoff of its own action over what the partner is currently doing. While the partner explores, action a meets −30 two times in three, so its estimate is far below 11, while c is safe; the learners drift to a safe joint action. Both (a, a) and (b, b) are Nash equilibria of the climbing game, so a learner can settle on the worse one and have no individual reason to leave.
Optimism and its limit. In a deterministic common-payoff game, the best reward ever seen for an action equals its value when the partner plays its best reply, so optimistic agents find the optimal joint action. With stochastic payoffs the maximum is biased: a joint action that sometimes pays 14 looks better than one that always pays 11. Hysteretic learning (Matignon, Laurent and Le Fort-Piat 2007) is a compromise: learn quickly from good news and slowly from bad news.
Zero-sum learning dynamics. In a zero-sum game, no-regret learners such as multiplicative weights have average strategies that converge to a Nash equilibrium: the average regret bounds the exploitability of the average. Their last iterate need not converge; in rock–paper–scissors it spirals away from the equilibrium towards the boundary. Optimistic variants, which use the last payoff as a prediction of the next, make the last iterate converge in zero-sum games (Daskalakis and Panageas 2019). Fictitious play’s frequencies also converge in zero-sum games (Robinson 1951), slowly.
Value factorisation. VDN writes Q_team = Σ_i Q_i, so maximising each Q_i maximises the sum. A payoff table that is not a sum, such as the climbing game, cannot be represented this way, and the best additive fit can point to the wrong joint action.
- 1. Independent learners avoid action a in the climbing game because…
- 2. Optimistic learners fail when payoffs are…
- 3. In zero-sum games, no-regret learners' averages converge to…
Level 4: Expert
★★★★★ Expert⏱ 30 minResearchers: original papers and open problems.Which learners coordinate on the optimum of the climbing game with deterministic and stochastic payoffs, and which learning dynamics converge in rock–paper–scissors?
History.
- G. Brown (1951) proposed fictitious play and J. Robinson (1951) proved it converges in zero-sum games.
- M. Littman (1994) introduced Markov games to RL with minimax-Q; C. Claus and C. Boutilier (1998) studied independent and joint-action learners and introduced the climbing game.
- M. Lauer and M. Riedmiller (2000) introduced distributed (optimistic) Q-learning; L. Matignon, G. Laurent and N. Le Fort-Piat (2007) introduced hysteretic Q-learning.
- R. Lowe and colleagues (2017) introduced MADDPG; J. Foerster and colleagues (2018) introduced COMA; T. Rashid and colleagues (2018) introduced QMIX.
- O. Vinyals and colleagues (2019) reached Grandmaster level in StarCraft II with AlphaStar’s league training.
Exercise 2.
- 40 runs of 3,000 rounds for each learner in the climbing game and in its partially stochastic version, where (b, b) pays 14 or 0 with equal probability (still 7 on average). Hysteretic learners use rates 0.1 for good news and 0.01 for bad news.
- Rock–paper–scissors from the starting strategies (0.5, 0.25, 0.25) and (0.25, 0.5, 0.25): fictitious play, multiplicative weights with step 0.1, and optimistic multiplicative weights; exploitability after 100, 1,000 and 10,000 steps. These dynamics are deterministic.
Seed 0, share of runs ending on the optimal joint action (a, a):
| learners | climbing | partially stochastic climbing |
|---|---|---|
| independent | 0.175 | 0.200 |
| hysteretic | 0.950 | 0.800 |
| optimistic | 1.000 | 0.000 |
| joint (central) | 1.000 | 1.000 |
Rock–paper–scissors exploitability:
| steps | fictitious play | weights, last iterate | weights, average | optimistic, last iterate |
|---|---|---|---|---|
| 100 | 0.2079 | 0.4871 | 0.0682 | 0.3668 |
| 1,000 | 0.0649 | 1.5845 | 0.0351 | 0.0740 |
| 10,000 | 0.0201 | 1.5519 | 0.0177 | below 10⁻⁶ |
- Independent learners rarely coordinated: 12.5% to 17.5% of runs reached (a, a) over three seeds; most settled on the equilibrium (b, b). In the stochastic game 80% to 90% of runs ended miscoordinated, on joint actions that are not even equilibria.
- Optimism was perfect, then useless: 100% with deterministic payoffs on all seeds, 0% with the stochastic (b, b), where every run chased the lucky 14.
- Hysteretic learners were robust: 92.5% to 100% on the deterministic game and 72.5% to 80% on the stochastic one.
- The central learner always succeeded, but it needs one value per joint action, which grows exponentially with the number of agents.
- Plain learning dynamics cycled: the last iterate of multiplicative weights moved away from the equilibrium (exploitability 1.55 after 10,000 steps, close to the maximum of 2), while its average converged; the optimistic variant’s last iterate converged.
- Exercise 1: independent learners reached (a, a) in 4 of 20 runs, optimistic and central learners in 20 of 20; fictitious play’s exploitability fell from 0.5455 after 10 rounds to 0.0475 after 2,000.
Multi-agent RL in practice
- Games: self-play with populations reached superhuman play in Go, StarCraft II (AlphaStar), Dota 2 (OpenAI Five) and poker (Libratus and Pluribus, via counterfactual regret minimisation).
- Robotics and logistics: warehouse fleets, drone swarms and traffic signals use CTDE methods, often with communication between agents.
- Language models: multi-agent debate and self-play fine-tuning apply the same ideas to text.
- Social dilemmas: general-sum games study how cooperation can emerge among self-interested learners.
References
- C. Claus and C. Boutilier (1998). “The dynamics of reinforcement learning in cooperative multiagent systems.” AAAI.
- M. Littman (1994). “Markov games as a framework for multi-agent reinforcement learning.” ICML.
- L. Matignon, G. Laurent and N. Le Fort-Piat (2007). “Hysteretic Q-learning: an algorithm for decentralized reinforcement learning in cooperative multi-agent teams.” IROS.
- T. Rashid, M. Samvelyan, C. Schroeder de Witt, G. Farquhar, J. Foerster and S. Whiteson (2018). “QMIX: monotonic value function factorisation for deep multi-agent reinforcement learning.” ICML.
- S. Albrecht, F. Christianos and L. Schäfer (2024). “Multi-Agent Reinforcement Learning: Foundations and Modern Approaches.” MIT Press.