Infectious disease monitoring and early warning method and system based on large language model and knowledge graph
Patent Information
- Application Number
- CN202610864371.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-16
- Publication Date
- 2026-08-21
- Estimated Expiration
- 2046-06-16
AI Technical Summary
[0008]为克服上述现有技术的不足,本发明提供了一种基于大语言模型与知识图谱的传染病监测预警方法及系统,旨在解决口岸场景下多源数据孤岛、专家认知超载及自动化管控能力不足的问题
(1)本发明通过动态时间滞后掩码机制与跨模态注意力融合模型,将文本、数值、轨迹、传感等多类型数据统一映射至同一特征空间,有效解决传统系统中数据割裂、模态不匹配、传播时序错位等问题。依托流行病学潜伏期先验知识约束,过滤无效噪声、保留真实因果关联,显著提升数据利用率与早期异常信号检出能力,为精准监测提供高质量、高可信的融合特征基础,大幅降低因数据碎片化导致的漏检、误检风险。
Smart Images

Figure CN122417461B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of public health monitoring, artificial intelligence and big data interdisciplinary technology, and in particular relates to an infectious disease monitoring and early warning method and system based on large language models and knowledge graphs. Background Technology
[0002] The statements in this section are merely background information related to the present invention and do not necessarily constitute prior art.
[0003] With the continuous increase in global cross-border population movement, international trade and logistics, cold chain transportation, and wildlife habitat changes, ports and cross-border flow areas have become important sites for the importation, spread, and early interception of infectious diseases. These scenarios typically involve multiple types of data, including abnormal human health, animal activity, logistics routes, environmental exposure, and pathogen detection. Their transmission processes are characterized by multi-agent participation, multi-pathway coupling, multi-scale spatiotemporal evolution, and the concealment of early signals. Especially for zoonotic diseases, emerging and re-emerging infectious diseases, and cross-border imported infectious diseases, relying solely on clinical case reports or fixed-disease surveillance often fails to identify potential transmission chains between pathogens and animal hosts, environmental media, logistics carriers, and human communities in a timely manner.
[0004] Existing infectious disease surveillance and early warning systems primarily rely on case reports, laboratory test results, or information from single public health events for data source, using fixed thresholds, manual rules, or static statistical models for anomaly identification. While these methods have some application value under conditions of known pathogens, single scenarios, and relatively complete data, they still have significant shortcomings in complex port scenarios. On the one hand, data from customs logistics, ecological monitoring, clinical syndromes, pathogen omics, and multilingual open-source intelligence are scattered across different systems, with significant differences in data format, temporal granularity, spatial labels, and semantic expression, making direct unified modeling and collaborative analysis difficult. On the other hand, existing models often fail to fully utilize prior epidemiological knowledge such as disease incubation periods, exposure windows, logistics delays, and host activity cycles, easily misjudging accidental co-occurrence signals that do not conform to the transmission timeline as risk associations, or overlooking real but time-delayed hidden transmission clues.
[0005] Furthermore, traditional monitoring and early warning methods often employ fixed threshold triggering mechanisms based on region, disease type, or number of cases, lacking the ability to adaptively characterize the dynamic relationships between population movement, overlapping animal habitats, changes in logistics routes, environmental exposure, and abnormal clinical signals. For cross-regional, cross-species, and cross-modal transmission risks, existing systems often can only perform local anomaly detection within a single data source, making it difficult to form a unified knowledge structure that expresses entities, relationships, time, space, and the confidence level of evidence. It is also difficult to forward extrapolate potential transmission paths, risk diffusion trends, and intervention effects.
[0006] With the development of large language models, knowledge graphs, graph neural networks, and multimodal learning technologies, transforming multi-source heterogeneous public health data into computable, reasonable, and interpretable spatiotemporal relational networks has become an important direction for improving infectious disease monitoring and early warning capabilities. However, current technologies still lack a complete technical solution that can simultaneously achieve multimodal data temporal alignment, epidemiological prior constraints, spatiotemporal knowledge graph construction, dynamic graph risk extrapolation, and intelligent response suggestion generation in port scenarios. Especially when facing low-quality, high-missing, cross-language, cross-system, and cross-scale data, how to reduce invalid noise associations, enhance the interpretability of transmission timelines, and improve the timeliness and traceability of risk warnings remains an urgent technical problem to be solved.
[0007] Therefore, it is necessary to provide a method and system for infectious disease monitoring and early warning based on large language models and knowledge graphs. By introducing dynamic time lag masking mechanism, cross-modal attention fusion, port spatiotemporal knowledge graph, metapopulation graph transformation neural network and multi-agent counterfactual inference mechanism, a closed-loop monitoring and early warning system can be realized from multi-source data perception, risk association modeling, transmission trend inference to the generation of structured treatment suggestions. Summary of the Invention
[0008] To overcome the shortcomings of the existing technologies, this invention provides a method and system for infectious disease monitoring and early warning based on large language models and knowledge graphs, aiming to solve the problems of multi-source data silos, expert cognitive overload, and insufficient automated management capabilities in port scenarios.
[0009] To achieve the above objectives, one or more embodiments of the present invention provide the following technical solutions: The first aspect of this invention provides a method for infectious disease monitoring and early warning based on a large language model and knowledge graph; Infectious disease monitoring and early warning methods based on large language models and knowledge graphs include: Acquire ubiquitous sensing data at ports of entry; A dynamic time lag mask matrix that integrates prior knowledge of the epidemiological incubation period is constructed, and cross-modal feature alignment is performed on ubiquitous sensing data based on the matrix. Based on the aligned cross-modal features, heterogeneous entities are instantiated, and a port spatiotemporal knowledge graph is generated by constructing network edges with bilateral spatiotemporal topological constraints between different nodes. By using a metapopulation graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph, the dynamic parameters of time-varying infectious diseases can be calculated and the spread risk can be assessed. When the risk exceeds the preset dynamic threshold, the large language model multi-agent cluster is activated to perform counterfactual inference and automatically generate disposal instructions.
[0010] As a further technical solution, cross-modal feature alignment of ubiquitous sensing data is performed based on a dynamic time lag mask matrix, mapping it to a unified multimodal feature latent space, as shown in the following equation:
[0011] in, The query feature matrix generated for the text modality. and The key matrix and value matrix generated from numerical time series data are respectively. Scaling the dimension of the features It is a dynamic time-lag mask matrix generated based on prior knowledge of the epidemiological incubation period.
[0012] As a further technical solution, based on aligned cross-modal features, heterogeneous entities are instantiated, and a port spatiotemporal knowledge graph is generated by constructing network edges with bilateral spatiotemporal topological constraints between different nodes, including: Based on the aligned cross-modal features, a heterogeneous entity set including human patient nodes, animal community nodes, logistics commodity nodes and spatial location nodes is instantiated. Construct network edges with bilateral spatiotemporal topological constraints between different nodes, and define each network edge as a quadruple with spatiotemporal attributes; The port spatiotemporal knowledge graph is obtained by dynamically updating entities based on newly added data, incrementally generating edges, and adjusting edge weights.
[0013] As a further technical solution, the network edges include infection tracing relationships based on virus sequencing or contact history, logistics route area relationships generated based on logistics, habitat overlap relationships generated based on ecological sensing, and spatiotemporal co-occurrence relationships.
[0014] As a further technical solution, a meta-population graph transformation neural network is used to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate the dynamic parameters of time-varying infectious diseases and assess the spread risk, including: The spatiotemporal knowledge graph is input into the meta-population graph transformation neural network. During the forward graph convolution propagation process, the hidden state of each node in the graph is updated layer by layer according to the following node feature update formula:
[0015] in, This represents the updated features of the target node in the next convolutional layer. To dynamically fuse the attention interaction coefficients of the human spatiotemporal mobility matrix and the wildlife habitat overlap probability matrix; To indicate the first l Neighbor nodes in the layer j The hidden feature vector; To indicate the first l The learnable weight matrix of a layered graph neural network is used to evaluate neighboring nodes. j Hidden features Perform a linear transformation so that the features of different types of nodes can be mapped to the same update space.
[0016] As a further technical solution, the large language model multi-agent cluster includes at least: a chief commander agent, a cross-border trade verification agent, a common health monitoring agent, and an open-source intelligence analysis agent.
[0017] As a further technical solution, when the risk exceeds a preset dynamic threshold, the large language model multi-agent cluster is activated to perform counterfactual inference and automatically generate disposal instructions, including: The chief commander agent breaks down the assessment task into several sub-tasks, which are then distributed to the cross-border trade verification agent, the same health monitoring agent, and the open-source intelligence analysis agent for parallel execution. Each intelligent agent invokes its dedicated domain knowledge base or database interface to return structured context features; The chief commander agent combines the converged contextual features to perform counterfactual inferences on multiple intervention strategies and calculates the comprehensive utility objective function; The comprehensive utility objective function is solved by solving the logic chain of the large model to obtain the optimal control strategy. The optimal strategy is then transformed into a structured natural language response report and issued through the instruction generation function.
[0018] The second aspect of this invention provides an infectious disease monitoring and early warning system based on a large language model and knowledge graph.
[0019] An infectious disease monitoring and early warning system based on large language models and knowledge graphs includes: The data acquisition module is configured to acquire ubiquitous sensing data from the port. The feature alignment module is configured to: construct a dynamic time-lag mask matrix that integrates prior knowledge of the epidemiological incubation period, and perform cross-modal feature alignment on ubiquitous sensing data based on the matrix; The knowledge graph construction module is configured to: instantiate heterogeneous entities based on aligned cross-modal features, and generate a port spatiotemporal knowledge graph by constructing network edges with bilateral spatiotemporal topological constraints between different nodes. The risk projection module is configured to: use a metapopulation graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate the dynamic parameters of time-varying infectious diseases and assess the risk of spread; The decision-making and handling module is configured to activate the large language model multi-agent cluster when the risk exceeds the preset dynamic threshold range, perform counterfactual inference, and automatically generate handling instructions.
[0020] A fourth aspect of the present invention provides an electronic device, including a memory, a processor, and a program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in the first aspect of the present invention.
[0021] The above one or more technical solutions have the following beneficial effects: (1) This invention uses a dynamic time lag masking mechanism and a cross-modal attention fusion model to map multiple types of data, such as text, numerical values, trajectories, and sensor data, to the same feature space, effectively solving problems such as data fragmentation, modal mismatch, and misaligned propagation time in traditional systems. Relying on prior knowledge of the epidemiological incubation period, it filters out invalid noise and retains true causal relationships, significantly improving data utilization and early abnormal signal detection capabilities. This provides a high-quality and highly reliable fusion feature foundation for accurate monitoring, greatly reducing the risk of missed detections and false detections caused by data fragmentation.
[0022] (2) This invention constructs a spatiotemporal knowledge graph of "Same Health" covering humans, animals, commodities, environment, and location. It uses dynamic weighted edges to depict complex relationships such as infection tracing, logistics links, habitat overlap, and spatiotemporal co-occurrence, breaking through the limitations of traditional models that only focus on a single dimension. By presenting the transmission chain and spatial topology of infectious diseases in a complete graph structure, it can realize rapid tracing of transmission paths and intelligent mining of implicit associations, significantly improving the modeling ability of cross-regional, cross-species, and cross-scenario transmission risks, and providing reliable support for dynamic risk assessment.
[0023] (3) This invention utilizes a meta-population graph transformation neural network to perform forward graph convolution and spatial attention aggregation, dynamically calculating the time-varying dynamic parameters of infectious diseases, replacing the traditional static threshold and fixed parameter models. It can adaptively track real-time changes in transmission intensity, spread speed, and affected range, quantitatively assess outbreak risks and predict trends, and has stronger adaptability to highly complex scenarios such as emerging unknown pathogens and covert transmission, effectively improving the timeliness and accuracy of early warning and providing a scientific basis for early intervention.
[0024] Advantages of additional aspects of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0025] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute an improper limitation of the invention.
[0026] Figure 1 This is a flowchart of the method in the first embodiment.
[0027] Figure 2 The flowchart shows the automated decision-making mechanism of the multi-agent cluster in the first embodiment.
[0028] Figure 3 This is a system architecture diagram for the second embodiment. Detailed Implementation
[0029] It should be noted that the following detailed descriptions are exemplary and intended to provide further illustration of the invention. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains.
[0030] It should be noted that the terminology used herein is for the purpose of describing particular implementations only and is not intended to limit the exemplary implementations of the present invention.
[0031] Where there is no conflict, the embodiments and features in the embodiments of the present invention can be combined with each other.
[0032] Example 1 This embodiment discloses an infectious disease monitoring and early warning method based on a large language model and knowledge graph. First, a dynamic time lag masking mechanism is used to achieve semantic alignment and feature fusion of cross-modal heterogeneous data. Then, heterogeneous entities such as hosts, animals, logistics, and spatial locations are instantiated to construct a spatiotemporal knowledge graph covering all elements of "same health". On this basis, a metapopulation graph transformation neural network is used for forward graph convolution propagation to dynamically calculate the dynamic parameters of time-varying infectious diseases and assess the spread risk. Finally, when the risk exceeds the limit, the large language model multi-agent cluster is activated to automatically generate the optimal prevention and control strategy and structured disposal instructions through counterfactual inference, forming a millisecond-level intelligent closed loop from perception to decision-making.
[0033] like Figure 1 As shown, the infectious disease monitoring and early warning method based on large language models and knowledge graphs includes: Step S1: Obtain ubiquitous sensing data of the port. This ubiquitous sensing data includes at least customs cross-border trade logistics node sequences, wildlife ecological sensing time-series values, clinical syndrome statistics, and multilingual open-source intelligence text. The customs cross-border trade logistics node sequences are used to construct logistics commodity nodes, transit area relationships, and spatiotemporal co-occurrence relationships. The wildlife ecological sensing time-series values are used to construct animal community nodes and habitat overlap relationships. The clinical syndrome statistics are used to construct human patient nodes and health abnormality features. The multilingual open-source intelligence text is used to extract semantic features of public health events and participate in cross-modal attention fusion. After cleaning, time-slice discretization, spatial label binding, and feature encoding, the above data serves as input data for subsequent dynamic time-lag mask matrix construction, cross-modal feature alignment, port spatiotemporal knowledge graph generation, and risk inference.
[0034] This step, based on a multi-source IoT and system interface network, constructs a real-time data acquisition link across the entire region, uniformly accessing, cleaning, and standardizing ubiquitous sensing data within the port area. The system acquires real-time cross-border trade logistics node sequence data through the customs information management platform interface, including cargo declaration information, transport vehicle trajectories, customs clearance times, cold chain temperature and humidity records, loading and unloading nodes, and transit routes—a complete time-series information process. Simultaneously, through IoT devices deployed in the port's ecological areas, such as infrared sensors, trajectory monitoring, and environmental sampling devices, it continuously collects ecological sensing time-series values such as wildlife activity frequency, species distribution, and habitat environmental parameters.
[0035] The system synchronously connects with port medical institutions and quarantine stations, automatically aggregating statistical data on clinical syndromes such as fever, cough, and gastrointestinal symptoms, and generating real-time statistical reports according to time and space dimensions. In addition, through multilingual web crawlers and open-source intelligence gathering interfaces, it obtains real-time multilingual text data such as the dynamics of infectious diseases abroad, regional health announcements, and social media platform warning information.
[0036] All collected data undergoes real-time preprocessing to remove duplicates, complete data, standardize formats, and bind spatiotemporal tags, forming a high-quality, time-efficient ubiquitous port perception dataset. This provides stable and comprehensive data support for subsequent cross-modal feature fusion and knowledge graph construction, ensuring coverage of core monitoring dimensions such as logistics, ecology, and healthcare, leaving no monitoring blind spots.
[0037] Step S2: Construct a dynamic time lag mask matrix that integrates prior knowledge of the epidemiological incubation period, and align the discrete numerical time series signals and unstructured text through cross-modal attention fusion and map them to a unified multimodal feature latent space.
[0038] The discrete numerical time-series signals are obtained by time-slice discretization, normalization, and feature encoding from customs cross-border trade logistics node sequences, wildlife ecological sensing time-series values, and clinical syndrome statistics. The unstructured text is obtained from multilingual open-source intelligence text through text cleaning, entity extraction, and semantic encoding. The dynamic time lag mask matrix uses the discretized time slices as row and column indices. Based on the shortest incubation period, longest incubation period, host exposure window, and logistics transportation delay of the target infectious disease, it determines whether any two time slices meet the effective transmission lag constraint. If they do, they are assigned effective weights; otherwise, they are assigned suppression weights. These weights are used as attention bias terms in cross-modal attention fusion, aligning the discrete numerical time-series signals with the unstructured text representations and mapping them to a unified multimodal feature latent space.
[0039] Specifically, independent encoding is performed on data of different modalities and mapped to a shared latent feature space. For unstructured text, a large language model fine-tuned for the public health domain (such as PubMedBERT) is used to extract contextual semantic features, which are then used to generate a query matrix via linear projection. This is used to match temporal features in attention mechanisms. For discrete numerical time-series data, after slicing by a sliding window, the data is input into a hybrid network of a one-dimensional convolutional neural network (1D-CNN) and a long short-term memory network (LSTM) to extract local mutations and long-short-term dependencies, and then projected to generate a key matrix. AND-value matrix .
[0040] In the cross-modal attention fusion stage, a dynamic time-lag mask matrix based on prior knowledge of epidemiological latency is introduced. This is used to constrain temporal causal relationships and filter out noisy matches that do not conform to the disease transmission pattern. Subsequently, matching calculations are performed using the query matrix and the key matrix, and these calculations are superimposed during the process. To implement physical propagation logic constraints. Finally, normalization is performed using the Softmax function and compared with the value matrix. Multiplying these features filters out noise signals that do not conform to temporal causality, and outputs a depth-aligned cross-modal fusion feature vector.
[0041]
[0042] in, The query feature matrix generated for the text modality. and The key matrix and value matrix generated from numerical time series data are respectively. Scaling the dimension of the features This is a dynamic time-lag mask matrix generated based on prior knowledge of the epidemiological incubation period, initially set to all 1s.
[0043] The above steps achieve precise alignment between text semantics and numerical temporal sequence in a unified latent space. By utilizing prior knowledge of the latency period, a strong binding between physical propagation logic and data feature space is achieved. This effectively solves problems such as temporal misalignment, modal heterogeneity, and semantic gap among multi-source heterogeneous data, improves the robustness and biological interpretability of feature fusion, and provides a high-quality, highly consistent cross-modal feature foundation for subsequent entity instantiation, relational reasoning, and risk calculation.
[0044] Step S3: Based on the aligned cross-modal features, heterogeneous entities are instantiated, and a port spatiotemporal knowledge graph is generated by constructing network edges with bilateral spatiotemporal topological constraints between different nodes.
[0045] Based on aligned cross-modal features, entity recognition, type determination, and attribute filling are performed on feature vectors representing patient symptoms, animal activity, logistics goods, spatial location, and open-source intelligence events. This generates heterogeneous entity sets including human patient nodes, animal community nodes, logistics goods nodes, spatial location nodes, and intelligence event nodes. Each entity node contains at least entity identifier, entity type, occurrence time, spatial location, source modality, and confidence level attributes. Furthermore, based on spatiotemporal co-occurrence, logistics routes, infection tracing, habitat overlap, and semantic relationships among different entities, a network edge with bilateral spatiotemporal topological constraints is constructed. This edge transforms dispersed multi-source sensing features into a reasonable port spatiotemporal knowledge graph, providing structured input for subsequent propagation path identification, risk diffusion simulation, and multi-agent response decision-making.
[0046] Specifically, the first step is to instantiate heterogeneous entities. Based on the aligned multimodal features, four types of core entity nodes are automatically extracted and instantiated: human patient nodes, animal community nodes, logistics commodity nodes, and spatial location nodes. Human patient nodes integrate syndrome statistics and clinical text features, labeling symptom types, occurrence times, and sampling information; animal community nodes are based on ecological sensing time-series features, marking animal species, activity ranges, monitoring times, and abnormal health states; logistics commodity nodes are based on cross-border trade logistics node sequence features, associating cargo types, means of transport, customs clearance records, and cold chain status; spatial location nodes are based on port areas, monitoring points, and logistics transit points, binding spatial information such as latitude and longitude, administrative divisions, and functional zones, forming a heterogeneous entity set with a unified structure and complete attributes.
[0047] Subsequently, network edges with bilateral spatiotemporal topological constraints are constructed between different entity nodes. These network edges include at least infection tracing relationships, logistics route relationships, habitat overlap relationships, and spatiotemporal co-occurrence relationships, and each network edge is defined as a quadruple with spatiotemporal attributes. ,in, Represents the source entity node. Represents the target entity node. Indicates the type of relationship between nodes. This represents the confidence weight calculated based on multimodal evidence. The spatiotemporal attributes include the time of occurrence, spatial location, effective time window, and source of evidence.
[0048] Among them, infection tracing refers to determining whether there is a potential source of transmission relationship between two patient nodes, between a patient node and an animal community node, or between a patient node and a logistics commodity node, based on pathogen genome sequence similarity, patient contact history, exposure location, and sampling time. Specifically, the system first obtains the pathogen whole genome sequencing sequences corresponding to different samples and performs a uniform length comparison of the sequences; for any two sample sequences... and The Hamming distance is calculated by comparing the corresponding bases in the two sequences one by one and recording the number of inconsistent positions. The calculation formula is as follows:
[0049] in, Indicates the length of the aligned sequence. and These represent the two sample sequences at the th... The bases at each position, This is an indicator function; it takes a value of 1 when the two bases are inconsistent and a value of 0 when they are consistent. If the Hamming distance between two samples is less than a preset genetic difference threshold, and they satisfy the propagation sequence constraints in sampling time, exposure location, or contact chain, then an infection tracing edge is established between the corresponding entity nodes, and the confidence weight of the edge is calculated based on the Hamming distance, time interval, spatial distance, and contact history evidence. This can be further written as an edge weight formula:
[0050] in, This represents the Hamming distance between two pathogen sequences. Indicates the time interval between two samples or events. Indicates spatial distance. This indicates a history of contact or evidence of shared exposure. The weighting coefficient is denoted by . The smaller the Hamming distance, the more similar the two pathogen sequences are, and the higher the confidence in the infection tracing relationship. If the temporal sequence, spatial proximity, and contact history are all satisfied simultaneously, the weight of the network edge is further increased.
[0051] For the "spatiotemporal co-occurrence" relationship, base station roaming data, GPS trajectories, logistics node times, clinical symptom onset times, and ecological sensor data collection times are extracted to calculate the spatial distance between different entity nodes. and time interval When two entity nodes satisfy and When the constraints are met, it is determined that the two co-occur within the same spatiotemporal window, and a spatiotemporal co-occurrence edge is established between the corresponding nodes.
[0052] in, It represents the spatial distance between corresponding locations of two entity nodes, such as the distance between the location of a patient's activity and the location through which logistics goods pass. This indicates a preset spatial distance threshold, such as 500 meters, 1 kilometer, or a value set according to the size of the port area. This indicates the time interval between the occurrence of two entity events, such as the interval between the onset of a patient's symptoms and the transit time of a logistics product. This represents a preset time window threshold, such as 6 hours, 24 hours, or a threshold set based on the disease incubation period and monitoring frequency. Then, based on the aforementioned entity instantiation and edge relationship construction process, a border spatiotemporal knowledge graph with macroscopic "same health" characteristics is evolved and generated. This evolutionary process includes: aligning the continuously accessed customs logistics node sequences, ecological sensor data, clinical syndrome statistics, and open-source intelligence text with timestamps and binding them with spatial tags; matching new data to existing entity nodes or generating new patient, animal, logistics, environment, and spatial location nodes; and simultaneously updating node attributes. For entity nodes that meet the conditions of infection tracing, logistics routes, habitat overlap, or spatiotemporal co-occurrence, the system incrementally generates corresponding network edges and dynamically adjusts edge weights based on time decay, spatial distance, consistency of multi-source evidence, and event confidence, thereby forming a border spatiotemporal knowledge graph that can reflect abnormal population health, changes in animal activity, logistics flow paths, and environmental exposure risks over time.
[0053] Step S4: The metapopulation graph transformation neural network is used to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate the dynamic parameters of time-varying infectious diseases and assess the risk of spread.
[0054] The core of this step lies in using a meta-population graph transform neural network to perform forward graph convolution propagation on the constructed port spatiotemporal knowledge graph, thereby dynamically calculating time-varying infectious disease dynamic parameters and assessing the risk of disease spread. To overcome the isolation limitations of traditional epidemiological models when dealing with complex spatial heterogeneity, the meta-population graph transform neural network, in the cross-regional multimodal feature aggregation stage, no longer relies on a static distance matrix. Instead, it dynamically evaluates the influence weights of multi-source spatiotemporal neighbor nodes in the network topology and performs nonlinear feature interactions based on a graph attention mechanism.
[0055] Specifically, the port spatiotemporal knowledge graph generated in step S3 is first input into the meta-population graph transformation neural network. The meta-population graph transformation neural network adopts a multi-layer graph convolutional structure and introduces a multi-head graph attention mechanism in each layer of graph convolution. Its input is heterogeneous graph data containing patient nodes, animal community nodes, logistics commodity nodes, spatial location nodes, and intelligence event nodes. The node features are composed of cross-modal aligned feature vectors, and the edge features are composed of relationship types, time attributes, spatial attributes, and confidence weights related to infection tracing, logistics routes, habitat overlap, and spatiotemporal co-occurrence.
[0056] During data processing, the system first converts heterogeneous entity nodes into node feature matrices, transforms the spatiotemporal relationships between nodes into adjacency matrices or edge index matrices, and encodes the time interval, spatial distance, relationship type, and confidence weight of edges into edge attribute vectors. Subsequently, in each layer of graph convolution, the features of neighboring nodes are linearly transformed based on the set of neighboring nodes of the target node, and the influence weights of different neighboring nodes on the target node are calculated using a multi-head attention mechanism. This adaptively aggregates information from different sources such as population flow, overlapping animal habitats, logistics paths, and environmental exposure, and updates the hidden state of each node in the graph layer by layer.
[0057] The network output includes risk representations of each node, transmission risk scores for different regions or groups, and time-varying infectious disease dynamic parameters, which are used to subsequently determine whether the risk exceeds the dynamic threshold domain and trigger the large language model multi-agent cluster to perform counterfactual inference and generate disposal instructions.
[0058] During the forward graph convolutional propagation process, the network updates the hidden state of each node layer by layer according to the following node feature update formula:
[0059] in, This represents the updated features of the target node in the next convolutional layer. To dynamically fuse the attention interaction coefficients of the human spatiotemporal mobility matrix and the wildlife habitat overlap probability matrix; To indicate the first l Neighbor nodes in the layer j The hidden feature vector; To indicate the first l The learnable weight matrix of a layered graph neural network is used to evaluate neighboring nodes. j Hidden features Perform a linear transformation so that the features of different types of nodes can be mapped to the same update space.
[0060] Step S5: When the risk exceeds the preset dynamic threshold range, activate the large language model multi-agent cluster, perform counterfactual inference, and automatically generate disposal instructions.
[0061] like Figure 2 As shown, the large-scale multi-agent cluster includes a chief commander agent, a cross-border trade verification agent, a unified health monitoring agent, and an open-source intelligence analysis agent. This cluster, through task decomposition and parallel inference, reconstructs complex numerical predictions into counterfactual scenario simulations based on natural language. By calculating the game balance between maintaining economic activity and disease control under different intervention strategies, it automatically generates structured infectious disease response reports. To overcome the 'illusion' and 'uncontrollability' inherent in traditional large-scale language models that directly output control strategies, step S5 introduces a counterfactual inference mechanism based on utility function constraints.
[0062] Specifically, the system formalizes the decision-making logic of multi-agent systems into a comprehensive utility objective function. When faced with sudden signals at the border, the chief commander's AI can perform parallel calculations of strategic space. Multiple intervention paths are involved. Let the current spatiotemporal knowledge graph output the comprehensive anomaly risk state as... Chief Commander AI The analysis task is broken down into a set of subtasks. Each specialized intelligent agent executes tasks in parallel and returns structured context features. :
[0063] in, Represents structured context features, Represents a set of subtasks. Indicates a comprehensive abnormal risk status. Indicates time characteristics, This refers to the dedicated domain knowledge base or database interface mounted by each intelligent agent. Representing a large language model. Defining the feasible intervention strategy space as follows: (Such as closing borders, conducting additional nucleic acid tests, and carrying out localized disinfection). For any strategy... The chief commander agent combines converged contextual features Counterfactual reasoning is performed within its internal "world model" to calculate the overall utility objective function of the strategy. :
[0064] in, Objective function, representing In strategy Next, future The expected public health benefits of suppressing the spread of infectious diseases within a given time step; Indicates implementation strategy The penalty for direct and indirect losses to border economic activities is initially set to 0. The game equilibrium factor, dynamically and adaptively adjusted according to the level of disease crisis, is initially set to 0.3. The system solves for the optimal control strategy through the logic chain of the large model. :
[0065] in, This represents the optimal control strategy. Finally, the optimal strategy is transformed into a structured and compliant natural language response report using an instruction generation function. :
[0066] in, This indicates a natural language response report.
[0067] Example 2 This embodiment discloses an infectious disease monitoring and early warning system based on a large language model and knowledge graph; like Figure 3 As shown, the infectious disease monitoring and early warning system based on large language models and knowledge graphs includes: The data acquisition module is configured to acquire ubiquitous sensing data from the port. The feature alignment module is configured to: construct a dynamic time-lag mask matrix that integrates prior knowledge of the epidemiological incubation period, and perform cross-modal feature alignment on ubiquitous sensing data based on the matrix; The knowledge graph construction module is configured to: instantiate heterogeneous entities based on aligned cross-modal features, and generate a port spatiotemporal knowledge graph by constructing network edges with bilateral spatiotemporal topological constraints between different nodes. The risk projection module is configured to: use a metapopulation graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate the dynamic parameters of time-varying infectious diseases and assess the risk of spread; The decision-making and handling module is configured to activate the large language model multi-agent cluster when the risk exceeds the preset dynamic threshold range, perform counterfactual inference, and automatically generate handling instructions.
[0068] Example 3 The purpose of this embodiment is to provide a computer-readable storage medium.
[0069] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps in the infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in Example 1.
[0070] Example 4 The purpose of this embodiment is to provide an electronic device.
[0071] An electronic device includes a memory, a processor, and a program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps in the infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in Embodiment 1.
[0072] The steps and methods involved in the apparatuses of Embodiments 2, 3, and 4 above correspond to those in Embodiment 1. For specific implementation details, please refer to the relevant description section of Embodiment 1. The term "computer-readable storage medium" should be understood as a single medium or multiple media including one or more instruction sets; it should also be understood as including any medium capable of storing, encoding, or carrying an instruction set for execution by a processor and enabling the processor to perform any of the methods in this invention.
[0073] Those skilled in the art will understand that the modules or steps of the present invention described above can be implemented using general-purpose computer devices. Optionally, they can be implemented using computer-executable program code, thereby allowing them to be stored in a storage device for execution by a computer device, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. The present invention is not limited to any particular combination of hardware and software.
[0074] While the specific embodiments of the present invention have been described above in conjunction with the accompanying drawings, this is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that various modifications or variations that can be made by those skilled in the art without creative effort based on the technical solutions of the present invention are still within the scope of protection of the present invention.
Claims
1. A method for infectious disease monitoring and early warning based on large language models and knowledge graphs, characterized in that, include: Acquire ubiquitous sensing data at ports of entry; A dynamic time-lag mask matrix is constructed that integrates prior knowledge of the epidemiological incubation period, and cross-modal feature alignment of ubiquitous sensing data is performed based on the matrix. Specifically, the cross-modal feature alignment of ubiquitous sensing data based on the dynamic time-lag mask matrix maps to a unified multimodal feature latent space, as shown in the following equation: in, The query feature matrix generated for the text modality. and The key matrix and value matrix generated from numerical time series data are respectively. Scaling the dimension of the features A dynamic time-lag mask matrix generated based on prior knowledge of the epidemiological incubation period; Based on the aligned cross-modal features, heterogeneous entities are instantiated, and a port spatiotemporal knowledge graph is generated by constructing network edges with bilateral spatiotemporal topological constraints between different nodes. By using a metapopulation graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph, the dynamic parameters of time-varying infectious diseases can be calculated and the spread risk can be assessed. When the risk exceeds the preset dynamic threshold, the large language model multi-agent cluster is activated to perform counterfactual inference and automatically generate disposal instructions.
2. The infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in claim 1, based on aligned cross-modal features, instantiates heterogeneous entities, and generates a port spatiotemporal knowledge graph by constructing network edges with bilateral spatiotemporal topological constraints between different nodes, including: Based on the aligned cross-modal features, a heterogeneous entity set including human patient nodes, animal community nodes, logistics commodity nodes and spatial location nodes is instantiated. Construct network edges with bilateral spatiotemporal topological constraints between different nodes, and define each network edge as a quadruple with spatiotemporal attributes; The entity is dynamically updated based on the newly added data, edges are incrementally generated and edge weights are adjusted to obtain the port spatiotemporal knowledge graph.
3. The infectious disease monitoring and early warning method based on large language model and knowledge graph as described in claim 2 defines each network edge as a quadruple with spatiotemporal attributes, specifically: the network edge includes infection tracing relationship based on virus sequencing or contact history, logistics route area relationship based on logistics, habitat overlap relationship based on ecological sensing, and spatiotemporal co-occurrence relationship.
4. The infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in claim 1, which utilizes a meta-population graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate time-varying infectious disease dynamic parameters and assess spread risk, includes: The spatiotemporal knowledge graph is input into the meta-population graph transformation neural network. During the forward graph convolution propagation process, the hidden state of each node in the graph is updated layer by layer according to the following node feature update formula: in, This represents the updated features of the target node in the next convolutional layer. To dynamically fuse the attention interaction coefficients of the human spatiotemporal mobility matrix and the wildlife habitat overlap probability matrix; To indicate the first l Neighbor nodes in the layer j The hidden feature vector; To indicate the first l The learnable weight matrix of a layered graph neural network is used to evaluate neighboring nodes. j Hidden features Perform a linear transformation so that the features of different types of nodes can be mapped to the same update space.
5. The infectious disease monitoring and early warning method based on large language models and knowledge graphs as described in claim 1, wherein the large language model multi-agent cluster includes at least: Chief Commander Agent, Cross-border Trade Verification Agent, Same Health Monitoring Agent, and Open Source Intelligence Analysis Agent.
6. The infectious disease monitoring and early warning method based on a large language model and knowledge graph as described in claim 5, wherein when the risk exceeds a preset dynamic threshold, the large language model multi-agent cluster is activated to perform counterfactual inference and automatically generate disposal instructions, including: The chief commander agent breaks down the assessment task into several sub-tasks, which are then distributed to the cross-border trade verification agent, the same health monitoring agent, and the open-source intelligence analysis agent for parallel execution. Each intelligent agent invokes its dedicated domain knowledge base or database interface to return structured context features; The chief commander agent combines the converged contextual features to perform counterfactual inferences on multiple intervention strategies and calculates the comprehensive utility objective function; The comprehensive utility objective function is solved by solving the logic chain of the large model to obtain the optimal control strategy. The optimal strategy is then transformed into a structured natural language response report and issued through the instruction generation function.
7. An infectious disease monitoring and early warning system based on large language models and knowledge graphs, characterized in that, include: The data acquisition module is configured to acquire ubiquitous sensing data from the port. The feature alignment module is configured to: construct a dynamic time-lag mask matrix that integrates prior knowledge of the epidemiological incubation period, and perform cross-modal feature alignment on ubiquitous sensing data based on the matrix; wherein, the cross-modal feature alignment of ubiquitous sensing data based on the dynamic time-lag mask matrix is mapped to a unified multimodal feature latent space, as shown in the following equation: in, The query feature matrix generated for the text modality. and The key matrix and value matrix generated from numerical time series data are respectively. Scaling the dimension of the features A dynamic time-lag mask matrix generated based on prior knowledge of the epidemiological incubation period; The knowledge graph construction module is configured to: instantiate heterogeneous entities based on aligned cross-modal features, and generate a port spatiotemporal knowledge graph by constructing network edges with bilateral spatiotemporal topological constraints between different nodes. The risk projection module is configured to: use a metapopulation graph transformation neural network to perform forward graph convolution propagation in the spatiotemporal knowledge graph to calculate the dynamic parameters of time-varying infectious diseases and assess the risk of spread; The decision-making and handling module is configured to activate the large language model multi-agent cluster when the risk exceeds the preset dynamic threshold range, perform counterfactual inference, and automatically generate handling instructions.
8. A computer-readable storage medium having a program stored thereon, characterized in that, When executed by the processor, the program implements the steps of the infectious disease monitoring and early warning method based on large language models and knowledge graphs as described in any one of claims 1-6.
9. An electronic device comprising a memory, a processor, and a program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps in the infectious disease monitoring and early warning method based on large language models and knowledge graphs as described in any one of claims 1-6.
Citation Information
Patent Citations
Knowledge graph construction method and system based on large language model technology
CN120523966A
Intelligent landslide risk decision-making method and system driven by multi-modal knowledge graph
CN121881250A