Architecture Evolution and Engineering Practices of Ultra-Scale Open-Source LLMs

    This article breaks down the architecture and engineering practices behind ultra-scale open-source large language models, covering hybrid linear attention, attention residuals, sparse MoE routing, native multimodality, benchmark interpretation, inference infrastructure, and cost control. It offers developers a reusable methodology for building efficient, reliable, and cost-aware LLM services.

    1. Introduction: From a Parameter Race to an Efficiency Race

    Over the past few years, the main trajectory of large model development has been the simultaneous expansion of parameter count and data volume. However, once parameters reached the trillion scale, simply stacking more parameters began to yield rapidly diminishing marginal returns. What truly determines whether a model is usable has become three things: effective output per unit of compute, stable attention under long contexts, and controllable inference service costs.

    In July 2026, a research team released an open-source large model with roughly 2.8 trillion parameters and a context window of about 1 million tokens, and simultaneously made the weights, technical report, and several key infrastructure components public. This was not a single-point breakthrough, but rather the combination of three threads—architectural innovation + training method optimization + inference infrastructure—with an official overall scaling efficiency improvement of about 2.5x. This article strips away the specific product attributes and abstracts them into a reusable technical methodology.

    2. Core Architecture Breakdown: Hybrid Linear Attention and Attention Residuals

    2.1 Why Hybrid Linear Attention Is Needed

    The computational and memory overhead of standard self-attention grows quadratically with sequence length. A million-level context using pure attention would come at an unacceptable cost. The mainstream industry solution is linear attention: approximating attention as a recurrent state update, making the complexity approximately linear in sequence length.

    However, pure linear attention suffers from a “long-range memory decay” problem. The more mature approach today is therefore hybrid: most layers use linear attention to handle long-range information compression, while a small number of layers retain full attention for precise retrieval. A sketch is shown below:

    1. # Pseudocode: scheduling logic for hybrid attention layers
    2. def build_layers(num_layers, full_attn_every=4):
    3. layers = []
    4. for i in range(num_layers):
    5. if i % full_attn_every == 0:
    6. layers.append(FullAttentionLayer()) # precise retrieval
    7. else:
    8. layers.append(LinearAttentionLayer()) # long-range compression
    9. return layers

    The key engineering trade-off is the ratio: too few full-attention layers lose retrieval precision, while too many degrade back to quadratic complexity. In practice, the ratio is usually kept within a small range, and overhead is further reduced through chunking and state caching.

    2.2 Attention Residuals: Stabilizing Deep Stacking

    The most common problem in ultra-deep networks (hundreds of layers) at the trillion-parameter scale is drift in the scale of gradients and activations. The attention residual approach makes the residual path carry not only the previous layer’s output but also aggregated representations from multiple shallow layers, forming a smoother information pathway. Its value is reflected in two aspects:

    • Mitigating deep degradation, allowing stable training even with over a hundred stacked layers;
    • Improving information reuse in long contexts, reducing the dilution of critical details across layers.

    2.3 Sparse Experts: Sparse Activation of 16 out of 896

    A Mixture-of-Experts (MoE) design is adopted, with a total of about 896 experts and only 16 activated per inference pass. This means: total parameters determine knowledge capacity, while activated parameters determine the compute cost of a single pass. This decoupling is the prerequisite for a trillion-parameter model to still be served at an acceptable cost.

    Routing quality is the key to MoE success or failure. Common engineering techniques include load balancing loss, expert capacity factor limits, and routing jitter to avoid expert collapse. A sketch:

    1. # Pseudocode: sparse expert routing and load balancing
    2. logits = router(hidden_states) # [tokens, num_experts]
    3. weights, expert_ids = topk_softmax(logits, k=16)
    4. loss += load_balance_loss(expert_ids, num_experts=896)

    3. Native Multimodality and a Layered Capability Roadmap

    The model natively supports visual understanding, rather than “bolting a visual adapter onto a text model.” The benefit of native multimodality is that vision and text share the same representation space, making cross-modal alignment more natural. Its capability roadmap shows a clear layered rhythm: first solidify text and reasoning, then expand to multimodality. This rhythm is highly instructive for resource-constrained teams—first make the capability density of a single modality high, then expand horizontally, avoiding interference among training signals caused by optimizing multiple objectives simultaneously in the early stages.

    4. Evaluation Perspective: How to Rationally Interpret Benchmark Scores

    Public information shows that this class of models scores about 60 on a comprehensive intelligence index, and achieves 1679 and 1664 on frontend programming and full-stack development leaderboards respectively, ranking first. Developers should interpret this rationally:

    1. Leaderboards are a lower bound of capability, not an upper bound; real business performance depends on prompt engineering, tool calling, and context organization;
    2. High programming scores often come from “verifiable reward” training, strongly correlated with code correctness and executability, and migrating to unstructured tasks requires re-evaluation;
    3. Evaluation should return to your own datasets and establish a three-dimensional metric of “task success rate / first-token latency / cost per thousand calls.”

    5. Engineering Implementation: Inference, Compute, and Cost Governance

    5.1 Balancing Memory and Throughput

    A trillion-parameter model cannot be hosted on a single machine and must rely on a combination of tensor parallelism, pipeline parallelism, and expert parallelism. Key infrastructure typically includes three types of capabilities:

    • Expert parallelism communication library: solving the all-to-all communication bottleneck of MoE;
    • Efficient linear attention operators: fusing state updates with chunked computation to reduce memory access;
    • Agent runtime environment: providing isolation and reproducible environments for tool calling and sandbox execution.

    5.2 Cost Control

    The public pricing is about $3 per million input tokens (cache miss) and about $15 per million output tokens. General cost optimization techniques include:

    • Prefix caching and result caching to improve hit rates;
    • Context compression and retrieval-based context injection to reduce ineffective tokens;
    • Task-tiered routing, where simple requests go to small models.
    1. # Pseudocode: tiered routing for cost reduction
    2. def route(request):
    3. if request.complexity == "low":
    4. return small_model(request)
    5. return large_model(request)

    5.3 Compute Elasticity and Rate Limiting

    Pausing new user subscriptions after launch because request volume far exceeded expectations is a typical demand-side shock. The mature approach is to build quota, queuing, degradation, and multi-availability-zone elastic scaling mechanisms in advance, and to locate hotspots through monitoring alerts and logging services.

    6. Ecosystem Adaptation and Accessibility

    Open-sourcing the weights and technical report, together with the simultaneous release of key infrastructure, alongside the launch of API calling services on a national-level computing platform and the completion of adaptation on domestic accelerator cards, collectively lowers the barrier to use. The takeaway for enterprises is: model selection should incorporate “portability” into the evaluation, including hardware backend abstraction, inference framework compatibility, and the feasibility of private deployment.

    7. Conclusion

    The competitive focus of ultra-scale open-source models has shifted from parameters to architectural efficiency and engineering completeness. Hybrid linear attention solves the cost of long contexts, attention residuals stabilize deep training, sparse experts decouple capacity from compute, native multimodality and a layered roadmap control complexity, and inference infrastructure and cost governance determine ultimate usability. For developers, what is most worth borrowing is not any specific number, but this methodology of collaborative optimization across “architecture—training—inference.” If an enterprise wants to implement similar capabilities on Baidu AI Cloud, it can combine general cloud product capabilities such as container platforms, object storage, and monitoring alerts to build an elastic, observable, and cost-controllable large model service pipeline.