Evaluating Chinese LLMs: A Practical Engineering Guide to Model Selection

    Public leaderboards rarely predict how a large language model will behave in your own application. This guide lays out a hands-on framework for evaluating Chinese LLMs across six practical dimensions: document understanding, structured prompt adherence, retrieval-augmented generation, code generation, API availability, and context management. Each dimension comes with concrete evaluation methods and engineering safeguards, illustrated with runnable pseudo-code. A real project case study shows how task-based model routing, mandatory testing, and fallback planning work in practice, and the article closes with a reusable selection checklist and a case for building your own small evaluation set instead of trusting benchmarks.

    Evaluating Chinese LLMs: A Practical Engineering Guide to Model Selection

    1. Why “Promising” Can’t Be Judged by Leaderboards Alone

    When developers discuss which Chinese LLMs are worth investing in, the default move is to check benchmark rankings. But real-world engineering experience often diverges from the leaderboards: a model that scores highly on general Q&A may be mediocre at structured output, long-document parsing, or code completion, while a model that ranks unremarkably can be rock-solid in a specific scenario.

    Whether a model is “promising” should therefore be judged across four dimensions: task fit, clarity of capability boundaries, engineering integration cost, and ecosystem maturity. Drawing on hands-on experience from real projects, the sections below take each one in turn.

    2. Hands-On Observations Across Core Capabilities

    2.1 Document Understanding and Information Extraction

    Long-document parsing is one of the areas where Chinese models have improved most visibly. Take PDF reading and key-point summarization: with relatively simple prompts, some models can now complete the full chain of “read — summarize — output structured data,” extracting the important information from a document and presenting it in a specified format.

    The engineering value here is high. Contract review, report summarization, and cleaning content before it enters a knowledge base all depend on a model’s ability to reliably understand unstructured documents. When evaluating, focus on three things:

    • Long-context retention: once a document exceeds a certain length, can the model still reference details from earlier sections?
    • Table and layout fidelity: are tables and multi-column layouts in the PDF parsed correctly?
    • Hallucination resistance: does the summary contain figures or conclusions that don’t exist in the source?

    You can use the following pseudo-code as a unified evaluation harness to compare multiple models side by side:

    1. def evaluate_doc_understanding(model_client, pdf_text, questions):
    2. prompt = build_structured_prompt(
    3. task="summarize_and_extract",
    4. schema={"summary": "str", "key_points": "list[str]", "risks": "list[str]"}
    5. )
    6. resp = model_client.chat(prompt=prompt, context=pdf_text)
    7. parsed = safe_json_parse(resp) # structured parsing; score 0 on failure
    8. score = {
    9. "schema_valid": parsed is not None,
    10. "coverage": answer_coverage(parsed, questions),
    11. "hallucination": detect_hallucination(parsed, pdf_text),
    12. }
    13. return score

    Same script, same prompts, same scoring rubric — only then do you get comparable conclusions instead of judgments based on subjective impressions.

    2.2 Adherence to Structured Prompts

    An early, widespread weakness of Chinese models was unstable handling of structured prompts — when a prompt combined a role definition, output format constraints, and multi-step instructions, models tended to execute only part of it or ignore the format and improvise.

    Recent hands-on testing suggests this is improving: some models now understand reasonably simple structured prompts and emit JSON or tables with the specified fields. But there is still a clear gap between “understands simple structure” and “reliably executes complex multi-step instructions.” Engineering countermeasures include:

    1. Lower the complexity of each call: split multi-step tasks into multiple calls, one job per step;
    2. Validate output up front: enforce schema checks in the parsing layer and automatically retry with the error message attached when validation fails;
    3. Use few-shot examples: including one or two input/output pairs in the prompt noticeably improves format adherence.

    2.3 Real-World RAG Performance

    Retrieval-augmented generation (RAG) has become a standard component of mainstream architectures, but implementation quality varies widely. One design pattern worth noting: not every user request should trigger web retrieval — run a decision step first to determine whether the question actually needs external information, and only then retrieve.

    This “retrieve on demand” strategy makes more engineering sense because:

    • Retrieving on every request adds latency and cost, and can inject irrelevant noise into the context;
    • For questions the model’s own knowledge can answer, forced retrieval can actually degrade the response;
    • The decision logic can be implemented as configurable rules (keywords, freshness requirements, domain allowlists), which is more controllable than relying purely on the model’s judgment.

    To evaluate RAG behavior, build three categories of test questions: freshness questions (need the latest information), common-knowledge questions (should not trigger retrieval), and boundary questions (part of the information lives externally). Then watch whether retrieval fires at the right moments.

    2.4 Code Generation

    Coding ability is a key differentiator of model positioning. Hands-on experience shows that some models strong at document understanding have clear weaknesses on code: they handle simple questions correctly, but with slightly more complex requirements — multi-file coordination, edge-case handling, dependency calls — they produce code that “looks right but fails at runtime.”

    This class of error is more dangerous than obvious syntax errors because it’s hard to catch by eye. Protective measures:

    • Actually execute the code: run every generated snippet against unit tests in a sandbox and reject it if tests fail;
    • Generate in stages: have the model produce the design and function signatures first, confirm them, then generate the implementation;
    • Cross-validate: generate critical modules with two different models and compare the differences.

    If code generation is a core requirement of your project, prioritize models specifically optimized for programming tasks rather than forcing a general-purpose model to cope.

    2.5 API Availability and Integration Cost

    This is the most commonly overlooked factor, and the one that most directly affects your schedule. Some models deliver a great web experience, but their APIs remain in closed beta or application-only access for long stretches, so developers can’t wire them into their own systems.

    The practical impact is concrete: if you want to build a personal knowledge base or an automated document-processing pipeline, and the model you want has no usable API, your only option is to fall back to another model with open interfaces. So API availability, quota limits, billing model, and SDK support should be hard gate criteria in your selection checklist — not something you think about after the prototype is done.

    2.6 Context Management and Session Experience

    Web-based chat products share several common weaknesses in context management:

    • No explicit context toggle: users can’t choose whether to carry conversation history forward;
    • Unexpected context loss: partway through a long conversation, the model suddenly “forgets” earlier content with no clear warning;
    • Weak history search: past conversations can’t be searched by keyword, which hurts long-running projects.

    The root cause is opaque context-window management. If you’re integrating a model into your own product, implement session management at the application layer: maintain the message list explicitly, truncate or summarize within a token budget, and provide history search. Don’t rely on the model to “remember automatically.”

    1. // Application-layer context management: trim history to a token budget
    2. function buildContext(history, maxTokens, tokenizer) {
    3. let total = 0;
    4. const kept = [];
    5. for (let i = history.length - 1; i >= 0; i--) {
    6. const t = tokenizer.count(history[i].content);
    7. if (total + t > maxTokens) break;
    8. kept.unshift(history[i]);
    9. total += t;
    10. }
    11. return kept;
    12. }

    3. From Requirements to Deployment: A Real Project’s Selection Path

    My team once set out to build a SaaS platform for self-service venues — game rooms and billiard halls. When we evaluated outsourcing early on, third-party quotes came in at the 100,000+ RMB level; with a limited budget, we decided to build it ourselves.

    Toolchain: We worked primarily with AI coding tools — an AI-assisted IDE and a terminal-based assistant — on a professional subscription plan, with multiple mainstream LLMs running underneath. Conversational assistants and command-line AI utilities filled supporting roles. The principle behind this combination: coding-optimized models for implementation, general-purpose conversational models for documentation and design discussions — route by task type rather than defaulting to a single model.

    Tech stack: Node + Express + MongoDB on the backend, deployed on cloud servers to serve the whole SaaS platform. The models’ roles included API code generation and completion, document parsing (merchant qualification materials), marketing copy generation, and drafting customer-support answers.

    Lessons learned:

    1. Task routing matters more than model choice. No single model wins at everything; routing tasks by type is the pragmatic approach.
    2. AI-generated code must pass tests. For anything touching billing or permissions, human review is non-negotiable.
    3. API stability beats peak capability. An interface that scores 90 but behaves unpredictably is worth less than one that scores 75 and is predictable.
    4. Keep a fallback path. Have backup models ready for critical flows so a single provider’s instability doesn’t take your business down.

    4. A Practical Evaluation Checklist

    Putting it all together, run your selection against this checklist:

    Dimension How to Evaluate Suggested Weight
    Document understanding Run extraction tests on your own real documents; check hallucination rate High
    Structured output Fix a schema and measure the parse success rate High
    Code capability Sandbox execution plus unit test pass rate Depends on scenario
    API availability Confirm open status, quotas, billing, and SDK support Hard requirement
    Context management Long-conversation testing; watch for forgetting and truncation Medium
    Ecosystem and docs SDK quality, error-code conventions, community activity Medium

    5. Conclusion

    Chinese LLMs are iterating fast. Judging whether one is “promising” should come back to engineering fundamentals: can it reliably complete your tasks, can it be integrated at low cost, and are its capability boundaries clear and predictable? A practical habit: build your own small evaluation set — 20 to 50 test cases constructed from real business data — and run regression tests against it regularly. Leaderboards change; your own evaluation set is the most reliable basis for selection.

    For tasks like document understanding and structured output, current models already reach a “fairly good” level and are worth trying hands-on. For code generation and long-session management, stay cautious and back them up with engineering safeguards. The end goal of model selection isn’t finding “the strongest model” — it’s building an architecture where models are replaceable, capabilities are verifiable, and failures degrade gracefully.