Accurate sensing method and system for topological transformation event of distribution network

By introducing a custom dictionary and Bert-CRF model, combining dependent syntax and semantic role features, a knowledge graph is constructed, and the multimorphic expression and entity ambiguity problems in the text entity extraction of distribution network topology transformation events are solved, precise extraction of power equipment failure entities is achieved, and the security of the distribution network is improved.

CN120508664AInactive Publication Date: 2025-08-19YUNNAN XINGSHENG POWER TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510760678.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-09
Publication Date
2025-08-19
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The existing distribution network topology transformation event text entity extraction technology has problems with multi-morphological expression, entity ambiguity and data sparseness of power equipment, resulting in low word segmentation accuracy, imbalance in the training samples of entity relationship models, and it is difficult to build an accurate fault knowledge graph.

Method used

The LTP word segmentation system is used to introduce a custom power field dictionary, combine the Bert-CRF model and feature vector extraction entities, build an entity relationship classification model that depends on syntax and semantic role features, and use the Neo4j graph database to build a knowledge graph to realize multi-level feature matching and entity relationship extraction.

Benefits of technology

It improves the accuracy and recall of the text entity of distribution network topology transformation event, ensures the accurate extraction of power equipment failure and defect text, and ensures the safe operation of the distribution network.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120508664A_ABST
    Figure CN120508664A_ABST
Patent Text Reader

Abstract

The invention discloses a precise sensing method and system for a distribution network topological transformation event. The method comprises the following steps: performing text entity word segmentation on the distribution network topological transformation event by using an LTP word segmentation system; extracting a distribution network topology transformation event text entity by adopting a dictionary-based method; extracting a time entity by adopting a time information extraction tool; adopting a Bert-CRF model to extract two types of entities of a line name and a manufacturer name of a distribution network topological transformation event text entity; a supervised learning method based on feature vectors is adopted to extract the relation between the power equipment entities; and constructing a distribution network topological transformation event knowledge graph from bottom to top based on the Neo4j graph database. According to the scheme provided by the invention, the power distribution network topological transformation event text entity can be extracted from different dimensions, and the multi-level feature matching model is established; based on the feature vectors, the dependency syntax features and the semantic role features, an entity relation classification model is constructed, accurate extraction of fault entities of the power equipment fault defect text is achieved, and safe operation of a power distribution network is guaranteed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of distribution network topology technology, and in particular to a method for accurately sensing distribution network topology change events. Background Art

[0002] With the continuous advancement of the smart grid strategy and the increasing installation of advanced measurement devices (smart meters, umpus, etc.), the power system has obtained a huge amount of data from the distribution network. Based on the obtained data, the distribution network topology structure can be constructed to perceive the real-time status of the distribution network. By monitoring the distribution network topology change events based on the operating status of the distribution network, the safe operation of the distribution network can be guaranteed.

[0003] Current entity extraction technology for distribution network topology transformation event text on power equipment fault defects exists. Power equipment is represented in multiple forms within text. For example, "circuit breaker" may be abbreviated as "DL" or labeled with a device ID. Professional terminology is intertwined with general vocabulary, resulting in low accuracy for conventional word segmentation tools. The same word refers to different entity types in different contexts. For example, "isolation" can refer to both a switch state and an isolation device, requiring reliance on power domain knowledge for disambiguation. Fault-related entities and specific switch model defects appear very rarely in the corpus, while general entities account for a high proportion, leading to imbalanced training samples for entity relationship models. Existing technologies rely on rule templates and natural language processing (NLP) tools, making them difficult to adapt to the domain-specific nature of power equipment fault defect text, limiting the accuracy of fault knowledge graph construction.

[0004] There is an urgent need for a hierarchical perception technology that integrates knowledge in the field of power equipment faults to achieve accurate extraction of fault entities. Summary of the Invention

[0005] In order to solve or partially solve the problems existing in the related technologies, the present application provides a method and system for accurately perceiving distribution network topology transformation events, aiming to solve the problems that the existing distribution network topology transformation event text entity extraction technology is affected by entity irregularity, entity ambiguity and data sparsity.

[0006] This application provides a method for accurately sensing distribution network topology change events, including: An LTP word segmentation system is used to perform entity word segmentation on distribution network topology transformation event texts; the LTP word segmentation system introduces a custom user dictionary, adds professional vocabulary related to the power field to the dictionary, and improves the accuracy of word segmentation results; A dictionary-based method is used to extract text entities of distribution network topology transformation events. The text entities include device ID, feeder ID, feeder name, voltage level, switch name, switch ID, and status before and after transformation. Use time information extraction tools to extract time entities. Specifically, traverse each distribution network topology transformation event text, record each word and its part of speech, and use the part of speech to determine whether the word is a time noun. The Bert-CRF model is used to extract the line name and manufacturer name entities of the distribution network topology change event text entity; A supervised learning method based on feature vectors is used to extract the relationships between power equipment entities. Specifically, dependency syntactic features and semantic role features are added to the relationship features to construct an entity relationship classification model, and the relationships between the entities in the distribution network topology transformation event text are obtained. A knowledge graph of distribution network topology transformation events is constructed from the bottom up based on the Neo4j graph database.

