Continued pretraining lifts an open-weight EHR model past familiar baselines

Open-weight language models may have a real place in electronic health record prediction when they are adapted to the structure of local data rather than treated as generic text engines. In a medRxiv preprint, investigators built VEX-EHR by extending a 12-billion-parameter open-weight language model with 17,601 clinical and audit-log codes drawn from 170,483 patients’ records at one academic medical center, then continued pretraining on 4.7 billion tokens from records spanning 2019 through 2024. The model was then fine-tuned for specific prediction tasks and compared with two familiar standards: gradient-boosted trees and CEHR-BERT, an EHR foundation model.

The performance gap was not subtle. For next-24-hour discharge prediction, VEX-EHR reached an AUROC of 0.917, compared with 0.868 for gradient-boosted trees and 0.848 for CEHR-BERT. For 30-day readmission, the model achieved 0.715 versus 0.677 and 0.650. For intensive care unit acute kidney injury, it posted 0.847 against 0.828 and 0.791. Continued pretraining improved AUROC by 0.031 to 0.053 across every task.

Why clinical vocabulary matters more than generic language fluency

The result fits the basic logic of hospital data: EHRs are not prose, and clinical meaning often lives in codes, sequence, timing, and administrative signals rather than in natural language alone. By adding 17,601 clinical and audit-log codes to the model’s vocabulary, the investigators gave the network a denser map of how care is actually documented and delivered. That matters because discharge readiness, readmission risk, and kidney injury risk are all shaped by patterns that unfold across orders, transfers, billing-like events, and note-adjacent metadata, not just by a single note or a tidy problem list.

A generic language model can read medical text, but it may still miss the operational grammar of care. Continued pretraining on institution-specific records appears to teach the model which events cluster together, which orders tend to precede deterioration, and which documentation artifacts carry predictive value in a given health system.

The strongest signal came when labels were scarce

One of the most practical findings was performance under low-label conditions. With only 10% of the labels, VEX-EHR still exceeded both comparators using all labels for discharge prediction, and it outperformed CEHR-BERT for readmission. In a hospital setting, that is not a trivial advantage. Many predictive tasks are label-limited because adjudication is expensive, outcomes are delayed, or the endpoint itself is defined by downstream utilization rather than a clean physiologic measurement.

A model that remains strong when labels are sparse can lower the cost of deployment and make local adaptation more realistic for institutions that do not have the annotation bandwidth of a large academic center. This is especially relevant for quality improvement teams that need usable predictions before a comprehensive labeled dataset can be assembled. Sparse-label robustness also suggests that the pretrained representation retained useful clinical structure before task-specific tuning began.

Open-weight systems gain an edge when local adaptation is feasible

The study’s broader argument is about flexibility as much as accuracy. Because the backbone model, Gemma-4 12B, is publicly available under its published license, the approach shows how an open-weight model can be specialized using a hospital’s own data without relying on a closed commercial system. That structure gives health systems more control over adaptation, auditing, and reproducibility, even if the model itself still requires careful governance.

The pretraining step likely did the heavy lifting. Clinically, this is plausible: a model repeatedly exposed to site-specific sequences from 2019 to 2024 can absorb the rhythms of admissions, discharges, ICU transfers, lab ordering, and code patterns in a way that generic pretraining cannot. The downstream fine-tuning then converts that representation into task-specific predictions. The result was superior AUROC across all three tested outcomes, including the ICU acute kidney injury endpoint, which sits closer to acute physiology than administrative utilization.

What the numbers do and do not prove

These findings support the idea that continual pretraining can make open-weight language models competitive with, and in this preprint superior to, traditional machine learning for EHR-based prediction. They do not prove broad portability. The patient-level data came from a single academic medical center, and the model was trained and evaluated within that institutional ecosystem. Local coding practices, care pathways, and documentation habits can all shape predictive performance, which is exactly why the adaptation worked so well here and exactly why outside validation will matter.

The data were also not publicly shareable because they contained protected health information, although the backbone model and code repository were made available. That combination offers a useful research pattern: public base model, private institutional adaptation, and task-level validation inside a defined health system. For clinical deployment, though, AUROC alone is not enough. Calibration, drift across time, subgroup performance, and real-world workflow burden will determine whether a model helps clinicians or merely makes predictions faster.

There is also a difference between predicting discharge, readmission, and kidney injury on paper and changing what happens at the bedside. Discharge prediction may influence bed management and transitional care. Readmission prediction may shape follow-up planning, social support, and medication review. Acute kidney injury prediction has a more immediate physiologic edge, since earlier recognition can affect fluid management, nephrotoxin avoidance, and monitoring intensity. Each endpoint carries a different operational meaning, and the study’s three-task design hints at that spread without resolving how each model would be used in practice.

The preprint was approved by Vanderbilt University Medical Center’s Institutional Review Board under IRB #260543 with a waiver of informed consent, and the work was funded by the National Library of Medicine of the National Institutes of Health under R01LM015078. Those details place the study squarely in the growing effort to make foundation models useful for hospital prediction tasks, but the clinical threshold for adoption remains high. External validation, prospective testing, and evidence that the model improves decisions rather than only scores outcomes will decide whether this approach stays a research advance or becomes an operational tool.


Reporting by Dr. A. Nikhil Krishnan, MBBS for Medicine World Foundation, with additional data provided by medRxiv (Clinical Preprints).
PRIMARY CLINICAL EVIDENCE & REGISTRY DATA