From GQA to Gated Sparse Attention: Architecture Upgrades in a New Open-Source MoE LLM
This article explains the architecture changes in a newly released open-source MoE large language model preview. It covers the shift from Grouped-Query Attention (GQA) to gated sparse attention with IndexCache, how indexer results are reused across layers, and other design updates. These include shared experts, a 4-stream residual design, a larger multi-token prediction (MTP) draft module, and FP8 support. The article also offers practical advice for evaluating models like this one.
1. Background: An Architecture Iteration Worth Watching
A vendor recently released and open-sourced a preview of its next-generation large language model. Public information suggests the team made broad structural changes instead of simply scaling up parameters. The model reworks its backbone, attention mechanism, residual design, and inference acceleration. For developers who follow LLM technology, this is a clear example of how the “long context + agent” direction is being put into practice.
First, here are the overall parameter changes:
Table 1: Key parameter changes between the previous and new generations
| Dimension | Previous generation | New generation | Change |
|---|---|---|---|
| Total backbone parameters | 295B | 770B | About 2.6x |
| Activated parameters per token | 21B | 49B | About 2.3x |
| Context length | 256K | 1M | 4x |
| Number of layers | 80 | 78 | Slightly reduced |
| Hidden size | 4096 | 6144 | 1.5x |
| Routed experts | 192 | 256 | +64 |
| Activated experts | Top-8 | Top-8 + 1 shared expert | Shared expert added |
| Attention mechanism | GQA | Gated sparse attention + IndexCache | Full redesign |
| Residual stream | Standard residual | 4-stream multi-information flow | Redesigned |
| MTP draft module | 3.8B | 10B (0.7B activated) | Substantially larger |
The table shows two clear trends. First, the model grows both its total MoE capacity and its activation density. This suggests the team believes the inference compute budget can support more activated parameters, which in turn gives stronger single-step reasoning. Second, the context length jumps to 1M tokens in one step. This points to scenarios such as long-document processing and multi-turn agent tasks.
2. Attention Mechanism: From GQA to Gated Sparse Attention
The previous generation used Grouped-Query Attention (GQA), a common approach. GQA shares key and value heads to reduce KV cache memory use, and it has been widely validated in recent years. The new generation switches to a gated sparse attention architecture, paired with IndexCache. This matches the main evolution direction of leading models.
The core workflow has two steps:
- Relevant token selection: A lightweight indexer scores the very long historical context and identifies which tokens are most relevant to the current query.
- Sparse exact computation: The main attention module computes full attention only over the selected positions, about 2,048 of them. It skips all other positions.
Mathematically, this design is equivalent to using cheap retrieval to narrow the candidate set, then running exact attention over those candidates. It resembles the two-stage recall-and-rerank approach in information retrieval. With a 1M-token context, computing attention between each query and every historical token would be unacceptably expensive. With sparsification, the compute cost depends on the number of selected tokens instead of the total context length. This decoupling is the key to long-context inference.
3. Layered Reuse of the Indexer
A notable engineering detail is that all 78 layers use sparse attention, but not every layer runs a full indexer. According to public information, only about 21 layers run the full indexer. The other 57 layers reuse the token indices selected by earlier layers.
This design can be understood from two angles:
- Compute cost: Although the indexer is lightweight, running it independently in all 78 layers adds up. Reusing indices means most layers pay only the cost of a lookup.
- Semantic consistency: Adjacent layers usually agree closely on which tokens matter. Deeper features become more abstract step by step, but it is reasonable to assume the same set of positions stays stable across several layers. This approach carries a risk, though. If a shallow indexer selects the wrong key tokens, the error propagates through later layers with no chance to correct it. This is why inserting full indexers at intervals matters. It recalibrates the attention distribution at key layers.
For developers building their own long-context systems, this trade-off is useful. Computing exact indices in every layer is not necessary, and reusing them in every layer is not either. Sampling full indexers at fixed layer intervals offers a reasonable balance between cost and quality.
4. Other Notable Design Choices
Shared expert: In addition to the top-8 routed experts, the model always activates one shared expert. The shared expert carries general knowledge that applies across tasks and domains. This lets routed experts focus on domain-specific features, which can improve expert specialization and reduce routing oscillation.
Multi-stream residual: The standard single-channel residual connection expands into four parallel information streams. Features at different depths can travel through different streams, which helps ease gradient and information decay in deep networks. This design is increasingly common in very deep models with more than 70 layers.
Larger MTP draft module: The multi-token prediction module grows from 3.8B to 10B parameters, with 0.7B activated per step. Combined with speculative decoding, it can significantly improve inference throughput. A natively trained draft module aligns more closely with the main model’s distribution, so its acceptance rate is usually higher than that of an external small-model draft.
Quantization support: In addition to BF16, the model adds official FP8 precision support. For deployment, this lowers memory use and raises compute efficiency. This matters especially for a model with 770B total parameters.
5. How to Evaluate Models Like This Rationally
Here are some practical suggestions for developers:
- Treat benchmarks as a rough reference. Public leaderboards vary in how much training data they contaminate, so simple score comparisons offer limited value. Build a private evaluation set from your own business data.
- Focus on task-specific metrics. For long-context models, test needle-in-a-haystack retrieval accuracy, multi-hop reasoning consistency, and factual retention in summaries of very long documents.
- Estimate costs carefully. Base API cost estimates on your actual token mix, including the input-to-output ratio and cache hit rate. Preview pricing may differ from the final release.
- Keep preview results in perspective. Preview versions usually still have room for tuning, so keep tracking the final release.
Overall, this release shows a typical technical combination for the “long context + agent” direction: sparse attention, IndexCache, shared experts, and native speculative decoding. Regardless of how this specific model performs, its architectural approach is worth studying and learning from.