[0007] Optionally, in some embodiments, the Bert-CRF model includes: The pre-trained language Bert model is used to train text word vectors, and the conditional random field (CRF) model is used to replace the softmax output layer of the Bert model. The advantages of the Bert model and the CRF model are combined to extract the line name and manufacturer name of the target entity in the text.

[0008] Optionally, in some implementations, the entity segmentation of the distribution network topology transformation event text using the LTP word segmentation system includes: The LTP word segmentation system uses the ME model to extract unigram character features, bigram character features, character type features, and dictionary attribute features from the text; Import the distribution network topology transformation event text after word segmentation, create a new data file to store the standardized text, traverse each word in the word segmentation text, determine whether the word contains special symbols, and remove the special symbols if so. Otherwise, do not process it, store the words composed of Chinese characters in the data, and output the data file to complete the standardization of the distribution network topology transformation event text.

[0009] Optionally, in some implementations, the customized user dictionary includes: Add professional vocabulary related to the power industry to the dictionary to improve the accuracy of word segmentation results; The construction of the dictionary is divided into two steps: obtaining relevant knowledge texts in the power field, collecting network links of public information of power grid companies accessible on the Internet, using web page analysis tools to analyze the network addresses and obtain the network hyperlinks hidden in the page; calling the request object to send a request to the server to obtain data, and using the request.get() function to obtain the web page data; using a breadth-first strategy, parsing the downloaded item data using regular expressions to remove irrelevant tags, and continuing to download the corresponding information for the returned new network until no new network is generated; using the json() function to encode the web page data into json data, and then decoding the json data and saving it in txt file format; With reference to national standards, a knowledge vocabulary was manually established. With reference to the State Grid Corporation's document and archive organization specifications, knowledge texts in the power field were analyzed and crawled, and keywords related to equipment failures were screened and stored in txt files, with one keyword stored per line.

[0010] Optionally, in some implementations, extracting the distribution network topology transformation event text entity using a dictionary-based method includes: Import dictionaries and processed text records, store entity content in the form of dictionaries, and specify a type of entity label for each dictionary; For each pre-processed distribution network topology change event text, all words in each dictionary are traversed in turn to determine whether the word appears in the text record; If it appears, it means that the distribution network topology transformation event text has a corresponding entity. The category of the corresponding entity is determined by the dictionary category to which it belongs. If it does not appear, continue traversing; When all dictionaries are traversed, all entities in the distribution network topology transformation event text are successfully extracted.

[0011] Optionally, in some implementations, extracting the time entity using a time information extraction tool includes: Use the LTP word segmentation system to segment each distribution network topology change event text and mark the part of speech of each word; Traverse each word and its part of speech, and determine whether the word is a time noun based on the part of speech; If so, determine whether the next word is also a time noun, and continue in this way until there is a word that is not a time noun; Then connect the consecutive time nouns together to form a time entity; if not, continue traversing until each text record is traversed.

[0012] Optionally, in some embodiments, adding dependency syntactic features and semantic role features to the relationship features includes: In the relationship extraction between power equipment entities, the entity relationship features used can be divided into two categories: basic features and syntactic and semantic features; Basic features include entity type, entity content, entity part of speech, and entity context; Syntactic and semantic features include entity dependency syntax and entity semantic roles; Dependency syntactic features describe the dependency structure in a sentence and its grammatical and semantic functions by analyzing the words and grammar in the sentence in the form of a syntactic structure tree. Through the dependency syntactic analysis results of the text, the dependent objects and dependency relationships of each entity are obtained, and the syntactic feature vector of the entity is constructed; The syntactic feature f(i) of each entity can be expressed as: (5) Where i is the entity, is the position number of the entity in the sentence, parent is the dependent object of the entity in the sentence, Indicates the position number of the dependent object in the sentence, and relate indicates the dependency relationship between the entity and the dependent object; The semantic role feature is based on sentences and takes the predicate verbs in the sentences as the core to analyze the relationship between the various components in the sentences and the predicate verbs. If there are multiple predicate verbs in a sentence, the semantic role will also have multiple layers of annotation results. The outermost layer of semantic role annotation results is determined by the core verbs in the sentence, and the annotation results of the remaining layers are determined by the various non-core verbs in the sentence. If the semantic role of an entity has multiple layers of annotation results, all the annotation results are considered when constructing the semantic role feature vector. The entity semantic feature g(i) can be expressed as (6) Where N is the maximum number of semantic role annotation layers, Srl k Represents the results of entity labeling in different semantic role layers.

