TL;DR
Traditional process reward models (PRMs) evaluate mathematical reasoning steps chronologically, meaning they cannot use future context to spot earlier mistakes. This paper introduces LLaDA-PRM, an 8B bidirectional evaluator built on a diffusion language model that looks both backward and forward through a solution trace. By leveraging downstream consequences, LLaDA-PRM achieves state-of-the-art error detection, outperforming causal models up to four times its size.
What Problem Does This Paper Address?
When large language models (LLMs) tackle complex, multi-step math problems, evaluating the validity of each intermediate step is crucial for accurate decoding and data filtering. Most existing step-level evaluators are built on autoregressive language models. Because of their causal attention mechanism, these models can only evaluate a step based on the problem and the steps leading up to it.
However, humans don't just read math solutions strictly left-to-right when grading them; we often look ahead. An intermediate step might look perfectly plausible locally, but its flaws only become apparent when it leads to a contradiction or a failed derivation later in the proof.
As shown in Figure 1, an incorrect factorization initially satisfies some constraints but is completely exposed by later steps. Causal models are blind to this future evidence when evaluating earlier steps, creating a fundamental bottleneck in automated reasoning evaluation.
Methods
To isolate and validate the benefits of looking ahead, the authors first conducted a rigorous, controlled study at the 1B to 3B parameter scale. They trained models from scratch using the LLaDA (Large Language Diffusion Assistant) transformer architecture, keeping everything identical (data, hyperparameters, initialization) except for the self-attention mask:
- Causal variant: Restricted to attending only to current and past tokens.
- Bidirectional variant: Allowed to attend to the entire sequence (past and future).
After proving the bidirectional advantage, they scaled the approach up to create LLaDA-PRM by fine-tuning the pretrained LLaDA-8B-Base model. They replaced the standard language modeling head with a linear score head that outputs a three-way probability vector for each step: positive (correct and useful), neutral (valid but redundant), or negative (contains an error).
Datasets
- Training: The models were trained on PRM800K, a dataset containing human-annotated, step-by-step solutions to MATH problems. For the 1B-3B controlled grid, the authors constructed a label-balanced diagnostic subset to handle the natural positive-label skew.
- Evaluation: The authors evaluated full-trace error detection using three meta-evaluation benchmarks from the ReasonEval framework:
- MR-MATH-invalid: In-domain solutions that reach correct final answers but contain mid-trace errors.
- MR-GSM8K: An out-of-distribution subset to test cross-domain generalization.
- MR-MATH-redundant: Solutions containing valid but unnecessary steps.
- Downstream Application: MMIQC was used as a candidate pool for Supervised Fine-Tuning (SFT) data filtering, and the filtered models were evaluated on MATH-500.
Key Insights and Ideas
-
The Bidirectional Advantage Scales Up: At the 1B scale, causal and bidirectional models perform similarly. However, as model size increases to 2B and 3B, the bidirectional advantage emerges and widens significantly. Future context requires sufficient model capacity to be properly integrated.
Step-level test metrics on 1B/2B/3B models -
Resilience in Online Settings: Intuitively, a bidirectional model should suffer when evaluated "online" (i.e., step-by-step during generation, where future steps don't exist yet). Surprisingly, LLaDA-PRM experiences only a modest performance drop in online settings and still beats strong causal baselines, proving it learns robust step representations overall.
- Redundancy is a Powerful Filtering Signal: When using the evaluator to select high-quality data for training other models, filtering out redundant steps (unnecessary calculations) yielded a much stronger downstream performance boost than filtering solely based on step validity.
Key Results
LLaDA-PRM (8B) achieved outstanding results across the board, frequently outperforming the 34B parameter ReasonEval-Llemma model:
- Error Detection: On MR-MATH-invalid, LLaDA-PRM achieved a 88.8 Step-F1 score, outperforming ReasonEval-Llemma-34B by 11.3 F1 points. On the out-of-distribution MR-GSM8K dataset, it maintained its lead, outperforming the 34B baseline by 10.3 F1 points (see Figure 3).
- Online vs. Offline: Even without future context during online evaluation, LLaDA-PRM achieved an 84.9 Step-F1 on MR-MATH-invalid, remaining well above the causal baselines (see Figure 4).
- Downstream SFT Gains: Using LLaDA-PRM's redundancy-based filtering to select a 5,222-example training set for Mistral-7B led to a 22.5% accuracy on MATH-500, a +3.4 percentage point improvement over a size-matched random data selection baseline (see Figure 5).
Limitations and Future Work
While highly effective, the authors note a few limitations:
- Architecture Scope: The controlled experiments were restricted to the LLaDA diffusion architecture. It remains an open question whether applying bidirectional masking to standard autoregressive architectures (like LLaMA or Mistral) during fine-tuning yields identical benefits.
- Data Skew: The PRM800K dataset is heavily skewed toward positive labels (~80%), leaving very little supervision for the
neutral(redundant) class. This makes redundancy detection the least stable part of the evaluation system.
Future work includes exploring other discrete-diffusion backbones and developing better-balanced process supervision datasets to improve neutral-class classification.
Summary updated