Type 2 diabetes patient respiratory tract infection risk prediction system and method

By integrating multi-dimensional data and using machine learning methods, a structured dataset was constructed to identify comorbid pairs significantly associated with respiratory infections. An ensemble learning model was trained to quantify the contribution of core features and mediating pathways. This solved the problem that existing technologies cannot accurately predict the risk of respiratory infections in patients with type 2 diabetes, and enabled personalized risk prediction and clinically actionable intervention guidance.

CN121687490APending Publication Date: 2026-03-17JIANGSU PROVINCE HOSPITAL (THE FIRST AFFILIATED HOSPITAL OF NANJING MEDICAL UNIVERSITY)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511860224.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-10
Publication Date
2026-03-17

AI Technical Summary

Technical Problem

Current technologies cannot accurately predict the risk of respiratory infections in patients with type 2 diabetes, ignore the interconnected effects of metabolic disorders, immune deficiencies, and multi-system damage, and fail to explain the specific reasons for the increased risk, making it difficult to translate the predictions into clinically feasible interventions.

Method used

By employing multi-dimensional data integration and machine learning methods, a structured dataset is constructed. Through univariate analysis, multi-model feature importance assessment, and correlation filtering, comorbid pairs significantly associated with respiratory infections are identified. Multiple machine learning models are trained and fused through ensemble learning to generate an ensemble learning model. The contribution of core features to the prediction results is quantified, and the influence path of core features is clarified through mediation effect analysis, resulting in individualized risk prediction results.

Benefits of technology

It has achieved accurate prediction of respiratory infection risk in patients with type 2 diabetes, improved prediction accuracy and stability, provided a closed-loop solution of risk source-intervention target-measure suggestions, and enhanced clinical translational value.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121687490A_ABST
    Figure CN121687490A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of respiratory tract infection risk prediction of patients with type 2 diabetes mellitus, in particular to a respiratory tract infection risk prediction system and method for patients with type 2 diabetes mellitus, and the method comprises the steps: obtaining multi-dimensional data, and constructing a structured data set after integration; carrying out univariate analysis, multi-model feature importance evaluation and correlation filtering, and determining a core feature set; identifying a common disease pair significantly associated with respiratory tract infection as an outcome variable; multiple machine learning models are trained, an integrated learning model is generated through integration of the integrated learning models, and all the models are compared to determine an optimal model; quantifying the contribution degree of each core feature in the core feature set to the prediction result; analyzing and determining an intermediary path of the core feature set influencing the infection risk based on an intermediary effect; and outputting an individualized risk prediction result based on the optimal model, and the method has the advantages that the prediction accuracy is improved, and a basis is provided while the result is output, so that the result is converted into a clinically executable intervention measure.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of predicting the risk of respiratory infections in patients with type 2 diabetes, and particularly to a system and method for predicting the risk of respiratory infections in patients with type 2 diabetes. Background Technology

[0002] Type 2 diabetes is a prevalent chronic metabolic disease worldwide. Patients with this condition are at high risk for respiratory infections due to long-term metabolic disturbances and impaired immune function. Respiratory infections not only exacerbate metabolic disorders and increase the risk of blood sugar fluctuations in diabetic patients, but can also trigger serious complications such as pneumonia and respiratory failure, significantly increasing hospitalization and mortality rates and placing enormous pressure on clinical treatment and public health management. Therefore, accurately predicting the respiratory infection risk of type 2 diabetes patients and taking targeted interventions in advance is of great significance for improving patient prognosis and reducing the medical burden.

[0003] Existing respiratory infection prediction methods are mostly based on single respiratory diseases. On the one hand, they do not fully consider the special physiological and pathological state of patients with type 2 diabetes. On the other hand, they can only predict single respiratory diseases and cannot focus on the comorbidity risk of type 2 diabetes patients with various respiratory infections.

[0004] However, this limitation is not a simple technical oversight, but rather stems from a cognitive bias regarding the infection risk mechanisms in patients with type 2 diabetes. Those skilled in the art generally view respiratory infections in these patients as "a special manifestation of common infections," consistently applying the predictive logic of a single respiratory disease while ignoring the fact that the risk is essentially a linked result of "metabolic disorders, immune deficiencies, and multi-system damage." This cognitive inertia has led to a bottleneck in existing technologies, resulting in current solutions being fundamentally mismatched with the infection risk mechanisms of patients with type 2 diabetes, making accurate prediction impossible.

[0005] Secondly, in clinical practice, infection control for patients with type 2 diabetes requires a clear understanding of the correspondence between "risk sources and intervention targets." However, existing models are mostly "black box" calculations based on statistical regularities, only outputting "high / low risk" conclusions without explaining the specific reasons for the increased risk. This "only providing results without evidence" model makes it difficult to translate predictive results into clinically actionable interventions, ultimately reducing them to theoretical numerical judgments rather than practical diagnostic and treatment tools. Summary of the Invention

