Chemical abnormal event detection method and system based on event graph

By constructing a chemical abnormal event detection method based on the rational map, and using the graph attention network model to detect chemical abnormal event, the problem of insufficient detection accuracy in the existing technology is solved, efficient matching and accurate prediction of chemical abnormal events is achieved, and a fast emergency response solution is provided.

CN114153988BActive Publication Date: 2025-08-19QINGDAO UNIV OF SCI & TECH
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202111461707.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-02
Publication Date
2025-08-19
Estimated Expiration
2041-12-02

AI Technical Summary

Technical Problem

The existing chemical anomaly event detection methods are difficult to fully capture the changes and evolution of historical cases, resulting in insufficient accuracy and completeness of detection and analysis, and lack of sufficient exploration of multi-source information and deep commonality among events.

Method used

A chemical abnormal event detection method based on the theory map is constructed, similar events are gathered through the theory map abstract technology, and the specific causes and evolutionary expressions of each accident case are formed. The graph attention network model is used to detect abnormal events, and combined with the logical relationships such as follow-up, cause and effect, conditions and superior and inferior events between events, to achieve efficient matching and accurate prediction.

Benefits of technology

It improves the accuracy and efficiency of chemical abnormal event detection, can quickly provide accurate emergency response plans, fully explore data implicit information, enhance the ability to fusion of event representation and surrounding node information, and achieve efficient matching and evolution analysis of abnormal events.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114153988B_ABST
    Figure CN114153988B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and system for detecting abnormal chemical events based on a causal graph. The method comprises: obtaining a chemical accident report to be detected; preprocessing the chemical accident report to obtain a text vector of the chemical accident report; and determining the accident type and case type corresponding to the chemical accident report based on the text vector and a trained graph attention network model. The graph attention network model is trained based on the causal graph, thereby more accurately predicting the type of accident and quickly providing an emergency response plan.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of chemical abnormal event detection, and in particular to a chemical abnormal event detection method and system based on an event graph. Background Art

[0002] The statements in this section merely mention background art related to the present invention and do not necessarily constitute prior art.

[0003] Chemical production processes are characterized by flammability, explosiveness, highly toxic byproducts, and high process risks. Often, a single minor misstep can escalate into a major incident, such as a fire, explosion, or poisoning. Heinrich's Law states that no accident is an isolated event, but rather the result of a series of successive events. These "minor incidents" frequently occur on production sites, yet often go unnoticed. When these unsafe factors converge, they can trigger larger incidents or even accidents. In severe cases, these can have catastrophic consequences, including significant economic losses, casualties, environmental pollution, and even domino effects affecting neighboring plants. Therefore, accurately detecting abnormal events that could potentially lead to accidents and correctly analyzing their potential evolution is crucial for ensuring production safety and reducing the probability of accidents.

[0004] The analysis and assessment of chemical industry incidents often rely on expert experience. When an incident occurs in a chemical production process, experts analyze the incident and determine its evolutionary trends based on their experience handling similar incidents, ultimately developing a response plan. However, this approach introduces significant uncertainty and risk in developing a response plan due to the complexity of the on-site environment, the diversity of incident evolution, and the varying expertise of experts. Transforming historical incident management experience into reusable expert knowledge and leveraging information technology and artificial intelligence for comprehensive analysis and assessment is crucial for analyzing current accident hazards and identifying the potential evolution of incidents.

[0005] Existing abnormal event detection and analysis methods are mostly based on accident analysis models, such as fault tree analysis (FTA), event tree analysis (ETA), bow-tie analysis, and hazard and operability analysis (HAZOP). These methods are either based on the cause analysis of a single accident or the safety analysis results of a specific device or equipment, making it difficult to categorize and summarize a large number of historical cases. Therefore, abnormal event detection, accident simulation, and scenario analysis based on Bayesian networks, random networks, neural networks, and other technologies only retrieve and analyze accidents on a per-accumulator basis, without forming a convergent analysis of accidents. As a result, they cannot fully represent events with multi-source information, nor can they fully explore the implicit information of similar events. The constructed scenarios cannot fully capture the changes and evolution of historical cases, resulting in insufficient accuracy and completeness in the detection and evolution analysis of abnormal events.

