Diabetes disease auxiliary diagnosis and treatment system based on knowledge graph

By constructing a knowledge graph-based diabetes auxiliary diagnosis and treatment system, and utilizing heterogeneous knowledge graphs and bidirectional graph neural network reasoning, the system solves the problem of difficulty in modeling the impact of dietary structure on drug metabolism in existing systems, and achieves more accurate blood glucose prediction and drug dosage adjustment.

CN123033653APending Publication Date: 2026-11-03THE FIRST AFFILIATED HOSPITAL OF ARMY MEDICAL UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202611259317.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-19
Publication Date
2026-11-03

AI Technical Summary

Technical Problem

Existing diabetes-aided diagnostic and treatment systems lack detailed modeling of dietary composition characteristics, making it difficult to reflect the synergistic effects of complex dietary structures on drug metabolism mechanisms, resulting in insufficient accuracy and reliability of individualized treatment recommendations.

Method used

A knowledge graph-based diabetes auxiliary diagnosis and treatment system was constructed. By quantifying the synergistic effect of patients' dietary structure on drug metabolism mechanisms, and using heterogeneous knowledge graphs and bidirectional graph neural network reasoning, individualized dynamic blood glucose prediction, drug dosage matching suggestions, and dietary structure optimization plans were generated.

Benefits of technology

It enables structured expression and unified modeling of multi-source factors such as diet, medication, and patient status, improving the accuracy and targeting of blood glucose prediction and drug dosage adjustment, and outputting personalized diagnosis and treatment strategies that are more in line with the patient's actual metabolic status.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123033653A_ABST
    Figure CN123033653A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of auxiliary diagnosis and treatment, in particular to an auxiliary diagnosis and treatment system for diabetes based on a knowledge graph, which comprises the following modules: a diet data acquisition module used for acquiring diet data of a patient, disassembling ingredients of food intake, and constructing a diet ingredient feature vector; a medicine data acquisition module used for acquiring data of a hypoglycemic medicine currently used by the patient, and constructing a medicine metabolism feature vector; a patient state monitoring module used for acquiring blood glucose monitoring data, exercise behavior data and sleep quality data of the patient, and constructing a patient state feature vector; a knowledge graph construction module used for constructing a heterogeneous knowledge graph; and a diagnosis and treatment strategy generation module used for executing bidirectional graph neural network reasoning based on the heterogeneous knowledge graph and generating an auxiliary diagnosis and treatment strategy. The application quantifies the synergistic influence of a diet structure of a patient on a medicine metabolism mechanism, and effectively improves the accuracy and reliability of auxiliary diagnosis and treatment for diabetes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of auxiliary diagnosis and treatment technology, and in particular to an auxiliary diagnosis and treatment system for diabetes based on knowledge graphs. Background Technology

[0002] Diabetes mellitus is a prevalent chronic, wasting, and metabolic disease, primarily affecting middle-aged and elderly individuals. Its pathogenesis is complex, and long-term management relies on the synergistic effects of multiple factors, including dietary control, medication, and lifestyle interventions. In actual clinical practice, differences in dietary structure, drug metabolism capacity, and behavioral habits lead to significantly individualized blood glucose fluctuation patterns among patients. This results in the same hypoglycemic regimen potentially producing drastically different effects in different patients. Furthermore, factors such as dietary intake, exercise intensity, and sleep quality further influence drug metabolism efficiency and insulin sensitivity. Therefore, achieving a holistic analysis of diet, medication, and patient metabolic status at the individual level is a key challenge in current diabetes management.

[0003] Existing auxiliary diagnostic and treatment systems for diabetes mainly rely on continuous glucose monitoring systems and standardized medication recommendations, and then use mathematical models to estimate blood glucose trends. For example, invention patent application CN117095828A discloses a method for predicting and alerting blood glucose levels based on follow-up records of diabetic patients. This method includes: collecting patient follow-up records and extracting raw blood glucose data, cleaning the data, and then using linear interpolation to complete the data; resampling the data at fixed time intervals and using quadratic interpolation to fill the gaps; finally, using an exponentially weighted moving average method to smooth and denoise the data. Using Bayesian information for automatic parameter tuning, a differential autoregressive moving average model, a gradient boosting decision tree model, and a long short-term memory network model were trained separately and then integrated. When the model predicts that a patient's future blood glucose level or trend is abnormal, an alarm message will be generated to help medical staff pay more attention to and manage patients. However, this type of method lacks fine modeling of dietary component characteristics, makes it difficult to reflect the synergistic effect of complex dietary structure on drug metabolism mechanism, and fails to incorporate the causal relationship between diet, drugs and patient behavior factors into a unified analysis framework, resulting in insufficient accuracy and reliability of individualized treatment recommendations. Summary of the Invention

[0004] To overcome the shortcomings and deficiencies of existing technologies, this invention provides an auxiliary diagnosis and treatment system for diabetes based on knowledge graphs. By quantifying the synergistic effect of patients' dietary structure on drug metabolism mechanisms, it effectively improves the accuracy and reliability of auxiliary diagnosis and treatment of diabetes.

[0005] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, the present invention provides an auxiliary diagnosis and treatment system for diabetes based on knowledge graphs, including a diet data acquisition module, a drug data acquisition module, a patient status monitoring module, a knowledge graph construction module, and a diagnosis and treatment strategy generation module; The dietary data acquisition module is used to acquire the patient's dietary data and break down the components of the ingested food to construct a dietary component feature vector. The drug data acquisition module is used to acquire data on the hypoglycemic drugs currently used by the patient and to construct a drug metabolism feature vector based on the drug action mechanism. The patient status monitoring module is used to acquire the patient's blood glucose monitoring data, exercise behavior data, and sleep quality data, and to construct a patient status feature vector that characterizes the patient's metabolic response ability. The knowledge graph construction module is used to construct a heterogeneous knowledge graph based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. The diagnosis and treatment strategy generation module is used to perform bidirectional graph neural network reasoning based on heterogeneous knowledge graphs and generate auxiliary diagnosis and treatment strategies based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of the patient's blood glucose in the future, drug dosage adaptation suggestions, and dietary structure optimization plans.

[0006] Furthermore, the specific execution steps of the knowledge graph construction module include: Based on the patient's dietary component feature vector, drug metabolism feature vector, and patient state feature vector, respectively construct a dietary subgraph, a drug subgraph, and a patient state subgraph; Candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are constructed between the diet subgraph, drug subgraph, and patient state subgraph. Structural screening and orientation are performed on each candidate cross-subgraph relationship to obtain diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges. By structurally integrating diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, a heterogeneous knowledge graph containing diet subgraphs, drug subgraphs, and patient state subgraphs is constructed, providing a knowledge structure foundation for bidirectional graph neural network reasoning.

[0007] Furthermore, the construction of the diet subgraph, the drug subgraph, and the patient state subgraph includes: By partitioning the feature vectors of dietary components into feature subspaces, carbohydrate structure, fat type, starch granule structure, amino acid composition, and dietary fiber type are respectively constructed as nutrient feature nodes in the dietary subgraph. Based on dietary data, the actual intake, intake frequency, and intake time distribution of each nutrient feature node within the target statistical period are calculated, and these are used as individual intake attributes for the corresponding nutrient feature nodes. Internal relationship edges within the dietary subgraph are established based on the similarity of nutritional features between different nutrient feature nodes, and the corresponding structural weights are determined according to the structural importance of each nutrient feature node. The individual intake attributes and structural weights of each nutrient feature node are combined as the node attributes of the corresponding nodes in the dietary subgraph. Based on the drug target, enzymatic metabolic pathway, liver metabolic level and dose intensity in the drug metabolism feature vector, target nodes, metabolic nodes and dose nodes in the drug subgraph are constructed, and directed metabolic pathways between nodes are established according to the drug action mechanism. By performing time-series encoding on the patient state feature vector, the continuous blood glucose monitoring trend, the exercise intensity change sequence and the sleep cycle rhythm are respectively constructed as nodes in the patient state subgraph, and a time decay factor reflecting the metabolic response speed is generated for each node. Candidate directed structures are formed based on candidate cross-subgraph relationships. The minimum description length corresponding to each candidate directed structure is calculated. The candidate directed structure whose minimum description length satisfies the optimal screening condition is selected as the target directed structure. The retention state and direction of diet-drug synergistic response edge, diet-glucose response edge, drug-state response edge and behavior regulation edge are determined according to the target directed structure. The edge weights are determined according to the goodness of fit of the corresponding directed relationship and the stability across the time window. Based on graph embedding algorithms, unified feature embedding is performed on the node vectors of diet subgraph, drug subgraph and patient state subgraph to achieve semantic space alignment of nodes across subgraphs. The semantic space aligned node embeddings, internal subgraph relations and filtered cross-subgraph relations are then structurally integrated to construct a heterogeneous knowledge graph.

