Medical quality dynamic evaluation method and system based on machine learning

By constructing a causal graph and digital twin model for medical quality, and combining federated learning with crowdsourced annotation by doctors, the problems of single data and poor real-time performance in existing medical quality assessment methods are solved, achieving high-precision, real-time, and interpretable assessment.

CN121075689AActive Publication Date: 2025-12-05CHONGQING MUNICIPAL HEALTH STATISTICS INFORMATION CENT

Patent Information

Application Number
CN202511588416.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-03
Publication Date
2025-12-05
Estimated Expiration
2045-11-03

AI Technical Summary

Technical Problem

Existing medical quality assessment methods rely on data from a single institution, resulting in low accuracy and poor real-time performance. They also lack dynamic time-series modeling and causal inference capabilities, failing to meet the needs for dynamic, accurate, and interpretable assessments.

Method used

By securely aggregating structured, unstructured, and time-series data, a causal graph of medical quality is constructed. The results of the causal graph are optimized using Bayesian information criterion. Counterfactual intervention scenarios are generated by combining Do calculus. The model is then corrected in real time through a federated learning optimization framework and a doctor crowdsourcing annotation mechanism. A digital twin model is then constructed for real-time evaluation.

Benefits of technology

It enables dynamic optimization of model parameters across institutions, improves the generalization ability and accuracy of the evaluation model, enhances the interpretability and decision-making guidance value of the evaluation results, and meets the real-time monitoring needs of the surgical process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121075689A_ABST
    Figure CN121075689A_ABST
Patent Text Reader

Abstract

The invention provides a medical quality dynamic evaluation method and system based on machine learning. The method comprises the following steps: acquiring a cross-mechanism desensitization data set, constructing a medical quality causal diagram, generating an anti-fact intervention scene by using Do calculation, and outputting an interpretable causal relationship model; constructing a federated learning optimization framework, aggregating causal relationship model parameters of all medical institutions, introducing a doctor crowdsourcing labeling mechanism to correct a result, and generating a global medical quality dynamic evaluation model; and constructing a surgical digital twin model, mapping dynamic data, and generating a dynamic quality score. Through a federated learning framework, the limitation of single mechanism data is broken through, parameters are optimized, and the performance is improved; causal graph construction and anti-fact intervention scene generation are combined, causal logic is mined, and the result value is enhanced; mapping dynamic data based on a digital twinborn model to realize accurate dynamic scoring; a doctor crowdsourcing labeling mechanism is introduced, a closed-loop optimization system is formed, and finally a high-precision medical quality dynamic evaluation result is output.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical quality assessment technology, and in particular to a method and system for dynamic medical quality assessment based on machine learning. Background Technology

[0002] Current medical quality assessments often rely on post-hoc statistical indicators (such as surgical complication rates and patient satisfaction) or static models from single institutions, depending on human experience for qualitative judgment. While some methods incorporate machine learning, they are limited to data from a single institution, failing to integrate structured / unstructured / time-series multi-source heterogeneous data, and lacking dynamic time-series modeling and causal inference capabilities. Consequently, assessment results are difficult to provide real-time feedback on the surgical process.

[0003] Traditional approaches suffer from shortcomings such as insufficient assessment accuracy, poor real-time performance, and weak interpretability. Data from a single institution limits the model's generalization ability, and static indicators cannot capture dynamic changes during surgery. The lack of causal inference and counterfactual analysis makes it difficult to reveal the underlying logic of quality-influencing factors. Furthermore, physicians' professional experience is not effectively integrated into model optimization, resulting in a disconnect between assessment results and clinical decision-making needs, failing to meet the requirements for dynamic, accurate, and interpretable medical quality assessment. Summary of the Invention

[0004] This invention aims to at least address the technical problems of limited data and low accuracy of evaluation results in existing technologies, and innovatively proposes a dynamic medical quality evaluation method and system based on machine learning.

[0005] To achieve the above-mentioned objectives of this invention, this invention provides a method for dynamic assessment of medical quality based on machine learning, characterized in that the method includes: S1. Collect structured data, unstructured data, and time-series data for secure aggregation to generate a cross-organizational de-identified dataset; S2. Based on the cross-institutional desensitized dataset, a medical quality causal graph is dynamically constructed using a hybrid algorithm of constraint basis and scoring basis, and the results of the medical quality causal graph are optimized using the Bayesian information criterion. S3. Based on the aforementioned medical quality causal graph, use Do calculus to generate counterfactual intervention scenarios and output an interpretable causal relationship model; S4. Construct a federated learning optimization framework, dynamically aggregate the causal relationship model parameters of each medical institution through the PPO algorithm, and introduce a doctor crowdsourcing annotation mechanism in the federated learning optimization framework to correct the model prediction results in real time, and generate a global medical quality dynamic evaluation model after group optimization. S5. Construct a digital twin model of the surgical scene / patient status, and map the instrument position, operation sequence and physiological parameters to the global medical quality dynamic assessment model in real time. Use the global medical quality dynamic assessment model to generate a dynamic quality score every time t.

[0006] In another aspect, the present invention also provides a machine learning-based dynamic assessment system for medical quality, the system comprising: processor; Memory used to store processor-executable instructions; The processor is configured to implement the machine learning-based dynamic assessment method for medical quality when executing the executable instructions.

[0007] The beneficial effects of this invention are as follows: By securely aggregating multi-source heterogeneous data and using a federated learning framework, this invention overcomes the limitations of single-institution data, achieves dynamic optimization of model parameters across institutions, and significantly improves the generalization ability and accuracy of the evaluation model. Combined with the construction of a medical quality causal graph and the generation of counterfactual intervention scenarios, it deeply explores the causal logic between surgical operations, physiological parameters, and procedural compliance, enhancing the interpretability and decision-making guidance value of the evaluation results. Relying on a digital twin model to map dynamic data of surgical scenarios in real time, and combined with temporal modeling and trend correction terms, it achieves accurate dynamic scoring at each time step t, meeting the real-time monitoring needs of the surgical process. By introducing a doctor crowdsourcing annotation mechanism, professional experience is directly embedded into the scoring function, forming a closed-loop optimization system of "data-driven - causal inference - expert correction," effectively solving core problems in traditional evaluations such as poor real-time performance, weak interpretability, and clinical disconnect, ultimately outputting high-precision, high-real-time, and highly interpretable dynamic evaluation results for medical quality.

[0008] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description

[0009] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a flowchart of a machine learning-based dynamic assessment method for medical quality according to the present invention. Detailed Implementation

[0010] Embodiments of the present invention are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0011] Example 1 like Figure 1 As shown, a dynamic assessment method for medical quality based on machine learning is characterized in that the method includes: S1. Collect structured data, unstructured data, and time-series data for secure aggregation to generate a cross-organizational de-identified dataset; In step S1, it is necessary to explain in detail that structured data includes surgical records, medication records, vital signs data, and laboratory test results from the patient's electronic medical record; unstructured data includes operating room monitoring video streams, handwritten text of anesthesia records, postoperative nursing voice recordings, and medical imaging reports; and time-series data covers ECG, blood oxygen saturation, and invasive blood pressure waveform sequences output by high-frequency physiological monitors. In this embodiment, secure aggregation specifically employs differential privacy and homomorphic encryption technologies. After data encryption is completed locally at each medical institution, cross-institutional data joint analysis is achieved through a secure multi-party computation protocol, ensuring that the original data does not leave the domain, generating a desensitized dataset containing multi-source feature fusion. This dataset, after verification by federated learning nodes, is stored in a distributed storage system for subsequent model training. During use, structured data is processed by a natural language processing module to extract key medical events; unstructured data is transformed into structured features using computer vision and speech recognition technologies; and time-series data is processed through sliding window segmentation and dynamic time warping to form a feature sequence with a unified time scale, ultimately generating a cross-institutional medical data matrix containing spatial-temporal multidimensional features.

