Abstract
Solving math word problems (MWPs) requires complex reasoning, including natural language understanding, quantity extraction, and logical planning. Traditional neural solvers often treat this as a black-box translation task, mapping text directly to equations or answers, which limits interpretability. This paper introduces MathQA, a large-scale dataset of 37,259 problems annotated with executable operation programs. By employing a sequence-to-program (Seq2prog) model with domain categorization, the researchers achieve state-of-the-art results while providing a transparent reasoning path for each solution.
Introduction: The Challenge of Math Word Problems
Math word problems are a hallmark of human intelligence, requiring the synthesis of linguistic and mathematical reasoning. For an AI, a problem like "finding the radius of a circular region on a square poster" involves identifying geometric constraints and applying a sequence of formulas.
Existing research has been hindered by two primary issues. First, large datasets like AQuA-RAT are often noisy, containing unsolvable problems or rationales that do not logically lead to the answer. Second, most models lack interpretability; if a solver outputs an incorrect answer, it is difficult to diagnose whether the error occurred during language parsing or mathematical execution.
The MathQA Dataset and Representation Language
To address these gaps, the authors developed MathQA. This dataset enhances a subset of AQuA-RAT through rigorous human filtering and dense annotation. Each problem is mapped to a "program"—a sequence of mathematical operations chosen from a defined set of 58 primitives (e.g., circle_area, divide, sqrt).
This operation-based formalism serves as an intermediate representation that bridges the gap between natural language and final equations. As shown in the following figure, a complex geometry problem is broken down into a series of discrete, executable steps. This structure ensures that the model's "thought process" is both human-readable and verifiable.
Methodology: Seq2prog with Domain Categorization
The proposed architecture utilizes a sequence-to-program (Seq2prog) approach. The model consists of a bi-directional RNN encoder with attention that translates the word problem into the operation language.
A key innovation is the inclusion of a Domain Categorization layer. Before generating the program, the model classifies the problem into a specific domain, such as Geometry, Physics, or Gain-Loss. This classification acts as a "hard switch" for the decoder, pruning the search space by restricting the available operations to those relevant to the predicted category. This mimics human problem-solving, where identifying the type of problem (e.g., "this is a rate problem") precedes the selection of specific formulas.
Results and Insights
The Seq2prog + cat model demonstrated significant improvements over previous benchmarks:
- MathQA Accuracy: 54.2%
- AQuA Accuracy: 37.9% (surpassing the original 36.4% baseline despite using a smaller training set).
The results highlight that data quality is more critical than quantity in mathematical reasoning tasks. Furthermore, the domain categorization step proved vital; by forcing the network to make a categorical decision first, the accuracy of the subsequent operation sequence generation improved substantially. Despite these gains, a significant gap remains between model and human performance on these GRE-level problems, highlighting that deep logical reasoning remains challenging for current architectures.
Conclusion
MathQA represents a significant step toward interpretable AI in the mathematical domain. By moving away from black-box solvers and toward executable operation programs, the research provides a framework for diagnosing model failures and understanding the logic behind machine-generated solutions. Future work will focus on expanding the operation library to handle more complex logic and improving the model's "world knowledge" for diverse story-based scenarios.
Summary updated