Knowledge graph-based security boundary identification method and device, medium and product

Through the safety boundary identification method based on the knowledge graph, the problem of inaccurate and difficult integration of safety boundary identification in rail transit is solved, and the identification of dynamic safety boundaries and the improvement of train operation safety is achieved.

CN119646233AActive Publication Date: 2025-03-18BEIJING JIAOTONG UNIV +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411603644.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-11
Publication Date
2025-03-18
Estimated Expiration
2044-11-11

AI Technical Summary

Technical Problem

In the field of rail transit, the automation level of train control systems has been continuously improved, resulting in changes in safety boundaries. It is difficult for existing technology to achieve accurate and dynamic safety boundary identification, affecting the safety of train operations.

Method used

The safety boundary identification method based on the knowledge graph is adopted, and the knowledge graph is constructed to identify the safety boundary of the train control system through the steps of obtaining hazard source logs, text extraction, knowledge extraction, knowledge fusion and logical relationship inversion.

Benefits of technology

Effectively support the identification of dynamic safety boundaries, improve the safety of train operations, eliminate the problem of information fragmentation, and achieve accurate and comprehensive identification of entities, relationships and attributes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119646233A_ABST
    Figure CN119646233A_ABST
Patent Text Reader

Abstract

The invention discloses a safety boundary identification method and device based on a knowledge graph, a medium and a product, and relates to the technical field of train operation safety protection in rail transit, and the method comprises the steps: obtaining a dangerous source log, and carrying out the text extraction, and obtaining a dangerous event database; performing knowledge extraction on the dangerous event database by utilizing a knowledge extraction model to obtain a triple table comprising entities, relationships and attributes; the knowledge extraction model comprises a pre-training language unit, a bidirectional long-short-term memory network unit and a conditional random field unit; performing knowledge fusion operation and knowledge processing operation on the triple table to obtain a knowledge graph; and performing logical relation negation on the knowledge graph to obtain the safety boundary of the train control system. By introducing the knowledge graph technology, the defect that in the prior art, identification of the safety boundary is not accurate is overcome, identification of the dynamic safety boundary can be effectively supported, and therefore the safety of train operation is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of train operation safety protection in rail transit, and in particular to a knowledge graph-based safety boundary identification method, equipment, medium and product. Background Art

[0002] In the field of rail transit, the key to ensuring the safety of train operation lies in the constraints on train safety behaviors. This constraint is reflected in the design of the train control system. The definition of its functional safety availability is crucial to ensuring the safety of train operation, and is usually guaranteed in the form of contract management. In this process, there are two main sources of information involved; on the one hand, the information is recorded in detail in the system safety constraint document, and on the other hand, the information is reflected in the hazard source log. However, since this information is described in natural language, there are problems of incomplete, non-standard and inaccurate descriptions, which may lead to misunderstandings among technicians, thus affecting the safety of train operation.

[0003] In addition, in the evolution of train control systems, the level of automation continues to improve, and the system functions and structures continue to change, resulting in changes in the corresponding safety boundaries, which may break through the static safety boundaries defined in the form of traditional train control system documents. Therefore, in order to adapt to the evolution of train control systems, it is necessary to adopt dynamic safety boundary protection technology, that is, to monitor the safety boundary parameters of the system in real time and select appropriate control strategies. However, the first step to achieve this goal is to fully identify the safety boundary.

[0004] In summary, train operation safety protection requires comprehensive identification of safety boundaries. However, the current identification process of safety boundaries mostly remains at the level of natural language description and manual experience. There are problems such as inaccurate identification of safety boundaries and difficulty in integration. The retained information is seriously fragmented, and there is a lack of effective tools and technologies for parametric identification of safety boundaries. Summary of the invention

[0005] The purpose of this application is to provide a security boundary identification method, equipment, medium and product based on knowledge graph, which can effectively support the identification of dynamic security boundaries and solve the problem of inaccurate analysis results and difficult integration of security boundaries.

