Symbol-Aware Reasoning with Masked Discrete Diffusion for Handwritten Mathematical Expression Recognition
Takaya Kawakatsu, Ryo Ishiyama
TL;DR
This work reframes handwritten mathematical expression recognition (HMER) as a discrete diffusion process that iteratively refines symbols and two-dimensional structure, rather than generating LaTeX tokens autoregressively. It introduces Symbol-Aware Tokenization (SAT) to align visible symbols with per-symbol modifiers and Random-Masking Mutual Learning (RMML) to enforce cross-view consistency under masking, together yielding robust structural reasoning. Empirical results on MathWriting and CROHME show state-of-the-art performance, with a MathWriting CER of $5.56\%$ and EM of $60.42\%$, and consistent improvements across CROHME editions, including a 2023 EM of $60.78\%$. The approach demonstrates a new paradigm for structure-aware recognition beyond generative models, balancing accuracy, stability, and efficiency in offline HMER.
Abstract
Handwritten Mathematical Expression Recognition (HMER) requires reasoning over diverse symbols and 2D structural layouts, yet autoregressive models struggle with exposure bias and syntactic inconsistency. We present a discrete diffusion framework that reformulates HMER as iterative symbolic refinement instead of sequential generation. Through multi-step remasking, the proposal progressively refines both symbols and structural relations, removing causal dependencies and improving structural consistency. A symbol-aware tokenization and Random-Masking Mutual Learning further enhance syntactic alignment and robustness to handwriting diversity. On the MathWriting benchmark, the proposal achieves 5.56\% CER and 60.42\% EM, outperforming strong Transformer and commercial baselines. Consistent gains on CROHME 2014--2023 demonstrate that discrete diffusion provides a new paradigm for structure-aware visual recognition beyond generative modeling.
