AUTHOR=Fu Jiwei , Wu Ahao , Zhou Ziwei , Deng Ting , Shi Pei , Zhu Wentao , Tao Mengyu , Zeng Yuyu , Peng Yuchen , Wang Yuna , Wu Xiaoping TITLE=Predicting the gastrointestinal bleeding of HBV-related acute-on-chronic liver failure based on machine learning JOURNAL=Frontiers in Medicine VOLUME=Volume 12 - 2025 YEAR=2025 URL=https://www.frontiersin.org/journals/medicine/articles/10.3389/fmed.2025.1516476 DOI=10.3389/fmed.2025.1516476 ISSN=2296-858X ABSTRACT=BackgroundThis study aimed to investigate the effect of gastrointestinal bleeding (GIB) on the short-term survival of hepatitis B virus-related acute-on-chronic liver failure (HBV-ACLF) patients, establish a prediction model for HBV-ACLF-related GIB via machine learning (ML) algorithms, and compare the predictive ability of various models.MethodsA total of 583 HBV-ACLF patients from two medical centers were retrospectively enrolled, and patients from one of the centers were randomly divided into a training cohort (n = 360) and a test cohort (n = 153) at a 7:3 ratio. Patients from the other center composed the validation cohort (n = 70). Patients were divided into GIB and non-gastrointestinal bleeding (NGIB) groups according to whether they had GIB during hospitalization, and short-term survival rates were compared between the two groups. Least absolute shrinkage and selection operator (LASSO) regression was used to screen for features associated with GIB. On the basis of the screened features, we used five ML algorithms, namely, logistic regression (LR), support vector machine (SVM), decision tree (DT), random forest (RF), and K-nearest neighbors (KNN), to build a prediction model for GIB. Six metrics, namely, accuracy, area under the curve (AUC), sensitivity, specificity, positive predictive value (PPV), and negative predictive value (NPV), were used to evaluate the predictive ability of these models.ResultsIn the training cohort, patients in the GIB group had significantly lower 30- and 90-day survival rates than did those in the NGIB group (48.72% versus 85.67% and 10.26% versus 64.80%, respectively), and similar results were obtained in the test cohort and the validation cohort. LASSO regression screened seven features associated with GIB, of which portal hypertension, electrolyte disturbance, and white blood cell counts were modeled features common to the five machine prediction models. The AUCs of the LR, SVM, DT, RF, and KNN models in the training cohort were 0.819, 0.924, 0.661, 1.000, and 0.865, respectively. Compared with the other four models, the LR model had the lowest PPV of 0.202 in the test cohort, the SVM model had the lowest AUC and sensitivity of 0.657 and 0.500 in the validation cohort, the DT model had the lowest sensitivity of 0.436 and 0.438 in the training and test cohorts, respectively, and the KNN model had the lowest PPV of 0.250 in the validation cohort. Notably, the RF model had the least fluctuations in accuracy, AUC, sensitivity, specificity, PPV, and NPV among the 3 cohorts, with good overall predictive ability.ConclusionGIB has a significant effect on short-term survival in patients with HBV-ACLF. On this basis, five ML prediction models, LR, SVM, DT, RF, and KNN, were established to have better prediction ability for GIB, among which the RF model has the most robust prediction performance, which can help clinicians intervene in advance and improve the short-term survival rate of patients.