the.ai

Systems / Distributed

verified

Expert Parallelism

A mixture-of-experts model holds more parameters than one accelerator can, so the experts are spread across devices. Each token then has to travel to whichever device owns the expert that was chosen for it, and come back. The routing decision stops being arithmetic and becomes network traffic.

Viz primitive · router-dispatchexperts = 8 · devices = 4 · capacity-factor = 1.25

6 tokens routed across 8 experts, sharded across 4 devices. Each token wakes its top 2. Experts 1, 8 stay asleep. 2 assignments were dropped where an expert exceeded its capacity of 2.

6 tokens routed across 8 experts, sharded across 4 devices. Each token wakes its top 2. Experts 1, 8 stay asleep. 2 assignments were dropped where an expert exceeded its capacity of 2.

Tokens dispatched across four devices, with dropped tokens marked where an expert exceeds capacity. Drag the capacity factor to trade wasted memory against dropped tokens.

Same primitive, engineer depth: how full each expert runs. An expert pinned at capacity is dropping tokens; one far below it is memory bought and not used. Drag the capacity factor to move every bar at once.

Dashed = dropped, expert at capacity (2)

Bar = share of each expert's capacity used

1.25

Reviewed by opendroid · 2026-08-04

  • arXiv:2006.16668 — GShard: Scaling Giant Models with Conditional Computation and Automatic Sharding
  • arXiv:2101.03961 — Switch Transformers: Scaling to Trillion Parameter Models with Simple and Efficient Sparsity