Full Text
<article class="scholarly-article">
<h2>Introduction</h2>
<p>Sepsis is a dysregulated host response to infection that leads to life-threatening organ dysfunction, affecting millions globally each year (Evans et al., 2021). Despite advances in critical care, sepsis remains a leading cause of mortality, with delays in recognition and treatment significantly increasing risk of death (Rehman et al., 2022). Emergency departments (EDs) serve as the primary entry point for septic patients, making early detection a critical priority (Sungkar et al., 2018).</p><p>Traditional screening tools such as systemic inflammatory response syndrome (SIRS) criteria and quick Sequential Organ Failure Assessment (qSOFA) have limited sensitivity and specificity in the ED setting (Hwang et al., 2020). In recent years, machine learning (ML) algorithms have emerged as a promising approach to leverage electronic health record (EHR) data for early sepsis prediction (Kijpaisalratana et al., 2022; Sherwin & Ying, 2018). These models can integrate multiple variables—including vital signs, laboratory results, and demographic data—to generate real-time risk scores.</p><p>Several studies have demonstrated the feasibility of ML-based sepsis detection in intensive care units (Desautels et al., 2016) and EDs (Xie et al., 2024; Brann et al., 2023). However, many models are developed using retrospective data from single centers, and their generalizability remains uncertain. Moreover, implementation into clinical workflows poses challenges related to alert fatigue, provider trust, and integration with existing systems (Henry et al., 2022).</p><p>This study aimed to develop and validate a machine learning model for early sepsis detection within 24 hours of ED triage, using a retrospective cohort from a tertiary care hospital. We compared multiple algorithms, identified key predictors, and assessed potential clinical impact through simulation.</p>
<h2>Literature Review</h2>
<p>Early identification of sepsis is paramount to reducing morbidity and mortality (Evans et al., 2021). In ED settings, screening protocols such as SIRS and qSOFA have been widely adopted, yet their diagnostic accuracy is suboptimal (Hwang et al., 2020). For instance, a systematic review found that qSOFA had a pooled sensitivity of only 0.54 for predicting in-hospital mortality in ED patients (Hwang et al., 2020).</p><p>Machine learning approaches offer the potential to improve upon these tools by capturing complex, non-linear relationships among clinical variables. Kijpaisalratana et al. (2022) developed an ML model using ED triage data from a Thai hospital, achieving an area under the receiver operating characteristic curve (AUROC) of 0.85 for sepsis prediction. Similarly, Xie et al. (2024) reported an AUROC of 0.88 for predicting sepsis within 24 hours at triage using gradient boosting. Brann et al. (2023) incorporated natural language processing of triage notes, further improving performance (AUROC 0.91).</p><p>Beyond accuracy, studies have examined the clinical impact of ML-based alerts. Kijpaisalratana et al. (2024) conducted a cluster-randomized trial demonstrating that real-time ML-assisted sepsis alerts reduced time to antibiotic administration by a median of 1.5 hours. However, alert fatigue and false alarms remain concerns (Henry et al., 2022). Desai et al. (2022) reviewed prehospital data integration and found that including ambulance data could enhance model performance but requires data standardization.</p><p>Bias and fairness are also critical issues. Challen et al. (2019) highlighted that ML models may perpetuate existing disparities if training data are not representative. Therefore, validation across diverse populations is essential before widespread deployment.</p>
<h2>Methodology</h2>
<h4>Study Design and Setting</h4><p>This retrospective cohort study was conducted at a tertiary care academic hospital with approximately 80,000 ED visits annually. The study was approved by the institutional ethics committee (approval number IRB-2023-045).</p><h4>Study Population</h4><p>We included all adult patients (≥18 years) presenting to the ED between January 1, 2020, and December 31, 2022, with suspected infection as indicated by the ordering of blood cultures or administration of antibiotics within 24 hours of triage. Exclusion criteria were: transfer from another hospital, do-not-resuscitate orders, and missing outcome data. A total of 18,351 patients met inclusion criteria.</p><h4>Outcome Definition</h4><p>The primary outcome was sepsis within 24 hours of triage, defined according to Sepsis-3 criteria: suspected infection plus an increase in Sequential Organ Failure Assessment (SOFA) score of ≥2 points (Evans et al., 2021). SOFA scores were calculated using laboratory and clinical data within 24 hours of triage.</p><h4>Predictor Variables</h4><p>We extracted 28 candidate predictors from the EHR at triage: age, sex, vital signs (heart rate, respiratory rate, systolic blood pressure, diastolic blood pressure, oxygen saturation, temperature), laboratory values (white blood cell count, hemoglobin, platelets, creatinine, blood urea nitrogen, glucose, lactate, procalcitonin, C-reactive protein), comorbidities (diabetes, hypertension, chronic kidney disease, chronic obstructive pulmonary disease, cancer), and triage acuity score.</p><h4>Data Preprocessing</h4><p>Missing values were imputed using median imputation for continuous variables and mode for categorical variables. Continuous variables were standardized to zero mean and unit variance. The dataset was split into training (70%, n=12,845) and test (30%, n=5,506) sets using stratified sampling based on the outcome.</p><h4>Machine Learning Models</h4><p>We trained four supervised learning algorithms: logistic regression (LR) with L1 regularization, random forest (RF) with 100 trees, gradient boosting machine (GBM) with 100 estimators, and a feedforward neural network (NN) with two hidden layers (64 and 32 neurons, ReLU activation). Hyperparameters were optimized using 5-fold cross-validation on the training set. The models were implemented using Python's scikit-learn and TensorFlow libraries.</p><h4>Performance Evaluation</h4><p>Model performance was assessed on the test set using AUROC, sensitivity, specificity, positive predictive value (PPV), and F1-score. We also compared models against SIRS criteria (≥2 criteria) and qSOFA (≥2 criteria). Calibration was evaluated using calibration plots and Brier score. Additionally, we simulated the potential clinical impact by estimating the time difference between the ML alert (at a threshold yielding 90% sensitivity) and the earliest clinical recognition (documented sepsis diagnosis or antibiotic administration).</p>
<h2>Results</h2>
<h4>Baseline Characteristics</h4><p>The study cohort comprised 18,351 patients, of whom 2,847 (15.5%) developed sepsis within 24 hours. The median age was 58 years (IQR 42–72), and 52% were male. Patients with sepsis were older, had higher heart rate and respiratory rate, and lower oxygen saturation. Table 1 presents baseline characteristics stratified by sepsis status.</p><figure class="table-figure"><table><thead><tr><th>Characteristic</th><th>Non-Sepsis (n=15,504)</th><th>Sepsis (n=2,847)</th><th>p-value</th></tr></thead><tbody><tr><td>Age (years), median (IQR)</td><td>56 (40–70)</td><td>65 (52–78)</td><td><0.001</td></tr><tr><td>Male, n (%)</td><td>8,062 (52.0)</td><td>1,482 (52.1)</td><td>0.94</td></tr><tr><td>Heart rate (bpm), mean (SD)</td><td>88 (18)</td><td>102 (22)</td><td><0.001</td></tr><tr><td>Respiratory rate (breaths/min), mean (SD)</td><td>18 (4)</td><td>22 (6)</td><td><0.001</td></tr><tr><td>Systolic BP (mmHg), mean (SD)</td><td>132 (24)</td><td>118 (28)</td><td><0.001</td></tr><tr><td>Oxygen saturation (%), median (IQR)</td><td>97 (95–98)</td><td>94 (90–96)</td><td><0.001</td></tr><tr><td>Temperature (°C), mean (SD)</td><td>37.1 (0.8)</td><td>38.2 (1.2)</td><td><0.001</td></tr><tr><td>WBC (×10³/µL), median (IQR)</td><td>9.2 (6.8–12.5)</td><td>14.1 (9.8–19.2)</td><td><0.001</td></tr><tr><td>Lactate (mmol/L), median (IQR)</td><td>1.2 (0.9–1.8)</td><td>2.8 (1.6–4.5)</td><td><0.001</td></tr><tr><td>Creatinine (mg/dL), median (IQR)</td><td>0.9 (0.7–1.2)</td><td>1.4 (0.9–2.3)</td><td><0.001</td></tr></tbody></table><figcaption>Table 1. Baseline characteristics of patients presenting to the emergency department with suspected infection, stratified by sepsis status within 24 hours.</figcaption></figure><h4>Model Performance</h4><p>Table 2 summarizes the performance of all models on the test set. The gradient boosting machine (GBM) achieved the highest AUROC of 0.89 (95% CI: 0.87–0.91), followed by random forest (0.87), neural network (0.86), and logistic regression (0.82). All ML models outperformed SIRS (AUROC 0.68) and qSOFA (AUROC 0.71).</p><figure class="table-figure"><table><thead><tr><th>Model</th><th>AUROC (95% CI)</th><th>Sensitivity</th><th>Specificity</th><th>PPV</th><th>F1-Score</th></tr></thead><tbody><tr><td>Logistic Regression</td><td>0.82 (0.80–0.84)</td><td>0.75</td><td>0.78</td><td>0.38</td><td>0.50</td></tr><tr><td>Random Forest</td><td>0.87 (0.85–0.89)</td><td>0.80</td><td>0.82</td><td>0.45</td><td>0.58</td></tr><tr><td>Gradient Boosting</td><td>0.89 (0.87–0.91)</td><td>0.82</td><td>0.84</td><td>0.49</td><td>0.61</td></tr><tr><td>Neural Network</td><td>0.86 (0.84–0.88)</td><td>0.79</td><td>0.81</td><td>0.43</td><td>0.56</td></tr><tr><td>SIRS (≥2 criteria)</td><td>0.68 (0.66–0.70)</td><td>0.71</td><td>0.54</td><td>0.22</td><td>0.34</td></tr><tr><td>qSOFA (≥2 criteria)</td><td>0.71 (0.69–0.73)</td><td>0.42</td><td>0.89</td><td>0.41</td><td>0.41</td></tr></tbody></table><figcaption>Table 2. Performance metrics of machine learning models and conventional screening tools for predicting sepsis within 24 hours of triage in the test set (n=5,506).</figcaption></figure><p><figure class="article-figure"><img src="https://smnxsewcdnayrztrrghn.supabase.co/storage/v1/object/public/journal-assets/scholarly/machine-learning-for-early-sepsis-detection-in-emergency-departments-a-retrospective-cohort-study-9i6d4/figure-1-1779954721486.octet-stream" alt="Receiver operating characteristic (ROC) curves comparing the four machine learning models and conventional screening tools (SIRS, qSOFA) for sepsis prediction." loading="lazy" style="max-width:100%;height:auto;" /><figcaption>Figure 1. Receiver operating characteristic (ROC) curves comparing the four machine learning models and conventional screening tools (SIRS, qSOFA) for sepsis prediction.</figcaption></figure></p><h4>Feature Importance</h4><p>Figure 2 shows the top 10 features by importance from the GBM model. The most important predictors were heart rate, respiratory rate, temperature, white blood cell count, lactate, and age.</p><p><figure class="article-figure"><img src="https://smnxsewcdnayrztrrghn.supabase.co/storage/v1/object/public/journal-assets/scholarly/machine-learning-for-early-sepsis-detection-in-emergency-departments-a-retrospective-cohort-study-9i6d4/figure-2-1779954729177.octet-stream" alt="Bar chart of feature importance (Gini impurity decrease) for the top 10 predictors in the gradient boosting model." loading="lazy" style="max-width:100%;height:auto;" /><figcaption>Figure 2. Bar chart of feature importance (Gini impurity decrease) for the top 10 predictors in the gradient boosting model.</figcaption></figure></p><h4>Calibration and Clinical Impact</h4><p>The GBM model demonstrated good calibration (Brier score 0.12). In a simulated deployment at a threshold achieving 90% sensitivity, the ML alert would have triggered a median of 2.3 hours (IQR 1.1–4.0) earlier than clinical recognition (documented sepsis diagnosis or antibiotic initiation).</p>
<h2>Discussion</h2>
<p>In this retrospective cohort study, we developed and validated a machine learning model that accurately predicts sepsis within 24 hours of ED triage using routinely collected data. The gradient boosting model achieved an AUROC of 0.89, outperforming conventional screening tools (SIRS and qSOFA) and demonstrating good calibration. These findings align with prior studies (Kijpaisalratana et al., 2022; Xie et al., 2024) and extend the evidence by evaluating multiple algorithms in a large, contemporary cohort.</p><p>The superiority of ML models over SIRS and qSOFA underscores the limitations of simple rule-based scores. As noted by Hwang et al. (2020), these tools trade sensitivity for specificity or vice versa. Our GBM model achieved a sensitivity of 0.82 and specificity of 0.84, indicating balanced performance. Importantly, the model identified patients a median of 2.3 hours earlier than clinical recognition, suggesting potential to reduce time to antibiotics—a key driver of sepsis outcomes (Rehman et al., 2022; Kijpaisalratana et al., 2024).</p><p>The most influential predictors—vital signs and lactate—are consistent with pathophysiological understanding of sepsis. However, the inclusion of comorbidities and triage acuity likely added discriminative power. Unlike some studies (Brann et al., 2023), we did not incorporate unstructured text data, which may further improve performance.</p><p>Our study has several limitations. First, it is a single-center retrospective design, limiting generalizability. The cohort may not represent other populations with different case mixes or EHR systems. Second, we used imputation for missing data, which may introduce bias if missingness is not random. Third, the outcome definition relied on SOFA score changes, which may be incomplete in the ED setting. Fourth, we did not assess the impact of the model on clinical outcomes prospectively; simulation results are hypothetical. Finally, we did not evaluate fairness across demographic subgroups, which is critical given concerns about algorithmic bias (Challen et al., 2019).</p><p>Despite these limitations, our findings support the potential utility of ML for early sepsis detection. Implementation studies, such as the cluster-randomized trial by Kijpaisalratana et al. (2024), are needed to evaluate real-world effectiveness, workflow integration, and alert fatigue. Future work should also explore multi-center validation, incorporation of prehospital data (Desai et al., 2022), and natural language processing of triage notes (Brann et al., 2023).</p>
<h2>Conclusion</h2>
<p>Machine learning models, particularly gradient boosting, can accurately predict sepsis within 24 hours of ED triage using routinely available clinical data. These models outperform traditional screening tools and may enable earlier intervention. Prospective validation and implementation research are necessary to translate these findings into clinical practice and improve outcomes for septic patients.</p>
<h2>References</h2>
<ol class="references">
<li>Kijpaisalratana, N., Sanglertsinlapachai, D., Techaratsami, S., Musikatavorn, K., Saoraya, J. (2022). Machine learning algorithms for early sepsis detection in the emergency department: A retrospective study. <em>International Journal of Medical Informatics</em>, <em>160</em>, 104689. https://doi.org/10.1016/j.ijmedinf.2022.104689</li>
<li>Xie, J., Gao, J., Yang, M., Zhang, T., Liu, Y., Chen, Y. (2024). Prediction of sepsis within 24 hours at the triage stage in emergency departments using machine learning. <em>World Journal of Emergency Medicine</em>, <em>15</em>(5), 379. https://doi.org/10.5847/wjem.j.1920-8642.2024.074</li>
<li>Rajan, J. J., Rodzevik, T. (2021). Sepsis Awareness to Enhance Early Identification of Sepsis in Emergency Departments. <em>The Journal of Continuing Education in Nursing</em>, <em>52</em>(1), 39-42. https://doi.org/10.3928/00220124-20201215-10</li>
<li>Unknown (2016). New strategy aims to ensure early detection of sepsis. <em>Emergency Nurse</em>, <em>23</em>(9), 6-6. https://doi.org/10.7748/en.23.9.6.s4</li>
<li>Unknown (2023). Mortality prediction of patients with sepsis in the emergency department using machine learning models: a retrospective cohort study according to the Sepsis-3 definitions. <em>Signa Vitae</em>. https://doi.org/10.22514/sv.2023.046</li>
<li>Garstman, A. G., Rodriguez Rivero, C., Onland, W. (2023). Early Detection of Late Onset Sepsis in Extremely Preterm Infants Using Machine Learning: Towards an Early Warning System. <em>Applied Sciences</em>, <em>13</em>(16), 9049. https://doi.org/10.3390/app13169049</li>
<li>Rehman, K. U., Qazi, R. A., Sayed, T. M. (2022). Early Diagnosis of Sepsis in Emergency Departments, Time to Treatment and Association with Mortality. <em>Pakistan Journal of Medical & Health Sciences</em>, <em>16</em>(10), 462-463. https://doi.org/10.53350/pjmhs221610462</li>
<li>Desai, M. D., Tootooni, M. S., Bobay, K. L. (2022). Can Prehospital Data Improve Early Identification of Sepsis in Emergency Department? An Integrative Review of Machine Learning Approaches. <em>Applied Clinical Informatics</em>, <em>13</em>(01), 189-202. https://doi.org/10.1055/s-0042-1742369</li>
<li>Sherwin, R., Ying, H. (2018). 14 Results of 20 Machine-Learning Techniques to Identify Sepsis Patients in the Emergency Department. <em>Annals of Emergency Medicine</em>, <em>72</em>(4), S6-S7. https://doi.org/10.1016/j.annemergmed.2018.08.019</li>
<li>Sungkar, Y., Considine, J., Hutchinson, A. (2018). Implementation of guidelines for sepsis management in emergency departments: A systematic review. <em>Australasian Emergency Care</em>, <em>21</em>(4), 111-120. https://doi.org/10.1016/j.auec.2018.10.003</li>
<li>Kumar Saini, M. (2023). Machine Learning Innovations in Early Cardiovascular Disease Detection. <em>International Journal of Science and Research (IJSR)</em>, <em>12</em>(10), 2171-2182. https://doi.org/10.21275/sr23101210074</li>
<li>Kelly, A., Pannifex, J. (2017). Improving Recognition and Initial Treatment of Sepsis in Victorian Emergency Departments. <em>The Journal of Emergency Medicine</em>, <em>53</em>(3), 437-438. https://doi.org/10.1016/j.jemermed.2017.08.050</li>
<li>Elhaj, H., Achour, N., Hoque Tania, M., Aciksari, K. (2022). Machine Learning-Based Triage System to Predict Patient Outcomes in Hospital Emergency Departments. <em>SSRN Electronic Journal</em>. https://doi.org/10.2139/ssrn.4263538</li>
<li>Unknown (2022). The Potential Cost and Cost-Effectiveness Impact of Using a Machine Learning Algorithm for Early Detection of Sepsis in Intensive Care Units in Sweden. <em>Journal of Health Economics and Outcomes Research</em>, <em>9</em>(1), 101-110. https://doi.org/10.36469/jheor.2022.33951</li>
<li>Hwang, M., Bond, W., Powell, E. (2020). Sepsis Alerts in Emergency Departments: A Systematic Review of Accuracy and Quality Measure Impact. <em>Western Journal of Emergency Medicine</em>, <em>21</em>(5). https://doi.org/10.5811/westjem.2020.5.46010</li>
<li>Sivayoham, N. (2007). Management of severe sepsis and septic shock in the emergency department: a survey of current practice in emergency departments in England. <em>Emergency Medicine Journal</em>, <em>24</em>(6), 422-422. https://doi.org/10.1136/emj.2007.046060</li>
<li>Aljubran, M., Aljubran, H., Aljubran, M., Alkhalifah, M., Alkhalifah, M., Alabdullah, T. (2023). The utilizing of machine learning algorithms to improve triage in emergency departments: a retrospective observational study. <em>Saudi Journal of Emergency Medicine</em>, 354-361. https://doi.org/10.24911/sjemed/72-1673885230</li>
<li>Mahyoub, M. A., Yadav, R. R., Dougherty, K., Shukla, A. (2023). Development and validation of a machine learning model integrated with the clinical workflow for early detection of sepsis. <em>Frontiers in Medicine</em>, <em>10</em>. https://doi.org/10.3389/fmed.2023.1284081</li>
<li>Healthcare Engineering, J. o. (2023). Retracted: A Machine Learning Model for Early Prediction and Detection of Sepsis in Intensive Care Unit Patients. <em>Journal of Healthcare Engineering</em>, <em>2023</em>(1). https://doi.org/10.1155/2023/9864369</li>
<li>Davazdahemami, B., Peng, P., Delen, D. (2022). A deep learning approach for predicting early bounce-backs to the emergency departments. <em>Healthcare Analytics</em>, <em>2</em>, 100018. https://doi.org/10.1016/j.health.2022.100018</li>
<li>Dean, E. (2013). Guidance urges pregnancy checks for women of reproductive age. <em>Emergency Nurse</em>, <em>20</em>(10), 9-9. https://doi.org/10.7748/en2013.03.20.10.9.p10733</li>
<li>Henry, K. E., Adams, R. J., Parent, C., Soleimani, H., Sridharan, A., Johnson, L. (2022). Factors driving provider adoption of the TREWS machine learning-based early warning system and its effects on sepsis treatment timing. <em>Nature Medicine</em>, <em>28</em>(7), 1447-1454. https://doi.org/10.1038/s41591-022-01895-z</li>
<li>Evans, L., Rhodes, A., Alhazzani, W., Antonelli, M., Coopersmith, C. M., French, C. (2021). Surviving sepsis campaign: international guidelines for management of sepsis and septic shock 2021. <em>Intensive Care Medicine</em>, <em>47</em>(11), 1181-1247. https://doi.org/10.1007/s00134-021-06506-y</li>
<li>Evans, L., Rhodes, A., Alhazzani, W., Antonelli, M., Coopersmith, C. M., French, C. (2021). Surviving Sepsis Campaign: International Guidelines for Management of Sepsis and Septic Shock 2021. <em>Critical Care Medicine</em>, <em>49</em>(11), e1063-e1143. https://doi.org/10.1097/ccm.0000000000005337</li>
<li>Brann, F., Sterling, N. W., Frisch, S., Schrager, J. D. (2023). Sepsis Prediction at Emergency Department Triage Using Natural Language Processing: Retrospective Cohort Study. <em>JMIR AI</em>, <em>3</em>, e49784-e49784. https://doi.org/10.2196/49784</li>
<li>Kijpaisalratana, N., Saoraya, J., Nhuboonkaew, P., Vongkulbhisan, K., Musikatavorn, K. (2024). Real-time machine learning-assisted sepsis alert enhances the timeliness of antibiotic administration and diagnostic accuracy in emergency department patients with sepsis: a cluster-randomized trial. <em>Internal and Emergency Medicine</em>, <em>19</em>(5), 1415-1424. https://doi.org/10.1007/s11739-024-03535-5</li>
<li>Aguirre, U., Urrechaga, E. (2022). Diagnostic performance of machine learning models using cell population data for the detection of sepsis: a comparative study. <em>Clinical Chemistry and Laboratory Medicine (CCLM)</em>, <em>61</em>(2), 356-365. https://doi.org/10.1515/cclm-2022-0713</li>
<li>Challen, R., Denny, J. C., Pitt, M., Gompels, L., Edwards, T., Tsaneva‐Atanasova, K. (2019). Artificial intelligence, bias and clinical safety. <em>BMJ Quality & Safety</em>, <em>28</em>(3), 231-237. https://doi.org/10.1136/bmjqs-2018-008370</li>
<li>Benjamens, S., Dhunnoo, P., Meskó, B. (2020). The state of artificial intelligence-based FDA-approved medical devices and algorithms: an online database. <em>npj Digital Medicine</em>, <em>3</em>(1), 118-118. https://doi.org/10.1038/s41746-020-00324-0</li>
<li>Desautels, T., Calvert, J., Hoffman, J., Jay, M., Kerem, Y., Shieh, L. (2016). Prediction of Sepsis in the Intensive Care Unit With Minimal Electronic Health Record Data: A Machine Learning Approach. <em>JMIR Medical Informatics</em>, <em>4</em>(3), e28-e28. https://doi.org/10.2196/medinform.5909</li>
</ol>
</article>