[0008] Furthermore, the construction of candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges includes: Based on the cross-feature attention matrix of dietary component feature vectors and drug metabolism feature vectors, candidate dietary-drug synergistic response edges are constructed between dietary subgraphs and drug subgraphs to characterize the synergistic association between nutritional component features and drug metabolism features. Based on the patient's blood glucose monitoring data, the blood glucose change curve after food intake is fitted, and candidate food-blood glucose response edges are constructed between the food subgraph and the patient state subgraph to characterize the response correlation of different nutrient features to blood glucose changes after intake. Based on drug targets, metabolic enzyme pathways and dose intensity, candidate drug-state response edges are constructed between the drug subgraph and the patient state subgraph to characterize the association between drug action and drug metabolism state and patient blood glucose state and metabolic response state. Based on the correlation between patient behavioral characteristics and metabolic regulation capacity, candidate behavioral regulation edges are constructed between the patient state subgraph and the diet and drug subgraphs to characterize the regulatory effect of behavioral factors on the diet-glucose response relationship and the drug-state response relationship. Based on causal structure learning, candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are screened and oriented. Candidate relations that meet the temporal order constraint and directed structure screening conditions are retained as the corresponding diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges, and the weights of the corresponding edges are determined.

[0009] Furthermore, the knowledge graph construction module is also capable of executing a dynamic update mechanism for heterogeneous knowledge graphs, including: Based on changes in patients’ diet data, hypoglycemic drug data, and blood glucose monitoring data, a time decay factor is used to decay and update the node weights in the diet subgraph, drug subgraph, and patient status subgraph. The model uses a Bayesian structural learning model to detect whether the diet-glucose response relationship and the drug-state response relationship have drifted, and performs edge weight re-estimation on the significantly drifted associated edges. By using a graph incremental learning network based on a gated update strategy, newly added nodes and edges are embedded into the unified vector space of heterogeneous knowledge graphs while maintaining the semantic consistency of subgraphs. In the process of updating heterogeneous knowledge graphs, a graph conflict detection mechanism is used to perform minimum conflict adjustment on the conflict weights of diet-drug synergistic response edges and behavior regulation edges; Based on changes in patients' long-term metabolic trends, a topology update is performed on the node structure of the diet and drug subgraphs. The topology update includes node aggregation, node splitting, and cleaning up weakly correlated nodes.

[0010] Furthermore, the step of performing bidirectional graph neural network reasoning based on heterogeneous knowledge graphs includes: Forward message passing is performed from the diet subgraph to the drug subgraph. The state representation of drug target nodes, metabolism nodes and dose nodes is updated through graph convolution to simulate the changing trend of drug metabolism effect in patients under the current diet structure and individual intake state. Based on the drug subgraph, reverse message passing is performed to the diet subgraph. The influence strength of each nutrient feature node is inferred by the drug sensitivity gradient and drug metabolism pathway weight, and the restricted food categories and the corresponding intake risk levels of the restricted food categories are determined. By integrating the node update results of forward and backward reasoning, cross-subgraph aggregation operation is performed on the patient state subgraph to generate a prediction vector representing the dynamic changes in blood glucose in future time periods and a state score representing the metabolic regulation ability. A drug dosage adaptation model is constructed based on patient status feature vectors and blood glucose prediction vectors, and individualized dosage adjustment suggestions are output based on drug metabolism characteristics, physiological metabolic sensitivity and dietary synergistic effects. Based on the edge weight changes of the nutrient feature nodes in the diet subgraph and the restricted food categories and corresponding intake risk levels obtained through back reasoning, a diet structure optimization plan is generated. The diet structure plan includes recommended nutrient ratios, sensitive food substitution strategies, and individualized food tolerance suggestions. The system weighs multiple objectives, including dynamic blood glucose prediction results, medication dosage recommendations, and dietary optimization plans, and outputs auxiliary treatment strategies.

[0011] Secondly, this invention provides an auxiliary diagnostic and treatment method for diabetes based on knowledge graphs, including: Acquire patients' dietary data and break down the components of ingested food to construct dietary component feature vectors; Acquire data on the patient's current hypoglycemic medications and construct a drug metabolism feature vector based on the drug action mechanism; Acquire patients’ blood glucose monitoring data, exercise behavior data, and sleep quality data, and construct a patient state feature vector that characterizes patients’ metabolic response capabilities; A heterogeneous knowledge graph is constructed based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. Based on heterogeneous knowledge graphs, bidirectional graph neural network reasoning is performed, and auxiliary diagnosis and treatment strategies are generated based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of patients' blood glucose in future time periods, drug dosage adaptation suggestions, and dietary structure optimization plans.

[0012] Thirdly, the present invention provides an electronic device, comprising: a processor and a memory, wherein the memory stores a computer program that can be called by the processor, and the processor executes a knowledge graph-based auxiliary diagnosis and treatment method for diabetes by calling the computer program stored in the memory.

[0013] Fourthly, the present invention provides a computer-readable storage medium storing instructions that, when executed on a computer, cause the computer to perform a knowledge graph-based auxiliary diagnosis and treatment method for diabetes.

[0014] Compared with the prior art, the present invention has the following advantages and beneficial effects: (1) This invention constructs a heterogeneous knowledge graph covering three key elements: diet, medication and patient status, to realize the structured expression and unified modeling of multi-source factors in diabetes management. It can comprehensively depict the complex relationship between nutritional components, drug metabolism mechanisms and individual patient metabolic responses. By introducing dietary component characteristics, drug metabolism pathway structures and dynamic state characteristics driven by behavioral data, the basic data for auxiliary diagnosis and treatment has higher granularity and higher causal expression ability, effectively improving the accuracy and pertinence of blood glucose prediction and drug dosage adjustment.

[0015] (2) This invention designs a collaborative structure of diet subgraph, drug subgraph and patient state subgraph, and establishes diet-drug synergistic response edge, diet-blood glucose response edge, drug-state response edge and behavior regulation edge to realize cross-domain semantic alignment and directional correlation modeling between multiple subgraphs. It can effectively identify the synergistic effect of different diet structures on drug metabolism efficiency. At the same time, the bidirectional graph neural network reasoning mechanism is adopted so that the positive influence of diet on drug metabolism and the reverse regulation of drug on diet tolerance can be modeled synchronously, and can output more personalized diagnosis and treatment strategies that fit the patient's real metabolic state. Attached Figure Description

[0016] Other features, objects, and advantages of the invention will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings: Figure 1 This is a schematic diagram of the structure of the knowledge graph-based auxiliary diagnosis and treatment system for diabetes provided in an embodiment of the present invention; Figure 2 This is a flowchart illustrating the auxiliary diagnosis and treatment method for diabetes based on knowledge graphs provided in an embodiment of the present invention. Figure 3 This is a schematic diagram of the structure of the electronic device provided in an embodiment of the present invention. Detailed Implementation

[0017] The technical solution of the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the embodiments of the present invention and the specific features in the embodiments are detailed descriptions of the technical solution of the present invention, rather than limitations thereof. In the absence of conflict, the embodiments of the present invention and the technical features in the embodiments can be combined with each other.

[0018] Please see Figure 1, Figure 1 This is a schematic diagram of the structure of a knowledge graph-based auxiliary diagnosis and treatment system for diabetes provided in an embodiment of the present invention, including: The dietary data acquisition module 210 is used to acquire the patient's dietary data and break down the components of the ingested food to construct a dietary component feature vector. The drug data acquisition module 220 is used to acquire data on the hypoglycemic drugs currently used by the patient and construct a drug metabolism feature vector based on the drug action mechanism. The patient status monitoring module 230 is used to acquire the patient's blood glucose monitoring data, exercise behavior data and sleep quality data, and to construct a patient status feature vector that characterizes the patient's metabolic response ability. The knowledge graph construction module 240 is used to construct a heterogeneous knowledge graph based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. The diagnosis and treatment strategy generation module 250 is used to perform bidirectional graph neural network reasoning based on heterogeneous knowledge graphs and generate auxiliary diagnosis and treatment strategies based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of the patient's blood glucose in the future, drug dosage adaptation suggestions, and dietary structure optimization plans.

