Machine learning models to improve targeting of blood culture testing

This article has been Reviewed by the following groups

Read the full article See related articles

Abstract

Background

Bloodstream infections are a major cause of mortality, yet the primary testing method, blood cultures, have low positivity (<10%) and turnaround times of 24–48 hours. Many are taken from patients at low risk of infection, while some bloodstream infections are diagnosed late or missed entirely. We aimed to develop and externally validate machine learning models to improve targeting of blood culture testing.

Methods

In this retrospective cohort study, we used routinely collected clinical and laboratory data available around culture collection from a large multi-site NHS trust (Oxford University Hospitals; Infections in Oxfordshire Research Database), between 1 January 2016 and 17 March 2025. All blood cultures taken from adults and children were included. XGBoost models were trained to predict pathogenic blood culture positivity using a temporal split (training before 1 January 2024; held-out test thereafter). External validation used emergency department data (between 1st May 2019 and 30th April 2024) from University College London Hospitals. An additional analysis examined blood culture reallocation towards the highest-risk untested admissions.

Findings

294,064 cultures were included (positivity 5.6%). In the temporal hold-out test set (n=46,339), AUROC (Area Under the Receiver Operating Characteristic) was 0.853 (95% CI 0.846–0.860), rising to 0.876 in emergency department patients, and the model was well calibrated (slope 1.046). In external validation (n=37,326), AUROC was 0.847 (95% CI 0.839–0.856) with preserved calibration. In a simulated resource-neutral reallocation, replacing the 10,000 lowest-risk sent cultures with the highest-risk untested emergency admissions yielded 627 additional positive cultures (28.3% relative increase in yield). Performance was reduced when restricted to data available at the point of culture collection (AUROC 0.769, 95% CI 0.760–0.779).

Interpretation

An externally validated, well calibrated machine learning model built from broadly available, routinely collected data could improve blood culture yield without increasing testing volume, supporting resource-neutral diagnostic stewardship across NHS sites.

Article activity feed

  1. This Zenodo record is a permanently preserved version of a PREreview. You can view the complete PREreview at https://prereview.org/reviews/24456813.

    Summary

    Bloodstream infections are primarily tested through blood cultures, which have low positivity and long turnaround times. This preprint aimed to develop and externally validate machine learning models to improve targeted blood culture testing using samples from Oxford University Hospitals and external samples from University College London Hospitals. They found that mean predicted risk closely matched observed positivity of pathogenic blood cultures. Through a simulated resource-neutral reallocation, they also hypothesized that their model had a 28.3% increase in diagnostic yield in the untested population. Their findings suggest that machine learning could be used to improve blood culture diagnostics.

    Strengths

    1. Large database

    The models were internally validated with a large database, the Oxfordshire Research Database, covering 1% of England. They included over 290,000 samples, which is substantial for model development.

    1. External validation with a separate database.

    The authors used data from the University of College London Hospitals and had an AUROC of 0.847, which supports the model's generalizability beyond Oxford University Hospitals.

    Major concerns

    1. Retrospective data.

    The model was tested with hypothetical simulations that may not have been reflected if the study were conducted prospectively. This also limits the hypothesis of the increase in diagnostic yield, since we would not know this outcome with retrospective data. Also, they are limited to the data collected by clinicians, which could have been selected without regard to blood infection risk.

    1. Performance is not equal in all subgroups.

    Performance was significantly lower in pediatric patients, Black patients, and those in the most deprived quintile. This raises concerns about whether the model would work as well in real-life, diverse settings, and it is something that must be addressed in future validation studies.

    Competing interests

    The author declares that they have no competing interests.

    Use of Artificial Intelligence (AI)

    The author declares that they did not use generative AI to come up with new ideas for their review.