Outlier-Aware Low-Bit Quantization for Host-Response Infection Diagnostics

When a patient shows up at a rural clinic with fever, deciding between a bacterial, viral, or non-infectious cause usually requires detecting the pathogen itself — but pathogens are often too scarce in blood to find, and PCR cannot tell active disease from harmless carriage. Host-response transcriptomics sidesteps this by reading the patient's own immune cells as a biosensor: infection triggers a coordinated wave of gene expression in circulating white blood cells that differs between bacterial, viral, and fungal causes, and this signal can be measured from a single blood draw. The field has converged on an uncomfortable trade-off. Large gene signatures and expressive neural classifiers generalize best across hospitals, cohorts, and measurement platforms, but point-of-care hardware — the battery-powered instruments where such diagnostics actually matter — forces teams back to tiny logistic-regression models (Development of Machine Learning Classifiers for Blood-based Diagnosis and Prognosis of Suspected Ac infections and Sepsis).

This proposal argues that the obstacle between the two poles is, in part, a numerical one that a second literature has already characterized but never applied here. Compressing a neural network to low-bit integer arithmetic (the kind edge chips run fast) fails catastrophically when a few activation values inside the network are hundreds of times larger than the rest, because the quantization grid stretches to cover them and everything informative collapses into one bin. In language Transformers, these activation outliers arise from attention heads fighting the softmax constraint that weights must sum to one — a head that wants to "do nothing" must instead dump its output into some token, creating attention sinks on uninformative tokens and extreme values in specific channels (Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothing; Outlier Suppression: Pushing the Limit of Low-bit Transformer Language Models). Nobody knows whether the same thing happens when the tokens are genes, whether biological expression skewness makes it worse, or whether the known fixes transfer.

Core Claim

The claim is threefold. First, attention-based host-response classifiers — where each gene (or gene pair) is a token — develop the same attention-sink and channel-outlier structure seen in language models, but the sinks concentrate on biologically identifiable tokens (housekeeping or near-unexpressed genes rather than punctuation), and the input-side skewness of immune-gene surges produces an asymmetric outlier pattern that channel-wise corrections can partially but not fully neutralize. Second, post-training outlier suppression — channel-wise shifting and scaling absorbed into downstream weights with zero inference cost, as introduced for language models by Outlier Suppression+: Accurate quantization of large language models by equivalent and effective shifting and scaling — is the right starting tool here and should recover most diagnostic accuracy at 8-bit and possibly 4-bit weight-activation precision. Third, and most speculatively, the random orthogonal rotations used by QuIP: 2-Bit Quantization of Large Language Models With Guarantees to spread outlier energy across dimensions may do double duty against transcriptomic batch effects, which are themselves coordinate-specific variance concentrated by laboratory and platform — a hypothesis we can test directly because the field's central benchmark is cross-cohort transfer (bvnGPS: a generalizable diagnostic model for acute bacterial and viral infection using integrative host transcriptomics and pretrained neural networks).

Research Program

The program has three stages, each producing an independent deliverable.

Stage one builds the model class that the outlier literature has never touched: a Transformer classifier over gene-expression profiles, trained on the 18 public GEO cohorts used by bvnGPS for bacterial/viral/non-infected three-way classification. Two input encodings will be compared: raw log-expression with genes as tokens, and the pairwise ordinal encoding of bvnGPS (gene A above or below gene B), which is invariant to monotone platform gain and therefore the safer starting point. We will then run the diagnostic battery that Quantizable Transformers ran on BERT: measure the maximum activation magnitude across layers and channels, localize which gene tokens receive the attention-sink mass, and test whether sinks sit on housekeeping genes, near-zero-expression genes, or infection-induced genes. This alone is a publishable finding whichever way it goes — if gene transformers have no outliers, that constrains quantization theory; if they do, the sink genes are biologically interpretable and the result connects two disjoint literatures.