[0013] Optionally, in some implementations, constructing an entity relationship classification model includes: After completing the sentence lexical analysis, dependency syntactic feature analysis, and semantic role feature annotation, the feature vector V(i) of each entity is established based on the dependency syntactic features and semantic role features: (7) In the formula, i represents the entity, Indicates the category of the entity, Represents entity content, Indicates the part of speech of the entity, Represents the context of the entity; Based on the basic features of entities, dependency syntactic features and semantic role features, the relationship feature vector E(i,j) of the entity pair is constructed: (8) The text is randomly divided into training text and test text in a ratio of 7:3. The SVM classification model is trained using the relational feature vector E(i, j) in the training text to obtain the relational classifier for entity pairs. The performance of the relational classifier is tested using the test text. The entity relationship results of the distribution network topology transformation event text are predicted using the trained SVM classification model.

[0014] Optionally, in some implementations, constructing a distribution network topology transformation event knowledge graph includes: The knowledge graph is represented by a triple G=(E, R, S), where E={e1, e2, …, en} represents the entity set; R={r1, r2 …, rn} represents the relationship set of the knowledge graph; S⊆E×R×E represents the triple set of entity E and relationship R. Represent the distribution network topology transformation event entities and entity relationships in the form of knowledge graph triples; Store the distribution network topology transformation event entities and entity relationship triples in CSV format and import the stored files into the Neo4j graph database using the Cypher language LOAD command. Use the MERGE command to identify the entities and relationships of the triples imported into Neo4j; By integrating and reasoning about the intrinsic connections between various entities and relationships, a knowledge graph of the distribution network topology transformation event domain is drawn, and the corresponding entity attribute relationships are queried through the MATCH and WHERE commands.

[0015] A second aspect of the present application provides a system for accurately sensing distribution network topology change events, including: A memory, a processor, and a distribution network topology change event accurate perception program stored in the memory and runnable on the processor. When the distribution network topology change event accurate perception program is executed by the processor, the steps of the distribution network topology change event accurate perception method are implemented.

[0016] The technical solution provided by this application may have the following beneficial effects: A dictionary-based and machine learning method is used to extract distribution network topology transformation event text entities, time entities, and two types of entities, line name and manufacturer name, from different dimensions. A multi-level feature matching model is established to improve the accuracy and recall rate of entity extraction. Based on feature vectors, dependency syntactic features and semantic role features are added to the relationship features to construct an entity relationship classification model, extract the relationships between power equipment entities, improve the accuracy and reliability of entity relationship matching, and achieve accurate extraction of fault entities in power equipment fault defect texts, thereby ensuring the safe operation of the distribution network.

[0017] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] The above and other objects, features and advantages of the present application will become more apparent through a more detailed description of exemplary embodiments of the present application in conjunction with the accompanying drawings, wherein the same reference numerals generally represent the same components in the exemplary embodiments of the present application.

[0019] Figure 1 This is a flow chart of a method for accurately sensing a distribution network topology change event, as shown in an embodiment of the present application; Figure 2 This is a schematic diagram of an entity extraction process of a method for accurately sensing a distribution network topology change event, as shown in an embodiment of the present application; Figure 3 This is a schematic diagram of a time entity extraction process of a method for accurately sensing a distribution network topology change event, as shown in an embodiment of the present application; Figure 4 This is a schematic diagram of the Bert-CRF model structure of a method for accurately sensing distribution network topology change events shown in an embodiment of the present application; Figure 5 This is a schematic diagram of dependency syntax parsing of a method for accurately perceiving distribution network topology transformation events, as shown in an embodiment of the present application; Figure 6 This is a schematic diagram of the semantic role labeling results of a method for accurately perceiving distribution network topology change events, as shown in an embodiment of the present application; Figure 7 This is a schematic diagram of the knowledge graph drawing process of a method for accurately perceiving distribution network topology transformation events shown in an embodiment of the present application. DETAILED DESCRIPTION

[0020] The following describes embodiments of the present application in more detail with reference to the accompanying drawings. Although the accompanying drawings illustrate embodiments of the present application, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments described herein. Rather, these embodiments are provided to make the present application more thorough and complete, and to fully convey the scope of the present application to those skilled in the art.

[0021] It should be understood that although the terms "first", "second", "third", etc. may be used in this application to describe various information, this information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. For example, without departing from the scope of this application, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.

[0022] In the description of this application, it should be understood that the terms "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating the orientation or position relationship, are based on the orientation or position relationship shown in the accompanying drawings, and are only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on this application.

[0023] Unless otherwise expressly specified or limited, terms such as "mounted," "connected," "connect," and "fixed" should be interpreted broadly. For example, they may refer to fixed or detachable connections, or integration; mechanical or electrical connections; direct or indirect connections through an intermediary; and internal communication between two components or interaction between two components. Those skilled in the art will understand the specific meanings of these terms in this application based on the specific circumstances.

