scieee AI-readable full text Open interactive document viewer

HERALD: High-resolution Early Recognition of Antigenic Landscape Divergence

Davis, Bee Rosa

Abstract

HERALD: High-resolution Early Recognition of Antigenic Landscape Divergence A theoretical framework for geometry-based viral surveillance that enables early detection of immune-escape variants before widespread transmission. HERALD constructs a Riemannian pullback manifold where Euclidean distances in latent space approximate antigenic relationships within bounded-distortion regimes. This deposit includes: Empirical validation studies on SARS-CoV-2 data (DMS and genomic surveillance) Key Contributions: Manifold Construction: Defines a contrastive learning objective with Jacobian/Laplacian regularization that induces smooth pullback metrics, enabling Euclidean computations to approximate geodesic distances reflecting antigenic divergence Real-Time Drift Detection: Specifies a probability-integral transform (PIT) fusion scheme combining sequence, antigenic, and structural signals into a scalar drift statistic with O(log n) amortized complexity Formal Guarantees: Derives margin-to-separation results for InfoNCE objectives and establishes Cantelli-based probability bounds requiring only finite variance (no sub-Gaussian assumptions), composing into conditional end-to-end dominance bounds with explicit error budgets Evaluation Protocols: Provides falsifiable protocols for retrospective time-slice replay, prospective streaming emulation, distortion audits, and equity/parity analysis across pathogens (SARS-CoV-2, influenza, HIV) Ethics Framework: Includes comprehensive governance templates addressing dual-use risks, information hazards, data sovereignty, abstention policies, and oversight structures Empirical Validation: Validation I demonstrates 5.7–8.8× improvement in geometric separation (Δ) over baseline methods on SARS-CoV-2 deep mutational scanning data. Validation II confirms out-of-time generalization: the frozen encoder detects Omicron BA.1 emergence in South Africa (Z = 2.29, p ≈ 0.011) under sparse monthly surveillance data with near-zero support-adjusted latency. Scope: The theoretical manuscript presents definitions, assumptions, theorems, and evaluation protocols. Validation I provides empirical confirmation on historical DMS data; Validation II demonstrates real-world surveillance applicability via retrospective time-slice replay on Nextstrain genomic data. Both studies use rigorous train/test methodology and no sequence optimization (safe surveillance scope). Applications extend beyond viral surveillance to bacterial pathogen monitoring (STEC, antibiotic resistance) where antigenic/functional divergence precedes clinical detection. Author: Bee Rosa Davis (NASA Mission Systems Engineer, IBM X-Force Red Principal Adversarial Intelligence Engineer) Keywords: viral surveillance, Riemannian geometry, contrastive learning, immune escape, early warning systems, algorithmic epidemiology, information geometry, public health AI, ESM-2, protein language models, deep mutational scanning License and Patent Disclaimer Copyright License: This work is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0). You are free to share and adapt this work for non-commercial purposes with appropriate attribution, provided derivative works use the same license. Patent Notice: The methods, systems, and algorithms described herein are subject to U.S. Provisional Patent Application No. 63/919,595 (filed November 18, 2025). This copyright license does NOT grant any rights under patent law. Implementation, commercial use, or deployment of the HERALD framework may require separate patent licensing arrangements. Clarification: The CC BY-NC-SA 4.0 license governs only the manuscript text and documentation—the right to read, cite, and build upon these ideas academically. The patent covers the technical implementation of the framework. For research and educational use, no patent license is required. For commercial deployment or production systems, contact the inventor regarding patent licensing. Contact for Patent Licensing: [email protected] 3.0: Added Validation Study II ("Time Traveler") demonstrating out-of-time generalization—frozen geometry trained on 2020 DMS data detects 2022 Omicron emergence with p ≈ 0.011 under sparse surveillance conditions. Includes time-slice replay code, heatmaps, and frozen encoder checkpoint.

Full text

