[Paper Review] GPT Can Solve Mathematical Problems Without a Calculator
The paper demonstrates that a 2B-parameter MathGLM model can perform multi-digit arithmetic and math word problems with high accuracy without external tools, closely rivaling or surpassing GPT-4 on several tasks, using step-by-step training and curriculum strategies.
Previous studies have typically assumed that large language models are unable to accurately perform arithmetic operations, particularly multiplication of >8 digits, and operations involving decimals and fractions, without the use of calculator tools. This paper aims to challenge this misconception. With sufficient training data, a 2 billion-parameter language model can accurately perform multi-digit arithmetic operations with almost 100% accuracy without data leakage, significantly surpassing GPT-4 (whose multi-digit multiplication accuracy is only 4.3%). We also demonstrate that our MathGLM, fine-tuned from GLM-10B on a dataset with additional multi-step arithmetic operations and math problems described in text, achieves similar performance to GPT-4 on a 5,000-samples Chinese math problem test set. Our code and data are public at https://github.com/THUDM/MathGLM.
Motivation & Objective
- Challenge the assumption that LLMs cannot perform multi-digit arithmetic without calculators.
- Develop MathGLM to excel in arithmetic operations and math word problems through step-by-step reasoning.
- Show that curriculum learning and dataset design enable large gains in mathematical accuracy.
- Compare MathGLM's performance with GPT-4 and other LLMs across arithmetic tasks and math word problems.
Proposed method
- Train a decoder-only Transformer (MathGLM) on a large arithmetic dataset with step-by-step solutions to teach calculation rules.
- Use curriculum learning to gradually increase numeric digit ranges up to 12 digits.
- Fine-tune GLM family backbones on math word problems using a reconstructed Ape210K dataset with step-by-step solutions.
- Evaluate arithmetic tasks with accuracy and relative error thresholds on a dedicated test set.
- Compare MathGLM variants (10M–2B parameters) against GPT-4, ChatGPT, and other LLMs across multiple datasets.
Experimental results
Research questions
- RQ1Can a language model perform complex multi-digit arithmetic without external calculators?
- RQ2Does a step-by-step (chain-of-thought-like) training strategy enable reliable arithmetic reasoning in LLMs?
- RQ3How does MathGLM perform on math word problems versus standard arithmetic tasks compared to GPT-4?
- RQ4What is the impact of model size and curriculum data on multi-digit arithmetic accuracy?
Key findings
- MathGLM achieves 93.03% accuracy on a complex arithmetic test with 2B parameters, surpassing GPT-4 (18.84%).
- Smaller MathGLM variants (e.g., 10M) outperform GPT-4 and ChatGPT on several arithmetic tasks.
- Arithmetic performance improves with larger model size and more training data according to scaling analyses.
- Step-by-step solution strategy significantly improves math word problem accuracy over directly fine-tuning on the original dataset.
- MathGLM with 5–12 digit generalization shows higher accuracy than GPT-4 and ChatGPT on multi-digit arithmetic tasks.
- On BIG-bench arithmetic tasks, MathGLM generally outperforms GPT-4, especially in higher-digit scenarios.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.