[0006] To address the aforementioned technical issues, this application provides a system and method for predicting the risk of respiratory infections in patients with type 2 diabetes.

[0007] This application provides a method for predicting the risk of respiratory infection in patients with type 2 diabetes, which adopts the following technical solution: A method for predicting the risk of respiratory infections in patients with type 2 diabetes, the method comprising: Acquire multi-dimensional data, integrate them, and construct a structured dataset. The multi-dimensional data includes clinical data, laboratory indicators, TyG-derived indicators, respiratory infection outcomes, and comorbidity information. Univariate analysis and multi-model feature importance assessment are performed on the structured dataset to determine candidate feature variables, and correlation filtering is performed on the candidate feature variables to determine the core feature set; Based on comorbidity information and respiratory infection outcomes, we identified comorbidity pairs that were significantly associated with respiratory infection as outcome variables. The core feature set and outcome variable are fused together as a sample dataset and divided into training set and test set according to a preset ratio. After class imbalance processing of the training set and test set, multiple machine learning models are trained and fused together through an ensemble learning model to generate an ensemble learning model. All models are compared to determine the optimal model. The contribution of each core feature to the prediction results is quantified in the core feature set to explain the association between core features and respiratory infection outcomes; Using core feature set as independent variable, outcome variable as dependent variable, and other multidimensional data as mediating variables, the mediation path of core feature set influencing infection risk was identified based on mediation effect analysis. Based on the optimal model, using an individualized core feature set as input, the system outputs individualized risk prediction results.

[0008] In one embodiment: the clinical dataset includes demographic features and anthropometric indices; The laboratory indicators include albumin (ALB), glycated hemoglobin (HbA1c), high-density lipoprotein (HDL), white blood cell count (WBC), and hemoglobin (HB). The TyG derived indicators include TyG index, TyG-BMI, TyG-WC, and TyG-WHtR; The respiratory infection outcome is characterized by whether influenza, pneumonia, or ear infection has occurred within a preset time period in the past; The comorbidity information includes cardiovascular disease (HD), cardiovascular and cerebrovascular disease (CVD), metabolic comorbidity (CMM), and chronic respiratory disease (CRD); among which... The cardiovascular disease HD is defined as 1 when the patient has any of the following conditions: hypertension, congestive heart failure, coronary heart disease, angina pectoris, or heart attack; otherwise, it is defined as 0. The cardiovascular disease CVD is defined as 1 when the patient has HD or stroke, and 0 otherwise. The metabolic comorbidity CMM is defined as 1 when a patient has at least two of the following diseases: CVD, type 2 diabetes mellitus (TDM), and high cholesterol (HC); otherwise, it is defined as 0. The chronic respiratory disease (CRD) is defined as 1 when the patient has any of the following conditions: asthma, emphysema, or chronic bronchitis; otherwise, it is 0.

[0009] In one embodiment: during univariate analysis, based on different data types in the structured dataset, the Wilcoxon rank-sum test is used for continuous variables, the Fisher exact test is used for categorical variables, and the exact logistic regression is used for sparse data, retaining the features whose test results meet the preset significance threshold. In the multi-model feature importance evaluation, the feature importance of the features after univariate analysis is calculated through a variety of different types of first machine learning models, and the features that simultaneously meet the preset importance threshold of each model are retained as candidate feature variables; During correlation filtering, the correlation coefficients of candidate feature variables are calculated, and high collinearity features with correlation coefficients exceeding a preset threshold are removed to determine the core feature set.

[0010] In one embodiment: when identifying comorbidity pairs that are significantly associated with respiratory infection, statistical tests are performed on all disease pairs to analyze the independence between diseases, and the odds ratio is calculated to quantify the intensity of comorbidity. Comorbidity pairs that meet the preset statistical significance conditions, have an odds ratio greater than a preset value, and have more than a preset number of comorbidity cases are retained as outcome variables.

[0011] In one embodiment: the machine learning model includes at least a plurality of logistic regression, LASSO regression, elastic network, linear discriminant analysis, random forest, gradient boosting machine, XGBoost and support vector machine; the ensemble learning model is a stacking ensemble method; After model training, the prediction performance of each machine learning model and ensemble learning model is evaluated by preset performance indicators, and the optimal model is determined based on the prediction performance. The preset performance indicators include the area under the ROC curve.

[0012] In one embodiment: the machine learning model includes at least a plurality of logistic regression, LASSO regression, elastic network, linear discriminant analysis, random forest, gradient boosting machine, XGBoost and support vector machine; the ensemble learning model is a stacking ensemble method; After model training, the core feature set is divided into subgroups, and the prediction performance of each machine learning model and ensemble learning model is evaluated for each subgroup using preset performance indicators. The best model for each subgroup is determined based on the prediction performance, and the optimal model is determined based on the subgroup interval to which the individual core feature set belongs. The preset performance indicators include the area under the ROC curve.