[0006] In addition to most accident analysis model-based approaches, there are also graph-based models. Examples include: Chinese invention patent publication number CN110968699A - A logical graph construction and early warning method and device based on event-based recommendation; and Chinese invention patent publication number CN108052576A - A method and system for constructing event-based knowledge graphs.

[0007] Chinese invention patent, publication number CN110968699A - A method and device for constructing a logical graph and providing early warning based on event-based recommendation. Regarding graph construction, this patent extracts events based on the logical relationship types between specified events and creates a graph based on the event extraction results. The graph has the advantage of focusing on both the evolving logical relationships between external events and the rich attribute information of the events themselves. However, this patent lacks a top-level structural design for event abstraction and is merely a graph of accident cases.

[0008] Chinese invention patent, publication number CN108052576A - A method and system for constructing a knowledge graph of events. The patent constructs a knowledge graph of events consisting of a macro event layer, a micro knowledge layer and a knowledge ontology layer. Although a hierarchical structured network relationship of ontology, micro and macro is adopted, the constructed knowledge graph is separated from each other at the ontology layer, micro layer and event layer. The lack of information connectivity makes it difficult to discover the deep commonalities between events. Summary of the Invention

[0009] In order to address the deficiencies of the prior art, the present invention provides a method and system for detecting abnormal chemical events based on a causal graph. This method proposes abnormal event detection based on a causal graph, aggregates similar events through the concept graph abstraction technology of the causal graph, and forms the specific causes and evolutionary expressions of each accident case through a case graph. This method not only discovers the common information of abnormal events, but also represents the individual variations of different cases, providing a basic knowledge organization form for accurately detecting the historical commonalities and different scenario evolutions of abnormal events. Based on this knowledge organization form of historical accident cases, the present invention provides an abnormal event detection method that integrates the process relationship of the overall accident evolution, which can more accurately predict the type of accident and quickly provide an emergency response plan.

[0010] In a first aspect, the present invention provides a method for detecting abnormal chemical events based on a fact-based graph;

[0011] The chemical industry abnormal event detection method based on the event graph includes:

[0012] Obtain chemical accident reports for testing;

[0013] Preprocessing the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected;

[0014] Determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the report and the trained graph attention network model;

[0015] Among them, the graph attention network model is obtained based on the training of the event graph.

[0016] In a second aspect, the present invention provides a chemical industry abnormal event detection system based on event graph;

[0017] The chemical industry abnormal event detection system based on the event graph includes:

[0018] An acquisition module is configured to: acquire a chemical accident report to be detected;

[0019] A preprocessing module is configured to: preprocess the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected;

[0020] A prediction module is configured to: determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the chemical accident report to be detected and the trained graph attention network model;

[0021] Among them, the graph attention network model is obtained based on the training of the event graph.

[0022] In a third aspect, the present invention further provides an electronic device, comprising:

[0023] a memory for non-transitory storage of computer-readable instructions; and

[0024] a processor for executing said computer-readable instructions,

[0025] When the computer-readable instructions are executed by the processor, the method described in the first aspect is executed.

[0026] In a fourth aspect, the present invention further provides a storage medium that non-temporarily stores computer-readable instructions, wherein when the non-temporary computer-readable instructions are executed by a computer, the instructions of the method described in the first aspect are executed.

[0027] In a fifth aspect, the present invention further provides a computer program product, comprising a computer program, wherein the computer program is used to implement the method described in the first aspect when running on one or more processors.

[0028] Compared with the prior art, the present invention has the following beneficial effects:

[0029] 1. Based on expert experience, this method designs a graph describing the evolutionary patterns and patterns of chemical events. This graph provides a basis for subsequent chemical event evolution and abnormal event detection.

[0030] 2. The GAT-based fusion graph model considers the logical relationships between graph node events, such as sequence, causality, conditions, and hierarchy, while conducting evolutionary reasoning on chemical accidents. This provides a high-quality data foundation for subsequent retrieval, evolutionary reasoning, and classification decisions, improving classification accuracy.

[0031] 3. This method fully mines the implicit information in the data, efficiently expresses multi-information events and sensitive information, and helps enhance the representation of chemical abnormal events and the potential of integrating surrounding node information;

