TL;DR
Computing exact data values (like Shapley values) to find the most useful training data is notoriously expensive, but many applications only need to identify the top-$m$ most valuable data points. This paper introduces GPGapE, an algorithm that uses Gaussian Processes to model the non-linear relationship between data features and values, efficiently finding the top-$m$ points. By further evaluating points only on small data subsets, the method achieves up to a 50x speedup over existing baselines, making it highly practical for tasks like noisy data detection and LLM fine-tuning.
The Challenge of Data Valuation
Data valuation methods, particularly Data Shapley, are used to quantify how much individual data points contribute to a machine learning model's performance. This is incredibly useful for pricing data, debugging (finding mislabeled or noisy data), and selecting high-quality subsets for training.
However, calculating exact Shapley values requires training models on all possible subsets of the data ($n!$ combinations), which is computationally intractable for real-world datasets. Fortunately, most practical applications don't need the exact value of every data point; they just need to identify the $m$ points with the highest values (the "top-$m$" points).
Previous attempts to solve this framed it as a "top-$m$ arm identification" problem using Multi-Armed Bandits (MAB). But these existing methods either ignore the actual features of the data entirely, or they assume a strictly linear relationship between data features and data values. For complex data like images or text, this linear assumption completely breaks down, leading to poor efficiency and accuracy.
Proposed Method: GPGapE
To overcome these limitations, the authors propose GPGapE (Gaussian Process Gap Exploration), an algorithm that adapts linear bandit techniques but replaces the linear model with a Gaussian Process (GP).
- Gaussian Process Modeling: By using a GP, the algorithm can model highly complex, non-linear mappings from data features to data values. It relies on the intuition that data points with similar features will likely have similar Shapley values.
- Gap Index: GPGapE actively selects which data points to evaluate by calculating a "gap index"—an upper confidence bound on the difference in value between a point currently in the top-$m$ candidate set and a point outside of it. It focuses computational budget on borderline points rather than wasting time on obviously good or obviously bad data.
- GPGapE-Small (Acceleration via Small Subsets): The authors exploit the "diminishing returns" property of ML models: adding a data point to a small dataset changes performance much more than adding it to a massive dataset. Because marginal contributions on large subsets are tiny, computing them is mostly wasted effort. GPGapE-Small only queries marginal contributions on small subsets (e.g., $\le 10\%$ of the total data). The authors mathematically prove that finding the top-$m$ points on these small subsets is equivalent to finding them on the full dataset, drastically cutting down model training time.
Key Insights and Ideas
- Features predict value, but not linearly: Data points that look similar in feature space contribute similarly to model performance. Modeling this relationship allows the algorithm to infer the value of unqueried points, but you must use a non-linear model (like a GP) to capture this accurately for complex data.
- Diminishing returns are a computational shortcut: Because the impact of a data point shrinks as the training set grows, you don't need to evaluate points across subsets of all sizes. Truncating the subset size preserves the relative ranking of the top-$m$ points while slashing the computational complexity of model training.
- Adaptive querying beats random sampling: Standard approximation methods (like Monte Carlo) sample permutations randomly. GPGapE adaptively zeroes in on the "boundary" between the $m$-th and $(m+1)$-th ranked points, ignoring data that is clearly in or clearly out of the top-$m$.
Key Results
The authors evaluated GPGapE across image classification datasets (MNIST, FashionMNIST, CIFAR10) and NLP benchmarks (TYDIQA for LLAMA-2-7B fine-tuning).
- Massive Query Efficiency: To achieve the same recall in identifying the top-1000 data points, GPGapE-Small required 50x fewer queries compared to existing baselines like Monte Carlo, KernelSHAP, and Stratified sampling.
- Wall-Clock Speedup: By querying only small subsets, GPGapE-Small runs nearly 2x faster in actual computation time compared to the standard GPGapE algorithm.
- Noisy Data Detection: GPGapE and GPGapE-Small consistently outperformed all baselines in identifying injected noisy data (images with added Gaussian noise) across the vision datasets.
- LLM Fine-Tuning: When applied to select data for fine-tuning LLAMA-2-7B, GPGapE found a 5% data subset that outperformed the full dataset using only 21.7% of the computation required by the state-of-the-art LESS data selection method.
Limitations and Future Work
The performance of the Gaussian Process relies heavily on the quality of the input data features. While the authors successfully used PCA for logistic regression and hidden layer representations for neural networks, finding the optimal feature representation remains an open challenge. Future work could focus on better selection methods for these GP data point features or approximating the utility function itself to further accelerate the algorithm without fully training a model for every query.
Summary updated