[0013] In one embodiment, the step of quantifying the contribution of each core feature in the core feature set to the prediction result specifically includes: Interpretability analysis was used to quantify the positive or negative contribution of each core feature to the infection risk prediction results; The contribution distribution of all core features and the impact of each core feature on the individual level are displayed in a visual way.

[0014] In one embodiment: the step of identifying the mediation path by which the core feature set influences the risk of infection based on mediation effect analysis specifically includes: A pre-set number of simulations were conducted using a resampling method, and the average causal mediation effect was calculated. Prioritize interventions for mediating variables based on average causal mediation effect; Based on the priority ranking of interventions, the key pathways that influence infection risk by core clinical features are identified, and these key pathways are used as the mediating pathways.

[0015] In one embodiment: the individualized risk prediction results include individual risk level, core influencing factors and their direction of influence, and mediation effect analysis results; Among them, the core influencing factors and their directions of influence are obtained based on the contribution of each core feature to the prediction results; the mediation effect analysis results are obtained based on the mediation paths corresponding to the core influencing factors.

[0016] This invention also provides a respiratory infection risk prediction system for patients with type 2 diabetes, comprising: The data acquisition module is used to collect and integrate multi-dimensional data to build structured datasets; The feature selection module is used to perform a three-level feature selection strategy, which includes univariate analysis, multi-model feature importance and correlation filtering. Comorbidity analysis models are used to identify comorbidity pairs, serving as outcome variables in machine learning. The model training module is used to train multiple machine learning models and implement ensemble learning. The interpretability analysis module is used to quantify the contribution of each core feature in the core feature set to the prediction results and identify the core influencing factors. The mediation analysis module is used to explore the mediating effect of TyG-derived indicators in infection risk pathways. The report generation module is used to generate personalized risk prediction reports.

[0017] In summary, this application has the following beneficial effects: 1. The core features are highly targeted, and the prediction accuracy is significantly improved. Unlike the prediction of a single respiratory disease, this application breaks through the limitations of the existing technology of "piling up general indicators" and focuses on the core pathological logic of "metabolic disorder-infection susceptibility" in patients with type 2 diabetes. Through multi-level feature screening, it locks in the core feature set including TyG-derived indicators, immune function indicators and anthropometric indicators, effectively eliminating redundant variables that are not related to infection risk, and improving the accuracy of prediction. 2. Accurate quantification of comorbidity interaction risks, closely aligned with actual clinical scenarios; In response to the clinical characteristics of multiple comorbidities in patients with type 2 diabetes, this application does not simply include comorbidity information, but uses statistical methods to screen comorbidity pairs that are significantly associated with respiratory infections to accurately identify the "risk superposition effect" between comorbidities, avoiding the problems of existing technologies that "ignore comorbidity interaction" or "generalize the impact of comorbidities", making the prediction results more in line with the actual complexity of the patient's condition; 3. Scientifically adapted model architecture, achieving excellent prediction stability and reliability; This application adopts an architecture of "multi-basic model training + ensemble learning fusion", covering various types such as linear models, ensemble tree models, and support vector machines. The optimal configuration of each model is determined through hyperparameter tuning, avoiding the prediction bias of a single model. Furthermore, the complementary nature of multiple models reduces the impact of data fluctuations on the results. Compared with the existing "single black box model", both prediction stability and accuracy are significantly improved. 4. Mechanism Explanation and Intervention Guidance Closed Loop, with Outstanding Clinical Translational Value: This application quantifies the contribution direction and intensity of core features to individual risk through model interpretability analysis, and clarifies the exclusive path of "core influencing factors → mediating variables → infection risk" by combining mediation effect analysis, completely breaking the existing technology model of "only providing results without evidence". The personalized report generated based on this logic can directly output a closed-loop solution of "risk source - intervention target - measure recommendation", transforming the predicted results from "theoretical values" into clinically executable diagnosis and treatment guidance, truly becoming a practical tool connecting risk prediction and precision intervention. Attached Figure Description

[0018] Figure 1 This is a schematic diagram of a method for predicting the risk of respiratory infection in patients with type 2 diabetes in Example 1; Figure 2 This is a logic block diagram of a respiratory infection risk prediction system for patients with type 2 diabetes in Example 2.

[0019] In the diagram, 10 is the data acquisition module; 20 is the feature selection module; 30 is the comorbidity analysis model; 40 is the model training module; 50 is the interpretability analysis module; 60 is the mediation analysis module; and 70 is the report generation module. Detailed Implementation