[0012] S2. Based on the cross-institutional desensitized dataset, a medical quality causal graph is dynamically constructed using a hybrid algorithm of constraint basis and scoring basis, and the results of the medical quality causal graph are optimized using the Bayesian information criterion. S3. Based on the aforementioned medical quality causal graph, use Do calculus to generate counterfactual intervention scenarios and output an interpretable causal relationship model; S4. Construct a federated learning optimization framework, dynamically aggregate the causal relationship model parameters of each medical institution through the PPO algorithm, and introduce a doctor crowdsourcing annotation mechanism in the federated learning optimization framework to correct the model prediction results in real time, and generate a global medical quality dynamic evaluation model after group optimization. S5. Construct a digital twin model of the surgical scene / patient status, and map the instrument position, operation sequence and physiological parameters to the global medical quality dynamic assessment model in real time. Use the global medical quality dynamic assessment model to generate a dynamic quality score every time t.

[0013] In this embodiment, a machine learning-based dynamic assessment method for medical quality operates as follows: First, a secure aggregation technique for multi-source heterogeneous data is used to integrate and anonymize structured, unstructured, and time-series data from different medical institutions, breaking down data silos. Next, a hybrid algorithm combining constraint basis and scoring basis is used to dynamically construct a causal graph for medical quality. This graph clearly demonstrates the inherent logical relationships between surgical procedures, physiological parameters, and procedural compliance, and is optimized using Bayesian information criterion to ensure the accuracy and reliability of causal relationships. Subsequently, based on the constructed causal graph, the Do calculus method is used to generate counterfactual intervention scenarios. These scenarios simulate surgical procedures under different conditions, thereby outputting a highly interpretable causal relationship model. For model optimization, a federated learning optimization framework is constructed, and the PPO algorithm is used to dynamically aggregate causal relationship model parameters from various medical institutions, enabling cross-institutional model parameter sharing and optimization. Simultaneously, a doctor crowdsourcing annotation mechanism is introduced, allowing doctors to correct model predictions in real time based on their professional knowledge and experience, further improving the model's accuracy and practicality. Ultimately, by constructing a digital twin model of the surgical scene and the patient's condition, key information such as instrument positions, operation sequence, and physiological parameters during the surgical process can be mapped in real time. Furthermore, a dynamic quality assessment model for global medical quality is used to generate a dynamic quality score every time t, thereby achieving real-time monitoring and accurate evaluation of the surgical process.

[0014] As an optional embodiment of the present invention, optionally, in step S2, a medical quality causal graph is dynamically constructed based on the cross-institutional de-identified dataset using a hybrid algorithm of constraint basis and scoring basis, and the result of optimizing the medical quality causal graph using the Bayesian information criterion includes: S201. Preprocess the cross-institutional desensitized dataset and extract candidate variables related to medical quality; based on clinical knowledge graph and statistical dependency analysis, screen a subset of variables with potential causal relationships from the candidate variables and construct an initial undirected variable network. In step S201, it is necessary to explain in detail that the preprocessing operation includes data cleaning, missing value imputation, and standardization of the cross-institutional desensitized dataset: First, rule-based filtering methods are used to remove abnormal records and duplicate data; second, mean imputation or K-nearest neighbor algorithm is applied to handle missing values ​​to ensure data integrity; finally, Z-score standardization is used to normalize continuous variables to eliminate the influence of dimensions. Candidate variable extraction is based on a predefined medical quality indicator system, including key dimensions such as surgical success rate, complication rate, operation time, and postoperative recovery indicators. These variables are automatically extracted from the dataset through feature engineering and stored in a temporary feature library. Based on a clinical knowledge graph, the International Classification of Diseases (ICD) and the Clinical Procedure Coding System (CPT) are integrated to construct a prior knowledge network among variables; simultaneously, statistical dependency analysis is performed using Pearson correlation coefficient and mutual information calculation to screen out a subset of variables with significant correlation (e.g., p < 0.05), such as the association between the frequency of surgical instrument use and fluctuations in patient physiological parameters. When constructing the initial undirected variable network, nodes represent the selected subset of variables, edges represent the potential dependencies between variables, the network structure is stored through an adjacency matrix or graph database, and preliminary topology analysis is performed using visualization tools.

[0015] S202. Based on the conditional independence test rule, perform edge pruning on the initial undirected variable network, and use the collision node rule to orient the remaining edges to generate a partially directed acyclic graph. In step S202, it is necessary to explain in detail that the conditional independence test rule adopts a statistical method based on the chi-square test or G-test to evaluate the independence of each pair of nodes in the initial undirected variable network. Specifically, it includes the following operations: First, construct a condition set Z, which consists of covariates related to the target variable pair, such as surgical operation sequences or physiological parameter fluctuations; Second, apply the chi-square test to calculate the conditional independence of the variable pair (X,Y) given Z. If the p-value is greater than a preset significance threshold (e.g., 0.05), X and Y are determined to be independent, and the undirected edge between them is removed; This pruning process is achieved by iteratively traversing all variable pairs, effectively eliminating spurious dependencies. Subsequently, the remaining edges are oriented using the collision node rule. Specifically, the rule is: identify the V-structure (i.e., when variables A and B both point to C, but A and B are not directly connected), orient the incoming edge of the collision node C as a directed edge; At the same time, based on causal direction constraints (e.g., chronological order), further orient other edges to ensure that the generated partially directed acyclic graph (PDAG) meets the causal identifiability requirement. The entire orientation process is implemented using graph theory algorithms, and the adjacency matrix storage structure of the PDAG is output.

[0016] S203. Construct a scoring function using the Bayesian information criterion to evaluate the goodness of fit and complexity penalty of different edge combinations in the partially directed acyclic graph, optimize the edge direction, and obtain the initial causal graph. The expression for the scoring function is: in, Indicates the optimization objective. This represents the current cause-effect graph. Represents the likelihood function. This represents the total sample size of the cross-institutional de-identified dataset. Indicates the number of parameters in the cause-effect graph. Indicates the weights of prior constraints. This indicates the number of disputed edges in the current graph. Indicates an indicator function, Representing a cause-effect graph The first in Disputed edge; In step S203, the specific calculation process of the scoring function is as follows: First, the likelihood function value is calculated using the maximum likelihood estimation method. The graph structure corresponds to the current part of the directed acyclic graph (PDAG), and a multivariate Gaussian distribution or discrete Bayesian network model is used for probability fitting. Second, the number of parameters is defined as the sum of the node parameters and directed edges in the graph. The total sample size is directly obtained from the metadata of the desensitized dataset. The prior constraint weight is preset to an empirical value of 0.1 to balance the model complexity penalty term and the disputed edge constraint. The number of disputed edges is counted by a graph traversal algorithm to count the number of undirected edges in the PDAG. The indicator function takes a value of 1 when the edge direction is uncertain, and 0 otherwise. The optimization process adopts a greedy search strategy: traverse all combinations of disputed edge directions in the PDAG, calculate the scoring function value of each combination, and retain the 10 candidate graph structures with the highest scores. Based on the Bayesian information criterion, the candidate graphs are screened a second time to remove redundant structures (such as redundant cycles or invalid nodes). Finally, the initial causal graph with the largest scoring function value and satisfying the PDAG constraint is output. When in use, adjacency matrix operations are implemented through a graph theory library, and the scoring calculation module integrates the Scikit-learn statistical modeling toolkit to ensure efficient optimization of large-scale graph structures in a distributed environment.

[0017] S204. Based on the initial causal graph, a set of multiple versions of causal graphs is generated using the resampling method, and high-frequency edges in the causal graph set are retained. For controversial edges, expert rules are introduced to force correction, thereby obtaining an optimized causal graph of medical quality.

