Moonshot AI Open-Sources MoonEP: A Perfectly Balanced Expert Parallelism Library for MoE Training
Moonshot AI
Moonshot AI open-sourced MoonEP, an Expert Parallelism communication library for distributed Mixture-of-Experts workloads. MoonEP ensures every rank receives exactly S×K tokens regardless of router skew, using online-planned redundant experts. It is released under MIT license as part of Kimi K3 Open Day.
Moonshot AI has open-sourced MoonEP, an Expert Parallelism (EP) communication library for distributed Mixture-of-Experts (MoE) workloads, under MIT license. MoonEP was released as part of Kimi K3 Open Day alongside the K3 model weights, technical report, and other infrastructure codebases FlashKDA and AgentEnv. It addresses the problem of router imbalance in expert parallelism by enforcing a hard invariant that every rank receives exactly S×K tokens, achieved through online planning of redundant experts prefetched before computation. The design ensures perfect balance, online planning via a GPU kernel with negligible overhead, zero copy and static shapes eliminating per-layer host synchronization. Benchmarks against DeepEP v2 show MoonEP communication time stays flat as imbalance increases, while DeepEP degrades. Training requires B = E/R prefetch slots; inference can use B = 3–4 without correctness cost.
- Сокращения
- EP = Expert Parallelism
- MoE = Mixture of Experts
- MIT = Massachusetts Institute of Technology license
- GPU = Graphics Processing Unit
- NVLink = NVIDIA NVLink
- OOM = Out of Memory
- SM = Streaming Multiprocessor
Source: MarkTechPost —
original
