Math word problem solver requires both precise relation reasoning about quantities in the text and reliable generation for the diverse equation. Current sequence-to-tree or relation extraction methods regard this only from a fixed view, struggling to simultaneously handle complex semantics and diverse equations. However, human solving naturally involves two consistent reasoning views: top-down and bottom-up, just as math equations also can be expressed in multiple equivalent forms: pre-order and post-order. We propose a multi-view consistent contrastive learning for a more complete semantics-to-equation mapping. The entire process is decoupled into two independent but consistent views: top-down decomposition and bottom-up construction, and the two reasoning views are aligned in multi-granularity for consistency, enhancing global generation and precise reasoning. Experiments on multiple datasets across two languages show our approach significantly outperforms the existing baselines, especially on complex problems. We also show after consistent alignment, multi-view can absorb the merits of both views and generate more diverse results consistent with the mathematical laws.
翻译:数学应用题求解器需要在文本中对数量进行精确关系推理,并可靠地生成多样化的方程。当前的序列到树或关系抽取方法仅从固定视角处理此问题,难以同时应对复杂语义和多样化的方程。然而,人类解题自然涉及两种一致的推理视角:自上而下与自下而上,正如数学方程也可以用多种等价形式表达:前序和后序。我们提出了一种多视角一致对比学习,以实现更完整的语义到方程映射。整个过程被解耦为两个独立但一致的视角:自上而下的分解与自下而上的构建,并通过多粒度对齐这两个推理视角以保持一致性,从而增强全局生成和精确推理。在跨两种语言的多个数据集上的实验表明,我们的方法显著优于现有基线,尤其是在复杂问题上。我们还证明,经过一致性对齐后,多视角能够吸收两种视角的优点,并生成更符合数学规律的多样化结果。