[0020] To better understand the purpose, technical solutions, and advantages of this application, it has been described and illustrated below with reference to the accompanying drawings and embodiments. However, those skilled in the art should understand that this application can be implemented without these details. In some cases, to avoid obscuring various aspects of this application due to unnecessary description, well-known methods, processes, systems, components, and / or circuits already described at a higher level will not be elaborated upon. It will be apparent to those skilled in the art that various modifications can be made to the embodiments disclosed in this application, and the general principles defined in this application can be applied to other embodiments and application scenarios without departing from the principles and scope of this application. Therefore, this application is not limited to the illustrated embodiments, but conforms to the broadest scope consistent with the scope of protection claimed in this application.

[0021] It should be noted that the descriptions of these embodiments are for the purpose of aiding understanding the present invention, but do not constitute a limitation thereof. Furthermore, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0022] In the description of this application, "several" means one or more, "more than" means two or more, "greater than," "less than," and "exceeding" are understood to exclude the stated number, while "above," "below," and "within" are understood to include the stated number. The use of "first" and "second" in the description is merely for distinguishing technical features and should not be construed as indicating or implying relative importance, or implicitly indicating the number of indicated technical features, or implicitly indicating the order of the indicated technical features.

[0023] In the description of this application, the terms "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any one or more embodiments or examples.

[0024] Example 1: As Figure 1As shown in the diagram, this invention presents a method for predicting the risk of respiratory infections in patients with type 2 diabetes, and proposes an embodiment of this method.

[0025] In Example 1, the steps of a method for predicting the risk of respiratory infection in patients with type 2 diabetes specifically include: S101. Obtain multi-dimensional data, integrate it to construct a structured dataset, wherein the multi-dimensional data includes clinical data, laboratory indicators, TyG-derived indicators, respiratory infection outcomes and comorbidity information.

[0026] It should be noted that in step S101, the clinical dataset contains demoographic features and anthropometric indicators. Demographic features include age, gender, race, smoking status, drinking status, etc., while anthropometric indicators include weight, height, waist circumference, BMI, WHtR, etc.

[0027] Laboratory indicators include albumin (ALB), glycated hemoglobin (HbA1c), high-density lipoprotein (HDL), white blood cell count (WBC), and hemoglobin (HB).

[0028] TyG derivative indicators include TyG index, TyG-BMI, TyG-WC, and TyG-WHtR, among which: The TyG index is calculated using the formula TyG=ln[TG(mg / dl)×FBG(mg / dl) / 2], where TG is fasting triglycerides and FBG is fasting blood glucose. TyG-BMI = TyG × BMI, BMI = weight (kg) / height 2 (m) 2 ); TyG-WC = TyG × Waist circumference (unit: cm); TyG-WHtR = TyG × waist-to-height ratio, waist-to-height ratio = waist (cm) / height (cm).

[0029] Respiratory infection outcomes are characterized by whether influenza, pneumonia, or ear infection occurred within a pre-specified time period. Data is collected using standardized questionnaires such as the NHANES database and the HSQ520 questionnaire, with a pre-specified time period of at least 6 months, preferably 12 months.

[0030] Comorbidity information includes cardiovascular disease (HD), cardiovascular and cerebrovascular disease (CVD), metabolic comorbidity (CMM), and chronic respiratory disease (CRD); among which, Cardiovascular disease HD is defined as 1 when the patient has any of the following conditions: hypertension, congestive heart failure, coronary heart disease, angina pectoris, or heart attack; otherwise, it is defined as 0. When a patient has HD or stroke, CVD is defined as 1, otherwise it is 0. Metabolic comorbidity (CMM) is defined as 1 when a patient has at least two of the following diseases: CVD, type 2 diabetes mellitus (TDM), and high cholesterol (HC); otherwise, it is defined as 0. The chronic respiratory disease (CRD) is defined as 1 when the patient has any of the following conditions: asthma, emphysema, or chronic bronchitis; otherwise, it is 0.

[0031] S102. Perform univariate analysis and multi-model feature importance assessment on the structured dataset to determine candidate feature variables, and perform correlation filtering on the candidate feature variables to determine the core feature set.

[0032] It should be noted that in step S102, during univariate analysis, based on the different data types in the structured dataset, the Wilcoxon rank-sum test is used for continuous variables, the Fisher exact test is used for categorical variables, and the exact logistic regression is used for sparse data. The test results are retained if they meet the preset significance threshold. Under normal circumstances, the preset significance threshold is set to P < 0.05.

[0033] The formulas involved in the Wilcoxon rank-sum test mentioned above include: Assume the formula is set as follows: In the formula, H0 is the null hypothesis, H1 is the alternative hypothesis, F1(x) is the first group of population distribution functions, F2(x) is the second group of population distribution functions, x is the variable value, and vs is the comparison symbol.

[0034] Rank definition formula: In the formula, R ij X represents the rank of the j-th sample in the i-th group; rankof is the rank calculation symbol, representing "the rank of a variable in the combined sample"; X ij is the observation value of the j-th sample in the i-th group; combinedsample is the combined sample.

