Equipment diagnosis method and system based on power grid event feature matching and event traceability
By building an event rule base and using Transformer model to extract and match features with RAG technology, the problem that existing power grid equipment fault diagnosis technology relies on a large amount of data and complex calculations is solved, achieving higher diagnostic accuracy and flexibility.
Patent Information
- Application Number
- CN202411576361.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-11-06
AI Technical Summary
Existing power grid equipment fault diagnosis technology relies on a large amount of data and complex calculations, and the matching is not flexible enough, making it difficult to accurately identify and process fault information in a complex power grid operating environment.
By building an event rule library, establishing a custom dictionary and inverted index library, feature extraction and matching is used using Transformer model and RAG technology to achieve grid event feature matching and event traceability.
Reliance on large amounts of real-time data and the need for complex calculations, improve the accuracy and flexibility of fault diagnosis, narrow the fault range and locate fault points, and reduce operation and maintenance costs.
Smart Images

Figure CN119621872A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of equipment diagnosis, and more specifically, relates to an equipment diagnosis method and system based on power grid event feature matching and event tracing. Background Art
[0002] With the rapid development of power grid systems, the scale and complexity of power grids are increasing, which puts higher requirements on the monitoring, diagnosis and maintenance of power grid equipment. In power systems, equipment failures often lead to abnormal operation of power grids and even cause serious consequences such as large-scale power outages. Therefore, timely and accurate fault diagnosis of power grid equipment is of great significance to ensure the safe and stable operation of power systems.
[0003] Fault diagnosis technology mainly monitors and analyzes the operating status of equipment, promptly detects abnormal conditions of equipment, and predicts possible failures, thereby avoiding losses caused by equipment failures. At the same time, with the continuous development of artificial intelligence technology, natural language processing (NLP) technology has gradually been applied to power system management. NLP technology is a technology that can understand and process human natural language, which can help people more conveniently obtain, process and use information. In the power system, NLP technology can be used to analyze reports and records of power grid events, so as to more accurately understand and process power grid events.
[0004] Existing fault diagnosis technology mainly monitors the operating status of equipment, collects relevant data of equipment, and uses data analysis and logical reasoning methods to infer the cause and location of equipment failure. This method requires a large amount of data and complex calculations, has many application restrictions, and has high requirements for data accuracy and completeness. In addition, the existing matching mechanism for power system management is not flexible enough and needs to be matched according to manually set matching rules. It is not flexible and accurate enough for the increasingly complex power grid operation environment.
[0005] The fault diagnosis techniques related to natural language processing include:
[0006] The patent with the authorization announcement number CN118410360B discloses a method and system for judging power line fault events based on natural language processing. It includes obtaining switch telemetering displacement data and protection device action information data, and converting them into data sets with unified formats respectively; analyzing and processing the data sets according to natural language processing technology, extracting key information and establishing event rule models; automatically generating power line power outage events according to established rules, and judging the fault type of power line power outage events; comparing the events judged by the fault model with the results after on-site verification, updating and correcting the power line power outage events in real time, and optimizing the event rule model. However, this method is overly dependent on natural language processing technology and the reliability of data sources. If the technology fails or there are errors or omissions in the switch telemetering displacement data and protection device action information, it will directly affect the accuracy of the subsequent analysis results, and will directly affect the normal operation and judgment results of the system; and this method mainly focuses on judging and correcting the power line fault events that have occurred, but lacks the ability to trace the source of the fault event and locate the cause of the equipment failure. It mainly relies on manual on-site verification for correction, which increases the dependence and cost of manual intervention. Summary of the invention
[0007] In order to solve the deficiencies in the prior art, the present invention provides a device diagnosis method and system based on power grid event feature matching and event tracing.
[0008] The present invention adopts the following technical solution.
[0009] The first aspect of the present invention proposes a device diagnosis method based on power grid event feature matching and event tracing, specifically:
[0010] By collecting and analyzing events occurring in the power grid, an event rule base is constructed, which includes a rule base for event characteristics of different devices and an event-based model rule base; wherein the event characteristic rule base contains event characteristics corresponding to failures or abnormalities of different devices, and the event-based model base contains event attributes and conditions for event occurrence; the condition for event occurrence is the occurrence of several event characteristics, and when these event characteristics meet a certain event logic, the event is judged to have occurred;
[0011] Establish a custom dictionary, and establish an inverted index library based on the custom dictionary, wherein the custom dictionary is a custom dictionary containing power grid terms, and the inverted index library is an index library that can search for documents or document fragments containing terms in the monitoring information of the power grid; the monitoring information includes equipment status, operation records and fault alarms;
[0012] Establish a feature extraction model, collect text data related to power grid equipment failures, segment them, and use the feature extraction model to extract features after segmentation to obtain multi-dimensional vectors. Store all the extracted multi-dimensional vectors together to form a vector index database.
[0013] When querying equipment information or warning of sudden equipment failure, the feature extraction model is used to extract the equipment information and fault warning information to obtain the query vector, and the RAG technology and vector index database are used to match the query vector features to obtain the alarm event;
[0014] Match the alarm event with the event feature rule library to obtain the event feature of the event, match the alarm event with the event model feature rule library to obtain the conditions for the event to occur, combine with the inverted index library to infer the cause and location of the alarm event, issue an alarm and display the alarm event and its event features, cause and location.
[0015] Preferably, the event characteristics contained in the event characteristic rule base include alarm type, alarm state, object information, equipment voltage level, circuit breaker connection equipment information, measurement data configuration, pre-condition, and associated sub-events; the event characteristic rule base is divided into a main transformer fault event rule base, a busbar fault event rule base, a line fault event rule base, a standby automatic switch fault event rule base, other fault event rule bases, a main transformer abnormal event rule base, a busbar abnormal event rule base, a line abnormal event rule base, a standby automatic switch abnormal event rule base, other abnormal event rule bases, an auxiliary equipment event rule base, and a main and auxiliary equipment linkage rule base according to different equipment;
[0016] The event attributes in the event-based model rule base include operation scope, event priority, event type, event level, event type, and event equipment type. Specifically, the operation scope includes the same plant station, the same bay, the same main transformer, the same equipment, the equipment connected to the circuit breaker, the same line, etc.; the event priority includes high, medium, and low; the event type includes accident, abnormality, over-limit, displacement, and notification; the event level includes critical, serious, severe, and general; the event type includes comprehensive events and combined events; the event equipment type includes lines, busbars, transformers, switches, etc.
[0017] Preferably, the establishment of a custom dictionary is specifically as follows:
[0018] Collect the monitoring information of the power grid in advance, and divide all the collected monitoring information into terms based on the word segmentation tool to form a set of custom dictionaries.
[0019] Preferably, the establishing of the inverted index library is specifically as follows:
[0020] Based on the Lucene full-text retrieval framework, one or more index items are assigned to each word obtained from the segmentation of all monitoring information. These index items point to the documents or document fragments containing the word. Each term in the custom dictionary is also added to the index, eventually forming an inverted index library.
[0021] Preferably, the text data related to the power grid equipment failure includes power grid failure reports, maintenance records, user feedback, and equipment logs;
[0022] The feature extraction model uses a bidirectional encoder representation model from Transformer, uses a word segmentation tool used when establishing a custom dictionary and an inverted index library to perform word segmentation on text data related to power grid equipment failures, and then converts them into a format that can be processed by the feature extraction model, which includes a NumPy array, a Pandas DataFrame, a TensorFlow / Keras Dataset or a TFRecord; uses it to pre-train the feature extraction model, and then annotates the text data related to power grid equipment failures according to event classification, event failure causes and failure analysis, obtains annotated power grid equipment failure event data set, and uses the data set to further train the model.
[0023] Preferably, the Transformer model is an end-to-end Seq2Seq structure, adopts a 6-layer stacked structure, stacks 6 encoders and decoders for text input and output, and the output multidimensional vector dimension is 6. Each vector represents the position of a word or phrase in the embedding space, and contains the semantic information of the vocabulary, the association between words and context information.
[0024] Preferably, RAG technology is used for rapid retrieval and matching, specifically:
[0025] Sorting similarity by calculating the cosine similarity of the vectors:
[0026] The formula for calculating cosine similarity is as follows:
[0027]
[0028] Among them, A and B are two vectors that need to be compared in similarity. i and B i are the components of vectors A and B respectively, and n is the dimension of the vector;
[0029] Calculate the cosine similarity between all vectors in the vector index database and the query vector, and sort them by similarity. Select the knowledge text or historical record with the highest similarity. According to the similarity sorting results, select the set m results with the highest similarity as candidate answers. Combine the candidate answers with the device information or fault warning information of the query to extract the alarm events.
[0030] Preferably, the alarm event is matched with the event feature rule library to obtain the event feature of the event, the alarm event is matched with the event model feature rule library to obtain the conditions for the occurrence of the event, and the cause and location of the alarm event are inferred by combining the custom dictionary and the inverted index library. Specifically, the event features of the alarm event contained in each device information and the number of times these features occur are queried through the inverted index library, the complete event logic is inferred through the conditions for the occurrence of the event, the specific device where the event occurred is obtained, and the location of the device is obtained through the device information of the device.
[0031] Preferably, when the alarm event is extracted and the event failure type that occurred is obtained and the alarm is issued and displayed, event priority management is performed, specifically: when a new event is extracted, all existing events are analyzed to see whether there is a business logic association with the new event, and the business logic is that the two events occur on the same device or are a precursor or prerequisite between the two; if there is business logic, the new event is defined as a parent event, and all existing events that have business logic with the new event are combined and defined as child events, and the event priorities of the parent event and the child event are extracted from the event model rule library. If the set parent event priority is higher than the child event, only the parent event alarm result is displayed, otherwise both the parent and child event alarm results are displayed.
[0032] The second aspect of the present invention proposes a device diagnosis system based on power grid event feature matching and event tracing using the power grid fault diagnosis method of the first aspect of the present invention, specifically:
[0033] Rule base building module: collects and analyzes events occurring in the power grid, builds event feature rule base and event model event rule base;
[0034] Inverted index library establishment system: The collected typical monitoring information is divided according to terms, and one or more index items are assigned to each word and term of the typical monitoring information based on the Lucene full-text search framework to form an inverted index library;
[0035] Feature extraction module: The collected text data related to power grid equipment failures are segmented, and after segmentation, the bidirectional encoder representation model from Teansformer is used to convert it into a multidimensional vector form and store it in the vector index database; when performing equipment information query or sudden equipment failure warning, the equipment information and the fault warning information are converted into a query vector through the bidirectional encoder representation model from Teansformer;
[0036] Matching module: uses RAG technology to search the vector index database for the knowledge text or historical record that is most similar to the query vector;
[0037] Fault analysis module: matches the alarm event with the event feature rule library to obtain the event feature of the event, matches the alarm event with the event model feature rule library to obtain the conditions for the event to occur, and combines the inverted index library to infer the cause and location of the alarm event.
[0038] The beneficial effect of the present invention is that, compared with the prior art,
[0039] (1) It solves the problem that existing fault diagnosis technology requires a large amount of data and complex calculations
[0040] By establishing an event rule library, historical events, event causes and types accumulated in the power grid operation system are collected and integrated, covering the correspondence between common fault modes, fault phenomena and fault causes. In the fault diagnosis process, the system can directly call the rules in the event rule library for matching and reasoning without re-performing complex data analysis and calculations. This reduces the reliance on large amounts of real-time data and the need for complex calculations, thereby reducing the implementation cost and operation and maintenance cost of fault diagnosis technology.
[0041] (2) Solved the problem of insufficient flexibility in matching existing power grid equipment fault diagnosis technology
[0042] The application of the Transformer model and RAG fast index matching technology to parse power grid event text can more accurately extract key information from text information such as fault reports and maintenance records, thereby improving the accuracy of fault diagnosis. At the same time, the applied Transformer model is not limited to keyword matching, but can also understand the semantics and contextual relationships of the text. This enables more flexible identification and processing of various fault information in the complex and changing power grid operating environment.
[0043] (3) Solved the problems and limitations of existing technologies in power grid equipment fault diagnosis
[0044] By introducing the event rule library and multi-dimensional information such as the physical characteristics and operating rules of the equipment, the reliance on data integrity and accuracy is reduced. The physical characteristics and operating rules are used to judge the behavior patterns of the equipment in normal and abnormal states. Through the rapid matching and reasoning of the event rule library, the fault scope is narrowed and the fault point is located, the diagnostic efficiency is improved, and the limitations of existing technologies are solved. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 It is the Transformer model structure;
[0046] Figure 2 Encoding and decoding process for Transformer model;
[0047] Figure 3 It is the vector conversion process of Transformer model;
[0048] Figure 4 Fast index matching process for RAG;
[0049] Figure 5 It is a process framework diagram of the present invention;
[0050] Figure 6 To suppress abnormal situation judgment logic diagram;
[0051] Figure 7 It is a logic diagram for judging abnormal conditions of three-phase current;
[0052] Figure 8 It is the logic diagram for judging the abnormal situation of opening and closing;
[0053] Fig. 9 This is the logic diagram for judging the abnormal situation of spring energy storage after the circuit breaker is actuated. DETAILED DESCRIPTION
[0054] In order to make the purpose, technical scheme and advantages of the present invention clearer, the technical scheme of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. The embodiments described in this application are only embodiments of a part of the present invention, rather than all embodiments. Based on the spirit of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work belong to the protection scope of the present invention.
[0055] like Figure 5 As shown, Embodiment 1 of the present invention provides a device diagnosis method based on power grid event feature matching and event tracing, specifically:
[0056] By collecting and analyzing events occurring in the power grid, an event rule base is constructed. The event rule base includes an event feature rule base and an event-based model rule base. The event feature rule base contains event features of each event. Event features include alarm type, alarm status, object information, equipment voltage level, circuit breaker connection equipment information, measurement data configuration, preconditions, and associated sub-events. The event-based model rule base contains various attributes of events and conditions for event occurrence. Attributes include operation scope, event priority, event type, event level, event type, and event equipment type. The condition for event occurrence is the occurrence of several event features. When these event features meet a certain event logic, the event is judged to have occurred.
[0057] For example, the conditions for the occurrence of events recorded in the event-based model rule base in this embodiment include: circuit breaker energy storage mechanism abnormality rule, three-phase current abnormality rule, opening and closing abnormality rule, and spring energy storage abnormality rule after action. Specifically:
[0058] like Figure 6 As shown, the abnormal rules of the circuit breaker energy storage mechanism are:
[0059] The number of suppression start action alarms within the statistical period. If it is greater than the frequent suppression warning or alarm limit, it is judged as frequent suppression;
[0060] Calculate the difference between the number of suppressions and the last time. If it is greater than the suppression trend warning or alarm limit, it is judged that the suppression trend exceeds the limit.
[0061] If the timing of the suppression start action is not reset and it is greater than the suppression duration abnormal warning or alarm limit, it is judged as suppression timeout;
[0062] Calculate the change trend of the average of the suppression duration of the previous three times. If it is greater than the suppression trend warning or alarm limit, it is judged that the suppression duration trend exceeds the limit;
[0063] If any of the above items is greater than its corresponding limit value, it is judged that the circuit breaker energy storage mechanism is abnormal. If any of the above items is greater than its corresponding warning limit value, a warning message is sent. If any of the above items is greater than its corresponding alarm limit value, an alarm message is sent.
[0064] Specifically, the frequent suppression warning limit is set to 4 times, and the frequent suppression alarm limit is set to 10 times;
[0065] The suppression trend warning limit is set to 100%, and the suppression trend alarm limit is set to 200%;
[0066] The abnormal warning limit for the suppression duration is set to 180 seconds, and the abnormal alarm limit for the suppression duration is set to 360 seconds.
[0067] like Figure 7 As shown, the three-phase current abnormality rule is:
[0068] Calculate the deviation of phase A, B and C currents and the three-phase current balance. If any current deviation is greater than the deviation limit and the three current balances are greater than the balance warning limit, it is determined that the three-phase current of the circuit breaker is seriously unbalanced and a warning signal is sent.
[0069] Specifically, the circuit deviation limit is set to 10%; and the balance warning limit is set to 10%.
[0070] like Figure 8 As shown in the figure, the abnormal rules for opening and closing are:
[0071] Calculate the maximum time difference and sending time interval of the three-phase remote signal SOE signal. If the maximum time difference is greater than the time limit or the sending time interval is greater than the delay time threshold, it is judged that the opening and closing are seriously out of sync, and a warning signal is sent.
[0072] Specifically, the time limit is set to 10ms; the delay time threshold is set to 3 seconds.
[0073] like Fig. 9 As shown in the figure, the abnormal rules of spring energy storage after action are:
[0074] Record the time the circuit breaker waits for the energy storage signal after actuation. If it is greater than the energy storage signal time limit, it is judged as no energy storage.
[0075] If the reserve start action signal is not reset, and the time is greater than the non-reset time limit, it is judged as energy storage timeout;
[0076] Calculate the change trend of the energy storage duration and the average value of the previous three times. If it is greater than the energy storage trend limit, it is judged that the energy storage duration trend exceeds the limit;
[0077] If any of the above items is greater than its corresponding limit value, it is judged that the spring energy storage is abnormal after the circuit breaker is actuated, and an early warning message is sent.
[0078] Specifically, the energy storage signal time limit is set to 2s, the non-reset time limit is set to 60s, and the energy storage trend limit is set to 30%.
[0079] Preferably, the event feature rule base includes a main transformer fault event rule base, a busbar fault event rule base, a line fault event rule base, a standby automatic throw-in fault event rule base, other fault event rule base, a main transformer abnormal event rule base, a busbar abnormal event rule base, a line abnormal event rule base, a standby automatic throw-in abnormal event rule base, other abnormal event rule base, an auxiliary equipment event rule base, and a main and auxiliary equipment linkage rule base; the various attributes of the events in the event model rule base include operation scope, event priority, event type, event level, event type, and event equipment type, specifically: the operation scope includes the same plant station, the same bay, the same main transformer, the same equipment, the circuit breaker connected equipment, the same line, etc.; the event priority includes high, medium, and low; the event type includes accident, abnormality, over-limit, displacement, and notification; the event level includes critical, severe, serious, and general; the event type includes comprehensive events and combined events; the event equipment type includes lines, buses, transformers, switches, etc.
[0080] Establish a custom dictionary, and establish an inverted index library based on the custom dictionary, wherein the custom dictionary is a custom dictionary containing power grid terms, and the inverted index library is an index library that can search for documents or document fragments containing terms in the monitoring information of the power grid; the monitoring information includes equipment status, operation records and fault alarms;
[0081] Preferably, the establishment of a custom dictionary is specifically as follows:
[0082] Collect the monitoring information of the power grid in advance, and divide all the collected monitoring information into terms based on the word segmentation tool to form a set of custom dictionaries.
[0083] Preferably, the establishing of the inverted index library is specifically as follows:
[0084] Based on the Lucene full-text retrieval framework, one or more index items are assigned to each word obtained from the segmentation of all monitoring information. These index items point to the documents or document fragments containing the word. Each term in the custom dictionary is also added to the index, eventually forming an inverted index library.
[0085] Collect text data related to power grid equipment failures, segment them, use feature extraction models to extract features after segmentation to obtain multi-dimensional vectors, and store all extracted multi-dimensional vectors together to form a vector index database;
[0086] When querying equipment information or warning of sudden equipment failure, the feature extraction model is used to extract the equipment information and fault warning information to obtain the query vector, and the RAG technology and vector index database are used to match the query vector features to obtain the alarm event;
[0087] Preferably, the text data related to the power grid equipment failure includes power grid failure reports, maintenance records, user feedback, and equipment logs;
[0088] like Figure 1 As shown, the feature extraction model uses a bidirectional encoder representation model from Transformer, uses a word segmentation tool used when establishing a custom dictionary and an inverted index library to perform word segmentation on text data related to power grid equipment failures, and then converts them into a format that can be processed by the feature extraction model, which includes NumPy arrays, PandasDataFrame, TensorFlow / Keras Dataset or TFRecord; uses them to pre-train the feature extraction model, and then annotates the text data related to power grid equipment failures according to event classification, event failure causes and failure analysis, obtains annotated power grid equipment failure event data set, and uses the data set to further train the model.
[0089] Preferably, if Figure 2 As shown in the figure, the Transformer model is an end-to-end Seq2Seq structure with a 6-layer stacked structure. Six encoders and decoders are stacked for text input and output. The output multidimensional vector dimension is 6. Each vector represents the position of a word or phrase in the embedding space, and contains the semantic information of the vocabulary, the association between words and context information.
[0090] It should be noted that the context information contained in the vector is obtained through the self-attention mechanism in the Transformer model, specifically:
[0091] like Figure 3 As shown in the figure, in the Transformer model, all texts are first converted into a set of vectors, and each of the vectors is linearly transformed (i.e. multiplied by the weight matrix and added with the bias term) to obtain the query vector Q, key vector K and value vector V. For each query vector, the similarity between it and all other key vectors is calculated. The similarity calculation formula is:
[0092]
[0093] Where Q is the query vector, K T is the transpose of the key vector, d k is the dimension of the key vector; based on the similarity calculation results, the similarity scores are normalized to the interval [0,1] using the softmax function, and the sum of all normalized similarity scores is ensured to be 1; each query vector then obtains a weighted vector
[0094] Multiply the value vector corresponding to each query vector by the corresponding weight, and sum all weighted value vectors; the result of this weighted summation is the information after considering the context information.
[0095] Preferably, if Figure 4 As shown, RAG technology is used for rapid retrieval and matching, specifically:
[0096] Sorting similarity by calculating the cosine similarity of the vectors:
[0097] The formula for calculating cosine similarity is as follows:
[0098]
[0099] Among them, A and B are two vectors that need to be compared in similarity. i and B i are the components of vectors A and B respectively, and n is the dimension of the vector;
[0100] Calculate the cosine similarity between all vectors in the vector index database and the query vector, and sort them by similarity. Select the knowledge text or historical record with the highest similarity. According to the similarity sorting results, select the set m results with the highest similarity as candidate answers. Combine the candidate answers with the device information or fault warning information of the query to extract the alarm events.
[0101] Match the alarm event with the event feature rule library to obtain the event feature of the event, match the alarm event with the event model feature rule library to obtain the conditions for the event to occur, combine with the inverted index library to infer the cause and location of the alarm event, issue an alarm and display the alarm event and its event features, cause and location.
[0102] Preferably, the alarm event is matched with the event feature rule library to obtain the event feature of the event, the alarm event is matched with the event model feature rule library to obtain the conditions for the occurrence of the event, and the cause and location of the alarm event are inferred by combining the custom dictionary and the inverted index library. Specifically, the event features of the alarm event contained in each device information and the number of times these features occur are queried through the inverted index library, the complete event logic is inferred through the conditions for the occurrence of the event, the specific device where the event occurred is obtained, and the location of the device is obtained through the device information of the device.
[0103] Preferably, when the alarm event is extracted and the event failure type that occurred is obtained and the alarm is issued and displayed, event priority management is performed, specifically: when a new event is extracted, all existing events are analyzed to see whether there is a business logic association with the new event, and the business logic is that the two events occur on the same device or are a precursor or prerequisite between the two; if there is business logic, the new event is defined as a parent event, and all existing events that have business logic with the new event are combined and defined as child events, and the event priorities of the parent event and the child event are extracted from the event model rule library. If the set parent event priority is higher than the child event, only the parent event alarm result is displayed, otherwise both the parent and child event alarm results are displayed.
[0104] In the actual test process of this embodiment, the matching accuracy of feature retrieval reaches more than 98%.
[0105] Embodiment 2 of the present invention proposes a device diagnosis system based on power grid event feature matching and event tracing using the power grid fault diagnosis method described in Embodiment 1 of the present invention, specifically:
[0106] Rule base building module: collects and analyzes events occurring in the power grid, builds event feature rule base and event model event rule base;
[0107] Inverted index library establishment system: The collected typical monitoring information is divided according to terms, and one or more index items are assigned to each word and term of the typical monitoring information based on the Lucene full-text search framework to form an inverted index library;
[0108] Feature extraction module: The collected text data related to power grid equipment failures are segmented, and after segmentation, the bidirectional encoder representation model from Teansformer is used to convert it into a multidimensional vector form and store it in the vector index database; when performing equipment information query or sudden equipment failure warning, the equipment information and the fault warning information are converted into a query vector through the bidirectional encoder representation model from Teansformer;
[0109] Matching module: uses RAG technology to search the vector index database for the knowledge text or historical record that is most similar to the query vector;
[0110] Fault analysis module: matches the alarm event with the event feature rule library to obtain the event feature of the event, matches the alarm event with the event model feature rule library to obtain the conditions for the event to occur, and combines the inverted index library to infer the cause and location of the alarm event.
[0111] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0112] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0113] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0114] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0115] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents, and any modifications or equivalent replacements that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.
Claims
1. A device diagnosis method based on power grid event feature matching and event tracing, characterized in that: include: By collecting and analyzing events occurring in the power grid, an event rule base is constructed, which includes a rule base for event characteristics of different devices and an event-based model rule base; wherein the event characteristic rule base contains event characteristics corresponding to failures or abnormalities of different devices, and the event-based model base contains event attributes and conditions for event occurrence; the condition for event occurrence is the occurrence of several event characteristics, and when these event characteristics meet a certain event logic, the event is judged to have occurred; Establish a custom dictionary, and establish an inverted index library based on the custom dictionary, wherein the custom dictionary is a custom dictionary containing power grid terms, and the inverted index library is an index library that can search for documents or document fragments containing terms in the monitoring information of the power grid; the monitoring information includes equipment status, operation records and fault alarms; Establish a feature extraction model, collect text data related to power grid equipment failures, segment them, and use the feature extraction model to extract features after segmentation to obtain multi-dimensional vectors. Store all the extracted multi-dimensional vectors together to form a vector index database. When querying equipment information or warning of sudden equipment failure, the feature extraction model is used to extract the equipment information and fault warning information to obtain the query vector, and the RAG technology and vector index database are used to match the query vector features to obtain the alarm event; Match the alarm event with the event feature rule library to obtain the event feature of the event, match the alarm event with the event model feature rule library to obtain the conditions for the event to occur, combine with the inverted index library to infer the cause and location of the alarm event, issue an alarm and display the alarm event and its event features, cause and location.
2. The device diagnosis method based on power grid event feature matching and event tracing according to claim 1 is characterized in that: The event characteristics contained in the event feature rule base include alarm type, alarm status, object information, equipment voltage level, circuit breaker connection equipment information, measurement data configuration, pre-conditions, and associated sub-events; the event feature rule base is divided into a main transformer fault event rule base, a busbar fault event rule base, a line fault event rule base, a standby automatic throw-in fault event rule base, other fault event rule bases, a main transformer abnormal event rule base, a busbar abnormal event rule base, a line abnormal event rule base, a standby automatic throw-in abnormal event rule base, other abnormal event rule bases, an auxiliary equipment event rule base, and a main and auxiliary equipment linkage rule base according to different equipment; The event attributes in the event-based model rule base include operation scope, event priority, event type, event level, event type, and event equipment type. Specifically, the operation scope includes the same plant station, the same bay, the same main transformer, the same equipment, the equipment connected to the circuit breaker, the same line, etc.; the event priority includes high, medium, and low; the event type includes accident, abnormality, over-limit, displacement, and notification; the event level includes critical, serious, severe, and general; the event type includes comprehensive events and combined events; the event equipment type includes lines, busbars, transformers, switches, etc.
3. The device diagnosis method based on power grid event feature matching and event tracing according to claim 1 is characterized in that: The establishment of a custom dictionary is specifically as follows: Collect the monitoring information of the power grid in advance, and divide all the collected monitoring information into terms based on the word segmentation tool to form a set of custom dictionaries.
4. The device diagnosis method based on power grid event feature matching and event tracing according to claim 3 is characterized in that: The establishment of the inverted index library is specifically as follows: Based on the Lucene full-text retrieval framework, one or more index items are assigned to each word obtained from the segmentation of all monitoring information. These index items point to the documents or document fragments containing the word. Each term in the custom dictionary is also added to the index, eventually forming an inverted index library.
5. The device diagnosis method based on power grid event feature matching and event tracing according to claim 4 is characterized in that: The text data related to the power grid equipment failure includes power grid failure reports, maintenance records, user feedback, and equipment logs; The feature extraction model uses a bidirectional encoder representation model from Transformer, uses a word segmentation tool used when establishing a custom dictionary and an inverted index library to perform word segmentation on text data related to power grid equipment failures, and then converts the word segmentation into a format that can be processed by the feature extraction model, which includes a NumPy array, a Pandas DataFrame, a TensorFlow / Keras Dataset or a TFRecord; the feature extraction model is pre-trained with the processed text data related to power grid equipment failures, and then the text data related to power grid equipment failures is labeled according to event classification, event failure causes and failure analysis to obtain a labeled power grid equipment failure event data set, and the data set is used to further train the model.
6. The device diagnosis method based on power grid event feature matching and event tracing according to claim 5 is characterized in that: The Transformer model is an end-to-end Seq2Seq structure with a 6-layer stacked structure. Six encoders and decoders are stacked for text input and output. The output multidimensional vector dimension is 6. Each vector represents the position of a word or phrase in the embedding space, and contains the semantic information of the vocabulary, the association between words and context information.
7. The device diagnosis method based on power grid event feature matching and event tracing according to claim 1 is characterized in that: Use RAG technology for rapid retrieval and matching, specifically: Sorting similarity by calculating the cosine similarity of the vectors: The formula for calculating cosine similarity is as follows: Among them, A and B are two vectors that need to be compared in similarity. i and B i are the components of vectors A and B respectively, and n is the dimension of the vector; Calculate the cosine similarity between all vectors in the vector index database and the query vector, and sort them by similarity. Select the knowledge text or historical record with the highest similarity. According to the similarity sorting results, select the set m results with the highest similarity as candidate answers. Combine the candidate answers with the device information or fault warning information of the query to extract the alarm events.
8. The device diagnosis method based on power grid event feature matching and event tracing according to claim 2 is characterized in that: The alarm event is matched with the event feature rule library to obtain the event feature of the event, the alarm event is matched with the event model feature rule library to obtain the conditions for the occurrence of the event, and the cause and location of the alarm event are inferred by combining the custom dictionary and the inverted index library. Specifically, the event features of the alarm event contained in each device information and the number of times these features occur are queried through the inverted index library, the complete event logic is inferred through the conditions for the occurrence of the event, the specific device where the event occurred is obtained, and the location of the device is obtained through the device information of the device.
9. The device diagnosis method based on power grid event feature matching and event tracing according to claim 2 is characterized in that: When the alarm event is extracted and the event fault type that occurred is obtained and the alarm is issued and displayed, event priority management is performed, specifically: when a new event is extracted, all existing events are analyzed to see whether there is a business logic association with the new event, and the business logic is that the two events occur on the same device or are a precursor or prerequisite between the two; if there is business logic, the new event is defined as a parent event, and all existing events that have business logic with the new event are combined and defined as child events. The event priorities of the parent event and the child event are extracted from the event model rule library. If the set parent event priority is higher than the child event, only the parent event alarm result is displayed, otherwise both the parent and child event alarm results are displayed.
10. An equipment diagnosis system based on power grid event feature matching and event tracing using the power grid fault diagnosis method according to any one of claims 1 to 9, characterized in that: Rule base building module: collects and analyzes events occurring in the power grid, builds event feature rule base and event model event rule base; Inverted index library establishment system: The collected typical monitoring information is divided according to terms, and one or more index items are assigned to each word and term of the typical monitoring information based on the Lucene full-text search framework to form an inverted index library; Feature extraction module: The collected text data related to power grid equipment failures are segmented, and after segmentation, the bidirectional encoder representation model from Teansformer is used to convert it into a multidimensional vector form and store it in the vector index database; when performing equipment information query or sudden equipment failure warning, the equipment information and the fault warning information are converted into a query vector through the bidirectional encoder representation model from Teansformer; Matching module: uses RAG technology to search the vector index database for the knowledge text or historical record that is most similar to the query vector; Fault analysis module: matches the alarm event with the event feature rule library to obtain the event feature of the event, matches the alarm event with the event model feature rule library to obtain the conditions for the event to occur, and combines the inverted index library to infer the cause and location of the alarm event.
Citation Information
Patent Citations
Power line fault event analysis method and system based on natural language processing
CN118410360B
Knowledge base construction method
CN105335488A
Event reasoning analysis alarm method and system based on lexical analysis
CN117350281A
Event categorization and key prospect identification from storylines
US20170056764A1