A Deep Dive into Large-Scale MoE Model Architecture: 744B Total Parameters, 40B Active

    This article breaks down the architecture and engineering trade-offs of a new large-scale sparse MoE model with 744B total parameters and 40B active parameters. It explains how the model balances training stability, long-context efficiency, and inference cost through Multi-head Latent Attention (MLA), Muon Split optimizer granularity, Multi-Token Prediction, and DSA sparse attention, and offers practical guidance for capacity planning and deployment.

    1. Why It Matters: Open-Source Models Are Moving Up the Capability Curve

    The distribution of model capabilities has shifted noticeably over the past two years. Closed-source flagship models have long held the top spots, while open-weight models have been catching up at a faster pace. The latest third-party comprehensive evaluation results show that a new generation of large-scale sparse models crossed the 50-point threshold on a mainstream intelligence index for the first time, ranking first among open-source models. It also ranked first in the open-source camp in human-preference arenas (separate leaderboards for text and code), placing it in the same tier as leading closed-source flagships overseas.

    The key point is that benchmark scores are only the result. What is truly worth studying for developers is “what price was paid to achieve this score.” This article does not repeat the leaderboards. Instead, it focuses on architecture and engineering: how a sparse model with 744B total parameters and 40B active parameters makes trade-offs among training stability, long-text efficiency, and inference cost.

    2. Fundamentals: Parameter Scale, Activation Scale, and Data Mix

    The model uses a Mixture of Experts (MoE) architecture. The core idea of MoE is to decouple parameter capacity from per-pass computation: the model holds a large parameter pool, but each token is routed to only a few experts for computation. This allows the total parameter count to be very large while keeping the floating-point operations per token manageable.

    Key metrics are as follows:

    • 744B total parameters, 40B activated per token, 256 experts, 80 layers;
    • Compared with the previous generation (355B total parameters, 32B activated), total parameters doubled and activated parameters increased by about 25%;
    • The pre-training corpus grew from 23T tokens to 28.5T tokens, with about 27T used for pre-training and 1.5T for mid-training.

    There are two easily overlooked engineering implications. First, increasing activated parameters from 32B to 40B means higher computation per token, so inference cost and throughput planning must be recalculated rather than reusing the previous generation’s capacity model. Second, carving out 1.5T tokens for mid-training shows that data engineering has shifted from a one-shot feed to staged allocation: the pre-training stage pursues breadth and coverage of language and world knowledge, while the mid-training stage reinforces specific capability distributions such as code, math, and long text.

    3. Architecture Change 1: Splitting MLA and Optimizer Granularity

    The model uses Multi-head Latent Attention (MLA). Its idea is similar to existing low-rank KV compression schemes in the industry: project Key/Value into a low-dimensional latent space, and cache only this compressed representation during inference, significantly reducing the memory footprint of the KV Cache. For long-context scenarios, memory bandwidth often becomes a bottleneck earlier than compute, so the benefit of KV Cache compression is very direct.

    However, the team encountered a real problem during training: when using a Muon-type orthogonalized optimizer with MLA, convergence could not match the structurally simpler GQA-8 (grouped-query attention with 8 shared KV groups). The reason is not hard to understand: Muon’s update rule relies on orthogonalizing parameter matrices, but MLA’s projection matrices are not structurally “neat,” and processing them as a whole forces the update scales of different attention heads to be flattened.

    The final solution is described as Muon Split: change “orthogonalizing the whole projection matrix” to “orthogonalizing each attention head separately.” A sketch is shown below:

    1. # Pseudocode: whole-matrix orthogonalization vs. per-head split orthogonalization
    2. def muon_update(W, heads, split=False):
    3. if not split:
    4. return orthogonalize(W) # Process as a whole; scales are flattened
    5. W_h = W.reshape(heads, -1) # Split into a per-head view
    6. for h in range(heads):
    7. W_h[h] = orthogonalize(W_h[h]) # Orthogonalize each head independently
    8. return W_h.reshape_as(W)

    The general value of this change is that there is coupling between sparse attention/low-rank compression structures and modern optimizers. When migrating architectures, the optimizer granularity must be checked at the same time; otherwise, a “more memory-efficient structure” can easily be trained into “worse results.”

    4. Architecture Change 2: Multi-Token Prediction

    The second change is Multi-Token Prediction. Traditional autoregressive training predicts only the next token at each position, while multi-token prediction lets the model predict tokens at multiple future positions at the same position, increasing training signal density and improving sample efficiency.

    There are usually two engineering approaches: one is to add several lightweight prediction heads that share the backbone representation; the other is to stack a small number of prediction modules in the deeper layers to form cascaded prediction. A sketch of the structure:

    1. Input tokens → Backbone Transformer (80 layers)
    2. ↓
    3. ┌───────────┼───────────┐
    4. head-1 head-2 head-3
    5. t+1 t+2 t+3

    During inference, only the main prediction head can be kept, and the extra heads can be discarded at deployment; alternatively, they can be used for self-speculative decoding, verifying multiple candidate tokens in one forward pass to reduce decoding steps. Note that multi-token prediction increases training memory and implementation complexity, and is more sensitive to data quality: noisy labels are amplified across multiple prediction targets at the same time.

    5. Architecture Change 3: DSA Sparse Attention

    The third change is the DSA (sparse attention) mechanism. It solves a different problem from MLA: MLA compresses the “KV representation dimension of each token,” while sparse attention reduces the “number of tokens each token needs to attend to.” Only by combining the two can memory and computation be held down simultaneously under extremely long contexts.

    Common implementation paths for sparse attention include: a learnable routing/selection module that scores and takes the Top-K key tokens; a hybrid mode of a local window plus a small number of global anchor tokens; and coarse filtering at block granularity followed by fine computation. The core trade-off is that too small a K loses information and affects long-text retrieval tasks, while too large a K degenerates into full attention and loses the acceleration benefit. Therefore, such structures must be validated together with long-text evaluations (needle-in-a-haystack, multi-hop retrieval, long-document summarization).

    6. Practical Recommendations for Engineering Teams

    1. Estimate compute based on activated parameters rather than total parameters, and estimate memory based on the actual cache after KV compression.
    2. When migrating to a new attention structure, recheck the optimizer and parameter grouping granularity at the same time to avoid “better structure, worse results.”
    3. Design the data mix separately for the mid-training stage to specifically strengthen code, math, and long-text capabilities.
    4. If adopting multi-token prediction weights, first evaluate their actual speedup in speculative decoding before deciding whether to keep the extra prediction heads.
    5. On the deployment side, combine container platforms for elastic scaling, object storage for hosting models and data, and logging services and monitoring alerts to track first-token latency and throughput; Baidu AI Cloud can serve as a reference for infrastructure selection in these general capabilities.