Stage two quantizes these models post hoc — no retraining, since the clinical setting forbids expensive pretraining runs on small cohorts, matching the constraint that architectural fixes like gated attention require training from scratch (Quantizable Transformers). The core tool is the equivalent-shift-and-scale trick: for a linear layer with input $X$ and weight $W$, one can replace $X$ by $X \cdot S^{-1}$ and $W$ by $S \cdot W$ with identical output, so per-channel shifts $z$ and scales $s$ can be applied to activations and absorbed into the adjacent weights at zero runtime cost. We will measure how much of the transcriptomic outlier structure this removes, whether the residual is the symmetric component that shifting cannot touch (predicted from the asymmetric-outlier analysis of Outlier Suppression+), and whether a low-rank branch in the spirit of SVDQuant: Absorbing Outliers by Low-Rank Component for 4-Bit Diffusion Models is needed to survive 4-bit weight-activation quantization.

Stage three tests the double-duty rotation hypothesis. Batch effects concentrate variance in platform-specific coordinates; random orthogonal rotations provably spread coordinate-wise peaks across all dimensions without losing information (QuIP). We will apply a fixed random rotation (or a data-driven near-orthogonal matrix) to the input gene vector and its inverse to the first weight matrix, then measure two things at once: cross-cohort transfer AUC in full precision (does rotation suppress batch effects the way iPAGE's pairwise ranks do?) and quantized AUC at 8/6/4 bits (does it protect the quantization grid the way QuIP's incoherence processing does in language models?). If rotation improves both, the two fields' hardest problems partially share a solution.

Proposed Experiments

The primary benchmark is the multi-cohort GEO meta-analysis from bvnGPS: 16 discovery cohorts with $N = 2{,}533$ (1,773 train / 760 test) plus two fully independent external validation sets (GSE21802 and GSE57065, $N = 147$). This is the right testbed because it is explicitly a cross-cohort transfer benchmark, which is where both batch effects and generalization gaps bite. Secondary benchmarks: the 51-dataset, 4,589-subject systematic comparison of 28 published signatures with its COVID-19 out-of-distribution cohorts (Systematic comparison of published host gene expression signatures for bacterial/viral discrimination), and the ICU metatranscriptomics cohort of 180 patients with a fungal subclass of only 15 cases (Stacking ensemble learning models diagnose pulmonary infections using host transcriptome data from metatranscriptomics) — the rare-class regime where expressive models should help most. The primary metric is per-class AUC (bacterial, viral, non-infected) on held-out cohorts, reported as full-precision AUC and the AUC delta after quantization at each bitwidth; the headline success criterion is a 4-bit or 6-bit integer model whose per-class AUC stays within 0.01 of its full-precision self while beating the strongest shallow baseline on external validation. We will also report the pediatric degradation documented in the systematic comparison (Systematic comparison) as a stress test, and an outlier-structure report (max activation norm, sink-gene identities) alongside every accuracy number, so the mechanism is audited even when accuracy alone looks unremarkable.

Baselines

The do-nothing reference point is the full-precision (FP32) version of our own Transformer: quantization should cost nothing relative to it, and any AUC drop at 8 bits is already a negative result for naive deployment. The naive compression baseline is standard MinMax quantization with no outlier handling — in language Transformers this collapses BERT's perplexity from 4.49 to 1294 at INT8 (Quantizable Transformers), and we expect the analogous collapse in AUC here; it exists to show the problem is real in this domain. The strongest external competitor is bvnGPS itself — an MLP over pairwise gene-pair signatures, trained and validated on exactly the cohorts we use, reporting test-set AUCs of 0.954 (bacterial), 0.956 (viral), and 0.975 (non-infected), versus 0.835/0.898/0.914 for an SVM, and independent external-validation AUCs of 0.988 (bacterial) and 0.994 (viral) (bvnGPS). It is the strongest because it owns the current best numbers on the exact benchmark, its pairwise encoding already solves input-level batch effects, and it runs as a small MLP that is cheap to deploy without quantization. To make the comparison fair, we will retrain bvnGPS's architecture on identical train/test splits, give every method the same feature universe and the same hyperparameter search budget, and additionally quantize the bvnGPS MLP itself to the same bitwidths — if a quantized shallow MLP matches a quantized Transformer, the Transformer is not paying its way. The key ablation isolates the proposal's central ingredient: our Transformer quantized with channel-wise shift-and-scale suppression versus the identical Transformer quantized without it (MinMax only) versus with rotation added, at matched bitwidth and identical calibration data, so any AUC difference is attributable to outlier handling alone. As a clinical anchor for what "good enough" means, the deployed 29-mRNA point-of-care system reports multi-class AUROC of 0.83 (Development of Machine Learning Classifiers for Blood-based Diagnosis and Prognosis of Suspected Ac Infections and Sepsis); a compressed model that clears the bvnGPS numbers while running in integer arithmetic on that class of hardware is the practical win condition.

