Synthetic Data for any Differentiable Target

2026-04-09Computation and Language

Computation and LanguageArtificial IntelligenceMachine Learning
AI summary

The authors introduce a method called Dataset Policy Gradient (DPG), which is a way to create special training data that can guide a language model to behave in certain ways. By carefully crafting these synthetic examples and fine-tuning the model, they can make the model learn specific patterns or properties, like embedding a QR code or changing how it represents information. Their technique uses advanced math to accurately figure out how changes in the training data affect the model’s outputs, allowing precise control over the model through artificial data alone. This shows DPG can flexibly shape model behaviors without needing real data examples.

reinforcement learningdataset policy gradientsynthetic training datasupervised fine-tuningdata attributionlanguage modelhigher-order gradientspolicy gradientmodel embeddingUUID
Authors
Tristan Thrush, Sung Min Park, Herman Brunborg, Luke Bailey, Marcel Roed, Neil Band, Christopher Potts, Tatsunori Hashimoto
Abstract
What are the limits of controlling language models via synthetic training data? We develop a reinforcement learning (RL) primitive, the Dataset Policy Gradient (DPG), which can precisely optimize synthetic data generators to produce a dataset of targeted examples. When used for supervised fine-tuning (SFT) of a target model, these examples cause the target model to do well on a differentiable metric of our choice. Our approach achieves this by taking exact data attribution via higher-order gradients and using those scores as policy gradient rewards. We prove that this procedure closely approximates the true, intractable gradient for the synthetic data generator. To illustrate the potential of DPG, we show that, using only SFT on generated examples, we can cause the target model's LM head weights to (1) embed a QR code, (2) embed the pattern $\texttt{67}$, and (3) have lower $\ell^2$ norm. We additionally show that we can cause the generator to (4) rephrase inputs in a new language and (5) produce a specific UUID, even though neither of these objectives is conveyed in the generator's input prompts. These findings suggest that DPG is a powerful and flexible technique for shaping model properties using only synthetic training examples.