Development and validation of an early risk prediction model based on inflammatory and metabolically derived markers for early diagnosis of diabetic kidney disease Authors: Xu Liu, Wanting Zhao, Yu Fu, Yan Yu, Min Chen, Yimin Yao, Ying Yu Published: 2026 ABSTRACT AbstractWith the global prevalence of diabetic kidney disease (DKD) continuing to rise, its early diagnosis remains challenging due to the limitations of existing clinical methods. This study integrates pathological diagnostic data using machine learning (ML), employing feature selection, multi-model comparison, and model evaluation to construct a high-precision early prediction model. This retrospective study enrolled patients from Zhejiang Provincial Hospital of Traditional Chinese Medicine and Hangzhou Hospital of Traditional Chinese Medicine, including individuals newly diagnosed with diabetes mellitus (DM) and those pathologically confirmed with DKD. A machine learning-compatible dataset was constructed, comprising 209 cases in the training set and 42 cases in the external validation set. Key predictors were screened using univariate logistic regression and Lasso regression. ML algorithms, including XGBoost, random forest, and logistic regression, were employed to construct models. A comparative analysis of binary classification models revealed that the XGBoost model achieved optimal diagnostic performance. The model underwent internal cross-validation and external multicenter validation, with performance evaluated using Receiver Operating Characteristic (ROC) curves, sensitivity and specificity, Decision Curve Analysis (DCA), and calibration curves to assess discriminative power and clinical utility. 1. Significant differences (P < 0.05) in hematological and biochemical parameters were observed between the DKD and DM groups. Independent risk factors for DKD included the Uric Acid to High-Density Lipoprotein Cholesterol Ratio (UHR), Neutrophil to High-Density Lipoprotein Ratio (NHR), Systemic Immune-Inflammatory Index (SII), Homocysteine (HCY), Platelet Distribution Width (PDW), and Albumin (ALB). 2. The XGBoost model, constructed using key variables, outperformed other models in both training and validation sets. Internal validation yielded an AUC of 0.83, while external validation yielded 0.80. Critical predictors (HCY, UHR, NHR) exhibited AUC values of 0.79, 0.78, and 0.78, respectively. The model demonstrated balanced performance with sensitivity (0.63), specificity (0.90), and accuracy (77%), confirming its robust diagnostic capability. The XGBoost-based diagnostic prediction model effectively integrates novel inflammatory and metabolic indicators, enabling high-precision early diagnosis of DKD with significant clinical applicability.Keywords: Diabetic kidney disease, Machine learning, Diagnostic markers, Predictive modelSubject terms: Biomarkers, Computational biology and bioinformatics, Diseases, Endocrinology, Medical research, Risk factors Introduction With ongoing lifestyle changes and population aging, the incidence of type 2 diabetes mellitus (T2DM) continues to rise. Epidemiological data show that in 2021, the global prevalence of T2DM among adults aged 20–79 years was 10.5% (approximately 536.6 million people)1. It is projected that by 2050, the number of affected individuals worldwide will exceed 1.31 billion2. In China, the current prevalence of diabetes among adults has reached 12.8%, with an estimated 129.8 million patients, predominantly characterized by T2DM, while type 1 diabetes and other forms of diabetes are less common3. Notably, the prevalence of chronic kidney disease (CKD) among individuals with T2DM in China is 36%4. DKD, a major microvascular complication of diabetes, represents a growing public health burden. The diagnosis of DKD encompasses both pathological and clinical criteria. Currently, the clinical diagnosis of DKD relies on the urine albumin-to-creatinine ratio (UACR) and estimated glomerular filtration rate (eGFR). However, early-stage DKD is often asymptomatic, making timely diagnosis challenging. A key early characteristic is a supra-physiological increase in the glomerular filtration rate, known as glomerular hyperfiltration. In patients with diabetes, hyperfiltration typically precedes the onset of albuminuria and/or a decline in renal function5. Once the stage of macroalbuminuria is reached, the progression to end-stage renal disease (ESRD) occurs approximately 14 times faster than with other kidney diseases6. A decrease in GFR often signifies substantial loss of renal function and severe glomerular damage, contributing to low early diagnosis rates of DKD7. Furthermore, studies have indicated that relying solely on a single eGFR measurement to assess overall renal function progression is relatively unreliable and inefficient for individual patients. This limitation arises because current eGFR equations are population-based and do not account for individual variability8,9. Although several diagnostic models for DKD progression based on clinical laboratory indicators have been developed10, such models generally suffer from low specificity and sensitivity, and there is a particular lack of models capable of early-stage DKD risk assessment. Therefore, there is an urgent clinical need for novel biomarkers with high sensitivity and specificity to predict early renal injury and monitor DKD progression. The renal pathological hallmark of DKD is progressive glomerulopathy. Renal biopsies from diabetic patients, regardless of the presence of albuminuria, commonly reveal characteristic histopathological features. These include glomerular basement membrane (GBM) thickening, mesangial proliferation, endothelial alterations, and podocyte injury11. Pathological diagnosis requires an invasive procedure—renal biopsy—with subsequent histological staging and classification based on the examination of tissue sections. Renal biopsy is indicated for diabetic patients presenting with rapidly progressive disease, hematuria, or atypical clinical manifestations to achieve a definitive diagnosis. Although DKD has been extensively studied, the mechanisms underlying its progression remain incompletely understood. Current research suggests that the pathogenesis of DKD primarily involves alterations in organ-level morphology and architecture, endothelial changes, glomerular basement membrane thickening, mesangial expansion, cell death, and dysregulation of intracellular signaling pathways12. Inflammation is recognized as a potential mechanism driving the progression from type 2 diabetes to DKD. However, due to the high cost and technical demands of measuring specific inflammatory markers, they are not widely used in routine clinical practice. In recent years, growing research has shifted toward developing novel diagnostic markers, such as neutrophil-to-high-density-lipoprotein ratio (NHR), lymphocyte-to-monocyte ratio (LMR), and monocyte-to-high-density-lipoprotein ratio (MHR)—derived from routine blood and biochemical parameters. These markers have shown potential for early detection and risk stratification of DKD13,14. In recent years, as a critical branch of artificial intelligence, ML has demonstrated considerable promise and broad application prospects in the medical field15. By analyzing large-scale patient data—such as age, lifestyle, dietary habits, and body weight—ML algorithms, including Naïve Bayes, k-nearest neighbors (KNN), and decision trees, have been employed to predict the onset and progression of diseases such as diabetes. In the context of early diagnosis of DKD, although some diagnostic and prognostic models have been developed, most studies lack external validation, resulting in limited generalizability16. Moreover, these models are predominantly based on clinical diagnoses rather than pathological confirmation. To address these limitations, this study leverages pathological diagnosis as the reference standard and incorporates a control group of patients with type 2 diabetes for differential indicator analysis. Our objective is to develop and validate a high-accuracy diagnostic prediction model to enable early identification and diagnosis of DKD. Materials and methods Data source and ethical considerations The data for this study were obtained from the First Affiliated Hospital of Zhejiang Chinese Medical University. All collected data underwent de-identification procedures. The study protocol was approved by the Ethics Committee of The First Affiliated Hospital of Zhejiang Chinese Medical University (Approval No.: 2025-KL-848-01). The need to obtain informed consent was waived by the Ethics Committee of the First Affiliated Hospital of Zhejiang Chinese Medical University. This study was conducted in accordance with the Declaration of Helsinki and the local laws and regulations of China. Study participants A total of 209 participants were included in the model training set. This comprised 100 patients with pathologically confirmed DKD, classified as pathological stages I and II, who were hospitalized in the Endocrinology and Nephrology Departments of the First Affiliated Hospital of Zhejiang Chinese Medical University between January 1, 2022, and February 1, 2025. Additionally, 109 patients newly diagnosed with T2DM during the same period at our hospital were included as the control group. For the external validation set, 42 participants were selected from the Hangzhou Hospital of Chinese Medicine within the same timeframe. This cohort included 18 patients with pathologically confirmed DKD (stages I and II) and 24 concurrently enrolled patients newly diagnosed with T2DM (Fig. 1). Experimental design flowchart. Diagnostic criteria Diagnostic criteria for diabetes mellitus The diagnosis was established based on the presence of typical clinical manifestations (such as polydipsia, polyphagia, polyuria, and unexplained weight loss), coupled with at least one of the following laboratory findings, in accordance with the Chinese Guideline for the Prevention and Treatment of Type 2 Diabetes Mellitus (2020 Edition)17. Details are provided in Table 1. Table 1Diagnostic criteria for diabetes mellitus.Diagnostic criteriaVenous plasma glucose or HbA1c levelWith typical diabetic symptoms Plus random plasma glucose≥ 11.1 mmol/L Or plus fasting plasma glucose≥ 7.0 mmol/L Or plus 2-hour plasma glucose during OGTT≥ 11.1 mmol/L Or plus HbA1c≥ 6.5 mmol/LFor individuals without typical diabetic symptoms, the result must be confirmed by repeat testing on a separate day. OGTT denotes oral glucose tolerance test; HbA1c denotes glycated hemoglobin. Typical diabetic symptoms include polydipsia, polyuria, polyphagia, and unexplained weight loss. Random plasma glucose refers to a blood glucose measurement taken at any time of day, regardless of the time of the last meal; it cannot be used to diagnose impaired fasting glucose or impaired glucose tolerance. The fasting state is defined as no caloric intake for at least 8 h. Diagnostic criteria for diabetes mellitus. For individuals without typical diabetic symptoms, the result must be confirmed by repeat testing on a separate day. OGTT denotes oral glucose tolerance test; HbA1c denotes glycated hemoglobin. Typical diabetic symptoms include polydipsia, polyuria, polyphagia, and unexplained weight loss. Random plasma glucose refers to a blood glucose measurement taken at any time of day, regardless of the time of the last meal; it cannot be used to diagnose impaired fasting glucose or impaired glucose tolerance. The fasting state is defined as no caloric intake for at least 8 h. Diagnostic and staging criteria for DKD The Renal Pathology Society’s pathological grading criteria18 were used to diagnose and stage DKD. Typical glomerular pathological changes in DKD include GBM thickening, mesangial matrix expansion, and glomerulosclerosis. Early-stage DKD was defined as pathological classes I, IIa, and IIb. Class I: Characterized by GBM thickening alone. Light microscopy reveals no or only mild, nonspecific changes, whereas electron microscopy demonstrates GBM thickening (> 395 nm in females and > 430 nm in males aged ≥ 9 years). Pathological changes do not meet the criteria for classes II, III, or IV. Class IIa: Mild mesangial matrix expansion, affecting > 25% of glomeruli. Pathological changes do not meet the criteria for classes III or IV. Class IIb: Severe mesangial matrix expansion, affecting > 25% of glomeruli. Pathological changes do not meet the criteria for classes III or IV. Inclusion criteria Complete clinical data; Complete clinical data; Clinical diagnosis of diabetes mellitus; Clinical diagnosis of diabetes mellitus; Pathologically confirmed diagnosis of diabetic kidney disease by renal biopsy during. Pathologically confirmed diagnosis of diabetic kidney disease by renal biopsy during. Exclusion criteria Pathologically diagnosed non-diabetic renal disease (NDRD); Pathologically diagnosed non-diabetic renal disease (NDRD); Clinically diagnosed systemic diseases or acute infections, such as autoimmune diseases, systemic lupus erythematosus, or urinary tract infections; Clinically diagnosed systemic diseases or acute infections, such as autoimmune diseases, systemic lupus erythematosus, or urinary tract infections; History of diabetic ketoacidosis within one month before hospitalization; History of diabetic ketoacidosis within one month before hospitalization; Clinically diagnosed history of malignant tumors. Clinically diagnosed history of malignant tumors. Study content For eligible patients, case data were extracted from the hospital’s inpatient medical record system. The collected data encompassed general information, laboratory parameters, and renal biopsy pathological findings. These included age, sex, body mass index (BMI), duration of diabetes (defined as the time from initial diabetes diagnosis to renal biopsy), history of hypertension, complete blood count, and various biochemical indicators. Study design See Fig. 1. Statistical analysis Data preprocessing was performed prior to model development and validation18. some hospitalized patients had missing laboratory indicators, but the proportion of missing data was less than 5% and was deemed missing completely at random. The random forest method was employed to impute these mi ssing values19. Outliers were identified using the 3σ principle and replaced by the median to minimize bias. All continuous variables were standardized to Z-scores to eliminate dimensional influences. The class distribution was balanced: the training set included 100 DKD patients and 109 patients with DM alone, and the external validation set included 18 DKD patients and 24 patients with DM alone, with no severe class imbalance observed. This study strictly applied the inclusion and exclusion criteria. All DKD patients were diagnosed by renal biopsy. Consecutive enrollment was adopted to minimize selection bias. First, univariate logistic regression was used for preliminary screening of potential indicators, and variables with P < 0.05 were included as candidate features to avoid missing potentially valuable predictors. Subsequently, Lasso regression with 5-fold cross-validation was applied for further variable selection. The optimal λ value was determined based on the minimum cross-validation error, and variables with non-zero coefficients were retained. The primary outcome variable was DKD diagnostic status. Continuous variables were summarized differently based on their distribution: those following a normal distribution are presented as mean ± standard deviation, while non-normally distributed variables are described using median (interquartile range). Categorical variables are expressed as frequency (percentage). For between-group comparisons, independent-samples t-tests were used for continuous variables, and chi-square tests were used for categorical variables. In this study, strict data harmonization and standardized preprocessing were applied to the external validation dataset20,21. The two hospitals used identical inclusion and exclusion criteria, variable definitions, missing value imputation methods, outlier processing rules, and calculation formulas for derived variables. All laboratory parameters were measured using routine clinical assays in each hospital, and unit standardization was performed to ensure data comparability across centers. Machine learning model development ML algorithms were processed on the Deepwise and Beckman Coulter DxAI platform. This platform supports ML modeling (including XGBoost, Random Forest, and Logistic Regression) for analytical data. Patients were split into training and validation sets in a 7:3 ratio. Variables found to be statistically significant in the univariate analysis were assessed for multicollinearity. Using multiple cross-validation, six distinct ML prediction models were constructed based on six key parameters: XGBoost, Logistic Regression, Light GBM, AdaBoost, Support Vector Machine, and Random Forest. All comparison methods use the exact same data preprocessing, training process, validation, and evaluation methods. They also used identical 5‑fold cross‑validation in the training set to ensure reliable and fair comparison22. The XGBoost model maintained consistent hyperparameters in both the training and validation cohorts, with the following settings: learning rate = 0.3, max depth = 6, min child weight = 2, and L2 regularization parameter (lambda) = 1. The discriminatory ability of each model was evaluated using the Receiver Operating Characteristic (ROC) curve to identify the optimal predictive model. Calibration curves were used to assess the calibration performance of the models in both the training and validation sets. DCA was applied to evaluate the clinical utility of the models. Based on the final model, an online prediction tool was developed. A P-value < 0.05 was considered statistically significant for all analyses. XGBoost model The XGBoost model is an efficient ML algorithm based on the gradient boosting framework23. It achieves iterative performance improvement by integrating multiple weak decision trees and optimizing the objective function. Its core mechanisms include gradient boosting strategy, regularization design, parallelization and engineering optimization, and flexible extensibility. This model excels in feature importance evaluation, data processing, and modeling nonlinear relationships. This study employs the XGBoost model to analyze risk factors for Diabetic Kidney Disease. It quantifies variable importance across multiple dimensions—Gain, Cover, and Frequency—to identify key risk factors. Simultaneously, SHAP (Shapley Additive Explanations) visualizes the direction and magnitude of individual feature contributions to predictions for specific cases24. This approach addresses the need for medical interpretability and provides a quantitative basis for clinical decision-making. Results Comparison of routine blood laboratory parameters between the DKD group and the control group This study included 100 patients with early-stage DKD and 109 patients with diabetes mellitus (DM) alone serving as the control group. Significant differences were observed between the DKD and control groups in the following parameters (P < 0.05): white blood cell count (WBC), neutrophil percentage (NEUT%) and count (NEUT#), eosinophil percentage (EO%) and count (EO#), basophil percentage (BASO%) and count (BASO#), monocyte count (MONO#), red cell distribution width (RDW), platelet count (PLT), platelet distribution width (PDW), lymphocyte percentage (LYMPH%), red blood cell count (RBC), hemoglobin (HGB), and hematocrit (HCT). Specifically, the DKD group exhibited significantly higher values for WBC, NEUT%, NEUT#, EO%, BASO%, MONO#, EO#, BASO#, RDW, PLT, and PDW, while LYMPH%, RBC, HGB, and HCT were significantly lower compared to the control group (P < 0.05). In contrast, no statistically significant differences were found between the two groups for monocyte percentage (MONO%), lymphocyte count (LYMPH#), mean corpuscular volume (MCV), mean corpuscular hemoglobin (MCH), mean corpuscular hemoglobin concentration (MCHC), plateletcrit (PCT), and mean platelet volume (MPV) (P > 0.05). (detailed in Table 2) Table 2Comparison of routine blood laboratory indicators between the DKD group and the control group.VariableDM group (n = 109)DKD group (n = 100)Statistical valueP valueWBC5.90 [4.80,7.40]7.00 [5.90,8.10]3.70< 0.001NEUT58.40 [51.70,64.30]67.00 [60.60,75.40]6.26< 0.001LYMPH30.80 [26.10,37.60]26.70 [21.80,33.00]3.69< 0.001MONO7.00 [5.80,8.30]7.20 [6.20,8.70]1.050.293EO2.10 [1.40,3.20]2.90 [1.60,4.20]2.570.010BASO0.50 [0.30,0.70]0.60 [0.50,0.80]4.20< 0.001NEUT#3.50 [2.60,4.60]4.70 [3.60,5.80]5.26< 0.001LYMPH#1.80 [1.60,2.30]1.70 [1.40,2.20]1.460.145MONO#0.41 [0.32,0.51]0.50 [0.40,0.60]3.050.002EO#0.12 [0.07,0.20]0.19 [0.09,0.27]3.060.002BASO#0.03 [0.02,0.04]0.04 [0.03,0.06]4.87< 0.001RBC4.65 ± 0.594.35 ± 0.892.860.005HGB141.00 [130.00,153.00]135.00 [116.00,150.00]2.840.005HCT41.40 [38.10,44.50]40.20 [33.90,44.60]2.070.038MCV89.40 [86.20,92.50]89.40 [86.90,91.90]0.160.873MCH30.80 [29.50,31.80]30.50 [29.60,31.30]0.880.381MCHC342.00 [338.00,347.00]343.00 [336.00,348.00]0.090.927RDW13.10 [12.70,13.50]13.40 [12.80,13.80]2.470.013PLT191.00 [168.00,231.00]214.00 [184.00,246.00]2.360.018PCT0.19 [0.16,0.21]0.19 [0.16,0.24]1.320.186MPV9.30 [8.60,10.20]9.20 [8.60,9.70]1.430.154PDW16.80 ± 0.5616.97 ± 0.592.140.033 Comparison of routine blood laboratory indicators between the DKD group and the control group. Comparison of biochemical laboratory parameters between the DKD group and the control group Analysis of biochemical parameters revealed statistically significant differences between the DKD and control groups in uric acid (UA), creatinine (Cr), blood urea nitrogen (BUN), triglycerides (TG), total cholesterol (TC), aspartate aminotransferase (AST), HCY, high-density lipoprotein (HDL), albumin (ALB), and anion gap (AG) (P < 0.05). Specifically, the DKD group demonstrated significantly higher levels of UA, Cr, BUN, TG, TC, AST, and HCY. In contrast, HDL, ALB, and AG levels were substantially lower compared to the control group. In contrast, no statistically significant differences were observed in glucose (GLU), low-density lipoprotein (LDL), total protein (TP), globulin (GLB), total bilirubin (TBIL), direct bilirubin (DBIL), indirect bilirubin (IBIL), or alanine aminotransferase (ALT) (P > 0.05), as detailed in Table 3. Table 3Comparison of clinical characteristics and inflammatory and metabolism-derived indicators between the DKD group and the control group.VariableDM group (n = 109)DKD group (n = 100)Statistical valueP valueGLU6.63 [5.60,8.65]7.02 [5.70,8.20]0.090.928UA311.00 [268.00,372.00]405.00 [340.00,463.00]5.89< 0.001Cr63.00 [56.00,77.00]121.00 [88.00,185.00]9.21< 0.001BUN5.10 [4.40,6.30]7.60 [6.20,11.00]8.01< 0.001TG1.43 [1.04,2.07]2.10 [1.51,2.61]3.82< 0.001TC3.99 [3.18,4.63]4.11 [3.61,5.60]2.030.042HDL1.22 [1.04,1.48]1.06 [0.88,1.19]4.58< 0.001LDL2.22 [1.54,2.55]2.21 [1.66,3.17]1.180.238TP65.90 [61.40,71.30]67.00 [61.50,72.20]1.130.261ALB41.90 [39.00,45.00]39.10 [35.60,42.40]4.17< 0.001GLB26.50 [23.70,31.60]28.50 [25.50,31.60]1.860.063AG1.59 [1.44,1.87]1.41 [1.24,1.54]5.88< 0.001TBIL11.30 [8.20,15.50]9.50 [7.20,12.70]1.930.054DBIL4.30 [3.00,5.90]3.70 [3.00,4.80]1.890.059IBIL7.50 [5.30,10.20]6.90 [4.90,8.90]1.430.154AST18.00 [14.00,22.00]20.00 [16.00,26.00]2.230.025ALT20.00 [15.00,30.00]22.00 [14.00,31.10]0.440.657HCY12.60 [10.70,17.30]19.70 [14.28,23.38]5.40< 0.001 Comparison of clinical characteristics and inflammatory and metabolism-derived indicators between the DKD group and the control group. Comparison of clinical characteristics and inflammatory-metabolic derived indicators between the DKD group and the control group In the analysis of novel diagnostic indicators for DKD versus the control group, statistically significant differences (P < 0.05) were observed between the DKD group and the DM group in the following parameters: sex, age, Monocyte to HDL Ratio (MHR), UHR, Neutrophil to Lymphocyte Ratio (NLR), Platelet to Lymphocyte Ratio (PLR), Lymphocyte to HDL Ratio (LHR), Platelet to Hemoglobin Ratio (PHR), NHR, Red cell distribution width to Albumin Ratio (RAR), Monocyte to Lymphocyte Ratio (MLR), Neutrophil to (Monocyte + Lymphocyte) Ratio (NMLR), SII, Platelet to Neutrophil Ratio (PNR), Lymphocyte to Monocyte Ratio (LMR), and Mean Platelet Volume to Platelet Count Ratio (MPV/PC or MPVPC). Specifically, the levels of PNR, LMR, and MPVPC in the DKD group were significantly lower than those in the control group (P < 0.05). No statistically significant differences were found for age and the Red cell distribution width to Platelet Count Ratio (RPR) (P > 0.05). For details, please refer to Table 4. Table 4Comparison of clinical characteristics, inflammatory, and lipid metabolism-related indicators between the DKD group and the control group.VariableDM group (n = 109)DKD group (n = 100)Statistical valueP valueGender Male102 (92.73)83 (83.00)4.730.030 Female8 (7.27)17 (17.00)Age60.00 [52.00,67.00]58.00 [48.00,65.00]1.630.103MHR0.86 [0.61,1.13]1.22 [0.92,1.68]5.38< 0.001UHR253.73 [193.16,323.62]382.71 [302.88,484.52]6.57< 0.001PNR60.98 [41.11,71.61]46.78 [36.46,58.00]3.62< 0.001NLR1.83 [1.39,2.50]2.67 [1.89,3.36]5.42< 0.001PLR104.12 [84.80,134.21]125.00 [93.64,153.81]2.810.005LMR4.50 [3.44,5.76]3.40 [2.75,4.50]3.96< 0.001LHR1.43 [1.10,1.95]1.70 [1.25,2.05]2.160.031PHR150.43 [117.73,196.00]202.80 [152.46,245.02]4.74< 0.001NHR2.74 [1.92,3.85]4.32 [3.33,6.03]6.73< 0.001RPR0.07 [0.06,0.08]0.06 [0.05,0.07]1.720.085MPVPC0.05 [0.04,0.06]0.04 [0.03,0.05]2.550.011RAR3.16 [2.87,3.47]3.43 [3.14,3.83]4.58< 0.001MLR0.22 [0.17,0.29]0.29 [0.22,0.36]3.96< 0.001NMLR2.07 [1.62,2.74]3.00 [2.18,3.71]5.32< 0.001SII372.38 [268.42,495.13]570.67 [397.76,757.75]5.68< 0.001 Comparison of clinical characteristics, inflammatory, and lipid metabolism-related indicators between the DKD group and the control group. Selection of model variables Least absolute shrinkage and selection operator (LASSO) regression was performed to identify factors associated with DKD risk. Based on prior research and collinearity assessment, 21 indicators were included as independent variables: MHR, UHR, NLR, LHR, PHR, NHR, SII, RAR, PNR, LMR, HGB, RDW, MPV, PDW, BUN, TG, TC, ALB, HCY, PLR, and HCT. LASSO regression with 5‑fold cross‑validation was applied for feature selection. The optimal penalty parameter λ = 0.07 was selected based on the minimum cross‑validation error with the smallest standard error. Finally, six key variables with non‑zero coefficients were retained, including UHR, NHR, SII, PDW, ALB, and HCY (Fig. 2). Lasso Regression Model. A Shows the trajectory of regression coefficients versus Log(λ). As the penalty term λ increases, more important variables are less affected by the penalty and are thus more likely to be retained in the model. B Displays the cross-validation results. The vertical dashed line on the right corresponds to the value 6, indicating the number of feature variables selected by the Lasso regression. Subsequently, the diagnostic performance of these six individual variables was evaluated, and ROC curves were plotted for each indicator (Fig. 3). Among them, HCY demonstrated the best overall diagnostic performance, with an area under the curve (AUC) of 0.79, a specificity of 0.86, and a sensitivity of 0.64. The UHR and the NHR both achieved AUC values of 0.78, indicating relatively favorable diagnostic performance. Detailed results are presented in Table 5. ROC curve of feature variables. This study conducted a diagnostic performance analysis of six indicators: UHR, NHR, SII, PDW, ALB, and HCY. Table 5Diagnostic performance analysis of model variables.VariableAUC valueSensitivitySpecificityYouden’s indexCutoff valueUHR0.780.760.710.48318.09NHR0.780.580.880.464.18SII0.740.690.730.43481.25PDW0.660.740.510.2516.7ALB0.690.820.470.2938.5HCY0.790.640.860.516.2 Diagnostic performance analysis of model variables. Correlation analysis A Spearman correlation analysis was conducted to examine the relationships between the six selected variables (UHR, NHR, SII, PDW, ALB, HCY) and DKD. The study revealed that increased levels of UHR, NHR, SII, and PDW, along with decreased levels of ALB and HCY, were significantly associated with a higher risk of DKD. Detailed results are presented in Fig. 4. Correlation analysis heatmap of variables. The heatmap displays correlation coefficients primarily through color intensity, with darker shades indicating smaller values and lighter shades indicating larger values. Multi-model comparison This study compared the predictive performance of six ML models—XGBoost, Logistic Regression, Light GBM, AdaBoost, Support Vector Machine (SVM), and Random Forest—for DKD. XGBoost demonstrated superior performance in both the training and validation sets, with area under the curve (AUC) values of 1.00 and 0.83, respectively. In the validation set, it achieved a specificity of 0.88 and a sensitivity of 0.62. Based on the binary classification model comparisons, calibration curves and DCA curves were plotted, as shown in Fig. 5. The overall ROC analysis indicated that the lowest AUC among all models was 0.8, suggesting that all six models possessed reasonably good predictive discrimination (details in Table 6). Multi-model comparison for binary classification. Performance comparison among multiple binary classification models. A Shows the ROC results on the training set; B displays the ROC results on the validation set; C presents a dot plot of AUC values for each classification model, where markers indicate the forest area for each model’s respective region; D illustrates the model calibration curves, where the output probabilities or confidence levels should reliably reflect prediction accuracy; E shows the DCA decision curves for each model. Table 6Summary of multi-model classification results on the validation set.Classification modelAUC (95% CI)Cut-off value (95% CI)Sensitivity (95% CI)Specificity (95% CI)F1-score (95% CI)Kappa (95% CI)XG boost0.83 (0.71–0.95)0.84 (0.82–0.85)0.62 (0.52–0.68)0.88 (0.82–0.98)0.71 (0.61–0.80)0.51 (0.35–0.66)Logistic0.80 (0.67–0.93)0.45 (0.40–0.50)0.7 (0.63–0.81)0.79 (0.61–0.83)0.73 (0.65–0.77)0.49 (0.30–0.57)Random forest0.83 (0.71–0.95)0.54 (0.49–0.59)0.72 (0.66–0.82)0.78 (0.66–0.90)0.73 (0.68–0.82)0.5 (0.37–0.68)AdaBoost0.80 (0.67–0.94)0.5 (0.50–0.50)0.75 (0.63–0.77)0.75 (0.66–0.87)0.75 (0.64–0.79)0.5 (0.32–0.61)SVM0.80 (0.67–0.93)0.43 (0.38–0.49)0.76 (0.72–0.86)0.73 (0.62–0.78)0.74 (0.70–0.79)0.49 (0.40–0.58)Light GBM0.81 (0.67–0.94)0.51 (0.44–0.57)0.62 (0.58–0.80)0.77 (0.65–0.85)0.66 (0.62–0.78)0.39 (0.31–0.58) Summary of multi-model classification results on the validation set. Among the six classification models constructed in this study, XGBoost exhibited the optimal comprehensive performance. It had an AUC of 0.83 (95%CI: 0.70–0.95), which was the highest, tied with RF, and superior to the other models, indicating prominent discriminative efficacy and stability. Both the specificity (0.88) and positive predictive value (0.83) of XGBoost were the highest, which could effectively reduce the false positive rate, improve the credibility of positive results, and meet the needs of clinical decision-making. In addition, the accuracy (0.76) and Kappa value (0.51) of XGBoost were superior to those of most models, showing better prediction consistency, and the cutoff value (0.85) with a narrow 95%CI suggested a stable decision boundary. In summary, XGBoost had better comprehensive performance than other models and could be used as the preferred prediction model in this study. In summary, XGBoost, leveraging its regularization strategy and optimized parallel tree structure, significantly outperformed the other models while maintaining clinical interpretability through feature importance ranking. XGBoost model development An XGBoost algorithm was used to develop a predictive model for pathological staging of DKD. The model was constructed using data from 209 samples (100 in the DKD group and 109 in the DM-alone control group) and incorporated six blood and biochemical indicators: UHR, NHR, SII, PDW, ALB, and HCY. Model performance was validated via 5-fold cross-validation (AUC = 0.83) and on an independent test set (AUC = 0.89, accuracy = 81%). The model was configured with a learning rate of 0.3 and an L2 regularization term (lambda = 1). These results indicate good model generalizability without significant overfitting (Table 7). Table 7XGBoost model validation set results.AUC (95%CI)Cutoff (95%CI)Accuracy (95%CI)Sensitivity (95%CI)Specificity (95%CI)Positive predictive value (95%CI)Negative predictive value (95%CI)F1-score (95%CI)0.83 (0.76–0.89)0.84 (0.79–0.83)0.77 (0.72–0.83)0.63 (0.56–0.78)0.90 (0.82–0.92)0.86 (0.76–0.89)0.73 (0.69–0.80)0.72 (0.65–0.82) XGBoost model validation set results. The confusion matrix on the test set showed a precision of 83.33%, reflecting a strong ability to rule out non-DKD patients. The stability of these core performance metrics supports the model’s potential clinical applicability. The learning curve (Fig. 6D) showed a minimal difference in AUC between the training set and the cross-validation set, with both curves stabilizing as the sample size increased. The highly consistent AUC values obtained from 5-fold cross-validation (AUC = 0.83) and the independent test set (AUC = 0.89) confirmed that the model possessed favorable generalizability. Meanwhile, the calibration curve (Fig. 6F) also demonstrated a good agreement between the model’s predicted probabilities and the actual observed probabilities, as detailed in Fig. 6. Predictive performance of the XGBoost model. A shows the ROC results on the training set. B shows the ROC results on the validation set; C displays the ROC results on the test set; D presents the learning curve of the XGBoost classifier; E demonstrates the decision curve analysis; F illustrates the calibration curve analysis. Furthermore, after selecting the XGBoost model, the SHAP package was used to analyze it, revealing the influence of each feature on the sample and showing both positive and negative effects (Fig. 7). SHAP Visualizations for Feature Parameters in the XGBoost Model. A Bar Plot of Mean SHAP Values. This figure presents the mean absolute SHAP values (mean |SHAP value|) for each feature (UHR, NHR, SII, PDW, ALB, HCY) in the XGBoost model, reflecting the average magnitude of each feature’s impact on the model output. B SHAP Summary Plot (Scatter). This scatter plot displays the distribution of SHAP values for individual features and illustrates how feature values influence the model output. C SHAP Force Plot for a Single Sample. This force plot visualizes the contribution of each feature to the model prediction for an individual sample. After incorporating six feature parameters, the model’s predicted value for this DKD sample is 0.91. D In this sample, only a higher ALB value slightly elevates the prediction, whereas lower values of HCY, SII, and UHR substantially decrease the predicted value. E For this sample, higher values of HCY, ALB, and SII push the prediction upward, while a lower UHR value strongly pulls it down, resulting in a final model-predicted DKD risk score of 0.27. Validation of the predictive performance of the XGBoost model An external validation set comprising 42 cases from the Hangzhou Hospital of Chinese Medicine was used to validate the XGBoost model, including 18 patients with pathologically confirmed DKD and 24 controls with DM alone. The results demonstrated that the model maintained stable disease-discriminating ability in this independent, multi-center dataset, achieving an area under the curve of 0.80. The model’s accuracy was 67%, while its specificity remained high at 96% (consistent with the 90% observed in internal testing). Regarding predictive efficacy, the model achieved a positive predictive value (PPV) of 83% and a negative predictive value (NPV) of 64%, with an F1 Score of 0.42 and a Kappa coefficient of 0.26. These metrics indicate high reliability in identifying positive cases, whereas negative results should be interpreted in conjunction with other clinical indicators. Furthermore, DCA and calibration curves were generated from the external validation results to assess diagnostic performance, as detailed in Fig. 8. External Validation of the XGBoost Model. A Shows the ROC curve results of the XGBoost model on the external validation set; B displays the DCA curve; C illustrates the model calibration curve. Based on the findings of this study, we have developed an online predictive tool designed to assist clinicians in assessing the risk of DKD in patients with T2DM. This web-based tool allows users to input specific hematological and biochemical parameters—namely UHR, NHR, SII, PDW, ALB, and HCY—to estimate the probability of disease development (Fig. 9). If the assessment indicates a high risk of DKD, clinicians should exercise increased vigilance, conduct a comprehensive evaluation of the patient’s condition, and consider further diagnostic investigations to confirm the diagnosis. An Online Prediction Tool. The tool (A, B) predicts the risk of Diabetic Kidney Disease in patients with Type 2 Diabetes Mellitus based on nine input indicators through an online interface, utilizing the XGBoost model for probability assessment. https://www.xsmartanalysis.com/model/list/predict/model/html?mid=27792&symbol=2175729611LExk15qUtd. Discussion By collecting case data from patients with pathologically diagnosed DKD, we utilized ML to construct six binary classification risk prediction models. Through comparison, the optimally fitted XGBoost model was selected (AUC 0.83, sensitivity 0.63, specificity 0.88). Furthermore, an online prediction website based on the six factors (UHR, NHR, SII, PDW, HCY, and ALB) derived from the XGBoost algorithm was developed and validated to estimate the risk of DKD. This serves as a practical, straightforward risk calculator for clinicians, helping physicians assess early DKD risk. DKD is one of the most serious microvascular complications of diabetes. The urinary albumin-to-creatinine ratio, as a sensitive indicator of kidney injury, can assess the severity and progression of DKD. However, albuminuria can be influenced by other factors, and its early detection lacks sufficient sensitivity. Notably, compared to patients with early-stage DKD, individuals progressing to the macroalbuminuria stage or those with a significant decline in eGFR face a substantially increased risk of all-cause mortality. Renal biopsy is the gold standard method for diagnosing DKD. Still, its invasive nature limits its widespread use25, which further restricts clinicians’ ability to identify the progression to DKD in diabetic patients early. Therefore, early identification and diagnosis of DKD can reduce diagnostic and treatment costs, thereby alleviating the burden on the healthcare system, optimizing the allocation of medical resources, and consequently enabling more patients to receive timely and effective treatment. Our findings indicate that NHR, SII, and UHR are risk factors for DKD. NHR demonstrated good discriminative ability (AUC = 0.78, specificity = 0.88), supporting its role as a potential risk indicator for DKD. Previous studies have suggested that a hyperglycemic state activates the monocyte system, mediating monocyte-macrophage infiltration in the glomeruli via the MCP-1 signaling axis, and further activating the TGF-β/Smad3 signaling pathway, thereby accelerating glomerular basement membrane thickening and mesangial matrix expansion, and promoting DKD progression26. Research on the role of neutrophils in the pathogenesis and progression of DKD is limited. The currently proposed mechanisms involve the release of large amounts of ROS and TNF-α by neutrophils, neutrophil accumulation, protease release, and NET formation, which promote endothelial damage and consequently accelerate kidney injury27. Related studies have shown that, in diabetic patients, neutrophils can contribute to insulin resistance and amplify inflammatory responses28. SII, as an inflammatory marker that comprehensively reflects neutrophil, lymphocyte, and platelet levels, demonstrated diagnostic value for DKD in this study, with an AUC of 0.74, sensitivity of 0.69, and specificity of 0.73. This indicates its ability to relatively balance the risks of missed diagnosis and misdiagnosis when identifying DKD. Although its discriminatory performance is slightly lower than that of indicators like HCY and NHR, potentially related to SII’s susceptibility to interference from non-specific inflammation, such as infections and autoimmune diseases29, SII has been significantly associated with the risk of CKD and all-cause mortality. It is considered capable of reflecting oxidative stress and the chronic inflammatory state induced by hyperglycemia in DKD. It may be linked to local renal pathologies, such as podocyte injury and glomerulosclerosis30. UHR is a biomarker integrating uric acid metabolism. This study confirmed that its AUC for DKD diagnosis reached 0.78, with a sensitivity of 0.76 and specificity of 0.71. A previous retrospective study of patients with type 2 diabetes indicated that UHR was significantly associated with insulin resistance and the risk of DKD, with each 0.1-unit increase in UHR associated with a 2.3-fold increase in the risk of developing DKD31. As a low-cost, easily accessible indicator, UHR holds high clinical utility and cost-effectiveness for assessing metabolic disorders and renal function impairment, making it suitable for early screening and risk stratification of DKD32. Compared with the established gold-standard biomarkers for diabetic nephropathy—urinary albumin-to-creatinine ratio (UACR) and estimated glomerular filtration rate (eGFR)—these six novel factors exhibit complementary and potential clinical value in early risk stratification. As the cornerstone of DN diagnosis, UACR can specifically detect damage to the glomerular filtration barrier, but it is insensitive to tubular injury, inflammatory activation, or metabolic disorders before the onset of albuminuria. Similarly, eGFR mainly reflects late-stage renal function decline and is easily affected by age, muscle mass, and gender. In contrast, HCY can detect subclinical renal injury before the occurrence of albuminuria33. Although ALB is less specific than UACR, it can serve as a prognostic indicator of disease severity and nutritional status, predicting the rate of progression to end-stage renal disease34. Multiple previous studies have shown that constructing a multi-dimensional predictive model is superior to a single traditional marker in identifying high-risk diabetic patients, thereby facilitating preventive therapeutic intervention for DKD35,36. ML, a crucial branch of artificial intelligence, involves training algorithms on data to make predictions or decisions15 automatically. In the healthcare domain, supervised learning has been widely used for classification, diagnosis, and prognosis prediction tasks37. Bo Mi Seo et al.38 constructed a DKD prediction model based on an LSTM neural network, achieving an AUC of 0.83, and demonstrated HbA1c, SBP, and PP as specific diagnostic indicators. Chan et al.39 developed and validated a risk score for predicting DKD using an ML algorithm trained on a combination of EHR data and biomarkers from 1,146 patients. Although the model’s AUC was 0.77, the blood-based biomarkers it uses are less frequently used in diabetes screening. Another study using the random forest method achieved an AUC of 0.79 with only six features40. Previous studies have developed an early diagnostic model for DKD using the XGBoost algorithm, incorporating simple clinical parameters and potential biomarkers, achieving an AUC of 0.75. However, due to the reliance on clinical diagnosis rather than pathological diagnosis for study enrollment, the model failed to effectively identify individuals with early-stage pathological changes of diabetic kidney disease41. In recent years, multiple machine learning models for early prediction of DKD have been established42. Most previous models were based on clinical diagnosis rather than pathological diagnosis, with limited sample sizes and lack of external validation16. In contrast, the present study used pathological diagnosis as the gold standard, incorporated novel inflammatory and metabolically derived markers, constructed a model using the XGBoost algorithm, and completed external validation, with an AUC of 0.83. The overall predictive performance and generalization ability are superior to most similar models43. Meanwhile, the proposed model uses routine laboratory indicators with low cost and easy popularization, making it more suitable for early clinical screening. Future studies can further optimize the accuracy and applicability of the model by enlarging the sample size of the dataset. The model demonstrated high specificity (0.90) and accuracy (0.77). By utilizing readily available clinical information and routine laboratory test indicators, it can be used to identify early risk of DKD. Notably, the XGBoost model achieved an AUC of 1.00 in the training set, which may reflect the characteristics of the small training dataset rather than genuine overfitting. Nevertheless, the high training AUC should be interpreted with caution. The model yielded an AUC of 0.83 in the 5 fold cross validation internal test and an AUC of 0.80 in the external validation, confirming its favorable generalization ability. Although the model showed high specificity for DKD detection, the relatively modest sensitivity suggests a potential risk of missing early-stage DKD patients in clinical practice. Therefore, this predictive model is recommended as a supplementary screening tool, and combined application with conventional clinical indicators such as UACR and eGFR is encouraged to reduce the rate of missed diagnosis. In addition, the slightly decreased performance in external validation reflects the heterogeneity of real-world clinical data, which may be attributed to differences in patient sources, laboratory testing systems, and baseline characteristics across medical centers. Given the relatively small sample size of this study, our findings should be interpreted with considerable caution. Further studies with expanded datasets and more diverse populations are warranted to strengthen the clinical application value of the model. Innovation points First, the diagnostic model developed in this study is based on pathological diagnosis as the gold standard for enrolling DKD patients, making the modeling results more reliable than those of previous studies that relied on clinical diagnosis for enrollment. Second, this study employs the XGBoost ML algorithm to develop a diagnostic prediction model, which has been validated externally. The results demonstrate that the model performs well, with higher sensitivity and specificity in real-world datasets, indicating improved predictive accuracy compared to previous models. Additionally, the model’s parameters primarily include novel clinical indicators such as UHR, NHR, and SII, which are readily accessible, cost-effective, and convenient. Combined with other general clinical data, these indicators enable a more intuitive and convenient assessment of DKD risk. This model may serve as a supplementary tool for early risk stratification, but cannot replace pathological diagnosis or gold-standard clinical tests. Limitations As a retrospective study enrolling only pathologically diagnosed DKD patients, this study is inevitably limited by the relatively small sample size and potential retrospective bias. In addition, the small scale of the external validation cohort may affect the overall stability and generalizability of the model results. Future multi-center prospective studies are warranted to validate the model performance, and multi-dimensional biomarkers and multi-modal clinical data should be incorporated to further improve the prediction accuracy. Although we adjusted for major confounding factors and performed external validation, residual confounding due to unmeasured or incompletely controlled variables cannot be fully excluded. Furthermore, novel diagnostic indicators such as UHR, NHR, and SII still lack sufficient research data to support them. Future studies with larger sample sizes are needed to validate the model’s efficacy further and to collect relevant data to enhance the accuracy of causal inference. Conclusion This study confirms that SII, UHR, and NHR are independent risk factors for DKD and can serve as efficient biomarkers for early screening. The XGBoost model, built on multidimensional indicators, demonstrates strong predictive performance and generalization. Its high specificity and positive predictive value significantly outperform traditional indicator. This model may provide a supplementary non-invasive approach for risk stratification of early DKD. Prospective studies with larger samples are warranted to validate its generalizability and clinical utility. Acknowledgements This work is supported by the Extreme Smart Analysis platform (https://www.xsmartanalysis.com/). Author contributions Xu Liu and Wanting Zhao were responsible for the study conception and design, methodology implementation, result analysis, and manuscript drafting; Yu Fu was responsible for sample collection; Min Chen and Yan Yu participated in data analysis; Yimin Yao and Yu Ying contributed to the interpretation of the results. All authors participated in manuscript revision, read, and approved the submitted version. Xu Liu and Wanting Zhao contributed equally to this work and share first authorship. Funding The author(s) declare that financial support was received for the research, authorship, and/or publication of this article. This study was supported and approved by the First Affiliated Hospital of Zhejiang Chinese Medical University (Grant No. 2B12518). This work was supported by the Science and Technology Project of Traditional Chinese Medicine in Zhejiang Province (2024ZL055). Data availability The datasets and models used and/or analysed during the current study are available from the corresponding author on reasonable request. Declarations Competing interests The authors declare no competing interests. Ethical approval The study was approved by the Ethics Committee of the First Affiliated Hospital of Zhejiang Chinese Medical University (Approval No.: 2025-KL-848-01). The need to obtain informed consent was waived by the Ethics Committee of the First Affiliated Hospital of Zhejiang Chinese Medical University. This study was conducted in accordance with the Declaration of Helsinki and the local laws and regulations of China. Consent for publication Not applicable. Footnotes Publisher’s Note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations. These authors contributed equally: Xu Liu and Wanting Zhao. Contributor Information Yimin Yao, Email: 20173266@zcmu.edu.cn. Ying Yu, Email: yuying721030@163.com. References Associated Data Data Availability Statement The datasets and models used and/or analysed during the current study are available from the corresponding author on reasonable request.