Scaling Relationship on Learning Mathematical Reasoning with Large Language Models

Zheng Yuan, Hongyi Yuan, Chengpeng Li, Guanting Dong, Keming Lu +3 more
8/3/2023
cs.CL

No official code found. Best implementation: OFA-Sys/gsm8k-ScRel (270 stars, last commit 2024-09-12).

Abstract

Mathematical reasoning is a challenging task for large language models (LLMs), while the scaling relationship of it with respect to LLM capacity is under-explored. In this paper, we investigate how the pre-training loss, supervised data amount, and augmented data amount influence the reasoning performances of a supervised LLM. We find that pre-training loss is a better indicator of the model's performance than the model's parameter count. We apply supervised fine-tuning (SFT) with different amounts of supervised data and empirically find a log-linear relation between data amount and model performance, and we find better models improve less with enlarged supervised datasets. To augment more data samples for improving model performances without any human effort, we propose to apply Rejection sampling Fine-Tuning (RFT). RFT uses supervised models to generate and collect correct reasoning paths as augmented fine-tuning datasets. We find with augmented samples containing more distinct reasoning paths, RFT improves mathematical reasoning performance more for LLMs. We also find RFT brings more improvement for less performant LLMs. Furthermore, we combine rejection samples from multiple models which push LLaMA-7B to an accuracy of 49.3\% on GSM8K which outperforms the supervised fine-tuning (SFT) accuracy of 35.9\% significantly.

View on arXivView PDF

Code Implementations(1)

OFA-Sys/gsm8k-ScRelCommunity100%

Codes and Data for Scaling Relationship on Learning Mathematical Reasoning with Large Language Models

27019Shell, PythonAug 4, 20232 years ago

Similar Papers

Cite this paper

@article{yuan2023scaling,
  title  = {Scaling Relationship on Learning Mathematical Reasoning with Large Language Models},
  author = {Zheng Yuan and Hongyi Yuan and Chengpeng Li and Guanting Dong and Keming Lu and Chuanqi Tan and Chang Zhou and Jingren Zhou},
  year   = {2023},
  eprint = {2308.01825},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2308.01825v2}
}

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

Discussion