TL;DR
PRODiGI (PROgram Discovery for Generative Inference) is a new tabular foundation model that transforms empirical data into executable generative programs in a single forward pass. By amortizing the cost of model fitting into pretraining, it achieves state-of-the-art density estimation and data generation with order-of-magnitude speedups over traditional iterative methods.
What Problem Does This Paper Address?
Probability density estimation—the task of figuring out the underlying distribution of a set of data points—is a cornerstone of statistical inference. Traditionally, this requires dataset-specific model fitting. Whether you are using classical methods like Gaussian Mixture Models (GMMs) or modern Neural Density Estimators (NDEs), you usually have to run an iterative optimization process (like the EM algorithm or gradient descent) for every new dataset you encounter. This is computationally expensive and often requires manual model selection.
While recent Tabular Foundation Models (TFMs) have shown great promise, they typically focus on downstream tasks like classification or regression. During pretraining, these models are often fed synthetic data generated from known "programs" (mathematical descriptions of distributions), but they discard these programs after the data is sampled. The authors of this paper ask: What if we trained a model to recover the program itself directly from the data?
Methods
The authors introduce PRODiGI, an encoder-decoder architecture designed for "data-to-program" inference.
- Data Encoder: It uses a Set Transformer to process an unordered collection of data points into a fixed-size representation. This ensures the model is permutation-invariant—the order of rows in your spreadsheet doesn't change the result.
- Program Serialization: The core innovation is representing complex statistical models (GMMs, Structural Causal Models, and Copulas) as structured, serialized "programs." These act like a domain-specific language that the model can "write."
- Non-Autoregressive (N-AR) Decoder: Unlike large language models that predict one token at a time, PRODiGI predicts all parts of the program template in parallel. This is faster and prevents "cascading errors" where one wrong token ruins the rest of the program.
- Program-Space Fine-Tuning: If the zero-shot program isn't perfect, PRODiGI can perform a unique type of fine-tuning. Instead of updating the 32.5 million parameters of the neural network, it keeps the model fixed and optimizes the few dozen parameters of the inferred program (e.g., shifting the means of a GMM) to better match the empirical data.
Datasets
The model was pretrained on a massive scale using 54 million distinct programs sampled from three diverse data priors:
- GMMs: Universal density approximators.
- Structural Causal Models (SCMs): Which capture causal relationships and non-linear dependencies.
- Copulas: Which allow for independent control over marginal distributions and correlation structures.
For evaluation, the authors used 96 synthetic datasets and 96 real-world datasets from the MacrOData and OddBench benchmarks, covering a wide range of dimensions (up to 50) and sample sizes.
Key Insights and Ideas
- Amortized Inference: The "hard work" of fitting a model is moved to the pretraining phase. At inference time, the model simply "recognizes" the pattern and outputs the answer, turning a slow optimization problem into a fast pattern recognition task.
- Interpretable Outputs: Unlike NDEs, which are "black boxes," PRODiGI outputs a human-readable program. You can inspect the inferred means, weights, and causal structures, making it highly valuable for high-stakes data analysis.
- The Power of N-AR: The authors found that autoregressive decoding (the standard for LLMs) is actually a poor fit for mathematical parameters. Since the entries of a mean vector are often independent, predicting them in parallel is not only faster but more robust.
- Decoupled Adaptation: Program-space fine-tuning is significantly more efficient than traditional fine-tuning. It requires much less memory and prevents the "catastrophic forgetting" often seen when tuning large neural networks.
Key Results
PRODiGI demonstrates a remarkable balance of speed and accuracy:
- Speed: In zero-shot mode, PRODiGI is roughly 8x faster than its closest competitors (like NNKDE), generating programs in just 0.06 seconds.
- Accuracy: It achieves lower average density and score errors (MAE) than existing pretrained models.
- Fine-Tuning Impact: Program-space fine-tuning reduced the Maximum Mean Discrepancy (MMD)—a measure of how well the generated data matches the real data—by a staggering 84%.
- Real-World Performance: Even on complex real-world manifolds that weren't exactly like the training priors, PRODiGI remained competitive, often outperforming models that were specifically designed for those tasks.
Limitations and Future Work
While a major step forward, the authors note several areas for growth:
- Continuous Only: The current version is restricted to continuous distributions and does not yet support categorical variables (like "City" or "Color").
- Prior Coverage: While GMMs, SCMs, and Copulas are expressive, they can't capture every possible real-world manifold. The authors suggest that expanding the library of supported "program families" will be key to improving performance on highly complex real-world data.
- High Dimensions: Like all density estimators, performance naturally degrades as the number of dimensions increases, though PRODiGI scales more gracefully than autoregressive competitors.
By turning empirical data into explicit, reusable programs, PRODiGI introduces a promising new direction for fast, interpretable generative modeling.
Summary updated