arXiv:2411.07681cs.LG2024-11被引 25

通过训练初期准确率揭示大模型推理泛化能力,指导数据优化。

What Do Learning Dynamics Reveal About Generalization in LLM Reasoning?

  • 用训练前的准确率衡量模型是否真理解而非死记硬背。
  • 该指标在多个模型和数据集上预测测试准确率的R²超过0.9。
  • 可指导数据筛选,提升1.5到2倍的数据使用效率。

尽管现代大语言模型表现出色,但其解决问题的机制仍不清晰。本文聚焦推理任务,区分记忆(复制训练数据中的推理步骤)与真实性能(答案正确性)。我们提出一个名为‘预记忆训练准确率’的指标,即模型在开始复制训练步骤前对训练样本的准确率。该指标在不同模型(Llama3 8B、Gemma2 9B)、数据集(GSM8k、MATH)和训练配置下,对测试准确率的预测能力均达到或超过0.9的R²。在个体样本层面,该指标还能反映模型预测对训练输入扰动的鲁棒性。通过连接学习行为与泛化表现,该指标可用于优化训练策略。以数据筛选为例,优先选择低预记忆准确率的样本,使数据效率提升1.5至2倍,优于i.i.d.数据扩展和其他标准数据筛选方法。

原文摘要 · Abstract (English)

Despite the remarkable capabilities of modern large language models (LLMs), the mechanisms behind their problem-solving abilities remain elusive. In this work, we aim to better understand how the learning dynamics of LLM finetuning shapes downstream generalization. Our analysis focuses on reasoning tasks, whose problem structure allows us to distinguish between memorization (the exact replication of reasoning steps from the training data) and performance (the correctness of the final solution). We find that a model's generalization behavior can be effectively characterized by a training metric we call pre-memorization train accuracy: the accuracy of model samples on training queries before they begin to copy the exact reasoning steps from the training set. On the dataset level, this metric is able to reliably predict test accuracy, achieving $R^2$ of around or exceeding 0.9 across various models (Llama3 8, Gemma2 9B), datasets (GSM8k, MATH), and training configurations. On a per-example level, this metric is also indicative of whether individual model predictions are robust to perturbations in the training query. By connecting a model's learning behavior to its generalization, pre-memorization train accuracy can guide targeted improvements to training strategies. We focus on data curation as an example, and show that prioritizing examples with low pre-memorization accuracy leads to 1.5-2x improvements in data efficiency compared to i.i.d. data scaling, and outperforms other standard data curation techniques.

大模型推理泛化分析数据效率

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。