InferenceEvolve: Automated Causal Effect Estimators through Self-Evolving AI
InferenceEvolve treats causal inference algorithms as full, modifiable Python programs and iteratively refines them using an evolutionary LLM loop guided by MAP-Elites. Across four classic causal benchmarks, it systematically outperforms standard packages and human entries—placing on the Pareto frontier against 58 human submissions in the ACIC 2022 competition. Furthermore, using cross-fitted doubly robust surrogate metrics, it can evolve high-performing estimators entirely from observed data without ground-truth counterfactuals.
Why Causal Estimation Resists Automation
In observational science and policy, we rarely want to know just correlations; we want to know what happens if we intervene. For any individual $i$, their treatment effect is defined as $\tau_i = Y_i(1) - Y_i(0)$. Yet the fundamental problem of causal inference guarantees that we can only observe one of these potential outcomes:
Because the true counterfactual is forever hidden in real observational data, human statisticians must make a complex constellation of choices: identifying assumptions (ignorability, overlap), estimation strategies (propensity weighting, outcome regression, or doubly robust learners), nuisance model selection, and clustered confidence interval calibration. A slight mistake in any component can lead to extreme bias or dangerously misleading confidence intervals.
Simultaneously, evaluating whether a novel estimator works is deeply paradoxical: how do you grade an algorithm when the ground truth can never be measured? While previous AI attempts have focused on narrow subtasks—like extracting causal graphs from text—none have tackled the open-ended design of complete, executable statistical programs that optimize identification, estimation, and uncertainty quantification simultaneously.
Scientific Programs as Evolving Genomes
InferenceEvolve casts causal estimation not as fixed parameter optimization, but as an evolutionary search across executable Python programs. Starting from zero-shot LLM-generated code templates, it leverages an ensemble of frontier LLMs (e.g., GPT-5, Gemini 3 Flash, Claude Sonnet) as intelligent mutation operators. Guided by a Quality-Diversity evolutionary algorithm (MAP-Elites) and evaluated through a fast two-stage cascade on replicated benchmark draws, the system iteratively evolves sophisticated estimators tailored to each dataset's unique latent mechanics. To bridge the gap to real-world applications where true counterfactuals do not exist, it derives cross-fitted doubly robust pseudo-outcomes as proxy reward signals, creating a closed-loop scientific discovery engine.
Inside the InferenceEvolve Engine
How LLMs navigate the combinatorial space of statistical estimation without overfitting or cheating.
1 The MAP-Elites Evolutionary Search Engine
Rather than maintaining a single line of descent, InferenceEvolve implements Multi-dimensional Archive of Phenotypic Elites (MAP-Elites). It partitions candidates into multi-island archives based on behavioral niches (balancing primary accuracy against secondary targets like coverage calibration or ATE precision). In each iteration, a parent is sampled from the archive alongside high-performing and diverse inspiration programs to construct a rich context prompt for candidate generation.
The framework operates over 100 iterations. Search-time scoring is strictly restricted to training replicates $D_{\text{train}}$, ensuring zero information leakage to held-out test replicates $D_{\text{val}}$.
To prevent slow or crashing code from halting the evolution, candidates pass through a two-stage cascade:
- Stage 1 (Filter): Runs on $\approx 10\%$ of replicates with 180s timeout. Scores $<0.001$ (syntax errors, NaN returns, dimension mismatches) are instantly pruned.
- Stage 2 (Full): Surviving candidates evaluate on all training replicates with an enforced 1,800s hard process termination.
MAP-Elites guides candidate insertion using a scalarized multi-objective criterion balancing primary estimation against secondary stability:
Regularization factor $\lambda \in \{0.2, 1.0, 5.0\}$ penalizes ATE error while preserving unit-level heterogeneity discovery.
2 Proxy Objectives: Evolving Without Ground Truth
In the real world, $Y_i(1)$ and $Y_i(0)$ are never observed concurrently. How can InferenceEvolve navigate toward high-fidelity estimators when true labels don't exist?
The authors derive cross-fitted doubly robust pseudo-outcomes following Kennedy (2024). Data is split into $K=2$ cross-fitting folds. Nuisance outcome functions $\hat{\mu}_t(x) = \mathbb{E}[Y \mid X=x, T=t]$ are fitted with Ridge & Gradient Boosting, while propensity scores $\hat{e}(x)$ are estimated via clipped logistic regression. The transformed pseudo-target for unit $i$ is:
The surrogate optimization objective combines three complementary signals: (1) DR pseudo-outcome distance $\sqrt{\text{PEHE}_{\text{proxy}}}$, (2) absolute error against the cross-fitted AIPW average treatment effect, and (3) normalized R-loss ($R_{\text{loss,norm}}$):
where $\phi(x) = \frac{\log(1+x)}{1 + \log(1+x)}$ provides robust monotonic compression.
Live Exploration of Evolution & Results
Hands-on tools to inspect evolved program code mutations, cross-benchmark tradeoffs, and proxy fidelity.
Benchmark Performance & Pareto Frontier Explorer
Showing 58 Human Competition Submissions vs. InferenceEvolve (Target: Min RMSE & Coverage $\to 0.90$).
Evolutionary Trajectory & Code Diff Inspector
# Loading diff...
Regularization $\lambda$ & Multi-Objective Selection Simulator
The search objective scalarizes primary heterogeneous treatment effect accuracy ($\sqrt{\text{PEHE}}$) with secondary average calibration error ($|\text{ATE err}|$):
Consistent Reductions in Error Across Benchmarks
All results evaluated on disjoint, untouched held-out validation replicates ($D_{\text{val}}$).
| Dataset | Metric | Strongest Package Baseline | Guidance Mode | Best Evolved | Mean ± SE | % Beat Baseline | Best Error Reduction $\Delta$ |
|---|---|---|---|---|---|---|---|
| IHDP | $\sqrt{\text{PEHE}}$ | 2.411 (BART) | True Score | 1.222 | 1.392 ± 0.021 | 100% | +49.3% |
| Proxy (No Truth) | 1.034 | 1.632 ± 0.311 | 83% | +57.1% | |||
| ATE Error | 0.110 (BART) | True Score | 0.063 | 0.081 ± 0.005 | 100% | +42.9% | |
| Proxy (No Truth) | 0.074 | 0.084 ± 0.003 | 100% | +33.0% | |||
| ACIC 2016 | $\sqrt{\text{PEHE}}$ | 1.283 (Causal Forest) | True Score | 0.858 | 1.011 ± 0.042 | 100% | +33.1% |
| Proxy (No Truth) | 1.504 | 2.037 ± 0.196 | 0% | -17.2% | |||
| ATE Error | 0.147 (Causal Forest) | True Score | 0.087 | 0.114 ± 0.011 | 100% | +40.6% | |
| Proxy (No Truth) | 0.156 | 0.170 ± 0.008 | 0% | -5.7% | |||
| LaLonde | Norm $\sqrt{\text{PEHE}}$ | 0.765 (BART) | True Score | 0.598 | 0.704 ± 0.016 | 83% | +21.8% |
| Proxy (No Truth) | 0.693 | 0.754 ± 0.017 | 67% | +9.4% | |||
| Norm ATE | 0.048 (Diff-in-means) | True Score | 0.033 | 0.057 ± 0.004 | 17% | +30.8% | |
| Proxy (No Truth) | 0.054 | 0.070 ± 0.005 | 0% | -12.6% | |||
| ACIC 2022 | SATT RMSE | 23.40 (Backdoor adj.) | True Score | 14.41 | 22.58 ± 2.39 | 50% | +38.4% |
| Proxy (No Truth) | 16.85 | 19.72 ± 1.33 | 83% | +28.0% |
Code & Conceptual Complexity Growth
Evolved code did not suffer from bloat or generic drift. While baseline programs had a median size of 54 lines (2,004 characters), true-evolved programs scaled up to a median of 104 lines (3,922 characters). Translating raw code into scientific methods paragraphs via GPT-5 confirmed that this represented genuine conceptual depth: methods descriptions grew from 172 words up to 263 words, describing cross-fitting, winsorization, and local propensity smoothing.
Convergence to Dataset-Specific Families
Rather than collapsing to a single generic template, the agents specialized:
- • ACIC 2022 (Panel): 21/24 converged on Two-Way Fixed Effects & DiD differencing.
- • ACIC 2016 (Cross-Section): 18/24 converged on X-Learners with random forest propensity weighting.
- • LaLonde (Observational): 13/24 synthesized DR-Learners, frequently hybridizing them with R-Learner residuals.
Limitations & Open Questions
The authors transparently discuss several key constraints and methodological boundaries:
Semi-synthetic benchmarks like IHDP or ACIC 2016 model synthetic response surfaces over real covariates. Exceptional performance on these benchmarks does not guarantee immunity to unmeasured confounding or extreme covariate overlap violations in real unconstrained data.
While proxy-guided optimization succeeded on IHDP, ACIC 2022, and LaLonde, it struggled on ACIC 2016 (-17.2% vs baseline). Optimal proxy surrogate design when true counterfactuals are inaccessible remains an active, unsolved challenge.
Baselines were standard package implementations (EconML, bartpy2). The study did not perform exhaustive benchmark-by-benchmark AutoML hyperparameter tuning for baseline packages; future work must evaluate evolved algorithms against tuned AutoML stacks.
Existing causal benchmark suites are strictly tabular. Benchmarks covering multimodal confounders (medical imaging, free-text clinical notes, genomics) remain scarce, preventing evolutionary search over high-dimensional unstructured estimators.
Glossary of Causal & Evolutionary Terminology
PEHE (Precision in Estimation of Heterogeneous Effect)
MAP-Elites (Multi-dimensional Archive of Phenotypic Elites)
Doubly Robust (DR) Estimator & Pseudo-Outcomes
X-Learner vs. R-Learner
SATT (Sample Average Treatment Effect on the Treated)
BibTeX Reference
@article{wang2026inferenceevolve,
title={InferenceEvolve: Automated Causal Effect Estimators through Self-Evolving AI},
author={Wang, Can and Zhao, Hongyu and Chen, Yiqun},
journal={arXiv preprint arXiv:2604.04274},
year={2026},
url={https://arxiv.org/abs/2604.04274}
}