[0018] In step S204, it is necessary to explain in detail that the resampling method is implemented using Bootstrap technology. The specific operations include: randomly sampling from the cross-institutional de-identified dataset (sampling ratio of 70%, repeated 1000 times) to generate 1000 resampled datasets; based on each resampled dataset, applying the causal graph construction algorithm from steps S201 to S203 (including a hybrid algorithm of constraint basis and scoring basis and Bayesian information criterion optimization) to output a set of 1000 versions of the causal graph, which is stored in a graph database for subsequent analysis. The strategy for retaining high-frequency edges is defined as follows: traversing all versions of the causal graph and counting the frequency of each edge; setting a frequency threshold (e.g., 90%), retaining only edges with a frequency greater than this threshold to form the core edge skeleton; for edges with a frequency lower than the threshold, marking them as controversial edges and recording their direction distribution (e.g., the proportion of inconsistent directions exceeds 30%). The correction of controversial edges incorporates a predefined expert rule base, which integrates clinical guidelines (such as WHO surgical safety standards) and medical quality indicators (such as postoperative complication risk pathways) to enforce the direction of controversial edges. For example, when there is a directional dispute between the edge between surgical operation time and fluctuations in patient physiological parameters, the rule "time priority" is applied to force the orientation to indicate that operation time affects physiological parameters. The optimized medical quality causal graph is generated by merging the core edge skeleton with the corrected controversial edges, ultimately outputting a directed acyclic graph structure, which is stored in a distributed graph computing engine for real-time querying. In practice, Apache Spark GraphX ​​is used for resampling and frequency statistics, the expert rule base is configured in JSON format, and the correction operations are automatically executed by a rule engine (such as Drools).

[0019] As an optional embodiment of the present invention, optionally, outputting an interpretable causal relationship model in step S3 includes: S301. Perform medical semantic annotation on the optimized medical quality causal graph, and add clinical interpretation labels and effect size ranges to each causal edge to obtain the semantically annotated causal graph. In step S301, the specific operations of medical semantic annotation include: First, integrating a pre-built clinical knowledge base (such as SNOMEDCT or UMLS ontology), and automatically matching standard medical concepts to each causal edge using a graph traversal algorithm to generate initial explanatory labels; for example, for the edge between the frequency of surgical instrument use and the fluctuation of patient blood oxygen saturation, the label is defined as "operation affects physiological stability," and the effect size range is calculated based on effect size statistics in historical data (such as linear regression coefficients or hazard ratios), specifically represented as [lower limit, upper limit], where the lower limit is the lower limit of the 95% confidence interval, and the upper limit is the upper limit of the 95% confidence interval. Second, a semi-automated verification mechanism is introduced: a natural language processing module (such as the BERT model) is used to parse the clinical guideline text, generate candidate labels, and verify and correct them through crowdsourced feedback from a panel of physician experts to ensure the clinical accuracy and consistency of the labels. Finally, the semantically annotated causal graph is stored in a graph database in an attribute graph structure, with each edge appended with metadata in JSON format, including the label text, effect size value, and confidence score.

[0020] S302. Based on the clinical knowledge graph and the time-series data analysis, select a set of interventionable variables from the semantically annotated causal graph; In step S302, the specific operations for screening the set of interventionable variables include: First, applying a graph traversal algorithm (such as depth-first search or breadth-first search) to traverse the semantically labeled causal graph and extracting the variable attributes of all nodes and the effect size range of the corresponding edges; Second, combining a clinical knowledge graph (such as integrating ICD intervention pathways or NCCN guidelines), matching each variable with a predefined intervention priority label (such as "high interventionibility" or "low interventionibility"). The specific matching rule is: if a variable is labeled as a standard clinical intervention point (such as drug adjustment or change of operating procedure) in the knowledge graph, it is automatically marked as a candidate intervention variable. Simultaneously, based on the time-series data analysis (such as feature sequences after dynamic time warping), an autoregressive model (ARIMA) or a long short-term memory network (LSTM) is used to predict the future fluctuation trend of the variables, calculate intervention sensitivity indicators (such as control gain or state transition probability), set sensitivity thresholds (such as gain > 0.5 or transition probability < 0.3), and retain only variables that meet the thresholds. Finally, the above results are integrated through a voting mechanism: if a variable simultaneously meets the intervention priority requirements of the clinical knowledge graph and the sensitivity requirements of time series analysis, it is included in the set of interventionable variables; this set is stored in a distributed database in key-value pair format (variable name: intervention priority), and supports real-time updates and queries. In practice, the Apache Spark GraphFrames library is used for graph traversal, the clinical knowledge graph is integrated through the Neo4j graph database, and the time series analysis module integrates the TensorFlow framework to ensure efficient computation.

