Held-Out-Line Critics for Automated Molecular Spectral Fitting

Cold molecular hydrogen, the gas that forms stars, cannot be seen directly. Astronomers therefore infer it from weak radio lines of companion molecules such as hydroxyl (OH) and methylidyne (CH). These lines are faint and blended with each other. They also sit on top of instrument artifacts: ripples in the receiver's spectral baseline and drifts in calibration. As fitting becomes automated, with neural networks trained on synthetic spectra, a familiar machine learning failure appears. A fitter optimized against a fixed quality score learns to "explain" instrument ripples as extra gas clouds, because doing so improves the score. This is the same pattern as reward hacking in language-model alignment, where a policy exploits blind spots of a frozen judge.

The fix from alignment research is to keep updating the judge on the policy's own current outputs. This note proposes the physical version of that idea. The critic that scores spectral fits is retrained online, on the fitter's own solutions. Its labels come from a signal that instrument artifacts cannot fake: whether a fit to some transitions correctly predicts a transition it was not shown. The central question is whether this adaptive critic reduces spurious line detections under unfamiliar artifacts better than a well-built static Bayesian fit. If it does not, that negative result is itself informative.

Core Claim

The claim has three parts. First, when an automated fitter (the "policy") decomposes multi-transition spectra into velocity components, a fixed goodness-of-fit score can be exploited by baseline systematics. Second, a critic trained on the fitter's current outputs can learn to recognize solutions whose residuals track instrument nuisance shapes. Third, the labels for that training can come from held-out-transition consistency rather than from human judgment or majority vote.

The labeling works as follows. A fit to the OH 1665 and 1667 MHz lines implies column densities and excitation, and these predict what the 1612 MHz line or a CO line should look like. Physical gas components must satisfy these cross-predictions. A ripple in one receiver band generally will not, because its systematics are largely independent of the other bands. This borrows the logic of orthogonal detection channels, such as the Daya Bay neutrino experiment's comparison of neutron-capture-on-hydrogen and neutron-capture-on-gadolinium measurements (Fengpeng An et al.). The difference is that here the check is used as a training signal inside the fitting loop, not as a one-off post hoc comparison.

Why This Gap Is Real

Three kinds of prior work shape the proposal.

The first kind motivates it. The Taurus boundary study (Duo Xu et al.) fit four OH lines with RADEX, a code that computes line strengths for gas out of thermal equilibrium. It reported a split of about 1 km/s between two velocity components, and an OH excess over stationary photodissociation-region chemistry of up to a factor of 80. The 1720 MHz line could not be reproduced. All of these discrepancies were attributed to physics such as shocks, with no formal treatment of instrument systematics. The OH absorption survey of 44 sight-lines (Di Li et al.) showed that the inferred CO-dark gas fraction shifts by a factor of about 2.5 depending on which CO survey's sensitivity is used. Inferred quantities in this field are therefore highly sensitive to instrument choices.

The second kind constrains the design. The ACsys work (Maximum-likelihood Regression with Systematic Errors) generalizes a standard likelihood test for count data to include systematic variance. It shows that a feature significant at p = 0.01 weakens to p = 0.036 under 5% systematics and p = 0.181 under 10%. Ignoring systematics therefore produces false detections. That framework is offline, and its systematic variance is fixed rather than learned. On the alignment side, Reward Learning on Policy (Hao Lang et al.) retrains the reward model on policy rollouts using self-consistency labels. The file notes that such consensus labels can lock in a biased majority. For that reason we deliberately avoid consensus labels.

The third kind supplies the method. AIHF (Chenliang Li et al.) alternates reward-model and policy updates, and treats expert demonstrations as implicit preferences. We reuse this structure, with synthetic injected ground truth playing the role of demonstrations. LaSRO (Zhiwei Jia et al.) keeps a differentiable surrogate reward adapted on fresh rollouts, for generators that are nearly deterministic. Our amortized fitter is similarly near-deterministic, so we adopt LaSRO's direct surrogate-gradient update.

The random-forest line-ratio work (Émeric Bron et al.) is the closest existing machine learning use of astrochemical grids. It is trained once on 5,000-model grids, and tested only with Gaussian noise. Our proposal differs in two ways: it targets non-Gaussian instrument artifacts, and it adapts after deployment.

Research Program

The work has three parts: a simulator, a fitter, and a critic.

The simulator uses RADEX-style radiative transfer to generate OH quartets (1612, 1665, 1667, 1720 MHz) and CO/13CO spectra. Gas conditions span the ranges reported for Taurus and the absorption sample: visual extinction from 0.4 to 2.7 magnitudes and OH optical depths near 0.01. Onto these spectra we add families of instrument artifacts: standing-wave sinusoids, slow gain-drift polynomials, and calibration-scale offsets. Each family is kept independent across receiver bands. Crucially, some artifact families are held out of all training. These are used only at test time, to mimic the gap between simulation and a real telescope.

The fitter is an amortized network. It reads the spectra and outputs a number of velocity components, their parameters, and a smooth baseline. It is trained to maximize the objective