[0024] Current entity extraction technology for distribution network topology transformation event text on power equipment fault defects exists. Power equipment is represented in multiple forms within text. For example, "circuit breaker" may be abbreviated as "DL" or labeled with a device ID. Professional terminology is intertwined with general vocabulary, resulting in low accuracy for conventional word segmentation tools. The same word refers to different entity types in different contexts. For example, "isolation" can refer to both a switch state and an isolation device, requiring reliance on power domain knowledge for disambiguation. Fault-related entities and specific switch model defects appear very rarely in the corpus, while general entities account for a high proportion, leading to imbalanced training samples for entity relationship models. Existing technologies rely on rule templates and natural language processing (NLP) tools, making them difficult to adapt to the domain-specific nature of power equipment fault defect text, limiting the accuracy of fault knowledge graph construction.

[0025] In response to the above problems, the embodiments of the present application provide a method and system for accurately perceiving distribution network topology transformation events. The method can use a dictionary-based and machine learning method to extract distribution network topology transformation event text entities, time entities, and two types of entities, line names, and manufacturer names, from different dimensions, establish a multi-level feature matching model, and improve the accuracy and recall rate of entity extraction; based on feature vectors, dependency syntactic features and semantic role features are added to the relationship features to construct an entity relationship classification model, extract the relationship between power equipment entities, improve the accuracy and reliability of entity relationship matching, and realize the accurate extraction of fault entities in power equipment fault defect texts, thereby ensuring the safe operation of the distribution network.

[0026] The technical solutions of the embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0027] Figure 1 This is a flow chart of a method for accurately sensing distribution network topology change events shown in an embodiment of the present application.

[0028] See also Figure 1 , a method for accurately sensing distribution network topology change events, comprising: S1. Use the LTP word segmentation system to perform entity word segmentation on the distribution network topology transformation event text; the LTP word segmentation system introduces a custom user dictionary, adds professional vocabulary related to the power field to the dictionary, and improves the accuracy of the word segmentation results; Specifically, the entity segmentation of the distribution network topology transformation event text using the LTP word segmentation system includes: The LTP word segmentation system uses the ME model to extract unigram character features, bigram character features, character type features, and dictionary attribute features from the text; The user-defined dictionary includes: adding professional vocabulary related to the power field to the dictionary to improve the accuracy of word segmentation results; the construction of the dictionary is divided into two steps: obtaining knowledge text related to the power field, collecting network links of public information of power grid companies accessible on the Internet, using web page analysis tools to analyze network addresses and obtain network hyperlinks hidden in the page; calling the request object to send a request to the server to obtain data, and using the request.get() function to obtain web page data; using a breadth-first strategy, using regular expressions to parse the downloaded item data to remove irrelevant tags, and continuing to download corresponding information for new networks returned until no new networks are generated; using the json() function to encode the web page data into json data, and decoding the json data and saving it in txt file format; With reference to national standards, a knowledge vocabulary was manually established. With reference to the State Grid Corporation of China's document and archive organization specifications "GB / T18894-2016", "DA / T38-2008" and "DA / T48-2009", knowledge texts in the power field were analyzed and crawled, and keywords related to equipment failures were filtered out and stored in txt files, with one keyword stored per line.

[0029] Import the distribution network topology transformation event text after word segmentation, create a new data file to store the standardized text, traverse each word in the word segmentation text, determine whether the word contains special symbols, and remove the special symbols if so. Otherwise, do not process it, store the words composed of Chinese characters in the data, and output the data file to complete the standardization of the distribution network topology transformation event text.

[0030] S2. Extract the text entities of the distribution network topology transformation event using a dictionary-based method. The text entities include device ID, feeder ID, feeder name, voltage level, switch name, switch ID, and status before and after transformation. Specifically, the dictionary-based method is used to extract the distribution network topology transformation event text entity, such as Figure 2 As shown, including: Import dictionaries and processed text records, store entity content in the form of dictionaries, and specify a type of entity label for each dictionary; For each pre-processed distribution network topology change event text, all words in each dictionary are traversed in turn to determine whether the word appears in the text record; If it appears, it means that the distribution network topology transformation event text has a corresponding entity. The category of the corresponding entity is determined by the dictionary category to which it belongs. If it does not appear, continue traversing; When all dictionaries are traversed, all entities in the distribution network topology transformation event text are successfully extracted.

[0031] S3. Use a time information extraction tool to extract time entities. Specifically, traverse each distribution network topology transformation event text, record each word and its part of speech, and determine whether the word is a time noun based on the part of speech. Specifically, the time entity is extracted using a time information extraction tool, such as Figure 3 As shown, including: Use the LTP word segmentation system to segment each distribution network topology change event text and mark the part of speech of each word; Traverse each word and its part of speech, and determine whether the word is a time noun based on the part of speech; If so, determine whether the next word is also a time noun, and continue in this way until there is a word that is not a time noun; Then connect the consecutive time nouns together to form a time entity; if not, continue traversing until each text record is traversed.