[0021] S303. Using the Do calculus, construct counterfactual interventions for the set of interventionable variables and generate a counterfactual query library covering high-risk medical pathways; In step 303, it is necessary to explain in detail that the construction process of counterfactual intervention strictly follows Judea Pearl's Do calculus three-rule system. The specific operation process is as follows: First, based on the semantically annotated causal graph, the target variable set V and its parent node set PA(V) are identified. The incoming edges of variable X are cut off by the intervention quantizer, and its value is forced to be set to a specific interval (e.g., the frequency of surgical instrument use x∈[5,10] times / minute). Second, the backdoor criterion and the frontdoor criterion are applied to adjust the confounding factors, and the conditional probability distribution after intervention is calculated, where Y is the outcome variable (e.g., the fluctuation range of the patient's physiological parameters), and Z is the adjusted set of covariates (e.g., the patient's underlying disease status). The generation of the counterfactual query library is achieved by traversing high-risk medical paths: based on historical adverse event data (e.g., surgical complication records), key decision nodes in the path are identified (e.g., specific operation steps or instrument use thresholds), and formal counterfactual questions are constructed (e.g., "If the frequency of instrument use is reduced by 20% at time t, how will the probability of a decrease in the patient's blood oxygen saturation change?"). Each counterfactual question is transformed into a query template containing three elements: 1) the intervention variable and its value range; 2) the target outcome variable and observation conditions; and 3) the effect size calculation function (such as risk difference RD or number of people requiring treatment NNT). This query library is stored in the Neo4j database in a graph structure, where each node represents a counterfactual question, and edges connect consecutive intervention steps with causal dependencies. It supports real-time retrieval of intervention plans for high-risk paths using the Cypher query language.

[0022] S304. Based on the backdoor criterion, eliminate the bias of the confusing variables in the counterfactual query database, calculate the counterfactual conditional probability, output the counterfactual result, and introduce expert rules to force correction to correct the counterfactual result; The expression for calculating the counterfactual conditional probability is: in, Indicates in covariates Values When intervention variables Set as a counterfactual value After that, the result variable The conditional probability, This indicates unobserved confounding factors. Indicating in intervention variables Values Covariates Values and unobserved confounding factors Values Under the condition, the outcome variable The probability distribution, Indicates in covariates Values Under these conditions, no confounding factors were observed. Values The probability of; In step S304, the specific operations for eliminating confounding variable bias include: First, based on the semantically annotated causal graph of medical quality, the backdoor criterion is applied to identify the adjustment set Z (such as the patient's underlying disease status or surgical environment parameters), and the confounding factor path is automatically located using a graph traversal algorithm (such as depth-first search); Second, Bayesian network inference technology is used, combined with the historical distribution in the cross-institutional desensitized dataset, to calculate the adjusted conditional probability distribution, where the integral calculation is implemented through Monte Carlo simulation (repeated sampling 10,000 times, numerical integration using the NumPy library), ensuring accurate estimation even when the confounding factor U is not observed. After calculating the counterfactual conditional probability, the specific process for outputting the counterfactual results includes: generating a structured report containing the value range of the intervention variable, the conditional probability of the target outcome variable, and the confidence interval (such as the 95% confidence interval), and storing it in JSON format in a distributed graph database (such as Neo4j), supporting real-time querying and visualization (such as generating trend charts using Matplotlib). The operation of introducing expert rules to force the correction of counterfactual results is defined as follows: Integrating a pre-built clinical rule base (e.g., based on WHO guidelines or NCCN standards, configured with the Drools rule engine), automatically scanning for outliers in the output results (e.g., probability values ​​exceeding the clinically feasible range [0,1] or conflicting with known medical knowledge), and applying forced correction rules (e.g., "automatically adjust to the historical average when the postoperative complication probability exceeds the threshold of 0.8") to cover controversial results; the corrected counterfactual results undergo secondary verification through a crowdsourced feedback mechanism (e.g., review by a panel of physician experts) to ensure that the final output meets the requirements of clinical consistency and interpretability. In practice, the TensorFlowProbability library is used for probability calculation, and the rule engine interacts with the database via a REST API to ensure efficient processing of large-scale counterfactual queries in a distributed environment.

[0023] S305. Utilize Bootstrap resampling to evaluate the statistical significance of the corrected counterfactual results, and based on the significance, label low-confidence intervention scenarios to obtain counterfactual intervention scenarios; In step S305, it is necessary to explain in detail the use of Bootstrap resampling technology to evaluate the statistical significance of the corrected counterfactual results. The specific operations include: First, randomly selecting a subsample (sampling ratio of 80%, repeated 1000 times) from the original cross-institutional desensitized dataset to generate 1000 resampled datasets; for each resampled dataset, re-performing the counterfactual conditional probability calculation (based on the corrected results in step S304) to obtain the effect size distribution (e.g., risk difference RD or number of people requiring treatment NNT). Second, based on this distribution, calculating the confidence interval (95% confidence level) and p-value (using t-test or Wilcoxon signed-rank test) for each counterfactual scenario, setting a significance threshold (e.g., p < 0.05) and a confidence interval width threshold (e.g., width > 0.2); if the p-value of a scenario is greater than the threshold or the confidence interval width exceeds the preset value, it is automatically marked as a low-confidence intervention scenario, and its uncertainty score is recorded (e.g., a value within the [0,1] interval, where a lower value indicates a lower confidence level). Finally, the outputs of all scenarios are integrated to generate a set of counterfactual intervention scenarios. This set is stored in a distributed graph database (such as Neo4j) in a structured format (e.g., JSON array), with each scenario accompanied by metadata (including effect size, confidence interval, p-value, and confidence level label). In practice, statistical tests are implemented using Python's SciPy library, and Bootstrap resampling is parallelized using Apache Spark's MLlib module to ensure efficient operation on large-scale datasets.

[0024] S306. Based on the counterfactual intervention scenario, generate and output an interpretable causal relationship model that includes a detailed description of the counterfactual intervention scenario, statistical significance analysis, and expert correction results.

[0025] In step S306, it is necessary to explain in detail that, based on the counterfactual intervention scenarios, an interpretable causal relationship model is generated and output, which includes a detailed description of the counterfactual intervention scenario, statistical significance analysis, and expert correction results. The specific operations include: First, each counterfactual intervention scenario output in step S305 is structurally integrated to generate a complete entry containing a scenario description (such as intervention variables, target variables, and assumptions), original counterfactual probability calculation results, expert correction rule application records, effect size distribution after Bootstrap resampling (including mean, 95% confidence interval, p-value), and confidence level labels; Second, based on the integrated scenario entries, a visual model tree structure centered on the intervention path is constructed, where the root node is the initial intervention point, branch nodes represent consecutive intervention steps, and leaf nodes store the final counterfactual results and their statistical attributes; simultaneously, a natural language explanation template is attached to each intervention path. The template automatically populates effect size values ​​and confidence information (e.g., "When the frequency of device use is controlled at [lower limit, upper limit] times / minute, the probability of a decrease in patient oxygen saturation is expected to decrease by [effect size]% (95% CI: [lower limit, upper limit]), and the confidence level of this conclusion is [high / medium / low]"). Finally, the model tree structure, interpretation template, and underlying data relationships are uniformly encapsulated into a standardized output module in JSON-LD format. This module is integrated into the clinical decision support system through a predefined API interface, supporting real-time retrieval and dynamic visualization by medical event type (such as surgical complication warning) or intervention variable category (e.g., generating interactive causal path diagrams via D3.js). In use, model tree construction is implemented using the NetworkX library, interpretation template generation integrates the Jinja2 engine, and the API service is deployed through the Flask framework to ensure low-latency response.

[0026] As an optional embodiment of the present invention, optionally, generating the population-optimized global medical quality dynamic assessment model in step S4 includes: S401, The basic architecture for building a federated learning optimization framework; In step S401, the specific operations for constructing the basic architecture of the federated learning optimization framework are detailed as follows: First, a distributed federated learning architecture is designed, consisting of a central aggregation server and multiple participant nodes (such as medical institutions). The central server is deployed in the cloud (such as AWS or Azure environment), and the participant nodes access it through API interfaces, storing and processing anonymized medical datasets locally. Second, a secure communication mechanism is implemented, using TLS / SSL protocol to encrypt data transmission and ensure privacy protection during model parameter exchange (e.g., applying differential privacy technology to add Gaussian noise, with the noise scale parameter ε set to 0.5 to balance privacy and utility). Then, the federated training workflow is configured. The central server initializes the global model (such as the interpretable causal relationship model based on the output of step S3), and the participant nodes use local data to perform model training (the training framework integrates the TensorFlow Federated library) and update the global model through periodic aggregation strategies (such as the FedAvg algorithm). Finally, a participant management module is established, including node registration, authentication, and contribution evaluation (based on Shapley value calculation). This architecture is deployed via Kubernetes containerization, supporting elastic scaling and fault recovery. In use, the central server uses the Flask framework to build a RESTful API, participant nodes integrate PyTorchLightning to achieve efficient local training, and the secure communication layer is implemented using the OpenSSL library.

[0027] S402. Under the basic architecture of the federated learning optimization framework, each medical institution uses local data to train and update its local causal relationship model, preprocesses structured data, unstructured data and time series data, and uses appropriate loss functions and optimization algorithms to train the causal relationship model. In step S402, it is necessary to explain in detail that each medical institution first preprocesses the local data: structured data (such as diagnostic codes and laboratory indicators in electronic health records) is processed through standardization (Z-score normalization) and feature selection (such as methods based on mutual information) to eliminate the influence of dimensions; unstructured data (such as clinical text reports and image descriptions) is transformed into structured feature vectors using natural language processing techniques (such as entity recognition and sentiment analysis using a BERT model integrated with HuggingFace); time-series data (such as vital sign monitoring streams and medication use records) is used to generate input sequences through sliding window segmentation (window size of 60 minutes) and time-series feature extraction (such as calculating mean, variance, and autocorrelation coefficient). After preprocessing, an appropriate loss function (such as cross-entropy loss for classification tasks or mean squared error loss for regression tasks) is used to evaluate the model output error. The Adam optimizer is selected for optimization, combined with gradient clipping (threshold set to 1.0) to prevent gradient explosion. The training of the local causal model is implemented using the TensorFlow framework. Validation set metrics (such as accuracy or AUC) are calculated after each epoch, and training efficiency is optimized through early stopping. The training and update process is executed on the local node, ensuring that the original data does not leave the domain; only the model parameter gradients are uploaded to the central server for federated aggregation.

[0028] S403. Dynamically aggregate the causal relationship model parameters of each medical institution using the PPO algorithm. Based on the aggregated model parameters, use the central server in the infrastructure of the federated learning optimization framework to generate aggregate weights according to the policy network, and obtain the global model update parameters by weighted average. In step S403, it is necessary to explain in detail the specific implementation of the PPO algorithm, which includes: First, a policy network (a three-layer fully connected neural network built on PyTorch) is deployed on the central server. Its inputs are the model parameter updates uploaded by the participant nodes and the local validation set performance metrics (such as accuracy and recall); the output is the aggregated weight vector of each node. The objective function of the policy network is designed to maximize the expected reward of the global model on the validation set (the reward function is defined as the improvement of the F1 score on the validation set), while constraining the KL divergence difference between the new and old policies (setting a threshold δ=0.01). Second, the policy network is trained using the proximal policy optimization algorithm (PPO-Clip version), and the weight allocation strategy is adjusted through multiple iterations (typically 50 iterations): In each round, the central server collects the parameter updates (in gradient tensor form) of all nodes, the policy network calculates the current weight distribution πθ(a|s), and performs a weighted average operation to obtain a temporary global model; then, the performance of the temporary model is evaluated on the retained validation set and the reward value is calculated, thereby updating the policy network parameters θ (the learning rate is set to 0.001, using the Adam optimizer). Finally, the node parameter updates are weighted and averaged according to the output weights of the converged policy network. In practice, the policy network is trained based on the Ray framework to implement distributed reinforcement learning, and the weighted average calculation utilizes the einsum function of the NumPy library to efficiently perform tensor operations.

[0029] S404. Introduce a doctor crowdsourcing annotation mechanism into the basic architecture of the federated learning optimization framework. Doctors correct and annotate the model prediction results based on their professional knowledge and experience. The central server integrates the annotation results and feeds them back to the model for optimization. In step S404, it is necessary to explain in detail the following: First, the specific implementation of the doctor crowdsourced annotation platform is constructed. This platform adopts a microservice architecture, and the front end uses the Vue.js framework to develop an interactive web interface (such as integrating ECharts visualization components). Authorized doctors can log in to view the counterfactual scenario results predicted by the model (presented in JSON format, including the probability distribution and confidence interval of the intervention variable and the target variable). Doctors can correct abnormal probability values ​​(such as manually adjusting them to the clinically feasible range [0,1]), add text annotations (such as "This result conflicts with the NCCN guidelines"), and select confidence level labels (high, medium, and low). Second, the annotated data is transmitted to the central server in real time via asynchronous REST API (based on the gRPC protocol to optimize latency). The server uses a Cassandra database to store annotation records (including timestamps, doctor IDs, and correction content), supporting high-concurrency writes. The central server executes batch processing tasks daily, applying a weighted allocation algorithm based on Shapley values ​​(weights are calculated based on doctor professional level and historical annotation consistency) to integrate the annotation results and generate a consensus correction dataset. Then, the corrected data is fed back to the federated learning framework: the central server distributes the integrated annotation results to each participant node, and the local model on each node updates the training data or adjusts the weights of the loss function (e.g., increasing the weight of the labeled samples in the cross-entropy loss) through incremental learning (e.g., using TensorFlow's retraining method). Simultaneously, the annotation triggers dynamic optimization of the expert rule base (e.g., when more than 70% of doctors annotate a rule as invalid, the Drools engine automatically disables that rule). In practice, the front-end is deployed on an Nginx server, and the back-end uses Node.js to handle API logic. Data transmission uses TLS 1.3 encryption and JWT token authentication to ensure security and real-time performance in a distributed environment.

[0030] S405. Repeat steps S402-S404 for iterative optimization to generate a group-optimized global dynamic assessment model for medical quality.

[0031] In step S405, the specific process of iterative optimization needs to be detailed as follows: First, before each round of training, the central server broadcasts the latest global model parameters (using Protocol Buffers serialization format to reduce transmission overhead) to all participating nodes. After each node performs local training based on its local data in step S402, it uploads the encrypted model parameter update (gradient tensors processed with differential privacy, noise parameter δ=0.01) and local validation metrics (such as AUC and F1 score) through a secure channel. Second, the central server executes the PPO algorithm in step S403 to dynamically adjust the aggregate weights and generate the updated global model. At the same time, the crowdsourcing annotation mechanism in step S404 is triggered, pushing the key counterfactual predictions generated in this round (scenarios with confidence levels below 0.6) to the doctor annotation platform. The doctor's correction results are fed back to the server within 12 hours. After each iteration, the system automatically calculates the global model performance change rate (e.g., the decrease in the validation set loss function is less than 0.5% for three consecutive rounds) and the variance of participant contributions (Shapley value coefficient of variation > 0.3) as the basis for determining the termination condition. When the convergence criterion is met or the maximum number of iterations (default 100) is reached, the final optimized global model is output. This model is stored in HDF5 format on the central server and synchronized to the edge computing nodes of each medical institution through version control (such as GitLFS), supporting real-time quality assessment inference (latency <200ms).

[0032] As an optional embodiment of the present invention, the expression of the PPO algorithm is optionally: in, This represents the pruning objective function of the near-end policy optimization algorithm. Indicates time step Expectations Indicates the new policy network in state Take action below The probability, Indicates the old policy network in state Take action below The probability, Indicating the old strategy The dominant function under the following conditions This represents the clipping function. Represents a positive number and is used to define the boundary range of the clipping.

[0033] As an optional embodiment of the present invention, optionally, generating a dynamic quality score every time t using the global medical quality dynamic assessment model in step S5 includes: S501. Construct a digital twin model of the surgical scene and the patient's condition, and establish a three-dimensional virtual model covering the positioning of surgical instruments, the logic of the surgical procedure, and the patient's physiological dynamics by integrating sensor data in the operating room, the patient's electronic medical record, and real-time physiological monitoring data. In step S501, it is necessary to explain in detail that the construction of the digital twin model is achieved through the fusion of multi-source heterogeneous data: First, based on the UWB positioning sensor (100Hz refresh rate) and inertial measurement unit (IMU) deployed in the operating room, the spatial coordinates and motion trajectory of the surgical instruments are captured in real time (accuracy ±1.5mm), and converted into six-degree-of-freedom pose data in the ROS coordinate system; Second, the patient's real-time physiological monitoring data stream (such as ECG waveform sampling rate 500Hz, blood pressure monitoring interval 30 seconds) is accessed through the OpenIGTLink protocol, and combined with the preoperative baseline indicators in the electronic medical record (such as ASA classification, comorbidity list), a dynamic vector of the patient's physiological state (containing 15-dimensional temporal features) is constructed; Finally, the preoperative imaging data in DICOM format (such as CT / MRI three-dimensional reconstruction model) and the surgical procedure knowledge graph (containing the logical relationship of surgical stages defined by the ISO8370 standard) are integrated to construct an interactive three-dimensional virtual surgical scene in the Unity3D engine. The specific construction process is as follows: First, import DICOM format imaging data using Unity3D's AssetImportPipeline (e.g., 3D reconstruction via Python scripts calling the SimpleITK library) to generate a patient-specific anatomical model (mesh accuracy <0.5mm); second, subscribe to six-DOF pose data in ROS topics in real time using Unity's ROS# plugin (update frequency 100Hz) to drive the motion trajectory of virtual surgical instruments (collision detection based on physics engines such as PhysX); next, integrate the surgical procedure knowledge graph (logical rules stored in JSON format) using Unity's Timeline system to design an interactive surgical stage switching interface (e.g., adding event triggers to control the visualization of the surgical process); then, access the OpenIGTLink data stream through Unity's WebGL module (using TCP / IP protocol) to dynamically map physiological monitoring data to the parameter panel of the virtual model (e.g., heart rate waveform rendered in real time using ShaderGraph); finally, add doctor interaction controls (e.g., VR controllers supporting HTC Vive devices) to achieve scaling, rotation, and annotation functions of the 3D scene (integrating UnityXRInteractionToolkit), ensuring model response latency <50ms.

[0034] S502. Using data interfaces and communication mechanisms, the position coordinates of surgical instruments, operation sequence information and patient physiological parameters in the three-dimensional virtual model are mapped to the global medical quality dynamic evaluation model in real time. Specifically, firstly, the data interface uses the ROS (Robot Operating System) message interface and the OpenIGTLink protocol to achieve real-time communication: Surgical instrument location coordinates and operation sequence information are subscribed to via ROS nodes (surgical stage events, such as incision start or suturing completion, are encapsulated in JSON format); simultaneously, patient physiological parameters (such as ECG waveform sampling rate of 500Hz, blood pressure values ​​at 30-second intervals, data format IGTL_SCALAR or IGTL_WAVEFORM) are transmitted via the OpenIGTLink protocol (based on TCP / IP protocol, port number 18944). Secondly, the communication mechanism is designed as an asynchronous publish-subscribe model: a ROSmaster node and an OpenIGTLink server are deployed on the central server, and each edge node (operating room terminal) acts as a client to push data in real time; the ZeroMQ library is used to optimize the message queue (buffer size set to 512KB) to ensure data transmission latency <20ms, and heartbeat detection (at 1-second intervals) maintains connection stability. Next, the mapping process includes data transformation and alignment: the surgical instrument position coordinates are transformed (using the ROS TF library to convert the UWB coordinate system to the world coordinate system, with an accuracy error of <2mm) to generate a three-dimensional spatial feature vector (containing 6 dimensions such as position and rotation angle); the operation sequence information is parsed into a time-series event sequence (e.g., using a Python script to call a json library to extract timestamps and event types) and encoded into a one-hot vector; the patient's physiological parameters are smoothed by a sliding window (window size 10 seconds) and standardized (Z-score normalization), and integrated into a 15-dimensional physiological state vector. All data is aggregated in real time on the central server, and the concatenate function of the NumPy library is called to concatenate the feature vectors to form the global model input tensor. In terms of optimization, a real-time verification mechanism is integrated: data integrity checks are performed before mapping (e.g., verifying the continuity of timestamps and the range of values, and triggering ROS warning topics for outliers); after mapping, a data pipeline is implemented through TensorFlow's Dataset API (prefetch buffer size 128), supporting online inference of the global model (response latency <50ms). When in use, the interface module is developed based on Python 3.8 and uses the roslibpy library to bridge ROS and web services. Communication security is ensured through TLS 1.3 encryption and JWT token authentication (key length 256 bits), ensuring reliability and real-time performance in a distributed environment.

[0035] S503. Based on the mapping data, the global medical quality dynamic assessment model is used to perform feature extraction, model inference and score calculation, and a dynamic quality score is generated at each time t.

[0036] In step S503, the feature extraction stage relies on the multilayer perceptron structure of the global model: the model input layer receives a 156-dimensional feature vector aggregated by the central server (including 6-dimensional surgical instrument spatial features, 12-dimensional operation temporal features, and 138-dimensional physiological state features). After normalization by the BatchNormalization layer, it undergoes nonlinear transformation through two hidden layers (containing 256 and 128 neurons respectively, with ReLU activation function) to extract deep features related to medical quality (such as surgical operation compliance, patient physiological stability, etc.). Secondly, the model inference stage uses the TensorFlowLite framework to deploy the optimized global model: the central server converts the trained HDF5 format model to TFLite format (model size compressed to 12.8MB) and distributes it to each edge computing node via the gRPC protocol; after loading the model at the node, it inputs real-time mapping data to perform inference (single inference time <35ms), and outputs a raw score vector containing 12 quality indicators (such as surgical time deviation rate, instrument usage standardization, etc.). Next, the scoring calculation module applies a dynamic weight adjustment mechanism: based on the surgical type (e.g., cardiac surgery weighting emphasizes physiological indicators, or orthopedic surgery weighting emphasizes operational indicators), a weight configuration file (JSON format) is loaded from the expert rule base, and the original scoring vector is weighted and summed. Simultaneously, a time decay factor is introduced (e.g., the weight of physiological indicators decreases by 15% hourly within the first 24 hours post-surgery) to generate the final dynamic quality score (range 0-100 points, precision retained to one decimal place). For optimization, an outlier handling mechanism is integrated: when a sudden change in score is detected (e.g., a difference of >20 points between adjacent time points), a secondary verification process is triggered (calling the local backup model for re-inference), and a warning message is generated through the Drools rule engine (e.g., "Abnormal blood pressure fluctuation in stage 3, manual review recommended"). During use, the scoring results are pushed to the operating room monitoring terminal in real time via the WebSocket protocol (latency <50ms). The terminal interface uses the ECharts visualization component to display the scoring trend chart (including threshold line markers) and indicator detail pop-ups, allowing doctors to view historical scoring records (stored in the InfluxDB time-series database) via touch operation.

[0037] As an optional embodiment of the present invention, optionally, generating a dynamic quality score in each time t in step S503 includes: S5031. Perform real-time feature extraction on the mapping data and standardize it to obtain a feature vector; In step S5031, it is necessary to explain in detail that the real-time feature extraction process is performed on multimodal data in the surgical scene: First, for the surgical instrument position coordinate data, the ROS TF transformation library is used to transform it from the UWB local coordinate system to the world coordinate system, eliminating coordinate deviations between different sensors, and generating a 6-dimensional spatial feature vector containing three-dimensional spatial position (X,Y,Z) and rotation angle (Roll,Pitch,Yaw), ensuring that the spatial positioning accuracy error is less than 2mm; Second, for the operation sequence information, the Python json library is used to parse the surgical stage events (such as "instrument enters the field of view", "suture begins", etc.) encapsulated in the ROS message, and extract the event... The event type and timestamp were used to construct a time-series event sequence, which was then converted into a 12-dimensional time-series feature vector using one-hot encoding. Each bit represents a surgical stage state (0 indicates no event, 1 indicates event). Finally, for patient physiological parameters, ECG waveforms (500Hz sampling rate) and blood pressure values ​​(30-second intervals) received via the OpenIGTLink protocol were first smoothed using a sliding window algorithm (10-second window size) to eliminate instantaneous noise, and then normalized using Z-score (mean to zero, standard deviation to one) to generate a 138-dimensional physiological state feature vector covering key indicators such as heart rate variability and blood pressure fluctuation range. The standardization process was implemented using the StandardScaler class of Scikit-learn to ensure that all feature values ​​conform to a standard normal distribution (mean μ=0, standard deviation σ=1), eliminating the influence of different units of measurement on model training. Finally, the 6-dimensional spatial features, 12-dimensional temporal features, and 138-dimensional physiological features were concatenated into a 156-dimensional feature vector using the concatenate function of the NumPy library, which served as the input data for the global dynamic assessment model of medical quality. During feature extraction, a data quality verification mechanism was integrated: the continuity of data timestamps was monitored in real time using a ROS topic subscriber; if an anomaly exceeding 50ms was detected, a ROS warning topic was immediately triggered and logged; simultaneously, the range of physiological parameter values ​​was checked (e.g., normal heart rate range 40-120 beats / min); if values ​​exceeded the threshold, they were marked as abnormal data, and their influence was eliminated through masking in subsequent model inference, ensuring the reliability and consistency of the input data.

[0038] S5032. Input the feature vector into the global medical quality dynamic assessment model, and generate a predicted medical quality value through model inference using a multi-layer neural network. In step S5032, it is important to explain in detail that the global medical quality dynamic assessment model adopts a multilayer perceptron structure. After receiving a 156-dimensional feature vector in its input layer, it first undergoes a BatchNormalization layer for normalization to eliminate dimensional differences between features and accelerate model convergence. Subsequently, the data enters the first hidden layer, which contains 256 neurons and uses the ReLU activation function to introduce a non-linear transformation, enabling the model to capture complex interactions between features. Next, the data is passed to the second hidden layer, which contains 128 neurons and also uses the ReLU activation function to further extract deep features highly correlated with medical quality, such as the standardization of surgical procedures and the stability of the patient's physiological state. During the model inference phase, the central server converts the trained HDF5 format model to TFLite format to reduce model size and improve inference speed, compressing the model size to 12.8MB. The converted model is distributed to each edge computing node via the gRPC protocol. After loading the model, the nodes input real-time mapping data to perform inference. During inference, the model performs forward propagation on the input feature vector, calculating the predicted medical quality value for the output layer using the weight matrices and bias vectors of each layer. This predicted value is an original score vector containing 12 quality indicators, such as surgical time deviation rate, instrument usage standardization, and patient physiological index fluctuation range. A single inference iteration takes less than 35ms, meeting real-time requirements. To ensure the accuracy and stability of inference, the model employs Dropout and L2 regularization techniques during training to prevent overfitting, and integrates an outlier detection mechanism during inference. When an anomaly is detected in the input data (such as feature values ​​exceeding a reasonable range), the model automatically triggers an alert and logs the information.

[0039] S5033. Based on the predicted medical quality value, a preset scoring function is applied to calculate the dynamic quality score at each time t.

[0040] In step S5033, it is necessary to explain in detail that the calculation of dynamic quality score is based on the following core mechanism: First, extract the values ​​of each quality indicator (such as operation time deviation rate as s1, instrument usage standardization as s2, physiological stability index as s3, etc.) from the 12-dimensional original score vector output by the global model; Second, load the corresponding dynamic weight configuration file (JSON format) according to the real-time operation stage (determined by ROS event timestamps). For example, in the "vascular anastomosis" stage of cardiac surgery, the weight of physiological indicators is increased to 0.35, while the weight of operation indicators is reduced to 0.15; At the same time, apply the time decay factor (t is the number of hours after surgery, with an upper limit of 24 hours) to decay and weight the historical scores of non-critical stages.

[0041] The system incorporates correction coefficients from the expert rule base: when a specific event combination is detected (e.g., "sudden drop in blood pressure + continuous use of high-frequency electrosurgical unit for >60 seconds"), correction rules (e.g., multiplying by a compliance coefficient of 0.8) are invoked via the Drools engine. The final score is truncated (forced to the boundary value when exceeding the [0,100] range) and retained to one decimal place before being pushed to the monitoring terminal via WebSocket. For anomaly handling, if adjacent scores differ, the system automatically triggers parallel inference on a local backup model (a lightweight TFLite model, 4.2MB in size). When the difference persists, a level three alert is generated (e.g., "Score anomaly: a surge in instrument trajectory offset in stage 3"), and the anomaly time point is marked with a flashing red indicator on the ECharts chart. All scoring results are synchronously written to the InfluxDB database, storing fields including timestamp, original vector, weight configuration version, and verification hash (SHA-256 algorithm) to ensure the integrity of audit traceability.

[0042] As an optional embodiment of the present invention, the expression for generating the predicted medical quality value is optionally: in, Indicates time The predicted value of dynamic quality score, This represents the Sigmoid activation function. Indicates the top-level weight. Indicates time The feature representation that integrates causal priors and dynamic temporal sequences. Indicates top-level bias. Represents the Long Short-Term Memory network. Indicates time eigenvectors, Indicates time The feature representation that integrates causal priors and dynamic temporal sequences. This represents the time-series parameters for federated learning optimization. This represents element-wise multiplication. This represents the correction vector for doctor crowdsourcing annotations. This indicates counterfactual intervention characteristics. This indicates the total number of medical institutions. Indicates the first Aggregated weights of local model parameters for each medical institution Indicates the first individual medical institutions in time Feature vectors extracted from counterfactual intervention scenarios.

[0043] As an optional embodiment of the present invention, the expression of the scoring function may be: in, Indicates time Dynamic quality score, Sigmoid activation function Representing dimension, Represents the set of evaluation dimensions. Representing dimensions Causal weights Representing dimensions In time The predicted value, This represents the trend correction coefficient. This indicates the rating trend over time. This represents the expert correction factor. Indicates time In this embodiment, doctor-annotated correction items are collected in real time through the interactive interface of the operating room monitoring terminal (such as a touch tablet). Specifically, an annotation panel is set below the scoring trend chart in the ECharts visualization interface. When a doctor finds a deviation between the model score and clinical reality, they can activate the annotation function through touch operation. During operation, the doctor directly drags the slider to adjust the current score (range 0-100), and the system automatically records the correction amount and timestamp t. For example, in coronary artery bypass surgery, if the model misjudges the instrument usage standardization as 72 points due to electrosurgical interference, the doctor can correct it to 85 points, generating doctor-annotated correction items.

[0044] Represents the state variable at time t. The value, Indicates the state variable in The value at any given moment.

[0045] In this embodiment, the state variables specifically refer to three core variables: surgical stage state, patient physiological state, and instrument operation state. These variables are dynamically updated through real-time data streams and directly affect the calculation process of dynamic quality scores.

[0046] The surgical stage status is determined by the ROS event timestamp and event type (such as "instrument enters the field of view" or "suture completed"). By parsing the JSON format configuration file, the weight parameters corresponding to the current stage (such as the "vascular anastomosis" stage in cardiac surgery) are loaded. This status value is stored in integer encoding (0 indicates inactive, 1 indicates active) and is updated every 100ms to ensure synchronization with the surgical progress.

[0047] The patient's physiological state is generated based on physiological parameters (such as heart rate and blood pressure) received from the OpenIGTLink protocol. After sliding window smoothing and Z-score standardization, a state vector is generated, which includes the heart rate variability index (HRV) and the blood pressure stability index. The state value range is limited to a preset threshold (such as heart rate 40-120 beats / min). When the value exceeds the range, an abnormality is triggered.

[0048] The instrument operation status is calculated using position data transformed to the UWB coordinate system to determine trajectory offset and operational compliance. Status values ​​are updated in real-time via TF transformation, with errors controlled within 2mm. In the scoring function, these status variables are used to dynamically adjust weight configurations and correction coefficients: for example, when the surgical stage status is "vascular anastomosis," the physiological status weight is increased to 0.35; if an abnormal patient physiological state is detected (such as a sudden drop in blood pressure), a correction rule (multiplied by a compliance coefficient of 0.8) is invoked through the Drools engine.

[0049] All state variable values ​​are synchronously written to the InfluxDB database every time t, with stored fields including timestamp, state code, and checksum hash (SHA-256 algorithm) to facilitate auditing and model rollback. Simultaneously, the system integrates a state monitoring mechanism, displaying real-time state change trends through the ECharts visualization interface and triggering alerts (such as flashing red markers) in case of anomalies.

[0050] Example 2 A machine learning-based dynamic assessment system for medical quality includes: processor; Memory used to store processor-executable instructions; The processor is configured to implement a machine learning-based dynamic assessment method for medical quality when executing executable instructions.

[0051] It should be noted that the computer device includes a processor, a memory, and may also include one or more of a multimedia component, an input / output (I / O) interface, and a communication component.

[0052] The processor controls the overall operation of the computer device to complete all or part of the steps in the aforementioned machine learning-based dynamic assessment method for medical quality.

[0053] Memory is used to store various types of data to support the operation of the computer device. This data may include, for example, instructions for any application or method used to operate on the computer device, as well as application-related data. Memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0054] The multimedia component may include a screen and an audio component, wherein the screen may be, for example, a touch screen, and the audio component is used to output and / or input audio signals; for example, the audio component may include a microphone for receiving external audio signals, the received audio signals may be further stored in memory or transmitted via a communication component; the audio component may also include at least one speaker for outputting audio signals.

[0055] I / O interfaces provide interfaces between the processor and other interface modules, such as keyboards, mice, buttons, etc.; these buttons can be virtual buttons or physical buttons.

[0056] The communication component is used for wired or wireless communication between the computer device and other devices; wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G, 4G or 5G, or one or more combinations thereof, and the corresponding communication component may include: Wi-Fi module, Bluetooth module, NFC module, mobile communication module.

[0057] As a preferred embodiment, the computer device may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to execute the aforementioned machine learning-based dynamic assessment method for medical quality.

[0058] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

Claims

1.A method for dynamically evaluating medical quality based on machine learning, characterized in that, The method comprises: S1, collecting structured data, unstructured data and time series data for security aggregation, and generating cross-institutional de-identification data sets; S2, based on the cross-institutional de-identification data set, a constraint base and a scoring base hybrid algorithm is used to dynamically construct a medical quality causal graph, and the Bayesian information criterion is used to optimize the medical quality causal graph result; S3, based on the medical quality causal graph, a counterfactual intervention scenario is generated by using the Do calculus, and an interpretable causal relationship model is output; S4, a federated learning optimization framework is constructed, the causal relationship model parameters of each medical institution are dynamically aggregated by using the PPO algorithm, and a doctor crowdsourcing labeling mechanism is introduced into the federated learning optimization framework to correct the model prediction result in real time, and a globally optimized medical quality dynamic evaluation model is generated; S5, a digital twin model of the operation scene / patient state is constructed, the instrument position, operation sequence and physiological parameters are mapped to the global medical quality dynamic evaluation model in real time, and the global medical quality dynamic evaluation model is used to generate a dynamic quality score once every time t. 2.The machine learning based medical quality dynamic evaluation method of claim 1, wherein, In step S2, based on the cross-institutional de-identification data set, a constraint base and a scoring base hybrid algorithm is used to dynamically construct a medical quality causal graph, and the Bayesian information criterion is used to optimize the medical quality causal graph result, comprising: S201, preprocessing the cross-institutional de-identification data set, and extracting candidate variables related to medical quality; based on the clinical knowledge graph and statistical dependence analysis, a variable subset with potential causal correlation is screened from the candidate variables, and an initial undirected variable network is constructed; S202, based on the conditional independence test rule, the initial undirected variable network is pruned, the remaining edges are oriented by using the collision node rule, and a partial directed acyclic graph is generated; S203, a scoring function is constructed by using the Bayesian information criterion, the fitting degree and complexity penalty of different edge combinations in the partial directed acyclic graph are evaluated, the edge direction is optimized, and an initial causal graph is obtained; S204, based on the initial causal graph, a multi-version causal graph set is generated by using the resampling method, and high-frequency edges in the causal graph set are retained, expert rules are introduced for mandatory correction of the controversial edges, and an optimized medical quality causal graph is obtained. 3.The machine learning based medical quality dynamic evaluation method of claim 1, wherein, In step S3, the output of the interpretable causal relationship model comprises: S301, medical semantic labeling is performed on the optimized medical quality causal graph, a clinical explanation label and an effect size range are added to each causal edge, and a semantically labeled causal graph is obtained; S302, based on the clinical knowledge graph and the time series data analysis, a set of intervenable variables is screened from the semantically labeled causal graph; S303, the Do calculus is used to construct counterfactual intervention on the set of intervenable variables, and a counterfactual query library covering high-risk medical paths is generated; S304, based on the backdoor criterion, the confounding variable bias in the counterfactual query library is eliminated, the counterfactual conditional probability is calculated, the counterfactual result is output, and the counterfactual result is corrected by introducing expert rules for mandatory correction; S305, evaluate the statistical significance of the corrected counterfactual result using Bootstrap resampling, mark low-confidence intervention scenarios based on the significance, and obtain counterfactual intervention scenarios; S306, generate and output an interpretable causal relationship model containing detailed descriptions of counterfactual intervention scenarios, statistical significance analysis, and expert correction results based on the counterfactual intervention scenarios. 4.The machine learning based medical quality dynamic evaluation method of claim 1, wherein, The generation of the globally optimized dynamic medical quality evaluation model in step S4 includes: S401, constructing a basic framework of a federated learning optimization framework; S402, under the basic framework of the federated learning optimization framework, each medical institution trains and updates the local causal relationship model using local data, preprocesses structured data, unstructured data, and time series data, and trains the causal relationship model using a suitable loss function and optimization algorithm; S403, dynamically aggregate the causal relationship model parameters of each medical institution using the PPO algorithm, generate aggregation weights based on the aggregated model parameters using the center server in the basic framework of the federated learning optimization framework according to the policy network, and obtain global model update parameters by weighted average according to the weights; S404, introduce a doctor crowdsourcing labeling mechanism in the basic framework of the federated learning optimization framework, doctors correct and label the model prediction results based on their professional knowledge and experience, the center server integrates the labeling results and feeds them back to the model for optimization; S405, repeat steps S402-S404 for iterative optimization to generate a globally optimized dynamic medical quality evaluation model. 5.The machine learning based medical quality dynamic evaluation method of claim 4, wherein, The expression of the PPO algorithm is: wherein, represents a clipped target function of a proximal policy optimization algorithm, represents an expectation over time steps , represents a probability of a new policy network taking an action in a state , represents a probability of an old policy network taking an action in a state , represents an advantage function under an old policy , represents a clipping function, represents a positive number for defining a boundary range of clipping. 6.The machine learning based medical quality dynamic evaluation method of claim 1, wherein, In step S5, the global medical quality dynamic evaluation model is used to generate a dynamic quality score at each time t, which includes: S501, construct a digital twin model of the surgical scene and patient state, and establish a three-dimensional virtual model covering surgical instrument positioning, surgical process logic, and patient physiological dynamics by integrating operating room sensor data, patient electronic medical records, and real-time physiological monitoring data; S502, use data interfaces and communication mechanisms to map the surgical instrument position coordinates, operation sequence information, and patient physiological parameters in the three-dimensional virtual model to the global medical quality dynamic evaluation model in real time; S503, based on the mapping data, use the global medical quality dynamic evaluation model for feature extraction, model inference, and score calculation to generate a dynamic quality score at each time t. 7.The machine learning based medical quality dynamic evaluation method of claim 6, wherein, In step S503, a dynamic quality score is generated at each time t, which includes: S5031, perform real-time feature extraction on the mapping data and standardize it to obtain a feature vector; S5032, input the feature vector into the global medical quality dynamic evaluation model, perform model inference through a multi-layer neural network, and generate a medical quality prediction value; S5033, based on the medical quality prediction value, apply a preset scoring function to calculate the dynamic quality score at each time t. 8.The method of claim 7, wherein, The expression of generating a medical quality prediction value is: in, Indicates time The predicted value of dynamic quality score, This represents the Sigmoid activation function. Indicates the top-level weight. Indicates time The feature representation that integrates causal priors and dynamic temporal sequences. Indicates top-level bias. Represents the Long Short-Term Memory network. Indicates time eigenvectors, Indicates time The feature representation that integrates causal priors and dynamic temporal sequences. The time parameters representing federated learning optimization are... This represents element-wise multiplication. This represents the correction vector for doctor crowdsourcing annotations. This indicates counterfactual intervention characteristics. This indicates the total number of medical institutions. Indicates the first Aggregated weights of local model parameters for each medical institution Indicates the first individual medical institutions in time Feature vectors extracted from counterfactual intervention scenarios. 9.The machine learning based medical quality dynamic evaluation method of claim 7, wherein, The expression of the scoring function is: wherein, representing a dynamic quality score, at time a sigmoid activation function, representing a dimension, representing a set of evaluation dimensions, representing a causal weight for a dimension representing a predicted value for a dimension representing a predicted value for a dimension at time representing a trend correction coefficient, representing a score time trend term, representing an expert correction coefficient, representing a doctor annotation correction term at time representing a doctor annotation correction term at time representing a doctor annotation correction term at time 10.A machine learning-based medical quality dynamic evaluation system, characterized by, The system includes: a processor; a memory for storing processor-executable instructions; The processor is configured to implement the machine learning-based medical quality dynamic evaluation method in any one of claims 1 to 9 when executing the executable instructions.

Citation Information

Patent Citations

  • Medical unit self-examination method and system based on data analysis

    CN119964744A

  • Method and system for optimizing medical decision based on artificial intelligence

    CN120260789A

  • Healthy life management system based on heterogeneous data collaboration

    CN120853899A

Cited By

  • Hepatopathy thyroid function abnormity early warning system based on machine learning

    CN121436220A

  • Data quality evaluation method and system under distributed storage architecture

    CN122045184A