arXiv:2610.21950stat.MLOct 2026

Manuscript Offprint

arXiv:2610.21950

SelectPFN: Amortized Bayesian Variable Selection for Sparse Nonlinear Regression with Prior-Data Fitted Networks

Bin Luo

Abstract

Tabular foundation models based on prior-data fitted networks (PFNs) predict on a new data set in a single forward pass, but they cannot report which inputs their predictions depend on. We propose SelectPFN, a PFN that performs Bayesian variable selection and prediction jointly for sparse nonlinear regression Y=f(XS)+εY = f(X_S) + \varepsilon, in which the response depends on a small active set SS of the pp inputs, ∣S∣≪p|S| \ll p. Given a training set, SelectPFN returns posterior inclusion probabilities for every variable and predictive draws, each computed from a sampled subset only, so that excluded variables provably cannot affect the prediction. We show that this selection-restricted prediction is exactly what the Bayesian model prescribes. The network is pretrained once on synthetic tasks from a meta-prior built around a group spike-and-slab sparse-input neural network and needs no data-set-specific fitting. The column-permutation equivariance of the architecture, combined with a random interleaving of original and knockoff columns, yields knockoff statistics with exact finite-sample false discovery rate control even when the meta-prior is wrong. We also develop theory for what amortization can and cannot guarantee: a Bayes-regret bound for the amortized median probability model; a two-sided characterization showing that the information index nκj2/σ2n\kappa_j^2/\sigma^2 (sample size times the squared signal strength of the variable, divided by the noise variance) needed to detect a variable grows like (2/λj)log⁡(1/ω)(2/\lambda_j)\log(1/\omega), where ω\omega is the prior weight of structures able to use the variable as the truth does and λj≤1\lambda_j \leq 1 is an efficiency; and a negative result showing that average-case training does not transfer to frequentist guarantees at a fixed truth. On out-of-prior nonlinear designs with pp up to 500, SelectPFN improves the area under the precision-recall curve by 0.23–0.28 over the lasso, BART, DART, LassoNet and a group-penalized sparse neural network, and by 0.16 over TabPFN with permutation importance (all Holm-adjusted p<10−100p < 10^{-100}), at a false discovery proportion of about 0.07, in 0.04 seconds per data set (more than 300 times faster than DART). With real covariate matrices from four public data sets the advantage persists (0.17–0.26). With real responses, it selects about two variables, of which only 11% are known nulls, against 28–60% for competing methods. The theory is also borne out: giving interaction-only structures weight in the meta-prior, as the prior-weight law prescribes, raises detection of variables that act only through an interaction from 0.06 to 0.36, and to 0.52 with a larger network; in a controlled sweep of this prior weight alone, detection rises monotonically with it while the false-selection rate stays unchanged.

Keywords: amortized inference; Bayesian variable selection; high-dimensional regression; sparse nonlinear regression; prior-data fitted networks; tabular foundation models; model-X knockoffs; posterior inclusion probabilities.

1 Introduction

Identifying which of many candidate variables drive a response is a basic task of modern data analysis. It arises whenever the number of candidate predictors pp is comparable to or exceeds the sample size nn: in genomics, where thousands of gene-expression or genotype measurements are screened for association with a disease (Golub et al., 1999; Wu et al., 2009; Guan and Stephens, 2011); in medical imaging, where voxel-level or radiomic features are related to clinical outcomes (Grosenick et al., 2013; Lambin et al., 2017); in biomedical research more broadly, where high-dimensional covariates enter survival and risk models (Tibshirani, 1997); and in economics, where a few relevant controls must be chosen from many (Belloni et al., 2014). Given D={(xi,yi)}i=1nD = \{(x_i, y_i)\}_{i=1}^n with xi∈Rpx_i \in \mathbb{R}^p, the goal is both accurate prediction and the identification of a small subset of variables that carries the information about the response. The statistical theory of this regime is by now mature for linear models (Fan and Lv, 2008, 2010; Bühlmann and van de Geer, 2011; Hastie et al., 2015; Wainwright, 2019), and it has more recently been extended to nonlinear models: sparse additive models (Ravikumar et al., 2009; Meier et al., 2009), nonparametric regression with variable selection (Lafferty and Wasserman, 2008; Yang and Tokdar, 2015; Jiang and Tokdar, 2021), and sparse-input neural networks (Liang et al., 2018; Sun et al., 2022; Luo and Halabi, 2025). In applications, a selection method has to meet three needs at once. It must be flexible enough to capture nonlinear and interaction effects, because a variable that acts only through an interaction carries no linear signal. It must be fast and free of expert tuning, so that it can be applied routinely and to many data sets. And it must come with guarantees on false selections, so that the selected variables can be trusted.

Existing methods meet these needs only in part (Section 2). Penalized and Bayesian selection for linear models (Tibshirani, 1996; Fan and Li, 2001; Zhang, 2010; George and McCulloch, 1993; Ročková and George, 2018) is fast and well understood, but a variable that acts only through a nonlinear or interaction effect carries no linear signal and is missed. Sparse additive models (Lin and Zhang, 2006; Ravikumar et al., 2009), Bayesian regression trees (Chipman et al., 2010; Linero, 2018) and sparse neural networks (Lemhadri et al., 2021; Luo and Halabi, 2025; Sun et al., 2022) capture such effects, but each solves a new, tuning-sensitive optimization or sampling problem for every data set, which is slow when p is large and gives no finite-sample error control. Knockoffs (Barber and Candès, 2015; Candès et al., 2018) supply such control, but their power rests on a feature statistic that must itself be fitted to each data set. Tabular foundation models built on prior-data fitted networks (PFNs; Müller et al., 2022), such as TabPFN (Hollmann et al., 2023, 2025), remove per-data-set fitting altogether and predict in a single forward pass, but they use every column and cannot say which variables a prediction depends on, and the first amortized selectors (Alrawkan et al., 2026; Schiekiera et al., 2026) are restricted to linear models, and LinearPFN to few variables. What is missing is a selector for sparse nonlinear regression that is amortized, integrated with prediction, and equipped with guarantees that do not depend on how well the network was trained.

We propose SelectPFN, a PFN that performs Bayesian variable selection and prediction jointly. Selection in SelectPFN is integrated rather than post hoc: the predictor has the form y^∗=gθ(x∗,S^,DS^)\hat{y}_* = g_\theta(x_*, \hat{S}, D_{\hat{S}}) for a test point x∗x_*, where DS^D_{\hat{S}} keeps only the columns in S^\hat{S}, so a variable outside the selected set S^\hat{S} cannot influence the prediction. The network is pretrained once on synthetic regression tasks drawn from a sparse nonlinear meta-prior, built around a group spike-and-slab sparse-input neural network. For a new data set, one forward pass returns posterior inclusion probabilities (PIPs) for all variables. Subsets of variables are then drawn from these PIPs, a second pass predicts from the columns of each subset only, and the predictions are averaged over the subsets, which is Bayesian model averaging (BMA). This restriction is exactly what the Bayesian model prescribes, because given the active set the posterior predictive depends on the data only through the active columns. A knockoff mode adds exact finite-sample control of the false discovery rate (FDR) that holds whatever the network has learned. Because a trained network is a fixed map from data sets to PIPs, its analysis becomes a question about amortization: what a small training loss guarantees for selection, which variables can be found at all, and what cannot be guaranteed for a fixed truth. We answer these questions and evaluate the method in extensive simulations and on real data.