[0032] 4. The model can efficiently match the nodes of the event graph for a given abnormal event, quickly and accurately provide similar historical cases of the abnormal event, and provide a basis for subsequent evolution analysis and emergency response.

[0033] 5. Based on the event evolution structure, this patent constructs a hierarchical event graph network structure that includes both event evolution relationships and event abstract relationships; at the same time, in terms of retrieval, this patent adopts a vectorized representation of the structural relationship of associated events, which can realize the semantic retrieval of current abnormal events based on historical common events.

[0034] 6. This patent employs an interconnected hierarchical structure—the connection between the concept-based layer and the case-based layer—represents the abstraction and generalization relationship between events. This means that nodes in the concept-based layer are more abstract semantic representations of nodes in the case-based layer, and that nodes in the concept-based layer can be generalized to any node in the case-based layer. Semantic alignment between the concept-based layer and the case-based layer effectively uncovers deep commonalities between different events, and thus, discovers essential connections and knowledge between events. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] The accompanying drawings, which constitute a part of the present invention, are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.

[0036] Figure 1 It is a chemical engineering phenomenon diagram proposed by the present invention that describes the evolution laws and patterns between events.

[0037] Figure 2 The present invention proposes a method and system for detecting abnormal chemical events based on an event graph. DETAILED DESCRIPTION

[0038] It should be noted that the following detailed descriptions are exemplary and intended to provide further explanation of the present invention. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which the present invention belongs.

[0039] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit exemplary embodiments according to the present invention. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0040] In addition, to facilitate a clear description of the technical solutions of the embodiments of the present invention, in the embodiments of the present invention, the words "first" and "second" are used to distinguish between identical or similar items with substantially the same functions and effects. Those skilled in the art will understand that the words "first" and "second" do not limit the quantity or execution order, and the words "first" and "second" do not necessarily mean that they are different.

[0041] In the absence of conflict, the embodiments of the present invention and the features thereof may be combined with each other.

[0042] All data in this embodiment is obtained in compliance with laws and regulations and based on the consent of the user, and is used legally.

[0043] Example 1

[0044] This embodiment provides a method for detecting abnormal chemical events based on a fact-based graph;

[0045] like Figure 2 As shown in FIG, the chemical abnormal event detection method based on the event graph includes:

[0046] S101: Obtain the chemical accident report to be tested;

[0047] S102: Preprocessing the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected;

[0048] S103: Determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the chemical accident report to be detected and the trained graph attention network model;

[0049] Among them, the graph attention network model is obtained based on the training of the event graph.

[0050] Further, S101: obtaining a chemical accident report to be detected; wherein the chemical accident report to be detected includes at least: an accident report title, accident report description information (time, location, cause of the accident, and casualties, property losses, etc. caused by the accident).

[0051] Further, S102: pre-processing the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected; specifically including:

[0052] Perform word segmentation on chemical accident reports to be tested;

[0053] Remove stop words from the word segmentation results;

[0054] Perform stem extraction on the result after removing stop words to obtain several stems;

[0055] For each extracted stem, generate each stem vector;

[0056] The average value of all stem vectors is calculated, and the average value is used as the text vector of the chemical accident report to be detected.

[0057] Exemplarily, the stem extraction uses the HanLP word segmentation tool.

[0058] HanLP is a Java toolkit consisting of a series of models and algorithms, aiming to popularize the use of natural language processing in production environments. HanLP offers comprehensive functionality, high performance, a clear architecture, up-to-date corpus, and customization.

[0059] Exemplarily, for each extracted word stem, each word stem vector is generated; this is achieved by using word2vec.

[0060] For example, after preprocessing matching events through data cleaning, word segmentation, stop word removal, and stemming, the word2vec toolkit can be used to generate vectors of a given dimension representing each word. The text vector can then be calculated, and the average of the word vectors in the text can be used to represent the event text vector.

[0061] Taking into account the structural characteristics of hazardous chemicals-specific nouns, custom domain vocabulary information, adopting the maximum matching mode, using the jieba Chinese word segmentation tool, and based on the hybrid mode of domain dictionary and general dictionary, the word automatic extraction method is designed and implemented for text-oriented word segmentation extraction.

