MathDivide: Improved mathematical reasoning by large language models

Saksham Sahai Srivastava, Ashutosh Gandhi
5/12/2024
cs.CLcs.AI

No confident code implementation found for this paper. 7 possible matches can be shown below.

Abstract

Large language models have been proven to be capable of handling complex linguistic and cognitive tasks. Therefore their usage has been extended to tasks requiring logical reasoning ability such as Mathematics. In this paper, we propose a prompting technique called MathDivide that breaks down the mathematical problem into simpler subproblems. Each of the subproblems is formulated as an algebraic expression whose value is evaluated by the Python code generated by the LLM for the corresponding algebraic expression. The values fed to the Python code are the numerical values provided in the problem statement. The solutions for the subproblems are composed together to obtain the final answer for the problem statement. Finally, the final answer is compared to the correct answer. If the final answer matches the correct answer, it is produced as output else a refinement prompt is fed to the LLM. We experiment with this prompting technique on both closed-source LLM models and open-source LLM models using GSM8K dataset. The results obtained demonstrate that MathDivide was able to significantly outperform the leading prompting technique called Math-prompter.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 7 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{srivastava2024mathdivide,
  title  = {MathDivide: Improved mathematical reasoning by large language models},
  author = {Saksham Sahai Srivastava and Ashutosh Gandhi},
  year   = {2024},
  eprint = {2405.13004},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2405.13004v1}
}

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/2405.13004.svg)](https://codeofpaper.com/paper/2405.13004)

Discussion