Abstract
BACKGROUND: Compassion fatigue (CF) significantly affects nurses’ workplace psychology and care quality, yet its status among geriatric nurses is underexplored and challenging to manage. OBJECTIVE: This study examines the prevalence of CF in geriatric nurses and develops a predictive model. METHODS: Geriatric nurses from 90 hospitals across China were surveyed using four scales to assess CF prevalence. Univariate and multivariate logistic regression and Pearson correlation analyses identified key factors. Multiple machine learning algorithms were used to construct predictive models, validated internally and externally. RESULTS: CF prevalence was 92.8%, primarily at moderate to severe levels. Key risk factors included middle and night shift, average daily work hours, income satisfaction, neuroticism, extraversion, and support utilization. Thirteen variables were selected via Lasso and Boruta for model building. The Extreme Gradient Boosting model outperformed Support Vector Machines and K-Nearest Neighbors. The optimal Naive Bayes model achieved internal validation accuracy of 0.75, precision 0.87, F1 score 0.75, specificity 0.90, sensitivity 0.74, and AUC 0.96. SHAP analysis highlighted neuroticism, agreeableness, and extraversion as key contributors. A web application was developed for management support. CONCLUSION: This multicenter study identified high CF prevalence in geriatric nurses and created a concise, interpretable predictive model, providing a tool for nursing management. GRAPHICAL ABSTRACT: [Image: see text] SUPPLEMENTARY INFORMATION: The online version contains supplementary material available at 10.1186/s12877-026-07223-1.