[0062] When using the GAT model to fuse surrounding nodes, the constructed event graph is used to perform word segmentation, remove stop words, and extract stems. The separated words are then processed using word2vec to obtain 128-dimensional vectors. The average value of these word vectors is used to represent the vector of the event text.

[0063] Furthermore, the graph attention network model includes: a first graph attention network and a second graph attention network connected in sequence.

[0064] Exemplarily, the first graph attention network and the second graph attention network are both implemented using a graph attention network (GAT). The full name of GAT is Graph Attention Network.

[0065] Further, if Figure 1 As shown, the process of obtaining the event graph includes:

[0066] Constructing a training set and a test set; the training set and the test set both include M known accident types and several case types included in each type of accident;

[0067] According to each accident type and several case types corresponding to each accident type, a subgraph corresponding to each accident type is constructed to obtain the case-reasoning network layer;

[0068] For all parent nodes, we connect them according to the accident link lines of disaster-causing factors, disaster-bearing bodies, accident types and accident consequences, combined with the causal relationship of accidents and the accident evolution process, to obtain the concept and event network layer;

[0069] After the case reasoning network layer and the concept reasoning network layer are merged, a reasoning graph is obtained.

[0070] Furthermore, in the process of constructing the subgraph, each accident type is taken as a parent node, and all case types corresponding to the current accident type are taken as child nodes, and connections are made based on whether there is an inclusion relationship between the parent node and the child node.

[0071] For example, the solution of the present invention is as follows Figure 2 As shown in the figure, the event graph is constructed. Structurally, the event graph is a directed cyclic graph, where nodes represent events and directed edges represent logical relationships between events, such as sequence, cause and effect, condition, and hierarchy.

[0072] The causal graph adopts a hierarchical network structure:

[0073] The first layer is the concept-event network layer, in which each node is an accident node event that is highly abstracted from the event nodes of M accident reports, and the lines between nodes represent the evolutionary relationship between accidents.

[0074] The second layer is the case-event network layer, in which each node is a case event node or a case fault tree event node abstracted from the accident report, and the lines between the nodes represent the evolutionary relationship between the events in the accident.

[0075] The connection between the first-layer network nodes and the second-layer network nodes represents the abstraction and generalization relationship of events, indicating that the first-layer network nodes are more abstract semantic representations of the second-layer network nodes, and the first-layer network nodes can be generalized into any second-layer network nodes.

[0076] Construction of the conceptual event network layer. Based on the theory of event graphs and previous research on accident chain models, this paper establishes a general event graph network model for the chemical industry, following the accident chain of hazard factor → hazard-bearing body → accident type → accident consequences, combining the causal relationship of accidents and the accident evolution process. This model is further improved based on historical chemical accident data and actual research.

[0077] The case-based network layer was constructed. A web crawler was used to crawl data from relevant chemical industry accident reporting websites, resulting in a total of 1,661 accident analysis reports. After screening these accident analysis reports, 165 storage tank accident reports were identified. Events were extracted from these crawled accident cases based on their evolutionary relationships to describe the narrative chain of events. Based on this, a causal graph of the accidents was constructed.

[0078] Semantic alignment between the concept-context network layer and the case-context network layer. This method uses crowdsourcing to perform knowledge annotation on the text of accident report sub-events and concept-context map nodes, as well as on the logic tree nodes of typical cases and concept-context map nodes. Annotators can select specific entities to annotate, and the annotated knowledge is interconnected across multiple data sources. If the knowledge to be annotated already exists in the knowledge base, intelligent prompts are provided to complete it, saving annotation time, improving annotation efficiency, and ensuring annotation consistency.

[0079] Furthermore, the training process of the trained graph attention network model includes:

[0080] Obtain M known accident types and several case types contained in each type of accident; where M is a positive integer;

[0081] Construct a subgraph for each accident type and obtain M subgraphs;

[0082] Perform vector extraction on the accident report under each accident type to obtain several text vectors;

[0083] Input the M subgraphs and the corresponding text vectors of each subgraph into the first graph attention network to obtain the first vectors of the M parent nodes;

