Cooperative reasoning method and system fusing medical knowledge graph and large model
By building a collaborative reasoning system between medical knowledge graph and large language model, dynamic updates and secure transmission are achieved, knowledge lag and safety hazards in the clinical decision support system are solved, and reasoning ability and interpretability are improved.
Patent Information
- Application Number
- CN202511039314.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-28
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2045-07-28
AI Technical Summary
The existing technology has problems in the clinical decision support system that knowledge update hysteresis, insufficient unstructured text resolution capabilities, easy interruption of reasoning chains in multiple complication scenarios, insufficient model credibility, and high safety hazards.
By constructing a collaborative reasoning system between medical knowledge graphs and large language models, using multimodal data to build dynamically updated knowledge graphs, combining differential privacy algorithms and federated learning mechanisms, real-time monitoring and secure transmission of medical information can be achieved, and interpretable inference reports are generated through the evidence-based medical framework.
It improves the reasoning ability, timeliness, interpretability and security of medical reasoning, solves the problems of data silos and knowledge lag, and enhances the credibility of the model and data privacy protection.
Smart Images

Figure CN120544940A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a collaborative reasoning method and system that integrates medical knowledge graphs and large models. Background Art
[0002] With the deep integration of artificial intelligence technology and clinical medicine, clinical decision support systems (CDSS) have gradually evolved from rule-based expert systems to intelligent agents that combine knowledge-driven and data-driven approaches. The current mainstream technology architecture presents a dual-track parallel development trend: 1. Structured reasoning system based on knowledge graph: This type of system, exemplified by IBM Watson Health's medical knowledge engine, builds a multimodal knowledge graph encompassing medical entities such as disease ontology, symptom representations, and test indicators, and integrates it with rule-based reasoning engines (such as Drools) or graph neural networks (GNNs) to implement path inference. However, these systems face three technical bottlenecks: First, knowledge updates rely on manual annotation and ontology reconstruction, resulting in a response lag of at least six weeks when dealing with emerging infectious diseases. Second, due to the limitations of framework-based knowledge representation, they lack the ability to parse the temporal features and semantic associations implicit in unstructured text such as medical logs and imaging reports. Third, in scenarios with multiple complications, their symbolic logic-based reasoning chains are prone to path interruptions due to missing nodes.
[0003] 2. End-to-end system based on generative large models: Medical Large Language Models (MLMs), such as GPT-4 and Med-PaLM, achieve powerful natural language understanding capabilities through pre-training with hundreds of billions of parameters, enabling end-to-end reasoning on patient complaints. However, they suffer from significant drawbacks: the model's black-box nature results in insufficiently reliable output; in low-resource scenarios, they are prone to hallucinatory reasoning that contradicts medical common sense; and, more critically, their parameterized knowledge storage makes it difficult for the system to synchronize with the latest clinical guidelines.
[0004] In addition, relevant medical data involves the privacy of patients. There may be security risks that medical data may be stolen and tampered with in plain text during model training, data transmission, and data storage. Traditionally, only simple account and password access systems are set up, and the security protection measures are single, posing a huge security risk.
[0005] Therefore, how to provide a collaborative reasoning method and system that integrates medical knowledge graphs and large models to improve the reasoning ability, timeliness, explainability and security of medical reasoning has become a technical problem that needs to be solved urgently. Summary of the Invention
[0006] The technical problem to be solved by the present invention is to provide a collaborative reasoning method and system that integrates medical knowledge graphs and large models to improve the reasoning ability, timeliness, explainability and security of medical reasoning.
[0007] In a first aspect, the present invention provides a collaborative reasoning method integrating a medical knowledge graph and a large model, comprising the following steps: Step S1: The cloud server obtains a large amount of historical medical data including structured health guides and unstructured medical records, and constructs a medical dataset after preprocessing the historical medical data; Step S2: The cloud server extracts multimodal medical entities, medical relationships, and medical attributes from the medical dataset using a pre-trained medical information extraction model, and constructs a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; Step S3: The cloud server creates a medical information monitoring agent, monitors the latest medical information through the medical information monitoring agent, verifies each piece of monitored medical information, and updates the medical knowledge graph based on the medical information using a differential privacy algorithm; Step S4: The cloud server creates a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and sets the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; Step S5: The cloud server trains the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and deploys the trained clinical decision collaborative reasoning model; Step S6: The cloud server deploys a federated gateway, and pushes the clinical decision collaborative reasoning model to the distributed medical terminals through the federated gateway; Step S7: The medical terminal obtains the input query request, parses and verifies the query request to obtain a query demand, inputs the query demand into the deployed clinical decision collaborative reasoning model to obtain a reasoning report including a reasoning result, reasoning basis, and reasoning path, and displays the reasoning report; Step S8: The medical terminal records in real time an inference log including at least the doctor's account number, inference time, query request, inference report, and inference feedback, and uses the inference log to iteratively optimize the collaborative inference model through a federated learning mechanism; Step S9: The medical terminal encrypts and distributes the reasoning log.
[0008] In a second aspect, the present invention provides a collaborative reasoning system that integrates medical knowledge graphs and large models, including the following modules: A medical data set construction module is used for the cloud server to obtain a large amount of historical medical data including structured health guides and unstructured medical records, and to construct a medical data set after preprocessing each of the historical medical data; A medical knowledge graph construction module is used for the cloud server to extract multimodal medical entities, medical relationships, and medical attributes from the medical data set through a pre-trained medical information extraction model, and to construct a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; A medical knowledge graph update module is used to create a medical information monitoring agent on the cloud server, monitor the latest medical information through the medical information monitoring agent, verify each piece of monitored medical information, and then update the medical knowledge graph based on the medical information using a differential privacy algorithm; A clinical decision collaborative reasoning model creation module is used by the cloud server to create a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and to set the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; A clinical decision collaborative reasoning model training module is used for the cloud server to train the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and to deploy the trained clinical decision collaborative reasoning model; A clinical decision collaborative reasoning model push module is used to deploy a federated gateway on the cloud server, and push the clinical decision collaborative reasoning model to distributed medical terminals through the federated gateway; A collaborative reasoning module is configured to receive a query request from a medical terminal, parse and verify the query request to obtain a query demand, input the query demand into a deployed clinical decision collaborative reasoning model to obtain a reasoning report including a reasoning result, reasoning basis, and reasoning path, and display the reasoning report; The model iteration and optimization module is used for the medical terminal to record the inference log in real time, including at least the doctor's account, inference time, query request, inference report, and inference feedback. Through the federated learning mechanism, the inference log is used to iteratively optimize the collaborative inference model; The inference log storage module is used by the medical terminal to encrypt and distribute the inference log.
[0009] The advantages of the present invention are: 1. Obtain a large amount of historical medical data including structured health guides and unstructured medical records through the cloud server, pre-process the historical medical data and build a medical data set; extract multimodal medical entities, medical relationships and medical attributes from the medical data set through the pre-trained medical information extraction model, and build a medical knowledge graph based on the extracted medical entities, medical relationships and medical attributes; monitor the latest medical information through the created medical information monitoring agent, verify each monitored medical information, and update the medical knowledge graph based on the medical information through the differential privacy algorithm; the cloud server creates a clinical decision collaborative reasoning model based on the multimodal fusion layer, collaborative reasoning layer and explanation generation layer, and sets the clinical decision collaborative reasoning model. The reasoning loss function and reasoning reward function of the reasoning model are constructed; the multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, and synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and then input the semantic text and the retrieved medical knowledge into the collaborative reasoning layer after modality alignment; the collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical large language model and the medical knowledge graph, and obtain candidate reasoning hypotheses with confidence assessment, and input the candidate reasoning hypotheses into the explanation generation layer; the explanation generation layer is used to generate an inference report containing inference results, reasoning basis and reasoning path based on the candidate reasoning hypothesis according to the evidence-based medicine framework; the cloud server uses medical data sets, inference loss function and reasoning reward function to generate inference reports based on the candidate reasoning hypothesis according to the evidence-based medicine framework; the cloud server uses medical data sets, inference loss function and reasoning reward function to generate inference reports based on the candidate reasoning hypothesis The loss function and reasoning reward function are used to train the clinical decision collaborative reasoning model, deploy the trained clinical decision collaborative reasoning model, and push the clinical decision collaborative reasoning model to distributed medical terminals through the federated gateway. The medical terminal receives the input query request, parses and verifies the query request to obtain the query demand, inputs the query demand into the deployed clinical decision collaborative reasoning model to obtain an inference report including the inference result, inference basis, and inference path, displays the inference report, and records the inference log in real time, including at least the doctor account, inference time, query demand, inference report, and inference feedback. Through the federated learning mechanism, the inference log is used to iteratively optimize the collaborative reasoning model, and the inference log is encrypted and distributedly backed up. That is, the input query request is inferred through the clinical decision collaborative reasoning model that combines the medical knowledge graph and the medical big language model, effectively combining the advantages of the medical knowledge graph and the medical big language model, and the reasoning report output by the clinical decision collaborative reasoning model carries the reasoning results, reasoning basis and reasoning path, effectively enhancing credibility; the medical knowledge graph is dynamically updated through the medical information monitored by the medical information monitoring agent, and the collaborative reasoning model is iteratively optimized through the inference log, so that the medical knowledge graph and the medical big language model are kept up to date. Combined with the security mechanism of the federal gateway, the verification of query requests, the encryption of the inference log and the distributed backup of the inference log, it ultimately greatly improves the reasoning ability, timeliness, interpretability and security of medical reasoning.
[0010] 2. By integrating multimodal medical data (structured health guidelines and unstructured medical records), a dynamically updated medical knowledge graph is constructed, and the generalized reasoning ability of large language models and the logic of knowledge graphs are innovatively integrated to achieve high-confidence collaborative reasoning for clinical decisions. By leveraging differential privacy algorithms and federated learning mechanisms, while ensuring data privacy and security, it supports real-time interaction and model optimization of distributed medical terminals, solving the problems of medical data silos and knowledge lags, and generating explainable reasoning results through the evidence-based medicine framework, significantly improving reasoning efficiency and accuracy.
[0011] 3. By building a dual-source data system of structured (health guide) and unstructured (medical record) data, covering the entire reasoning process elements (7 modules of health guide + 11 types of medical record data), the problem of single medical AI training data has been solved; by integrating image-text multimodal data (auxiliary examination data), it has broken through the limitations of traditional single-type data analysis and laid a data foundation for building a three-dimensional reasoning model.
[0012] 4. By innovatively integrating multimodal medical data from structured health guidelines and unstructured medical records, and effectively improving data quality through an original four-stage preprocessing process (desensitization-cleaning-unification-feature extraction), combined with a five-dimensional intelligent labeling system (treatment effect / query request / report / basis / path) to build a high-precision medical dataset, it not only overcomes the interpretability problem of medical AI models, but also supports rapid transfer learning across diseases. Its innovative multimodal data fusion architecture and dynamic feature extraction mechanism provide a breakthrough solution for the precision and practicality of medical AI systems.
[0013] 5. Text encoding uses the BioBERT network and a pre-trained medical corpus to accurately capture medical terminology and contextual semantics, enhancing the professionalism of text features. Image encoding uses the residual convolutional network (ResNet) to alleviate the vanishing gradient problem through jump connections, enhancing the feature extraction capabilities of medical images (such as CT and MRI). Structural encoding introduces the graph attention network (GAT) to dynamically learn the association weights between medical data nodes (such as diseases, symptoms, and drugs) to effectively model complex relationships. The feature mapping module maps text, image, and structural features to a unified semantic space through a fully connected layer, addressing the heterogeneity problem of multimodal data and laying the foundation for subsequent cross-modal interaction.
[0014] 6. The modality interaction module generates a semantic association matrix through a cross-attention mechanism to quantify the complementarity between different modalities (such as the association between image features and pathological descriptions) to avoid information isolation; the gated fusion module introduces learnable weights to dynamically adjust the contribution of each modality. For example, in the absence of high-quality images, the image modality weight is reduced to improve the model's robustness to missing data.
[0015] 7. Entity decoding uses conditional random fields (CRFs) combined with label transfer probabilities to optimize sequence annotation results and reduce "BIO" label conflicts (such as "drug-dose" continuous entity recognition); relationship decoding uses graph neural networks (GNNs) to construct entity association topologies and combines relationship classifiers to distinguish dependency types (such as "treatment" and "side effects") to enhance the interpretability of relationship reasoning; attribute decoding uses multi-head pointer networks to locate multi-label attributes (such as "dose" and "frequency"), supports non-continuous fragment extraction, and adapts to complex medical expressions.
[0016] 8. By adopting cross-entropy with category weights in entity loss, the loss weight is increased for rare medical entities (such as rare disease names) to alleviate the problem of data distribution skew; by introducing multi-label marginal loss with threshold adjustment in attribute loss, positive and negative samples are dynamically balanced (such as the simultaneous existence of "contraindications" and "indications") to reduce the false negative rate.
[0017] 9. The multimodal encoding layer integrates heterogeneous features of text (BioBERT), images (residual convolutional network) and structural data (graph attention network), and uses the cross-attention mechanism and dynamic gated fusion of the cross-modal alignment layer to achieve semantic association modeling and adaptive weight allocation. The CRF, GNN and multi-head pointer network in the joint decoding layer are combined to collaboratively optimize the parallel extraction of entities, relationships and attributes, and the weighted multi-task loss function is used to alleviate the category imbalance problem. Ultimately, high-precision cross-modal semantic understanding, robust multi-source data compatibility and end-to-end multi-task collaborative optimization are achieved in medical information extraction, significantly improving the accuracy and efficiency of joint extraction of entity relationships in complex medical scenarios.
[0018] 10. By integrating official APIs, academic databases, patent databases, paper databases, news websites and professional forums, we can break through the limitations of a single data source and ensure the comprehensiveness and authority of medical information; through dynamic IP rotation, we can ensure the stability of data capture.
[0019] 11. By adding controllable noise to the original data, strong protection of individual privacy can be achieved (such as avoiding the reverse deduction of patient identity or institutional data) while ensuring the effectiveness of medical knowledge extraction.
[0020] 12. By integrating official APIs, academic databases, patent libraries and other multi-source monitoring channels and adopting a dynamic IP proxy pool, comprehensive and stable collection of medical information is achieved; multi-level verification (format, logic, conflict) and data cleaning are used to ensure data quality, and differential privacy algorithms are used to add noise to sensitive information. Under the premise of ensuring privacy compliance, intelligent models are used to efficiently extract medical entities, relationships and attributes, and dynamically update knowledge graphs, ensuring data comprehensiveness, accuracy, security and timeliness; its modular design supports flexible expansion of monitoring rules and processing procedures, solving the pain points of traditional medical information monitoring such as data silos, high privacy risks, and delayed knowledge updates.
[0021] 13. By extracting the deep semantics of query requests (unstructured data) through Transformer and simultaneously retrieving the medical knowledge graph (structured data), a two-way complementarity between patient complaints and medical knowledge is achieved, which solves the information limitations of a single data source and significantly improves the comprehensiveness of the reasoning basis. By introducing medical ontology as a constraint framework for cross-modal alignment, semantic text and medical knowledge are mapped into a unified semantic space, effectively eliminating terminology ambiguity (such as the problem of homonymous symptoms) and reducing noise interference in multimodal data fusion.
[0022] 14. By using temporal convolutional networks and memory networks to construct an interactive channel between the medical large language model (LLM) and the medical knowledge graph, the model can not only capture the dynamic temporal characteristics of text semantics, but also perform logical verification based on the medical knowledge graph, solving the credibility problem of the traditional LLM "black box reasoning"; by using the low-rank matrix (LoRA) to vectorize the latest clinical guidelines and inject them into the LLM parameter space, the computing resource consumption is reduced by more than 60% compared to full parameter fine-tuning, and it supports online incremental updates of the clinical knowledge base, ensuring that the model timeliness meets the needs of medical practice.
[0023] 15. Generate a causal chain of reasoning hypotheses through a differentiable Markov logic network, decompose the reasoning process into an explicit logical link of symptoms → pathology → reasoning, and meet the mandatory requirements of medical scenarios for decision transparency; generate standardized reasoning results through a medical ontology template engine, and output structured reasoning basis (such as ICD code association), reasoning path (DDx) and confidence assessment, so that AI reasoning results can be directly embedded in the workflow of the hospital electronic medical record system.
[0024] 16. The multimodal fusion layer integrates unstructured semantic text and structured medical knowledge (accurate modality alignment is achieved based on medical ontology), and a dual-channel interaction mechanism is constructed in the collaborative reasoning layer (a temporal convolutional network captures dynamic features + a low-rank matrix dynamically injects the latest clinical guidelines) to achieve efficient generation of reasoning hypotheses and real-time knowledge updates; the explanation generation layer innovatively combines differentiable Markov logic networks (generating traceable causal chains) with ontology template engines (automated evidence-based report output), significantly improving decision transparency and clinical compliance; through a multi-objective joint optimization framework (the loss function balances alignment / reasoning / explanation, and the reward function strengthens five-dimensional indicators such as accuracy / evidence-based completeness), while ensuring the accuracy of reasoning, it effectively improves logical coherence and effectively reduces the misdiagnosis rate, meeting the strict requirements of medical AI systems for explainability, timeliness and legal effectiveness, and providing an end-to-end intelligent solution for clinical decision support systems.
[0025] 17. Expand data through adversarial networks, that is, using generative adversarial networks (GANs) to address the scarcity of medical data, generate high-fidelity synthetic data, break through the limitations of traditional data augmentation methods, and effectively alleviate model bias caused by small sample training; divide the data set through stratified sampling, that is, stratified sampling based on disease / case characteristics, to ensure balanced data distribution in training sets, validation sets, and test sets, and avoid missing key cases due to random partitioning. This is particularly suitable for dealing with the long-tail distribution problem of rare disease data.
[0026] 18. By alternating the use of inference loss functions (to ensure prediction accuracy) and inference reward functions (to enhance clinical logic consistency), the optimization limitations of a single loss function are overcome, improving inference accuracy while reducing clinical decision-making risks. By dynamically adjusting key parameters such as learning rate and batch size, adaptive learning rhythm control is achieved. Compared with fixed parameter settings, this effectively improves training efficiency and avoids local optimal traps. By implementing dynamic pruning during training, redundant connections are removed in real time based on the intensity of neuron activation, effectively reducing the model size and significantly lowering the hardware threshold for deploying equipment.
[0027] 19. Through the collaborative data enhancement strategy of adversarial network generation and stratified sampling, the problem of medical data scarcity is effectively solved. Combined with dynamic hyperparameter tuning and online model pruning technology, it improves the accuracy of model reasoning while achieving high efficiency and lightweight. Innovatively construct a verification and testing system that includes multi-dimensional indicators such as hallucination reasoning suppression rate and knowledge conflict resolution rate. Through a two-stage feedback mechanism, the closed-loop optimization of training data and model architecture is driven, which significantly enhances the reliability and interpretability of clinical decision-making. Ultimately, while ensuring that the reasoning logic complies with medical standards, a double breakthrough in reasoning efficiency and accuracy is achieved.
[0028] 20. By adopting double encryption of AES-128-GCM (symmetric encryption) and ChaCha20-Poly1305 (stream encryption), it takes into account both performance and security and prevents the risk of data leakage during transmission and storage. The model signature value is generated by the SM3 algorithm to ensure the integrity and source credibility of the model and prevent tampering or the implantation of malicious code. Through two-way authentication between the federal gateway and the medical terminal, illegal terminal access or man-in-the-middle attacks are eliminated.
[0029] 21. The model transmission security is ensured by a multi-layer encryption system (AES-128-GCM+ChaCha20-Poly1305) and a dynamic character replacement mechanism. The SM3 signature verification and two-way authentication mechanism are combined to prevent tampering and illegal access, ensuring the privacy compliance of medical data. The load balancing and service discovery capabilities of the federal gateway are used to achieve dynamic resource scheduling. Lightweight ONNX model conversion and metadata standardization are used to reduce terminal computing power requirements and support precise adaptation across scenarios. At the same time, local deployment and hierarchical decryption processes are used to reduce network dependence and improve emergency decision-making efficiency.
[0030] 22. Use MAC value (message authentication code) to perform integrity verification on key information such as request time, query request, account and password to ensure that data has not been tampered with during transmission and prevent malicious attacks; by adding request time verification, replay attacks can be effectively identified and blocked to avoid illegal use of expired or repeated requests; through account and password legitimacy verification, the legal identity of the operating subject is further ensured to prevent unauthorized access; through the three-layer verification process of integrity verification (MAC value) → timeliness verification (request time) → identity legitimacy verification (account and password), a progressive security protection system is formed to significantly reduce the risk of data leakage and misoperation.
[0031] 23. The deployed clinical decision-making collaborative reasoning model uses hardware acceleration technology (such as GPU, TPU or FPGA) to achieve accelerated reasoning, significantly shortening the time to generate reasoning results and meeting the high real-time requirements in clinical scenarios. Hardware acceleration technology can efficiently allocate computing resources, reduce system latency, avoid response bottlenecks caused by high concurrency requests, and improve the service capabilities of medical terminals.
[0032] 24. The generated reasoning report contains three parts: reasoning results, reasoning basis, and reasoning path. It not only provides conclusions, but also explains the logical chain and medical basis, enhancing doctors' trust in model decisions.
[0033] 25. By combining multiple security verification mechanisms (MAC value integrity verification, request time anti-replay, account and password authentication), data security and privacy protection are strengthened, and hardware acceleration technology is used to significantly improve the reasoning efficiency of clinical decision-making models to ensure real-time response; at the same time, the structured reasoning reports it generates have both explainability and auxiliary value, promoting efficient collaboration between doctors and AI, and the modular design meets medical compliance requirements on the basis of ensuring cross-platform compatibility, effectively solving the bottlenecks of traditional systems in terms of security, efficiency and explainability.
[0034] 26. By locally performing data desensitization and uploading model parameters (rather than raw data), patient privacy is doubly protected; the risk of privacy leakage is further reduced through the differential parameter transmission mechanism (rather than the complete model), forming a closed loop of data security protection.
[0035] 27. A training mechanism triggered by a log quantity threshold (e.g., every 1,000 logs) maximizes data utilization efficiency; a cloud server parameter fusion algorithm (weighted average / differential privacy aggregation, etc.) balances model convergence speed and data heterogeneity; and a differential parameter feedback mechanism significantly reduces communication costs.
[0036] 28. Support medical responsibility traceability through multi-dimensional log records (doctor account + timestamp + query request); ensure model stability through a dual performance verification mechanism (terminal local verification + cloud global verification); realize emergency rollback function through model version backup and difference comparison to meet the reliability requirements of the medical system.
[0037] 29. Through the deep integration of local data desensitization and the federated learning framework, a dynamic and efficient medical AI collaborative optimization system is built while ensuring patient privacy compliance: the terminal triggers local training based on log thresholds, the cloud realizes global model iteration through parameter fusion, and the differential parameter transmission mechanism reduces the communication load by more than 70%; the dual performance verification and model backup mechanism ensures the reliability of reasoning, supports medical responsibility traceability and emergency rollback, while edge computing and asynchronous update strategies balance the allocation of computing resources, realize the compliance mining of cross-institutional medical data value and the continuous improvement of model accuracy, and effectively solve the data island and privacy protection problems in the implementation of medical AI.
[0038] 30. By using the superposition of three algorithms: SHA-256 (hash), AES-128-CBC (symmetric encryption), and RSA (asymmetric encryption), attackers are forced to break through three encryption mechanisms at the same time, greatly increasing the cost of cracking; the combination of SHA-256 and RSA can resist traditional brute force cracking, while AES-128 still maintains high security in a quantum computing environment, forming technical generational redundant protection.
[0039] 31. Through the multiple encryption mechanisms of SHA-256 hash check, AES-128-CBC and RSA algorithms, combined with hexadecimal conversion and dynamic character obfuscation processing, a full-link security protection system for medical data from generation to storage is constructed: while ensuring data integrity and anti-tampering capabilities, the ability of ciphertext to resist reverse analysis and quantum attacks is greatly improved through algorithm cascading and obfuscation operations; the distributed backup design further enhances disaster recovery reliability and is compatible with fine-grained access control, achieving high-intensity confidential storage of sensitive medical information at a lightweight computing cost, meeting privacy compliance and business continuity requirements, and significantly improving the security protection level of medical data.
[0040] 32. By simultaneously processing structured health guidelines (disease definitions, clinical pathways, etc.) and unstructured medical records (text, images, time series data), the multi-dimensional information required for the entire reasoning process is covered, thereby improving the breadth of data utilization; through the multimodal encoding layer (BioBERT, residual convolutional network, graph attention network), text, image, and structural relationship features are extracted to achieve cross-modal semantic alignment, solving the problem of traditional methods relying on a single data type; by using medical information monitoring agents to capture the latest medical information (patents, papers, clinical guidelines, etc.) in real time, combined with differential privacy algorithms to ensure the security of data updates and avoid knowledge obsolescence problems; through the joint decoding layer (CRF, GNN, multi-headed pointer network), medical entities, relationships, and attributes are accurately extracted to build a high-precision knowledge graph to provide structured knowledge support for reasoning.
[0041] 33. Through the dual-stream cross-attention module, the generalized reasoning ability of the medical large language model (LLM) and the precise logical constraints of the knowledge graph are combined, and temporal reasoning and knowledge verification are realized through the temporal convolutional network to reduce the risk of model "hallucination". The latest clinical guidelines are embedded in the LLM parameter space in the form of a low-rank matrix through the dynamic knowledge injection module to ensure that the reasoning results meet the standards of evidence-based medicine. The causal chain is generated through the causal reasoning module (differentiable Markov logic network), and the medical ontology template engine is combined to output a reasoning report containing the reasoning basis and path to meet the transparency requirements of clinical decision-making. Through confidence assessment and multi-disease confusion matrix verification, the reliability of reasoning is quantified to assist doctors in quickly verifying the model conclusions.
[0042] 34. Innovatively integrate multimodal medical data, dynamic knowledge graphs, and medical large language models to achieve accurate and explainable clinical decision support through multimodal encoding alignment, dual-stream collaborative reasoning, and differential privacy updates. At the same time, with the help of federated learning mechanisms and a three-level encryption system, data privacy and cross-institutional collaboration security are guaranteed. Combined with dynamic pruning lightweight deployment, causal reasoning chain generation, and evidence-based medicine ontology constraints, it significantly improves reasoning accuracy, system robustness, and legal compliance, effectively solving core pain points in the field of medical AI, such as data silos, knowledge lags, model black boxes, and privacy leaks, and provides an efficient, secure, and reliable integrated solution for smart healthcare. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0044] Figure 1 This is a flowchart of a collaborative reasoning method that integrates medical knowledge graph and large model in the present invention.
[0045] Figure 2 It is a structural diagram of a collaborative reasoning system that integrates medical knowledge graph and large model in the present invention. DETAILED DESCRIPTION
[0046] The technical solution in the embodiments of the present application has the following overall idea: the input query request is inferred through a clinical decision collaborative reasoning model that combines the medical knowledge graph and the medical big language model, effectively combining the advantages of the medical knowledge graph and the medical big language model, and the reasoning report output by the clinical decision collaborative reasoning model carries the reasoning results, reasoning basis and reasoning path, effectively enhancing credibility; the medical knowledge graph is dynamically updated through medical information monitored by the medical information monitoring agent, and the collaborative reasoning model is iteratively optimized through the reasoning log, so that the medical knowledge graph and the medical big language model are kept up to date, combined with the security mechanism of the federal gateway, the verification of the query request, the encryption and distributed backup of the reasoning log, thereby improving the reasoning ability, timeliness, interpretability and security of medical reasoning.
[0047] Please refer to Figures 1 to 2 As shown, a preferred embodiment of the collaborative reasoning method of the present invention that integrates medical knowledge graph and large model includes the following steps: Step S1: The cloud server obtains a large amount of historical medical data including structured health guides and unstructured medical records, and constructs a medical dataset after preprocessing the historical medical data; Step S2: The cloud server extracts multimodal medical entities, medical relationships, and medical attributes from the medical dataset using a pre-trained medical information extraction model, and constructs a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; Step S3: The cloud server creates a medical information monitoring agent, monitors the latest medical information through the medical information monitoring agent, verifies each piece of monitored medical information, and updates the medical knowledge graph based on the medical information using a differential privacy algorithm; Step S4: The cloud server creates a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and sets the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; Step S5: The cloud server trains the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and deploys the trained clinical decision collaborative reasoning model; Step S6: The cloud server deploys a federated gateway, and pushes the clinical decision collaborative reasoning model to the distributed medical terminals through the federated gateway; Step S7: The medical terminal receives the input query request, parses and verifies the query request to obtain a query demand, inputs the query demand into the deployed clinical decision collaborative reasoning model to obtain a reasoning report including the reasoning result, reasoning basis, and reasoning path, and displays the reasoning report; the reasoning report is for reference only and is not a diagnosis result; Step S8: The medical terminal records in real time an inference log including at least the doctor's account number, inference time, query request, inference report, and inference feedback, and uses the inference log to iteratively optimize the collaborative inference model through a federated learning mechanism; Step S9: The medical terminal encrypts and distributes the reasoning log; The step S1 is specifically as follows: The cloud server acquires a large amount of historical medical data, including structured health guidelines and unstructured medical records; the health guidelines include at least disease definitions, treatment recommendations, prognosis assessments, recommendations for special populations, clinical pathways, and references; the medical records include at least patient information, chief presentation and present medical history, past medical history, physical examination data, auxiliary examination data, preliminary assessment results, differential assessment results, treatment process, disease progression data, consultation records, and discharge summaries; the auxiliary examination data include at least text data and image data; The historical medical data are preprocessed in sequence by data desensitization, data cleaning, data unification and feature extraction, and the medical data set is constructed after the preprocessed historical medical data are labeled with treatment effects, query requests, reasoning results, reasoning basis and reasoning paths.
[0048] In step S2, the medical information extraction model is constructed based on a multimodal encoding layer, a cross-modal alignment layer, and a joint decoding layer; The multimodal encoding layer is constructed based on a text encoding module, an image encoding model, a structure encoding module, and a feature mapping module; the text encoder is used to extract text features from a medical dataset through a BioBERT network; the image encoding model is used to extract image features from a medical dataset through a residual convolutional network; the structure encoding module is used to extract node relationship perception features from a medical dataset through a graph attention network; the feature mapping module is used to map text features, image features, and node relationship perception features to a unified semantic space through a fully connected layer to obtain corresponding modality embedding; The cross-modal alignment layer is constructed based on the modal interaction module and the gated fusion module; the modal interaction module is used to establish a semantic association matrix of the modal embeddings corresponding to the text features, image features, and node relationship perception features through a cross-attention mechanism; the gated fusion module is used to dynamically adjust the modal contribution of each modal embedding in the semantic association matrix through learnable gating weights to obtain a context-aware representation; The joint decoding layer is constructed based on an entity decoding branch, a relationship decoding branch, and an attribute decoding branch; the entity decoding branch is used to perform sequence labeling on the context-aware representation through a conditional random field, thereby identifying medical entities; the relationship decoding branch is used to construct entity associations on the context-aware representation through a graph neural network, and classify the entity associations through a relationship classifier to obtain medical relationships; the attribute decoding branch is used to locate medical attributes from the context-aware representation through a multi-headed pointer network; Conditional Random Fields (CRF) is a discriminative model commonly used in sequence labeling tasks, particularly in natural language processing (NLP) and computer vision (CV). CRF layers are typically used to process data with sequential structure, such as part-of-speech tagging in text, named entity recognition (NER), and pixel segmentation in images.
[0049] A relation classifier is a classification model used to identify semantic relationships between entities in text. Given two entities, the goal of a relation classifier is to predict the type of relationship between them. For example, in the sentence "Apple was founded by Steve Jobs," a relation classifier can identify the "founded" relationship between "Apple" and "Steve Jobs."
[0050] The Multi-Head Pointer Network (MHPN) is a model that combines a multi-head attention mechanism with a pointer network. It is used to process sequence-to-sequence tasks, especially when the output sequence is a subset or permutation of the input sequence. This network structure can effectively handle tasks such as the Traveling Salesman Problem (TSP), text summarization, and question-answering systems.
[0051] The extraction loss function of the medical information extraction model is constructed by weighting entity loss, relationship loss and attribute loss; the entity loss adopts cross entropy loss with category weight; the relationship loss adopts binary cross entropy loss; the attribute loss adopts multi-label marginal loss with threshold adjustment; The step S3 is specifically as follows: The cloud server creates a medical information monitoring agent based on crawler technology, and sets the monitoring channels, monitoring frequency, data crawling rules, and dynamic IP proxy pool of the medical information monitoring agent; the monitoring channels include at least official APIs, academic databases, patent databases, paper databases, industry news websites, and professional forums; The latest medical information is monitored by the medical information monitoring agent. After format verification (such as JSON Schema / XSD), logic verification (such as time sequence / numeric range) and conflict verification (comparison with the existing knowledge graph) are performed on each piece of the monitored medical information, each piece of the medical information is pre-processed for data cleaning and data anonymization. Noise is added to the pre-processed medical information through a differential privacy algorithm. Medical knowledge including medical entities, medical relationships and medical attributes is extracted from the medical information after the noise is added through the medical information extraction model, and the medical knowledge graph is then updated.
[0052] In step S4, the multimodal fusion layer is constructed based on a semantic parsing module, a graph retrieval module, and a modal alignment module; the semantic parsing module is used to extract deep semantic representations from the input query request through a Transformer, and to perform semantic parsing on the deep semantic representations through a bidirectional attention mechanism to obtain unstructured semantic text; the graph retrieval module is used to synchronously retrieve the medical knowledge graph using the query request to obtain structured medical knowledge; the modal alignment module is used to perform modal alignment between the semantic text and the retrieved medical knowledge through the constraints of the medical ontology; The collaborative reasoning layer is constructed based on a dual-stream cross-attention module, a dynamic knowledge injection module and a hypothesis verification module; the dual-stream cross-attention module is used to establish an interactive channel between a pre-trained medical large language model and a medical knowledge graph, and input semantic text and medical knowledge into the medical large language model and the medical knowledge graph through the interactive channel, and interactively reason the input semantic text and medical knowledge through a temporal convolutional network and a temporal memory network, thereby generating candidate reasoning hypotheses; the dynamic knowledge injection module is used to vectorize the latest clinical guidelines through a real-time knowledge adapter, and inject them into the parameter space of the medical large language model in the form of a low-rank matrix; the hypothesis verification module is used to infer the confidence assessment of the candidate reasoning hypothesis through a differential logic reasoner, and input the candidate reasoning hypothesis carrying the confidence assessment into the interpretation generation layer; The Differential Logic Reasoner (DLR) is a model that combines logical reasoning and deep learning techniques. It is designed to handle logical reasoning tasks in a differentiable manner. By combining logical rules and neural networks, it enables the model to learn and reason using optimization methods such as gradient descent while maintaining logical expressiveness.
[0053] The explanation generation layer is constructed based on a causal reasoning module and an evidence-based alignment module; the causal reasoning module is used to perform causal reasoning on the candidate reasoning hypothesis through a differentiable Markov logic network to obtain a causal chain; the evidence-based alignment module is used to convert the causal chain into an inference report containing inference results, inference basis, and inference path through a medical ontology template engine, and output the inference report; The formula of the inference loss function is: L_total=α*L_align+β*L_reason+γ*L_explain; Among them, L_total represents the inference loss value; L_align represents the modality alignment loss function; L_reason represents the collaborative reasoning loss function; L_explain represents the explanation generation loss function; α, β, and γ all represent the loss component weight coefficients, and α+β+γ=1; L_align=1-cos_sim(E_text, E_know); Where, E_text∈R^d represents the semantic text encoding vector, R is a real number, and d is the encoding dimension; E_know∈R^d represents the medical knowledge encoding vector; cos_sim represents the cosine similarity calculation; L_align is used to constrain the representation consistency of unstructured text and structured knowledge in the latent space; L_reason=CE(y_pred, y_true)+λ*KL(p_conf||p_true); Where CE represents the cross entropy loss function; y_pred∈R^C represents the probability distribution of candidate inference hypotheses, C is the number of disease categories; y_true∈R^C represents the true result label distribution; KL represents the Kullback-Leibler divergence; p_conf∈R^C represents the confidence distribution of the model output; p_true∈R^C represents the confidence benchmark of the expert annotation; L_reason = the accuracy (CE term) and confidence calibration (KL term) used to supervise the inference hypothesis; λ represents the weight coefficient; L_explain=Σ_{s∈S}[CE(g_s, g_s^)+δROUGE(g_s, g_s^)]; Where S = {report, basis, path}, which represents the set of evidence-based medicine elements; g_s represents the word-level probability distribution of the generated text; g_s^ represents the reference text annotated by experts; ROUGE represents the text semantic matching index; L_explain is used to constrain the factual accuracy (CE term) and medical logical coherence (ROUGE term) of the reasoning results; δ represents the weight coefficient; The formula of the inference reward function is: R_total=ω1*R_accuracy+ω2*R_consistency+ω3*R_coherence+ω4*R_confidence+ω5*R_evidence; Among them, R_total represents the reasoning reward value; R_accuracy represents the reasoning accuracy reward; R_consistency represents the knowledge consistency reward; R_coherence represents the logical coherence reward; R_confidence represents the confidence calibration reward; R_evidence represents the evidence-based integrity reward; ω1~ω5∈[0,1], represents the reward component weight, satisfying Σωi=1; R_accuracy=F1(y_pred, y_true)+AUC-ROC(p_conf, y_true); Among them, F1 represents the F1 score of disease classification (the harmonic average of precision and recall); AUC-ROC represents the area under the ROC curve of confidence prediction; R_accuracy is used to motivate the dual accuracy of the model in disease classification and confidence assessment; R_consistency=KG_Recall(h, G)*cos_sim(E_h, E_kg); Among them, KG_Recall represents the path recall rate of the candidate hypothesis h in the knowledge graph G; E_h∈R^d represents the hypothesis encoding vector; E_kg∈R^d represents the knowledge graph subgraph encoding vector; R_consistency is used to constrain the logical association strength between the inference hypothesis and the medical knowledge graph; ; Where p_t represents the probability distribution of the t-th step reasoning decision; C_{1:t-1} represents the historical reasoning context state; R_coherence is used to strengthen the causal coherence of the reasoning path in multi-step reasoning (calculated by conditional probability gain); represents the empty set; R_confidence=1-|Brier(p_conf,y_true)-Brier(p_expert,y_true)|; Among them, Brier represents the Brier score calibration indicator, which calculates the mean square error between the predicted confidence and the true label; p_expert represents the confidence benchmark of the expert annotation; R_confidence is used to drive the model confidence distribution to align with the clinical expert evaluation standard; R_evidence=0.5ROUGE-L(r, r')+0.5*Coverage(s,S_EBM); Among them, ROUGE-L represents the long sequence matching degree between the generated report r and the standard report r'; Coverage represents the coverage ratio of the generated content to the evidence-based medicine element set S_EBM (medical history / examination / guidelines); R_evidence is used to ensure that the reasoning explanation meets the complete fact chain required by evidence-based medicine.
[0054] The step S5 is specifically as follows: After expanding the sample size of the medical dataset through the adversarial network, the medical dataset is divided into a training set, a validation set, and a test set through a stratified sampling method, and the clinical decision collaborative reasoning model is trained through the training set. In each round of training, the inference loss function and the inference reward function are alternately used to optimize the clinical decision collaborative reasoning model. During the training process, the hyperparameters of the clinical decision collaborative reasoning model, including at least a learning rate, a decay rate, a batch size, a random dropout rate, and the number of neurons, are dynamically adjusted, and a dynamic pruning compression operation is performed on the clinical decision collaborative reasoning model until a preset early stopping condition is met; The reasoning accuracy of the clinical decision collaborative reasoning model is calculated using the validation set to verify the clinical decision collaborative reasoning model. If the verification fails, the training set is expanded to continue training. If the verification passes, then: The hallucination reasoning suppression rate, confidence calibration error, knowledge conflict resolution rate and multi-disease confusion matrix of the clinical decision collaborative reasoning model are calculated using the test set to test the clinical decision collaborative reasoning model. If the test fails, the training set is expanded to continue training; if the test passes, the training is terminated and the trained clinical decision collaborative reasoning model is deployed.
[0055] During specific implementation, the hallucination reasoning suppression rate is tested through an adversarial test set (containing 50 fictitious symptom combinations), and the qualification standard is that the probability of generating non-medical entities is <0.01%; the confidence calibration error is the Brier score of the model's predicted probability and the actual accuracy; the knowledge conflict resolution rate is tested by injecting 10% outdated guidelines, and the model passes the test if the proportion of preferentially adopting the latest guidelines is ≥98%; the multi-disease confusion matrix is a stratified sampling test of the confusion of 100 diseases, and the key indicators are: sensitivity (Recall): missed diagnosis rate ≤3%; specificity (Specificity): misdiagnosis rate ≤1.5%; F1-score (especially important for cases with complications).
[0056] The step S6 is specifically as follows: The cloud server deploys a federated gateway that supports load balancing and traffic management, enables the service discovery mechanism of the federated gateway, configures a two-way authentication mechanism, and performs two-way authentication operations with each distributed medical terminal through the two-way authentication mechanism; The cloud server converts the format of the clinical decision collaborative reasoning model into lightweight ONNX, calculates the signature value of the clinical decision collaborative reasoning model through the SM3 algorithm, adds metadata including at least a version number, applicable scenarios, medical knowledge graph query path, and signature value to the clinical decision collaborative reasoning model, encrypts the clinical decision collaborative reasoning model with the added metadata through AES-128-GCM to obtain a first-level encryption model, performs Base64 encoding on the first-level encryption model, replaces the character "+" with "$", and replaces the character " / " with "@" to obtain a second-level encryption model, encrypts the second-level encryption model through ChaCha20-Poly1305 to obtain a third-level encryption model, and pushes the third-level encryption model to the distributed medical terminal through the federal gateway; The medical terminal receives the third-level encryption model pushed by the federal gateway, decrypts the third-level encryption model through ChaCha20-Poly1305 to obtain a second-level encryption model, replaces the characters "$" in the second-level encryption model with "+" and "@" with " / ", and performs Base64 decoding to obtain a first-level encryption model, decrypts the first-level encryption model through AES-128-GCM to obtain a clinical decision collaborative reasoning model, verifies the signature value carried by the metadata of the clinical decision collaborative reasoning model, and then locally deploys the clinical decision collaborative reasoning model; The step S7 is specifically as follows: The medical terminal obtains the query request inputted with the request time, query request, doctor account, doctor password and MAC value, where the MAC value is obtained by performing HMAC calculation on the request time, query request, doctor account and doctor password; The medical terminal parses the query request to obtain the request time, query request, doctor account, doctor password and MAC value, performs integrity verification through the MAC value, and then performs integrity verification through the request time, and then performs legitimacy verification through the doctor account and doctor password. If the verification passes, the query request is input into the deployed clinical decision collaborative reasoning model. The clinical decision collaborative reasoning model uses hardware acceleration technology to accelerate reasoning to obtain an inference report including inference results, inference basis and inference path, and displays the inference report through a display screen.
[0057] The step S8 is specifically as follows: The medical terminal records in real time the inference logs including at least the doctor's account, inference time, query request, inference report, and inference feedback. When the number of inference logs reaches a preset threshold, the local collaborative inference model is trained by performing a data desensitization operation on each inference log, and the performance of the trained collaborative inference model is verified. The model parameters of the collaborative inference model after performance verification are read and uploaded to the cloud server through the federated gateway. The cloud server backs up the locally deployed collaborative reasoning model, averages the parameter values of the model parameters uploaded by each medical terminal, and updates the collaborative reasoning model. The updated collaborative reasoning model is then performance-verified. After the performance verification passes, the backed-up collaborative reasoning model is compared to obtain difference parameters. The difference parameters are then sent to each medical terminal via the federated gateway. Each medical terminal iteratively optimizes the collaborative reasoning model based on the received difference parameters. The step S9 is specifically as follows: The medical terminal calculates the hash value of the inference log through SHA-256, encrypts the inference log and the hash value through AES-128-CBC to obtain primary encrypted data, converts the primary encrypted data into hexadecimal data, swaps the number 7 with the letter B, and swaps the number 9 with the letter C in the hexadecimal data to obtain secondary encrypted data, encrypts the secondary encrypted data into an encrypted log through the RSA algorithm, stores the encrypted log, and performs distributed backup.
[0058] A preferred embodiment of the collaborative reasoning system that integrates medical knowledge graphs and large models includes the following modules: A medical data set construction module is used for the cloud server to obtain a large amount of historical medical data including structured health guides and unstructured medical records, and to construct a medical data set after preprocessing each of the historical medical data; A medical knowledge graph construction module is used for the cloud server to extract multimodal medical entities, medical relationships, and medical attributes from the medical data set through a pre-trained medical information extraction model, and to construct a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; A medical knowledge graph update module is used to create a medical information monitoring agent on the cloud server, monitor the latest medical information through the medical information monitoring agent, verify each piece of monitored medical information, and then update the medical knowledge graph based on the medical information using a differential privacy algorithm; A clinical decision collaborative reasoning model creation module is used by the cloud server to create a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and to set the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; A clinical decision collaborative reasoning model training module is used for the cloud server to train the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and to deploy the trained clinical decision collaborative reasoning model; A clinical decision collaborative reasoning model push module is used to deploy a federated gateway on the cloud server, and push the clinical decision collaborative reasoning model to distributed medical terminals through the federated gateway; The collaborative reasoning module is used to obtain query requests input by the medical terminal, parse and verify the query requests to obtain query demands, input the query demands into the deployed clinical decision collaborative reasoning model to obtain a reasoning report including the reasoning results, reasoning basis and reasoning path, and display the reasoning report; the reasoning report is for reference only and is not a diagnosis result; The model iteration and optimization module is used for the medical terminal to record the inference log in real time, including at least the doctor's account, inference time, query request, inference report, and inference feedback. Through the federated learning mechanism, the inference log is used to iteratively optimize the collaborative inference model; An inference log storage module is used for the medical terminal to encrypt and distribute the inference log; The medical data set construction module is specifically used for: The cloud server acquires a large amount of historical medical data, including structured health guidelines and unstructured medical records; the health guidelines include at least disease definitions, treatment recommendations, prognosis assessments, recommendations for special populations, clinical pathways, and references; the medical records include at least patient information, chief presentation and present medical history, past medical history, physical examination data, auxiliary examination data, preliminary assessment results, differential assessment results, treatment process, disease progression data, consultation records, and discharge summaries; the auxiliary examination data include at least text data and image data; The historical medical data are preprocessed in sequence by data desensitization, data cleaning, data unification and feature extraction, and the medical data set is constructed after the preprocessed historical medical data are labeled with treatment effects, query requests, reasoning results, reasoning basis and reasoning paths.
[0059] In the medical knowledge graph construction module, the medical information extraction model is constructed based on a multimodal encoding layer, a cross-modal alignment layer, and a joint decoding layer; The multimodal encoding layer is constructed based on a text encoding module, an image encoding model, a structure encoding module, and a feature mapping module; the text encoder is used to extract text features from a medical dataset through a BioBERT network; the image encoding model is used to extract image features from a medical dataset through a residual convolutional network; the structure encoding module is used to extract node relationship perception features from a medical dataset through a graph attention network; the feature mapping module is used to map text features, image features, and node relationship perception features to a unified semantic space through a fully connected layer to obtain corresponding modality embedding; The cross-modal alignment layer is constructed based on the modal interaction module and the gated fusion module; the modal interaction module is used to establish a semantic association matrix of the modal embeddings corresponding to the text features, image features, and node relationship perception features through a cross-attention mechanism; the gated fusion module is used to dynamically adjust the modal contribution of each modal embedding in the semantic association matrix through learnable gating weights to obtain a context-aware representation; The joint decoding layer is constructed based on an entity decoding branch, a relationship decoding branch, and an attribute decoding branch; the entity decoding branch is used to perform sequence labeling on the context-aware representation through a conditional random field, thereby identifying medical entities; the relationship decoding branch is used to construct entity associations on the context-aware representation through a graph neural network, and classify the entity associations through a relationship classifier to obtain medical relationships; the attribute decoding branch is used to locate medical attributes from the context-aware representation through a multi-headed pointer network; Conditional Random Fields (CRF) is a discriminative model commonly used in sequence labeling tasks, particularly in natural language processing (NLP) and computer vision (CV). CRF layers are typically used to process data with sequential structure, such as part-of-speech tagging in text, named entity recognition (NER), and pixel segmentation in images.
[0060] A relation classifier is a classification model used to identify semantic relationships between entities in text. Given two entities, the goal of a relation classifier is to predict the type of relationship between them. For example, in the sentence "Apple was founded by Steve Jobs," a relation classifier can identify the "founded" relationship between "Apple" and "Steve Jobs."
[0061] The Multi-Head Pointer Network (MHPN) is a model that combines a multi-head attention mechanism with a pointer network. It is used to process sequence-to-sequence tasks, especially when the output sequence is a subset or permutation of the input sequence. This network structure can effectively handle tasks such as the Traveling Salesman Problem (TSP), text summarization, and question-answering systems.
[0062] The extraction loss function of the medical information extraction model is constructed by weighting entity loss, relationship loss and attribute loss; the entity loss adopts cross entropy loss with category weight; the relationship loss adopts binary cross entropy loss; the attribute loss adopts multi-label marginal loss with threshold adjustment; The medical knowledge graph updating module is specifically used to: The cloud server creates a medical information monitoring agent based on crawler technology, and sets the monitoring channels, monitoring frequency, data crawling rules, and dynamic IP proxy pool of the medical information monitoring agent; the monitoring channels include at least official APIs, academic databases, patent databases, paper databases, industry news websites, and professional forums; The latest medical information is monitored by the medical information monitoring agent. After format verification (such as JSON Schema / XSD), logic verification (such as time sequence / numeric range) and conflict verification (comparison with the existing knowledge graph) are performed on each piece of the monitored medical information, each piece of the medical information is pre-processed for data cleaning and data anonymization. Noise is added to the pre-processed medical information through a differential privacy algorithm. Medical knowledge including medical entities, medical relationships and medical attributes is extracted from the medical information after the noise is added through the medical information extraction model, and the medical knowledge graph is then updated.
[0063] In the clinical decision collaborative reasoning model creation module, the multimodal fusion layer is constructed based on the semantic parsing module, the graph retrieval module and the modal alignment module; the semantic parsing module is used to extract deep semantic representations from the input query demands through Transformer, and semantically parse the deep semantic representations through the bidirectional attention mechanism to obtain unstructured semantic text; the graph retrieval module is used to synchronously retrieve the medical knowledge graph using the query demands to obtain structured medical knowledge; the modal alignment module is used to perform modal alignment between the semantic text and the retrieved medical knowledge through the constraints of medical ontology; The collaborative reasoning layer is constructed based on a dual-stream cross-attention module, a dynamic knowledge injection module and a hypothesis verification module; the dual-stream cross-attention module is used to establish an interactive channel between a pre-trained medical large language model and a medical knowledge graph, and input semantic text and medical knowledge into the medical large language model and the medical knowledge graph through the interactive channel, and interactively reason the input semantic text and medical knowledge through a temporal convolutional network and a temporal memory network, thereby generating candidate reasoning hypotheses; the dynamic knowledge injection module is used to vectorize the latest clinical guidelines through a real-time knowledge adapter, and inject them into the parameter space of the medical large language model in the form of a low-rank matrix; the hypothesis verification module is used to infer the confidence assessment of the candidate reasoning hypothesis through a differential logic reasoner, and input the candidate reasoning hypothesis carrying the confidence assessment into the interpretation generation layer; The Differential Logic Reasoner (DLR) is a model that combines logical reasoning and deep learning techniques. It is designed to handle logical reasoning tasks in a differentiable manner. By combining logical rules and neural networks, it enables the model to learn and reason using optimization methods such as gradient descent while maintaining logical expressiveness.
[0064] The explanation generation layer is constructed based on a causal reasoning module and an evidence-based alignment module; the causal reasoning module is used to perform causal reasoning on the candidate reasoning hypothesis through a differentiable Markov logic network to obtain a causal chain; the evidence-based alignment module is used to convert the causal chain into an inference report containing inference results, inference basis, and inference path through a medical ontology template engine, and output the inference report; The formula of the inference loss function is: L_total=α*L_align+β*L_reason+γ*L_explain; Among them, L_total represents the inference loss value; L_align represents the modality alignment loss function; L_reason represents the collaborative reasoning loss function; L_explain represents the explanation generation loss function; α, β, and γ all represent the loss component weight coefficients, and α+β+γ=1; L_align=1-cos_sim(E_text, E_know); Where, E_text∈R^d represents the semantic text encoding vector, R is a real number, and d is the encoding dimension; E_know∈R^d represents the medical knowledge encoding vector; cos_sim represents the cosine similarity calculation; L_align is used to constrain the representation consistency of unstructured text and structured knowledge in the latent space; L_reason=CE(y_pred, y_true)+λ*KL(p_conf||p_true); Where CE represents the cross entropy loss function; y_pred∈R^C represents the probability distribution of candidate inference hypotheses, C is the number of disease categories; y_true∈R^C represents the true result label distribution; KL represents the Kullback-Leibler divergence; p_conf∈R^C represents the confidence distribution of the model output; p_true∈R^C represents the confidence benchmark of the expert annotation; L_reason = the accuracy (CE term) and confidence calibration (KL term) used to supervise the inference hypothesis; λ represents the weight coefficient; L_explain=Σ_{s∈S}[CE(g_s, g_s^)+δROUGE(g_s, g_s^)]; Where S = {report, basis, path}, which represents the set of evidence-based medicine elements; g_s represents the word-level probability distribution of the generated text; g_s^ represents the reference text annotated by experts; ROUGE represents the text semantic matching index; L_explain is used to constrain the factual accuracy (CE term) and medical logical coherence (ROUGE term) of the reasoning results; δ represents the weight coefficient; The formula of the inference reward function is: R_total=ω1*R_accuracy+ω2*R_consistency+ω3*R_coherence+ω4*R_confidence+ω5*R_evidence; Among them, R_total represents the reasoning reward value; R_accuracy represents the reasoning accuracy reward; R_consistency represents the knowledge consistency reward; R_coherence represents the logical coherence reward; R_confidence represents the confidence calibration reward; R_evidence represents the evidence-based integrity reward; ω1~ω5∈[0,1], represents the reward component weight, satisfying Σωi=1; R_accuracy=F1(y_pred, y_true)+AUC-ROC(p_conf, y_true); Among them, F1 represents the F1 score of disease classification (the harmonic average of precision and recall); AUC-ROC represents the area under the ROC curve of confidence prediction; R_accuracy is used to motivate the dual accuracy of the model in disease classification and confidence assessment; R_consistency=KG_Recall(h, G)*cos_sim(E_h, E_kg); Among them, KG_Recall represents the path recall rate of the candidate hypothesis h in the knowledge graph G; E_h∈R^d represents the hypothesis encoding vector; E_kg∈R^d represents the knowledge graph subgraph encoding vector; R_consistency is used to constrain the logical association strength between the inference hypothesis and the medical knowledge graph; ; Where p_t represents the probability distribution of the t-th step reasoning decision; C_{1:t-1} represents the historical reasoning context state; R_coherence is used to strengthen the causal coherence of the reasoning path in multi-step reasoning (calculated by conditional probability gain); represents the empty set; R_confidence=1-|Brier(p_conf,y_true)-Brier(p_expert,y_true)|; Among them, Brier represents the Brier score calibration indicator, which calculates the mean square error between the predicted confidence and the true label; p_expert represents the confidence benchmark of the expert annotation; R_confidence is used to drive the model confidence distribution to align with the clinical expert evaluation standard; R_evidence=0.5ROUGE-L(r, r')+0.5*Coverage(s,S_EBM); Among them, ROUGE-L represents the long sequence matching degree between the generated report r and the standard report r'; Coverage represents the coverage ratio of the generated content to the evidence-based medicine element set S_EBM (medical history / examination / guidelines); R_evidence is used to ensure that the reasoning explanation meets the complete fact chain required by evidence-based medicine.
[0065] The clinical decision collaborative reasoning model training module is specifically used to: After expanding the sample size of the medical dataset through the adversarial network, the medical dataset is divided into a training set, a validation set, and a test set through a stratified sampling method, and the clinical decision collaborative reasoning model is trained through the training set. In each round of training, the inference loss function and the inference reward function are alternately used to optimize the clinical decision collaborative reasoning model. During the training process, the hyperparameters of the clinical decision collaborative reasoning model, including at least a learning rate, a decay rate, a batch size, a random dropout rate, and the number of neurons, are dynamically adjusted, and a dynamic pruning compression operation is performed on the clinical decision collaborative reasoning model until a preset early stopping condition is met; The reasoning accuracy of the clinical decision collaborative reasoning model is calculated using the validation set to verify the clinical decision collaborative reasoning model. If the verification fails, the training set is expanded to continue training. If the verification passes, then: The hallucination reasoning suppression rate, confidence calibration error, knowledge conflict resolution rate and multi-disease confusion matrix of the clinical decision collaborative reasoning model are calculated using the test set to test the clinical decision collaborative reasoning model. If the test fails, the training set is expanded to continue training; if the test passes, the training is terminated and the trained clinical decision collaborative reasoning model is deployed.
[0066] During specific implementation, the hallucination reasoning suppression rate is tested through an adversarial test set (containing 50 fictitious symptom combinations), and the qualification standard is that the probability of generating non-medical entities is <0.01%; the confidence calibration error is the Brier score of the model's predicted probability and the actual accuracy; the knowledge conflict resolution rate is tested by injecting 10% outdated guidelines, and the model passes the test if the proportion of preferentially adopting the latest guidelines is ≥98%; the multi-disease confusion matrix is a stratified sampling test of the confusion of 100 diseases, and the key indicators are: sensitivity (Recall): missed diagnosis rate ≤3%; specificity (Specificity): misdiagnosis rate ≤1.5%; F1-score (especially important for cases with complications).
[0067] The clinical decision collaborative reasoning model push module is specifically used to: The cloud server deploys a federated gateway that supports load balancing and traffic management, enables the service discovery mechanism of the federated gateway, configures a two-way authentication mechanism, and performs two-way authentication operations with each distributed medical terminal through the two-way authentication mechanism; The cloud server converts the format of the clinical decision collaborative reasoning model into lightweight ONNX, calculates the signature value of the clinical decision collaborative reasoning model through the SM3 algorithm, adds metadata including at least a version number, applicable scenarios, medical knowledge graph query path, and signature value to the clinical decision collaborative reasoning model, encrypts the clinical decision collaborative reasoning model with the added metadata through AES-128-GCM to obtain a first-level encryption model, performs Base64 encoding on the first-level encryption model, replaces the character "+" with "$", and replaces the character " / " with "@" to obtain a second-level encryption model, encrypts the second-level encryption model through ChaCha20-Poly1305 to obtain a third-level encryption model, and pushes the third-level encryption model to the distributed medical terminal through the federal gateway; The medical terminal receives the third-level encryption model pushed by the federal gateway, decrypts the third-level encryption model through ChaCha20-Poly1305 to obtain a second-level encryption model, replaces the characters "$" in the second-level encryption model with "+" and "@" with " / ", and performs Base64 decoding to obtain a first-level encryption model, decrypts the first-level encryption model through AES-128-GCM to obtain a clinical decision collaborative reasoning model, verifies the signature value carried by the metadata of the clinical decision collaborative reasoning model, and then locally deploys the clinical decision collaborative reasoning model; The collaborative reasoning module is specifically used for: The medical terminal obtains the query request inputted with the request time, query request, doctor account, doctor password and MAC value, where the MAC value is obtained by performing HMAC calculation on the request time, query request, doctor account and doctor password; The medical terminal parses the query request to obtain the request time, query request, doctor account, doctor password and MAC value, performs integrity verification through the MAC value, and then performs integrity verification through the request time, and then performs legitimacy verification through the doctor account and doctor password. If the verification passes, the query request is input into the deployed clinical decision collaborative reasoning model. The clinical decision collaborative reasoning model uses hardware acceleration technology to accelerate reasoning to obtain an inference report including inference results, inference basis and inference path, and displays the inference report through a display screen.
[0068] The model iterative optimization module is specifically used for: The medical terminal records in real time the inference logs including at least the doctor's account, inference time, query request, inference report, and inference feedback. When the number of inference logs reaches a preset threshold, the local collaborative inference model is trained by performing a data desensitization operation on each inference log, and the performance of the trained collaborative inference model is verified. The model parameters of the collaborative inference model after performance verification are read and uploaded to the cloud server through the federated gateway. The cloud server backs up the locally deployed collaborative reasoning model, averages the parameter values of the model parameters uploaded by each medical terminal, and updates the collaborative reasoning model. The updated collaborative reasoning model is then performance-verified. After the performance verification passes, the backed-up collaborative reasoning model is compared to obtain difference parameters. The difference parameters are then sent to each medical terminal via the federated gateway. Each medical terminal iteratively optimizes the collaborative reasoning model based on the received difference parameters. The reasoning log storage module is specifically used for: The medical terminal calculates the hash value of the inference log through SHA-256, encrypts the inference log and the hash value through AES-128-CBC to obtain primary encrypted data, converts the primary encrypted data into hexadecimal data, swaps the number 7 with the letter B, and swaps the number 9 with the letter C in the hexadecimal data to obtain secondary encrypted data, encrypts the secondary encrypted data into an encrypted log through the RSA algorithm, stores the encrypted log, and performs distributed backup.
[0069] Although the specific embodiments of the present invention are described above, those skilled in the art should understand that the specific embodiments described are merely illustrative and are not intended to limit the scope of the present invention. Equivalent modifications and changes made by those skilled in the art in accordance with the spirit of the present invention should be included within the scope of protection of the claims of the present invention.
Claims
1. A collaborative reasoning method that integrates medical knowledge graphs and large models, characterized by: The steps include: Step S1: The cloud server obtains a large amount of historical medical data including structured health guides and unstructured medical records, and constructs a medical dataset after preprocessing the historical medical data; Step S2: The cloud server extracts multimodal medical entities, medical relationships, and medical attributes from the medical dataset using a pre-trained medical information extraction model, and constructs a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; Step S3: The cloud server creates a medical information monitoring agent, monitors the latest medical information through the medical information monitoring agent, verifies each piece of monitored medical information, and updates the medical knowledge graph based on the medical information using a differential privacy algorithm; Step S4: The cloud server creates a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and sets the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; Step S5: The cloud server trains the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and deploys the trained clinical decision collaborative reasoning model; Step S6: The cloud server deploys a federated gateway, and pushes the clinical decision collaborative reasoning model to the distributed medical terminals through the federated gateway; Step S7: The medical terminal obtains the input query request, parses and verifies the query request to obtain a query demand, inputs the query demand into the deployed clinical decision collaborative reasoning model to obtain a reasoning report including a reasoning result, reasoning basis, and reasoning path, and displays the reasoning report; Step S8: The medical terminal records in real time an inference log including at least the doctor's account number, inference time, query request, inference report, and inference feedback, and uses the inference log to iteratively optimize the collaborative inference model through a federated learning mechanism; Step S9: The medical terminal encrypts and distributes the reasoning log.
2. The collaborative reasoning method integrating a medical knowledge graph and a large model according to claim 1, characterized in that: The step S1 is specifically as follows: The cloud server acquires a large amount of historical medical data including structured health guidelines and unstructured medical records; Performing data desensitization, data cleaning, data unification, and feature extraction preprocessing on each of the historical medical data in sequence, annotating the preprocessed historical medical data with treatment effects, query requests, reasoning results, reasoning basis, and reasoning paths to construct a medical data set; In step S2, the medical information extraction model is constructed based on a multimodal encoding layer, a cross-modal alignment layer, and a joint decoding layer; The multimodal encoding layer is constructed based on a text encoding module, an image encoding model, a structure encoding module, and a feature mapping module; the text encoder is used to extract text features from a medical dataset through a BioBERT network; the image encoding model is used to extract image features from a medical dataset through a residual convolutional network; and the structure encoding module is used to extract node relationship perception features from a medical dataset through a graph attention network. The feature mapping module is used to map text features, image features, and node relationship perception features to a unified semantic space through a fully connected layer to obtain corresponding modality embedding; The cross-modal alignment layer is constructed based on the modal interaction module and the gated fusion module; the modal interaction module is used to establish a semantic association matrix of the modal embeddings corresponding to the text features, image features, and node relationship perception features through a cross-attention mechanism; the gated fusion module is used to dynamically adjust the modal contribution of each modal embedding in the semantic association matrix through learnable gating weights to obtain a context-aware representation; The joint decoding layer is constructed based on the entity decoding branch, the relationship decoding branch and the attribute decoding branch; The entity decoding branch is used to perform sequence annotation on the context-aware representation through a conditional random field, thereby identifying medical entities; the relationship decoding branch is used to construct entity associations on the context-aware representation through a graph neural network, and classify the entity associations through a relationship classifier to obtain medical relationships; The attribute decoding branch is used to locate medical attributes from the context-aware representation through a multi-headed pointer network; The extraction loss function of the medical information extraction model is constructed by weighting entity loss, relationship loss and attribute loss; the entity loss adopts cross entropy loss with category weight; the relationship loss adopts binary cross entropy loss; the attribute loss adopts multi-label marginal loss with threshold adjustment; The step S3 is specifically as follows: The cloud server creates a medical information monitoring agent based on crawler technology, and sets the monitoring channels, monitoring frequency, data crawling rules, and dynamic IP proxy pool of the medical information monitoring agent; the monitoring channels include at least official APIs, academic databases, patent databases, paper databases, industry news websites, and professional forums; The latest medical information is monitored by the medical information monitoring agent. After format verification, logic verification and conflict verification are performed on each piece of the monitored medical information, each piece of the medical information is pre-processed for data cleaning and data anonymization. Noise is added to the pre-processed medical information through a differential privacy algorithm. Medical knowledge including medical entities, medical relationships and medical attributes is extracted from the medical information after noise addition through the medical information extraction model, and the medical knowledge graph is updated.
3. The collaborative reasoning method integrating a medical knowledge graph and a large model according to claim 1, characterized in that: In step S4, the multimodal fusion layer is constructed based on a semantic parsing module, a graph retrieval module, and a modal alignment module; the semantic parsing module is used to extract deep semantic representations from the input query request through a Transformer, and to perform semantic parsing on the deep semantic representations through a bidirectional attention mechanism to obtain unstructured semantic text; the graph retrieval module is used to synchronously retrieve the medical knowledge graph using the query request to obtain structured medical knowledge; the modal alignment module is used to perform modal alignment between the semantic text and the retrieved medical knowledge through the constraints of the medical ontology; The collaborative reasoning layer is constructed based on a dual-stream cross-attention module, a dynamic knowledge injection module, and a hypothesis verification module; the dual-stream cross-attention module is used to establish an interactive channel between the pre-trained medical language model and the medical knowledge graph, through which semantic text and medical knowledge are input into the medical language model and the medical knowledge graph, and interactive reasoning is performed on the input semantic text and medical knowledge through a temporal convolutional network and a temporal memory network, thereby generating candidate reasoning hypotheses; The dynamic knowledge injection module is used to vectorize the latest clinical guidelines through a real-time knowledge adapter and inject them into the parameter space of the medical large language model in the form of a low-rank matrix; The hypothesis verification module is used to infer the confidence evaluation of the candidate reasoning hypothesis through the differential logic reasoner, and input the candidate reasoning hypothesis carrying the confidence evaluation into the explanation generation layer; The explanation generation layer is constructed based on the causal reasoning module and the evidence-based alignment module; The causal reasoning module is used to perform causal reasoning on the candidate reasoning hypothesis through a differentiable Markov logic network to obtain a causal chain; the evidence-based alignment module is used to convert the causal chain into an inference report containing inference results, inference basis, and inference path through a medical ontology template engine, and output the inference report; The formula of the inference loss function is: L_total=α*L_align+β*L_reason+γ*L_explain; Among them, L_total represents the inference loss value; L_align represents the modality alignment loss function; L_reason represents the collaborative reasoning loss function; L_explain represents the explanation generation loss function; α, β, and γ all represent the loss component weight coefficients, and α+β+γ=1; The formula of the inference reward function is: R_total=ω1*R_accuracy+ω2*R_consistency+ω3*R_coherence+ω4*R_confidence+ω5*R_evidence; Among them, R_total represents the reasoning reward value; R_accuracy represents the reasoning accuracy reward; R_consistency represents the knowledge consistency reward; R_coherence represents the logical coherence reward; R_confidence represents the confidence calibration reward; R_evidence represents the evidence-based integrity reward; ω1~ω5∈[0,1], represents the reward component weight, satisfying Σωi=1; The step S5 is specifically as follows: After expanding the sample size of the medical dataset through the adversarial network, the medical dataset is divided into a training set, a validation set, and a test set through a stratified sampling method, and the clinical decision collaborative reasoning model is trained through the training set. In each round of training, the inference loss function and the inference reward function are alternately used to optimize the clinical decision collaborative reasoning model. During the training process, the hyperparameters of the clinical decision collaborative reasoning model, including at least a learning rate, a decay rate, a batch size, a random dropout rate, and the number of neurons, are dynamically adjusted, and a dynamic pruning compression operation is performed on the clinical decision collaborative reasoning model until a preset early stopping condition is met; The reasoning accuracy of the clinical decision collaborative reasoning model is calculated using the validation set to verify the clinical decision collaborative reasoning model. If the verification fails, the training set is expanded to continue training. If the verification passes, then: The hallucination reasoning suppression rate, confidence calibration error, knowledge conflict resolution rate and multi-disease confusion matrix of the clinical decision collaborative reasoning model are calculated using the test set to test the clinical decision collaborative reasoning model. If the test fails, the training set is expanded to continue training; if the test passes, the training is terminated and the trained clinical decision collaborative reasoning model is deployed.
4. The collaborative reasoning method integrating a medical knowledge graph and a large model according to claim 1, characterized in that: The step S6 is specifically as follows: The cloud server deploys a federated gateway that supports load balancing and traffic management, enables the service discovery mechanism of the federated gateway, configures a two-way authentication mechanism, and performs two-way authentication operations with each distributed medical terminal through the two-way authentication mechanism; The cloud server converts the format of the clinical decision collaborative reasoning model into lightweight ONNX, calculates the signature value of the clinical decision collaborative reasoning model through the SM3 algorithm, adds metadata including at least a version number, applicable scenarios, medical knowledge graph query path, and signature value to the clinical decision collaborative reasoning model, encrypts the clinical decision collaborative reasoning model with the added metadata through AES-128-GCM to obtain a first-level encryption model, performs Base64 encoding on the first-level encryption model, replaces the character "+" with "$", and replaces the character " / " with "@" to obtain a second-level encryption model, encrypts the second-level encryption model through ChaCha20-Poly1305 to obtain a third-level encryption model, and pushes the third-level encryption model to the distributed medical terminal through the federal gateway; The medical terminal receives the third-level encryption model pushed by the federal gateway, decrypts the third-level encryption model through ChaCha20-Poly1305 to obtain a second-level encryption model, replaces the characters "$" in the second-level encryption model with "+" and "@" with " / ", and performs Base64 decoding to obtain a first-level encryption model, decrypts the first-level encryption model through AES-128-GCM to obtain a clinical decision collaborative reasoning model, verifies the signature value carried by the metadata of the clinical decision collaborative reasoning model, and then locally deploys the clinical decision collaborative reasoning model; The step S7 is specifically as follows: The medical terminal obtains the query request inputted with the request time, query request, doctor account, doctor password and MAC value, where the MAC value is obtained by performing HMAC calculation on the request time, query request, doctor account and doctor password; The medical terminal parses the query request to obtain the request time, query request, doctor account, doctor password and MAC value, performs integrity verification through the MAC value, and then performs integrity verification through the request time, and then performs legitimacy verification through the doctor account and doctor password. If the verification passes, the query request is input into the deployed clinical decision collaborative reasoning model. The clinical decision collaborative reasoning model uses hardware acceleration technology to accelerate reasoning to obtain an inference report including inference results, inference basis and inference path, and displays the inference report through a display screen.
5. The collaborative reasoning method integrating a medical knowledge graph and a large model according to claim 1 is characterized by: The step S8 is specifically as follows: The medical terminal records in real time the inference logs including at least the doctor's account, inference time, query request, inference report, and inference feedback. When the number of inference logs reaches a preset threshold, the local collaborative inference model is trained by performing a data desensitization operation on each inference log, and the performance of the trained collaborative inference model is verified. The model parameters of the collaborative inference model after performance verification are read and uploaded to the cloud server through the federated gateway. The cloud server backs up the locally deployed collaborative reasoning model, averages the parameter values of the model parameters uploaded by each medical terminal, and updates the collaborative reasoning model. The updated collaborative reasoning model is then performance-verified. After the performance verification passes, the backed-up collaborative reasoning model is compared to obtain difference parameters. The difference parameters are then sent to each medical terminal via the federated gateway. Each medical terminal iteratively optimizes the collaborative reasoning model based on the received difference parameters. The step S9 is specifically as follows: The medical terminal calculates the hash value of the inference log through SHA-256, encrypts the inference log and the hash value through AES-128-CBC to obtain primary encrypted data, converts the primary encrypted data into hexadecimal data, swaps the number 7 with the letter B, and swaps the number 9 with the letter C in the hexadecimal data to obtain secondary encrypted data, encrypts the secondary encrypted data into an encrypted log through the RSA algorithm, stores the encrypted log, and performs distributed backup.
6. A collaborative reasoning system integrating medical knowledge graphs and large models, characterized by: Includes the following modules: A medical data set construction module is used for the cloud server to obtain a large amount of historical medical data including structured health guides and unstructured medical records, and to construct a medical data set after preprocessing each of the historical medical data; A medical knowledge graph construction module is used for the cloud server to extract multimodal medical entities, medical relationships, and medical attributes from the medical data set through a pre-trained medical information extraction model, and to construct a medical knowledge graph based on the extracted medical entities, medical relationships, and medical attributes; A medical knowledge graph update module is used to create a medical information monitoring agent on the cloud server, monitor the latest medical information through the medical information monitoring agent, verify each piece of monitored medical information, and then update the medical knowledge graph based on the medical information using a differential privacy algorithm; A clinical decision collaborative reasoning model creation module is used by the cloud server to create a clinical decision collaborative reasoning model based on the multimodal fusion layer, the collaborative reasoning layer, and the explanation generation layer, and to set the reasoning loss function and the reasoning reward function of the clinical decision collaborative reasoning model; The multimodal fusion layer is used to perform semantic analysis on the input query to obtain unstructured semantic text, synchronously retrieve the medical knowledge graph through the query to obtain structured medical knowledge, and perform modality alignment on the semantic text and the retrieved medical knowledge before inputting them into the collaborative reasoning layer; The collaborative reasoning layer is used to interactively reason on the input semantic text and medical knowledge through the medical language model and the medical knowledge graph to obtain candidate reasoning hypotheses with confidence assessments, and input the candidate reasoning hypotheses into the explanation generation layer; The explanation generation layer is used to generate an inference report including inference results, inference basis and inference path based on the candidate inference hypothesis according to the evidence-based medicine framework; A clinical decision collaborative reasoning model training module is used for the cloud server to train the clinical decision collaborative reasoning model using the medical data set, the reasoning loss function, and the reasoning reward function, and to deploy the trained clinical decision collaborative reasoning model; A clinical decision collaborative reasoning model push module is used to deploy a federated gateway on the cloud server, and push the clinical decision collaborative reasoning model to distributed medical terminals through the federated gateway; A collaborative reasoning module is configured to receive a query request from a medical terminal, parse and verify the query request to obtain a query demand, input the query demand into a deployed clinical decision collaborative reasoning model to obtain a reasoning report including a reasoning result, reasoning basis, and reasoning path, and display the reasoning report; The model iteration and optimization module is used for the medical terminal to record the inference log in real time, including at least the doctor's account, inference time, query request, inference report, and inference feedback. Through the federated learning mechanism, the inference log is used to iteratively optimize the collaborative inference model; The inference log storage module is used by the medical terminal to encrypt and distribute the inference log.
7. The collaborative reasoning system integrating medical knowledge graph and large model according to claim 6, characterized in that: The medical data set construction module is specifically used for: The cloud server acquires a large amount of historical medical data including structured health guidelines and unstructured medical records; Performing data desensitization, data cleaning, data unification, and feature extraction preprocessing on each of the historical medical data in sequence, annotating the preprocessed historical medical data with treatment effects, query requests, reasoning results, reasoning basis, and reasoning paths to construct a medical data set; In the medical knowledge graph construction module, the medical information extraction model is constructed based on a multimodal encoding layer, a cross-modal alignment layer, and a joint decoding layer; The multimodal encoding layer is constructed based on a text encoding module, an image encoding model, a structure encoding module, and a feature mapping module; the text encoder is used to extract text features from a medical dataset through a BioBERT network; the image encoding model is used to extract image features from a medical dataset through a residual convolutional network; and the structure encoding module is used to extract node relationship perception features from a medical dataset through a graph attention network. The feature mapping module is used to map text features, image features, and node relationship perception features to a unified semantic space through a fully connected layer to obtain corresponding modality embedding; The cross-modal alignment layer is constructed based on the modal interaction module and the gated fusion module; the modal interaction module is used to establish a semantic association matrix of the modal embeddings corresponding to the text features, image features, and node relationship perception features through a cross-attention mechanism; the gated fusion module is used to dynamically adjust the modal contribution of each modal embedding in the semantic association matrix through learnable gating weights to obtain a context-aware representation; The joint decoding layer is constructed based on the entity decoding branch, the relationship decoding branch and the attribute decoding branch; The entity decoding branch is used to perform sequence annotation on the context-aware representation through a conditional random field, thereby identifying medical entities; the relationship decoding branch is used to construct entity associations on the context-aware representation through a graph neural network, and classify the entity associations through a relationship classifier to obtain medical relationships; The attribute decoding branch is used to locate medical attributes from the context-aware representation through a multi-headed pointer network; The extraction loss function of the medical information extraction model is constructed by weighting entity loss, relationship loss and attribute loss; the entity loss adopts cross entropy loss with category weight; the relationship loss adopts binary cross entropy loss; the attribute loss adopts multi-label marginal loss with threshold adjustment; The medical knowledge graph updating module is specifically used to: The cloud server creates a medical information monitoring agent based on crawler technology, and sets the monitoring channels, monitoring frequency, data crawling rules, and dynamic IP proxy pool of the medical information monitoring agent; the monitoring channels include at least official APIs, academic databases, patent databases, paper databases, industry news websites, and professional forums; The latest medical information is monitored by the medical information monitoring agent. After format verification, logic verification and conflict verification are performed on each piece of the monitored medical information, each piece of the medical information is pre-processed for data cleaning and data anonymization. Noise is added to the pre-processed medical information through a differential privacy algorithm. Medical knowledge including medical entities, medical relationships and medical attributes is extracted from the medical information after noise addition through the medical information extraction model, and the medical knowledge graph is updated.
8. The collaborative reasoning system integrating a medical knowledge graph and a large model according to claim 6, characterized in that: In the clinical decision collaborative reasoning model creation module, the multimodal fusion layer is constructed based on the semantic parsing module, the graph retrieval module and the modal alignment module; the semantic parsing module is used to extract deep semantic representations from the input query demands through Transformer, and semantically parse the deep semantic representations through the bidirectional attention mechanism to obtain unstructured semantic text; the graph retrieval module is used to synchronously retrieve the medical knowledge graph using the query demands to obtain structured medical knowledge; the modal alignment module is used to perform modal alignment between the semantic text and the retrieved medical knowledge through the constraints of medical ontology; The collaborative reasoning layer is constructed based on a dual-stream cross-attention module, a dynamic knowledge injection module, and a hypothesis verification module; the dual-stream cross-attention module is used to establish an interactive channel between the pre-trained medical language model and the medical knowledge graph, through which semantic text and medical knowledge are input into the medical language model and the medical knowledge graph, and interactive reasoning is performed on the input semantic text and medical knowledge through a temporal convolutional network and a temporal memory network, thereby generating candidate reasoning hypotheses; The dynamic knowledge injection module is used to vectorize the latest clinical guidelines through a real-time knowledge adapter and inject them into the parameter space of the medical large language model in the form of a low-rank matrix; The hypothesis verification module is used to infer the confidence evaluation of the candidate reasoning hypothesis through the differential logic reasoner, and input the candidate reasoning hypothesis carrying the confidence evaluation into the explanation generation layer; The explanation generation layer is constructed based on the causal reasoning module and the evidence-based alignment module; The causal reasoning module is used to perform causal reasoning on the candidate reasoning hypothesis through a differentiable Markov logic network to obtain a causal chain; the evidence-based alignment module is used to convert the causal chain into an inference report containing inference results, inference basis, and inference path through a medical ontology template engine, and output the inference report; The formula of the inference loss function is: L_total=α*L_align+β*L_reason+γ*L_explain; Among them, L_total represents the inference loss value; L_align represents the modality alignment loss function; L_reason represents the collaborative reasoning loss function; L_explain represents the explanation generation loss function; α, β, and γ all represent the loss component weight coefficients, and α+β+γ=1; The formula of the inference reward function is: R_total=ω1*R_accuracy+ω2*R_consistency+ω3*R_coherence+ω4*R_confidence+ω5*R_evidence; Among them, R_total represents the reasoning reward value; R_accuracy represents the reasoning accuracy reward; R_consistency represents the knowledge consistency reward; R_coherence represents the logical coherence reward; R_confidence represents the confidence calibration reward; R_evidence represents the evidence-based integrity reward; ω1~ω5∈[0,1], represents the reward component weight, satisfying Σωi=1; The clinical decision collaborative reasoning model training module is specifically used to: After expanding the sample size of the medical dataset through the adversarial network, the medical dataset is divided into a training set, a validation set, and a test set through a stratified sampling method, and the clinical decision collaborative reasoning model is trained through the training set. In each round of training, the inference loss function and the inference reward function are alternately used to optimize the clinical decision collaborative reasoning model. During the training process, the hyperparameters of the clinical decision collaborative reasoning model, including at least a learning rate, a decay rate, a batch size, a random dropout rate, and the number of neurons, are dynamically adjusted, and a dynamic pruning compression operation is performed on the clinical decision collaborative reasoning model until a preset early stopping condition is met; The reasoning accuracy of the clinical decision collaborative reasoning model is calculated using the validation set to verify the clinical decision collaborative reasoning model. If the verification fails, the training set is expanded to continue training. If the verification passes, then: The hallucination reasoning suppression rate, confidence calibration error, knowledge conflict resolution rate and multi-disease confusion matrix of the clinical decision collaborative reasoning model are calculated using the test set to test the clinical decision collaborative reasoning model. If the test fails, the training set is expanded to continue training; if the test passes, the training is terminated and the trained clinical decision collaborative reasoning model is deployed.
9. The collaborative reasoning system integrating medical knowledge graph and large model according to claim 6, characterized in that: The clinical decision collaborative reasoning model push module is specifically used to: The cloud server deploys a federated gateway that supports load balancing and traffic management, enables the service discovery mechanism of the federated gateway, configures a two-way authentication mechanism, and performs two-way authentication operations with each distributed medical terminal through the two-way authentication mechanism; The cloud server converts the format of the clinical decision collaborative reasoning model into lightweight ONNX, calculates the signature value of the clinical decision collaborative reasoning model through the SM3 algorithm, adds metadata including at least a version number, applicable scenarios, medical knowledge graph query path, and signature value to the clinical decision collaborative reasoning model, encrypts the clinical decision collaborative reasoning model with the added metadata through AES-128-GCM to obtain a first-level encryption model, performs Base64 encoding on the first-level encryption model, replaces the character "+" with "$", and replaces the character " / " with "@" to obtain a second-level encryption model, encrypts the second-level encryption model through ChaCha20-Poly1305 to obtain a third-level encryption model, and pushes the third-level encryption model to the distributed medical terminal through the federal gateway; The medical terminal receives the third-level encryption model pushed by the federal gateway, decrypts the third-level encryption model through ChaCha20-Poly1305 to obtain a second-level encryption model, replaces the characters "$" in the second-level encryption model with "+" and "@" with " / ", and performs Base64 decoding to obtain a first-level encryption model, decrypts the first-level encryption model through AES-128-GCM to obtain a clinical decision collaborative reasoning model, verifies the signature value carried by the metadata of the clinical decision collaborative reasoning model, and then locally deploys the clinical decision collaborative reasoning model; The collaborative reasoning module is specifically used for: The medical terminal obtains the query request inputted with the request time, query request, doctor account, doctor password and MAC value, where the MAC value is obtained by performing HMAC calculation on the request time, query request, doctor account and doctor password; The medical terminal parses the query request to obtain the request time, query request, doctor account, doctor password and MAC value, performs integrity verification through the MAC value, and then performs integrity verification through the request time, and then performs legitimacy verification through the doctor account and doctor password. If the verification passes, the query request is input into the deployed clinical decision collaborative reasoning model. The clinical decision collaborative reasoning model uses hardware acceleration technology to accelerate reasoning to obtain an inference report including inference results, inference basis and inference path, and displays the inference report through a display screen.
10. The collaborative reasoning system integrating medical knowledge graph and large model according to claim 6, characterized in that: The model iterative optimization module is specifically used for: The medical terminal records in real time the inference logs including at least the doctor's account, inference time, query request, inference report, and inference feedback. When the number of inference logs reaches a preset threshold, the local collaborative inference model is trained by performing a data desensitization operation on each inference log, and the performance of the trained collaborative inference model is verified. The model parameters of the collaborative inference model after performance verification are read and uploaded to the cloud server through the federated gateway. The cloud server backs up the locally deployed collaborative reasoning model, averages the parameter values of the model parameters uploaded by each medical terminal, and updates the collaborative reasoning model. The updated collaborative reasoning model is then performance-verified. After the performance verification passes, the backed-up collaborative reasoning model is compared to obtain difference parameters. The difference parameters are then sent to each medical terminal via the federated gateway. Each medical terminal iteratively optimizes the collaborative reasoning model based on the received difference parameters. The reasoning log storage module is specifically used for: The medical terminal calculates the hash value of the inference log through SHA-256, encrypts the inference log and the hash value through AES-128-CBC to obtain primary encrypted data, converts the primary encrypted data into hexadecimal data, swaps the number 7 with the letter B, and swaps the number 9 with the letter C in the hexadecimal data to obtain secondary encrypted data, encrypts the secondary encrypted data into an encrypted log through the RSA algorithm, stores the encrypted log, and performs distributed backup.
Citation Information
Patent Citations
Interrogation method and system based on knowledge graph and generative large model
CN117854748A
Knowledge graph-driven medical large model diagnosis method
CN118280562A
Multi-modal knowledge graph multi-hop reasoning method and system, terminal and storage medium
CN119358681A
Clinical decision-making method and system based on large language model and knowledge graph
CN120372020A
Medical strategy generation method and system combined with data flywheel reinforcement learning
CN120376172A
Cited By
Medical decision-making method and device based on neural symbol hybrid model, and storage medium
CN120727176A
Clinical aid decision analysis method and system based on electronic medical record
CN120748697A
Method and device for constructing medical knowledge graph
CN120930759A
Federal learning-based intelligent transfer and self-rescue guidance aid decision-making method and system
CN120952484A
Biomedical knowledge extraction, fusion and sharing method and system based on federal map data
CN120977608A