[0032] S4. Use the Bert-CRF model to extract the line name and manufacturer name entities of the distribution network topology change event text entity; Specifically, the Bert-CRF model includes: The pre-trained language Bert model is used to train text word vectors, and the conditional random field (CRF) model is used to replace the softmax output layer of the Bert model. The advantages of the Bert model and the CRF model are combined to extract the line name and manufacturer name of the target entity in the text.

[0033] The overall structure of the Bert-CRF model is as follows Figure 4 As shown in the figure, all entities in the distribution network topology transformation event text are taken as input. The Bert model consists of an Embedding layer and a Transformer layer. First, a text containing n characters is input into the Embedding layer for encoding, including word embedding, sentence embedding, and position embedding, to obtain word vectors, sentence vectors, and position vectors, respectively. The word vector is the vector representation of each character in the input sentence itself, the sentence vector is used to represent the global semantic information of the sentence, and the position vector is used to represent the corresponding position information of the character in the sentence. The [CLS] and [SEP] symbols are added to indicate the start and end positions of the sentence. The custom user dictionary feature information constructed above is introduced, and the character features and lexical features are fused in the Bert model to achieve the simultaneous capture of character and lexical level information, solving the problem of unclear entity boundaries between feeder names and switch names.

[0034] The CRF model is used to obtain the global optimal label sequence, and the joint probability distribution represented by the undirected graph is denoted as G=(V, E), where V and E represent the set of nodes and edges respectively. ,side , there is a dependency between random variables. Under the premise of X, This will conform to the Markov property, as shown below: (1) In summary, in the chain structure CRF, setting is the observation sequence, and To label the word sequence, the conditional probability of Y can be obtained according to the concept , which is calculated as follows: (2) In the formula, for the sequence X, the characteristic function and It is used to represent some distribution characteristics of training data, representing transfer and state functions respectively. If the characteristic function is satisfied, it is 1, otherwise it is 0. The characteristic function usually takes the value of 0 or 1. represents the transition probability of sequence Y at position i, Represents the probability of the value corresponding to position i in sequence Y; Derived from training, they represent the weights of the two functions respectively; let = , the transfer and state functions will use the characteristic function To express it, the characteristic function is obtained by summing the characteristics at the corresponding locations, and the calculation is shown as follows: (3) After normalization of the above formula by Z(X) factor, the conditional probability of CRF is as follows (4) Finally, the Viterbi dynamic programming algorithm is used to select the sequence with the highest score as the optimal sequence. Conditional random fields do not require the output independence assumption, and all features are globally normalized to obtain the optimal solution, solving the labeling bias problem that exists in word segmentation algorithms.

[0035] S5. Use a supervised learning method based on feature vectors to extract the relationship between power equipment entities. Specifically, add dependency syntactic features and semantic role features to the relationship features, build an entity relationship classification model, and obtain the relationship between the distribution network topology transformation event text entities. Specifically, the addition of dependency syntactic features and semantic role features to the relationship features includes: In the relationship extraction between power equipment entities, the entity relationship features used can be divided into two categories: basic features and syntactic and semantic features; Basic features start from the entity, taking into account information such as the entity's content, part of speech, and context. Syntactic and semantic features start from the sentence, analyzing the dependency relationships and semantic roles of entities within the sentence. Basic features include entity type, entity content, entity part of speech, and entity context; syntactic and semantic features include entity dependency syntax and entity semantic role; dependency syntactic features describe the dependency structure and its grammatical and semantic function in the sentence by analyzing the words and grammar in the sentence in the form of a syntactic structure tree.

[0036] Dependency syntactic analysis describes the dependency structure in a sentence and its grammatical and semantic functions in the form of a syntactic structure tree by analyzing the words and grammar in the sentence. "Dependency" means that one syntactic component depends on another syntactic component, and there is a dominant and dominated relationship between the two. Dependency syntactic analysis claims that the core predicate verb in a sentence is the central component of the entire sentence, responsible for dominating other syntactic components, and there is a certain dependency relationship between all dominating and dominated syntactic components. By analyzing the dependency relationship of each syntactic component, the syntactic structure of the sentence is revealed, and the sentence is presented in the form of a tree. Taking "This transformer was produced by Huiwang Electric Co., Ltd. on November 14, 2009" as an example, the dependency syntactic analysis results are as follows: Figure 5 As shown, the arrows with directions represent dependency order, and the text on the arrows represents dependency relationships. Root represents the root node, ATT represents the attributive-predicate relationship, POB represents the prepositional-object relationship, ADV represents the adverbial-predicate structure, FOB represents the prepositional object, and HED represents the core relationship. In this sentence, there are three entities: "transformer," "Huiwang Electric Co., Ltd.", and "November 14, 2009." The dependent object of "transformer" is "production," and the dependency relationship is FOB; the dependent object of "Huiwang Electric Co., Ltd." is "by," and the dependency relationship is POB; the dependent object of "November 14, 2009" is "at," and the dependency relationship is POB. The dependent objects and dependency relationships of an entity often represent its syntactic components and status in the sentence, and these syntactic components and status also reflect the internal relationships between entities to a certain extent. Through the results of the text's dependency syntactic analysis, the dependent objects and dependency relationships of each entity are obtained, and the syntactic feature vector of the entity is constructed. The syntactic feature f(i) of each entity can be expressed as: (5) Where i is the entity, is the position number of the entity in the sentence, parent is the dependent object of the entity in the sentence, It indicates the position number of the dependent object in the sentence, and relate indicates the dependency relationship between the entity and the dependent object.