[0084] The first vectors of the M parent nodes, the M parent nodes in the concept-event network layer, and the connection relationship between the M parent nodes are input into the second graph attention network to obtain the second vectors of the M parent nodes;

[0085] The report text vector in the test set is tensor-decomposed with the second vector of the M parent nodes, and the vector similarity is compared. The first graph attention network and the second graph attention network are optimized to obtain the trained graph attention network model.

[0086] Further, S103: determining the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the chemical accident report to be detected and the trained graph attention network model; specifically including:

[0087] The text vector of the chemical accident report to be detected and the subgraph of the chemical accident report to be detected are input into the trained graph attention network model to obtain the prediction vector of the chemical accident report to be detected;

[0088] Compare the predicted vector of the chemical accident report to be detected with the second vectors of the M parent nodes for similarity, and obtain the accident report type corresponding to the node A with the highest similarity, which is the accident type of the chemical accident report to be detected;

[0089] The text vector of the chemical accident report to be detected is compared with the text vectors of all case nodes under the highest similarity node A to obtain the case type corresponding to the highest similarity case node B, which is the case type of the chemical accident report to be detected.

[0090] By designing a logical graph that describes the evolutionary laws and patterns between events, we can simultaneously consider the logical relationships between events, such as sequence, cause and effect, conditions, and hierarchy, in the process of logical deduction, thus ensuring the accuracy of abnormal event detection.

[0091] Based on the GAT model, we can realize the detection of specific chemical abnormal events and event evolution reasoning, embedding through metadata, and integrate the logical relationship of surrounding events through the GAT deep network model to build an emerging abnormal event detection model.

[0092] For example, the working principle of the first graph attention network is:

[0093] Extract 165 parent nodes from the event graph and the chemical accident cases under these nodes to form 165 subgraphs. Perform GAT operation on each subgraph:

[0094] Assume that a parent node contains N nodes, and the feature vector of each node is hi, and the dimension is F, as shown below:

[0095] h={h1,h2,...,h N}, h1∈R F (1)

[0096] By performing a linear transformation on the node feature vector h, we can obtain a new feature vector h'i with a dimension of F', as shown below. W is the matrix of the linear transformation:

[0097] h i '=Wh i , W∈R F'×F (2)

[0098] h'={h'1,h'2,...,h' N}, h' i ∈R F (3)

[0099] If node j is a neighbor of node i, the Attention mechanism can be used to calculate the importance of node j to node i, that is, the Attention Score:

[0100] e ij =Attention(Wh i ,Wh j ) (4)

[0101]

[0102] The specific approach of GAT's attention is as follows: concatenate the feature vectors h'i and h'j of nodes i and j, and then calculate the inner product with a 2F'-dimensional vector a. The activation function uses LeakyReLU, and the formula is as follows:

[0103]

[0104] The output of K attentions is multiplied by the number of times on the line.

[0105]

[0106] β is the value on the connection line between h1 node and surrounding nodes

[0107] After GAT, a 128-dimensional vector representing 165 nodes on the standard graph is extracted.

[0108] The 128-dimensional vectors of 165 standard nodes generated by the first graph attention network GAT and integrated with the surrounding node information are extracted as the feature vectors of 165 nodes on the concept and reasoning network layer.

[0109] The generated logical graph is processed again by the second graph attention network to generate a new 128-dimensional vector that takes into account the logical relationships between events such as sequence, causality, conditions, and hierarchy.

[0110] For new accident reports, we segment words, remove stop words, and extract stems. For each word, we use word2vec to generate a 128 vector. For a new chemical accident report, we use the average value of the vectors of the words in the text to represent the vector of the new accident report text.

[0111] The vector of the newly generated accident report text is subjected to tensor decomposition with the 165 generated vectors, and a multi-dimensional vector similarity comparison is performed. The resulting loss is then fed back to two layers of GAT to optimize the network.

[0112] Based on the trained model, we predict which node in the standard graph an accident report belongs to. We use similarity calculation: we compare the vector of the new accident report text with all the case nodes under that node. We find the case with the highest degree of match and determine its evolution method.

[0113] Example 2

[0114] This embodiment provides a chemical industry abnormal event detection system based on the event graph;

[0115] The chemical industry abnormal event detection system based on the event graph includes:

[0116] An acquisition module is configured to: acquire a chemical accident report to be detected;

[0117] A preprocessing module is configured to: preprocess the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected;

[0118] A prediction module is configured to: determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the chemical accident report to be detected and the trained graph attention network model;

[0119] Among them, the graph attention network model is obtained based on the training of the event graph.

[0120] It should be noted that the acquisition module, preprocessing module, and prediction module described above correspond to steps S101 to S103 in Example 1. The examples and application scenarios implemented by these modules and the corresponding steps are the same, but are not limited to the contents disclosed in Example 1. It should be noted that the modules described above, as part of a system, can be executed in a computer system, such as a set of computer-executable instructions.

[0121] The descriptions of the various embodiments in the above embodiments have different focuses. For parts not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0122] The proposed system can be implemented in other ways. For example, the system embodiment described above is merely illustrative. For example, the above module division is only a logical function division. In actual implementation, other division methods may be used. For example, multiple modules can be combined or integrated into another system, or some features can be ignored or not implemented.

[0123] Example 3

[0124] This embodiment also provides an electronic device, comprising: one or more processors, one or more memories, and one or more computer programs; wherein the processor is connected to the memory, and the one or more computer programs are stored in the memory. When the electronic device is running, the processor executes the one or more computer programs stored in the memory, so that the electronic device executes the method described in the above embodiment one.

[0125] It should be understood that in this embodiment, the processor may be a central processing unit (CPU), or may be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), off-the-shelf field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.

[0126] The memory may include a read-only memory and a random access memory, and provides instructions and data to the processor. A portion of the memory may also include a non-volatile random access memory. For example, the memory may also store information about the device type.

[0127] During implementation, each step of the above method may be completed by an integrated logic circuit of hardware in a processor or by instructions in the form of software.

[0128] The method in Example 1 can be directly implemented as being executed by a hardware processor, or by a combination of hardware and software modules within the processor. The software module can be located in a storage medium well-established in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. The storage medium is located in the memory, and the processor reads the information in the memory and, in conjunction with its hardware, completes the steps of the above method. To avoid repetition, a detailed description is not given here.

[0129] Those skilled in the art will appreciate that the units and algorithm steps of the various examples described in conjunction with this embodiment can be implemented using electronic hardware or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.

[0130] Example 4

[0131] This embodiment further provides a computer-readable storage medium for storing computer instructions. When the computer instructions are executed by a processor, the method described in the first embodiment is performed.

[0132] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention are intended to be within the scope of protection of the present invention.

Claims

1. A chemical abnormal event detection method based on event graph is characterized by: include: Obtain chemical accident reports for testing; Preprocessing the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected; Determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the report and the trained graph attention network model; The graph attention network model is trained based on the event graph. The process of obtaining the event graph includes: Constructing a training set and a test set; the training set and the test set both include M known accident types and several case types included in each type of accident; According to each accident type and several case types corresponding to each accident type, a subgraph corresponding to each accident type is constructed to obtain the case-reasoning network layer; For all parent nodes, we connect them according to the accident link lines of disaster-causing factors, disaster-bearing bodies, accident types and accident consequences, combined with the causal relationship of accidents and the accident evolution process, to obtain the concept and event network layer; After the case-related network layer and the concept-related network layer are merged, a reasoning graph is obtained; In the process of constructing the subgraph, each accident type is taken as the parent node, and all case types corresponding to the current accident type are taken as child nodes. Connections are made based on whether there is a containment relationship between the parent node and the child node; The trained graph attention network model. The specific training process includes: Obtain M known accident types and several case types contained in each type of accident; where M is a positive integer; Construct a subgraph for each accident type and obtain M subgraphs; Perform vector extraction on the accident report under each accident type to obtain several text vectors; Input the M subgraphs and the corresponding text vectors of each subgraph into the first graph attention network to obtain the first vectors of the M parent nodes; The first vectors of the M parent nodes, the M parent nodes in the concept-event network layer, and the connection relationship between the M parent nodes are input into the second graph attention network to obtain the second vectors of the M parent nodes; The report text vector in the test set is tensor-decomposed with the second vector of the M parent nodes, and the vector similarity is compared. The first graph attention network and the second graph attention network are optimized to obtain the trained graph attention network model.