HERALD Validation Study II: Retrospective Time-Slice Replay on SARS-CoV-2 Genomic Data (“Time Traveler”) Bee Rosa Davis November 21, 2025 Abstract Following the geometric separation confirmed on RBD deep-mutational scanning data (Validation I), this study evaluates whether the frozen HERALD encoder fϕexhibits out-of-time generalization during historical SARS-CoV-2 emergence episodes. We instantiate a preregistered Stage 2 drift pipeline—latent distance →PIT normalization →Gaussianized Z—and execute a retrospective time-slice replay on a deliberately sparse monthly slice (2020–2023). Despite the low-data regime, the rolling-anchor signal (DJump) issued a high-confidence alert in South Africa during January 2022 (Z= 2.29; one-sided p≈0.011), coincident with the Omicron BA.1 wave. Because November–December 2021 bins were unpopulated, absolute lead-time to WHO is not identifiable here; instead, we quantify support-adjusted latency and show near-zero delay once data resumes. This demonstrates robustness of the learned antigenic geometry under starvation and motivates a full-density Validation III for lead-time benchmarking. 1 Executive Summary This study is the second empirical pillar of HERALD. It operationalizes the Retrospective TimeSlice Replay protocol to test the hypothesis that geometry anticipates epidemiology when the geometry is trained only on 2020 DMS escape signals and then frozen.1 Key Findings. •Antigenic shift detected under starvation. The rolling-anchor statistic DJump triggered a statistically significant alert in South Africa, January 2022 (Omicron BA.1), despite monthly aggregation and low Nper bin. •Support-adjusted immediacy. With zero sequences in Nov–Dec 2021, absolute lead-time to WHO is undefined in this slice; however, support-adjusted latency from first supported bin to alert is ≈0 days (instantaneous once data appears). •Frozen geometry, temporal generalization. The same fϕthat produced a positive separation gap on held-out DMS mutants (Validation I) generalized to 2022 data without any retraining, supporting the stability of the “distance⇒escape” manifold. 1Stage 2 PIT drift and replay definitions follow the HERALD manuscript (Methods §4.4, Protocol §5.2; metrics §5.4). 1 2 Methods 2.1 Data, Scope, and Binning We use the Nextstrain open SARS-CoV-2 dataset; countries: United Kingdom, South Africa, USA; time: 2020–2023. To stress-test robustness, we aggregate by month and cap per-bin sampling (uniform) at Nmax = 200 after minimum support Nmin. Table 1: Protocol Configuration (Sparse Regime) Component Specification Data source Nextstrain Open (human host; QC passed) Regions UK, South Africa, USA Binning Monthly (robust to weekly gaps) Sampling Uniform subsample per (country, month); Nmax = 200 Underpowered Bins with N < Nmin excluded from scoring Encoder Frozen HERALD fϕfrom Validation I checkpoint Signals DWuhan (absolute); DJump (episode-local) Nulls Fixed historical window (W= 3 months) per-country, per-signal Normalization Probability Integral Transform (PIT) →Z= Φ−1(U) Alert rule First month twith Z(t)> θ (one-sided) Threshold θ∈ {1.5,2.0,2.5}; sparse default θ= 1.5 Baseline Hamming-to-Wuhan, 90th percentile, identical sampling and PIT 2.2 Geometry and Distance Each RBD sequence xis embedded by fϕinto z(x); distances are Euclidean in latent space. Primary anchor is Wuhan-Hu-1. For episodes, a rolling anchor is the consensus of the previously dominant lineage. Per-bin raw statistics are 90th percentiles: SWuhan(c, t) = p90{∥zi−zWuhan∥2}, SJump(c, t) = p90{∥zi−zprev∥2}. 2.3 PIT Normalization and Drift Scores For a country cand statistic S, estimate a leakage-free empirical CDF Fc(s) on a fixed historical window Wthat ends at cut date tc. Apply the probability integral transform to obtain Uc(t) = Fc(S(c, t)) and Gaussianize Zc(t)=Φ−1(Uc(t)). We report DWuhan and DJump separately; stacking is not used in this sparse slice. 2.4 Support-Adjusted Latency Standard lead-time metrics require continuous support. We therefore report: ∆data ≡tfirst-supported-bin −tbenchmark,∆alert|support ≡talert −tfirst-supported-bin. Small ∆alert|support indicates the system fires as soon as data exists. 2 3 Results 3.1 Automated Alert Log (South Africa) Table 2: High-confidence alert in a sparse monthly replay (one-sided pfrom Z). Signal Alert Date Z p (approx) Associated Event DJump 2022-01-17 2.29 0.011 Omicron BA.1 3.2 Latency Decomposition (South Africa, Omicron BA.1) Table 3: Separating data latency from model latency. Quantity Value / Interpretation Data coverage (Nov–Dec 2021) 0 sequences ⇒bins unsupportable First supported bin 2022-01 (data stream resumes) Alert date 2022-01-17 (first month with support) Support-adjusted latency ∆alert|support ≈0 days (instant) Interpretation. Absolute lead-time vs. WHO (Nov 26, 2021) cannot be computed on this slice. However, the near-zero support-adjusted latency demonstrates that the geometry triggers immediately once sequences appear, consistent with a robust detector operating under starvation. 3.3 Visual Validation Figure 1: Traffic-light heatmap for DWuhan (distance from Wuhan-Hu-1). Monotone drift increases over time, as expected. 3 Figure 2: Traffic-light heatmap for DJump (rolling anchor). A distinct high-Zblock appears in South Africa in early 2022, coincident with Omicron BA.1. 4 Baselines, Parity, and Power Apples-to-apples Hamming. We compute the Hamming baseline with identical sampling (uniform within bin), identical 90th-percentile aggregation, and identical PIT-to-Znormalization. This satisfies reviewer parity and isolates geometry’s contribution. Underpowered bins. We explicitly flag and exclude bins with N < Nmin to avoid unstable PIT behavior. Monthly aggregation mitigates sawtooth artifacts inherent in sparse weekly slices. 5 Discussion 5.1 Geometry ⇒Signal under Starvation Validation I demonstrated a positive separation gap ∆ on held-out DMS escape pairs, implying that latent distance carries functional meaning. Validation II shows that the same geometry, without any retraining, produces an Omicron-scale jump signal the instant data becomes available. This is precisely the setting where geometry should outperform raw mutation counts. 5.2 Limitations and Next Steps •Sparsity. With empty bins (Nov–Dec 2021), absolute lead-time metrics (LT10%,LTWHO) are non-identifiable. We therefore report support-adjusted latency here and reserve lead-time benchmarking for Validation III with full-density weekly data. •Calibration scope. Thresholds (θ) and null windows were chosen for sensitivity in sparsity; operating points should be re-optimized under full coverage. 5.3 Safety and Governance We adhere to a surveillance-only scope: no sequence optimization or ranking of hypothetical variants; coarse-grained attributions only; OOD/uncertainty abstention first; and versioned, auditable thresholds. A negative-control catalog and two-person integrity are used when elevating beyond Tier 1 (watch). 4 6 Conclusion Validation II confirms that HERALD’s learned geometry is operationally robust in a low-data environment: it fires a correct jump alert promptly once sequences appear, with near-zero supportadjusted latency. A full-density Validation III will fairly adjudicate absolute lead-time vs. WHO and t10% benchmarks while retaining the same frozen geometry and PIT apparatus. Reproducibility (Artifacts & Settings) Python scripts implement: Nextstrain ingestion; uniform subsampling; ESM→fϕembedding; Sstatistics (90th percentile); PIT-to-Zusing leakage-free fixed windows; alert scans; and heatmaps. Episode anchors are specified via a JSON file (country, start date, pre-window, lineage). Key parameters for this run: agg=month,N min=10,N max=200,null mode=fixed window,W=3 months, and θ∈ {1.5,2.0,2.5}. 5