[0019] In this embodiment of the invention, the dietary data acquisition module 210 is used to acquire the patient's dietary data and decompose the ingested food into components to construct a dietary component feature vector. The patient's dietary data can be acquired through various acquisition methods, including smart plates, dietary photo recognition systems, online dietary record applications, and hospital nutrition follow-up systems. The dietary data includes the food category, actual intake, and intake time of the food ingested by the patient. The actual intake can be obtained through the weighing results of the smart plate, the food mass in the dietary record, or by conversion based on standard portions. Specifically, the dietary component decomposition process is achieved through food standardization mapping and nutrient feature extraction: the food items ingested by the patient are mapped to a food-nutrient database for standardized identification; the intake of each nutrient in the corresponding dietary event is calculated based on the nutrient content per unit mass of the standardized food and the actual intake mass of the food; based on the standardized identification, nutrient features such as carbohydrate structure, fat type, starch granule structure, amino acid composition, and dietary fiber type of the food are extracted, and the above nutrient features and their corresponding intake information are encoded into a dietary component feature vector in a preset order to ensure that dietary data from different sources have a consistent feature expression scale in the graph construction stage.

[0020] In this embodiment of the invention, the drug data acquisition module 220 is used to acquire the data of the hypoglycemic drugs currently used by the patient and construct a drug metabolism feature vector based on the drug action mechanism. The hypoglycemic drug data can be acquired through the electronic medical record system (EMR) and the electronic prescription system. The hypoglycemic drug data includes the drug category, current dose, frequency of use and time of use. Furthermore, it can obtain the corresponding drug's target, enzyme pathways involved in metabolism, drug half-life and liver metabolism related information according to the drug instructions or pharmacology database. The above information is structured and encoded to form a drug metabolism feature vector.

[0021] In this embodiment of the invention, the patient status monitoring module 230 is used to acquire the patient's blood glucose monitoring data, exercise behavior data, and sleep quality data, and construct a patient status feature vector characterizing the patient's metabolic response capability. The patient's blood glucose monitoring data can be acquired through a continuous glucose monitoring device (CGM), and the exercise behavior data and sleep quality data can be collected through a wearable device. Specifically, the construction of the patient status feature vector includes unified time alignment and metabolic response encoding of the three types of data: blood glucose, exercise, and sleep. Blood glucose monitoring data is extracted using a sliding window method to extract parameters such as the blood glucose rise slope, peak delay time, and fall rate. Exercise behavior data is calculated based on the metabolic equivalent (MET) standard to determine the metabolic load intensity parameter per unit time. Sleep quality data is used to generate a sleep rhythm stability parameter through the proportion of sleep stages and the frequency of nighttime awakenings. The above parameters serve as the core attributes of the patient status subgraph nodes, enabling the patient status subgraph to truly reflect the individual's metabolic adaptation capability at different time periods.

[0022] In this embodiment of the invention, the knowledge graph construction module 240 is used to construct a heterogeneous knowledge graph based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph.

[0023] The knowledge graph construction module is used to structurally represent inherently heterogeneous, cross-dimensional, and cross-semantic space data involved in diabetes diagnosis and treatment, such as dietary components, drug metabolism mechanisms, and patient metabolic status. This data is then constructed into a heterogeneous knowledge graph with clear semantic relationships. Through subgraph partitioning, cross-domain edge relationship establishment, and unified semantic embedding, the system can transform the three key factors—diet, medication, and status—from their original scattered data format into a graph structure with reasonability and interpretability. This enables the structured representation of multi-source heterogeneous diabetes diagnosis and treatment data, and allows patients' actual dietary intake status to be independently represented and dynamically updated, distinct from nutritional structure knowledge. This provides solid knowledge support for subsequent auxiliary treatment strategies such as blood glucose prediction, drug dosage adaptation, and dietary structure optimization. The specific execution steps of the knowledge graph construction module include: Based on the patient's dietary component feature vector, drug metabolism feature vector, and patient state feature vector, respectively construct a dietary subgraph, a drug subgraph, and a patient state subgraph; Candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are constructed between the diet subgraph, drug subgraph, and patient state subgraph. Structural screening and orientation are performed on each candidate cross-subgraph relationship to obtain diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges. By structurally integrating diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, a heterogeneous knowledge graph containing diet subgraphs, drug subgraphs, and patient state subgraphs is constructed, providing a knowledge structure foundation for bidirectional graph neural network reasoning.

[0024] Dietary characteristics, drug mechanisms of action, and patient metabolic status are inherently different data types with varying dimensions, granularities, and complex interactions. Directly describing them in tabular or sequential formats makes it difficult for models to accurately capture the relationships between these multiple factors. However, by constructing subgraphs of these three data types and creating hierarchical node structures, nutritional components, drug metabolic pathways, and metabolic behavior characteristics can be clearly expressed. This lays the foundation for subsequent cross-subgraph directional correlation analysis, semantic alignment, and bidirectional graph neural network inference. Furthermore, the dietary subgraph breaks down patient food intake into multidimensional nutritional elements such as carbohydrate structure, fat type, amino acid composition, and dietary fiber characteristics. It also separately stores the structural attributes of the nutritional components and the patient's actual intake status within the current statistical period, avoiding the substitution of single node weights for actual dietary intake. By quantifying the similarity of nutritional characteristics, the system can accurately identify the differences in the impact of different nutritional characteristics on glycemic response and drug metabolism. For example, while both are carbohydrates, amylose and amylopectin differ significantly in their digestion rate and glycemic effect. Graph structures can accurately capture these differences in prediction and inference. The construction of the drug subgraph allows the target sites, metabolic enzyme pathways, liver metabolic levels, and dose intensity of hypoglycemic drugs to be expressed in a directed path manner, clearly presenting key mechanisms such as how drugs are metabolized and how they affect insulin sensitivity. The construction of the patient status subgraph represents dynamic behavioral factors such as continuous blood glucose monitoring trends, changes in exercise intensity, and sleep cycle rhythms as time-series nodes, and assigns time decay factors, enabling the system to identify metabolic response rates that change over time. For example, high carbohydrate intake at night combined with poor sleep quality will lead to higher fasting blood glucose the next morning. This complex cross-time-period correlation is captured through the time encoding mechanism of the patient status subgraph. By aligning the above subgraph construction with semantic space, high-precision correlation inference between cross-dimensional factors can be achieved, enabling the systematic expression and quantitative modeling of the complex coupling relationship between diet, medication, and patient status. The construction of diet subgraph, drug subgraph, and patient status subgraph includes: By partitioning the feature vectors of dietary components into feature subspaces, carbohydrate structure, fat type, starch granule structure, amino acid composition, and dietary fiber type are respectively constructed as nutrient feature nodes in the dietary subgraph. Based on dietary data, the actual intake, intake frequency, and intake time distribution of each nutrient feature node within the target statistical period are calculated, and these actual intake, intake frequency, and intake time distribution are used as individual intake attributes for the corresponding nutrient feature nodes. Internal relationship edges within the dietary subgraph are established based on the similarity of nutritional features between different nutrient feature nodes, and the corresponding structural weights are determined according to the structural importance of each nutrient feature node. The individual intake attributes and structural weights of each nutrient feature node are combined as node attributes for the corresponding nodes in the dietary subgraph; specifically, the corresponding natural day is used as the target statistical period. The statistical period is calculated by sorting each dietary event within the target statistical period according to the intake time. For any nutrient feature node, the intake of the nutrient feature node generated by the dietary event is calculated based on the actual intake of the food corresponding to each dietary event and the corresponding nutrient content recorded in the food-nutrient database. The intake of each dietary event within the target statistical period is accumulated to obtain the actual intake of the nutrient feature node. The number of dietary events containing the corresponding nutrient feature is counted to obtain the intake frequency. The intake time series or time-segmented intake ratio of each dietary event within the target statistical period is formed as the intake time distribution. When different patients have the same nutrient feature node but different actual intake, intake frequency, or intake time, the corresponding nutrient feature node can form different individual intake attributes.

