Training Trillion-Parameter LLMs on China-Made GPUs: Engineering Adaptation Practices
This article distinguishes inference adaptation from training adaptation for large models on domestic GPU platforms, then breaks down the engineering stack required to train a nearly 3-trillion-parameter MoE model. It covers operator coverage and numerical consistency, FSDP2 and expert parallelism, cross-node collective communication, toolchain delivery, a 400-step stability validation on two nodes with 16 AI accelerator cards, the path from “can train” to “train out of the box,” and practical recommendations for developers.
I. Training Adaptation vs. Inference Adaptation: Two Concepts Often Confused
In discussions about combining large models with domestic compute, “completing adaptation” is a frequently used phrase that is often misunderstood. In practice, adapting an advanced open-source large model involves at least two levels: inference adaptation and training adaptation. Their engineering difficulty, validation criteria, and industry implications are completely different.
The core goal of inference adaptation is to enable model weights to load correctly on the target hardware, perform forward computation, and produce reasonable outputs. It mainly involves operator coverage, precision alignment such as the numerical behavior of FP16/BF16/INT8, memory planning, and integration with inference frameworks. A common industry practice is to complete “Day 0” inference validation on the day a model is released: if it runs and the outputs do not diverge, it is considered successfully integrated. In their technical reports, some leading model teams present validation results across multiple hardware paths side by side. In most cases, this is compatibility validation at the inference-operator level, not proof that the base model’s pretraining compute came from those hardware platforms.
Training adaptation is entirely different. It requires the hardware platform to carry the full training pipeline: forward computation, backpropagation, gradient synchronization, optimizer state updates, checkpoint saving and recovery, and long-term numerical stability in multi-card and multi-node environments. A successful training adaptation means that every step—from model loading, parameter sharding, and communication scheduling to gradient reduction—has been tested in real training runs on the target chips. In other words, inference adaptation proves “it can run,” training adaptation proves “it can train,” and continuous stable operation for hundreds of steps is initial evidence that “it can train reliably.”
Understanding this distinction is critical for engineering teams: when evaluating whether a compute platform can support training their own models, they should not look only at inference demos. They should focus on the completeness of the training framework, the maturity of distributed parallelism, and the stability record of long-running training.
II. Breaking Down the Technical Stack for Trillion-Parameter Training Adaptation
Completing training adaptation for a flagship open-source model with nearly 3 trillion parameters is a system engineering effort spanning multiple technical layers. Taking the industry’s mainstream Mixture-of-Experts (MoE) architecture as an example, training adaptation usually requires the following key elements.
1. Operator Layer: Coverage and Numerical Consistency
MoE models introduce many sparse computation structures, such as gating routing, expert dispatch/combine, and grouped matrix multiplication. These operators are often not covered by default in general-purpose operator libraries. The first step in adaptation is to provide high-performance implementations of these specialized operators on the target hardware and ensure that their numerical behavior under BF16 mixed precision matches the reference implementation. A per-operator unit-test system is usually needed to compare whether output errors remain within acceptable thresholds.
2. Parallel Strategy Layer: Coordination of FSDP and Expert Parallelism
With trillions of parameters, single-card memory is far from sufficient to hold model states, so composite parallelism is necessary. The current mainstream approach is to build a native multimodal training path based on Fully Sharded Data Parallel (FSDP2): model parameters, gradients, and optimizer states are distributed across devices in shards and aggregated on demand during forward and backward passes. For MoE structures, expert parallelism (EP) must also be layered on top, assigning different experts to different device groups and completing token routing exchange through collective communication. In addition, tensor parallelism (TP), pipeline parallelism (PP), and sequence parallelism (SP) must be flexibly combined according to model structure and cluster topology. The core difficulty is that these parallel strategies must have native support in the target hardware’s software stack, rather than being emulated through inefficient fallback paths.
3. Communication Layer: Efficiency and Reliability of Cross-Node Collective Communication
In two-node and larger-scale training, collective communications such as gradient synchronization (AllReduce) and expert data exchange (AllToAll) become performance bottlenecks and frequent failure points. Adaptation work must ensure deep coordination between the communication library and the underlying interconnect hardware, and apply topology-aware optimization to communication operators. Common engineering techniques include communication-computation overlap, gradient bucketing, and communication compression.
4. Framework and Toolchain Layer: End-to-End Engineering
The real deliverable of training adaptation is not a single demo but a reusable engineering system. This includes model loading and weight format conversion tools, automated generation of training configurations, checkpoint resume and elastic fault tolerance mechanisms, real-time monitoring and alerting for loss and gradient norms, and performance profiling toolchains. Only when these elements are complete can a platform be considered capable of supporting the full path from “rapid inference deployment” to “stable full-pipeline training.”
III. Stability Validation: What 400 Consecutive Steps Without Anomaly Means
In the acceptance phase of training adaptation, a widely adopted practice is to complete a certain scale of consecutive optimizer updates on the target cluster while monitoring key numerical metrics throughout. For example, two nodes with 16 training-and-inference AI accelerator cards in total can be used for cross-node joint training, with all 16 training processes completing 400 consecutive optimizer updates while observing whether the loss curve and gradient norm remain finite throughout—that is, no NaN/Inf numerical overflow and no abnormal interruptions such as process hangs or communication timeouts.
The logic behind this validation method is that the first few hundred steps of training are a high-risk window for numerical issues. Whether mixed-precision loss scaling is reasonable, whether precision reductions in communication are correct, and whether optimizer state sharding and recovery are lossless will all be exposed in early iterations. Although 400 consecutive stable steps are far from sufficient to represent full pretraining, they are enough to validate the correctness and basic robustness of the training pipeline. Further acceptance usually includes point-by-point alignment with the loss curve on reference hardware, allowing minor errors; mean time between failures under long-duration stress testing lasting days to weeks; and automatic recovery capability after failures.
Engineering teams should also establish a standardized acceptance checklist in practice:
- Numerical correctness: the relative error of loss in the first several steps compared with the reference implementation is within the agreed threshold.
- Throughput target: the number of tokens processed per second reaches a reasonable proportion of the theoretical peak.
- Stability: continuous operation produces no unrecoverable errors, and occasional failures can be automatically resumed from checkpoints.
- Observability: training metrics, hardware metrics, and communication metrics are monitorable end to end.
IV. From “Can Train” to “Train Out of the Box”: Evolution of Engineering Capability
The ultimate goal of training adaptation is not a one-off effort for a single model but a platform-level general capability. Industry practice suggests that this evolution generally goes through three stages. The first stage is “can train,” meaning manual, tuning-heavy adaptation for a specific model. The second stage is “stable training,” meaning complete from-scratch training on models ranging from tens of billions to hundreds of billions of parameters, while supporting full-pipeline training for different architectures such as scientific foundation models, world models, and embodied intelligence models. The third stage is “train out of the box,” meaning that mature operator libraries, standardized parallel configuration templates, and automated toolchains allow newly emerging frontier models to be adapted and put into training within a relatively short time.
The key to reaching the third stage lies in the degree of toolchain automation: whether missing operators can be automatically generated or fall back, whether parallel strategies can be automatically searched based on model structure and cluster scale, and whether training anomalies can be automatically diagnosed and localized. These capabilities determine how quickly the domestic compute ecosystem can respond to frontier models.
V. Practical Recommendations for Developers
For teams that want to train large models on domestic GPUs, the following path is recommended. First, start with small-scale single-node multi-GPU setups to validate operator correctness and the basic training workflow. Second, gradually expand to multi-node environments, focusing on validating collective communication and FSDP sharding strategies. Third, perform stability acceptance at the level of hundreds of steps and establish a loss alignment baseline. Finally, improve production-grade capabilities such as monitoring, alerting, and checkpoint resume before launching formal training tasks. At the same time, training data storage and movement can leverage general-purpose object storage and container platforms to build pipelines, while training task scheduling and observability can be implemented with general log services and monitoring and alerting systems, reducing duplicated infrastructure development costs.
Conclusion
Completing training adaptation for a flagship open-source model with nearly 3 trillion parameters and achieving 400 consecutive stable steps on two nodes with 16 cards marks a shift in domestic full-function GPU training capability from single-point validation to systematic engineering practice. As operator ecosystems, parallel frameworks, and automated toolchains continue to mature, the barrier to training frontier large models on domestic compute will continue to fall, and “domestic chips training domestic models” will gradually move from a benchmark case to a replicable industry norm.
