Neural-Symbolic Solver for Math Word Problems with Auxiliary Tasks

Jinghui Qin, Xiaodan Liang, Yining Hong, Jianheng Tang, Liang Lin
7/3/2021
cs.CL

Official code: QinJinghui/NS-Solver (19 stars, Python, last commit 2022-07-15).

Abstract

Previous math word problem solvers following the encoder-decoder paradigm fail to explicitly incorporate essential math symbolic constraints, leading to unexplainable and unreasonable predictions. Herein, we propose Neural-Symbolic Solver (NS-Solver) to explicitly and seamlessly incorporate different levels of symbolic constraints by auxiliary tasks.

Show full abstract

Our NS-Solver consists of a problem reader to encode problems, a programmer to generate symbolic equations, and a symbolic executor to obtain answers. Along with target expression supervision, our solver is also optimized via 4 new auxiliary objectives to enforce different symbolic reasoning: a) self-supervised number prediction task predicting both number quantity and number locations; b) commonsense constant prediction task predicting what prior knowledge (e.g. how many legs a chicken has) is required; c) program consistency checker computing the semantic loss between predicted equation and target equation to ensure reasonable equation mapping; d) duality exploiting task exploiting the quasi duality between symbolic equation generation and problem's part-of-speech generation to enhance the understanding ability of a solver. Besides, to provide a more realistic and challenging benchmark for developing a universal and scalable solver, we also construct a new large-scale MWP benchmark CM17K consisting of 4 kinds of MWPs (arithmetic, one-unknown linear, one-unknown non-linear, equation set) with more than 17K samples. Extensive experiments on Math23K and our CM17k demonstrate the superiority of our NS-Solver compared to state-of-the-art methods.

View on arXivView PDF

Code Implementations(1)

193PythonMay 26, 20214 years ago

Similar Papers

Cite this paper

@article{qin2021neuralsymbolic,
  title  = {Neural-Symbolic Solver for Math Word Problems with Auxiliary Tasks},
  author = {Jinghui Qin and Xiaodan Liang and Yining Hong and Jianheng Tang and Liang Lin},
  year   = {2021},
  eprint = {2107.01431},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2107.01431}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2107.01431.svg)](https://codeofpaper.com/paper/2107.01431)

Discussion