[0025] The nutritional structure features corresponding to each nutrient feature node are standardized and encoded to obtain a nutritional structure feature vector. The cosine similarity between different nutrient feature nodes is calculated. Nodes with cosine similarity reaching a preset similarity condition are used to establish internal relationship edges in the diet subgraph, and the corresponding cosine similarity is used as the initial connection strength of the internal relationship edges. The structural importance of each nutrient feature node is calculated based on the number of connections between each nutrient feature node and its adjacent nodes and the initial connection strength. The structural importance of the nodes is normalized to obtain structural weights. The structural weights are only used to characterize the relative importance of nutrient feature nodes in the nutritional knowledge structure within the diet subgraph and do not represent the patient's actual intake. The patient's actual dietary intake status is independently represented by individual intake attributes consisting of actual intake amount, intake frequency, and intake time distribution. The individual intake attributes and structural weights are encoded separately and then concatenated to obtain the node attributes of the corresponding nutrient feature nodes, so that the diet subgraph retains both relatively stable nutritional structure information and individual intake information that changes with the patient's diet.

[0026] Based on drug targets, enzymatic metabolic pathways, liver metabolic levels, and dose intensity from drug metabolism feature vectors, target nodes, metabolic nodes, and dose nodes are constructed in the drug subgraph. Directed metabolic pathways between nodes are established according to the drug action mechanism. Specifically, the acquired drug metabolism feature vectors are structurally parsed, and information on the drug's corresponding target, enzymatic pathways involved in metabolism, liver metabolic level parameters, and dosage intensity parameters are extracted from drug instructions and pharmacological databases. Drug targets are mapped to target nodes, metabolic enzymes involved in drug biotransformation and their metabolic stages are mapped to metabolic nodes, and dose intervals are divided into discrete dose levels to construct dose nodes. All nodes use vectors of a uniform dimension to ensure semantic consistency across subgraphs. Directed connections between nodes are established according to the drug action mechanism, where the connection from the dose node to the target node is... A dose-intensity edge is established at the target node to characterize the effect of dose changes on the degree of target activation. A target-metabolic trigger edge is established from the target node to the metabolic node to represent the biological pathway of drug action into the metabolic process. A directed metabolic cascade edge is established between metabolic nodes according to the phase I and phase II metabolism of the drug in the liver, and metabolic rate weights are assigned to the edges based on liver metabolic level parameters. Furthermore, by calculating the normalized values ​​of the parameters of each dimension in the drug metabolism feature vector, the dose intensity, enzyme activity contribution, and metabolic level are combined into edge weight coefficients to quantify the drug delivery efficiency in different metabolic pathways. This forms a drug subgraph structure that includes target nodes, metabolic nodes, dose nodes, and multiple types of directed metabolic pathways, enabling the drug action process to be expressed in a computable path form and providing an executable structured input for subsequent bidirectional graph neural network inference.

[0027] By performing time-series encoding on the patient state feature vector, the continuous blood glucose monitoring trend, exercise intensity change sequence, and sleep cycle rhythm are respectively constructed as nodes in the patient state subgraph. A time decay factor reflecting the metabolic response speed is generated for each node. Specifically, the time series corresponding to the continuous blood glucose monitoring trend, exercise intensity change sequence, and sleep cycle rhythm are aligned to a unified time scale, and the change rate and response delay features of each sequence are extracted. The metabolic response speed index of the corresponding node is calculated based on the change rate and response delay. The metabolic response speed index is mapped to the time decay function to obtain the time decay factor reflecting the metabolic response speed. State time sequence edges are established according to the order of the time windows to which each state node belongs, forming the patient state subgraph.

[0028] Candidate directed structures are formed based on candidate cross-subgraph relationships. The minimum description length corresponding to each candidate directed structure is calculated. The candidate directed structure whose minimum description length satisfies the optimal screening condition is selected as the target directed structure. The retention states and directions of diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges are determined according to the target directed structure. The edge weights are determined based on the goodness of fit and stability across the time window of the corresponding directed relationship. Specifically, for each candidate directed structure, the structural description length used to encode the candidate directed structure itself and the data description length used to encode the residual error of multivariate observation data under the conditions of the candidate directed structure are calculated, and the sum of the two is used as the minimum description length evaluation value of the candidate directed structure. The minimum description length evaluation values ​​of different candidate directed structures are compared and their... Candidate directed structures whose minimum description length meets the preset optimal screening criteria are identified as target directed structures. The optimal screening criteria can be set to have the minimum description length evaluation value and the lowest structural complexity. The retention status and direction of the corresponding cross-subgraph relation edges are determined based on the actual retained directed connections between nodes in the target directed structure. For each retained cross-subgraph relation edge, the goodness of fit is obtained based on the degree of fit of the directed relation to the change of the target variable. Structural learning is then re-executed in multiple consecutive time windows, and the proportion of time windows in which the corresponding directed relation maintains the same connection direction is counted to obtain the cross-time window stability. The goodness of fit and the cross-time window stability are normalized and then weighted to obtain the directed association confidence score, which is used as the edge weight of the corresponding cross-subgraph relation edge.

[0029] Based on graph embedding algorithms, unified feature embedding is performed on the node vectors of the diet subgraph, drug subgraph, and patient state subgraph to achieve semantic space alignment of nodes across subgraphs. The semantically aligned node embeddings, internal subgraph relationships, and filtered cross-subgraph relationships are then structurally integrated to construct a heterogeneous knowledge graph. Specifically, the initial feature vectors and adjacency information of each node in the diet, drug, and patient state subgraphs are extracted to construct heterogeneous graph structure data containing node type and edge type identifiers. A type encoding vector is introduced for each node according to its subgraph type, and the node's initial feature vector, type encoding vector, and neighborhood structure features are concatenated to form a unified node input representation. A relation type-aware graph embedding algorithm is used to perform multi-relation message passing on nodes in different subgraphs. Independent relation transformation matrices are set for diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges to achieve feature propagation and aggregation under different semantic relationships. The relation type-aware graph embedding algorithm is a relational graph convolutional network. The model employs either R-GCN (Relational-Generative Graph Network) or Heterogeneous Graph Attention Network (HAN). During message passing, node representations from different subgraphs are jointly trained by sharing embedding space parameters. This allows causally related cross-subgraph nodes to gradually converge to similar positions in the vector space, thus achieving cross-subgraph semantic space alignment. Specifically, when learning graph representations for diet, drug, and patient status subgraphs, independent embedding spaces are not constructed separately; instead, a unified low-dimensional semantic vector space is established, and node mapping functions and embedding update parameters are shared. In other words, the three types of subgraph nodes are input into the same graph embedding model. Through shared node encoding network parameters, feature transformation matrices, and aggregation functions, different subgraph nodes are jointly optimized during training based on cross-subgraph related edges. When a diet node is associated with a drug node or a patient node, the alignment is achieved. When state nodes have causal relationships, their embedding vectors gradually converge during backpropagation due to the constraints of a common loss function. This allows semantically related but different data from different sources to form comparable and inferable representations in a unified vector space, achieving semantic alignment of cross-dimensional knowledge and ensuring that subsequent graph neural networks can perform cross-subgraph information propagation and bidirectional reasoning. The updated node embedding vectors are normalized, and the node set and relation set are reorganized according to node type and edge relationship to generate node representation and relation representation in a unified vector space. The semantically aligned node embeddings and corresponding relation mappings are written into a heterogeneous knowledge graph database to form a heterogeneous knowledge graph structure containing multiple types of nodes, multiple relation edges, and a unified semantic representation, which is used for subsequent bidirectional graph neural network reasoning.The heterogeneous knowledge graph is a multi-layered relational network structure composed of multi-type node sets, multi-type relation edge sets, and a unified semantic embedding space. The node layer includes three heterogeneous node types: diet subgraph nodes, drug subgraph nodes, and patient state subgraph nodes. Diet subgraph nodes represent nutrient molecular-level entities such as carbohydrate structure, fat type, amino acid composition, starch structure, and dietary fiber characteristics, as well as their individual intake status. Drug subgraph nodes represent drug mechanism entities such as drug targets, enzymatic metabolic pathways, liver metabolic levels, and dosage intensity. Patient state subgraph nodes represent blood glucose trend nodes, exercise behavior nodes, and sleep rhythm nodes. The system consists of entities in dynamic metabolic states; the relation layer includes two types: intra-subgraph relations and cross-subgraph relations. Intra-subgraph relations describe structural or metabolic pathway associations between entities of the same type. Cross-subgraph relations include diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, used to characterize the causal coupling between nutrient intake, drug effects, and metabolic state. Each node and relation is mapped to a unified low-dimensional semantic embedding space, forming a heterogeneous network structure with multiple node types, multiple relation types, and cross-domain semantic alignment capabilities. This enables the knowledge graph to support cross-subgraph information propagation, causal reasoning, and bidirectional graph neural network-based diagnostic strategy generation.