[0006] To achieve the above objectives, this application provides the following solutions:

[0007] In a first aspect, the present application provides a security boundary identification method based on a knowledge graph, comprising:

[0008] Obtaining a hazard source log, and performing text extraction on the hazard source log to obtain a hazard event database; the hazard source log is a text recording hazard events;

[0009] Using a knowledge extraction model, knowledge is extracted from the dangerous event database to obtain a triple table including entities, relationships and attributes; the knowledge extraction model includes a pre-trained language unit, a bidirectional long short-term memory network unit and a conditional random field unit;

[0010] Performing knowledge fusion operations and knowledge processing operations on the triple table to obtain a knowledge graph;

[0011] Reversing the logical relationship of the knowledge graph to obtain the safety boundary of the train control system;

[0012] The determination process of the knowledge extraction model is as follows:

[0013] Based on the safety boundary ontology model of the train control system, the historical text data set is annotated to obtain a historical sample data set; the safety boundary ontology model of the train control system is used to define entities, relations and attributes in the train control system; the historical sample data set includes multiple sample data; the sample data includes historical text data and corresponding label data; the historical text data is historical dangerous event data, and the label data is entities, relations and attributes;

[0014] Construct a knowledge extraction network;

[0015] Based on the historical sample data set, the knowledge extraction network is trained to obtain the knowledge extraction model.

[0016] In a second aspect, the present application provides a computer device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement one of the above-mentioned security boundary identification methods based on a knowledge graph.

[0017] In a third aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements one of the above-mentioned security boundary identification methods based on a knowledge graph.

[0018] In a fourth aspect, the present application provides a computer program product, including a computer program, which, when executed by a processor, implements one of the above-mentioned security boundary identification methods based on the knowledge graph.

[0019] According to the specific embodiments provided in this application, this application discloses the following technical effects:

[0020] The present application provides a method, device, medium and product for safety boundary identification based on knowledge graph, the method comprising: obtaining a hazard source log and performing text extraction to obtain a hazard event database; using a knowledge extraction model to perform knowledge extraction on the hazard event database to obtain a triple table including entities, relationships and attributes; the knowledge extraction model comprises a pre-trained language unit, a bidirectional long short-term memory network unit and a conditional random field unit; performing knowledge fusion operations and knowledge processing operations on the triple table to obtain a knowledge graph; performing logical relationship inversion on the knowledge graph to obtain a safety boundary of a train control system; wherein the determination process of the knowledge extraction model is as follows: based on a safety boundary ontology model of a train control system, annotating a historical text data set to obtain a historical sample data set; constructing a knowledge extraction network; and training the knowledge extraction network based on the historical sample data set to obtain a knowledge extraction model.

[0021] This application introduces knowledge graph technology to convert the information in the hazard source log into nodes and edges in the knowledge graph, thereby eliminating the problem of information fragmentation. At the same time, as the functions of the train control system change, the knowledge graph can be dynamically updated to effectively support the identification of dynamic safety boundaries, thereby improving the safety of train operation. Moreover, this application generates historical sample data sets based on the safety boundary ontology model of the train control system, which can ensure the richness of the generated historical data sets, thereby enabling accurate and comprehensive identification of entity, relationship and attribute triple tables. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0023] Figure 1 This is an application environment diagram of a security boundary identification method based on a knowledge graph in one embodiment of the present application;

[0024] Figure 2 A schematic diagram of a flow chart of a security boundary identification method based on a knowledge graph provided in one embodiment of the present application;

[0025] Figure 3 A schematic diagram of the structure of a pre-trained language unit provided in an embodiment of the present application;

[0026] Figure 4 A schematic diagram of the structure of a bidirectional long short-term memory network unit provided in one embodiment of the present application;

[0027] Figure 5A schematic diagram of the structure of a conditional random field unit provided in an embodiment of the present application;

[0028] Figure 6 A schematic diagram of a safety boundary ontology model of a train control system provided in an embodiment of the present application;

[0029] Figure 7 A schematic diagram of the structure of the Word2Vec model provided in one embodiment of the present application.

[0030] Figure 8 A schematic diagram of the structure of a computer device provided in one embodiment of the present application. DETAILED DESCRIPTION

[0031] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0032] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0033] The security boundary identification method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the data that the server 104 needs to process. The data storage system can be set up separately, integrated on the server 104, or placed on the cloud or other servers. The terminal 102 can send the hazard source log to be processed to the server 104, and the server 104 receives the hazard source log to be processed. For the hazard source log to be processed, the server 104 is used to perform text extraction to obtain a hazardous event database; use the knowledge extraction model to extract knowledge from the hazardous event database to obtain a triple table including entities, relationships and attributes; perform knowledge fusion operations and knowledge processing operations on the triple table to obtain a knowledge graph; perform logical relationship inversion on the knowledge graph to obtain the safety boundary of the train control system. The server 104 can feedback the obtained safety boundary of the train control system to the terminal 102. In addition, in some embodiments, the safety boundary identification method can also be implemented independently by the server 104 or the terminal 102. For example, the terminal 102 can directly perform safety boundary identification processing on the hazard source log to be processed, or the server 104 can obtain the hazard source log to be processed from the data storage system and perform safety boundary identification processing on the hazard source log to be processed.

[0034] The terminal 102 may be, but is not limited to, various desktop computers, laptop computers, smart phones, tablet computers, IoT devices, and portable wearable devices. The server 104 may be implemented as an independent server or a server cluster consisting of multiple servers, or may be a cloud server.

[0035] In recent years, with the rapid development of knowledge graph technology, this technology describes the concepts and relationships between things in the real world in a structured form. It stores the relationships between entities in the form of graphs and has obvious advantages in mining implicit associations in data. In natural language processing, knowledge graphs can be used as a powerful tool to help us understand the complex factors behind entities.

[0036] In an exemplary embodiment, Figure 2 As shown, a security boundary identification method based on knowledge graph is provided. The method is executed by a computer device, and can be executed by a computer device such as a terminal or a server alone, or by a terminal and a server together. In the embodiment of the present application, the method is applied to Figure 1 The server 104 in the example is used as an example to illustrate, including the following steps 201 to 205. Among them:

[0037] Step 201, obtain a hazard source log, and perform text extraction on the hazard source log to obtain a hazard event database; the hazard source log is a text recording hazard events.

[0038] An example: the hazard source log is a text recording dangerous events during the train's travel.

[0039] Step 202, using a knowledge extraction model, extracting knowledge from the dangerous event database to obtain a triple table including entities, relationships and attributes; the knowledge extraction model includes a pre-trained language unit, a bidirectional long short-term memory network unit and a conditional random field unit.

[0040] Furthermore, the dangerous event database includes a plurality of current text data; the knowledge extraction model is used to extract knowledge from the dangerous event database to obtain a triple table including entities, relationships and attributes, specifically including:

[0041] Step 2021, input the current text data into the pre-trained language unit to vectorize the current text data and obtain the pre-trained word vector result. The structure diagram of the pre-trained language unit is as follows: Figure 3 shown.

[0042] Step 2022, the pre-trained word vector result is input into the bidirectional long short-term memory network unit to perform forward and reverse processing on the pre-trained word vector result, and capture the context information of the pre-trained word vector result to obtain a predicted label sequence that integrates the context information, so as to improve the generalization ability of the model and reduce the risk of overfitting. The structure diagram of the bidirectional long short-term memory network unit is shown in FIG. Figure 4 shown.

[0043] Step 2023, input the predicted label sequence of the fused context information into the conditional random field unit to decode the predicted label sequence of the fused context information to obtain an optimal label sequence; the optimal label sequence is a triple table including entities, relations and attributes obtained after knowledge extraction of the current text data. The structure diagram of the conditional random field unit is shown in FIG. Figure 5 shown.

[0044] Step 203, in order to determine whether the entities mentioned in different data sources refer to the same object in the real world, the entities in the triple table are updated using a knowledge fusion operation to obtain a new triple table; the knowledge fusion operation includes entity disambiguation and entity alignment.

[0045] Furthermore, the knowledge fusion operation is used to update the entities in the triple table to obtain a new triple table, which specifically includes:

[0046] Step 2031 , extracting features from the entities in the triple table to obtain entity feature vectors; the entity feature vectors may include entity names, attributes, context information, and co-occurring words.

[0047] Step 2032, using the cosine similarity calculation method, similarity calculation is performed on any two entity feature vectors, and a similarity matrix is ​​constructed based on the calculated similarity. The similarity matrix is ​​represented by S ij It represents the similarity between entity i and entity j.

[0048] The cosine similarity calculation formula is:

[0049]

[0050] Among them, A and B are any two entity feature vectors, A·B is the dot product of any two entity feature vectors, |A|×|B| is the norm of any two entity feature vectors, A i and B i are the components of vectors A and B in the i-th dimension respectively.

[0051] Step 2033, using the K-means clustering algorithm and the similarity matrix, iteratively calculate the entities corresponding to the similarity matrix until the convergence condition is met to obtain entity pairs. The goal of the K-means clustering algorithm is to group data points so that the sum of the distances between each data point and the center of the cluster to which it belongs (i.e., the mean of all points in the cluster) is minimized.

[0052] In addition, the quality of clustering results is evaluated by precision, recall and F1 score. Indicates the proportion of correctly identified entity links to all identified links; recall rate Indicates the proportion of correctly identified entity links to all links that should be identified; F1 score It is the harmonic average of precision and recall, an indicator used to balance precision and recall; where TP is the number of correctly identified entity links, FP is the number of incorrectly identified entity links, and FN is the number of unrecognized entity links.

[0053] Step 2034: Use a support vector machine to determine whether the entity pairs are aligned, and update the entities in the triple table according to the determination result to obtain a new triple table.

[0054] Specifically, this application uses the support vector machine (SVM) algorithm to perform entity alignment. First, for any pair of entities, features that can reflect their similarity are extracted, and the extracted features are converted into numerical vectors for SVM processing. Then, a linear SVM model is selected, and a linear kernel function is used to map the data to a high-dimensional space. A hyperplane that can maximize the boundary between different categories is found by optimizing the interval. The formula is as follows:

[0055]

[0056] u=β·(w * α+b * );

[0057]

[0058] Among them, d is the normalized linear function output; β is the true target value; w is the weight vector, w * is the transpose of the weight vector; α is the input feature vector; b is the bias term, b * is the transpose of the bias vector; u is the unnormalized linear function output.

[0059] The Lagrange multiplier method is used to transform the SVM optimization problem into a dual problem and solve it to obtain the optimal solution, specifically:

[0060]

[0061] Among them, L(w,b,λ) is the loss function; λ is the Lagrange multiplier, λ i is the Lagrange multiplier of the i-th data point; w is the weight vector; b is the bias term; oi is the true target value of the i-th sample; N is the number of samples; vi is the feature vector of the i-th sample.

[0062] During the solution process, the data points that have a decisive influence on the hyperplane, namely the support vectors, are identified, and the final hyperplane is constructed using the support vectors and Lagrange multipliers. The category to which the new data points belong is determined by calculating their positions on the hyperplane. Finally, the performance of the SVM model is evaluated using indicators such as accuracy, recall, and F1 score.

[0063] Step 204, using knowledge processing operations to supplement the relationships between entities in the new triple table to obtain a knowledge graph; after the entities in the triple table are updated, most of the relationships between entities are incomplete and the missing values ​​are very serious, so knowledge processing operations are used to supplement the relationships between entities in the new triple table.

[0064] Specifically, the graph reasoning of local structure is used to supplement the relationship between entities in the new triple table to obtain the knowledge graph. The determination process of the graph reasoning of local structure is as follows: select the degree of the entity (i.e., the number of edges connected to the entity) as the local structure feature of reasoning; extract the selected features from the knowledge graph and create feature vectors for each entity and relationship; create an adjacency matrix to represent the relationship between entities; construct a feature matrix based on the extracted features, with each entity and relationship occupying a row in the matrix; initialize the model parameters, including the weight matrix. The feature space is expanded through linear transformation to enhance the model's expressiveness. The cross entropy loss function is defined to measure the difference between the predicted results and the actual results. Using the training data, the model parameters are adjusted through the gradient descent optimization algorithm to minimize the loss function. The missing relationships in the knowledge graph are predicted to generate a set of candidate relationships; a threshold is set to filter the prediction results to balance the precision and recall. In addition, the model performance is evaluated using test data, and the accuracy, recall and F1 score indicators are used for evaluation. The model is iteratively optimized based on the evaluation results, and the feature selection and parameters are adjusted to improve the reasoning performance. Ultimately, the model will integrate the verified reasoning results back into the knowledge graph, update entity and relationship information, and continue to iterate and optimize to improve performance.

[0065] Step 205, invert the logical relationship of the knowledge graph to obtain the safety boundary of the train control system. Since the generated knowledge graph is a risk cause graph, in order to obtain the safety factors, it is necessary to invert the logical relationship of the above factors, that is, the conditions that the system safety needs to meet.

[0066] Furthermore, the logical relationship of the knowledge graph is inverted to obtain the safety boundary of the train control system, which specifically includes:

[0067] Step 2051, evaluate the knowledge graph using accuracy indicators, coverage indicators and consistency indicators.

[0068] Step 2052: When the evaluation result of the knowledge graph meets the preset conditions, the logical relationship of the knowledge graph whose evaluation result meets the preset conditions is inverted to obtain the safety boundary of the train control system; when the evaluation result of the knowledge graph does not meet the preset conditions, the knowledge extraction network is retrained to obtain a new knowledge extraction model, and based on the new knowledge extraction model, a new knowledge graph is obtained, and then the new knowledge graph is evaluated.

[0069] Among them, the calculation process of the accuracy index is: using the random sampling method to calculate the accuracy of the knowledge graph to obtain the accuracy index; the calculation process of the coverage index is: calculating the coverage of entities, relationships and attributes in the knowledge graph to obtain the coverage result; the coverage result is obtained by comparing the entities, relationships and attributes in the knowledge graph with the entities, relationships and attributes in the historical sample data set, and the coverage index is obtained according to the coverage result; the determination process of the consistency index is: using the query function of the graph database to extract data from the knowledge graph, and passing the extracted data to the rule engine, according to the predefined rules in the rule engine, the consistency index is obtained. In addition, for complex inconsistency issues, manual review and judgment are carried out.

[0070] Furthermore, the determination process of the knowledge extraction model is as follows:

[0071] Based on the safety boundary ontology model of the train control system, the historical text dataset is annotated using the BIO annotation system and Label-Studio to obtain the historical sample dataset.

[0072] The safety boundary ontology model of the train control system is constructed by using the Protégé tool to define entities, relationships and attributes in the train control system; Figure 6As shown in the figure, the train control system itself is a system that operates repeatedly under a complete safety assurance system. Generally, it operates periodically under given line conditions and operation plans. It usually consists of two parts: safety constraints for ensuring safe operation of trains and operation assumptions for ensuring the safety and availability of the operating environment. For rail transit, the operation process of trains is realized through the necessary equipment and facilities for train operation and the active safety protection system (signal system) to avoid collisions during the operation of trains and maintain the main operation constraints. Therefore, safety constraints specify the functions and timeliness requirements of the actions of signal equipment to prevent trains from encountering dangerous situations. Generally speaking, they can be divided into signal subsystems, vehicle subsystems, communication subsystems, etc. from the perspective of system composition; operation assumptions mainly include environmental information, scheduling information, speed limit information, etc. required for train operation control in addition to the signal system.

[0073] The historical sample data set includes multiple sample data; the sample data includes historical text data and corresponding label data; the historical text data is historical dangerous event data, and the label data is entities, relationships and attributes.

[0074] Construct a knowledge extraction network; the knowledge extraction network includes a pre-trained language network, a bidirectional long short-term memory network and a conditional random field.

[0075] Based on the historical sample data set, the knowledge extraction network is trained to obtain the knowledge extraction model.

[0076] During the training process of the pre-trained language network, any historical text data is input into the Word2Vec model to obtain an initial word vector, and the initial word vector is used to initialize the embedding layer of the pre-trained language network; the structure of the Word2Vec model is as follows Figure 7 As shown, the specific steps are as follows:

[0077] a. Walk parameter setting: The parameters of the random walk set in this application include walk length, walk number, return parameters, and entry and exit parameters.

[0078] b. Random walk execution: Starting from each node of the model, a walk path is generated according to the set parameters.

[0079] c. Walk data preprocessing: Convert the walk path into a serialized node list format suitable for model training.

[0080] d. Embedding model selection: The Word2Vec model is used to learn node embedding, including two architectures: CBOW and Skip-gram. Negative sampling technology and hierarchical Softmax technology are used to optimize training. The hierarchical Softmax reduces computational complexity by constructing a binary tree. The Word2Vec model adjusts weights to minimize the loss function through the gradient descent algorithm, and updates weights based on the loss function through the back propagation algorithm.

[0081] The loss function formula is as follows:

[0082]

[0083]

[0084] Among them, p is the true distribution; q is the predicted probability distribution; a is the sample; is the output of the exponential function, fg i is the log probability calculated by the model for the input a of a specific category i; f is the weight and bias of the linear combination input to the softmax function; g i is the output value of a specific category; fj is the linear transformation of the jth element of the softmax function input feature vector.

[0085] e. Train the Word2Vec model.

[0086] f. Apply embedding vectors: Apply the trained initialized word vectors to the embedding layer of the pre-trained language network.

[0087] The training process of the bidirectional long short-term memory network (BiLSTM) is as follows: first, the bidirectional long short-term memory network is initialized by setting the dimensions of the hidden layer and the word embedding layer. The bidirectional long short-term memory network consists of two LSTM units, which process the forward and reverse information of the sequence respectively, and each LSTM unit has its own initial hidden state and cell state; in the forward propagation process, the forward LSTM unit updates the state according to the word vector of the current word and the state of the previous time step; the reverse propagation process is similar, but the reverse LSTM unit starts processing from the end of the sequence, that is, the current hidden state and cell state are updated according to the word vector of the current word, the hidden state and cell state of the next time step. Then, the hidden states generated by the forward and reverse LSTMs at the same time step are merged to obtain a final hidden state that integrates the information in both directions; this merged state can simultaneously capture the context information of the pre-trained word vector results, and obtain a word vector sequence that integrates the context information.

[0088] Among them, the calculation process of the LSTM unit is:

[0089]

[0090] Among them, f t 、i t , o t are the activation values ​​of the forget gate, input gate, and output gate respectively; c t is the cell state at the current time step, is the new candidate value of the cell state; h t is the hidden state of the current time step; σ is the output value between 0 and 1, indicating the degree of opening of the door; W f , W i , W c , W o They are used for input gate, forget gate, unit state and output gate respectively; b f 、b i 、b c 、b o They are used for input gate, forget gate, unit state and output gate respectively; h t is the hidden state of the current time step, h t-1 is the hidden state of the previous time step; x t is the input for the current time step.

[0091] The conditional random field (CRF) takes into account the dependencies between labels and obtains the label sequence with the highest probability by calculating the emission score and the transfer score. The emission score represents the score of each word under a specific label, while the transfer score represents the probability of transferring from one label to another. The normalization factor ensures that the sum of the probabilities of all possible label sequences is 1. The most likely label sequence is found by using the Viterbi algorithm, that is, the label sequence with the highest probability under a given input sequence, that is, the optimal label sequence. The calculation process of the conditional random field is:

[0092]

[0093] in, is the i-th word in label y i The launch score under ; is from label y i Transfer to y i+1 transfer score; Z(x) is the normalization factor; n is the length of the observation sequence; x is the observation sequence; y is the label sequence.

[0094] During the training process, the conditional random field optimizes the model parameters by maximizing the ratio of the score of the true path to the scores of all possible paths, adopts the Adam optimizer, and uses the back propagation algorithm to update the model parameters.

[0095] In the specific implementation, the conditional random field unit first receives the output features of the bidirectional long short-term memory network unit as input, then defines the label set, calculates the transfer features, and constructs the potential energy function. The potential energy function score is converted into probability through the regularization factor, and the Viterbi algorithm is used to decode the optimal label sequence as the model's recognition result for entities, relations, and attributes.

[0096] This application introduces knowledge graph technology to convert the information in the hazard source log into nodes and edges in the knowledge graph, thereby eliminating the problem of information fragmentation. At the same time, as the functions of the train control system change, the knowledge graph can be dynamically updated to effectively support the identification of dynamic safety boundaries, thereby improving the safety of train operation. Moreover, this application generates historical sample data sets based on the safety boundary ontology model of the train control system, which can ensure the richness of the generated historical data sets, thereby enabling accurate and comprehensive identification of entity, relationship and attribute triple tables.

[0097] The present application also provides an application scenario, which applies the above-mentioned safety boundary identification method. Specifically: The safety boundary identification method provided in this embodiment can be applied in the train operation safety protection scenario. The train operation safety protection scenario includes a safety boundary identification link and a safety boundary execution link; the safety boundary identification method provided in this embodiment belongs to the safety boundary identification link in the train operation safety protection.

[0098] In an exemplary embodiment, a computer device is provided. The computer device may be a server or a terminal. The internal structure diagram thereof may be as follows: Figure 8 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store hazard source log processing data. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a safety boundary identification method based on a knowledge graph is implemented.

[0099] Those skilled in the art will understand that Figure 8The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0100] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.

[0101] In an exemplary embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

[0102] In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

[0103] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0104] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM may be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0105] The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.

[0106] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0107] This article uses specific examples to illustrate the principles and implementation methods of this application. The description of the above embodiments is only used to help understand the method and core ideas of this application. At the same time, for those skilled in the art, according to the ideas of this application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting this application.

Claims

1. A security boundary identification method based on knowledge graph, characterized in that: The knowledge graph-based security boundary identification method includes: Obtaining a hazard source log, and performing text extraction on the hazard source log to obtain a hazard event database; the hazard source log is a text recording hazard events; Using a knowledge extraction model, knowledge is extracted from the dangerous event database to obtain a triple table including entities, relationships and attributes; the knowledge extraction model includes a pre-trained language unit, a bidirectional long short-term memory network unit and a conditional random field unit; Performing knowledge fusion operations and knowledge processing operations on the triple table to obtain a knowledge graph; Reversing the logical relationship of the knowledge graph to obtain the safety boundary of the train control system; The determination process of the knowledge extraction model is as follows: Based on the safety boundary ontology model of the train control system, the historical text data set is annotated to obtain a historical sample data set; the safety boundary ontology model of the train control system is used to define entities, relations and attributes in the train control system; the historical sample data set includes multiple sample data; the sample data includes historical text data and corresponding label data; the historical text data is historical dangerous event data, and the label data is entities, relations and attributes; Construct a knowledge extraction network; Based on the historical sample data set, the knowledge extraction network is trained to obtain the knowledge extraction model.

2. The method for identifying security boundaries based on knowledge graph according to claim 1 is characterized in that: The dangerous event database includes a plurality of current text data; using the knowledge extraction model, knowledge is extracted from the dangerous event database to obtain a triple table including entities, relations and attributes, specifically including: Inputting the current text data into the pre-trained language unit to vectorize the current text data and obtain a pre-trained word vector result; Inputting the pre-trained word vector result into the bidirectional long short-term memory network unit to perform forward processing and reverse processing on the pre-trained word vector result, and capturing the context information of the pre-trained word vector result to obtain a predicted label sequence integrating the context information; The predicted label sequence of the fused context information is input into the conditional random field unit to decode the predicted label sequence of the fused context information to obtain an optimal label sequence; the optimal label sequence is a triple table including entities, relationships and attributes obtained after knowledge extraction of the current text data.

3. The method for identifying security boundaries based on knowledge graph according to claim 1 is characterized in that: The knowledge fusion operation and knowledge processing operation are performed on the triple table to obtain a knowledge graph, which specifically includes: Using a knowledge fusion operation, the entities in the triple table are updated to obtain a new triple table; the knowledge fusion operation includes entity disambiguation and entity alignment; By using knowledge processing operations, the relationships between entities in the new triple table are supplemented to obtain a knowledge graph.

4. The method for identifying security boundaries based on knowledge graph according to claim 3 is characterized in that: Using the knowledge fusion operation, the entities in the triple table are updated to obtain a new triple table, which specifically includes: Extracting features of entities in the triple table to obtain entity feature vectors; Calculating the similarity between any two entity feature vectors, and constructing a similarity matrix based on the calculated similarities; Using the K-means clustering algorithm and the similarity matrix, iteratively calculating the entities corresponding to the similarity matrix to obtain entity pairs; A support vector machine is used to determine whether the entity pairs are aligned, and the entities in the triple table are updated according to the determination result to obtain a new triple table.

5. The method for identifying security boundaries based on knowledge graph according to claim 4 is characterized in that: The knowledge processing operation is used to supplement the relationship between entities in the new triple table to obtain a knowledge graph, specifically including: By using graph reasoning of local structure, we can supplement the relationship between entities in the new triple table and obtain the knowledge graph.

6. The method for identifying security boundaries based on knowledge graph according to claim 1, characterized in that: The knowledge extraction network includes a pre-trained language network, a bidirectional long short-term memory network and a conditional random field; wherein, during the training process of the pre-trained language network, any historical text data is input into the Word2Vec model to obtain an initialized word vector, and the initialized word vector is used to initialize the embedding layer of the pre-trained language network.

7. The method for identifying security boundaries based on knowledge graph according to claim 1 is characterized in that: The logical relationship of the knowledge graph is inverted to obtain the safety boundary of the train control system, which specifically includes: Evaluate knowledge graphs using accuracy, coverage, and consistency metrics; When the evaluation result of the knowledge graph meets the preset conditions, the logical relationship of the knowledge graph whose evaluation result meets the preset conditions is reversed to obtain the safety boundary of the train control system; When the evaluation result of the knowledge graph does not meet the preset conditions, the knowledge extraction network is retrained to obtain a new knowledge extraction model, and based on the new knowledge extraction model, a new knowledge graph is obtained, and then the new knowledge graph is evaluated; The calculation process of the accuracy index is as follows: using a random sampling method, calculating the accuracy of the knowledge graph to obtain the accuracy index; The calculation process of the coverage index is: compare with the historical sample data set, calculate the coverage results of the entities, relationships and attributes in the knowledge graph, and obtain the coverage index; The process of determining the consistency index is as follows: extracting data from the knowledge graph using the query function of the graph database, passing the extracted data to the rule engine, and obtaining the consistency index according to the predefined rules in the rule engine.

8. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the knowledge graph-based security boundary identification method described in any one of claims 1 to 7.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the knowledge graph-based security boundary identification method described in any one of claims 1 to 7 is implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the knowledge graph-based security boundary identification method described in any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Knowledge graph construction and improvement system and method based on natural language

    CN116737967A

  • Public security risk assessment method based on knowledge graph

    CN118093889A

  • System and method for capturing, indexing and extracting digital workflow from videos using artificial intelligence

    US20210271886A1