Abstract
Solving algebraic word problems requires executing a series of arithmetic operations—a program—to obtain a final answer. However, since programs can be arbitrarily complicated, inducing them directly from question-answer pairs is a formidable challenge. To make this task more feasible, we solve these problems by generating answer rationales, sequences of natural language and human-readable mathematical expressions that derive the final answer through a series of small steps. Although rationales do not explicitly specify programs, they provide a scaffolding for their structure via intermediate milestones. To evaluate our approach, we have created a new 100,000-sample dataset of questions, answers and rationales. Experimental results show that indirect supervision of program learning via answer rationales is a promising strategy for inducing arithmetic programs.
Introduction
Algebraic word problems present a unique challenge for artificial intelligence, requiring both natural language understanding and mathematical reasoning. A system must translate a narrative into a formal mathematical representation and then execute a sequence of operations to reach a solution. Traditional "black box" neural models often struggle with this task because the underlying mathematical "program" is typically hidden, with only the final answer provided for training. Mapping complex sentences directly to a single numerical value is a significant hurdle, often resulting in models that provide answers without explaining their reasoning.
Methodology
The proposed approach utilizes a sequence-to-sequence (Seq2Seq) framework that treats rationales as a latent bridge between the question and the answer.
Instruction-Based Generation
Rather than simply predicting text, the model generates a series of instructions (e.g., Add, Multiply, Choose). These instructions can draw arguments from the input text, previous outputs, or a dedicated memory buffer. This hybrid decoding process allows the model to "copy" numbers from the question and "execute" operations to derive new values that never appeared in the original text.
Rationale as Scaffolding
The model is trained to produce human-readable rationales—step-by-step explanations that break down the problem into manageable intermediate milestones. Because the specific programs are not explicitly provided in the training data, a heuristic search is employed to identify the most likely instruction sequences that align with the target rationale. To handle the significant length of mathematical rationales, the authors implemented "staged back-propagation," processing sequences in smaller chunks to avoid memory bottlenecks while preserving global context.
Dataset Construction
To support this research, a large-scale benchmark was developed consisting of over 100,000 algebraic word problems. The dataset began with 34,000 "seed" problems from GMAT and GRE test-prep materials. Crowdsourcing via Amazon Mechanical Turk was then used to generate nearly 70,000 "replica" problems, ensuring a diverse and robust training set for evaluating program induction.
Experimental Results
The model was evaluated against several state-of-the-art Seq2Seq baselines, including those equipped with "copy" mechanisms.
The results demonstrate a substantial performance gain. While standard Seq2Seq models achieved approximately 20% accuracy—comparable to random guessing on a 5-option multiple-choice test—the proposed model reached 36.4%. Furthermore, the model showed superior fluency, with significantly improved BLEU scores and lower perplexity, indicating that its generated explanations closely mirror human reasoning.
Conclusion
This work highlights that rationales are not merely post-hoc explanations but are essential latent variables that guide the model's computation. The "scaffolding" provided by step-by-step text is critical; without it, the search space for mathematical paths remains too unconstrained for effective learning. While word problems remain a challenging frontier, this research suggests that teaching machines to "explain their work" is a fundamental requirement for complex reasoning tasks.
Summary updated