[0030] By establishing a diet-drug synergistic response edge, the auxiliary diagnostic system can accurately characterize the impact of different food molecular structures on drug metabolism pathways based on the cross-attention association between dietary component feature vectors and drug metabolism feature vectors. This achieves a structural association between nutrient molecular characteristics and drug metabolism mechanisms, enabling the identification of implicit synergistic effects such as high-fat diets reducing drug absorption efficiency or high-GI carbohydrates enhancing insulin resistance. This provides data-driven, mechanism-level support for drug dosage adjustment and medication regimen optimization. Furthermore, by constructing a diet-glucose response edge, the causal influence between dietary intake and blood glucose fluctuations can be expressed in a graph structure, effectively revealing the effects of different nutrients on short-term blood glucose levels. The study examines the role of key indicators such as peak blood glucose, peak delay time, and recovery time, and further demonstrates their impact on long-term blood glucose stability. The drug metabolism pathway edge reflects the dynamic effects of drugs on patients' insulin sensitivity, hepatic glucose output, and glucose uptake. A behavioral regulation edge is constructed to link patient behavioral factors such as exercise intensity and sleep quality with diet and drug subgraphs, structurally expressing the regulatory role of behavioral factors in the diet-drug synergistic effect. This allows the model to make inferences and judgments that more closely approximate real physiological laws by comprehensively considering behavioral influences. The model establishes diet-drug synergistic response edges, diet-blood glucose response edges, drug-state response edges, and behavioral regulation edges, including: Based on the cross-feature attention matrix of dietary component feature vectors and drug metabolism feature vectors, candidate dietary-drug synergistic response edges are constructed between the dietary subgraph and the drug subgraph to characterize the synergistic association between nutrient component features and drug metabolism features. Specifically, the node features corresponding to each nutrient component feature node in the dietary subgraph are mapped to the node features corresponding to the target node, metabolism node, and dosage node in the drug subgraph to the same dimension feature space. The feature matching degree between each nutrient component feature node and each drug node is calculated, and the feature matching degree of all corresponding to the same drug node is normalized to obtain the cross-attention weight of the corresponding nutrient component feature node to the drug node. The cross-feature attention matrix is ​​composed of the cross-attention weights between all nutrient component feature nodes and all drug nodes. Based on the patient's blood glucose monitoring data, the blood glucose change curve after food intake is fitted, and candidate food-blood glucose response edges are constructed between the food subgraph and the patient status subgraph to characterize the response correlation of different nutrient features to blood glucose changes after intake. Specifically, the blood glucose response analysis window is determined according to the time of the food event, and the candidate response intensity between nutrient features and blood glucose status is determined according to the peak change, peak delay and fall process of blood glucose relative to the pre-intake baseline blood glucose within the blood glucose response analysis window. Based on drug targets, metabolic enzyme pathways and dose intensity, candidate drug-state response edges are constructed between the drug subgraph and the patient state subgraph to characterize the association between drug action and drug metabolism state and patient blood glucose state and metabolic response state. Based on the correlation between patient behavioral characteristics and metabolic regulation capacity, candidate behavioral regulation edges are constructed between the patient state subgraph and the diet and drug subgraphs to characterize the regulatory effect of behavioral factors on the diet-glucose response relationship and the drug-state response relationship. Based on causal structure learning, candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are screened and oriented. Candidate relations that meet the temporal order constraint and directed structure screening conditions are retained as the corresponding diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges, and the weights of the corresponding edges are determined. Specifically, the above-mentioned candidate cross-subgraph relations are subjected to directed structure screening, and candidate relations that meet the temporal order constraint, conditional independence test, and minimum description length screening results are retained as the final cross-subgraph relation edges in the heterogeneous knowledge graph, and the edge weights are determined according to the corresponding directed association confidence.

[0031] By introducing a dynamic update mechanism for heterogeneous knowledge graphs, this invention enables the individualized dynamic information in the constructed diet subgraph, drug subgraph, and patient state subgraph to evolve synchronously with the patient's real-time metabolic state. Through a time decay factor, the weights of subgraph nodes are dynamically decayed, allowing old information to gradually fade out and new behavioral patterns to be promptly enhanced. This achieves a temporally adaptive expression of the knowledge graph, ensuring that the knowledge structure better conforms to real physiological laws. The knowledge graph construction module can also execute the dynamic update mechanism for heterogeneous knowledge graphs, including: Based on changes in patients’ diet data, hypoglycemic drug data, and blood glucose monitoring data, a time decay factor is used to decay and update the node weights in the diet subgraph, drug subgraph, and patient status subgraph. This study uses a Bayesian structural learning model to detect whether the diet-glucose response relationship and the drug-state response relationship have drifted. It then performs edge weight re-estimation on significantly drifted edges. Specifically, dietary data, hypoglycemic drug data, and blood glucose monitoring data collected from patients at different time periods are divided into multiple time windows, and a corresponding Bayesian network structure is constructed within each time window. By comparing the changes in edge connections and conditional probability distributions of the Bayesian network structures in adjacent time windows, a structural difference measure is calculated between the diet-glucose response relationship and the drug-state response relationship. This structural difference measure is compared with a preset drift threshold; when the structural difference measure exceeds the threshold, the corresponding relationship is determined to have drifted significantly. For significantly drifted edges, the conditional probability strength is recalculated based on the Bayesian network parameters in the latest time window, and the normalized conditional probability strength is used as the updated weight of the corresponding edge, thus achieving dynamic adjustment of edge weights in the knowledge graph.

[0032] By using a graph incremental learning network based on a gated update strategy, newly added nodes and edges are embedded into a unified vector space of a heterogeneous knowledge graph while maintaining semantic consistency of the subgraph. Specifically, the node attributes and neighborhood relationships of newly added nodes are input into a node encoding network that is the same as the original heterogeneous knowledge graph. The fusion ratio between historical node representations and new messages is controlled by the gating coefficient, so that newly added nodes and edges can complete incremental updates without retraining the entire graph structure. In the process of updating heterogeneous knowledge graphs, a graph conflict detection mechanism is used to perform minimum conflict adjustment on the conflict weights of diet-drug synergistic response edges and behavior regulation edges. Specifically, when two types of relations act on the same target node and their corresponding directions of action are opposite, they are identified as candidate conflict relations. The directed association confidence of the two relations is compared. The original edge weights of the relations with higher directed association confidence are retained, while the edge weights of the relations with lower directed association confidence are reduced. This ensures that the information of the two observation factors is still preserved after the conflict relations are adjusted, while reducing the interference of low-confidence relations on subsequent message propagation. For relations with lower directed association confidence, the weight decay ratio is determined based on the difference in confidence between the two conflict relations. The larger the confidence difference, the greater the weight decay of the low-confidence relation. After adjustment, the synthetic message of the two relations to the target node is recalculated. When the direction of action of the synthetic message is consistent with that of the high-confidence relation and the edge weight of the low-confidence relation is greater than zero, the minimum conflict adjustment is completed. This avoids directly deleting the low-confidence relation and reduces the interference of conflict relations on subsequent graph neural network message propagation while maintaining the original observation information. Based on changes in patients' long-term metabolic trends, a topology update is performed on the node structure of the diet and drug subgraphs. The topology update includes node aggregation, node splitting, and weakly correlated node cleaning. Specifically, the patient status scores, diet-glucose response edge weights, and drug-status response edge weights for multiple consecutive target statistical periods are arranged in chronological order to form the patient's long-term metabolic trend. For multiple nutrient feature nodes in the diet subgraph that have similar individual intake attributes, similar glucose response directions, and node embedding similarity that are consistently higher than the preset aggregation conditions, they are identified as candidate aggregation nodes. The node attributes of the candidate aggregation nodes are weighted and combined according to their respective structural weights to form aggregation nodes, while inheriting the effective relationship edges between each candidate aggregation node and external nodes.

