Large-Model Training on China-Developed AI Compute: Technical Paths and Practices

    This article examines the shift from inference to pretraining on domestically developed AI accelerators. It explains why large-scale training is more demanding than inference in compute scale, stability, communication, and software ecosystems; outlines a software-stack-first migration path; discusses the cost implications of diversified compute supply; and offers practical guidance for engineering teams.

    1. Background: The Compute Challenge of Large-Model Training

    Training large models places extraordinary demands on compute. For a model with hundreds of billions of parameters, pretraining often requires thousands of high-performance accelerators running continuously for weeks or even months. For a long time, training compute has relied mainly on high-end GPUs from overseas vendors. As export controls have continued to tighten, channels for domestic teams to obtain high-end training chips have become narrower, and costs have risen accordingly.

    Recent industry discussions suggest that one large-model R&D team plans to move the pretraining of its next-generation model entirely onto domestically developed AI chips. Previously, domestic chips in that team’s technical stack mainly handled inference. Inference has relatively looser requirements for compute precision and cluster scale, whereas training—especially pretraining—is a stress test of chips, software stacks, and cluster interconnect capabilities. If this transition is realized, it would push domestic compute into the most technically demanding position for the first time, with significance far beyond a single model iteration.

    2. Why Is Training Harder Than Inference?

    To understand the difficulty of this shift, it is necessary to clarify the fundamental technical differences between training and inference.

    1. Different Requirements for Compute Scale and Stability

    Inference services can usually run on a single machine with a single card or on a small cluster. Tasks can be interrupted and retried, and tolerance for hardware failures is relatively high. Once pretraining starts, however, thousands of cards often need to work together continuously for weeks. Any single-point failure can interrupt the training job, so hardware stability, fault recovery mechanisms, and checkpoint-saving strategies all face extremely high requirements.

    2. Different Levels of Communication Pressure

    During training, gradients must be synchronized frequently across cards. With data parallelism, AllReduce is performed at every step, while pipeline parallelism and tensor parallelism introduce finer-grained communication patterns. This places strict demands on inter-node interconnect bandwidth, network topology, and communication library optimization. The following gradient synchronization logic is illustrative:

    1. # Gradient synchronization in data-parallel training (pseudo-code)
    2. for batch in dataloader:
    3. loss = model(batch)
    4. loss.backward()
    5. # AllReduce: average gradients across all cards
    6. for param in model.parameters():
    7. dist.all_reduce(param.grad, op=dist.ReduceOp.SUM)
    8. param.grad /= world_size
    9. optimizer.step()

    Behind this seemingly simple logic lies extensive room for optimization in communication libraries, collective communication primitives, and network protocol stacks. To support training, domestic chips must complete this entire part of the puzzle.

    3. Different Levels of Software Ecosystem Maturity

    Inference scenarios have relatively manageable requirements for software stack compatibility. Training frameworks—such as various distributed training engines—and underlying hardware involve a large number of low-level components, including compilers, operator libraries, memory management, and automatic differentiation. The absence of any one link can significantly reduce training efficiency or even prevent training from running.

    3. A Key Path for Domestic Compute: Software Stack First, Then Hardware

    Industry practice suggests a clear technical path for domestic chips to take on training workloads: build out the software stack first, then move to hardware.

    1. A Complete Set of Low-Level Components

    To run large-scale training on domestic accelerators, at least the following layers of components are needed:

    • Compiler layer: compiles computation graphs from upper-layer frameworks into hardware-executable instructions, covering graph optimization, operator fusion, memory planning, and related steps;
    • Operator compute library: provides core operator implementations such as high-fidelity matrix multiplication and attention mechanisms; operator efficiency directly determines training throughput;
    • Communication library: implements collective communication primitives such as AllReduce and AllGather and optimizes them for cluster network topologies;
    • Runtime and driver: handles task scheduling, memory management, multi-stream concurrency, and other low-level resource management.

    One team reportedly open-sourced domestic counterparts for its full stack of low-level components originally targeting foreign chips—compiler, compute library, and communication library aligned one by one. This “layer-by-layer alignment” approach indicates that the team had already laid a solid foundation for the software ecosystem before hardware migration. The strategy is worth learning from: the upper limit of hardware performance is largely determined by the maturity of the software stack.

    2. Typical Approaches to Operator and Performance Optimization

    In practical adaptation, common optimization methods include:

    • Operator fusion: combining multiple small operators into a large operator to reduce memory access overhead and kernel launches;
    • Mixed-precision training: using BF16/FP16 for computation while maintaining master weights in FP32 to improve throughput while preserving convergence;
    • Recomputation strategy: trading time for memory by recomputing intermediate activations on demand when memory is tight;
    • Topology-aware communication optimization: adjusting parallel strategy partitioning based on differences between intra-node NVLink-like high-speed interconnect and inter-node networks.

    4. The Cost Perspective: Diversified Compute Supply Breaks the Price Ceiling

    From an industry perspective, diversifying training compute sources has a deeper impact: it changes the cost structure.

    When training compute has only a single source, the supplier holds pricing power, AI compute costs remain high, and this ultimately translates into high model API prices. Once domestic compute can handle training workloads, the market gains de facto “substitutable supply,” and compute prices naturally enter a downward path. Over the past year or so, domestic large-model API prices have undergone multiple rounds of significant cuts—from token pricing that was once more expensive than gold to today’s extremely low prices. Behind this are multiple combined factors, including diversified compute supply, inference efficiency optimization, and model architecture innovation such as sparse activation and MoE.

    For developers, this is a tangible benefit. A simple cost estimation example:

    1. # Rough estimate of model invocation cost
    2. input_tokens = 1_000_000 # Monthly input tokens
    3. output_tokens = 500_000
    4. price_per_m_input = 0.5 # Price per million tokens (CNY)
    5. price_per_m_output = 2.0
    6. monthly_cost = (input_tokens / 1e6) * price_per_m_input \
    7. + (output_tokens / 1e6) * price_per_m_output
    8. print(f"Estimated monthly cost: {monthly_cost} CNY")

    The same application logic might have required dozens of times the cost to run a year ago. The decline in cost directly changes the feasibility boundary of application innovation, and many AI applications that could not be deployed due to cost now have commercialization conditions.

    5. Implications for Technical Teams

    Based on these trends, here are several suggestions for enterprise technical teams:

    1. Keep architecture design compute-agnostic: application layers should access model capabilities through standardized interfaces as much as possible, avoiding deep binding to specific hardware or specific inference engines, and preserving flexibility for future compute switching;
    2. Focus on hybrid compute scheduling: training, fine-tuning, and inference can be allocated to different compute pools, improving overall utilization through a unified scheduling platform;
    3. Prioritize inference cost optimization: including KV Cache management, request batching, quantized deployment, and model distillation; when applied properly, these can significantly reduce per-token cost;
    4. Establish a cost monitoring system: use usage statistics and alerting mechanisms to track compute consumption across business lines in real time and avoid runaway costs.

    6. Conclusion

    From inference to training, domestic compute is completing a transition from an “auxiliary role” to a “main force.” This is not the result of a single breakthrough, but a systematic outcome of progress across software stack completion, hardware iteration, capital investment, and ecosystem building. Diversified compute supply is not only about technology autonomy and supply-chain control; through market competition, it also continues to push down the cost of using AI, ultimately benefiting more developers and enterprises.

    For technical professionals, what is worth doing now is to maintain technical sensitivity during this infrastructure shift: understand the adaptation logic of heterogeneous compute, master engineering methods for cost optimization, and make technical solutions run efficiently in any compute environment.