[0035] Wilcoxon rank-sum statistic formula: In the formula, W is the Wilcoxon rank-sum statistic, n1 is the sample size of the first group, and R0 is the weight of the sample. 1i Let be the rank of the i-th sample in the first group.

[0036] Mann-Whitney U statistic formula: In the formula, U is the Mann-Whitney U statistic, n² is the sample size of the second group, I(⋅) is the indicator function, and X... 1i Let X be the observation value of the i-th sample in the first group. 2j This is the observation value of the j-th sample in the second group.

[0037] Standardized statistic formula: In the formula, Z is the standardized statistic, n1 is the sample size of the first group, and n2 is the sample size of the second group.

[0038] The formulas involved in the Fisher exact test mentioned above include: Exact probability formula: In the formula, P is the exact probability of a single contingency table, a, b, c, and d are the cell frequencies of a 2×2 contingency table, and n is the total sample size.

[0039] Cumulative probability formula: In the formula, p is the cumulative probability, a min a is the minimum possible value of the first group of positive numbers. max P represents the maximum possible value of the first group of positive cases. i Let P be the exact probability of the i-th contingency table. observed To observe the precise probability of the contingency table.

[0040] Ratio formula: In the formula, θ is the ratio.

[0041] In the multi-model feature importance evaluation, the features after univariate analysis are evaluated using various types of first-order machine learning models to calculate their importance. Features that simultaneously meet the preset importance thresholds of each model are retained as candidate feature variables. The first-order machine learning models include Random Forest, Gradient Boosting Machine, and XGBoost. The preset importance thresholds for each model are: Random Forest importance > 10, GBM relative importance > 1, and XGBoost gain > 0.01.

[0042] During relevance filtering, the correlation coefficients of candidate feature variables are calculated, and high-collinearity features with correlation coefficients exceeding a preset threshold are removed to determine the core feature set. The correlation coefficient is the Pearson correlation coefficient, and the preset threshold is set to |r| > 0.85.

[0043] S103. Based on comorbidity information and respiratory infection outcomes, identify comorbid pairs that are significantly associated with respiratory infection as outcome variables.

[0044] It should be noted that in step S103, when identifying comorbidity pairs that are significantly associated with respiratory tract infection, statistical tests are performed on all disease pairs to analyze the independence between diseases, and the odds ratio is calculated to quantify the intensity of comorbidity. Comorbidity pairs that meet the preset statistical significance conditions, have an odds ratio greater than a preset value, and have more than a preset number of comorbidity cases are retained as outcome variables.

[0045] In this embodiment, the statistical test method used for independence analysis is chi-square test analysis, with the preset statistical significance condition being P < 0.05, the preset value of the odds ratio being OR > 1, and the preset number of cases being 50.

[0046] S104. The core feature set and the outcome variable are fused together as a sample dataset and divided into a training set and a test set according to a preset ratio. After class imbalance processing of the training set and the test set, multiple machine learning models are trained and fused together through an ensemble learning model to generate an ensemble learning model. All models are compared to determine the optimal model.

[0047] It should be noted that in step S104, the training set and test set are divided in a 7:3 ratio, and the ROSE method is used to solve the class imbalance problem. The machine learning model includes at least several of the following: logistic regression, LASSO regression, elastic network, linear discriminant analysis, random forest, gradient boosting machine, XGBoost, and support vector machine. In this embodiment, it is preferred to use all eight of the above machine learning models simultaneously; and the ensemble learning model is the Stacking ensemble method.

[0048] The formulas involved in the aforementioned logistic regression model include: Prediction probability formula: In the formula, P(Y=1|X) is the conditional probability that the outcome variable Y=1 given feature X, Y is the outcome variable, X is the core feature set, β0 is the intercept term, and β p These are the characteristic regression coefficients.

[0049] Loss function formula: In the formula, L(β) is the logarithmic loss function, β is the set of regression coefficients, yi is the true outcome of the i-th sample, and pi is the predicted probability of the i-th sample.

[0050] The formulas involved in the LASSO regression model mentioned above are: In the formula, β is the characteristic coefficient vector, and x i TLet λ be the transpose of the feature vector of the i-th sample, λ be the regularization parameter, and p be the total number of core features.

[0051] The formulas involved in the above elastic network model are: In the formula, α is the regularization balance parameter.

[0052] The formulas involved in the above linear discriminant analysis model are as follows: In the formula, δ k (x) represents the discriminant function value for the k-th class, k is the class index, and x is the sample feature vector. T This is the transpose of the feature vector, where μk is the feature mean vector of the k-th class of samples, and μ k T π is the transpose of the mean vector of the k-th class. k Let be the prior probability of the k-th class.

[0053] The formulas involved in the above random forest model include: Gini coefficient formula: In the formula, Gini(D) is the Gini coefficient of dataset D, D is the dataset to be divided, k is the total number of categories, and p k Let be the proportion of samples of class k in dataset D.

