Accident scene reasoning method and device
By extracting and integrating causal mentions from historical data, a generalized causal event network is formed, which solves the problems of inefficient reasoning and low accuracy in accident scenario reasoning, and achieves more efficient and accurate accident scenario reasoning.
Patent Information
- Application Number
- CN202411976394.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-05-02
- Estimated Expiration
- 2044-12-31
AI Technical Summary
In the prior art, the inference efficiency and accuracy of the inference process of accident scenario in the process of accident scenario reasoning are inefficient and the accuracy rate is low, which limits the practical application of accident scenario reasoning.
By extracting causal mentions from historical data, a causal mention data set is constructed and parsed into causal events. Then, a common causal event is integrated based on causal events to form a generalized causal event network, which is used to reason about analytical accidents.
The efficiency and accuracy of accident scenario reasoning have been improved, and a useful tool can be formed to predict future accidents have been overcome, and the problems of inefficient and low accuracy in the existing technology have been overcome.
Smart Images

Figure CN119918665A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information processing, and in particular to a reasoning method and device based on accident scenarios. Background Art
[0002] Accident scenario reasoning is a complex and evolving field that involves the analysis, simulation, and prevention of accidents. The conventional reasoning method is case-based reasoning, which mainly uses historical cases to guide emergency decision-making and has important application prospects for emergency response. However, China currently lacks a complete emergency case library. Most cases are manually organized and scattered in different departments, resulting in low reasoning efficiency and accuracy, which limits the practical application of accident scenario reasoning. These technologies and problems show that accident scenario reasoning methods are constantly developing, but also face many challenges, which require further research and innovation to overcome these problems. Summary of the invention
[0003] The present invention provides a reasoning method and device based on accident scenarios, which are used to solve the problems of low reasoning efficiency and low accuracy in the accident scenario reasoning process in the prior art.
[0004] The present invention provides a method for reasoning about an accident scenario, the method comprising:
[0005] Extracting causal relationship mentions from historical data and constructing a causal relationship mention dataset; the historical data records the cause events and result events of historical accidents; the causal relationship mentions represent text containing causal relationship pairs; the causal relationship pairs include: related cause events and result events;
[0006] parsing the causal mentions in the causal mention dataset into causal events;
[0007] Based on the causal events, at least two causal events having commonality are integrated to form a generalized causal event network;
[0008] Reasoning is performed on the accident to be analyzed based on the generalized causal event network.
[0009] Optionally, extract causal mentions from historical data including:
[0010] Identify causal connectives in historical data;
[0011] Extracting the cause event and result event associated with the causal relation connective based on the causal relation connective;
[0012] Causal mentions are obtained based on the cause event, the causal connective, and the effect event.
[0013] Optionally, parsing the causal relationship mention into a causal event includes:
[0014] Selecting a causal relationship template based on the causal relationship mentions data features that determine the causal relationship; the causal relationship template represents a grammatical format for describing the causal relationship;
[0015] The causal mentions are parsed into the causal events based on the causal template.
[0016] Optionally, based on the causal events, integrating at least two causal events having commonality to form a generalized causal event network includes:
[0017] calculating the similarity of at least two of the causal events;
[0018] When the similarity is greater than a preset threshold, integrating the two groups of causal events into a generalized causal event;
[0019] The generalized causal events are mapped to the generalized causal event network.
[0020] Optionally, before calculating the similarity of at least two groups of causal events, the method further includes:
[0021] Each of the causal events is vectorized to generate a feature vector of the causal event.
[0022] Optionally, reasoning about the accident to be analyzed based on the generalized causal event network includes:
[0023] Constructing a graph neural network based on the generalized causal event network;
[0024] Taking the feature vector of each causal event as the node attribute of each node in the graph neural network;
[0025] The number of times the two nodes appear at the same time is used as an edge attribute in the graph neural network;
[0026] An accident prediction model is constructed based on the node attributes and edge attributes to reason about the accident to be analyzed.
[0027] Optionally, the method further includes:
[0028] Construct a training set and a test set based on the first graph structure data;
[0029] Consider the edges in the first graph structure data as positive samples;
[0030] For each edge’s cause node, multiple non-existent edges are sampled in the training set and test set as negative samples;
[0031] Establishing a model consisting of two layers of GraphSAGE based on the first graph structure data corresponding to the positive samples in the training set, and calculating the first possibility score of the existence of edges between the positive sample nodes;
[0032] Calculate the second likelihood score of the non-existence of edges between negative sample nodes;
[0033] The accident prediction model is evaluated based on the first likelihood score and the second likelihood score.
[0034] Optionally, the method further includes:
[0035] The accident prediction model is optimized by using a cross entropy loss function and a marginal loss function.
[0036] The present invention provides an inference device for an accident scene, the device comprising:
[0037] A construction unit is used to extract causal relationship mentions from historical data and construct a causal relationship mention dataset; the historical data records the cause events and result events of historical accidents; the causal relationship mentions represent text containing causal relationship pairs; the causal relationship pairs include: related cause events and result events;
[0038] A parsing unit, configured to parse the causal relationship mentions in the causal relationship mention dataset into causal events;
[0039] A generalization unit, configured to integrate at least two causal events having commonality based on the causal events to form a generalized causal event network;
[0040] The reasoning unit is used to reason about the accident to be analyzed based on the generalized causal event network.
[0041] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement any of the methods described above.
[0042] The accident scenario reasoning method constructed by the present invention can mine valuable causal knowledge from a large number of English accident reports and form a useful tool that can predict future accidents. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 is a flow chart of a reasoning method for an accident scenario in an embodiment of the present invention;
[0044] Figure 2 It is a generalized causal event network construction diagram in an embodiment of the present invention;
[0045] Figure 3It is a generalized causal event network construction diagram in an embodiment of the present invention;
[0046] Figure 4 It is a schematic diagram of establishing a model composed of two layers of GraphSAGE in an embodiment of the present invention;
[0047] Figure 5 is a schematic diagram of the structure of a reasoning device for an accident scenario in an embodiment of the present invention;
[0048] Figure 6a and 6b They are schematic diagrams of model performance evaluation indicators based on the cross entropy loss function and the marginal loss function in embodiments of the present invention. DETAILED DESCRIPTION
[0049] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. It should also be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.
[0050] The specific embodiment of the present invention provides a method for reasoning about an accident scenario, such as Figure 1 As shown, the method includes:
[0051] Step 100, extract causal mentions from historical data and construct a causal mention dataset; the historical data records the cause events and result events of historical accidents; the causal mentions represent texts containing causal pairs; the causal pairs include: related cause events and result events. Specifically, the accident scenario inference of the embodiment of the present invention is based on the constructed accident scenario inference model (ASIM), wherein the historical data comes from English accident reports, wherein the cause events and result events of historical accidents are recorded in English, a cause event and a corresponding result event can form a causal pair, and the causal text pair is the causal mention. For example, "liquefiedammonia[causes]frostbite on contact (contact with liquid ammonia [cause] frostbite)" is a typical causal mention, which contains the causal pair "liquefiedammonia (contact with liquid ammonia) → frostbite on contact (frostbite)", wherein [causes] is a causal conjunction. This step can extract all causal mentions from the historical data and form a causal mention dataset. Among them, this step is to extract the causal relationship mentioned in a single complete sentence, rather than the causal relationship implicit in multiple sentences.
[0052] Step 200, parse the causal mentions in the causal mention dataset into causal events. The causal mentions extracted in step 100 are not convenient for storage, retrieval and application, so the second task of the ASIM method is to further parse the extracted causal mentions into specific causal events and simplify them to store accident information more concisely and effectively. Specifically, causal events are causal mentions expressed in a concise and effective way.
[0053] Step 300, based on the causal events, at least two causal events with commonality are integrated to form a generalized causal event network. Among them, the embodiment of the present invention mines the causal relationship between specific events, but it is still not convenient to explore the deeper and common causal laws behind a large number of historical accidents, nor is it conducive to practical application. Therefore, a generalized causal event network is also constructed to more conveniently guide accident prevention and safety decision-making.
[0054] Step 400, reasoning about the accident to be analyzed based on the generalized causal event network. After the generalized causal event network is constructed, being able to predict future accident scenarios is the ultimate goal of the ASIM model. After the ASIM model is constructed by machine learning in a specific embodiment of the present invention, reasoning about the accident to be analyzed is performed.
[0055] The accident scenario reasoning method constructed by the embodiment of the present invention can mine valuable causal knowledge from a large number of English accident reports and form a useful tool that can predict future accidents.
[0056] The accident scenario reasoning method described in the embodiment of the present invention preferably extracts causal relationships from historical data and includes:
[0057] Determine causal connectives in historical data. Comprehensively and systematically extracting high-quality causal mentions from a large number of English accident reports is the primary task of the accident scenario reasoning model. However, it is almost impossible to extract all causal mentions from a large number of English reports through manual analysis. Therefore, in the embodiment of the present invention, a machine learning method is used based on rules to efficiently identify and extract causal mentions in the text. Specifically, causal connectives refer to words or phrases used to connect cause events and result events in accident records. For example, "because", "because of", "lead to" and "after" are four common causal connectives, accounting for more than 80% of all connectives. On this basis, the connectives are expanded to make them more suitable for application in the accident analysis process. For example, in accident reports, when describing changes in temperature, pressure and liquid level in chemical accidents, words such as "increases" and "decreasing" often appear to illustrate the causal relationship between chemical substances, reactions and states.
[0058] Based on the causal connectives, the cause events and result events associated with them are extracted. Below are two examples of causal mentions, with the causal connectives in bold:
[0059]
[0060] In addition, “the / a result of”, “result in”, “due to”, “lead to” and “creating” can also be determined as causal connectives. The embodiment of the present invention lists 12 causal connectives as shown in Table 1.
[0061] The causal relationship mentions are obtained based on the cause event, the causal relationship connective and the result event.<Pattern,Constraint> The template formulates the extraction rules of causal mentions for each connective. Specifically, the Pattern in the template refers to the regular expression containing the causal connective, and the Constraint is the grammatical constraint. For example, for the causal connective "cause", its causal mention Pattern (regular expression) is designed as "[sentence1][caus\S+][sentence2]", where [sentence1] is the cause event, [sentence2] is the result event, and the regular expression [caus\S+] is used to match different forms of "cause", such as "causes" and "cause". In addition, since the last five letters of "cause" and "because" are the same, in order to avoid matching the text fragment containing "because", the Constraint stipulates that the previous position of the matched "cause" must be a space instead of a letter. Using this customized template, you can quickly identify all causal pairs connected by "cause". The following are two examples.
[0062]
[0063] The rules for mentioning causal connectives and should relations are shown in Table 1, where sentences marked in bold are cause events, and sentences not marked in bold are result events.
[0064] Table 1 Causal connectives and causal mention rules
[0065]
[0066]
[0067] The method described in the above embodiment can efficiently and accurately extract causal relationship mentions from English accident reports.
[0068] The inference method of the accident scene described in the embodiment of the present invention preferably includes: parsing the causal relationship into causal events:
[0069] A causal relationship template is selected based on the causal relationship mentioning data features that determine the causal relationship; the causal relationship template represents a grammatical format for describing the causal relationship.
[0070] The causal mentions are parsed into the causal events based on the causal template.
[0071] Specifically, the causal relationship templates include at least the following three types: (1) <subject-predicate-object> tuples; (2) noun phrase sets; and (3) verb and noun sets. These three causal relationship templates are suitable for different data features. First, for verb and noun sets, the method aims to abstractly represent a specific event as a set of verbs and nouns. For example, the causal relationship mention "a BLEVE cause the tank's failure" can be represented as a verb and noun set {BLEVE, cause, tank, failure}. For concise text descriptions, such as news headlines, they can be represented as a set of verbs and nouns. For example, in the causal relationship mention "The vapor ignited, [creating] an explosion", the cause event "The vapor ignited" and the result event "explosion" can be clearly represented in the form of verb and noun sets as {vapor, ignited} and {explosion}, and the causal relationship can be represented as {vapor ignited}→{explosion}.
[0072] However, for a complex sentence like "This process greatly compounded the total amount of explosive energy within each box", abstractly representing it as a set of verbs and nouns will increase the difficulty of understanding it and even introduce irrelevant information interference. In this case, it is a better choice to extract the subject, predicate, and object of the sentence according to the syntactic structure of the sentence. The syntactic structure of the sentence contains the nominal subject "process", the direct object "amount", the indirect objects "energy" and "box", and the predicate verb "compounded". Therefore, this sentence can be concisely represented as {process, compounded, amount, energy} using the <subject-predicate-object> tuple. It can also be represented as {this process, the total amount, explosive energy, each box} using a set of noun phrases.
[0073] Accident reports often contain both simple and complex sentences. Using a single method to represent causal events may lose key accident information. Therefore, the embodiment of the present invention uses these three causal relationship templates to represent causal events, which can help researchers better utilize and understand accident information.
[0074] The accident scenario reasoning method described in the embodiment of the present invention preferably integrates at least two common causal events to form a generalized causal event network based on the causal event, including:
[0075] calculating the similarity of at least two of the causal events;
[0076] When the similarity is greater than a preset threshold, integrating the two groups of causal events into a generalized causal event;
[0077] The generalized causal events are mapped to the generalized causal event network.
[0078] Specifically, the specific causal relationship pairs such as "miscommunication between the two shift supervisors→the unsafe use of steam in the reactor vessel" are converted into a more generalized representation: "miscommunication→unsafe use". Obviously, the latter is a more concise causal knowledge. This generalized causal information is conducive to discovering the deeper and more common laws hidden behind specific causal events. For example, Figure 2 As shown in the figure, events such as {lack, communication}, {supervisor, miscommunication}, and {communication, cease} can all be generalized to {lack, communication}. The red nodes represent specific events, and the directed arrows point from the cause events to the result events. The dotted lines are the conversion process from specific events to generalized events (blue nodes).
[0079] The accident scenario reasoning method described in the embodiment of the present invention preferably further comprises:
[0080] Each of the causal events is vectorized to generate a feature vector of the causal event. Specifically, in order to identify and integrate highly similar causal events, it is necessary to quantize each causal event and characterize it in the form of a feature vector. At the same time, the quantization process of the causal event should retain the original event information as much as possible. Traditional text mining models usually use One-Hot encoding or TF-IDF to calculate text similarity, ignoring context information, which may lead to the loss of key information. The embodiment of the present invention adopts a word vector representation model, which converts words into vectors of fixed dimensions and then calculates the similarity between words. The model maps semantically similar words in an embedding space so that the word vector contains context information. The model has the advantages of fast calculation speed and high accuracy. In addition, it is specifically divided into two models: Skip-gram and CBOW. Compared with Skip-gram, CBOW requires less training time and is more suitable for processing large amounts of text data. Preferably, the embodiment of the present invention calculates word vectors based on the CBOW model.
[0081] The corpus of the embodiment of the present invention includes 1175 accident reports from the eMARS database and 100 accident reports from the CSB website. First, these accident reports are processed sentence by sentence using a regular expression based on the Python language, and useless characters and stop words are removed to obtain a corpus containing 73075 English sentences. The corpus is then input into Word2vec for modeling, and each word in the corpus is finally represented by a 300-dimensional vector, as shown in Equations 1 and 2. Each specific causal event consists of a series of words. Therefore, the feature vector of the causal event is defined as Equation 3, and the similarity of two causal events is defined as Equation 4.
[0082] Corpus=[W1,W2,W3,…,W n ] (1)
[0083] W=[x1,x2,x3,…,x 300 ] (2)
[0084]
[0085] In the formula, Corpus represents a corpus containing n words, W is the word vector, and S j is the feature vector of the jth causal event, X j,i is the i-th value in the feature vector of the j-th causal event. j,k For S j With S k The similarity of , that is, the feature vector S j With the eigenvector S kThe cosine value of the angle. The closer the cosine value is to 1, the smaller the angle between the two vectors is, indicating that the two events are more similar, so as to calculate the similarity of the two causal events.
[0086] Specifically, the preset threshold is 0.95. For causal event pairs with similarity greater than 0.95, the causal event with a shorter tuple length is replaced by the causal event with a longer tuple length to generalize it. Finally, multiple generalized causal events construct a generalized causal event network, which consists of nodes (i.e., causal events) and directed edges (i.e., causal relationships between causal events).
[0087] The accident scenario reasoning method described in the embodiment of the present invention preferably includes: reasoning about the accident to be analyzed based on the generalized causal event network:
[0088] Constructing a graph neural network based on the generalized causal event network;
[0089] Taking the feature vector of each causal event as the node attribute of each node in the graph neural network;
[0090] The number of times the two nodes appear at the same time is used as an edge attribute in the graph neural network;
[0091] An accident prediction model is constructed based on the node attributes and edge attributes to reason about the accident to be analyzed.
[0092] After constructing the generalized causal event network, the ultimate goal of the ASIM model is to predict future accident scenarios. Similar to social networks and knowledge graphs, generalized causal event networks are typical graph structure data. This type of data consists of nodes and edges and is used to describe the internal structure of complex systems, such as Figure 2 However, compared with structured data, the processing and analysis of graph data is more complicated, and the scale of the graph (i.e., the number of nodes and edges) may be very large, so traditional machine learning is difficult to efficiently identify potential patterns and features in graph data.
[0093] The embodiment of the present invention uses a graph neural network (GNN) to process graph structure data, that is, by modeling the information transmission mechanism between nodes in the knowledge network, the possibility of predicting the existence of a causal relationship between nodes. Among them, the graph sample and aggregate network (GraphSAGE) is one of the classic GNN algorithms, which is suitable for learning information propagation mechanisms from complex networks. The algorithm generates new node embeddings by aggregating adjacent node information (i.e., feature vectors). The prediction tasks based on GraphSAGE include node classification, edge classification, and link prediction (i.e., predicting whether there is a relationship between two nodes). Therefore, a specific embodiment of the present invention uses a causal event network and the GraphSAGE algorithm to construct an accident prediction model. The model is used to predict whether there is an edge between two specific nodes (i.e., whether there is a causal relationship between two events) and reveal the possible development trend of the accident.
[0094] Specifically, the generalized causal event network (graph structure data) is recorded as G = (V, E), where V is the node set and E is the edge set. In the edge set E, c and e represent two nodes, and (c, e) represents a directed edge connecting node c and node e, which means that there is a causal relationship between the two nodes. Figure 3 As shown in Figure 1, the feature vector of each event is used as the node attribute, and the co-occurrence frequency of two nodes is used as the edge attribute, that is, the number of times they appear at the same time, which can characterize the strength of the relationship between the two nodes.
[0095] Preferably, when constructing a generalized causal event network, the causal relationship template will be further integrated. Specifically, the <subject-verb-object> tuple method is first used to detect whether a sentence of a causal event contains a subject, a predicate, and an object. If so, the <subject-verb-object> tuple is preferentially used to represent the event; otherwise, a verb and noun set will be used.
[0096] The reasoning method of the accident scenario described in the embodiment of the present invention is preferably that the accident prediction model constructed by the present invention is essentially a link prediction task based on GNN, which aims to infer whether there is a causal relationship between two nodes in the graph. Specifically, it is constructed with the help of the deep graph library (DGL) based on pytorch. The specific construction method includes:
[0097] A training set and a test set are constructed based on the first graph structure data. The first graph structure is divided into a training set and a test set according to a certain ratio.
[0098] Consider the edges in the first graph structure data as positive samples;
[0099] For each edge cause node, multiple non-existent edges (i.e., no edges between nodes) are sampled in the training set and the test set as negative samples. Then, each existing edge (c, e) has k negative samples (c, e <negative,i> ).
[0100] A model consisting of two layers of GraphSAGE is established based on the first graph structure data corresponding to the positive samples in the training set, and the first possibility score of the existence of edges between the positive sample nodes is calculated according to the following formula 5. The establishment of the model includes the following four steps: Figure 4 As shown in the figure: a. Input the first graph structure data with node attributes and edge attributes; b. For each node, sample the neighbor samples with a depth of 2; c. Aggregate the green node information to the blue node; d. Aggregate the red node information to the green node, update the embedding of the green node, and then update the embedding of the blue node again.
[0101] Calculate negative samples (c,e <negative,i> ) The second likelihood score when there is no edge between the nodes.
[0102] The accident prediction model is evaluated based on the first possibility score and the second possibility score. Specifically, based on the test set, the model is evaluated using the Area Under Curve (AUC) indicator. For a specific node pair, if the score of the existing edge is greater than the score of all non-existent edges, add 1; if the score of the existing edge is equal to the maximum score of all non-existent edges, add 0.5; otherwise, add 0. After n iterations (i.e., n existing edges), n1 represents the number of the first case, n2 represents the number of the second case, and the obtained model performance AUC is shown in Formula 8.
[0103]
[0104] The accident scenario reasoning method described in the embodiment of the present invention preferably further includes:
[0105] The accident prediction model is optimized by using a cross entropy loss function and a marginal loss function.
[0106] In order to make the scores of existing edges higher than those of all non-existent edges, two loss functions are used to update and optimize the model, such as
[0107] The cross entropy loss function of formula 6 and the marginal loss function of formula 7.
[0108]
[0109] In the formula, S' c and S' e are the embeddings of nodes c and e calculated based on the GraphSAGE model; yc,e is the score of the existence of edge (c,e), that is, S' c and S' e The dot product of i is the negative sample node of the cause node c, P n (e) is the negative sample distribution, is a negative sample edge (c,e i ), k is the number of negative sample nodes, and M is a constant hyperparameter.
[0110] The embodiment of the present invention also provides an inference device for an accident scene, such as Figure 5 As shown, the device comprises:
[0111] A construction unit 501 is used to extract causal relationship mentions from historical data and construct a causal relationship mention dataset; the historical data records the cause events and result events of historical accidents; the causal relationship mentions represent text containing causal relationship pairs; the causal relationship pairs include: related cause events and result events;
[0112] A parsing unit 502, configured to parse the causal relationship mentions in the causal relationship mention dataset into causal events;
[0113] A generalization unit 503, configured to integrate at least two causal events having commonality based on the causal events to form a generalized causal event network;
[0114] The reasoning unit 504 is used to reason about the accident to be analyzed based on the generalized causal event network.
[0115] To verify the practicality of the ASIM model, the embodiment of the present invention also models 100 accident reports from the CSB website of the United States. In addition, the accident process of the "2.11" Huludao explosion in China was deduced using the established model, verifying the model's ability to predict unknown accidents.
[0116] Specifically, the ASIM method was constructed to analyze 100 major chemical accident reports from the US CSB. These chemical accidents occurred between 1998 and 2022. As shown in Table 2, the length of the relevant accident reports ranged from dozens to hundreds of pages, containing rich accident details. In addition, the recording format and style of these reports were relatively uniform, which was conducive to the development of this study.
[0117] The accident report contents covered in the analysis process include modules such as factual information, accident description, accident analysis, conclusions, and key lessons, while the appendices and recommendations in each report were excluded from this analysis. The results show that a total of 3558 causal relationship mentions were extracted using 12 causal connectives. The distribution of the extracted causal relationship mentions is shown in Table 3.
[0118] Table 2. Collected CSB reports
[0119]
[0120] Table 3 Distribution of extracted causal relationship mentions
[0121]
[0122]
[0123] Using three types of causal relationship templates, namely, verb + noun set, <subject-predicate-object> tuple, and noun phrase set, the 3558 causal relationship mentions were further parsed into causal events. Finally, 5855 causal events and 3558 causal relationship pairs were obtained. These causal events can be stored in the information database of causal events to prepare for the generalization and prediction of subsequent causal events. The storage format of causal events is shown in Table 4-4, which contains causal relationship templates. For example, the causal event "Managers ordered a total refinery evacuation, after the fire erupted" can be represented by three representation methods: (1) {fire, erupted} → {managers, order, refinery, evacuation}; (2) {fire, erupted} → {managers, ordered, evacuation}; (3) {the fire} → {managers, a total refinery evacuation}. However, different representation methods are suitable for different events, so the next step is to optimize the event representation.
[0124] Table 4 Example of causal event representation
[0125]
[0126] All causal events are represented in a generalized form. First, the original text of each causal event is judged to see if it contains a <subject-predicate-object> structure; if so, the <subject-predicate-object> template is used to abstractly represent the event; otherwise, a verb+noun set is used to represent it. Second, all words are rooted to avoid different forms of the same word affecting the performance of the model (for example, "ignition", "ignited" and "ignites" are all replaced by "ignite"). Third, the feature vectors of the causal events are used to calculate the similarity between the two causal events, and the events with similarity greater than 0.95 are further integrated. As a result, 4982 generalized causal events and 3249 causal event pairs are obtained. In addition, these generalized causal events and causal relationships are mapped into the vector space to form a generalized causal event network. The generalized causal event network is used to reveal some key event categories and their distribution. In this network, all data are stored in the form of nodes (i.e., causal events) and directed edges (i.e., causal relationships). Table 5 shows some high-frequency event chains.
[0127] Table 5 High frequency event chains
[0128]
[0129] The prediction model is trained from the established generalized causal event network. The generalized causal event network consists of nodes and edges with feature vectors. In short, the prediction model aims to learn the influence mechanism or information propagation pattern between these nodes. Therefore, when a new event is input into the trained model, the most likely subsequent events caused by the event can be inferred. In this empirical study, the dataset is divided into training set and test set in a ratio of 9:1. Using the evaluation index shown in Equation 8, the model performance based on the cross entropy loss function and the marginal loss function is as follows: Figure 6a and 6b As shown in the figure. The higher the AUC value, the better the model performance.
[0130] Since this model is built based on English accident reports, in order to verify the practicality and generalizability of the inference model, the "2.11" Huludao explosion accident in China was taken as an example to verify the inference process and accuracy of the model. According to the Chinese records of the "2.11" Huludao explosion accident, they were first translated into English expressions, and the event chain of the explosion accident (consisting of seven basic events) was constructed through manual analysis. Then, the initial event of the Huludao explosion accident "In the clethodim workshop, an operator did not check and confirm the materials" was input into the model to predict the five most likely subsequent events. Subsequently, the five predicted events were compared with the actual accident chain, and the event closest to the actual situation was used as the input for the next prediction. After six predictions, the inference model generated a set of potential accident scenarios based on the initial event. Among the constructed potential accident scenarios, there is an event chain consistent with the actual accident. As expected, after six predictions using the prediction model, each time, an event close to the actual situation (i.e., one of the five most likely events) was accurately predicted. More importantly, the prediction results of the model provide more potential accident paths, which has important implications for safety management and accident prevention practices.
[0131] An embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement any of the methods described above.
[0132] It should be understood that in the various embodiments of this document, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this document.
[0133] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0134] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0135] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0136] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0137] The foregoing description of specific exemplary embodiments of the present invention is for the purpose of illustration and demonstration. These descriptions are not intended to limit the present invention to the precise form disclosed, and it is clear that many changes and variations can be made based on the above teachings. The purpose of selecting and describing the exemplary embodiments is to explain the specific principles of the present invention and its practical application, so that those skilled in the art can realize and utilize various different exemplary embodiments of the present invention and various different selections and changes. The scope of the present invention is intended to be limited by the claims and their equivalents.
Claims
1. A method for reasoning about an accident scenario, characterized in that: The method comprises: Extracting causal relationship mentions from historical data and constructing a causal relationship mention dataset; the historical data records the cause events and result events of historical accidents; the causal relationship mentions represent text containing causal relationship pairs; the causal relationship pairs include: related cause events and result events; parsing the causal mentions in the causal mention dataset into causal events; Based on the causal events, at least two causal events having commonality are integrated to form a generalized causal event network; Reasoning is performed on the accident to be analyzed based on the generalized causal event network.
2. The accident scene reasoning method according to claim 1, characterized in that: Extracting causal relationships from historical data mentions include: Identify causal connectives in historical data; Extracting the cause event and result event associated with the causal relation connective based on the causal relation connective; Causal mentions are obtained based on the cause event, the causal connective, and the effect event.
3. The accident scene reasoning method according to claim 1, characterized in that: Parsing the causal mentions into causal events includes: Selecting a causal relationship template based on the causal relationship mentions data features that determine the causal relationship; the causal relationship template represents a grammatical format for describing the causal relationship; The causal mentions are parsed into the causal events based on the causal template.
4. The accident scene reasoning method according to claim 1, characterized in that: Based on the causal events, integrating at least two causal events having commonality to form a generalized causal event network includes: calculating the similarity of at least two of the causal events; When the similarity is greater than a preset threshold, integrating the two groups of causal events into a generalized causal event; The generalized causal events are mapped to the generalized causal event network.
5. The accident scene reasoning method according to claim 4, characterized in that: Before calculating the similarity of at least two groups of causal events, the method further includes: Each of the causal events is vectorized to generate a feature vector of the causal event.
6. The accident scene reasoning method according to claim 5, characterized in that: Reasoning about the accident to be analyzed based on the generalized causal event network includes: Constructing a graph neural network based on the generalized causal event network; Taking the feature vector of each causal event as the node attribute of each node in the graph neural network; The number of times the two nodes appear at the same time is used as an edge attribute in the graph neural network; An accident prediction model is constructed based on the node attributes and edge attributes to reason about the accident to be analyzed.
7. The accident scene reasoning method according to claim 6, characterized in that: The method further comprises: Construct a training set and a test set based on the first graph structure data; Consider the edges in the first graph structure data as positive samples; For each edge’s cause node, multiple non-existent edges are sampled in the training set and test set as negative samples; Establishing a model consisting of two layers of GraphSAGE based on the first graph structure data corresponding to the positive samples in the training set, and calculating the first possibility score of the existence of edges between the positive sample nodes; Calculate the second likelihood score of the non-existence of edges between negative sample nodes; The accident prediction model is evaluated based on the first likelihood score and the second likelihood score.
8. The accident scene reasoning method according to claim 7, characterized in that: The method further comprises: The accident prediction model is optimized by using a cross entropy loss function and a marginal loss function.
9. An inference device for accident scenes, characterized in that: The device comprises: A construction unit is used to extract causal relationship mentions from historical data and construct a causal relationship mention dataset; the historical data records the cause events and result events of historical accidents; the causal relationship mentions represent text containing causal relationship pairs; the causal relationship pairs include: related cause events and result events; A parsing unit, configured to parse the causal relationship mentions in the causal relationship mention dataset into causal events; A generalization unit, configured to integrate at least two causal events having commonality based on the causal events to form a generalized causal event network; The reasoning unit is used to reason about the accident to be analyzed based on the generalized causal event network.
10. A computer-readable storage medium storing one or more programs, wherein the one or more programs can be executed by one or more processors to implement the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Aviation safety accident causal relationship extraction method
CN109871955A
Emotion reason mining method based on dependency syntax and generalized causal network
CN110781369A
Accident causal reasoning method and device, electronic equipment and readable storage medium
CN113657599A
Method and system for constructing hazardous chemical accident atlas
CN115221332A
Event atlas construction reasoning method and device based on statement similarity
CN115269780A
Cited By
Generative adversarial network-based event causal relationship identification method
CN121683891A
Event causal relationship identification method based on generative adversarial network
CN121683891B