[0037] The semantic role feature is based on the sentence as the unit and the predicate verb in the sentence as the core, analyzing the relationship between each component and the predicate verb in the sentence; similar to the syntactic components in dependency syntax analysis, the semantic role labeling results also contain relevant information features of the entity. Taking "This transformer was produced by Huiwang Electric Co., Ltd. on November 14, 2009" as an example, the semantic role labeling results are as follows: Figure 6 As shown in the figure, A0 represents the agent, A1 represents the patient, and TMP represents the time. This sentence contains three entities. Semantic role labeling is performed around the core verb "production." The agent A0 is "by Huiwang Electric Co., Ltd.", the patient A1 is "transformer," and the time TMP is "on November 14, 2009." Therefore, the semantic role labeling results for "transformer," "Huiwang Electric Co., Ltd.", and "November 14, 2009" are A1, A0, and TMP, respectively. Entity semantic role labeling generally represents the entity's role in the sentence and, to a certain extent, reveals the semantic relationships between entities.

[0038] The semantic role labeling results are usually determined by the predicate verbs in the sentence. If there are multiple predicate verbs in a sentence, the semantic role will also have multiple layers of labeling results. The outermost layer of semantic role labeling results is determined by the core verbs in the sentence, and the labeling results of the remaining layers are determined by the non-core verbs in the sentence. If the semantic role of an entity has multiple layers of labeling results, all the labeling results are considered when constructing the semantic role feature vector. The entity semantic feature g(i) can be expressed as (6) Where N is the maximum number of semantic role annotation layers, Srl k Represents the results of entity labeling in different semantic role layers.

[0039] Specifically, the constructing of the entity relationship classification model includes: After completing the sentence lexical analysis, dependency syntactic feature analysis, and semantic role feature annotation, the feature vector V(i) of each entity is established based on the dependency syntactic features and semantic role features: (7) In the formula, i represents the entity, Indicates the category of the entity, Represents entity content, Indicates the part of speech of the entity, Represents the context of the entity; Based on the basic features of entities, dependency syntactic features and semantic role features, the relationship feature vector E(i,j) of the entity pair is constructed: (8) In the extraction of entity relationships, the relationships between each pair of entities in each text are annotated in advance, and the annotated results are randomly divided into training text and test text in a ratio of 7:3. The SVM classification model obtains the final SVM classification model by learning the relationship feature vectors of entity pairs in the training text and the corresponding annotated entity relationships. This SVM classification model is then applied to the test text to predict the relationship between entity pairs in each text record. Finally, the annotated entity pair relationships are compared with the predicted entity pair relationships, the entity relationship extraction results are analyzed, and the performance of the relationship classifier is determined. The SVM classification model is to find the best straight line or plane among the two given points A and B, so that the shortest distance from category A and category B to the straight line or plane is the largest, that is, the interval is maximized. The training data set for SVM is in is the relationship feature vector of the entity pair, and is the corresponding relationship label. SVM learns the response relationship, finds the hyperplane between the entity pairs, and classifies entity pairs with similar relationship feature vectors into one category. For linear classification problems, the SVM model transforms the process of solving the optimal hyperplane into solving a quadratic optimal problem. The final objective function is: (9) The constraints that are satisfied are: (10) The relationship classification of entity pairs is a nonlinear problem. Therefore, when solving the optimal hyperplane, it is necessary to map the feature sample points to a high-dimensional feature space through a kernel function and replace the inner product operation in linear classification with the kernel function operation. The objective function at this time is: (11) The Gaussian kernel function RBF, which is commonly used in nonlinear classification, is selected. Its calculation formula is: (12) Where, is the bandwidth, which is used to control the scope of the kernel function. The final entity relationship classification function is: (13) Where μ i is the conjugate matrix of the hyperplane normal vector, and β is the conjugate matrix of the hyperplane intercept.