[0033] In this embodiment of the invention, the diagnosis and treatment strategy generation module 250 is used to perform bidirectional graph neural network reasoning based on heterogeneous knowledge graph and generate auxiliary diagnosis and treatment strategies based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of the patient's blood glucose in the future, drug dosage adaptation suggestions, and dietary structure optimization plans. By performing bidirectional graph neural network reasoning on a heterogeneous knowledge graph, this method achieves bidirectional collaborative modeling and causal correlation mining between diet, medication, and patient metabolic state. Forward message passing is used to simulate the impact of nutrient structure and individual intake status in the diet subgraph on the state of nodes in the medication subgraph, while reverse message passing is used to infer the limiting effect of drug sensitivity on food molecules. This allows the model to capture the complex synergistic effects between diet and medication. Furthermore, it generates auxiliary treatment strategies by multi-objective trade-offs between dynamic blood glucose prediction, dosage adaptation suggestions, and dietary structure plans. This achieves an intelligent balance between controlling blood glucose stability, reducing medication burden, and optimizing dietary behavior, improving patient compliance while enhancing the overall decision-making quality of the auxiliary treatment system. The bidirectional graph neural network reasoning based on the heterogeneous knowledge graph includes: Forward message passing is performed from the diet subgraph to the drug subgraph. The state representations of drug target nodes, metabolism nodes, and dosage nodes are updated through graph convolution to simulate the changing trends of drug metabolism effects in patients under current dietary structure and individual intake status. Specifically, the individual intake attributes and structural weights of each nutrient feature node in the diet subgraph are used as node inputs. The messages of adjacent diet nodes are weighted and aggregated according to the edge weights of the diet-drug synergistic response edges. The aggregation result is then fused with the original state of the drug node to obtain the updated state of the drug node under the influence of the current dietary structure and actual intake status. The updated drug state is then propagated to the patient state subgraph through the drug-state response edge. The algorithm performs reverse message passing from the drug subgraph to the diet subgraph. It uses drug sensitivity gradients and drug metabolism pathway weights to infer the influence strength of each nutrient feature node, determining the restricted food categories and their corresponding intake risk levels. Specifically, the aggregated state representation of the patient state subgraph is input into the blood glucose prediction layer, outputting a blood glucose prediction vector for the patient's future time period. This vector includes predicted blood glucose values ​​for multiple future prediction times. During the reverse inference process, the target is determined based on the deviation between the predicted blood glucose vector and the target blood glucose state. The degree of change in the prediction deviation relative to the state representation of each nutrient feature node is calculated using backpropagation in a bidirectional graph neural network. This degree of change is combined with the edge weights of diet-blood glucose response edges, diet-drug synergistic response edges, and related drug-state response edges to obtain the influence strength of each nutrient feature node on the blood glucose prediction deviation. Then, combined with the current actual intake and frequency of the corresponding node, nutrients with high influence and significant current actual intake contribution are ranked by risk. Based on this risk ranking, the restricted food categories and their corresponding intake risk levels are determined. By integrating the node update results from forward and backward reasoning, cross-subgraph aggregation operations are performed on the patient state subgraph to generate a prediction vector representing the dynamic changes in blood glucose in future time periods and a state score representing metabolic regulation capacity.

[0034] A drug dosage adaptation model is constructed based on patient status feature vectors and blood glucose prediction vectors. Individualized dosage adjustment suggestions are output based on drug metabolism characteristics, physiological metabolic sensitivity, and dietary synergistic effects. Specifically, the patient status feature vector and blood glucose prediction vector are aligned and standardized in the time dimension to construct a joint input feature reflecting the patient's current metabolic capacity and future blood glucose change trends. Based on the joint input feature, the patient's insulin sensitivity index, blood glucose fluctuation amplitude index, and metabolic stability index are extracted. A set of dosage influencing factors is established by combining the drug effect intensity, half-life parameter, and liver metabolic level from the drug metabolism feature vector. On this basis, a drug dosage response function is constructed, using drug dosage as an adjustable variable and blood glucose prediction deviation as an optimization objective. A regression model is used to learn the mapping relationship between dosage changes and blood glucose control effects. Furthermore, safety constraints are introduced to limit the hypoglycemia risk threshold, dosage change amplitude, and the patient's historical tolerance range, forming a constrained drug dosage adaptation model. Based on the drug dosage adaptation model, the optimal dosage adjustment value that makes the predicted blood glucose curve tend towards the target blood glucose range is calculated, and corresponding individualized dosage adjustment suggestions are output. Based on the edge weight changes of the nutrient feature nodes in the diet subgraph and the restricted food categories and corresponding intake risk levels obtained through back reasoning, a diet structure optimization plan is generated. The diet structure plan includes recommended nutrient ratios, sensitive food substitution strategies, and individualized food tolerance suggestions. The system weighs multiple objectives, including dynamic blood glucose prediction results, medication dosage recommendations, and dietary optimization plans, and outputs auxiliary treatment strategies.

[0035] Please see Figure 2 , Figure 2 This is a schematic diagram of the overall process of the knowledge graph-based auxiliary diagnosis and treatment method for diabetes provided in this embodiment of the invention, which specifically includes the following steps: S100. Obtain the patient's dietary data and break down the components of the ingested food to construct a dietary component feature vector; S200: Obtain data on the patient's current hypoglycemic drugs and construct a drug metabolism feature vector based on the drug action mechanism; S300: Acquire patients' blood glucose monitoring data, exercise behavior data, and sleep quality data, and construct a patient state feature vector that characterizes the patient's metabolic response ability; S400. Construct a heterogeneous knowledge graph based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. The specific execution steps include: Based on the patient's dietary component feature vector, drug metabolism feature vector, and patient state feature vector, respectively construct a dietary subgraph, a drug subgraph, and a patient state subgraph; Candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are constructed between the diet subgraph, drug subgraph, and patient state subgraph. Structural screening and orientation are performed on each candidate cross-subgraph relationship to obtain diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges. By structurally integrating diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, a heterogeneous knowledge graph containing diet subgraphs, drug subgraphs, and patient state subgraphs is constructed, providing a knowledge structure foundation for bidirectional graph neural network reasoning.

[0036] The construction of diet subgraphs, medication subgraphs, and patient status subgraphs includes: By partitioning the feature vectors of dietary components into feature subspaces, carbohydrate structure, fat type, starch granule structure, amino acid composition, and dietary fiber type are respectively constructed as nutrient feature nodes in the dietary subgraph. Based on dietary data, the actual intake, intake frequency, and intake time distribution of each nutrient feature node within the target statistical period are calculated, and these are used as individual intake attributes for the corresponding nutrient feature nodes. Internal relationship edges within the dietary subgraph are established based on the similarity of nutritional features between different nutrient feature nodes, and the corresponding structural weights are determined according to the structural importance of each nutrient feature node. The individual intake attributes and structural weights of each nutrient feature node are combined as the node attributes of the corresponding nodes in the dietary subgraph. Based on the drug target, enzymatic metabolic pathway, liver metabolic level and dose intensity in the drug metabolism feature vector, target nodes, metabolic nodes and dose nodes in the drug subgraph are constructed, and directed metabolic pathways between nodes are established according to the drug action mechanism. By performing time-series encoding on the patient state feature vector, the continuous blood glucose monitoring trend, the exercise intensity change sequence and the sleep cycle rhythm are respectively constructed as nodes in the patient state subgraph, and a time decay factor reflecting the metabolic response speed is generated for each node.

[0037] Candidate directed structures are formed based on candidate cross-subgraph relationships. The minimum description length corresponding to each candidate directed structure is calculated. The candidate directed structure whose minimum description length satisfies the optimal screening condition is selected as the target directed structure. The retention state and direction of diet-drug synergistic response edge, diet-glucose response edge, drug-state response edge and behavior regulation edge are determined according to the target directed structure. The edge weights are determined according to the goodness of fit of the corresponding directed relationship and the stability across the time window. Based on graph embedding algorithms, unified feature embedding is performed on the node vectors of diet subgraph, drug subgraph and patient state subgraph to achieve semantic space alignment of nodes across subgraphs. The semantic space aligned node embeddings, internal subgraph relations and filtered cross-subgraph relations are then structurally integrated to construct a heterogeneous knowledge graph.

