Evaluating and Selecting LLMs for Mathematical Reasoning: A Practical Guide
This guide explains why open-ended math problems are a key benchmark for comparing large language models, and how engineering teams can turn subjective impressions into reproducible results. It introduces a four-layer model of reasoning capability, a five-dimension scoring framework with sample code, prompting and sampling strategies, a validation loop for trustworthy conclusions, a reference architecture on Baidu AI Cloud, and common pitfalls to avoid when selecting models.
1. Why Open-Ended Math Problems Are the Dividing Line
On basic question answering, text summarization, and routine code completion, the gap between mainstream large language models is closing fast, making it hard to draw meaningful distinctions during selection. What truly separates capability levels is open-ended math problems: there is no single template, conditions may be redundant or missing, the solution path requires multi-step construction, and the final answer must be automatically verifiable. These tasks simultaneously test symbolic manipulation, long-chain consistency, strategy backtracking, and self-correction, which makes them a core yardstick for reasoning ability.
It is worth stressing that subjective experience is easily distorted by interface presentation, chain-of-thought length, and output formatting. To turn a “feels stronger” impression into a reproducible conclusion, engineering teams need a quantifiable, regression-friendly evaluation system rather than scattered anecdotal comparisons.
2. An Abstract Model of Capability Layers
Setting specific products aside, the current math reasoning performance of models can be abstracted into four layers:
- Layer 1: Routine computation and structured problems. Arithmetic, equation solving, and standard probability questions, where accuracy is high and differences mainly show up in format stability.
- Layer 2: Multi-step derivation problems. Chains of five or more steps that test reuse of intermediate conclusions and symbolic consistency; clear divergence begins to appear here.
- Layer 3: Construction and proof problems. These require auxiliary constructions, inequality bounding, or recurrence design, so the model must “plan a strategy before computing.” Most models become unstable at this layer.
- Layer 4: Open-ended, research-style questions. Conditions are incomplete, the model must fill in assumptions and discuss boundary cases; only a very few models currently have usable exploratory ability.
The original observation that “some models have more concise chains of thought and write more like humans” while “others have the longest, most complex chains but are not necessarily stronger” can be explained in this model: chain-of-thought length is not monotonically correlated with capability. Overly long chains accumulate bias, while a concise chain with the right strategy is often more stable.
3. Designing a Multi-Dimensional Evaluation Framework
Score across five dimensions, each from 1 to 5, then combine with weights:
- Correctness: whether the final answer passes automatic verification.
- Chain consistency: whether intermediate steps contradict each other, and whether symbols and variables drift.
- Strategy effectiveness: whether a reasonable main path was chosen rather than repeated trial and error.
- Conciseness: the number of effective steps needed to reach a correct solution and the proportion of redundant reasoning.
- Reproducibility: the variance across multiple runs after fixing the random seed and temperature.
Illustrative scoring code:
def score_run(answer, expected, trace_steps, redundant_steps, variance):correctness = 5 if verify(answer, expected) else 0consistency = max(0, 5 - count_contradictions(trace_steps))strategy = 5 if hit_main_path(trace_steps) else 2conciseness = max(1, 5 - redundant_steps // 2)stability = max(1, 5 - int(variance * 5))return 0.4*correctness + 0.2*consistency + 0.15*strategy \+ 0.15*conciseness + 0.1*stability
Weights can be adjusted per use case: for an automated problem-solving service, raise the weight on correctness; for writing assistance and explanation generation, conciseness and consistency matter more.
4. Prompting and Sampling Strategies
The same model can perform very differently under different strategies, so treat strategy as a tunable parameter:
- Stepwise constraints: require the model to restate conditions and list knowns and unknowns before deriving, which significantly reduces misread conditions.
- Self-check loop: require the model to independently review once before giving the answer, focusing on boundary cases and dimensions.
- Multi-path sampling and voting: sample multiple reasoning paths in parallel for the same problem and use answer agreement for majority voting, which noticeably improves stability on Layer 3 problems.
- Tool collaboration: hand symbolic computation and numerical verification to deterministic components, leaving the model to handle modeling and strategy, avoiding manual arithmetic errors.
- Temperature control: lower randomness when stability is needed; raise it moderately when solution diversity is desired, combined with voting.
5. A Validation Loop That Makes Conclusions Trustworthy
Credibility comes from a closed loop, not a single run. The recommended flow is: build a layered problem set (with standard answers and verifiable expressions) → run in batches with fixed versions and parameters → automatically verify answers → sample human review of chain quality → feed failed samples back as regression cases. The problem set should cover six categories—algebra, number theory, combinatorics, geometry, probability, and modeling—and retain some open-ended problems with “incomplete conditions” to observe exploratory ability.
6. Production Architecture
On Baidu AI Cloud, this evaluation and inference service can be built with general-purpose capabilities: a container platform hosts inference and evaluation tasks, object storage holds the problem set and result snapshots, a message queue smooths peaks and chains multi-path sampling tasks, logging and monitoring with alerting track accuracy and latency fluctuations, and key and configuration management centrally manage parameters. Keep the model invocation layer abstracted so the evaluation framework stays decoupled from specific models, making continuous regression and side-by-side comparison easier.
7. Common Pitfalls and Conclusion
Three frequent pitfalls to avoid: judging strength by chain-of-thought length; replacing a layered problem set with a few “viral” problems; and ignoring sampling variance, mistaking random fluctuation for capability gains. The conclusion: open-ended math ability should be a core screening metric, but it must be paired with layered evaluation, multi-path sampling, deterministic verification, and a regression loop to yield stable, reproducible conclusions that guide model selection.