Why not just…?

Why not just use logistic regression or a shallow ensemble, which already reach high AUCs? This is the most serious objection and we take it at face value. A 21-gene LASSO model reached clinical AUCs of 0.94 (fungal), 0.96 (bacterial), and 0.83 (viral) (Pathogen class-specific transcriptional responses derived from PBMCs accurately discriminate between fungal, bacterial, and viral infections), and the deployed point-of-care pipeline explicitly found logistic regression transferred across platforms better than gradient boosting (Development of Machine Learning Classifiers). The counter-evidence is about heterogeneity, not single-cohort accuracy: across the multi-cohort benchmark the SVM fell to 0.835/0.898/0.914 where the neural model held 0.954/0.956/0.975 (bvnGPS), and the systematic comparison showed small signatures degrade on real-world variation, including pediatric cohorts, while large composite sets stayed robust (Systematic comparison). Our design settles this empirically rather than rhetorically: both model families get the same data, tuning budget, and quantization treatment, and if the quantized shallow model matches the quantized Transformer on external validation, we will report the Transformer as unnecessary. The rare-fungal ICU setting (15 cases) is where we most expect expressiveness to matter (Stacking ensemble learning models).

Why not just use pairwise gene ratios (iPAGE), which already neutralize batch effects and bound the inputs? The pairwise-ordinal encoding of bvnGPS is excellent at what it targets — input-level platform gain — and we in fact adopt it as one of our two input encodings, so this is a partially absorbed objection rather than a rejected one. What it does not address is the internal, emergent side of the problem: activation outliers are generated by the network's own mechanics, not by input magnitude. BERT's inputs are already bounded, yet its activations reach a max norm of 735 and INT8 quantization destroys it (Quantizable Transformers); the cause is softmax's no-op workaround plus LayerNorm channel amplification (Outlier Suppression). Stage one of our program directly measures whether a gene-pair Transformer exhibits the same internal spikes despite bounded inputs — if it does, iPAGE alone cannot make the model quantizable, and our shift-and-scale stage is complementary rather than redundant.

Why not just do weight-only quantization and skip the activation-outlier problem entirely? Weight-only compression (say, 4-bit weights with 16-bit activations) sidesteps activation outliers by leaving activations in floating point, which is exactly why it under-delivers on edge hardware: the device still needs full floating-point multiply-accumulate units and the memory traffic that goes with them. The direct measurement in SVDQuant quantifies this — 4-bit weight-and-activation quantization gave a 3.0x speedup on an RTX 4090 and a 10.1x speedup on a 16GB laptop GPU over 4-bit weight-only, while cutting memory from 22.7 GiB to 6.5 GiB. The point-of-care context — the Myrna-class battery instruments described in Development of Machine Learning Classifiers — is precisely the low-power regime where integer arithmetic matters most. The honest caveat: our models are tiny by LLM standards, so memory is not the binding constraint; the argument rests on integer-only MAC throughput and on the 21-gene qPCR cost economics documented in Stacking ensemble learning models (a 93% cost reduction with under-6-hour turnaround), and we will report wall-clock energy measurements rather than assume the speedup transfers.

Decisive Checks

Three findings would make or break the proposal. First, if gene Transformers show no meaningful activation outliers (max norms comparable to feature scale) and naive INT8 quantization is lossless, the central premise is empty — we would report that as a genuine negative result constraining outlier theory to domains with softmax no-op pressure. Second, if the bvnGPS MLP quantizes losslessly to 4 bits and matches our Transformer everywhere, the engineering contribution reduces to "quantize the existing model," which is useful but modest; the Transformer would then have to justify itself on the rare-class and pediatric stress tests or concede. Third, the rotation experiment is decisive in both directions: if rotation improves cross-cohort AUC and quantized AUC together, it is evidence that batch effects and quantization damage share a coordinate-concentration mechanism — a claim neither literature has tested — and if it improves one but not the other, the double-duty hypothesis is falsified and we report which. All numbers will be stated against the published anchors above; no reported result exists on Lacuna for quantized host-response diagnostic models at any bitwidth, which is the gap this proposal fills.