Agent-Guided Discovery of Exchange-Correlation Functionals with Physics-based Validation
Authors: Achuth Chandrasekhar, Amir Barati Farimani
Organizations: Mechanical Engineering, Carnegie Mellon University, Pittsburgh, PA 15213, USA · Biomedical Engineering, Carnegie Mellon University, Pittsburgh, PA 15213, USA · Chemical Engineering, Carnegie Mellon University, Pittsburgh, PA 15213, USA · Materials Science and Engineering, Carnegie Mellon University, Pittsburgh, PA 15213, USA · Machine Learning Department, Carnegie Mellon University, Pittsburgh, PA 15213, USA
Accurate, compact exchange--correlation functionals are central to predictive density functional theory. Symbolic search and language-model agents can propose new functional forms, but it remains unclear whether their gains survive self-consistency and external evaluation, whether the new terms carry physical content, whether agents outperform evolutionary search, and how language-model backbones compare. We connect frontier LLM agents to a GPU evaluator through the Model Context Protocol, with training-only fitting, persistent memory, and self-consistent and external evaluation. Opus-5.5 agents passed the screening gate with about 40-fold fewer tokens than Codex (GPT-6-Astra) agents and found a candidate with lower validation and held-out errors; only this candidate advanced to self-consistent evaluation. The resulting 13-parameter functional, O159, multiplies same-spin correlation by a smooth density window. Refitted controls favor a window that scales the entire same-spin factor, reducing it by 15--30% at its peak, and that acts on reaction energies mainly in near-iso-orbital regions; against a refitted no-window control, it lowers heavy-atom total-energy errors on GSCDB137 by 29%. With about 400 fits each, SyFES evolution did not improve on its GAS22 seed, whereas the agents found forms 0.10--0.13 \kcal\ lower in validation error by adding an explicit density scale. Self-consistent O159 lowers the held-out MGCDB84 test error of ωB97M-V by 11.7%, and its mean normalized error ratio on 36 GSCDB137 datasets (1.139) is comparable to ωB97M-V (1.144) and below GAS22 (1.190). Frontier-LLM agents thus produced O159, a compact functional whose improvement over ωB97M-V survives self-consistent, physics-based validation.
Figures & tables
Figure 1: Workflow for agent-guided exchange–correlation functional discovery and evaluation. (a) A coordinator and thematic agent islands generate executable proposals, drawing on shared plans, lineages, results, and summaries. (b) The MCP server connects agents to the GPU evaluator, which fits coefficients on training data, measures validation WRMSD, and applies four screening checks: spin interchange, the uniform-gas exchange limit, exchange-factor scaling, and grid sensitivity. (c) Selected candidates and fitted parameters are frozen before held-out MGCDB84 testing, selected self-consistent-field validation, and external evaluation on the 36-dataset computational subset of GSCDB137. These downstream assessments are separate from discovery; their results were not used to fit, rank, or select candidates.
Figure 2: Agent responsibilities and communication during symbolic functional discovery. (a) The lead coordinator organizes thematic exchange, same-spin, opposite-spin, and parsimony roles. Shared records preserve plans, source code, fitted parameters, lineages, results, and summaries across agent contexts. (b) A schematic proposal–feedback cycle: an island retrieves context, records a plan and executable proposal, and calls the evaluator through MCP. The evaluator fits coefficients on training data, returns validation scores and four screening outcomes, and the island records a summary for subsequent review and proposals. The schematic shows agent roles and information flow through the proposal–evaluation cycle; held-out and external assessments remain outside this discovery loop.
Figure 3: Search-stage validation and the O159 density window. (a) Constraint-clean candidate scores and running minima from the retained Opus and Codex archives, indexed by database record ID. The displayed range emphasizes the competitive region; the archive retains all values and audit exclusions. (b) Analytic O159 multiplier at fixed kinetic descriptor, calculated from the evaluated coefficients. The radius refers to one spin density.
Search
Fits
Seed (val.)
Best new form
Training
Validation
GPU-h
Tokens (M)
SyFES evolution
400
GAS22 (3.462)
SyFES-174
3.444
3.506
61.1
0
Opus agents
397
refits a
O159
3.252
3.332
11.1
251
O396 b
3.140
3.138
Codex agents
400 c
refits a
C356
3.207
3.363
8.6
521
Table 1: Agent-guided and non-LLM symbolic search at a matched number of trained forms on the MGCDB84 SyFES split (non-SCF WRMSD, kcal mol -1 ).
Factor
Favors
Explicit density variable ρσ (or rsσ ) available; SyFES instructions act only on the scale-invariant x2=Xσ and w , from which τWσ/τσ and ασ follow
agents
Prompt listed rs -dependent correlation and τW/τ -based self-correlation corrections among example directions; reference sheet listed prior forms, including the multiplicative same- and opposite-spin rs corrections of SAFS26-b; second Opus campaign given window-related island themes
agents
Prompts quoted published validation and test errors of reference functionals and set beating GAS22 and SAFS26-a as a goal; no candidate test value was available during the first Opus campaign
agents
Category-resolved validation errors instead of a scalar fitness; warm starts from parent coefficients; screening penalty in the score
agents
Minimum taken on validation over repeated fits of the same form
agents
Seed is the validation minimum of the original 29,628-form search and keeps its published parameters, whereas children receive only a training-set CMA-ES fit
SyFES seed
Table 2: Differences between the two search workflows that bear on the comparison in Table 1 .
Functional
Mode
MGCDB84 val. b
MGCDB84 test b
GSCDB NER c
ω B97M-V
SCF
3.533
4.309
1.144
GAS22
non-SCF
3.462
3.599
1.212
GAS22
SCF
3.470
3.589
1.190
O159
non-SCF
3.332
3.818
1.141
O159
SCF
3.330
3.805
1.139
O396 a
non-SCF
3.138
3.841
1.147
Table 3: Performance on the MGCDB84 SyFES split and the 36-set GSCDB137 external-validation subset.
Figure 4: External-validation sensitivity to AE11. Left: mean NER for the 35-set scope without AE11 and the completed 36-set scope, with a truncated axis to resolve differences. Right: AE11 alone, an absolute heavy-atom energy dataset. O159 and GAS22 use SCF; O396 is non-SCF. Published reference rows are distinguished from the local ω B97M-V calculation. AE11 reduces the GAS22–O159 difference substantially, illustrating why the evaluated set membership must accompany aggregate ranks. Scope means are tabulated in Supporting Information Section S4.
Datasets
n
O178
O159
ω B97M-V
Δ
95% CI
p
New (primary)
20
1.312
1.270
1.290
−0.041
[−0.171,0.054]
0.55
New, without AE11
19
1.193
1.204
1.191
+0.011
[−0.046,0.072]
0.80
With MGCDB84 antecedents
16
1.036
0.979
0.961
−0.057
[−0.109,−0.010]
0.018
All
36
1.189
1.141
1.144
−0.048
[−0.121,0.011]
0.041
All, without AE11
35
1.122
1.101
1.086
−0.020
[−0.060,0.021]
0.067
Table 4: External test of the window against the refitted no-window control O178 on the GSCDB137 subset (non-SCF at ω B97M-V densities; mean NER, dimensionless). Δ is O159 minus O178; negative values favor the window.
Parameter
Value
Parameter
Value
a0
0.24549733
c0
1.14502582
a1
1.00304439
c1
3.75266635
b0
-4.69984961
c2
-3.35815548
b1
-4.88244588
c3
-10.59006317
b2
-1.96642642
c4
10.37863864
b3
7.80561285
β0
-0.25463509
Table S1: O159 fitted coefficients, rounded to eight decimal places.
Figure S1: Refitted ablations of the O145 density-window architecture. Each point uses a separate joint training fit; the dashed line denotes O145 validation error. Removing the window raises validation WRMSD by approximately 0.148 kcal mol -1 , while changing the cubic cutoff to the quartic O159 form gives nearly the same validation error. These comparisons do not isolate a term’s contribution at fixed coefficients. The analytic window shape is shown in the main manuscript rather than repeated here.
Functional
Mode
Δ train
Δ val.
Δ test
Δ NER 36
Δ NER 20
O159
non-SCF
−2×10−8
−4×10−7
+7×10−8
+3.1×10−5
+6.2×10−5
O159
SCF
−4.7×10−6
−6.4×10−5
+5.6×10−6
+3.2×10−5
+6.4×10−5
GAS22
non-SCF
−3×10−7
−9×10−7
−3.8×10−6
+5.0×10−5
+8.0×10−5
GAS22
SCF
+8.6×10−6
+8.7×10−6
+4.6×10−5
+5.1×10−5
+8.1×10−5
O396
non-SCF
−2×10−8
−3×10−7
+9×10−8
+4.0×10−5
+7.4×10−5
C356
non-SCF
−6×10−8
−3.7×10−6
+6.4×10−6
—
—
Table S2: Effect of correcting the large- a attenuation branch, using archived parameters and densities. MGCDB84 WRMSD changes are in kcal mol -1 ; GSCDB137 values are mean NER changes over 36 sets and over the 20 sets without MGCDB84 antecedents. SCF entries apply the first-order shift described in the text.
Record (parent)
Change relative to parent
Params
Train
Val.
Δ
O145 (O143)
reference architecture, h3 window
13
3.226
3.333
—
O159 (O145)
h3→h4
13
3.252
3.332
−0.001
O178 (O145)
window removed
11
3.386
3.481
+0.148
O185 (O178)
analogous window ( rs , wˉ ) on opposite-spin channel only
13
3.172
3.682
+0.201
O186 (O178)
one shared window on both channels
13
3.181
3.569
+0.088
O114 (O92)
total-density rs instead of rsσ
16
3.199
3.453
+0.074
Table S3: Refitted controls of the same-spin window (non-SCF, cached search metrics, kcal mol -1 ). Δ is the change in validation WRMSD relative to the parent.
Change
Record (parent)
ΔJval
Inference
Robust ( >0.09 kcal mol -1 )
Window removed
O178 (O145)
+0.148a
0.148 of O145’s 0.200 gain over ω B97M-V
Analogous window ( rs , wˉ ) on opposite-spin channel only
O185 (O178)
+0.201b
specific to same-spin correlation
Window on the uniform-gas same-spin term only ( ω B97M-V base)
O136 (O125)
+0.330
must scale the whole same-spin factor
Gate 1−τWσ/τσ (off in one-orbital regions)
O166 (O152)
+0.156
needed where τWσ/τσ is large
Gradient-corrected radius rsσ/(1+uσ)
O189 (O152)
+0.126
shifting the window to lower density at large gradient is harmful
Table S4: Classification of the refitted controls of the same-spin density window. ΔJval is the change in validation WRMSD (kcal mol -1 ) relative to the parent record; each row is a separate joint training fit recorded during the search. Peak positions refer to rsσ in bohr.
Table S5: O178 (refitted, no window) to O159: category contributions to ΔJ2 (kcal mol -1 2 ; negative values are improvements) and selected subset RMSDs (kcal mol -1 ).
Atom
O178
O159
Ewin
Atom
O178
O159
Ewin
H
2.25
2.98
−0.83
Ne
−9.90
−7.11
3.54
He
0.94
1.65
−2.62
Na
−7.44
−6.25
3.69
Li
0.62
2.51
−2.07
Mg
−10.66
−9.79
4.54
Be
−0.30
4.22
−0.32
Al
−6.85
−6.26
5.62
B
−1.74
4.81
0.66
Si
−1.74
−1.74
6.81
C
−5.38
1.54
1.72
P
5.48
4.48
8.22
Table S6: AE18 total-energy errors (calculated minus reference, kcal mol -1 ) for the refitted no-window control O178 and for O159, and the O159 window energy Ewin (kcal mol -1 ).
Split
Jon
Joff
JO178
0.37<rsσ<1.49
wσ≥0.3
Both
Electrons in both
Training
3.252
5.111
3.386
—
—
—
—
Validation
3.332
5.595
3.481
87%
82%
82%
4.9%
Test
3.818
7.188
3.865
88%
91%
91%
5.4%
Table S7: Window removal and localization of its effect. WRMSDs in kcal mol -1 ; shares are fractions of Jon2−Joff2 .
Functional
Ec (H)
ω B97M-V (published)
+4.11
GAS22 (published)
+4.36
O178 (refitted, no window)
+2.50
O145
+4.14
O159
+3.52
O159, window removed at fixed coefficients
+4.55
Table S8: Semilocal correlation energy of the exact hydrogen-atom density (kcal mol -1 ; exact value 0).
Dataset
Type
ω B97M-V
O159
NER ω B97M-V
NER O159
3d4dIPSS
TM
5.073
5.613
0.977
1.081
AE11
TC
368.86
295.66
3.154
2.528
ALKBDE10
TC
3.581
3.561
1.100
1.094
DAPD
TM
6.264
6.625
2.256
2.386
Dip146
EF
0.0365
0.0391
1.051
1.125
DIPCS9
TC
5.106
4.189
1.510
1.238
Table S9: GSCDB137 datasets without MGCDB84 antecedents: benchmark error measure and NER for local ω B97M-V SCF and O159 SCF.
Dataset
Type
O178
O159
δ
NER O178
NER O159
NER ω B97M-V
Prediction
Datasets without MGCDB84 antecedents
3d4dIPSS
TM
5.717
5.616
−1.8
1.101
1.081
0.977
—
AE11
TC
415.8
295.8
−28.9
3.555
2.529
3.154
better (l) ✓
ALKBDE10
TC
3.703
3.568
−3.6
1.138
1.096
1.100
—
DAPD
TM
7.054
6.632
−6.0
2.540
2.388
2.256
—
Dip146
EF
0.0375
0.0392
+4.6
1.079
1.128
1.051
—
Table S10: GSCDB137 per-dataset comparison of O159 with the refitted no-window control O178 (both non-SCF at the stored ω B97M-V densities). Error measures are the benchmark-specified metrics; δ is the relative change of the error measure from O178 to O159 (%). The ω B97M-V NER is the local SCF reference.
Functional
Mode
Train
Validation
Test
VT ¬RG10
ω B97M-V
SCF
3.319
3.533
4.309
3.867
GAS22
non-SCF
3.270
3.462
3.599
3.657
GAS22
SCF
3.264
3.470
3.589
3.664
O159
non-SCF
3.252
3.332
3.818
3.613
O159
SCF
3.253
3.330
3.805
3.607
Table S11: MGCDB84 SyFES: direct full-grid non-SCF and SCF WRMSDs (kcal mol -1 ).
Candidate
Parameters
Training
Validation
Test
O159
13
3.252
3.332
3.818
O396
10
3.140
3.138
3.841
O388
9
3.191
3.236
3.906
O376
12
3.230
3.294
3.961
C356
14
3.207
3.363
3.897
GAS22 refit (Codex)
12
3.266
3.489
3.628
Table S12: Selected cached non-SCF results on the SyFES split (kcal mol -1 ).
Functional
Training
Validation
Test
WRMSDtot
A. SAFS26 paper: reported non-SCF results
ω B97M-V
3.32
4.02
3.64
4.07
GAS22
3.27
3.74
3.19
3.77
SAFS26-x
2.91
3.95
3.49
3.81
SAFS26-a
2.76
3.65
3.41
3.70
SAFS26-b
2.75
3.78
3.44
3.83
Table S13: MGCDB84 comparison with SAFS26: reported and approximately matched splits (kcal mol -1 ).
Functional/mode
All 36
New 20
Without AE11 (35)
ω B97M-V published
1.135
1.285
1.077
ω B97M-V local SCF
1.144
1.290
1.086
O159 non-SCF
1.141
1.270
1.101
O159 SCF
1.139
1.269
1.099
O396 non-SCF
1.147
1.316
1.110
GAS22 non-SCF
1.212
1.344
1.227
Table S14: Mean GSCDB137 NER on the evaluated subsets (dimensionless).
Form
Params
Train
Validation
Violations
Failed test
GAS22 (seed, published)
14
3.2702
3.4623
1
uniform-gas exchange
SyFES-174
14
3.4441
3.5057
0
—
SyFES-55
14
3.2690
3.5542
1
uniform-gas exchange
SyFES-699
14
3.2072
3.5554
1
uniform-gas exchange
SyFES-1244
14
3.1896
3.5655
1
uniform-gas exchange
SyFES-30
14
3.1934
3.5683
1
uniform-gas exchange
Table S15: SyFES baseline: float64 re-evaluation of the seed and the ten best forms (stored parameters, kcal mol -1 ).
Scope
Records
Input
Output
Cache read
Cache write
Total
Opus
397
0.002
1.500
244.909
5.010
251.421
Opus, omit ID 201
396
0.002
1.285
200.864
3.743
205.893
Codex
401
7.852
1.028
512.494
0
521.374
Superseded Codex
200
0.829
0.128
31.136
0
32.094
Table S16: Assigned non-SCF tokens, in millions except record counts.
Figure S2: Token charges by database record ID for the retained runs: 397 Opus and 401 Codex attempts. Rows show total, output, and cumulative charges. The first two use symmetric-log axes that retain zeros; cumulative axes are linear. The Opus ID 201 inter-campaign charge and Codex failure 213 are included. Input and cache components are available for every record in the companion CSV files.
Figure S3: Token distributions and composition. Distribution panels (a,b) omit Opus ID 201 and omit zero charges on logarithmic axes; bars indicate nonzero medians. Composition panel (c) includes all charges, including ID 201. The arithmetic means in the text include zero-charge records within each stated scope.
Figure S4: Cumulative assigned tokens versus best constraint-clean validation WRMSD. All charges enter the horizontal axis, including Opus ID 201 and Codex failure 213. Values above 3.9 kcal mol -1 are outside the displayed range but remain in the archive. Passing evaluator checks is distinct from passing later source/parsimony audits. No held-out test or external metric updates the curves.
The development of accurate exchange-correlation (XC) functionals remains a longstanding challenge in density functional theory (DFT). The vast majority of XC functionals have been hand designed by human researchers combining physical insight, exact constraints, and empirical fitting. Recent advances in large language models enable a systematic, automated alternative to this human-driven design loop. This report presents an agentic search system in which an LLM proposes structured functional-form changes guided by evolutionary history. The system attempts to improve functional performance through an iterative plan-execute-summarize loop, where improvements are measurable by optimizing functional parameters against a standard thermochemistry dataset, then evaluating performance on a held-out subset. The strongest discovered functional, SAFS26-a (Seed Agentic Functional Search 2026), improves upon the gold-standard ωB97M-V baseline by ~9%. These results also surface a cautionary lesson for AI-assisted science: models powerful enough to discover genuine improvements are equally capable of exploiting unphysical shortcuts to game the benchmark; domain expertise translated into explicitly enforced constraints remains essential to keeping results scientifically grounded.
Titouan Duston, Jiashu Liang, Yuanheng Wang +6
ByteDance Seed · Princeton University · Work done at ByteDance Seed
Exchange--correlation functionals are trained mainly on energies, and their densities often degrade as their energies improve. We present a supervised-learning algorithm that trains functionals on energies and accurate densities without self-consistent-field (SCF) solutions. From one Fock build at a fixed accurate density, it predicts the density that the functional would reach self-consistently and penalizes its deviation from the reference; for functionals linear in their parameters, training is convex. Refitting the MN15 form to 1,500 reaction energies under a constraint on 98 coupled-cluster densities gives the density-constrained hybrid DCH-D4. On 19 held-out energy sets its mean normalized error ratio is 0.96, against 1.76 for MN15, and on 145 densities outside the fit its mean density error is 22 times lower than that of MN15. Deep-learning neural GGA and meta-GGA functionals (NN-GGA and NN-mGGA) trained on only 6 energies and 11 densities lower the atomization-energy error on 103 molecules from 14.6 to 5.6kcal/mol relative to PBE and from 3.7 to 3.3kcal/mol relative to SCAN, while roughly halving the density error of each base functional. Accurate densities can thus enter functional training at the scale of modern energy databases.
Yuhao Chen, Donald G. Truhlar, Xiao He
Shanghai Engineering Research Center of Molecular Therapeutics and New Drug Development, Shanghai Frontiers Science Center of Molecule Intelligent Syntheses, School of Chemistry and Molecular Engineering, East China Normal University, Shanghai 200062, China · Department of Chemistry, Chemical Theory Center, and Minnesota Supercomputing Institute, University of Minnesota, Minneapolis, Minnesota 55455-0431, USA · Anhui Provincial Key Laboratory of Advanced Catalysis and Energy Materials, Anhui Ultra High Molecular Weight Polyethylene Fiber Engineering Research Center, School of Chemistry and Chemical Engineering, Anqing Normal University, Anqing 261433, China +1
Machine-learned (ML) exchange-correlation (XC) functionals aim to replace human-designed density functional approximations by learning directly from reference data, but they still do not consistently outperform traditional O(N4)-scaling hybrid functionals. We study a hybrid-distillation setting in which O(N3)-scaling ML-XC functionals are trained to reproduce B3LYP/def2-SVP targets. We introduce Derivative Informed XC-Loss (DI-Loss), a loss that incorporates additional information from the reference hybrid functional by supervising first and second derivatives of the energy on the Grassmannian of admissible density matrices. Rather than only matching the self-consistent fixed point, DI-Loss aligns the local first- and second-order response of the learned functional with that of the target functional. Across four evaluated architectures, DI-Loss consistently improves the main energy metrics. Averaged uniformly across architectures, the total-energy MAE decreases by 66% relative to energy and density supervision alone. The density-sensitive mean-field energy metric Eρ improves from 1.2 to 0.8 mEh on average, while dipole and L2 density errors do not improve uniformly. We further show that densities from the distilled functionals reduce hybrid-functional SCF iterations by up to 50%. In downstream TDDFT calculations, Hessian supervision improves excited-state predictions, with XCdiff reducing the mean excitation-energy MAE by 19 - 35%.
Eike S. Eberhard, Luca A. Thiede, Abdul Aldossary +5
Technical University of Munich, Munich, Germany · Munich Data Science Institute, Munich, Germany · Munich Center for Machine Learning, Munich, Germany +4