[0054] Information gain formula: In the formula, IG(D) p f) represents the information gain of feature f with respect to the parent node dataset D_p, where D_p is the information gain of feature f with respect to the parent node dataset D_p. p Let N be the parent node dataset, f be the candidate splitting feature, I(⋅) be the impurity index, m be the number of child nodes after splitting by feature f, and N be the child nodes. j Let N be the number of samples in the j-th child node. p Parent node D p The number of samples, D j Let j be the dataset of the j-th child node.

[0055] The formulas for the gradient boosting machine model described above include: Model iteration formula: In the formula, F m (x) represents the ensemble model after the m-th iteration, where m is the iteration number and γ is the ensemble model. m The step size of the m-th base learner, where x is the sample feature vector.

[0056] Formula for calculating step size: In the formula, γ is the candidate step size, n is the total number of samples in the training set, and y i For the true outcome of the i-th sample, F m-1 (x) i ) represents the predicted value of the i-th sample by the model in the first m-1 rounds, γh m (x i ) represents the weighted prediction value of the m-th base learner for the i-th sample.

[0057] The formula for the XGBoost model mentioned above is: In the formula, L(ϕ) is the objective function of XGBoost, and ϕ is the set of model parameters. Let y be the loss term for the i-th sample. i For the true outcome of the i-th sample, Let Ω(f) be the model's predicted value for the i-th sample, k be the decision tree index, and Ω(f) be the predicted value for the i-th sample. k f is the k-th decision tree k The regularization term, f k Let f be the k-th decision tree, γ be the tree complexity penalty parameter, T be the number of leaf nodes in a single decision tree f, λ be the leaf node weight regularization parameter, and w be the leaf node weight vector of the decision tree.

[0058] The companies that use the aforementioned support vector machine model include: Soft-split SVM: Hard-spaced SVM: In the formula, w is the feature weight vector, b is the bias term, and ξ is the bias term. i Let be the slack variable for the i-th sample, C be the penalty parameter, n be the total number of samples in the training set, st be the constraint sign, and y be the slack variable for the i-th sample. i Let x be the class label of the i-th sample. i Let w be the feature vector of the i-th sample. T ∀i is the transpose of the weight vector, and ∀i is the universal quantifier.

[0059] The formulas for the Stacking integration method described above include: Integrated prediction formula: 0. In the formula, For the final predictions of the Stacking ensemble model, M represents the total number of base models, and w represents the total number of predictions. m Let y be the weight of the m-th base model, x be the sample feature vector, w be the base model weight vector, n be the total number of samples in the training set, and y be the weight of the m-th base model. i Let be the true outcome of the i-th sample.

[0060] In one embodiment, after model training, the prediction performance of each machine learning model and ensemble learning model is evaluated by preset performance metrics, and the optimal model is determined based on the prediction performance. The preset performance metrics include the area under the ROC curve.

[0061] In another embodiment, after model training, the core feature set is divided into subgroups based on the numerical range of the core feature set.

[0062] After the division, the prediction performance of each machine learning model and ensemble learning model is evaluated for each subgroup using preset performance indicators. Based on the prediction performance, the best model for each subgroup is determined. When making predictions again, the optimal model is determined based on the subgroup interval to which the individualized core feature set belongs. Among them, the preset performance indicators include the area under the ROC curve.

[0063] S105. Quantify the contribution of each core feature to the prediction results in the core feature set to explain the correlation between core features and respiratory infection outcomes.

[0064] It should be noted that step S105, which quantifies the contribution of each core feature in the core feature set to the prediction result, specifically includes: S1051. Employ interpretability analysis to quantify the positive or negative contribution of each core feature to the infection risk prediction results. S1052. Visualize the contribution distribution of all core features and the influence of each core feature on the individual level.

[0065] In the above steps, the SHAP method is used as the interpretability analysis method in this implementation. A SHAP value > 0 indicates a positive risk of infection, and a SHAP value < 0 indicates a negative risk of infection. The visualization can be presented in the form of bar charts, etc.

[0066] The formula for the SHAP method includes: Conditional expectation form: In the formula, ϕ i(f,x) is the SHAP value of the i-th core feature, i is the feature index, f is the ensemble learning model, x is the core feature vector of an individual patient, S is the subset of core features, p is the total number of core features, f(S∪{i}) is the predicted value containing the i-th feature, and f(S) is the predicted value not containing the i-th feature.

[0067] S106. Using the core feature set as the independent variable, the outcome variable as the dependent variable, and other multidimensional data as mediating variables, the mediation path of the core feature set influencing the risk of infection is identified based on the mediation effect analysis.

