arXiv:2610.29530stat.MLOct 2026

Manuscript Offprint

arXiv:2610.29530

Residual-Based Causal Discovery via Pretrained In-Context Quantile Regression

Daniel Klippert, Quang Nhat Huynh, Alexander Marx

Abstract

Residual-based causal discovery assumes that each variable is generated from its parents and an independent noise source. It estimates this noise and tests its independence from candidate causes. For identifiable functions such as additive-noise models (ANMs) and the broader class of location-scale noise models (LSNMs), this principle identifies the causal direction, as only the causal model admits this independence. Existing LSNM methods rely on parametric assumptions to obtain standardized residuals, risking model misspecification. In contrast, the RESIT-framework allows for nonparametric estimation of residuals to iteratively identify sink nodes, but was proposed for ANMs. To close this gap, we propose LOSCAR, an extension of RESIT to LSNMs that estimates the conditional mean and scale via quantile regression, enabling pretrained tabular foundation models as plug-in estimators. We compare it with a feasible generalized least squares (FGLS) variant, which is consistent given suitable basis functions. Across bivariate and multivariate causal-discovery benchmarks, in-context quantile regression substantially outperforms FGLS with flexible function classes, particularly for multivariate causes.

1. Introduction

Causal discovery provides a rigorous framework to determine under which conditions causal relations can be derived from observational data (Spirtes et al., 2000; Peters et al., 2017). Provided that all relevant sources of variation are observed, i.e., it can be assumed that confounding and selection bias are absent, and no cyclic relations exist, the causal graph can be described as a directed acyclic graph (DAG).

Constraint-based approaches rely on conditional independence testing to recover the Markov equivalence class (Spirtes et al., 2000), whereas methods restricting the function class of the structural causal model identify the unique DAG. Early approaches showed identifiability of the DAG under linear non-Gaussian additive models (Shimizu et al., 2006, LiNGAM). Both the linearity assumption (Hoyer et al., 2008) and the additivity assumption have been relaxed by subsequent works that prove identification results for post-nonlinear (Zhang & Hyvärinen, 2009, PNL) and location-scale noise models (Immer et al., 2023; Strobl & Lasko, 2023, LSNMs).

Alongside this line of research, another promising direction involves amortized approaches to causal discovery (Lorch et al., 2022; Petersen et al., 2023), which treat causal discovery as a supervised machine learning problem by training on a large corpus of synthetically generated data. Benefiting from the advantages of transformer models (Thompson et al., 2026) or the success of tabular foundation models (Xu et al., 2026), these approaches are scalable and show strong empirical results. These works aim to encode known identification results through drawing the training data from such data generative models, however, they lack formal guarantees and require extensive pretraining.

Our Contributions Taking a different approach, we integrate pretrained tabular foundation models (Hollmann et al., 2023) as plug-in estimators. Our method, LOSCAR, extends the well-studied RESIT algorithm (Peters et al., 2014) to LSNMs. In contrast to previous work on LSNMs that rely on distributional assumptions on the noise variable (Immer et al., 2023; Duong & Nguyen, 2023; Tran et al., 2024; Klippert & Marx, 2026) or symmetric noise variables (Lin et al., 2024) we show that nonparametric estimation is feasible by estimating the conditional standard deviation via quantile regression. This result enables us to harness the predictive capabilities of pretrained tabular foundation models such as TabPFN (Hollmann et al., 2023) through in-context quantile regression without the need of retraining or fine-tuning the model. We propose two strategies through quantile

1^{1}Department of Statistics, TU Dortmund University, Germany 2^{2}Research Center Trustworthy Data Science and Security, University Alliance Ruhr, Germany 3^{3}Department of Economics, University of Münster, Germany. Correspondence to: Daniel Klippert daniel.klippert@tu-dortmund.de, Alexander Marx alexander.marx@tu-dortmund.de.

Preprint. October 22, 2026.

Figure

Figure 1. Accuracy in % over 19 bivariate benchmarks. LOSCAR and LOSCAR-GL use TabPFN for in-context quantile regression, computing the conditional scale using different variants (Section 3.1). LOSCAR-FGLS (Section 3.2) employs spline-based FGLS. LOSCAR has an average accuracy of 90.04%. While LOSCAR-GL performs on par, the FGLS variant struggles to model complex location-scale relationships.

regression and compare them to a variant using feasible GLS (Greene & Zhang, 2000) which given appropriate basis functions consistently estimates the conditional mean and standard deviation without distributional assumptions. Through empirical evaluation on 19 bivariate benchmarks we show that LOSCAR using in-context quantile regression achieves state-of-the-art performance and outperforms the FGLS variant on flexible function classes (Figure 1). Further, we evaluate LOSCAR on multivariate simulated and real-world benchmarks obtaining competitive results while being scalable in low and medium dimensional settings.

We first review LSNMs and their estimation through conditional mean and variance in Section 2, followed by a description of LOSCAR. In Section 3.1, we derive two approaches that enable in-context quantile regression and describe the FGLS variant in Section 3.2. We discuss related work in Section 4, present experiments in Section 5, and conclude thereafter.

References (80)