G2MAF: Test-Time Gradient Guidance for Multi-Agent Flow Policies
Organizations: Sun Yat-sen University
Abstract
Offline multi-agent reinforcement learning (MARL) learns cooperative policies from fixed datasets without further environment interaction and a learned policy is frozen at deployment. Such a frozen policy typically proposes a single joint action and executes it directly at deployment time. However, this one-shot deployment often commits to a suboptimal proposal, even when better nearby alternatives remain consistent with the behavior data. To address this issue, we propose Gradient Guided Multi Agent Flow (G2MAF), a refinement framework for optimizing joint policies at test-time. G2MAF applies one globally normalized, projected critic gradient to guide and coordinate all agents' corrections while keeping the action both feasible and close to the frozen policy proposal. Across 24 MPE and SMAC settings, its canonical variant improves 20 frozen settings, with mean relative gains of 9.2% on MPE and 8.9% on SMAC, with model inference latency increased by about 6% only.
Figures & tables
| Task | Qual. | Data | BC | ICQ | TD3+BC | CQL | OMAR | Diff | MA-SfBC | DOM2 | G 2 MAF |
|---|---|---|---|---|---|---|---|---|---|---|---|
| Spread | Expert | 96.2 | 35.0 2.6 | 104.0 3.4 | 108.3 3.9 | 98.2 5.2 | 114.9 2.6 | 95.0 5.3 | 87.5 7.3 | 88.7 6.3 | 115.2 0.9 |
| MedRep | 9.3 | 10.0 3.8 | 13.6 5.7 | 15.4 5.6 | 31.4 7.2 | 37.9 6.1 | 30.3 2.5 | 8.2 4.6 | 63.1 9.5 | 47.3 2.2 | |
| Medium | 27.0 | 31.6 4.8 | 29.3 5.5 | 39.4 3.6 | 34.1 7.2 | 47.9 18.9 | 64.9 7.7 | 51.6 14.2 | 78.6 8.1 | 59.7 1.7 | |
| Random | 0.1 | -0.5 3.2 | 6.3 3.5 | 9.8 4.9 | 24.0 9.8 | 34.4 5.3 | 6.9 3.1 | 5.1 3.9 | 37.4 11.3 | 58.0 9.0 | |
| Tag | Expert | 89.5 | 40.0 9.6 | 113.0 14.4 | 115.2 12.8 | 119.3 14.0 | 123.9 10.5 | 103.0 12.0 | 77.4 13.9 | 98.2 14.4 | 139.7 1.1 |
| MedRep | 8.6 | 0.9 1.4 | 34.5 27.8 | 28.7 20.9 | 41.7 15.3 | 47.1 15.3 | 53.9 11.4 | 12.7 7.3 | 68.2 16.7 | 73.5 7.5 |
Appendix figures & tables6 assets
Supplementary material from the paper’s appendix.
Appendix
| Map | Quality | Frozen % | G 2 MAF % | Map | Quality | Frozen % | G 2 MAF % | ||
|---|---|---|---|---|---|---|---|---|---|
| 3m | Good | 95.6 | 95.6 | 5m_vs_6m | Good | 74.4 | 78.9 | +4.4 | |
| Medium | 66.7 | 50.0 | Medium | 68.9 | 77.8 | +8.9 | |||
| Poor | 22.2 | 43.3 | +21.1 | Poor | 13.3 | 25.6 | +12.2 | ||
| 2s3z | Good | 97.8 | 95.6 | 8m | Good | 96.7 | 98.9 | +2.2 | |
| Medium | 65.6 | 76.7 | +11.1 | Medium | 76.7 | 88.9 | +12.2 | ||
| Poor | 0.0 | 4.4 | +4.4 | Poor | 0.0 | 0.0 |
| Task | Quality | Base (ms) | Grad (ms) | G 2 MAF (ms) | Task | Quality | Base (ms) | Grad (ms) | G 2 MAF (ms) | ||
|---|---|---|---|---|---|---|---|---|---|---|---|
| MPE | SMAC | ||||||||||
| Spread | Expert | 142.1 | 3.0 | 145.1 | 1.02 | 3m | Good | 189.9 | 3.4 | 179.5 | 0.94 |
| MedReplay | 137.4 | 3.0 | 142.7 | 1.04 | Medium | 175.7 | 3.9 | 188.5 | 1.07 | ||
| Medium | 140.5 | 3.2 | 149.1 | 1.06 | Poor | 221.2 | 6.8 | 233.2 | 1.05 | ||
| Random | 137.3 | 2.9 | 143.9 | 1.05 | 2s3z | Good | 153.8 | 4.3 | 181.9 | 1.18 | |
| Tag | Expert | 138.9 | 3.1 | 150.7 | 1.08 | Medium | 164.2 | 3.7 | 162.4 | 0.99 | |
| Task | Quality | Frozen | G 2 MAF | Best- | 1-agent | Factor. | Task | Quality | Frozen | G 2 MAF | Best- | 1-agent | Factor. |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MPE | SMAC | ||||||||||||
| Spread | Expert | 108.59 | 3m | Good | 19.17 | – | |||||||
| MedReplay | 43.29 | Medium | 15.12 | – | |||||||||
| Medium | 59.35 | Poor | 9.14 | – | |||||||||
| Random | 36.69 | 2s3z | Good | 19.54 | – | ||||||||
| Tag | Expert | 113.02 | Medium | 17.08 | – | ||||||||
| Task | Quality | Canonical | LOTO | LOTO | Task | Quality | Canonical | LOTO | LOTO |
| MPE | SMAC | ||||||||
| Spread | Expert | 0.1 | 3m | Good | 1 | ||||
| MedReplay | 0.1 | Medium | 2 | ||||||
| Medium | 0.1 | Poor | 2 | ||||||
| Random | 0.1 | 2s3z | Good | 2 | |||||
| Tag | Expert | 0.1 | Medium | 2 | |||||
Cooperative MARL
Cooperative multi-agent reinforcement learning (MARL) trains agents to coordinate toward shared goals under partial information and decentralized control.
See all 231 papers