[0068] It should be noted that step S106, which involves identifying the mediating pathways through which the core feature set influences the risk of infection based on mediation effect analysis, specifically includes: S1061. Use the resampling method to conduct a preset number of simulations and calculate the average causal mediation effect; S1062. Prioritize interventions for mediating variables based on average causal mediation effect; S1063. Based on the priority ranking of interventions, identify the key pathways that influence infection risk from core clinical features and use these key pathways as mediating pathways.

[0069] In the above steps, the Bootstrap method is used for resampling, with a preferred number of iterations of 1000. The formula for the Bootstrap method includes: Empirical distribution function formula: Resampling formula: Resampling estimator formula: Bootstrap standard error formula: Bootstrap confidence interval formula: In the formula, in the formula, Let X be the empirical distribution function, n be the original sample size, and X be the empirical distribution function. i Let x be the i-th observation of the original sample, and let X be the variable value. n * For Bootstrap resampling samples, F is an independent and identically distributed sign. n Let be the empirical distribution function. For Bootstrap resampling estimators, This represents the Bootstrap standard error, where B is the number of resampling attempts. This is the estimate for the b-th resampling. CI is the mean of the resampled estimator. 1-α Let be the confidence interval. The lower quantile, Let α1 and α2 be the upper quantiles.

[0070] S107. Based on the optimal model, using the individualized core feature set as input, output individualized risk prediction results.

[0071] It should be noted that in step S107, the individualized risk prediction results include the individual risk level, core influencing factors and their direction of influence, as well as the results of the mediation effect analysis.

[0072] Among them, the core influencing factors and the direction of influence are obtained based on the contribution of each core feature to the prediction results. In this embodiment, the top 3-5 core features with positive contribution are selected as the core influencing factors.

[0073] The mediation effect analysis results were obtained based on the mediation paths corresponding to the core influencing factors.

[0074] Example 2: This invention provides a respiratory infection risk prediction system for patients with type 2 diabetes, such as... Figure 2 As shown, it includes: Data acquisition module 10 is used to collect and integrate multi-dimensional data to build a structured dataset; Feature selection module 20 is used to perform a three-level feature selection strategy of univariate analysis, multi-model feature importance and correlation filtering; Comorbidity analysis model 30 is used to identify comorbidity pairs as an outcome variable in machine learning; Model training module 40 is used to train multiple machine learning models and achieve ensemble learning; The interpretability analysis module 50 is used to quantify the contribution of each core feature in the core feature set to the prediction results and identify the core influencing factors. Mediation analysis module 60 is used to explore the mediating effect of TyG-derived indicators in infection risk pathways; Report generation module 70 is used to generate personalized risk prediction reports.

[0075] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make some modifications or alterations to the above-disclosed technical content to create equivalent embodiments without departing from the scope of the present invention. Any simple modifications, equivalent changes and alterations made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the scope of the present invention.

Claims

1. A method for predicting the risk of respiratory tract infection in a patient with type 2 diabetes, characterized by, The method comprises: acquiring multi-dimensional data to construct a structured data set after integration, wherein the multi-dimensional data comprises clinical data, laboratory indicators, TyG derived indicators, respiratory infection outcomes and comorbidity information; performing univariate analysis and multi-model feature importance evaluation on the structured data set to determine candidate feature variables, and performing correlation filtering on the candidate feature variables to determine a core feature set; based on the comorbidity information and the respiratory infection outcomes, identifying comorbidities significantly associated with respiratory infections as outcome variables; fusing the core feature set and the outcome variables as a sample data set, and dividing them into a training set and a test set at a predetermined ratio; after performing class imbalance processing on the training set and the test set, training multiple machine learning models and generating an ensemble learning model through ensemble learning model fusion, and comparing all models to determine the optimal model; quantifying the contribution of each core feature in the core feature set to the prediction result to explain the association between the core feature and the respiratory infection outcome; based on the mediation effect analysis, taking the core feature set as the independent variable, the outcome variable as the dependent variable, and the remaining multi-dimensional data as the intermediate variable, the mediation path of the core feature set affecting the infection risk is determined; based on the optimal model, taking the individualized core feature set as the input, and outputting the individualized risk prediction result.

2. The method of claim 1, wherein the method is for predicting the risk of respiratory tract infection in a type 2 diabetes patient. The clinical data set includes demographic characteristics and anthropometric indicators; The laboratory indicators include albumin ALB, glycosylated hemoglobin HbA1c, high-density lipoprotein HDL, white blood cell count WBC and hemoglobin HB; The TyG derived indicators include TyG index, TyG-BMI, TyG-WC and yG-WHtR; The respiratory infection outcome is represented by whether influenza, pneumonia or ear infection has occurred within a predetermined time period in the past; The comorbidity information includes cardiovascular disease HD, cardio-cerebrovascular disease CVD, metabolic comorbidity CMM and chronic respiratory disease CRD; wherein, When the patient has any of hypertension, congestive heart failure, coronary heart disease, angina pectoris, heart attack, the cardiovascular disease HD is defined as 1, otherwise as 0; When the patient has HD or stroke, the cardio-cerebrovascular disease CVD is defined as 1, otherwise as 0; When the patient has at least two of CVD, type 2 diabetes TDM, high cholesterol HC, the metabolic comorbidity CMM is defined as 1, otherwise as 0; When the patient has any of asthma, emphysema, chronic bronchitis, the chronic respiratory disease CRD is defined as 1, otherwise as 0.

