China's Open-Source LLMs Enter the Era of Long-Horizon AI Agents

    This article examines how China's latest open-source flagship models are shifting from conversational AI to long-horizon agents. It breaks down the sparse mixture-of-experts architecture, hybrid attention, and default thinking modes that enable multi-hour autonomous work, then covers evaluation benchmarks, deployment planning from single nodes to clusters, and risk controls for production use.

    1. From Chat Models to Long-Horizon Agents: A Shift in Technical Paradigm

    Over the past two years, LLM capability has mostly been evaluated through single-turn Q&A and short-chain reasoning, with interaction cycles typically lasting from seconds to minutes. Once models are placed inside real engineering workflows, however, the evaluation criteria change fundamentally. The task is no longer to answer a single question, but to advance a goal continuously for hours or even longer: reading code, modifying code, running tests, inspecting logs, rolling back, and iterating again.

    This shift introduces three direct constraints:

    1. State retention: The model must maintain the coherence of goals, constraints, and completed work across extremely long contexts.
    2. Self-correction: Failure is not an exception but part of the workflow. The model must interpret failure signals and adjust its strategy.
    3. Cost control: Long-running sessions cause token consumption to rise by orders of magnitude, making sparse activation and inference optimization engineering necessities.

    The new generation of Chinese open-source flagship models evolves incrementally around these three points: the underlying parameter scale and structure remain stable, with the focus on improving “working logic” and “task endurance.”

    2. Architecture Breakdown: Sparse Mixture of Experts + Composite Attention

    2.1 Parameter Scale and Sparse Activation

    These models reach a total parameter count in the 700-billion range (around 744B), yet activate only about 40 billion parameters (around 40B) per token. This “large total, small activation” design preserves knowledge capacity while keeping the actual compute cost of a single inference pass within an acceptable range.

    2.2 Mixture-of-Experts Structure

    A typical configuration uses 256 routed experts (Top-8 per token) plus 1 shared expert, with the first several layers retaining a dense structure to stabilize low-level representations. The engineering implications are:

    • Routed experts handle specialized capability distribution;
    • The shared expert carries general semantics, preventing capability fragmentation;
    • Dense base layers reduce uncertainty in training and inference.

    2.3 Attention and Speculative Decoding

    Attention layers commonly combine low-rank compressed attention with sparse attention to control memory and bandwidth pressure at context lengths of around 200,000 tokens. Multi-token prediction heads are also introduced to provide drafts for speculative decoding, which measurably reduces end-to-end latency in long-text scenarios.

    Illustrative pseudocode (structure only, not a specific API):

    1. # Illustrative mix of routed and shared experts
    2. logits = router(hidden) # Routing scores
    3. idx = topk(logits, k=8) # Top-8 routed experts
    4. y = sum(expert_i(hidden) for i in idx) + shared_expert(hidden)

    3. Why Long-Horizon Agents Need “Thinking by Default”

    The most notable behavioral change in the new generation is that thinking mode is enabled by default: general conversation uses “interleaved thinking,” while agent workflows add “retained thinking,” preserving reasoning traces between multiple tool calls to avoid goal drift over long chains.

    This brings two engineering benefits:

    • Traceable strategy: After a failure, you can pinpoint the specific decision branch instead of starting over.
    • Improving accuracy over time: In complex tasks that go through hundreds or thousands of strategy iterations, longer runtime yields higher result quality.

    The trade-off is higher token cost and latency. In practice, it is advisable to tier tasks: disable deep thinking for short Q&A, and enable the full thinking chain for long-running tasks.

    4. How to Read Capability Benchmarks Correctly

    Public benchmarks show that these models score around 58.4 on software engineering tasks (such as repository-level bug-fixing benchmarks), surpassing several leading overseas closed-source models from the same period. Overall capability and coding ability align with the international top tier.

    However, engineering selection should not rely on a single score. A three-dimensional evaluation is recommended:

    Dimension Focus Validation Method
    Task endurance Whether it converges during hours of unattended operation Long-chain regression task sets
    Environment operation Correctness of terminal commands and file system actions Sandboxed terminal benchmarks
    Long-context understanding Losslessness at the 200,000-token level Cross-file retrieval Q&A

    5. Compute and Deployment: Planning from Single Node to Cluster

    Deploying full 100-billion-class weights typically requires at minimum a single node equipped with 8 high-end accelerator cards (such as an HGX form factor). Three tiers are commonly used in practice:

    1. Validation tier: Quantized weights + single-node multi-GPU to validate the functional pipeline.
    2. Production tier: Full-precision weights + multi-node multi-GPU, with tensor/pipeline parallelism enabled.
    3. High-concurrency tier: Layered inference services with prefix caching + continuous batching + speculative decoding.

    For supporting capabilities, general cloud components are recommended: a container platform for elastic scaling, object storage for weights and artifacts, a message queue for task decoupling, and logging plus monitoring/alerting for observability of long-running tasks. If you use the relevant general capabilities from Baidu AI Cloud, they can be combined along these categories, avoiding tight coupling with specific business logic.

    6. Implementation Recommendations and Risk Controls

    • Sandbox first: Execute all terminal operations in an isolated environment; never connect directly to production.
    • Budget guardrails: Set token and duration limits, with automatic degradation or termination when exceeded.
    • Human-in-the-loop: Keep manual confirmation at critical nodes, especially for deletion and release operations.
    • Observability loop: Collect thinking chains, tool calls, and test results together to form a traceable pipeline.

    7. Conclusion

    The significance of the new generation of Chinese open-source models lies not in a single benchmark score, but in making “long-horizon autonomous work” an engineering reality: sparse architecture controls cost, composite attention supports ultra-long contexts, and the default thinking mode keeps long chains on track. For developers, the real barrier has shifted from “can it run” to “how to design tasks, guardrails, and observability systems”—this is the core engineering capability for deploying long-horizon agents.