Training 2.8T-Parameter Open-Source MoE Models on Domestic AI Compute: Adaptation Practices

    This article examines the engineering work required to adapt a 2.8-trillion-parameter open-source MoE model for training on a domestic AI compute platform. It covers the memory wall, communication bottlenecks, and software-stack compatibility issues involved; explains how a native FSDP2 multimodal training path was built through shard-aware loading, hybrid parallelism, and overlapped gradient synchronization; and summarizes practical guidance for developers validating and scaling large-model training on new hardware.

    Training 2.8T-Parameter Open-Source MoE Models on Domestic AI Compute: Adaptation Practices

    1. Background: Why Adaptation for Ultra-Large Models Is a Key Engineering Problem

    A leading large-model team recently open-sourced its flagship model, with a total parameter scale of 2.8 trillion. It uses a typical ultra-large-scale mixture-of-experts (MoE) architecture. At the same time, a domestically developed AI training-and-inference accelerator and its accompanying software stack announced that training adaptation for this model had been completed, connecting the full path from model loading and sharding scheduling to gradient synchronization.

    Behind this progress is an industry-wide engineering question: once model scale reaches the trillion-parameter level, training adaptation is no longer a simple matter of “getting the script to run.” It becomes a systems engineering effort involving parallel strategies, memory management, communication efficiency, and software-stack compatibility.

    For developers and enterprise users, the value of this kind of adaptation work is clear. Model weights and training code released by the open-source community usually target the mainstream GPU ecosystem by default. To complete training on another compute platform, teams must address operator coverage, distributed communication library integration, memory fragmentation, and a range of other low-level issues. Understanding the methodology behind this process has more long-term value than focusing on any single product.

    2. Three Core Challenges in Trillion-Parameter Model Training

    2.1 The Memory Wall: Combined Pressure from Parameters, Gradients, and Optimizer States

    Take a 2.8-trillion-parameter model as an example. Even if the number of activated parameters is far smaller than the total parameter count, the data that must reside in memory during full training is still enormous. Using common industry estimation methods, mixed-precision training typically requires storing FP16/BF16 weights (2 bytes), gradients (2 bytes), and optimizer states such as momentum and variance (usually 8 bytes or more) for each parameter. That means roughly 12 to 16 bytes of memory overhead per parameter. Even if optimizer states are maintained only for activated parameters, the total still far exceeds the 100GB-class memory capacity of a single card. This makes sharded data parallelism necessary, splitting weights, gradients, and optimizer states across a large number of devices.

    2.2 Communication Bottlenecks: Finer Sharding Means More Frequent Synchronization

    Parameter sharding means that forward and backward computation require frequent AllGather operations to collect weights and ReduceScatter operations to reduce gradients. In clusters with thousands of cards, the efficiency of collective communication directly determines training throughput. One key part of adaptation work is enabling the communication library on the domestic compute platform to work efficiently with the sharding and scheduling logic of the training framework, so that communication does not become the limiting factor for scalability.

    2.3 Software-Stack Compatibility: The Hidden Cost of Operators and Graph Compilation

    Ultra-large models commonly rely on highly optimized compute primitives such as FlashAttention-like operators, MoE routing, and grouped GEMM. When migrating to a new platform, teams need to confirm whether the software stack provides equivalent implementations or fill gaps through graph compilation and operator fusion. This work often accounts for more than half of the total adaptation effort, and much of it is difficult to observe from the outside.

    3. Key Elements of Building a Native FSDP2 Training Path

    The core highlight of this adaptation is that it built a native multimodal training path based on FSDP2, the second generation of fully sharded data parallelism, rather than taking a compatibility-conversion shortcut. The engineering work can be broken down into three parts.

    3.1 Model Loading: Shard-Aware Initialization

    A trillion-parameter model cannot be fully loaded first and then split. The correct approach is to use lazy initialization with meta device initialization together with shard-aware weight loading: each card reads only the shard it is responsible for from the checkpoint and materializes it directly onto the target device. This step requires coordination between the framework and the storage system. Typically, object storage or a parallel file system carries terabyte-scale weight files, and random reads are enabled through a shard index.

    1. # Example: shard-aware weight loading logic
    2. def load_sharded_weights(model, checkpoint_index, device_mesh):
    3. for name, param in model.named_parameters():
    4. shard_spec = checkpoint_index.get_shard(name, device_mesh.rank)
    5. local_shard = read_tensor_slice(shard_spec) # Read only this shard
    6. param.data.copy_(local_shard.to(device_mesh.device))

    3.2 Sharding Scheduling: Coordination of Hybrid Parallel Strategies

    A single parallelism dimension cannot support trillion-parameter training. The common industry approach is to combine multiple parallel strategies:

    • Data parallel sharding (FSDP2): Use the DTensor abstraction to express parameter distribution across devices and achieve fine-grained overlap between communication and computation.
    • Expert parallelism (EP): For MoE architectures, distribute different experts across different device groups, and exchange routed tokens through AllToAll communication.
    • Pipeline and tensor parallelism: Further split within or between model layers to control per-card activation memory.

    Adaptation work must ensure at the software-stack level that these parallelism dimensions can be freely combined, and that the scheduler can automatically choose communication priorities based on device topology.

    3.3 Gradient Synchronization: Overlapping Communication and Computation

    The performance of gradient synchronization determines training scalability. Common optimization methods include grouping operations by bucket to execute ReduceScatter and overlap it with backward computation, deferring synchronization during gradient accumulation, and using RDMA networks for zero-copy cross-node transfer. On a domestic compute platform, this part depends on sufficient adaptation of the communication library to the underlying interconnect hardware. It is the heaviest technical component behind the phrase “connecting the complete training path.”

    4. Additional Engineering Considerations for Multimodal Training Pipelines

    Flagship models generally provide multimodal capabilities, which introduces additional complexity into training adaptation. Vision encoders and language models have very different compute characteristics, so they require separate parallel strategy configurations. Variable-length image tokens cause uneven load within a batch, requiring dynamic padding or sequence packing strategies. The preprocessing throughput of multimodal data must match training speed; otherwise, the data pipeline becomes a bottleneck. A complete adaptation solution should incorporate data loading, augmentation, and tokenization into a unified pipeline and support checkpoint resume to handle the hardware failures that are unavoidable in clusters with tens of thousands of cards.

    5. Practical Lessons for Developers

    Several broadly applicable lessons can be drawn from this adaptation case. First, validate the framework’s native sharding capabilities before relying on manually rewritten parallel code. Second, use a small proxy model to verify operator and communication correctness before scaling to the full model size. Third, establish an end-to-end acceptance metrics system that includes per-step latency, MFU (model FLOPs utilization), and convergence-curve alignment, rather than focusing only on whether training can start. Fourth, make good use of general cloud capabilities such as container platforms, monitoring and alerting, and logging services to build training infrastructure, so that engineering effort can remain focused on the model and parallel strategies themselves.

    6. Conclusion

    Training adaptation for trillion-parameter open-source models is essentially a comprehensive test of the maturity of a compute platform’s software stack. Connecting the full path from sharded loading to gradient synchronization shows that domestic AI infrastructure is now capable of taking on frontier ultra-large-model training workloads. As more open-source flagship models emerge, this kind of systematic adaptation methodology will become a core competency for large-model engineering teams.