Home / Swarm Intelligence

Swarm Intelligence

Many real operations are really thousands of small decisions made at the same time: when each battery charges, where each drone flies, which room each attendant cleans next. I built one engine that lets every one of those decision-makers think for itself while working toward a shared goal, so the whole group behaves like a well-coordinated team. It is the same idea as a flock of birds or a colony of ants.

Explore by domain

The same engine, applied to three different problems. Each page explains the problem, shows the results and compares the swarm with what people do today.

Hospitality

Hotel operations

Five hotels: cutting peak-hour electricity charges, getting rooms ready for arriving guests, keeping overbooked guests in the group, and filling open shifts.

$279kenergy saving / yr
$14.8kbetter per oversold night
4 problemsLearned + market swarms

Energy

Grid batteries

Ten grid-scale batteries on a real Texas grid zone, working together to flatten demand peaks on three months of data they had never seen.

949 MWpeak cut
0 MWby the best simple rule
Real grid dataLearned swarm

Emergency response

Wildfire drones

Six drones dropping retardant to contain fires they have never seen before, with a replay you can watch step by step.

87%forest saved
33%with no drones
SimulationLearned swarm
More domains coming

How it works

One shared "brain", many independent members.

1 · Each member looks only at what it can see Battery 1: charge level, demand Drone 4: fire nearby, fuel Attendant 2: rooms close by … 10, 100 or 1,000 members 2 · One shared model the same small network runs for every member 3 · Each one acts Battery 1: discharge Drone 4: drop retardant Attendant 2: clean room 714 4 · One team score peak cut, forest saved, guest minutes waited 5 · The team score teaches the shared model what worked

No central bottleneck

Each member decides from its own local view, so the system keeps working when there are thousands of members, or when one drops out.

One model, any size

Every member uses the same model. A battery swarm trained with 10 batteries ran unchanged with 100 and 1,000, and still delivered the same 949 MW peak cut.

Team goal, not selfish goals

Members are rewarded for the team result (a flatter grid, less forest burned, fewer guests waiting), so they learn to cover for each other.

Honest testing

Every result is measured on data or scenarios kept aside while building, and compared with today's practice and the best simple rule. Where the swarm loses, the pages say so.

Two kinds of swarm

Learned swarm

Members learn by trial and error in a simulator (multi-agent reinforcement learning). They can also start by copying a good human rule and then improve on it. This is used for batteries, drones, hotel equipment and room attendants.

Market swarm

Members bid for tasks or resources based on what they are worth to the team, like a quick internal auction. The best combination of bids wins. This is used when a fair price can be worked out directly: walked hotel guests bidding for sister-hotel rooms, and staff bidding for open shifts.

Under the hood

  • Python and PyTorch, with one engine shared by all domains, each added as a small plug-in.
  • Shared-parameter Q-networks with team-reward mixing (VDN and QMIX-style), Double DQN, n-step returns and action masks for hard rules.
  • Optional attention-based messages between nearby members.
  • Learning from demonstrations: pre-training on a rule's moves before reinforcement learning.
  • Auction and contract-net markets, checked against exact optimisation (integer programming).
  • Batched across members and parallel simulators, so training cost barely grows with swarm size.

The engine's source code is private. These pages publish its results.

Scaling test: the same model at 10, 100 and 1,000 members

Each model was trained at its original size, then run unchanged with more members. The battery fleet keeps the same total power, split among more batteries. The forest grows so each drone covers the same area, but all drones still launch from one pad.

Domain10 members100 members1,000 membersWhat it shows
Grid batteries: peak cut949 MW949 MW949 MWIdentical result at every size. Choosing all 1,000 actions takes under 1 ms.
Wildfire drones: forest saved83%41%26%Drops with size, and the simple rule drops too (79%, 47%, 40%). One launch pad can't serve a huge forest, so the next step is several pads.