AN EXPLAINABLE ARTIFICIAL INTELLIGENCE-BASED STACKING ENSEMBLE FOR HEART FAILURE MORTALITY PREDICTION: A DATA-LEAKAGE-FREE CLINICAL DECISION SUPPORT APPROACH

Fadime ERINCI, Emek GULDOGAN, Cemil COLAK

Medicine Science - 2026;15(3):1410-1417

İnönü University, Institute of Health Sciences, Department of Biostatistics and Medical Informatics, Malatya, Türkiye

 

Accurate mortality risk prediction at emergency department admission is critical for triage and patient safety in heart failure. We aimed to develop a data-leakage-free stacking ensemble model predicting mortality from baseline variables, targeting high sensitivity for clinical safety, and utilizing Explainable Artificial Intelligence (XAI). A publicly available dataset of 299 heart failure patients was analyzed retrospectively. To prevent data leakage, the follow-up time variable was excluded. Class imbalance was addressed by applying the Synthetic Minority Oversampling Technique (SMOTE) exclusively to the training set. A stacking ensemble model was constructed using Random Forest, XGBoost, and LightGBM as base learners, with Logistic Regression as the meta-learner. To reflect clinical priorities, the decision threshold was optimized solely on the training set to achieve >= 85% sensitivity. Model interpretability was assessed using SHapley Additive exPlanations (SHAP). The stacking model achieved an area under the curve (AUC) of 0.838. On the test set, it reached 89.5% sensitivity and 92.3% negative predictive value (NPV), reliably identifying high-risk patients. SHAP analysis confirmed clinical plausibility, showing predictions were primarily driven by acute indicators (serum creatinine, ejection fraction, and age) rather than chronic comorbidities. This data-leakage-free stacking ensemble provides a transparent and reliable decision support tool for heart failure triage. Its high sensitivity and integration of XAI methods can significantly enhance clinician confidence in AI-assisted evaluations.