[0038] This includes establishing diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, including: Based on the cross-feature attention matrix of dietary component feature vectors and drug metabolism feature vectors, candidate dietary-drug synergistic response edges are constructed between dietary subgraphs and drug subgraphs to characterize the synergistic association between nutritional component features and drug metabolism features. Based on the patient's blood glucose monitoring data, the blood glucose change curve after food intake is fitted, and candidate food-blood glucose response edges are constructed between the food subgraph and the patient state subgraph to characterize the response correlation of different nutrient features to blood glucose changes after intake. Based on drug targets, metabolic enzyme pathways and dose intensity, candidate drug-state response edges are constructed between the drug subgraph and the patient state subgraph to characterize the association between drug action and drug metabolism state and patient blood glucose state and metabolic response state. Based on the correlation between patient behavioral characteristics and metabolic regulation capacity, candidate behavioral regulation edges are constructed between the patient state subgraph and the diet and drug subgraphs to characterize the regulatory effect of behavioral factors on the diet-glucose response relationship and the drug-state response relationship. Based on causal structure learning, candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are screened and oriented. Candidate relations that meet the temporal order constraint and directed structure screening conditions are retained as the corresponding diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges, and the weights of the corresponding edges are determined.

[0039] The dynamic update mechanism of heterogeneous knowledge graphs includes: Based on changes in patients’ diet data, hypoglycemic drug data, and blood glucose monitoring data, a time decay factor is used to decay and update the node weights in the diet subgraph, drug subgraph, and patient status subgraph. The model uses a Bayesian structural learning model to detect whether the diet-glucose response relationship and the drug-state response relationship have drifted, and performs edge weight re-estimation on the significantly drifted associated edges. By using a graph incremental learning network based on a gated update strategy, newly added nodes and edges are embedded into the unified vector space of heterogeneous knowledge graphs while maintaining the semantic consistency of subgraphs. In the process of updating heterogeneous knowledge graphs, a graph conflict detection mechanism is used to perform minimum conflict adjustment on the conflict weights of diet-drug synergistic response edges and behavior regulation edges; Based on changes in patients' long-term metabolic trends, a topology update is performed on the node structure of the diet and drug subgraphs. The topology update includes node aggregation, node splitting, and cleaning up weakly correlated nodes.

[0040] S500 performs bidirectional graph neural network reasoning based on heterogeneous knowledge graphs and generates auxiliary diagnosis and treatment strategies based on the bidirectional reasoning results. These strategies include dynamic prediction of the patient's blood glucose levels for future periods, medication dosage recommendations, and dietary optimization plans. Forward message passing is performed from the diet subgraph to the drug subgraph. The state representation of drug target nodes, metabolism nodes and dose nodes is updated through graph convolution to simulate the changing trend of drug metabolism effect in patients under the current diet structure and individual intake state. Based on the drug subgraph, reverse message passing is performed to the diet subgraph. The influence strength of each nutrient feature node is inferred by the drug sensitivity gradient and drug metabolism pathway weight, and the restricted food categories and the corresponding intake risk levels of the restricted food categories are determined. By integrating the node update results of forward and backward reasoning, cross-subgraph aggregation operation is performed on the patient state subgraph to generate a prediction vector representing the dynamic changes in blood glucose in future time periods and a state score representing the metabolic regulation ability. A drug dosage adaptation model is constructed based on patient status feature vectors and blood glucose prediction vectors, and individualized dosage adjustment suggestions are output based on drug metabolism characteristics, physiological metabolic sensitivity and dietary synergistic effects. Based on the edge weight changes of the nutrient feature nodes in the diet subgraph and the restricted food categories and corresponding intake risk levels obtained through back reasoning, a diet structure optimization plan is generated. The diet structure plan includes recommended nutrient ratios, sensitive food substitution strategies, and individualized food tolerance suggestions. The system weighs multiple objectives, including dynamic blood glucose prediction results, medication dosage recommendations, and dietary optimization plans, and outputs auxiliary treatment strategies.

[0041] The parameters and steps in the knowledge graph-based auxiliary diagnosis and treatment method for diabetes of the present invention described above can be referred to the parameters and steps of each unit module in the embodiments of the knowledge graph-based auxiliary diagnosis and treatment system for diabetes of the above-described invention to realize the corresponding functions, and will not be repeated here.

[0042] Please refer to Figure 3The embodiments of the present invention also provide an electronic device 300, including a memory 320 for storing a computer program 322; and a processor 310 for executing the computer program 322 to implement a knowledge graph-based auxiliary diagnosis and treatment method for diabetes as described in any of the above embodiments.

[0043] It should be noted that... Figure 3 This is a structural diagram of an electronic device 300 according to an exemplary embodiment. The content of the diagram should not be construed as limiting the scope of the invention.

[0044] Specifically, the electronic device 300 may include at least one processor 310, at least one memory 320, a power supply 330, a communication interface 340, an input / output interface 350, and a communication bus 360. The memory 320 stores a computer program 322, which is loaded and executed by the processor 310 to implement relevant steps in the knowledge graph-based auxiliary diagnosis and treatment method for diabetes disclosed in any of the foregoing embodiments. Alternatively, the electronic device 300 in the embodiments of the present invention may specifically be an electronic computer.

[0045] In embodiments of the present invention, the power supply 330 is used to provide operating voltage for each hardware device on the electronic device 300; the communication interface 340 can create a data transmission channel between the electronic device 300 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of the present invention, and is not specifically limited here; the input / output interface 350 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0046] In addition, the memory 320, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon can include operating system 321, computer program 322, etc., and the storage method can be temporary storage or permanent storage.

[0047] The operating system 321 is used to manage and control the various hardware devices and computer programs on the electronic device 300, and may be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program 322 capable of performing a knowledge graph-based auxiliary diagnosis and treatment method for diabetes disease executed by the electronic device 300 as disclosed in any of the foregoing embodiments, the computer program 322 may further include a computer program 322 capable of performing other specific tasks.

[0048] Embodiments of the present invention also provide a computer-readable storage medium for storing a computer program 322, which, when executed by a processor 310, implements a knowledge graph-based auxiliary diagnosis and treatment method for diabetes as described in any of the above embodiments.

[0049] For example, computer-readable storage media can be read-only memory (ROM), random access memory (RAM), compact disc read-only memory (CD-ROM), magnetic tape, floppy disk, and optical data storage devices.

[0050] The terms “comprising,” “including,” or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

[0051] The above description is merely a preferred embodiment of the present invention and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this application is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the foregoing concept. For example, technical solutions formed by substituting the above-described features with (but not limited to) technical features with similar functions claimed in this invention.

Claims

1. A knowledge graph-based auxiliary diagnosis and treatment system for diabetes, characterized in that, It includes modules for acquiring dietary data, acquiring drug data, monitoring patient status, constructing a knowledge graph, and generating treatment strategies. The dietary data acquisition module is used to acquire the patient's dietary data and break down the components of the ingested food to construct a dietary component feature vector. The drug data acquisition module is used to acquire data on the hypoglycemic drugs currently used by the patient and to construct a drug metabolism feature vector based on the drug action mechanism. The patient status monitoring module is used to acquire the patient's blood glucose monitoring data, exercise behavior data, and sleep quality data, and to construct a patient status feature vector that characterizes the patient's metabolic response ability. The knowledge graph construction module is used to construct a heterogeneous knowledge graph based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. The diagnosis and treatment strategy generation module is used to perform bidirectional graph neural network reasoning based on heterogeneous knowledge graphs and generate auxiliary diagnosis and treatment strategies based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of the patient's blood glucose in the future, drug dosage adaptation suggestions, and dietary structure optimization plans.

2. The knowledge graph-based auxiliary diagnosis and treatment system for diabetes as described in claim 1, characterized in that, The specific execution steps of the knowledge graph construction module include: Based on the patient's dietary component feature vector, drug metabolism feature vector, and patient state feature vector, respectively construct a dietary subgraph, a drug subgraph, and a patient state subgraph; Candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are constructed between the diet subgraph, drug subgraph, and patient state subgraph. Structural screening and orientation are performed on each candidate cross-subgraph relationship to obtain diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges. By structurally integrating diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavioral regulation edges, a heterogeneous knowledge graph containing diet subgraphs, drug subgraphs, and patient state subgraphs is constructed, providing a knowledge structure foundation for bidirectional graph neural network reasoning.

