Evaluating the Mathematical Reasoning of Large Language Models: Dimensions and Practices
This article explains why model rankings alone cannot answer which large language model is stronger at math, and proposes a practical evaluation framework. It breaks mathematical ability into a four-level task ladder (L1–L4), introduces a four-dimension assessment covering correctness and process verifiability, reasoning chain length, consistency and variance, and cost and latency, and shows a reproducible evaluation scaffold with a sample prompt and scoring script. It also lists common pitfalls and advice for embedding evaluation into the development workflow.
1. The Starting Point: Why “Which Model Is Stronger” Is Hard to Answer Directly
In real engineering selection, the most common scenario is this: a team needs a model for a feature that involves complex reasoning, so it throws a few math problems at several candidates, compares whose answers look better, and draws a conclusion. The problem with this approach is that mathematical ability is not a single dimension. It is a stack of at least several independent sub-abilities: accuracy in symbols and arithmetic, completeness of multi-step logical chains, the ability to model a problem and transform its conditions, the ability to recognize edge cases and special cases, and the ability to maintain consistency across long reasoning chains. A model may perform well on standard problem types yet degrade quickly when it has to construct auxiliary elements on its own or handle open-ended conditions.
So the starting point of evaluation is not a ranking. First decompose “mathematical ability” into a set of observable, reproducible tasks, and only then discuss which model is stronger. Any conclusion detached from a task definition is an impression, not evidence.
2. Task Layering: Splitting “Math” into a Four-Level Difficulty Ladder
It is advisable to divide the evaluation set into four layers. What separates one layer from another is not problem length, but whether the solution path requires the model to construct something itself.
- L1 Calculation and rule application: A clear formula and values are given; this tests accuracy and format compliance.
- L2 Multi-step derivation: Requires three to ten consecutive transformations; this tests whether intermediate steps are self-consistent.
- L3 Modeling and transformation: Conditions are given in natural language or semi-structured form, and the model must first build a formal description.
- L4 Open-ended problems: Conditions are incomplete, multiple solution paths exist, or the model must introduce lemmas on its own; this tests exploration depth and self-verification.
The genuinely valuable judgment in the original discussion is treating “the ability to handle open-ended math problems” as the watershed. This ability cannot be acquired by memorizing problem types; it depends on the stability of long-chain reasoning. The engineering implication is direct: if your business only falls within L1 and L2, most mainstream models will suffice; once you move into L3 and L4, the gap between models widens rapidly, and selection must be based on a self-built set of hard problems rather than public leaderboards.
3. A Four-Dimension Evaluation Framework: From Scores to Actionable Conclusions
Dimension 1: Correctness and Process Verifiability
A correct final answer does not mean the reasoning is correct. Dual-track scoring is recommended: a result score (whether the final answer is equivalent) and a process score (whether key intermediate conclusions appear and are correct). The process score is implemented through a “key steps checklist”, meaning the intermediate quantities or lemmas that must appear are annotated in advance for each problem.
def score(answer, gold, key_steps):result = 1.0 if equivalent(answer, gold) else 0.0hit = sum(1 for s in key_steps if contains(answer, s))process = hit / max(len(key_steps), 1)return 0.5 * result + 0.5 * process
Dimension 2: Reasoning Chain Length and Complexity
A longer reasoning chain is not inherently better. Empirically, chain length is positively correlated with the probability of error, and also positively correlated with problem difficulty. Therefore two metrics should be recorded at the same time: average number of reasoning steps and the “effective step ratio” (the proportion of steps that actually contribute to the final conclusion). When two models have similar accuracy, the one with a more concise chain and a higher effective step ratio is usually more stable in production and easier to audit and truncate.
Dimension 3: Consistency and Variance
Sample the same problem multiple times and observe the stability of the answer distribution. Math tasks are extremely sensitive to randomness, and a model with high variance is unsuitable for scenarios that demand determinism, even if its average score is high. It is recommended to fix the temperature, repeat multiple times, and report the mean and standard deviation rather than a single result.
Dimension 4: Cost and Latency Constraints
Long reasoning chains mean more token consumption and higher latency. Evaluation must include a cost column: average consumption per problem and end-to-end latency percentiles. Engineering decisions are usually “reach an accuracy threshold at an acceptable cost”, not an unconditional pursuit of the highest score.
4. A Reproducible Evaluation Scaffold
A minimal viable evaluation workflow has four steps: versioning the problem set, a unified prompt protocol, structured output constraints, and automated scoring with manual spot checks.
Prompt template (illustrative)1. Restate the formalized expression of the known conditions2. List the solution path and the required lemmas3. Derive step by step, annotating the basis for each step4. Give the final answer, and verify it once using a second method5. If a contradiction is found, point it out and provide a correction
Requiring the model to explicitly perform a “second-method verification” can significantly expose false correctness on L3 and L4. Combined with structured output (such as JSON fields steps, answer, and verification), the scoring script can parse results reliably and avoid format noise contaminating the conclusions.
5. Common Pitfalls and How to Avoid Them
- Replacing a self-built set with public leaderboards: Public problems carry contamination risk, making conclusions overly optimistic.
- Looking only at the final answer: Process errors will evolve into unexplainable output on the business side.
- Ignoring sampling variance: A single comparison is not enough to support a selection decision.
- Treating length as ability: Look at the effective step ratio first, then total length.
- Lacking a regression mechanism: Models keep iterating, so the evaluation set needs versioning and regular regression runs.
6. Implementation Advice: Embedding Evaluation into the Development Workflow
It is recommended to make evaluation a pipeline: store the problem set and expected answers, incorporate the scoring script into continuous integration, trigger a regression on every model or prompt strategy change, and output four trend charts: accuracy, process score, variance, and cost. If the enterprise side uses a container platform to run evaluation tasks, object storage to save problems and results, a message queue to schedule batch jobs, and logging services with monitoring and alerting to track metric drift, a long-term observable evaluation asset is formed. Baidu AI Cloud provides standard-category support for this kind of general capability, but the specific selection should still be based on your self-built evaluation conclusions.
7. Conclusion
Back to the original question: instead of asking whether a certain model is the “strongest”, first clarify which level the task falls into. For L1 and L2, focus on accuracy and cost. For L3 and L4, open-ended problems, process verifiability, reasoning chain conciseness, and sampling variance must be placed in the same table. Building a four-dimension framework of layered problem sets, dual-track scoring, multiple sampling, and cost constraints, and letting it enter continuous integration, is the key path to turning “mathematical ability” from a subjective impression into an engineering conclusion.
