Agentic Distributional Regression: Conditional Density Estimation through Agent-Written Programs
Lorenzo Tedesco
Abstract
In this paper we propose a method for estimating conditional densities from an iid sample using a language-model agent. The agent writes the estimator as a short program that, for each covariate value, returns the estimated conditional distribution of the response. The program is built from a library of probability distributions, so the returned law can be a parametric distribution, a mixture or a multivariate factorization, with parameters given by explicit functions of the covariates. Since the number of operations and constants in the program is limited, the fitted conditional density is a formula that can be inspected and evaluated independently of the agent, while the choice of the model structure and of the fitting procedure is left to the agent. We call this approach agentic distributional regression (ADR). Treating the returned program as a random conditional density estimator, we derive a finite-sample error bound under explicit complexity and optimization assumptions, and an oracle inequality for selection using independent validation data. For a stably selected regular structure with sufficiently accurate fitting, we obtain asymptotic normality of the fitted constants. In simulation studies, on twelve real datasets and on a new dataset collected after the agents' training data, ADR with Claude Opus 5.5 has the best average performance among the methods considered.
Create a lesson
Related papers
A flexible approach to high-dimensional clustering and classification using mixtures of finite mutually repulsive mixtures
Alejandro Murua, Fernando Andrés Quintana
Practical Guidelines for Goodness-of-Fit Testing for Right-Censored Data
Arnau Gómez-Català, Guadalupe Gómez Melis, Klaus Langohr
Cost-based variable selection for prediction models
Lasai Barreñada, Andrew Vickers, Laure Wynants et al.
Penalized Cause-Specific Hazard Regression under Competing Risks: An Elastic Net Approach Using SANAD Trial Data
Avinash Kumar
Efficient Bootstrap Calibration of Generalized Posteriors with Importance Reweighting
Masahiro Tanaka
Estimation and Inference for One-pass Streaming Function-on-Function Regression
Shuyang Jiang, Xin Liu, Peijun Sang