3. The method for predicting the risk of respiratory infection in patients with type 2 diabetes as described in claim 1, characterized in that: In univariate analysis, based on different data types in the structured data set, Wilcoxon rank-sum test is used for continuous variables, Fisher's exact test is used for categorical variables, and exact logistic regression is used for sparse data, and features that meet the preset significance threshold are retained; In multi-model feature importance evaluation, the features after univariate analysis are calculated for feature importance through multiple different types of first machine learning models, and features that meet the preset importance threshold of each model are retained as candidate feature variables. In the correlation filtering, the correlation coefficient of the candidate feature variable is calculated, and the high collinearity features with the absolute value of the correlation coefficient exceeding a preset threshold are removed to determine the core feature set.

4. The method of claim 1, wherein the method is for predicting the risk of respiratory tract infection in a type 2 diabetes patient. In identifying the comorbidity pairs significantly associated with respiratory tract infection, statistical test methods are used to analyze the independence between diseases, and the odds ratio is used to quantify the comorbidity intensity. The comorbidity pairs that meet the preset statistical significance conditions, have a ratio greater than a preset value, and have a number of comorbidity cases exceeding a preset number are retained as the outcome variable.

5. The method of claim 1, wherein the method is for predicting the risk of respiratory tract infection in a type 2 diabetes patient. The machine learning model includes at least one of logistic regression, LASSO regression, elastic network, linear discriminant analysis, random forest, gradient boosting machine, XGBoost, and support vector machine; and the ensemble learning model is a stacking ensemble method. After model training, the prediction effect of each machine learning model and ensemble learning model is evaluated by a preset performance indicator, and the optimal model is determined based on the prediction effect. The preset performance indicator includes the area under the ROC curve.

6. The method of claim 1, wherein the method is for predicting the risk of respiratory tract infection in a type 2 diabetes patient. The machine learning model includes at least one of logistic regression, LASSO regression, elastic network, linear discriminant analysis, random forest, gradient boosting machine, XGBoost, and support vector machine; and the ensemble learning model is a stacking ensemble method. After model training, the prediction effect of each machine learning model and ensemble learning model is evaluated by a preset performance indicator, and the optimal model is determined based on the prediction effect. The preset performance indicator includes the area under the ROC curve.

7. The method of claim 1, wherein the patient is a type 2 diabetic. The step of quantifying the contribution of each core feature in the core feature set to the prediction result specifically includes: An interpretable analysis method is used to quantify the positive or negative contribution of each core feature to the infection risk prediction result; The contribution distribution of all core features and the feature influence of each core feature on the individual level are displayed in a visual manner.

8. The method of claim 1, wherein the patient is a type 2 diabetic. The step of determining the mediation path of the core feature set affecting the infection risk based on mediation effect analysis specifically includes: A resampling method is used for simulation for a preset number of times, and the average causal mediation effect is calculated; Based on the average causal mediation effect, the intervention priority of the mediation variable is sorted; Based on the intervention priority sorting, the key path of the core clinical feature affecting the infection risk is determined, and the key path is taken as the mediation path.

9. The method of claim 1, wherein the method is for predicting the risk of respiratory tract infection in a type 2 diabetes patient. The individualized risk prediction result includes individual risk level, core influencing factors and influence direction, and mediation effect analysis result; The core influencing factors and influence direction are obtained based on the contribution of each core feature to the prediction result; and the mediation effect analysis result is obtained based on the mediation path corresponding to the core influencing factor.

10. A system for predicting the risk of respiratory tract infection in a patient with type 2 diabetes, applied to the method for predicting the risk of respiratory tract infection in a patient with type 2 diabetes according to any one of claims 1 to 9, characterized in that, It includes: A data acquisition module (10) for collecting and integrating multi-dimensional data to construct a structured data set; A feature selection module (20) for performing a three-level feature selection strategy of univariate analysis, multi-model feature importance, and correlation filtering; A comorbidity analysis model (30) for identifying comorbidity pairs as the outcome variable of machine learning; a model training module (40) configured to train a plurality of machine learning models and implement ensemble learning; an explainability analysis module (50) configured to quantify the contribution of each core feature in a core feature set to a prediction result and identify core influencing factors; an intermediary analysis module (60) configured to explore the intermediary effect of a TyG-derived index in an infection risk pathway; a report generation module (70) configured to generate an individualized risk prediction report.