How to Scientifically Evaluate the Core Capabilities of Large Language Models
Public leaderboards only tell part of the story when choosing an LLM. This article presents a practical, multi-dimensional framework for evaluating the core capabilities of large language models across seven dimensions—task execution and stability, resistance to gaming, world knowledge and factuality, honesty and anti-sycophancy, hallucination control, code generation, and scientific reasoning and writing. It also outlines how to build your own evaluation system by defining scenario weights, constructing a private test set, combining automated tests with blind human review, running continuous regression, and adding production safeguards, so you can make reliable model choices in a fast-moving ecosystem.
Why a Single Metric Cannot Define a “Good Model”
When selecting or iterating on models, many teams instinctively look at public leaderboard rankings and scores. But leaderboards only reflect performance on standardized test sets and cannot cover the hugely varied scenarios found in real business use. A model that scores very high on a particular benchmark is not necessarily “good” on a concrete task, and it may even hide real flaws by over-optimizing for evaluation rules.
A sound evaluation therefore has to rest on a multi-dimensional framework: it should look not only at “whether it gets the answer right,” but also at “whether it is honest, reliable, and stable.” The sections below break this down into seven key dimensions, with an evaluation approach and practical methods for each.
Dimension 1: Task Execution Quality and Stability
A high-quality model should maintain steady execution on long, multi-step tasks rather than cutting corners or drifting off track. When evaluating this dimension, focus on three points:
- Instruction following: Does the model complete the task strictly within the given constraints, rather than adding or removing content on its own initiative?
- Consistency: For the same or similar tasks, is output quality reproducible, avoiding wildly different results across multiple runs of the same prompt?
- Detail completeness: Does it miss critical details such as boundary conditions, error handling, and extreme inputs?
A practical method is to build a task set spanning multiple difficulty levels and give each task several variants to verify consistency:
# Illustration: batch consistency evaluation of task execution qualitytasks = load_task_set("eval_cases.json") # each case contains prompt and expected constraintsruns_per_task = 3 # repeat runs to reduce noisedef evaluate_consistency(model, tasks, runs_per_task):report = []for case in tasks:outputs = [model.generate(case["prompt"]) for _ in range(runs_per_task)]# 1) Constraint pass rate: check whether outputs meet hard requirementspass_rate = sum(check_constraints(o, case["constraints"]) for o in outputs) / runs_per_task# 2) Consistency: stability across multiple outputsstability = pairwise_similarity(outputs)report.append({"id": case["id"], "pass_rate": pass_rate, "stability": stability})return report
Dimension 2: Resistance to Gaming and Evaluation Credibility
This is the most easily overlooked dimension, yet it has the greatest impact on conclusions. Some models may “learn” to recognize evaluation patterns and gain inflated scores by retrieving questions, applying templates, or temporarily switching behavior under specific prompts. This kind of “optimizing for the evaluation” is not only useless in real business, but can also mislead selection decisions.
The key to judging whether a model is reliable is to see whether it remains robust on tasks that are unseen, randomly constructed, and different in style from public evaluations. When evaluating, you should:
- Use a self-built private test set that does not overlap with any public data;
- Randomly rewrite, add noise to, and rephrase prompts to see whether outputs drop sharply;
- Cross-validate the same capability under different phrasings.
If a model only performs well under “standard phrasing” and degrades noticeably once the wording changes, be wary of targeted overfitting.
Dimension 3: World Knowledge and Factuality
World knowledge determines whether a model can make reasonable common-sense judgments and provide background information when it lacks context. Evaluating this dimension should not stop at “can it answer,” but should ask “is it correct, and does it hold up to verification.” A good approach is to sample by domain and build a “fact-checking checklist,” comparing each item against authoritative sources. Answers involving numbers, dates, and causal relationships need particular caution, because this kind of content is most prone to fluent-sounding but incorrect statements.
Dimension 4: Communication Honesty and Resistance to Sycophancy
A trustworthy assistant should give measured, objective statements rather than simply pandering to the user’s expectations. Sycophantic output amplifies bad decisions—it dresses up the user’s wrong judgment as “very reasonable” and makes users mistakenly believe they are on the right track. When evaluating, you can deliberately raise views with false premises or obvious bias, then observe whether the model simply agrees or can point out the problem and offer a reasoned rebuttal.
At the same time, watch for the opposite extreme: over-defensiveness. Some models refuse to answer or repeatedly disclaim at the slightest hint of risk, reducing usability. The ideal state is “both honest and efficient”—able to recognize risk while still providing as much valuable help as possible.
Dimension 5: Hallucination Control and Prompt Constraints
Hallucination (generating content that seems plausible but does not match facts) is the primary risk of today’s large models in knowledge-intensive scenarios. The good news is that hallucinations are not entirely uncontrollable; reasonable prompt constraints can significantly reduce their rate. The core idea is: limit the answer boundary, require explicit citation of sources, and allow the model to admit “I don’t know.”
# Illustration: prompt template for reducing hallucinations through constraintsGUARDRAIL_PROMPT = """You must answer using only the content in the [Reference Material].Rules:1. If the reference material is insufficient to support an answer, you must reply "This cannot be confirmed based on the available material," and you are forbidden from fabricating content.2. After each key conclusion, mark the number of its source paragraph.3. When numbers, dates, or proper nouns are involved, you must verify them word-for-word against the reference material before outputting.Reference Material:{context}User Question:{question}"""
In engineering practice, you can also introduce a “retrieve-generate-verify” pipeline: first have the model extract the key entities in its answer, then check them for consistency against an external knowledge base (such as authoritative documents in a log service or object storage), intercepting assertions that cannot be verified. This turns “model self-discipline” into “system-verifiable” reliability.
Dimension 6: Code Generation Capability
Code capability is one of the scenarios developers care about most, but it is not a single question of “can it write code”; it should be broken into several sub-dimensions:
- Correctness: Can it pass unit tests and boundary cases?
- Maintainability: Are naming, structure, and comments clear, with no redundant stacking?
- Thoroughness: Are details such as error handling, concurrency safety, and resource release in place?
The advantage of code scenarios is the low cost of verification—correctness can be judged directly with automated tests. It is advisable to pair each code task with a test set and score by pass rate rather than subjective impression:
def evaluate_code_task(model, task):code = model.generate(task["prompt"])results = run_tests(code, task["test_cases"]) # execute in an isolated environmentreturn {"pass_rate": results.passed / results.total,"has_error_handling": detect_error_handling(code),"lint_score": run_linter(code),}
It is worth noting that a model strong at code is not necessarily equally strong at scientific reasoning, and vice versa. There are trade-offs between different capabilities, so selection should weigh them against the primary use case.
Dimension 7: Scientific Reasoning and Writing/Narrative
In scientific and deep-reasoning scenarios, the focus is on whether the model’s logical chain is complete when handling complex problems, whether its assumptions are reasonable, and whether its conclusions are grounded. Such tasks often have no single correct answer and require human sampling and review, or cross-validation across multiple models to expose logical gaps.
In writing and narrative scenarios, the focus shifts to the organization of language, the coherence of structure, and the persuasiveness of expression. These capabilities are hard to quantify but critical for content-production applications. A “blind comparison” approach works well here: have reviewers rank multiple outputs without knowing their source, reducing preconceived bias.
Building Your Own Evaluation System
Combining the dimensions above, a practical evaluation system should include the following steps:
- Define scenario weights: Assign different weights to each dimension according to the primary business scenario, avoiding a one-size-fits-all approach.
- Build a private test set: Cover multiple difficulty levels and phrasings, with no overlap with public data.
- Combine automation with human review: Automate verifiable dimensions (code, fact-checking) as much as possible, and supplement subjective dimensions (writing, honesty) with blind human review.
- Run continuous regression: Re-run the evaluation set after each model iteration to prevent capability regression or newly introduced sycophancy and hallucinations.
- Add production safeguards: Introduce constraint prompts and external verification into the production pipeline, turning reliability from “depending on model self-discipline” into “something the system can guarantee.”
When you need to scale these evaluation and inference tasks, you can leverage mature general-purpose capabilities on a cloud platform—for example, using a container platform to elastically schedule batch evaluation jobs, object storage to archive test sets and results, monitoring and alerting to track fluctuations in online output quality, and a log service to accumulate auditable evaluation records. Baidu AI Cloud offers corresponding support in these general capability categories and can help teams engineer and sustain their evaluation workflows.
Conclusion
Evaluating a large language model is essentially answering the question “can it be trusted in my scenario.” Leaderboard scores are only a starting point; real judgment comes from multi-dimensional cross-validation: does it execute carefully, is it honest rather than sycophantic, does it resist gaming, are hallucinations controllable, and are code and reasoning up to standard. Only by turning these dimensions into reproducible tests and engineered workflows can you make robust, durable choices in a rapidly iterating model ecosystem.