2. The method for detecting abnormal chemical events based on the event graph according to claim 1, wherein: Preprocessing the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected; Specifically include: Perform word segmentation on chemical accident reports to be tested; Remove stop words from the word segmentation results; Perform stem extraction on the result after removing stop words to obtain several stems; For each extracted stem, generate each stem vector; The average value of all stem vectors is calculated, and the average value is used as the text vector of the chemical accident report to be detected.

3. The method for detecting abnormal chemical events based on the event graph according to claim 1, wherein: The graph attention network model includes: a first graph attention network and a second graph attention network connected in sequence.

4. The method for detecting abnormal chemical events based on the event graph according to claim 1, wherein: Based on the text vector of the chemical accident report to be detected and the trained graph attention network model, the accident type and case type corresponding to the chemical accident report to be detected are determined; specifically, The text vector of the chemical accident report to be detected and the subgraph of the chemical accident report to be detected are input into the trained graph attention network model to obtain the prediction vector of the chemical accident report to be detected; Compare the predicted vector of the chemical accident report to be detected with the M second vectors for similarity, and obtain the accident report type corresponding to the node A with the highest similarity, which is the accident type of the chemical accident report to be detected; The text vector of the chemical accident report to be detected is compared with the text vectors of all case nodes under the highest similarity node A to obtain the case type corresponding to the highest similarity case node B, which is the case type of the chemical accident report to be detected.

5. The chemical abnormal event detection system based on the event graph is characterized by: include: An acquisition module is configured to: acquire a chemical accident report to be detected; A preprocessing module is configured to: preprocess the chemical accident report to be detected to obtain a text vector of the chemical accident report to be detected; A prediction module is configured to: determine the accident type and case type corresponding to the chemical accident report to be detected based on the text vector of the chemical accident report to be detected and the trained graph attention network model; The graph attention network model is trained based on the event graph. The process of obtaining the event graph includes: Constructing a training set and a test set; the training set and the test set both include M known accident types and several case types included in each type of accident; According to each accident type and several case types corresponding to each accident type, a subgraph corresponding to each accident type is constructed to obtain the case-reasoning network layer; For all parent nodes, we connect them according to the accident link lines of disaster-causing factors, disaster-bearing bodies, accident types and accident consequences, combined with the causal relationship of accidents and the accident evolution process, to obtain the concept and event network layer; After the case-related network layer and the concept-related network layer are merged, a reasoning graph is obtained; In the process of constructing the subgraph, each accident type is taken as the parent node, and all case types corresponding to the current accident type are taken as child nodes. Connections are made based on whether there is a containment relationship between the parent node and the child node; The trained graph attention network model. The specific training process includes: Obtain M known accident types and several case types contained in each type of accident; where M is a positive integer; Construct a subgraph for each accident type and obtain M subgraphs; Perform vector extraction on the accident report under each accident type to obtain several text vectors; Input the M subgraphs and the corresponding text vectors of each subgraph into the first graph attention network to obtain the first vectors of the M parent nodes; The first vectors of the M parent nodes, the M parent nodes in the concept-event network layer, and the connection relationship between the M parent nodes are input into the second graph attention network to obtain the second vectors of the M parent nodes; The report text vector in the test set is tensor-decomposed with the second vector of the M parent nodes, and the vector similarity is compared. The first graph attention network and the second graph attention network are optimized to obtain the trained graph attention network model.

6. An electronic device, comprising: a memory for non-transitory storage of computer-readable instructions; as well as a processor for executing said computer-readable instructions, When the computer-readable instructions are executed by the processor, the method according to any one of claims 1 to 4 is executed.

7. A storage medium, characterized in that: Computer-readable instructions are non-transitory stored, wherein when the non-transitory computer-readable instructions are executed by a computer, the instructions of the method according to any one of claims 1 to 4 are executed.

Citation Information

Patent Citations

  • Reason mapping knowledge domain construction method and system

    CN108052576A

  • Logic map construction and early warning method and device based on cause recommendation

    CN110968699A

  • Fusion map-based prediction method and device, electronic equipment and storage medium

    CN111914569A