[0040] In the SVM classification model of this application, the main model parameters include the type of kernel function, the bandwidth of the kernel function, and the kernel function. , the kernel function cache size cache_size, penalty factor C, training error convergence value tol and maximum number of iterations max_iter, where max_iter is -1 to indicate that there is no upper limit on the number of training times. The specific values of the model parameters are shown in Table 1 below: Table 1 - SVM model parameter values The entity relationship results of the distribution network topology transformation event text are predicted using the trained SVM classification model.

[0041] S6. Build a distribution network topology transformation event knowledge graph from the bottom up based on the Neo4j graph database.

[0042] Specifically, the construction of the distribution network topology transformation event knowledge graph is as follows: Figure 7 As shown, including: The knowledge graph is represented by a triple G=(E, R, S), where E={e1, e2, …en} represents the entity set; R={r1, r2…, rn} represents the relationship set of the knowledge graph; S ⊆E×R×E represents the triple set of entity E and relationship R. Represent the distribution network topology transformation event entities and entity relationships in the form of knowledge graph triples; The distribution network topology transformation event entities and entity relationship triples are stored in CSV format and imported into the Neo4j graph database using the Cypher language LOAD command. The MERGE command is used to identify the entities and relationships of the triples imported into Neo4j. By integrating and reasoning the intrinsic connections between each entity and relationship, a knowledge graph of the distribution network topology transformation event domain is drawn, and the corresponding entity attribute relationships are queried using the MATCH and WHERE commands.

[0043] Corresponding to the aforementioned application function implementation device embodiment, the present application also provides a distribution network topology change event accurate perception system and corresponding embodiments.

[0044] A memory, a processor, and a distribution network topology change event accurate perception program stored in the memory and runnable on the processor. When the distribution network topology change event accurate perception program is executed by the processor, the steps of the distribution network topology change event accurate perception method are implemented.

[0045] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0046] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the existing technology, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application.

[0047] The embodiments of the present application have been described above. The above description is illustrative and not exhaustive, and is not limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is selected to best explain the principles of the embodiments, their practical applications, or improvements to the technology in the market, or to enable other persons skilled in the art to understand the embodiments disclosed herein.

Claims

1. A method for accurately sensing distribution network topology change events, characterized in that: include: An LTP word segmentation system is used to perform entity word segmentation on distribution network topology transformation event texts; the LTP word segmentation system introduces a custom user dictionary, adds professional vocabulary related to the power field to the dictionary, and improves the accuracy of word segmentation results; A dictionary-based method is used to extract text entities of distribution network topology transformation events. The text entities include device ID, feeder ID, feeder name, voltage level, switch name, switch ID, and status before and after transformation. Use time information extraction tools to extract time entities. Specifically, traverse each distribution network topology transformation event text, record each word and its part of speech, and use the part of speech to determine whether the word is a time noun. The Bert-CRF model is used to extract the line name and manufacturer name entities of the distribution network topology change event text entity; A supervised learning method based on feature vectors is used to extract the relationships between power equipment entities. Specifically, dependency syntactic features and semantic role features are added to the relationship features to construct an entity relationship classification model, and the relationships between the entities in the distribution network topology transformation event text are obtained. A knowledge graph of distribution network topology transformation events is constructed from the bottom up based on the Neo4j graph database.

2. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The Bert-CRF model includes: The pre-trained language Bert model is used to train text word vectors, and the conditional random field (CRF) model is used to replace the softmax output layer of the Bert model. The advantages of the Bert model and the CRF model are combined to extract the line name and manufacturer name of the target entity in the text.

3. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The entity segmentation of the distribution network topology transformation event text using the LTP word segmentation system includes: The LTP word segmentation system uses the ME model to extract unigram character features, bigram character features, character type features, and dictionary attribute features from the text; Import the distribution network topology transformation event text after word segmentation, create a new data file to store the standardized text, traverse each word in the word segmentation text, determine whether the word contains special symbols, and remove the special symbols if so. Otherwise, do not process it, store the words composed of Chinese characters in the data, and output the data file to complete the standardization of the distribution network topology transformation event text.

4. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The custom user dictionary includes: Add professional vocabulary related to the power industry to the dictionary to improve the accuracy of word segmentation results; The construction of the dictionary is divided into two steps: obtaining relevant knowledge texts in the power field, collecting network links of public information of power grid companies accessible on the Internet, using web page analysis tools to analyze the network addresses and obtain the network hyperlinks hidden in the page; calling the request object to send a request to the server to obtain data, and using the request.get() function to obtain the web page data; using a breadth-first strategy, parsing the downloaded item data using regular expressions to remove irrelevant tags, and continuing to download the corresponding information for the returned new network until no new network is generated; using the json() function to encode the web page data into json data, and then decoding the json data and saving it in txt file format; With reference to national standards, a knowledge vocabulary was manually established. With reference to the State Grid Corporation's document and archive organization specifications, knowledge texts in the power field were analyzed and crawled, and keywords related to equipment failures were screened and stored in txt files, with one keyword stored per line.

5. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The method based on a dictionary is used to extract text entities of distribution network topology transformation events, including: Import dictionaries and processed text records, store entity content in the form of dictionaries, and specify a type of entity label for each dictionary; For each pre-processed distribution network topology change event text, all words in each dictionary are traversed in turn to determine whether the word appears in the text record; If it appears, it means that the distribution network topology transformation event text has a corresponding entity. The category of the corresponding entity is determined by the dictionary category to which it belongs. If it does not appear, continue traversing; When all dictionaries are traversed, all entities in the distribution network topology transformation event text are successfully extracted.

6. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The extracting of time entities using a time information extraction tool includes: Use the LTP word segmentation system to segment each distribution network topology change event text and mark the part of speech of each word; Traverse each word and its part of speech, and determine whether the word is a time noun based on the part of speech; If so, determine whether the next word is also a time noun, and continue in this way until there is a word that is not a time noun; Then connect the consecutive time nouns together to form a time entity; if not, continue traversing until each text record is traversed.

7. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: Adding dependency syntactic features and semantic role features to the relationship features includes: In the relationship extraction between power equipment entities, the entity relationship features used can be divided into two categories: basic features and syntactic and semantic features; Basic features include entity type, entity content, entity part of speech, and entity context; Syntactic and semantic features include entity dependency syntax and entity semantic roles; Dependency syntactic features describe the dependency structure in a sentence and its grammatical and semantic functions by analyzing the words and grammar in the sentence in the form of a syntactic structure tree. Through the dependency syntactic analysis results of the text, the dependent objects and dependency relationships of each entity are obtained, and the syntactic feature vector of the entity is constructed; The syntactic feature f(i) of each entity can be expressed as: (5) Where i is the entity, is the position number of the entity in the sentence, parent is the dependent object of the entity in the sentence, Indicates the position number of the dependent object in the sentence, and relate indicates the dependency relationship between the entity and the dependent object; The semantic role feature is based on sentences and takes the predicate verbs in the sentences as the core to analyze the relationship between the various components in the sentences and the predicate verbs. If there are multiple predicate verbs in a sentence, the semantic role will also have multiple layers of annotation results. The outermost layer of semantic role annotation results is determined by the core verbs in the sentence, and the annotation results of the remaining layers are determined by the various non-core verbs in the sentence. If the semantic role of an entity has multiple layers of annotation results, all the annotation results are considered when constructing the semantic role feature vector. The entity semantic feature g(i) can be expressed as (6) Where N is the maximum number of semantic role annotation layers, Srl k Represents the results of entity labeling in different semantic role layers.

8. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The constructing of the entity relationship classification model includes: After completing the sentence lexical analysis, dependency syntactic feature analysis, and semantic role feature annotation, the feature vector V(i) of each entity is established based on the dependency syntactic features and semantic role features: (7) In the formula, i represents the entity, Indicates the category of the entity, Represents entity content, Indicates the part of speech of the entity, Represents the context of the entity; Based on the basic features of entities, dependency syntactic features and semantic role features, the relationship feature vector E(i,j) of the entity pair is constructed: (8) The text is randomly divided into training text and test text in a ratio of 7:

3. The SVM classification model is trained using the relational feature vector E(i, j) in the training text to obtain the relational classifier for entity pairs. The performance of the relational classifier is tested using the test text. The entity relationship results of the distribution network topology transformation event text are predicted using the trained SVM classification model.

9. The method for accurately sensing distribution network topology change events according to claim 1, characterized in that: The construction of the distribution network topology transformation event knowledge graph includes: The knowledge graph is represented by a triple G=(E, R, S), where E={e1, e2, …en} represents the entity set; R={r1, r2…, rn} represents the relationship set of the knowledge graph; S ⊆E×R×E represents the triple set of entity E and relationship R. Represent the distribution network topology transformation event entities and entity relationships in the form of knowledge graph triples; Store the distribution network topology transformation event entities and entity relationship triples in CSV format and import the stored files into the Neo4j graph database using the Cypher language LOAD command. Use the MERGE command to identify the entities and relationships of the triples imported into Neo4j; By integrating and reasoning about the intrinsic connections between various entities and relationships, a knowledge graph of the distribution network topology transformation event domain is drawn, and the corresponding entity attribute relationships are queried through the MATCH and WHERE commands.

10. A distribution network topology change event accurate perception system, characterized by: The distribution network topology change event accurate perception system includes: A memory, a processor, and a distribution network topology change event precise perception program stored on the memory and runnable on the processor, wherein the distribution network topology change event precise perception program, when executed by the processor, implements the steps of the distribution network topology change event precise perception method according to any one of claims 1 to 9.