3. The knowledge graph-based auxiliary diagnosis and treatment system for diabetes as described in claim 2, characterized in that, The construction of the diet subgraph, drug subgraph, and patient status subgraph includes: By partitioning the feature vectors of dietary components into feature subspaces, carbohydrate structure, fat type, starch granule structure, amino acid composition, and dietary fiber type are respectively constructed as nutrient feature nodes in the dietary subgraph. Based on dietary data, the actual intake, intake frequency, and intake time distribution of each nutrient feature node within the target statistical period are calculated, and these are used as individual intake attributes for the corresponding nutrient feature nodes. Internal relationship edges within the dietary subgraph are established based on the similarity of nutritional features between different nutrient feature nodes, and the corresponding structural weights are determined according to the structural importance of each nutrient feature node. The individual intake attributes and structural weights of each nutrient feature node are combined as the node attributes of the corresponding nodes in the dietary subgraph. Based on the drug target, enzymatic metabolic pathway, liver metabolic level and dose intensity in the drug metabolism feature vector, target nodes, metabolic nodes and dose nodes in the drug subgraph are constructed, and directed metabolic pathways between nodes are established according to the drug action mechanism. By performing time-series encoding on the patient state feature vector, the continuous blood glucose monitoring trend, the exercise intensity change sequence, and the sleep cycle rhythm are respectively constructed as nodes in the patient state subgraph. A time decay factor reflecting the metabolic response speed is generated for each node, and state time sequence edges are established according to the time sequence relationship of the time windows corresponding to each state. Candidate directed structures are formed based on candidate cross-subgraph relationships. The minimum description length corresponding to each candidate directed structure is calculated. The candidate directed structure whose minimum description length satisfies the optimal screening condition is selected as the target directed structure. The retention state and direction of diet-drug synergistic response edge, diet-glucose response edge, drug-state response edge and behavior regulation edge are determined according to the target directed structure. The edge weights are determined according to the goodness of fit of the corresponding directed relationship and the stability across the time window. Based on graph embedding algorithms, unified feature embedding is performed on the node vectors of diet subgraph, drug subgraph and patient state subgraph to achieve semantic space alignment of nodes across subgraphs. The semantic space aligned node embeddings, internal subgraph relations and filtered cross-subgraph relations are then structurally integrated to construct a heterogeneous knowledge graph.

4. The knowledge graph-based auxiliary diagnosis and treatment system for diabetes according to claim 3, characterized in that, The construction of candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavioral regulation edges includes: Based on the cross-feature attention matrix of dietary component feature vectors and drug metabolism feature vectors, candidate dietary-drug synergistic response edges are constructed between dietary subgraphs and drug subgraphs to characterize the synergistic association between nutritional component features and drug metabolism features. Based on the patient's blood glucose monitoring data, the blood glucose change curve after food intake is fitted, and candidate food-blood glucose response edges are constructed between the food subgraph and the patient state subgraph to characterize the response correlation of different nutrient features to blood glucose changes after intake. Based on drug targets, metabolic enzyme pathways and dose intensity, candidate drug-state response edges are constructed between the drug subgraph and the patient state subgraph to characterize the association between drug action and drug metabolism state and patient blood glucose state and metabolic response state. Based on the correlation between patient behavioral characteristics and metabolic regulation capacity, candidate behavioral regulation edges are constructed between the patient state subgraph and the diet and drug subgraphs to characterize the regulatory effect of behavioral factors on the diet-glucose response relationship and the drug-state response relationship. Based on causal structure learning, candidate diet-drug synergistic response edges, candidate diet-glucose response edges, candidate drug-state response edges, and candidate behavior regulation edges are screened and oriented. Candidate relations that meet the temporal order constraint and directed structure screening conditions are retained as the corresponding diet-drug synergistic response edges, diet-glucose response edges, drug-state response edges, and behavior regulation edges, and the weights of the corresponding edges are determined.

5. The knowledge graph-based auxiliary diagnosis and treatment system for diabetes according to claim 4, characterized in that, The knowledge graph construction module can also execute a dynamic update mechanism for heterogeneous knowledge graphs, including: Based on changes in patients’ diet data, hypoglycemic drug data, and blood glucose monitoring data, a time decay factor is used to decay and update the node weights in the diet subgraph, drug subgraph, and patient status subgraph. The model uses a Bayesian structural learning model to detect whether the diet-glucose response relationship and the drug-state response relationship have drifted, and performs edge weight re-estimation on the significantly drifted associated edges. By using a graph incremental learning network based on a gated update strategy, newly added nodes and edges are embedded into the unified vector space of heterogeneous knowledge graphs while maintaining the semantic consistency of subgraphs. In the process of updating heterogeneous knowledge graphs, a graph conflict detection mechanism is used to perform minimum conflict adjustment on the conflict weights of diet-drug synergistic response edges and behavior regulation edges; Based on changes in patients' long-term metabolic trends, a topology update is performed on the node structure of the diet and drug subgraphs. The topology update includes node aggregation, node splitting, and cleaning up weakly correlated nodes.

6. The knowledge graph-based auxiliary diagnosis and treatment system for diabetes according to claim 1, characterized in that, The method of performing bidirectional graph neural network reasoning based on heterogeneous knowledge graphs includes: Forward message passing is performed from the diet subgraph to the drug subgraph. The state representation of drug target nodes, metabolism nodes and dose nodes is updated through graph convolution to simulate the changing trend of drug metabolism effect in patients under the current diet structure and individual intake state. Based on the drug subgraph, reverse message passing is performed to the diet subgraph. The influence strength of each nutrient feature node is inferred by the drug sensitivity gradient and drug metabolism pathway weight, and the restricted food categories and the corresponding intake risk levels of the restricted food categories are determined. By integrating the node update results of forward and backward reasoning, cross-subgraph aggregation operation is performed on the patient state subgraph to generate a prediction vector representing the dynamic changes in blood glucose in future time periods and a state score representing the metabolic regulation ability. A drug dosage adaptation model is constructed based on patient status feature vectors and blood glucose prediction vectors, and individualized dosage adjustment suggestions are output based on drug metabolism characteristics, physiological metabolic sensitivity and dietary synergistic effects. Based on the edge weight changes of the nutrient feature nodes in the diet subgraph and the restricted food categories and corresponding intake risk levels obtained through back reasoning, a diet structure optimization plan is generated. The diet structure plan includes recommended nutrient ratios, sensitive food substitution strategies, and individualized food tolerance suggestions. The system weighs multiple objectives, including dynamic blood glucose prediction results, medication dosage recommendations, and dietary optimization plans, and outputs auxiliary treatment strategies.

7. A knowledge graph-based auxiliary diagnosis and treatment method for diabetes, applied to any one of the knowledge graph-based auxiliary diagnosis and treatment systems for diabetes as described in claims 1-6, characterized in that, The method includes: Acquire patients' dietary data and break down the components of ingested food to construct dietary component feature vectors; Acquire data on the patient's current hypoglycemic medications and construct a drug metabolism feature vector based on the drug action mechanism; Acquire patients’ blood glucose monitoring data, exercise behavior data, and sleep quality data, and construct a patient state feature vector that characterizes patients’ metabolic response capabilities; A heterogeneous knowledge graph is constructed based on dietary component feature vectors, drug metabolism feature vectors, and patient state feature vectors. The heterogeneous knowledge graph includes a dietary subgraph, a drug subgraph, and a patient state subgraph. Based on heterogeneous knowledge graphs, bidirectional graph neural network reasoning is performed, and auxiliary diagnosis and treatment strategies are generated based on the bidirectional reasoning results. The auxiliary diagnosis and treatment strategies include dynamic prediction of patients' blood glucose in future time periods, drug dosage adaptation suggestions, and dietary structure optimization plans.

8. An electronic device, comprising: A processor and a memory, wherein the memory stores a computer program that can be called by the processor; characterized in that the processor executes the knowledge graph-based auxiliary diagnosis and treatment method for diabetes as described in claim 7 by calling the computer program stored in the memory.

9. A computer-readable storage medium, characterized in that, The system stores instructions that, when executed on a computer, cause the computer to perform the knowledge graph-based auxiliary diagnosis and treatment method for diabetes as described in claim 7.

Citation Information

Patent Citations

  • Blood glucose value prediction and alarm method based on follow-up visit record of diabetic patient

    CN117095828A