---
title: "Swarms, Flocks, Gangs: How to build, train, and evaluate multi-agent systems"
description: "Four agents sharing one Qwen3-0.6B policy learn to pool private numbers and submit a sorted list, trained with GRPO-style group-normalized team rewards that penalize token use."
url: "https://swe.quest/articles/swarms-flocks-gangs-how-to-build-train-and-evaluate-multi-agent-systems-94ba4fbca4851b84"
canonical: "https://huggingface.co/blog/training-swarms"
source: "Hugging Face"
published: "2026-11-26"
difficulty: "hard"
kind: "How-to"
reading_minutes: 13
tags: ["ai-agents","model-training","llms","evals"]
---

# Swarms, Flocks, Gangs: How to build, train, and evaluate multi-agent systems

A post on [Hugging Face](https://swe.quest/sources/hugging-face.md), published 2026-11-26, 13 min read, How-to. Original: [https://huggingface.co/blog/training-swarms](https://huggingface.co/blog/training-swarms)

## Summary

Four agents sharing one Qwen3-0.6B policy learn to pool private numbers and submit a sorted list, trained with GRPO-style group-normalized team rewards that penalize token use. Over 75 updates, training success rose from 6.6% to 82.3% (81.25% on held-out problems) while generated tokens per team fell 37.4%, with broadcasts replacing direct messages. The trained team beat an untrained best-of-8 baseline (37.5%) at about 1/13 the tokens. The post frames multi-agent systems as a Dec-POMDP with credit-assignment and non-stationarity problems, argues swarms must be compared at matched compute budgets, and gives a reproducible TRL plus vLLM script for Hugging Face Jobs on two H200s (about $50).

Written by swe.quest, not by the author.

**Difficulty:** Hard: written for specialists in the field

## Topics

- [AI agents](https://swe.quest/tags/ai-agents.md) (AI & ML)
- [Model training](https://swe.quest/tags/model-training.md) (AI & ML)
- [LLMs](https://swe.quest/tags/llms.md) (AI & ML)
- [Evaluation](https://swe.quest/tags/evals.md) (AI & ML)

## Prerequisites

- reinforcement learning basics ([easy posts on Model training](https://swe.quest/tags/model-training.md?difficulty=easy))
- GRPO policy optimization ([easy posts on Performance engineering](https://swe.quest/tags/performance.md?difficulty=easy))
- LLM tool calling ([easy posts on LLMs](https://swe.quest/tags/llms.md?difficulty=easy))
- vLLM serving

## Keywords

TRL, Qwen3-0.6B, vLLM, GRPO, Hugging Face Jobs, Dec-POMDP, s³ Simple Scaling of Swarms

## Related posts

- [DaisyRose-27B: Pushing the Frontier of Post-Training Efficiency](https://swe.quest/articles/daisyrose-27b-pushing-the-frontier-of-post-training-efficiency-d0f8a1d5a44a14e8.md): Hugging Face · 2026-11-18 · Hard · 6 min read · Model training, AI agents, LLMs, Sandboxing & isolation, Evaluation
  DaisyRose-27B is an RL post-trained version of Qwen3.8-27B, trained with the Miles framework on about 1,200 curated long-horizon agent tasks over 18 days on 144 H200s.
- [Together AI at ICML 2026: frontier research across the full stack](https://swe.quest/articles/together-ai-at-icml-2026-frontier-research-across-the-full-stack-7ba2ab06914581c4.md): Together AI · 2026-06-30 · Hard · 10 min read · Inference & serving, Model training, LLMs, AI agents, Evaluation
  Together AI's nine ICML 2026 papers span the AI stack from agents to GPU kernels, each with a headline result.
- [Turning Database Grading into RL Rewards: Post-Training Agents with ThinkingBox](https://swe.quest/articles/turning-database-grading-into-rl-rewards-post-training-agents-with-thinkingbox-9126975f97c5fba4.md): Hugging Face · 2026-10-22 · Hard · 18 min read · Model training, AI agents, Evaluation, LLMs
  Executable checks on terminal database state, originally built to grade agents in ThinkingBox-Bench, double as binary RL rewards for post-training tool-using agents.
- [Introducing ⚔️ AI vs. AI ⚔️ a deep reinforcement learning multi-agents competition system](https://swe.quest/articles/introducing-ai-vs-ai-a-deep-reinforcement-learning-multi-agents-competition-da84df97b66c307d.md): Hugging Face · 2023-02-07 · Medium · 6 min read · Evaluation, Machine learning, Model training
  AI vs. AI is an open-source system hosted on Hugging Face Spaces that ranks multi-agent reinforcement learning models by having them play each other continuously and computing ELO ratings from the results.
- [AutoSynthData: Generating Training Data for Enterprise Agents](https://swe.quest/articles/autosynthdata-generating-training-data-for-enterprise-agents-603dba56ad3916e2.md): Hugging Face · 2026-10-02 · Hard · 10 min read · Model training, AI agents, Evaluation, LLMs
  AutoSynthData is ServiceNow's pipeline for generating synthetic agentic training tasks, each a system specification, user prompt and verifier, targeted at a model's capability gaps.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