$$J(\theta) = \log p(x \mid \hat{s}_\theta(x)) + \lambda\, C_\phi(x, \hat{s}_\theta(x)),$$

where $x$ is the observed spectra, $\hat{s}_\theta(x)$ is the fitted solution produced by fitter weights $\theta$, the first term is the fit likelihood with ACsys-style systematic variance, and $\lambda$ weights the critic. The critic $C_\phi$, with weights $\phi$, scores how physically plausible the solution is.

The critic is trained on pairs of the fitter's current solutions. A solution is preferred when it better predicts the withheld transition, which is chosen at random each round, using the same log-probability-based preference loss as AIHF. On synthetic data, known injected truths serve as additional anchor preferences. On real data, only held-out-line preferences are available.

A final analysis step tests one assumption directly. For any given artifact family, we measure how correlated its residuals are across bands. The core method only works when this correlation is low.

Baselines

The naive reference is a per-spectrum least-squares Gaussian fit after subtracting a low-order polynomial baseline, with components added until a chi-square test stops improving. This is standard practice, and it sets the false-detection rate a practitioner currently accepts.

The strongest competitor is a full Bayesian multi-transition fit. It shares physical parameters across all four OH lines and CO. It models the baseline per band with a Gaussian process, a flexible random-function prior that can capture ripples. It includes ACsys-style systematic variance. It selects the number of components by comparing marginal likelihoods, and checks fits against held-out lines. This baseline uses the same physical cross-line constraints as our method, but through a fixed prior rather than a learned critic, which is exactly the contrast we want to test. For fairness, it gets the same simulator, the same artifact families during development, and a sampling compute budget matched to our training plus inference compute. Its Gaussian-process hyperparameters are tuned on the same validation spectra we use.

The static-grid competitor follows the random-forest approach of Émeric Bron et al., extended with artifact augmentation from the training families. That paper reports R² up to 0.92, against 0.57 for the DCO+/HCO+ ratio, when predicting ionization fraction in cold dense gas. That is a different target, so it serves only as a reference point. For false-component rates under systematics there is no reported result found on Lacuna, for this or any spectral decomposition method.

Two ablations isolate the key ingredient. The first freezes the critic after offline pretraining, which gives the static-judge version. The second replaces held-out-line labels with consensus labels in the style of Hao Lang et al..

To count as beating the Bayesian baseline, our method must do both of the following on held-out artifact families. It must cut the spurious-component rate at matched detection completeness for real faint components, by a margin exceeding the seed-to-seed variation. And it must produce column-density posteriors with correct coverage.

Why not just…?

Why not just integrate longer? Longer integration shrinks noise but leaves standing waves and gain drifts intact. The file's evidence is consistent: the factor-of-2.5 shift in dark-gas fraction in Di Li et al. comes from a sensitivity mismatch between surveys, not from photon-counting noise. We test this directly by scaling the simulated noise down tenfold with artifacts held fixed. We expect false-component rates in the naive baseline to stay flat.

Why not just use a Bayesian fit with a Gaussian-process baseline and posterior predictive checks? This is the real threat, and we treat it as the main comparison. If the artifacts in the data resemble what the Gaussian-process prior can represent, this baseline should match or beat us at lower complexity. Our method can only add value on artifact families the prior misrepresents. The held-out-family split is designed to settle that question. If the Bayesian fit wins there too, we will report that the online critic is unnecessary.

Why not just augment a static model with more simulated artifacts? If the artifact distribution is known, augmentation may suffice. The value of online adaptation lies entirely in unanticipated artifacts. The frozen-critic ablation and the augmented random forest, evaluated on held-out families, measure exactly this. A small gap would argue for abandoning the online component.

Why not use consensus labels, as RLP does? A fitter with a systematic bias produces a biased majority, and Hao Lang et al. flag exactly this collapse risk. The consensus-label ablation tests whether it occurs here.

Proposed Experiments

The first experiment is synthetic injection and recovery. Metrics are the spurious-component rate, completeness for components at 1 km/s separation, bias and calibration of recovered OH column density and excitation temperature, and bias in the dark-gas fraction. Performance is reported separately for seen and held-out artifact families, and as a function of how correlated the artifacts are across bands. We expect our method's advantage to vanish as that correlation approaches one. Seeing that vanishing would confirm the proposed mechanism, while an advantage that persists would suggest a leak somewhere in the setup.

The second experiment is decisive and uses real data, conditional on obtaining the reduced spectra from the Taurus and 44-sight-line studies. The Taurus analysis reports a dark-gas fraction falling from 80% to 20%, peaking near 0.79 magnitudes of extinction, together with the 1 km/s split and the factor-of-80 OH excess (Duo Xu et al.). We ask whether these survive refitting. We then examine the 1720 MHz discrepancy: does it persist when that line is withheld and predicted from the other three? If it does, that supports genuine non-thermal pumping rather than an artifact.

We do not presume the answers. Either outcome narrows what the Taurus anomalies can be attributed to, and that attribution is the scientific payoff of the proposal.