Papers › Common 7B Language Models Already Possess Strong Math Capabilities

Common 7B Language Models Already Possess Strong Math Capabilities

7 Mar 2024arXiv:2403.04706archive 2025-07-28

Chen Li, Weiqi Wang, Jingcheng Hu, Yixuan Wei, Nanning Zheng, Han Hu, Zheng Zhang, Houwen Peng

Mathematical capabilities were previously believed to emerge in common language models only at a very large scale or require extensive math-related pre-training. This paper shows that the LLaMA-2 7B model with common pre-training already exhibits strong mathematical abilities, as evidenced by its impressive accuracy of 97.7% and 72.0% on the GSM8K and MATH benchmarks, respectively, when selecting the best response from 256 random generations. The primary issue with the current base model is the difficulty in consistently eliciting its inherent mathematical capabilities. Notably, the accuracy for the first answer drops to 49.5% and 7.9% on the GSM8K and MATH benchmarks, respectively. We find that simply scaling up the SFT data can significantly enhance the reliability of generating correct answers. However, the potential for extensive scaling is constrained by the scarcity of publicly available math questions. To overcome this limitation, we employ synthetic data, which proves to be nearly as effective as real data and shows no clear saturation when scaled up to approximately one million samples. This straightforward approach achieves an accuracy of 82.6% on GSM8K and 40.6% on MATH using LLaMA-2 7B models, surpassing previous models by 14.2% and 20.8%, respectively. We also provide insights into scaling behaviors across different reasoning complexities and error types.

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2403.04706")

Code

Syntology Ran 6 of 28 code samples harvested from 2 repositories linked to this paper; 22 have no recorded run. Of those that ran: 1 ran · our draft was wrong; 5 ran with no contract checked.

By repository: official repository: 12 samples from 1 repository, 6 ran; community (archive-listed): 16 samples from 1 repository, 0 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

xwin-lm/xwin-lm officialmentioned in papermentioned on GitHubpytorch report
jerrywu-code/susgen mentioned on GitHubpytorchMIT report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

28 samples harvested; 6 ran; 0 honoured the contract we drafted; 22 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

1ran · our draft was wrong
5ran
22unverified

Licence: 12 of the 28 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from 2 repositories linked to this paper, official or community; each sample names its own and says which. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

extract_text xwin-lm/xwin-lm/Xwin-Coder/HumanEval/humaneval_gen.py official repository ran · our draft was wrong fingerprinted no licence file found · pointer only · 7a733b18081436f3 · report
find_indentation xwin-lm/xwin-lm/Xwin-Coder/APPS/reindent.py official repository ran no licence file found · pointer only · f05983c38acfa250 · report
generate_prompt xwin-lm/xwin-lm/Xwin-Coder/DS1000/ds1000_gen.py official repository ran fingerprinted no licence file found · pointer only · 2763cff93674bd85 · report
generate_prompt xwin-lm/xwin-lm/Xwin-Coder/HumanEval/humaneval_gen.py official repository ran fingerprinted no licence file found · pointer only · 34de3c98b4c4ccf0 · report
import_source_file xwin-lm/xwin-lm/Xwin-Coder/DS1000/ds1000ds.py official repository ran no licence file found · pointer only · 4557da831202481d · report
replace_inline_tabs xwin-lm/xwin-lm/Xwin-Coder/APPS/reindent.py official repository ran no licence file found · pointer only · 27f23c533d62061a · report
change_format xwin-lm/xwin-lm/Xwin-Coder/DS1000/ds1000_gen.py official repository unverified no licence file found · pointer only · b26735c9048e647a · report
get_model xwin-lm/xwin-lm/Xwin-Coder/HumanEval/humaneval_gen.py official repository unverified no licence file found · pointer only · 15a54731c6978e32 · report
get_model xwin-lm/xwin-lm/Xwin-Coder/MBPP/mbpp_gen.py official repository unverified no licence file found · pointer only · 54ff8bf66412b359 · report
get_question xwin-lm/xwin-lm/Xwin-Coder/APPS/testing_util.py official repository unverified no licence file found · pointer only · ed8331339b4de97c · report
get_solutions xwin-lm/xwin-lm/Xwin-Coder/APPS/testing_util.py official repository unverified no licence file found · pointer only · 0c83bb0f43b8dc57 · report
get_valid_problems xwin-lm/xwin-lm/Xwin-Coder/APPS/testing_util.py official repository unverified no licence file found · pointer only · 8bbb265e59e23293 · report
documentMetadata_loader jerrywu-code/susgen/utils/extractText_sus.py community (archive-listed) unverified MIT (permissive) · ce0b6e5c855875fc · report
extract_answer jerrywu-code/susgen/eval/code/eval_finqa.py community (archive-listed) unverified MIT (permissive) · 30e951ff25cd61d7 · report
extract_numbers jerrywu-code/susgen/eval/code/eval_finqa.py community (archive-listed) unverified MIT (permissive) · 72dfc5e9d73fa763 · report
generate_text jerrywu-code/susgen/src/template.py community (archive-listed) unverified MIT (permissive) · aa963276f597a210 · report
inference jerrywu-code/susgen/src/lora_inference.py community (archive-listed) unverified MIT (permissive) · 5adc840cfa3cba8a · report
instr_prompt jerrywu-code/susgen/src/template.py community (archive-listed) unverified MIT (permissive) · cd3318f643f2b529 · report
llama3_short jerrywu-code/susgen/src/utils/prompt_template.py community (archive-listed) unverified MIT (permissive) · 836aab9d5828036c · report
load_datasets jerrywu-code/susgen/utils/loadhf_data.py community (archive-listed) unverified MIT (permissive) · 43fd4e86eac55a80 · report
load_json jerrywu-code/susgen/src/finetune.py community (archive-listed) unverified MIT (permissive) · b3cd6beeda0e0909 · report
load_jsonl jerrywu-code/susgen/utils/process_v1.py community (archive-listed) unverified MIT (permissive) · 991cad3f55659f76 · report
load_lora jerrywu-code/susgen/src/lora_inference.py community (archive-listed) unverified MIT (permissive) · 5acbb99c75b740a1 · report
load_model jerrywu-code/susgen/src/template.py community (archive-listed) unverified MIT (permissive) · c87d1b4488a54c82 · report
mistral_formal jerrywu-code/susgen/src/utils/prompt_template.py community (archive-listed) unverified MIT (permissive) · c09691f510dbbb2a · report
mistral_short jerrywu-code/susgen/src/utils/prompt_template.py community (archive-listed) unverified MIT (permissive) · 46788756dee21d65 · report
time_logger jerrywu-code/susgen/src/batch_inference.py community (archive-listed) unverified MIT (permissive) · 1efc261c7054e106 · report
tokenize jerrywu-code/susgen/src/finetune.py community (archive-listed) unverified MIT (permissive) · 448dfa384a102a35 · report

Tasks

GSM8KMath

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

BASESFT

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections