MoE: you pay for the parameters you don’t use

Sparse experts cut the compute per token. They do not cut the memory, and the router has opinions about your batch.

A mixture-of-experts model looks like a bargain on the spec sheet: 8×7B, 47B total parameters, 13B active. The active number is the compute; the total is the memory. Those are two different budgets, and a serving plan that confuses them fails at exactly the wrong moment.

The block, with a fork

A standard transformer block has one feed-forward network per layer. An MoE block replaces it with a set of experts and a router. For each token, the router scores the experts and selects the top k — usually one or two. The token goes through those experts’ feed-forward networks, and their outputs are combined with the router weights. Attention stays shared; only the MLP is sparse.

Mixtral 8×7B is the example everyone knows: eight experts per layer, top-2 routing, roughly 47B total parameters and roughly 13B active per token. It is not “eight 7B models.” It is one model where each token uses a fraction of the feed-forward capacity. That is why it can be cheaper to run than a dense 47B model and more expensive than a dense 13B model at the same quality, depending on the comparison.

Sparse compute, dense memory

The router reduces the FLOPs per token, not the bytes. Every expert’s weights have to be available when a token routes to it. If the model has 47B parameters and you run it in fp16, you need room for 47B parameters, not 13B. On one GPU, that is the whole problem; across several, it is an expert-parallelism problem.

The serving mechanics are where MoE stops being free:

  • Expert parallelism. Experts can live on different GPUs, but tokens then need to travel to the right GPU and back. All-to-all communication becomes a first-class cost.
  • Load imbalance. A batch is not a uniform stream. If many tokens route to the same expert, that GPU becomes the bottleneck while others idle. Capacity factors and token dropping are trade-offs, not fixes.
  • Batch effects. A batch of one may touch only a few experts; a large batch touches more and amortizes the weights, but also creates more routing traffic. The optimal batch size is a property of the router, the parallelism, and the interconnect.
  • KV cache. Attention is shared, so the KV cache is not multiplied by the number of experts. The cache arithmetic from the KV cache note still applies; the weights are the MoE-specific memory problem.
  • Quantization. You can quantize all experts, but the memory saving is on the whole model, and the active compute still depends on which experts are selected.

Why anyone uses it

The pitch is capacity at a lower compute cost: more total parameters to store knowledge, with only a fraction used per token. If a dense model at the same active-parameter budget is weaker, an MoE can be a better quality-per-FLOP trade. It can also be easier to scale to a larger total parameter count without making every token pay for all of it.

The catch is that the quality-per-FLOP advantage is empirical, not automatic. Routing can specialize in useful ways or collapse onto a few experts; training needs a load-balancing objective; fine-tuning can shift the router and change which experts a task uses. The spec sheet does not tell you whether the routing is good.

What to check before choosing one

  • Total vs active parameters. Size memory from the total; size compute from the active count. Do not use one number for both.
  • Top-k and expert count. Top-2 with eight experts is a different serving profile from top-1 with sixty-four.
  • Parallelism plan. How many GPUs, what interconnect, and whether the all-to-all fits in the latency budget.
  • Batch and tail latency. Averages hide routing imbalance; measure p95 and p99.
  • Quality at your task. Compare against a dense model at the same active compute, not against a dense model at the same total parameters.

MoE is a real architectural win when memory is cheap and compute is the constraint. It is a trap when you read “13B active” and provision for 13B.1

  1. The router is trained, not fixed. A model that routes well in the lab can route differently after fine-tuning; evaluate the served model, not the base checkpoint. ↩