Large Language Model Innovation Under Compute Constraints: Architecture and Hardware Adaptation
This article examines how large language model teams pursue self-developed architectures and adapt models to domestic accelerators when high-end compute is constrained. It covers pluggable attention and positional encoding modules, a three-stage hardware adaptation process, open-source model releases, two-stage post-training with verifiable rewards, agent architecture for long-horizon tasks, and cloud inference cost practices, ending with an objective view of the remaining gap to the frontier.
Introduction: When Compute Constraints Become the Norm, Innovation Is the Only Variable
In the large language model industry, the past few years produced a simple scaling intuition: more parameters, more data, and more accelerators should translate into stronger capability. Once the supply of high-end compute became limited and technical routes remained far from converged, that intuition started to break down. A shared view has emerged within the industry: there is always a way forward. Constraints do not disappear on their own; what can change is engineering method and the way research is organized.
The public evolution paths of several large model teams in China show a clear main line: from self-developed pre-training architectures, to open-sourcing hundred-billion-parameter models, to exploring adaptation on domestic chips and opening up coding and agent capabilities for developers, and further to continued experimentation with model architecture directions such as recurrent and state-space structures. The difficulty of this path is not going from 0 to 1, but whether new technical breakthroughs can keep being found after crossing that first 1. This article takes a neutral perspective, abstracts the technical logic, and offers a reusable engineering practice framework.
1. Choosing a Technical Route Under Constraints
Pre-training Architecture: From Following to Self-Development
The industry early on widely adopted the decoder-only autoregressive structure, which is engineering-mature and has a well-developed ecosystem. The value of a self-developed architecture lies in two points: first, it allows structural optimization for Chinese corpora and long context; second, it allows controlled replacement of modules such as attention computation and positional encoding, leaving room for later cost and efficiency gains. The engineering recommendation is to make the architecture out of pluggable modules, for example:
# Illustration: pluggable attention/positional encoding modules make architecture ablation experiments easierclass Block(nn.Module):def __init__(self, attn_impl, pos_impl, d_model):super().__init__()self.attn = attn_impl(d_model) # Can be replaced with sparse attention, gated linear units, etc.self.pos = pos_impl(d_model) # Can be replaced with rotary positional encoding, etc.def forward(self, x, mask=None):return self.attn(self.pos(x), mask=mask)
Domestic Compute Adaptation: Not Just “It Runs,” but “It Runs Stably”
Migrating a model to domestic accelerators usually goes through three stages: filling operator gaps, aligning numerical precision, and optimizing communication. Common problems include missing operators that force a fallback to generic implementations, numerical precision differences that cause loss fluctuation, and insufficient collective communication bandwidth that reduces throughput. The practical recommendation: first establish a small-scale precision alignment baseline (comparing layer-by-layer output error), then perform operator-level replacement, and finally stress-test end-to-end throughput and memory usage.
Open Source and Ecosystem: Lowering the Cost of Trial and Error
The significance of open-sourcing hundred-billion-parameter models is that external developers can fine-tune and evaluate them under limited resources, forming a feedback loop. For enterprise users, this means scenario value can be validated at relatively low cost before deciding whether to commit training resources.
2. Post-training: Turning “Can Answer” into “Can Do”
Pre-training determines the foundation that sets the capability ceiling; post-training determines the shape in which capability actually lands. The current mainstream approach is a two-stage process of supervised fine-tuning (SFT) plus preference optimization (such as optimization based on human or rule feedback), with reinforcement learning using verifiable rewards layered on top.
Data Mix and Curriculum Design
In the post-training stage, data structure matters more than quantity. The recommendation is to construct data in layers of “basic instructions—domain tasks—long-horizon tasks” and control the difficulty gradient:
Stage 1: General instructions (covering format compliance, refusal boundaries)Stage 2: Domain tasks (code, structured extraction, tool calling)Stage 3: Long-horizon tasks (multi-step planning, state keeping, failure recovery)
Verifiable Rewards in Reinforcement Learning
In scenarios that can be judged automatically, such as coding and mathematics, using unit test pass rates and answer verifier output as reward signals is more stable than pure human preference. Engineering-wise, reward clipping and a KL constraint should be set to avoid policy collapse.
3. Long-Horizon Tasks and Agents: The Key to Engineering Deployment
Long-horizon tasks (such as multi-file code modification and cross-system data reconciliation) test state management and error recovery. A deployable architecture is “planner + executor + memory”:
- Planner: breaks the goal into verifiable subgoals, with each step producing an inspectable intermediate artifact;
- Executor: completes actions by calling tools (retrieval, code execution, database queries);
- Memory: stores key decisions and failure reasons to avoid repeating the same mistakes.
For evaluation, the recommendation is to introduce three metrics—task completion rate, average number of steps, and number of rollbacks—rather than looking only at final answer correctness.
4. Inference Cost and Cloud Engineering Practice
Hosting large model inference in the cloud usually requires combining general-purpose capability categories: object storage for models and datasets, a container platform for elastic inference instances, a message queue for smoothing request peaks, and logging plus monitoring and alerting services for observability. The general product categories Baidu AI Cloud offers for this kind of scenario can help enterprises move from validation to scale at relatively low operational cost. Key practices include dynamic batching to improve throughput, KV cache reuse to reduce latency, and tiered multi-instance scheduling by business priority.
5. Gap and Outlook
Objectively, a gap remains between large models in China and the highest global level, and there is still much unknown on the road to higher intelligence. Yet the necessary path from catching up to helping define the technical frontier is precisely the continuous solving of problems that are “hard but right”: architecture innovation, post-training methods, large-scale adaptation of domestic compute, and agent engineering. The difficulties have not disappeared, and the pace of innovation has never stopped.
