Sparse MoE Multimodal Model Architecture Deep Dive: Trillion-Parameter Scale and 1M-Token Context
This article takes a close look at a sparse Mixture-of-Experts (MoE) multimodal large model with roughly 2.8 trillion total parameters and about 104 billion activation parameters, and explains the architecture behind both its trillion-parameter scale and its 1M-token context window. Instead of reciting a spec sheet, it works through four questions: how capability and cost shift as MoE sparsity changes; how the context window is expanded from 8K to 1M through staged training; how hybrid attention (lower-bounded-decay linear attention, gated latent attention, and block-level attention residuals) combined with sparse routing balances efficiency and stability on very long sequences; and how developers should evaluate, select, and deploy such models. It also covers training-stability techniques such as quantile balancing, Stable Latent MoE, and SiTU-GLU, along with million-token Agentic RL post-training, and closes with practical guidance on measuring effective context and controlling deployment cost.
1. Introduction: How to Think About “Trillion Parameters” and “Million Context”
In July 2026, a team released a general-purpose MoE multimodal model aimed at everyday users. It supports long-text input with file understanding, content writing, and data analysis, and is available through multiple access methods. According to the release materials, the model has roughly 2.8 trillion total parameters and about 104 billion activation parameters. Its attention module combines linear attention with latent attention and introduces cross-layer block-level attention residuals. The MoE part uses a sparse architecture with 896 routed experts, paired with a quantile-based dynamic load-balancing strategy. Training expands context in stages (8K → 64K → 256K → 1M) and layers on million-token-level Agentic RL post-training.
Parameter count, context length, and leaderboard scores are the three metrics most commonly used to measure foundation models today. But “more parameters” does not mean “more capability,” and “supports 1M” does not mean “can fully use 1M.” Rather than reciting the spec sheet, this article addresses four questions:
- How capability and cost change as sparsity varies;
- How the context window expands from 8K to 1M;
- How hybrid attention and sparse MoE balance efficiency and stability on very long sequences;
- How developers should evaluate, select, and deploy such models.
2. The “Scissors Gap” Between Parameters and Activation: The Capability–Cost Tradeoff of Sparse MoE
2.1 First, Three Easily Confused Metrics
- Total parameters: determine the model’s knowledge capacity and representational ceiling.
- Activation parameters: the number of parameters actually involved in the forward pass for each token, which directly determines per-token inference compute.
- Training compute: tied to total parameters and data volume. Following the widely used Chinchilla scaling rule of thumb, training an effectively sized model needs on the order of “about 6 × parameters × tokens” floating-point operations. The larger the total parameters, the more compute a single full training run requires.
2.2 The Essence of Sparsification: Trading Activation Sparsity for Parameter Capacity
In a dense model, total parameters equal activation parameters, so scaling capacity necessarily brings a proportional cost increase. MoE splits the feed-forward layers into multiple “experts” and routes each token to only a few of them, decoupling the two quantities.
- Benefit: total parameters can scale to the trillion level to carry knowledge, patterns, and cross-modal representations, while per-token cost stays at the hundreds-of-billions level.
- Cost: whether that capacity is fully used depends on routing quality; whether training stays stable depends on load balancing; parallel efficiency depends on how communication is organized.
For this model, the total-to-active ratio is about 27:1, meaning a single forward pass touches only about 3.7% of the parameters. This also shows that estimating inference cost from total parameters severely overstates the real overhead.
2.3 Sparsity Is Not “Better When Sparser”
The lower the activation ratio, the cheaper each token, but the greater the engineering pressure:
- Each token sees less information and relies more heavily on the quality of routing decisions;
- As expert granularity gets finer, the arithmetic intensity per computation drops. The “large experts” introduced to reduce communication often push fine-grained routing back toward dense computation, which raises cost instead;
- The more experts there are, the more prone the load is to long tails, and the more likely parallel devices sit idle.
Beyond that, the same set of parameters can be turned—via quantization, distillation, or pruning—into multiple versions targeting different latency and cost constraints. So “how many total parameters” is only the starting point for understanding capability; it is not equivalent to deployment cost.
3. Context from 8K to 1M: Long Context Is Not “Trained in One Shot”
3.1 Progressive Window Expansion: Why Not Train 1M Directly at 8K
Full-attention compute grows quadratically with sequence length. If you start with a million-token context, the vast majority of samples end on short sequences, and almost all of the attention computation lands on padding positions—wasting compute while diluting the learning signal for long-range dependencies. The mainstream approach is to “learn language and reasoning first, then long-range associations.” Two common paths:
- Keep a shorter window for the bulk of pretraining, then progressively widen it;
- Train uniformly at a long window throughout, using document-level packing and cross-document attention masking.
Each has tradeoffs: the former costs less to train and spends less time learning long-range dependencies; the latter requires fewer stage switches but needs careful sample organization to keep efficiency high.
3.2 The Progressive Logic of Multi-Stage Expansion
This model’s training proceeds in four stages:
| Stage | Context length | Training goal |
|---|---|---|
| One | 8K | Solidify language modeling and basic reasoning; establish stable lexical and syntactic representations |
| Two | 64K | Introduce document-level and code-repository-level long samples; learn cross-paragraph coreference and structural dependencies |
| Three | 256K | Strengthen long-range understanding for books, long reports, and multi-turn dialogues; begin to accept a decline in effective context |
| Four | 1M | Align with product-level ultra-long input scenarios; balance efficiency and position generalization |
Table: Training goals for multi-stage context expansion
The point of stage progression: the short-window stages accumulate solid “local language priors,” so when the window widens, the model only has to link those priors to farther distances, which significantly lowers the learning difficulty. Meanwhile, as the window grows, compute, memory, and communication pressure rise stage by stage, allowing parallel and sequence-splitting strategies to be tuned at each stage and avoiding the training instability that a one-shot switch would cause.
3.3 Position Encoding: Relative Decay and No Position Encoding
The hard part of widening the window is position extrapolation. Common position encodings rely on rotary frequencies; beyond the training length, the rotary phases enter ranges the model has never seen, and the attention distribution easily becomes distorted. Mitigations include position interpolation, frequency scaling, and YaRN-style methods.
One common approach in linear attention is to remove explicit position encoding entirely (NoPE) and rely on the causal mask and a decay mechanism to express order. Under a design where “decay strength is bound to distance and the decay parameter is lower-bounded” (see 4.2), attention weights naturally decay with relative distance, so the model can extrapolate in length without changing any position parameters.
3.4 Post-Training: From “Can Read Long” to “Can Use Long”
Pretraining gives the model a passive “long-range retrieval” ability; Agentic RL post-training addresses “actively using long context”—planning across many tool calls, locating key information in a long history, editing files in a huge codebase. This stage runs at the million-token level, matching the typical input scale of long-range tasks: multi-turn dialogues, tool-call logs, code repositories, long documents, and audio/video transcripts, stacked together, easily reach hundreds of thousands to a million tokens.
3.5 How to Spot an “Inflated” Long Context
The following signs indicate that a model’s supported length may exceed its effective length:
- Strong performance when key information is at the beginning or end, but a sharp drop when it sits in the middle (the classic “lost in the middle”);
- Instruction-following weakens as the input grows, with output showing repetition, omission, or off-topic answers;
- Generation length gets compressed under long context, and long-form writing breaks off mid-way;
- In needle-in-a-haystack tests, hit rate drops noticeably as the number of needles increases.
So an advertised context length should be treated as the “acceptable range,” not the “reliable range.”
4. Attention Architecture: Combining Linear, Latent, and Residual
4.1 Two Bottlenecks of Full Attention
Standard self-attention has two hard constraints:
- Compute: for a sequence of length L, the attention matrix scales as O(L²). At a 1M context, the attention scores for a single head in a single layer reach on the order of 10¹²; even with FlashAttention-style chunking to avoid materializing the matrix explicitly, the compute cost cannot be avoided.
- Memory: in autoregressive decoding, the KV Cache grows linearly with length. The actual capacity is often determined by cache size rather than by the weights, which caps concurrency.
So the core challenge of a million-token context is not “support longer” but “stay efficient at longer.”
4.2 Lower-Bounded Decay Parameterization: Letting Linear Attention Saturate Tensor Cores
Linear attention compresses history state recursively. Each step’s update takes the form:
S_t = λ_t · S_{t-1} + k_t v_tᵀ, with output o_t = q_tᵀ S_t, where λ_t ∈ (0,1] is the decay factor.
Engineering implementations typically use chunked parallelism: compute directly within a block via matrix multiplication, and pass the compressed state between blocks—balancing parallelism with linear complexity. The problem is how the decay term’s value is chosen.
- If
λ_t = exp(g_t)andg_tcomes from an unbounded Negative-Softplus-style function, theng_tcan be arbitrarily negative. - To offset the decay accumulated within a block, the implementation needs its reciprocal. In low precision such as BF16,
exp(-g_t)quickly overflows to infinity or underflows to zero. - To keep things numerically stable, the diagonal block (the causal-attention portion within a sequence block) is forced onto a per-position-pair special path and cannot use dense matrix multiplication.
- On a GPU, this means the diagonal block struggles to use the high-throughput matrix multiplication of the Tensor Core—and Tensor Cores are precisely the main source of deep-learning compute today.
KDA (incremental attention with lower-bounded decay) offers a clean fix: replace the log decay with a Scaled Sigmoid that has a fixed lower bound:
g_t = g_min · σ(W_g x_t), where g_min is −5.
Because σ(·) ∈ (0,1), g_t is locked to the interval (−5, 0). This brings three changes:
- The reciprocal of the decay accumulated over any length is bounded, eliminating the overflow/underflow problem at low precision;
- The diagonal and non-diagonal blocks use the same dense matrix-multiplication path, greatly simplifying the operator implementation;
- With the decay step constrained by a lower bound, a single token’s influence on the history state does not decay infinitely, so combined with NoPE the model can extrapolate directly to 1M length.
Illustrative code (schematic pseudocode):
# Linear attention single-step update (pseudocode)# Goal: let both the diagonal-block and cross-block paths use dense GEMMGAMMA_MIN = -5.0 # lower bound on the log decay, a fixed hyperparameterdef log_decay(x, W_g):# Scaled Sigmoid: maps unbounded negative values into (GAMMA_MIN, 0)# At any precision, the reciprocal of the accumulated decay exp(-sum(g)) stays boundedreturn GAMMA_MIN * sigmoid(W_g @ x)def linear_attn_chunk(Q, K, V, S_prev, g):# 1) Intra-block: compute the score matrix once; diagonal/off-diagonal share GEMM# A[i, j] = (q_i · k_j) * exp(cumsum(g)[i] - cumsum(g)[j])A = tril((Q @ K.T) * exp(cumsum(g)[:, None] - cumsum(g)[None, :]))O_intra = (A @ V)# 2) Inter-block: add the decayed history state to the intra-block contributionlam = exp(cumsum(g)[-1]) # total decay of this block, bounded thanks to g_minS_new = lam * S_prev + K.T @ V # update the compressed stateO_inter = Q @ S_prev * exp(cumsum(g)[:, None])return O_intra + O_inter, S_new
4.3 Gated MLA: Latent Attention with Gating
Multi-head Latent Attention (MLA) compresses each head’s keys and values into a low-rank latent vector, so at inference time only the latent vectors need to be cached rather than the full key-value pairs—shrinking the KV Cache. Its limitation is that the compressed representation has limited capacity and may lose detail during information retrieval in ultra-long contexts.
Adding gating (Gated MLA) lets each head weight between “reading the latent representation” and “reading the raw / high-precision key-values,” and even configure different gating strategies per layer. This effectively provides a tunable knob between memory footprint and retrieval precision, easing the compression-versus-retrieval tradeoff.
4.4 Block AttnRes: Block-Level Residuals to Break the Depth Bottleneck
A common phenomenon in deep Transformers: as layers increase, the fine-grained features of shallow layers get diluted layer by layer, and the model struggles to keep using early local information in deeper layers. Attention Residual (AttnRes) injects the outputs of early layers into deeper layers as residuals—effectively a cross-layer “information highway.”
Block AttnRes operates at “block” granularity rather than passing information layer by layer, preserving the sharing effect while significantly reducing extra memory and cross-device communication. At a 1M context, storing intermediate activations layer by layer is a cost that cannot be ignored, so a block-level design becomes a pragmatic choice for large-scale training.
4.5 The Combined Logic of the Three
The three designs are not independent—they work together:
- KDA handles “efficiency and stability”: letting linear attention saturate Tensor Cores even at low precision;
- Gated MLA handles “the precision–cost balance”: compressing the cache with latent representations while retaining retrieval ability through gating;
- Block AttnRes handles “depth and information flow”: keeping shallow-layer information usable in deeper layers.
Linear attention supplies a globally cheap “coarse-grained memory,” latent attention supplies “compressed global retrieval,” and block-level residuals supply “cross-layer fine-grained information”—together forming an approximate full coverage of ultra-long context.
5. Training Stability for Ultra-Large-Scale MoE: From Auxiliary Loss to Quantile Balancing
5.1 Routing Imbalance Brought by Scale
When the number of routed experts reaches around 896, the question is no longer “can it train” but “can it train stably and in balance.” Typical MoE training failures include:
- Routing collapse: a few experts receive the vast majority of tokens while the rest go long stretches without gradient updates;
- Load long tail: under expert parallelism (EP), the most heavily loaded device sets the synchronization time for the whole batch;
- Precision drift: low-precision rounding errors accumulate across layers during long-sequence training.
5.2 The Tradeoffs of Auxiliary Loss and Quantile Balancing (QB)
The conventional approach adds a load-balancing loss (an auxiliary loss) on top of the main loss to penalize uneven distribution. The problem: the auxiliary loss competes with the language-modeling objective for gradients, and with enough capacity it can even interfere with convergence of the main task.
The idea behind Quantile Balancing is to avoid an extra loss term entirely, and instead compute capacity thresholds dynamically from the current batch’s per-expert load distribution. Tokens below the threshold route normally, while tokens above it are downgraded to shared experts or handled through residual connections.
# Quantile-based dynamic load balancing (pseudocode)load = count_tokens_per_expert() # per-expert load in the current batchcap = quantile(load, 0.9) # use the load quantile as the capacitymask = load <= cap # experts below the quantile participate normally# tokens exceeding the quantile switch to the shared-expert/residual path,# with no auxiliary loss introduced
Its advantages:
- It introduces no gradient that competes with the main objective, keeping the training objective pure;
- The threshold changes dynamically with training, naturally adapting to different data distributions and training stages;
- It is simple to implement and easy to integrate with existing MoE kernels.
5.3 Stable Latent MoE: A Structured Design for Stability and Efficiency
Beyond the routed experts, a sparse MoE typically also includes a few always-active shared experts that carry general capability, while the routed experts handle specialization. This model uses a “stable latent expert” structure, emphasizing:
- Latent compression inside each expert, lowering per-expert compute and memory overhead;
- A combination of gating and shared experts that ensures a stable “general-purpose base” even under extreme sparsity;
- Pairing with the SiTU-GLU activation to ease gradient-scale issues in deep networks.
5.4 Activation Function: The Role of SiTU-GLU
GLU-style activations (such as SwiGLU and GeGLU) boost expressiveness through gated multiplication and are the standard configuration for today’s feed-forward layers. SiTU-GLU adds a smooth, bounded nonlinear transform on top, making the range of the gating signal more controllable, thereby reducing the chance of activation explosion or vanishing in deep networks and improving numerical stability under low-precision training.
At the trillion-parameter, thousand-expert scale, the numerical properties of the activation function get amplified repeatedly across layers and experts, and their impact far exceeds what intuition suggests at the same scale.
6. Agentic RL: What Million-Token-Level Post-Training Solves
Pretraining lets the model “read long”; post-training lets it “use it correctly.” The key difference of Agentic RL lies in where the training signal comes from:
- Traditional SFT relies on human-annotated demonstration data—high cost, narrow coverage;
- RL lets the model perform multi-step tasks in real or simulated environments and adjust its strategy based on the outcome feedback.
Under a million-token input, Agentic RL addresses three problems:
- Long-range credit assignment: a single trajectory may contain dozens of tool calls and hundreds of dialogue turns, with the cause of the final success or failure scattered across early steps;
- Context pollution: history is mixed with large amounts of irrelevant logs, so the model must learn “selective attention”;
- Action-space expansion: from pure text generation to tool calls, code execution, and file operations.
Common training methods include reinforcement learning with verifiable rewards (RLVR), rejection-sampling fine-tuning (RFT) combined with process reward models (PRM), and simulated-environment replay.
7. Beyond Benchmarks: What Else to Look At
Leaderboard scores reflect “average capability,” while engineering deployment cares about “stability in specific scenarios.” It helps to supplement evaluation along four dimensions:
- Effective context: design a test set on a two-dimensional grid of “key-information position × question type” and plot a hit-rate heatmap, rather than relying on a single needle test;
- Long-range consistency: have the model complete tasks in long documents that require cross-chapter references, to check whether it truly “remembers” rather than merely “read”;
- Instruction-following stability: insert conflicting instructions into a long context and observe whether the model still follows the system prompt;
- Tool calls and multi-step planning: use real task chains (retrieve → reason → execute → verify) as scripts, and measure end-to-end success rate and average number of steps.
In addition, the “total parameters / activation parameters” on a model card should be read together with deployment cost. With the same total parameters, a different activation ratio can make the inference unit price differ by several times.
8. Deployment Guidance: How Developers Should Use It
- Tier access by task: route long-document understanding and summarization to long-context capability, code and data analysis to structured-reasoning capability, and creative writing to a high-quality generation version;
- Control context cost: make good use of prefix caching (reuse the KV cache for the same system prompt and documents across turns), and for ultra-long inputs, segment and summarize first, then concatenate;
- Build observability: for long-context requests, log input length, first-token latency, throughput, and truncation rate; establish a baseline and monitor for drift;
- Maintain a regression test set: freeze real business samples into a regression set and run it after every model or prompt change, to avoid “silent degradation.”
9. Conclusion
The model’s roadmap can be summed up in three sentences:
- Sparsification: a param-to-activation ratio of about 27:1 that separates capacity from cost;
- Progressive window expansion: multi-stage training from 8K → 64K → 256K → 1M to “feed” the model its context capability;
- Hybrid attention + quantile balancing: using KDA, Gated MLA, Block AttnRes, and QB to strike an engineering balance among efficiency, precision, and training stability.
For developers, the most worthwhile focus is not the numbers on the spec sheet, but “how long the effective context really is, how stable instruction-following is under long context, and how low the per-token cost is.” The recommendation is to rely on your own regression set, run small-scale comparison tests around real tasks, and then decide your access strategy.
