Trillion-Parameter MoE Model Architecture Explained and Local Deployment

    \nA trillion-parameter Mixture of Experts (MoE) model behaves very differently from a dense model of the same size: it stores a massive number of parameters but activates only a fraction of them per token. Using a recently open-sourced 2.8-trillion-parameter model as a case study—2.8T total parameters, 104B activated per token, 1.56TB of weights, 93 layers, and 896 experts—this article unpacks why such models are hard to deploy locally. It explains sparse activation, expert routing with shared experts, the real cost of the KV cache under long context, a step-by-step VRAM calculation showing why at least eight high-memory accelerators are required, and practical strategies covering quantization, parallelism, and long-context optimization.\n\n

    \n\nIn recent years, large model parameter counts have climbed from hundreds of billions toward the trillions—and the barrier to deploying them locally has risen just as sharply. Take a recently open-sourced trillion-scale Mixture of Experts (MoE) model as an example: it has about 2.8 trillion total parameters, roughly 1.56TB of weights, and the official guidance for running it locally calls for at least eight high-memory accelerator cards. These numbers alone make the point: model capability and engineering cost are entering a new tug-of-war. Rather than focusing on any specific product, this article treats such a model as a representative case and works through it layer by layer—from architecture principles and parameter composition to VRAM estimation and deployment practice—to answer one question: what exactly makes a trillion-parameter model so hard to run?

    MoE Sparse Architecture: The Premise for “More Parameters, Fewer Activations”

    To understand the relationship between 2.8T and 104B, you first have to grasp the core idea of MoE—sparse activation.

    In a traditional dense model, every token passes through all parameters during each forward pass. More parameters means more computation; the two are linearly bound. MoE breaks that binding. It splits the model’s main structure into a large number of parallel “expert” subnetworks, then introduces a gating network (Router/Gate) that dynamically selects a few experts for each token to compute.

    This leads to two key facts:

    • Storage: All expert parameters must stay resident in memory or VRAM—none can be left out—because any of them could be routed to at any time.
    • Computation: A single token passes through only the few selected experts, so the parameters actually used in the math are far fewer than the total.

    This “store everything, compute sparsely” property lets a model push its total parameter count to the trillions without a proportional increase in per-token compute. It is also why a 2.8T model activates only about 104B parameters per token—an activation rate of roughly 3.7%.

    How 2.8T Total and 104B Activated Parameters Add Up

    Putting the key numbers side by side makes the composition clear:

    • Total parameters: ~2.8 trillion (2.8T)
    • Activated parameters per token: ~104B
    • Activation ratio: 104B ÷ 2800B ≈ 3.7%
    • Layers: 93
    • Total experts: 896
    • Experts selected per token: 16 (plus 2 always-on shared experts)
    • Context length: ~100K

    Start with what the activation ratio means mathematically. The 104B activated per token comes almost entirely from the shared experts, the attention layers, and the 16 experts selected in each MoE layer. Since more than 90% of the parameters sit “dormant” during any single pass, the model’s actual FLOPs do not scale with 2.8T—they are closer to those of a dense model in the tens-of-billions range. This is MoE’s biggest selling point on inference cost-effectiveness.

    The storage ledger tells a completely different story. Whether it is the 16 selected experts or the 880 that were not selected, their weights must all genuinely exist in VRAM. Gating decisions happen at runtime; you cannot predict which experts the next token will hit, so you cannot trim anything at storage time. This shifts the conflict from “compute” to “VRAM capacity.”

    Expert Routing: Choosing 16 from 896, with Shared Experts

    The combination of 896 experts and 16 selections per token deserves a closer look.

    A typical MoE layer’s routing logic can be summarized with the following pseudocode:

    1. def moe_forward(token_emb, experts, shared_experts, top_k=16):
    2. # 1. The gating network scores every expert
    3. logits = router(token_emb) # shape: [num_experts]
    4. scores = softmax(logits)
    5. # 2. Select the top_k highest-scoring experts
    6. topk_scores, topk_ids = topk(scores, k=top_k)
    7. # 3. Compute only over the selected experts (the key to sparse activation)
    8. out = 0
    9. for score, eid in zip(topk_scores, topk_ids):
    10. out += score * experts[eid](token_emb)
    11. # 4. Add the output of the always-on shared experts
    12. out += sum(shared(e)(token_emb) for e in shared_experts)
    13. return out

    Two design points are worth expanding on:

    First, the sparsity of 16/896. Each token uses only 16 of 896 experts—a sparsity of about 1.8%. High sparsity means a high degree of division of labor in routing: different experts tend to learn different knowledge domains or token patterns, so the model maintains a huge total capacity while keeping per-token compute lean.

    Second, the role of shared experts. The 2 always-on shared experts do not compete in routing; they are activated for every token. They typically carry cross-domain general knowledge and common representations, acting like a “common foundation,” while the 16 routed experts handle domain-specific, context-dependent content. This “shared + routed” combination preserves general capability while enabling fine-grained specialization—a common paradigm in recent MoE designs.

    Depth and Long Context: The Hidden Cost of 93 Layers and 100K

    The depth of 93 layers and the 100K context length further amplify deployment difficulty.

    The cost of depth. The more layers a model has, the more serial compute steps run per token; the activations, residual connections, and normalization intermediates that accumulate layer by layer all add to VRAM use and memory-access pressure. 93 layers is a fairly deep configuration, and it raises the bar for memory bandwidth and pipeline scheduling during inference.

    The cost of long context—the KV cache. The VRAM sink that is easiest to overlook is the KV cache. In autoregressive inference, to avoid recomputation, the model caches the Key and Value of past tokens. Cache size scales with “layers × attention heads × head dimension × sequence length.” When context stretches to around 100K, the KV cache’s VRAM footprint can rival the weights themselves—and under high concurrency it can even exceed them.

    A rough estimate: KV cache VRAM ≈ 2 (K and V) × layers × hidden dimension × sequence length × batch size × bytes per value. Plugging in 93 layers and a 100K sequence length, even with a moderate hidden dimension, the cache for a single sequence reaches tens of gigabytes. This is why “the weights fit” does not mean “it runs”—the weights are only the first line of the VRAM ledger.

    Weight Size and VRAM Math: Why You Need 8 GPUs to Start

    Now let’s do the VRAM math.

    First, weight storage. 1.56TB of weights spread across 8 cards means each card carries about 195GB. This is well beyond the VRAM of consumer-grade GPUs and requires high-spec accelerators with more than 100GB of VRAM per card, plus Tensor Parallelism to split each layer’s parameters across multiple cards for coordinated computation.

    One point worth noting is precision. 2.8T parameters at 1.56TB works out to roughly 0.56 bytes per parameter—about 4–5 bits—which suggests these weights are likely the product of 4-bit or mixed-precision quantization. Quantization significantly compresses size but also introduces precision loss, a trade-off to weigh during deployment.

    Second, the KV cache and activations. Beyond the weights, you must reserve space for the KV cache, runtime activations, and communication buffers. With 8 cards each holding 195GB of weights, the headroom left for the KV cache is already very tight. Turn on long context or high concurrency, and you can easily hit the VRAM ceiling.

    Third, inter-card communication. Tensor Parallelism splits a large matrix multiplication across multiple cards, and every layer needs cross-card AllReduce or AllGather synchronization. The interconnect bandwidth among the 8 cards—whether a high-speed proprietary link or a more general network—directly determines inference throughput. When bandwidth is insufficient, communication becomes the bottleneck and GPU compute sits idle waiting.

    Stack these three costs together, and 8 high-memory cards are basically the “passing grade” for this kind of trillion-scale model, not the “comfortable line.” Truly supporting long context and high concurrency in production typically requires more cards or more aggressive quantization.

    Engineering Challenges and Deployment Recommendations

    Overall, running a trillion-scale MoE model locally means systematically addressing the following challenges, along with corresponding recommendations:

    1. VRAM is the first hard constraint. Calculate the total of “weights + KV cache + activations + communication buffers” first, then work backward to how many cards you need and what VRAM spec—do not make decisions by looking at weight size alone.

    2. Quantization is the core lever for lowering the barrier. 4-bit or lower quantization can dramatically shrink weight size and is the key path to running large models on consumer hardware locally. But evaluate quantization’s actual impact on model quality and run A/B validation.

    3. The parallelism strategy sets the efficiency ceiling. The combination of Tensor Parallelism, Pipeline Parallelism, and Expert Parallelism directly affects multi-card utilization. MoE models especially need attention to load balancing under Expert Parallelism—if routing is heavily skewed, some cards idle while others overload, and throughput drops sharply.

    4. Optimize long context specifically. Consider general techniques such as KV cache quantization, chunked attention, and cache reuse to keep VRAM from being eaten up by historical caches.

    5. Fill local gaps with cloud compute. When a local 8-card setup is only “barely running,” organizations can use cloud GPU container services, elastic compute, and object storage to scale compute on demand and absorb peak loads smoothly—turning heavy-asset hardware purchases into elastic compute spend, which suits scenarios with large fluctuations and long validation cycles.

    Conclusion

    A trillion-scale MoE model with 2.8T total parameters, 104B activated per token, and 1.56TB of weights condenses all the typical features of today’s ultra-large models: trading sparse activation for parameter capacity, using shared + routed experts to divide up capability, using long context to boost task performance, and simultaneously raising the deployment barrier with enormous VRAM demands and multi-card coordination.

    Understanding “why there are so many parameters, why so few are activated, why VRAM is so tight, and why you cannot cut the number of cards” is the starting point for mastering this class of models. For developers, rather than being awed by the trillion-parameter scale, it is better to break it down into a clear VRAM ledger, compute ledger, and communication ledger—once the math is clear, the feasibility boundary and optimization room for local deployment become obvious.