Metabolomics studies routinely compare a few dozen patients against a few dozen controls using hundreds to thousands of measured molecules. They then ask a supervised projection method which molecules separate the groups. The standard tool is OPLS-DA (orthogonal partial least squares discriminant analysis, a linear method that finds one direction in molecule space that best separates the classes and sets aside other structured variation as "orthogonal" noise). With far more molecules than samples, this direction is poorly determined. It can latch onto noise, and the resulting biomarker lists shift with small preprocessing changes. The method also knows nothing about chemistry: a loading vector that says "metabolite A goes up and its direct product B also goes up for no reason" is treated the same as one that follows how metabolism actually works.
We propose to borrow the central move of physics-informed machine learning, which is to route the model's output through a fixed, known physical operator, and apply it to the discriminant direction itself. Concretely, the class-separating direction of OPLS-DA is restricted to be a sparse combination of columns of the stoichiometric matrix. Each such column is one biochemical reaction: substrates negative, products positive. The class difference must then be explained as "these few reactions were shifted." Structured variation unrelated to class is left free to absorb batch and technical effects. The output is a short list of candidate perturbed reactions rather than a list of correlated molecules. The main empirical question is whether this prior makes small-cohort findings more reproducible than generic sparsity or pathway-graph smoothing. If it does not, the stoichiometric structure is not earning its place.
Core Claim
In a cohort of $N$ samples with an autoscaled, annotated metabolite matrix $X \in \mathbb{R}^{N \times P}$ and class vector $y$, ordinary PLS picks a weight vector $w$ maximizing $\mathrm{cov}(Xw, y)$. We instead parameterize the predictive weight as $w = S r$. Here $S \in \mathbb{R}^{P \times R}$ is the stoichiometric matrix of $R$ reactions linking the measured metabolites, and $r \in \mathbb{R}^{R}$ is a sparse vector of reaction weights:
$$\max_{r}\ \mathrm{cov}(X S r,\, y) - \lambda \lVert r \rVert_1 \quad \text{subject to } \lVert S r \rVert_2 = 1 .$$
The orthogonal components are then extracted from the residual of $X$ in the usual unconstrained way, giving the decomposition $X = T_p P_p^T + T_o P_o^T + E$ (Yan Yang et al.). Only the predictive block is constrained. Variation that does not fit the reaction structure can still be modeled, but it cannot be credited with separating the classes.
The claim is that this hard constraint gives three things on cohorts of 20 to 50 samples. First, biomarker and reaction lists that are more stable across bootstrap resamples and across preprocessing variants. Second, held-out discrimination at least as good as unconstrained OPLS-DA. Third, better recovery of a known perturbed enzyme in simulation. Crucially, these gains must come from the substrate–product sign structure of $S$, not merely from reducing the dimension.
We should be honest about the physics. At metabolic steady state, pool sizes are not literally $S$ times a flux change. The constraint encodes a weaker, first-order hypothesis: shifting one enzyme's activity mainly moves its own substrates and products, in opposite directions. The prior is therefore a testable structural hypothesis, not a conservation law, and the experiments are designed so that it can fail.
Relation to Prior Work
The mechanism comes from the "fixed differentiable physical decoder" idea. The Explainable Physical PolSAR Autoencoders for Soil Moisture Estimation paper forces a radar model's bottleneck through electromagnetic scattering equations. It pays a small in-distribution cost (reported RMSE 7.11% versus 6.37% for a black-box model on CROPEX 2014) in exchange for following physical trends on the out-of-distribution HTERRA 2022 campaign. In our method the linear operator $S$ plays the role of that decoder. Unlike that work, our method is supervised, linear, and includes an explicit orthogonal-noise block.
The choice of a hard rather than soft constraint is motivated by reports that loss-penalty physics can be bypassed during optimization. The survey Physics-informed machine learning and Discussing the spectrum of physics-enhanced machine learning both describe competing data and physics loss terms that require manual balancing. The penalty-based grey-box approach of PhyLSTM works for a low-dimensional cooling system. We test a soft variant only as an ablation.
On the statistics side, the gap is documented rather than assumed. OPLS-DA studies such as the DDH lipidomics study (N=50) and the gastric cancer multi-omics study (N=29) flag small cohorts and purely correlational findings as limitations. TraceMetrix shows that preprocessing choices substantially change differential-metabolite lists.
Two negative results constrain the design. MetaBench reports that automated cross-database identifier mapping is extremely unreliable: below 1% exact match without retrieval and about 40% with retrieval. We therefore cannot assume that $S$ is built correctly and must measure sensitivity to mapping errors. The agarwood GC-MS study (Visualization OPLS class models) already reaches $Q^2 = 0.997$. On such easy, well-separated problems no prior can help, so that dataset serves only as a sanity check that the constraint does not hurt.
Research Program
We will construct $S$ for the annotated features of each dataset from curated reaction databases, keeping reactions in which at least one substrate and one product are measured. Mapping will be done by hand plus database lookup, and every identifier decision will be logged.
Because $w = Sr$, the constrained problem is sparse PLS on the reaction-difference features $XS$. This makes the method simple to implement, easy to audit, and directly comparable to existing sparse PLS code. Orthogonal components follow the standard OPLS residual filtering on $X$.
Two variants test how rigid the prior should be. In the first, a per-metabolite positive rescaling $w = DSr$ absorbs differences in mass-spectrometry response factors, which would otherwise distort the substrate–product balance. In the second, unannotated features enter through a separate, heavily penalized unconstrained block. This addresses the fact that most untargeted features have no known identity.
Variable importance in projection (VIP, the standard score of how much each variable drives the discriminant direction) will be reported at two levels. At the reaction level we report the magnitudes of $r$. At the metabolite level we report VIP computed from $Sr$, so the method remains comparable to existing biomarker lists.
Baselines
The naive reference point is unconstrained OPLS-DA with a 200-permutation test, run on identical preprocessed matrices. It represents what nearly every paper in the file does. It is also the only baseline with reported results on these data, although none is a held-out predictive metric. On MTBLS2627 TraceMetrix reports 116 differential metabolites but no AUC or $Q^2$ (TraceMetrix), so there is no reported predictive result on Lacuna for OPLS-DA on MTBLS2627. On the DDH cohort, the best reported single-marker AUC is 0.917 for TAG(17:0/18:1/20:1) (DDH lipidomics). That figure is in-sample, so we will treat it as an upper-bound reference rather than a target.
The strongest competitor is sparse PLS-DA with an L1 penalty directly on metabolite weights. It is the most direct answer to overfitting when molecules outnumber samples. We will run it with the same nested cross-validation and the same grid size for $\lambda$ and component count as our method.
The second strong competitor is network-smoothed PLS-DA. It penalizes differences between loadings of metabolites that share a reaction, using a graph Laplacian penalty built from the same reaction set. This baseline uses exactly the same prior knowledge as our method but encodes "neighbors move together" instead of "substrates and products move oppositely." Beating it is what would show that the sign structure of stoichiometry matters.
Two ablations isolate the key ingredient. The first replaces $S$ with a random matrix that has the same shape and the same sparsity pattern per column but random signs. The second replaces $S$ with a degree-preserving shuffle of which metabolites share reactions. The soft-constraint version, which penalizes the distance of $w$ from the column space of $S$, tests the hard-versus-soft question.
Beating a baseline means one thing here. Bootstrap Jaccard stability of the top-k list must be higher, with a 95% bootstrap interval excluding zero difference. At the same time, held-out AUC must not be worse by more than 0.02. Only the real $S$, not its randomized versions, should produce the gain.
Why not just…?
Why not just run standard OPLS-DA and map VIP > 1 hits to pathways afterward? Post-hoc enrichment treats the hit list as an unordered set. It cannot prevent the projection from selecting chemically incoherent combinations. It also inherits the instability of the list itself, and TraceMetrix documents strong preprocessing sensitivity. Our preprocessing-variant experiment directly compares list stability under both workflows. If post-hoc enrichment yields equally stable pathway-level conclusions, our advantage reduces to reaction-level resolution, and we will report it that way.
Why not just use a lasso logistic regression on the reaction-difference features $XS$? This is a real threat. Mathematically it is close to our predictive block without the orthogonal filtering. We include it as a baseline. If it matches our method, then the contribution is the reaction-space representation, not its placement inside OPLS. We would say so and simplify the recommendation accordingly. The orthogonal block should matter most on MTBLS2627, which includes quality-control samples that let us estimate technical drift. We will test exactly that.
Why not just build a kinetic model or do flux balance analysis? Kinetic models need rate parameters and absolute concentrations that untargeted mass spectrometry does not provide. The surveys note that white-box models are hard to calibrate and invert from noisy high-dimensional data (Physics-informed machine learning). Our method uses only the topology and signs of $S$, which is the part of mechanistic knowledge that survives relative, unscaled measurements.
Why not just use graph-smoothed sparse PLS? It is the same knowledge with a different encoding, so it is the decisive comparison rather than a dismissal. If it matches us on stability and on simulated enzyme recovery, the opposite-sign hypothesis is not supported.
Proposed Experiments
The primary benchmark is MetaboLights MTBLS2627: 57 controls, 52 intrahepatic cholestasis patients, and 18 QC samples. It is public and larger than the clinical cohorts in the file, and its reported hits concentrate in bile secretion and tryptophan metabolism, which have well-curated stoichiometry. We repeatedly subsample training cohorts of 20, 30 and 50 and evaluate on the untouched remainder. Metrics are held-out AUC and $Q^2$, and bootstrap Jaccard stability of the top-20 metabolites and reactions. We also measure agreement between the subsampled lists and the list fitted on the full cohort.
The preprocessing-robustness check reruns the pipeline under a grid of normalization and missing-value imputation settings, following the parameters TraceMetrix exposes, and measures cross-setting list agreement.
Mapping sensitivity is tested by randomly reassigning 5–30% of identifier mappings in $S$ and tracking how quickly the advantage decays. This directly probes the grounding fragility reported by MetaBench.
A simulation provides ground truth. We will build a small kinetic model of tryptophan and bile-acid reactions ourselves, perturb one enzyme per "disease" class, add realistic noise and batch effects, and ask each method to rank the perturbed reaction. This is the setting where the substrate–product hypothesis is guaranteed to hold. A second simulation, where the perturbation is a non-local regulatory effect, shows how the method fails when the hypothesis does not hold.
If the DDH lipidomics and gastric cancer data can be obtained from their authors, they serve as small-N replication cohorts. The agarwood GC-MS data serves only to confirm that the constraint does not degrade an already-saturated $Q^2$.
The decisive check is simple. On subsampled MTBLS2627 and in the local-perturbation simulation, real-$S$ reaction-space OPLS-DA must beat both network-smoothed PLS and the random-sign ablation of $S$ on stability and on reaction recovery. It must also keep held-out AUC within 0.02 of unconstrained OPLS-DA. Otherwise the stoichiometric prior is not contributing and we will report a negative result.
References
- Microbiota and metabolites alterations in proximal and distal gastric cancer patients
- Explainable Physical PolSAR Autoencoders for Soil Moisture Estimation
- Physics-informed machine learning
- Discussing the spectrum of physics-enhanced machine learning: a survey on structural mechanics applications
- Physics-Informed LSTM Network for Flexibility Identification in Evaporative Cooling System
- Plasma Lipidomics Profiling of Developmental Dysplasia of the Hip in Tibet Plateau
- TraceMetrix: a traceable metabolomics interactive analysis platform
- MetaBench: A Multi-task Benchmark for Assessing LLMs in Metabolomics
- Visualization OPLS class models of GC-MS-based metabolomics data for identifying agarwood essential oil extracted by hydro-distillation