To develop and validate a prediction model for in-hospital cardiogenic shock (CS) after percutaneous coronary intervention (PCI) in patients with acute myocardial infarction (AMI) based on machine learning (ML) algorithms. A total of 1608 AMI patients admitted to the First Hospital of Lanzhou University during 2023 and 2024 were retrospectively enrolled in this study. The 851 patients from 2023 were randomly divided into a training set (n = 595) and a validation set (n = 256) at a ratio of 7:3. The LASSO–Boruta combined algorithm was used for feature selection, resulting in the construction of six ML models. The validation set was used for internal validation, while the patients enrolled from 2024 served as a temporal external validation cohort in a test set (n = 757). Model performance was evaluated using various metrics, including the area under the receiver operating characteristic curve (AUROC), accuracy, sensitivity, precision, and F1 score. Additionally, SHAP analysis was employed to interpret the contribution of the selected features. An online prediction application based on the Streamlit framework was developed. LASSO regression initially identified 13 candidate features, while the random forest (RF) model demonstrated the best predictive performance in the training set. Following Boruta refinement, seven key features were retained, leading to the construction of an updated RF model. This model achieved an AUROC of 0.906, an accuracy of 0.977, a precision of 0.900, a sensitivity of 0.643, a specificity of 0.996, and a F1 score of 0.750 on the internal validation set. Temporal external validation at the same center showed an AUROC of 0.988, an accuracy of 0.967, a precision of 0.701, a sensitivity of 0.904, a specificity of 0.972, and a F1 score of 0.790. Furthermore, the model demonstrated excellent calibration, with a Brier score of 0.023 and 0.027. The SHAP analysis ranked feature importance as Killip class, D-dimer (DD), creatinine (Crea), alanine aminotransferase (ALT), apolipoprotein B/A (APOB/A), diastolic blood pressure (DBP) and lactate (Lac). We developed and validated a RF model based on seven key variables—Killip class, DD, Crea, ALT, APOB/A, DBP and Lac—that serves as a predictive tool for identifying the risk of in-hospital CS in AMI patients post-PCI. Additionally, we created an online prediction application using Streamlit, which facilitates the implementation of this model into clinical practice.
Du et al. (Wed,) studied this question.