Maybe Only 0.5% Data is Needed: A Preliminary Exploration of Low Training Data Instruction Tuning

Hao Chen, Yiming Zhang, Qi Zhang, Hantao Yang, Xiaomeng Hu, Xuetao Ma, Yifan Yanggong, Junbo ZhaoarXiv 2023 · DOI

Abstract

Instruction tuning (IT) is a critical step in aligning Large Language Models (LLMs) with human intent, yet it typically requires massive datasets and significant computational resources. This paper explores Low Training Data (LTD) instruction tuning, questioning whether high-performance task specialization can be achieved with a fraction of the usual data. We propose a pipeline utilizing sentence embeddings, clustering, and KCenterGreedy coreset selection to identify the most representative samples for a target task. Our experiments on the Galactica-1.3b model using the P3 dataset demonstrate that tuning on just 0.5% of the data (16k instances) can outperform models trained on the full dataset. These results suggest that for specialized tasks, data quality and diversity coverage are more impactful than volume, offering a path toward more efficient LLM adaptation.

Introduction

The current paradigm in Large Language Model (LLM) development often follows a "bigger is better" philosophy, particularly regarding instruction tuning. Datasets like P3 or FLAN contain millions of examples, making the fine-tuning process prohibitively expensive. For instance, instruction-tuning a model like GPT-3 (Davinci) on the full P3 dataset could cost upwards of $7.5 million in API fees.

This research challenges the necessity of such massive data volumes for task specialization. We investigate whether identifying a "core" subset of samples can reduce training costs and improve efficiency without sacrificing—and potentially even improving—model performance on specific downstream tasks.

Methodology: The LTD Pipeline

To achieve efficient task specialization, we developed a pipeline designed to extract the most valuable samples from a massive general pool (like P3) for a specific target task (e.g., Natural Language Inference).

Overview of the Low Training Data (LTD) instruction tuning pipeline, from sentence embedding to model inference.

The pipeline consists of four primary stages:

  1. Sentence Embedding: Data is reformatted into instruction-style strings. We then use a pre-trained model (such as Galactica or BERT) to generate high-dimensional embeddings for each sample.
  2. Clustering: Using K-Means, we cluster these embeddings in a latent space. By analyzing the frequency of target task samples within these clusters, we identify the "center" or most relevant region for the specific task.
  3. Coreset Selection: Rather than selecting samples based solely on similarity to the center—which often leads to redundant data—we employ the KCenterGreedy algorithm. This approach selects a subset of points that best "covers" the entire distribution of the task data, ensuring both representativeness and diversity.
  4. Specialized Tuning: Finally, a base model (Galactica-1.3b) is fine-tuned on this tiny, curated "core" subset.

Data Selection and Formatting

The study primarily utilizes the Public Pool of Prompts (P3) as the source dataset. To prepare the data for the LTD pipeline, raw samples are converted into a natural language instruction format. This process transforms standard NLP tasks into a conversational or prompt-based structure that the LLM can process.

Comparison between original dataset samples and their instruction-tuned counterparts for Natural Language Inference (NLI) and Sentence Completion (SC).

Performance was evaluated across 11 datasets spanning four major categories: Natural Language Inference (NLI), Sentence Completion (SC), Word Sense Disambiguation (WSD), and Coreference Resolution (CR).

Experimental Results

The quantitative results, particularly in the NLI domain, provide strong evidence for the efficacy of the LTD approach. Using only 16,000 instances (approximately 1.9 million tokens), which represents just 0.5% of the total P3 dataset, the model achieved remarkable results:

  • Vanilla Model (0% IT): 39.19% average accuracy.
  • Full P3 Model (100% data): 54.06% average accuracy.
  • NLI Coreset Model (0.5% of P3): 56.64% average accuracy.
  • NLI-Related Model (5% of P3): 62.95% average accuracy.

Notably, the model trained on the 0.5% coreset outperformed the model trained on the entire P3 dataset by over 2.5%. When the data was expanded to include all NLI-related samples (5% of the pool), the performance boost reached nearly 9% over the full-dataset baseline.

Discussion and Key Insights

Several critical insights emerged from this exploration:

  • The "Noise" of Diversity: For task-specific models, training on a massive variety of unrelated tasks can be counterproductive. This extraneous diversity acts as noise that can degrade performance on the target task.
  • Instruction Minimalism: While general-purpose models require diverse prompt phrasing, task specialization often requires only a single, consistent instruction format. Adding more instruction types yielded diminishing returns in our experiments.
  • Coreset vs. Similarity: The failure of simple "Top-K similarity" selection highlights the importance of diversity. A model needs a subset that represents the boundaries and breadth of the task distribution (a Coreset) rather than just the most typical examples.

Conclusion

This preliminary exploration demonstrates that for LLM task specialization, "less is more" when the data is selected intelligently. By using a coreset-based selection method, we achieved superior performance with 200x less data than traditional instruction-tuning methods. Future work will focus on validating these "low data laws" across larger model scales (e.g., 70B+ parameters) and a broader array of complex NLP tasks.

Summary updated

Abstract

Instruction tuning for large language models (LLMs) has gained attention from researchers due to its ability to unlock the potential of LLMs in following instructions. While instruction tuning offers advantages for facilitating the adaptation of large language models (LLMs) to downstream tasks as a fine-tuning approach, training models with tens of millions or even billions of parameters on large amounts of data results in unaffordable computational costs. To address this, we focus on reducing the data used in LLM instruction tuning to decrease training costs and improve data efficiency, dubbed as Low Training Data Instruction Tuning (LTD Instruction Tuning). Specifically, this paper conducts a preliminary exploration into reducing the data used in LLM training and identifies several observations regarding task specialization for LLM training, such as the optimization of performance for a specific task, the number of instruction types required for instruction tuning, and the amount of data required for task-specific models. The results suggest that task-specific models can be trained using less than 0.5% of the original dataset, with a 2% improvement in performance over those trained on full task-related data.
BibTeX
@misc{chen2023maybe,
  author = {Hao Chen and Yiming Zhang and Qi Zhang and Hantao Yang and Xiaomeng Hu and Xuetao Ma and Yifan Yanggong and Junbo Zhao},
  title = {{Maybe Only 0.5\% Data is Needed: A Preliminary Exploration of Low Training Data Instruction Tuning}},
  year = {2023},
  eprint = {2305.09246},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2305.09246},
}
Figure