How to Evaluate and Benchmark the Mathematical Reasoning of Large Language Models

    This guide explains why a single "who is stronger" ranking fails to capture the mathematical reasoning ability of large language models, and lays out a practical evaluation methodology. It covers building a four-tier capability model, key details of benchmark construction such as difficulty mix, contamination control and version freezing, the impact of decoding and sampling settings, and how to report first-answer accuracy, majority-consistency rates, confidence intervals and process scores. It also lists common pitfalls and shows how to turn the evaluation workflow into a repeatable pipeline for model selection.

    1. Why “Which Model Is Stronger” Is Hard to Answer in One Sentence

    In discussions of model capability, mathematical reasoning is often treated as the core yardstick of general reasoning. Yet evaluation results frequently contradict each other: the same set of models can produce completely reversed rankings across different problem sets, prompting strategies, and sampling counts. The reason is not complicated — mathematical ability is not a single-dimensional metric, but a composite outcome determined jointly by the difficulty distribution of the problems, the length of the reasoning chain, tool-use ability, and output stability.

    A more professional approach, therefore, is not to publish a sweeping leaderboard, but to define the evaluation objective first: are you assessing the ability to crack competition-level hard problems, or the reliability of numerical computation and logic verification in engineering scenarios? Different objectives call for entirely different problem sets and metric designs.

    2. Building a Tiered Capability Model

    It is advisable to split mathematical reasoning into four tiers, each with its own problem design and scoring method:

    1. Basic arithmetic and symbolic manipulation: four arithmetic operations, unit conversion, equation solving. Focus on accuracy and format compliance.
    2. Applied modeling: converting a business problem described in natural language into equations or constraints. Focus on whether the model drops any conditions.
    3. Multi-step reasoning: derivations requiring more than five steps, involving case analysis or proof by contradiction. Focus on whether the intermediate steps are self-consistent.
    4. Open-ended problems: no standard answer or an open answer format, requiring conjectures, counterexample construction, and boundary verification. Focus on argument structure and verifiability.

    The value of tiering is that a model performing excellently at tier 2 while degrading markedly at tier 4 is a very common phenomenon. Mixing tiers into a single total score masks the real weaknesses.

    3. Key Details of Benchmark Construction

    • Difficulty mix: a 3:3:3:1 ratio of basic, modeling, multi-step, and open-ended problems is recommended, to avoid excessive noise from open-ended items.
    • Contamination control: prefer self-built problems, or rewrite public problems with new numbers and scenarios, to reduce inflated scores caused by memorization.
    • Decidable answers: subjective problems must come with scoring points (a rubric), for example “whether boundary conditions are stated explicitly” and “whether the correctness of the construction is verified”.
    • Version freezing: once a problem set is frozen, record its version number, and have all subsequent experiments reference the same version to guarantee cross-comparison.

    4. How Prompting and Sampling Strategies Affect Results

    The same model can differ significantly under different decoding configurations. In engineering practice, fix the following variables and record them in the experiment log:

    1. temperature: 0.0 # disable randomness for decision-type problems
    2. top_p: 1.0
    3. max_tokens: 4096 # long reasoning needs a sufficient budget
    4. n_samples: 5 # sample multiple times per problem, take the majority-consistent result
    5. seed: fixed value # ensure reproducibility

    For multi-step reasoning problems, a structured prompt can be used: first list the known conditions, then discuss cases separately, and finally substitute back to verify. For open-ended problems, require the model to explicitly output a four-part structure of “conjecture — construction — verification — conclusion”, which makes manual rubric-based scoring easier. After multiple samples, computing the consistency rate is an effective way to distinguish “genuinely capable” from “correct by luck”.

    5. Scoring and Statistics: From Accuracy to Confidence Intervals

    Accuracy from a single evaluation run fluctuates widely, so a statistical basis must be stated:

    • Sample multiple times per problem, and record both majority voting and first-answer accuracy as separate measures.
    • Report confidence intervals rather than single-point numbers, and avoid strong conclusions when the sample size is insufficient.
    • Introduce a process score: even if the final answer is wrong, if the reasoning structure is correct and the error occurs only in the final computation, it should be classified separately. Such “fixable errors” have a far smaller impact on engineering deployment than “structural errors”.
    • Report by tier: provide a radar chart of scores per tier instead of a single total-score ranking.

    Illustrative statistical output:

    1. Tier First-answer accuracy Majority consistency Process score
    2. Basic arithmetic 0.96 0.98 0.97
    3. Applied modeling 0.78 0.84 0.81
    4. Multi-step 0.55 0.66 0.70
    5. Open-ended 0.21 0.29 0.48

    6. Common Pitfalls

    1. Drawing global conclusions from a small number of problems. Differences across a dozen or so problems often fall within the noise range.
    2. Looking only at the final answer. “Lucky samples” with process errors but correct answers will severely overestimate ability.
    3. Ignoring output length and cost. A model with extremely long reasoning chains may lead on accuracy, but its latency and compute overhead may be unacceptable, so accuracy per unit cost needs to be introduced.
    4. Comparing horizontally with a uniform prompt. Different models vary in sensitivity to prompt structure, so each should undergo small-scale prompt tuning before comparison; otherwise you are measuring prompt-engineering skill.
    5. Confusing “can compute” with “can prove”. Strength on numerical problems does not imply the ability to complete rigorous proofs, and vice versa.

    7. Engineering Implementation Recommendations

    For enterprise adoption, the evaluation workflow can be built as a pipeline: problem sets are stored in object storage with version management, evaluation jobs are scheduled by a container platform, inference calls all go through an internal gateway to fix parameters, logs and scoring results are written to a logging service, and a metrics dashboard is connected to monitoring and alerting so that a notification is triggered automatically when a tier’s accuracy drops below a threshold. If enterprise private data is involved, it should be desensitized before entering the benchmark to avoid leaking sensitive information.

    If you use the relevant general capabilities of Baidu AI Cloud, the same category-based combination applies: object storage for dataset versioning, a container platform for concurrent evaluation, and logging plus monitoring and alerting for quality gating — upgrading “subjective impression-based comparison” into a sustainable quality system.

    8. Conclusion

    The right way to evaluate a large language model’s mathematical ability is: tier first, then fix the problem set, freeze decoding parameters, sample multiple times, report first-answer accuracy and consistency rate separately, provide confidence intervals and process scores, and factor cost into the metrics. Conclusions reached this way are reproducible, comparable, and usable for selection decisions, and they faithfully reflect the model’s capability boundaries in basic arithmetic, applied modeling, multi-step reasoning, and open-ended problems.