Method for dynamic checking of operation order based on secondary safety rule knowledge base
By constructing an operation topology and a secondary security rule base using an object-oriented inheritance model and a four-layer coupled semantic knowledge base, the problems of low efficiency and safety hazards in power dispatching operations are solved, and automated and safe operation ticket generation is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HEFEI YOUSHENG POWER TECH CO LTD
- Filing Date
- 2026-06-22
- Publication Date
- 2026-07-21
AI Technical Summary
In power dispatching operations, existing technologies suffer from low efficiency in preparing operation tickets, are prone to safety hazards due to human negligence, and lack systematic modeling of the complex functional relationships of secondary equipment, making it difficult to dynamically adapt to changes in the power grid and automatically correct conflicting steps.
By adopting an object-oriented inheritance model and a four-layer coupled semantic knowledge base, an operational topology and a secondary security rule base are constructed to perform dependency analysis and automatic conflict correction, generating conflict-free executable operation tickets.
It significantly improves the automation level and security of operation ticket preparation, can dynamically adapt to changes in power grid operation mode and topology, automatically correct conflicting steps, and generate operation tickets with standardized formats.
Smart Images

Figure CN122434464A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of operation and maintenance technology for power transmission and transformation equipment, and more specifically, to a method for dynamic verification of operation tickets based on a secondary safety rule knowledge base. Background Technology
[0002] In power dispatching operations, operation tickets are key technical documents ensuring the safe operation of the power grid. Their accuracy directly affects the safety of the operation process and the stable operation of the power grid. Traditional operation ticket preparation mainly relies on the experience of dispatchers, generating operation steps by manually checking equipment status, analyzing electrical connections, and safety rules. This is not only inefficient but also highly susceptible to human error, leading to problems such as incorrect operation sequence, mismatched equipment status, or violation of safety rules, posing significant safety hazards.
[0003] Existing rule-based automatic verification methods primarily focus on primary equipment operations, lacking systematic modeling of the complex functional relationships between secondary equipment such as protection devices, measurement and control devices, and control loops. When operations involve protection coordination logic or control linkage relationships, it is difficult to effectively assess the impact of the operation on secondary safety logic. Furthermore, existing knowledge base structures are mostly static, making it difficult to adapt to dynamic changes in power grid operation modes and topology, thus limiting their applicability to different scenarios. When a conflict between an operation and a rule is detected, existing methods typically only provide alarm prompts, lacking the ability to automatically analyze and correct conflicting steps, and cannot directly generate conflict-free executable operation sequences. Summary of the Invention
[0004] To overcome the aforementioned deficiencies of the prior art, embodiments of the present invention provide a dynamic verification method for operation tickets based on a secondary security rule knowledge base. By constructing an object-oriented inheritance model and a four-layer coupled semantic knowledge base, and performing dependency analysis and automatic conflict correction, the method solves the problems of the prior art, such as lack of secondary equipment system modeling, difficulty in dynamically adapting to scene changes, and inability to automatically correct conflict steps.
[0005] To achieve the above objectives, the present invention provides the following technical solution: This application provides a dynamic verification method for operation tickets based on a secondary security rule knowledge base. The method includes: using an object-oriented inheritance model to determine secondary devices and their functional relationships, and constructing an operation topology structure to represent operation dependencies; constructing a four-layer coupled semantic structure secondary security rule knowledge base based on the topology structure, wherein the operation topology structure guides the generation of step sequences, and the knowledge base is used for subsequent verification; performing dependency analysis based on the initial operation semantic set and operation topology structure to generate a candidate operation step sequence that satisfies operation sequence constraints, which serves as the initial operation path to be verified; calling the knowledge base to perform real-time conflict detection on each step in the candidate step sequence, correcting conflicting steps, and generating a conflict-free corrected step sequence; and performing structured encapsulation and format verification on the corrected step sequence to output an executable operation ticket.
[0006] In one embodiment, obtaining the initial operation semantic set includes: obtaining the current operating state of the power grid and the target operating state, generating a state difference set based on the equipment state differences between the two, and converting the state difference set into the initial operation semantic set.
[0007] In one embodiment, converting the state difference set into an initial operation semantic set includes: obtaining the difference units in the state difference set, removing the difference units whose states remain unchanged and filtering them using device state validity rules to obtain a valid state difference set; converting each difference unit in the valid state difference set into a corresponding operation behavior item according to predefined mapping rules for different device types and state change directions, and summarizing them to form an operation behavior set; sorting the operation behavior items in the operation behavior set according to the connection relationship between devices and preset operation dependency rules to generate an ordered operation sequence; associating each operation behavior in the operation sequence with its corresponding target state to generate an operation semantic unit, and summarizing them to obtain the initial operation semantic set.
[0008] In one embodiment, the construction of the operation topology includes: obtaining each operation semantic unit in the initial operation semantic set; performing standardized mapping of equipment objects based on the operation object information in the operation semantic units to determine the corresponding primary power equipment objects; expanding the corresponding set of secondary equipment objects based on the hierarchical association between primary and secondary equipment; extracting the functional association between secondary equipment and verifying the functional association, removing abnormal and invalid associations to obtain a set of valid equipment associations; constructing a graph structure model with secondary equipment objects as nodes and valid equipment associations as edges, assigning weights to the edges, and constructing the operation topology.
[0009] In one embodiment, a secondary security rule knowledge base with a four-layer coupled semantic structure is constructed, including: parsing the operation topology, extracting secondary equipment nodes and associated edges containing protection associations, control linkages, and signal interaction relationships, and their weights; constructing equipment layer semantic nodes based on equipment ledgers, and generating an operation behavior semantic set according to the associated edge type and weight; constructing a dynamic graph model and mapping it to a Petri net for reachability analysis, defining prohibition rules by unreachable paths, and defining restriction rules by operations with weights greater than a threshold in the optimal transition path, forming security constraint rules; constructing a context condition layer based on power grid operating conditions; and using equipment layer semantic nodes as anchors, integrating operation behavior semantics, security constraint rules, and the context condition layer to form a four-layer coupled semantic structure and generate a secondary security rule knowledge base.
[0010] In one embodiment, a dynamic graph model is constructed and mapped to a Petri net for reachability analysis, including: constructing a dynamic graph with secondary devices as nodes and mapping it to a Petri net; setting suppression arcs for the state library of mutually exclusive devices; setting corresponding transitions as mandatory constraint transitions, priority constraint transitions, and advisory constraint transitions according to protection associations, control linkages, and signal interaction relationships, forming an extended constraint Petri net; performing reachability analysis to eliminate conflicting paths; iteratively solving the optimal operation transition sequence by updating dynamic edge weights with the goal of minimizing the weight of connecting edges and the number of transition steps.
[0011] In one embodiment, dependency analysis is performed based on an initial set of operational semantics and an operational topology to generate a sequence of candidate operational steps that satisfy operational order constraints. This includes: extracting operational semantic units from the initial set of operational semantics and matching them in the operational topology to obtain an operational object association subgraph; extracting dependencies between operational objects, including electrical connection dependencies, control linkage dependencies, and protection coordination dependencies; establishing operational order constraints and operational priorities based on the dependencies to generate multiple candidate operational paths that satisfy the constraints; and validating the candidate operational paths to obtain a set of candidate operational step sequences.
[0012] In one embodiment, the knowledge base is invoked to perform real-time conflict detection on each step in the candidate step sequence, including: obtaining each operation step item in the candidate operation step sequence; inputting the operation step item into the inference rule layer of the secondary security rule knowledge base, performing semantic matching through device identifier consistency, operation type mapping, and context condition compatibility to construct a candidate rule set; activating security constraint rules that satisfy the context conditions based on the candidate rule set to obtain a valid rule set; and performing constraint consistency verification on the operation step item according to the valid rule set, determining it as a conflicting operation step item when the constraint is not satisfied.
[0013] In one embodiment, conflicting steps are corrected to generate a conflict-free corrected step sequence, including: based on the correlation between conflicting step items, solving for the minimum subset of conflict source operation steps that can explain all conflicts through set coverage optimization; calculating the conflict contribution of each step in the minimum conflict source operation step subset and generating a conflict correction priority sequence; performing correction on the conflict source steps based on the conflict correction priority sequence, the correction including at least one of equivalent substitution of operation objects, local rearrangement of execution order, and insertion of pre-constraint steps; iterating the correction until there are no conflicting steps or the conflict source subset is empty, and outputting an executable safe operation sequence.
[0014] In one embodiment, the modified step sequence is structured and format-checked to output an executable operation ticket, including: obtaining an executable safe operation sequence, encapsulating it into standardized operation step data units according to a preset operation ticket field format, mapping it to an operation ticket template and performing sequence solidification; performing integrity verification on the solidified operation ticket structure data, including field integrity and sequence consistency verification; and converting it into an executable operation ticket and outputting it to the scheduling execution terminal after the verification passes.
[0015] As can be seen from the above technical solutions, the embodiments of this application have the following advantages: By systematically modeling secondary equipment and their functional relationships using an object-oriented inheritance model and constructing an operational topology, the shortcomings of existing technologies that neglect the complex logic of secondary circuits are effectively compensated for. On this basis, a knowledge base based on a four-layer coupled semantic structure can dynamically adapt to changes in power grid operation modes and topology, breaking through the scenario limitations of static rule bases. By combining dependency analysis to generate candidate step sequences and calling the knowledge base for real-time conflict detection and automatic correction, not only is the problem that traditional methods can only issue alarms but cannot eliminate conflicts solved, but also the ability to directly output standardized, conflict-free, executable operation tickets, significantly improving the automation level, security, and scenario adaptability of operation ticket preparation. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 This is a schematic diagram of the operation ticket dynamic verification method based on a secondary security rule knowledge base provided in an embodiment of this application.
[0018] Figure 2 This is an operational object association diagram provided for embodiments of this application.
[0019] Figure 3 This is a diagram showing the storage structure of the secondary security rule knowledge base provided in the embodiments of this application.
[0020] Figure 4 A bar chart comparing the performance of operation ticket verification provided in the embodiments of this application. Detailed Implementation
[0021] To enable those skilled in the art to better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0022] Reference Figure 1 As shown in the diagram, the dynamic verification method for operation tickets based on a secondary security rule knowledge base provided by this invention includes the following steps: S1, obtain the current and target operating states of the power grid and align the equipment, generate a state difference set based on the state differences, and map it to an initial operation semantic set with sequence constraints, including: S11, Obtain the current operating status data of the power grid, wherein the current operating status data includes the real-time status information of each power device and the connection relationship information between the devices, and perform standardized processing on the current operating status data, uniformly converting it into a data structure in the form of (device identifier, device type, device status) to form a current status data set; S12, obtain target operating status information, wherein the target operating status information is used to describe the expected state of each power equipment under the target operating condition, and convert the target operating status information into a data structure form consistent with the current state data set to form a target state data set; S13, Match the devices in the current state data set and the target state data set according to the device identification information to determine the correspondence between the same device in the current state and the target state; Specifically, when a device exists in the current state data set but not in the target state data set, it is marked as a device to be exited; when a device exists in the target state data set but not in the current state data set, it is marked as a newly added device; for cases where the device names are inconsistent but the device codes are consistent, the unified device code is used as the matching basis.
[0023] S14. Based on the correspondence, compare the current state of each device with the target state one by one, extract the devices with inconsistent states, and form a state difference set. The state difference set is used to record the relationship between the device state and the target state. S15, classify the state difference set according to the equipment type and state change, and transform it into an operation behavior set; S16. Based on the connection relationships between devices and preset operation dependency rules, the set of operation behaviors is sorted in order; wherein, the preset operation dependency rules include operation rules for protection devices, operation rules for circuit breakers, operation rules for disconnecting switches, and operation rules for grounding devices; a directed dependency graph is used to represent the sequential constraints between each operation, and the execution order of each operation behavior is determined according to the topology sorting result to form an ordered operation sequence. S17, associate the operation behavior with the corresponding target state to generate operation semantic units, wherein each operation semantic unit includes operation object, operation type and target state information, and summarize the operation semantic units to generate an initial operation semantic set, which is used to describe all the operation content required to achieve the target running state.
[0024] Further, in step S15, the state difference set is categorized according to the equipment type and state change, and then transformed into an operational behavior set, including: S151, obtain each differential unit in the state differential set, wherein each differential unit in the state differential set is recorded using a quadruple structure of (device identifier, device type, current state, target state); The device identifier is used to uniquely identify the corresponding power equipment, the device type is used to characterize the category to which the equipment belongs, the current state is used to characterize the actual state of the equipment under the current operating mode, and the target state is used to characterize the expected state of the equipment under the target operating mode.
[0025] S152, perform preliminary classification of the differential units based on equipment type, wherein an equipment type classification rule base is established, and the differential units are classified according to the equipment type code; the equipment type classification rule base includes at least: switchgear, protection and automatic devices, measurement and control and secondary circuits, and auxiliary equipment; The categories are as follows: Switchgear includes circuit breakers, disconnectors, and grounding switches; Protection and automatic devices include line protection devices, busbar protection devices, safety automatic devices, and reclosing devices; Measurement and control and secondary circuits include measurement and control devices, remote signaling circuits, and remote control circuits; Auxiliary equipment includes communication equipment, power supply equipment, and monitoring equipment; and corresponding differential sets are formed based on the equipment type classification rule base.
[0026] S153, within each set of differences, identify the change relationship based on the state coding difference between the current state and the target state; Among them, a state change determination rule table is established, as shown in Table 1: Table 1. Rules for Determining State Changes
[0027] The state change relationship corresponding to each differential unit is determined according to the state change determination rule table, and the direction of state change is identified; S154, remove the difference cells whose state remains unchanged, and perform validity screening on the remaining difference cells; Among them, a device status legality rule base is established, which records the allowed state change relationships of each device in the form of a state transition matrix; For switchgear: allowed to close → open, open → close; prohibited: fault → close, maintenance → close. For protection and automatic devices: allowed to engage → disengage, disengage → engage; prohibited: fault → engage, interlock → engage. For state changes that do not meet the state transition matrix constraints, they are judged as abnormal state changes and filtered to form an effective state difference set.
[0028] S155, Based on the combination relationship between device type and state change direction, establish a mapping rule set from state difference to operation type, and the mapping rule set is stored in the operation semantic rule base in the form of a rule table; The mapping rule set is shown in Table 2: Table 2 Mapping Rule Set
[0029] S156, Invoke the mapping rule set to transform the effective state difference set one by one to generate the corresponding operation behavior item; Specifically, the operation object is determined based on the equipment identifier in the differential unit; the corresponding mapping rule is queried based on the equipment type and the direction of status change; and the corresponding operation behavior item is generated. Each operation behavior item is represented by a data structure of (operation object, operation type). The operation object is described by a combination of identifiers: "plant name + voltage level + bay name + equipment name".
[0030] S157, standardize the generated operation behavior items, and aggregate the standardized operation behavior items to form an operation behavior set.
[0031] The standardization process includes standardizing the operation objects using a unified naming rule and expressing the operation types using preset standard operation terms, thereby eliminating expression differences caused by data from different sources.
[0032] It should be noted that, based on the difference-driven mechanism between the current operating state and the target operating state of the power grid, the automatic identification and structured expression of equipment state changes are realized. The operation process that originally relied on manual experience or semantic analysis is transformed into a rule-based mapping and sequential generation process based on state difference. This can improve the accuracy and consistency of operation semantic generation, reduce errors caused by manual intervention and semantic ambiguity, and at the same time, through equipment type classification, state legality screening and topology constraint sorting, the generated initial operation semantic set has stronger power grid adaptability and execution reliability, and provides a clear and logically consistent basic data support for subsequent safety verification and automatic generation of operation tickets.
[0033] S2, based on the initial operation semantic set, combined with the power grid equipment model and real-time operation data, an object-oriented inheritance model is used to determine the secondary equipment and their functional relationships, and an operation topology structure for representing operation dependencies is constructed, including: S21, obtain each operation semantic unit in the initial operation semantic set, wherein each operation semantic unit includes operation object, operation type and target state information, which is used to characterize the operation requirements at the primary equipment level of the power grid; S22, Based on the operation object information in the operation semantic unit, perform standardized mapping of equipment objects, and convert the operation object into a standard equipment identifier consistent with the preset power grid equipment model through equipment coding rules and equipment ledger information. Based on the standard equipment identifier, determine the corresponding primary power equipment object in the power grid equipment model. The power grid equipment model is used to uniformly describe the entity information of power grid equipment and the equipment association relationship, including at least equipment identification information, equipment type information, voltage level information, bay information, topology node information, operating status information, and equipment association rule information.
[0034] S23, invoke the pre-established object-oriented inheritance model to determine the equipment category and inheritance attributes corresponding to the primary equipment object; The object-oriented inheritance model is constructed using a hierarchical inheritance structure of equipment base class—equipment category—specific equipment object; the equipment base class defines at least equipment identification attributes, equipment status attributes, and equipment function attributes; the primary equipment class inherits the attributes of the equipment base class and extends electrical connection attributes; the secondary equipment class inherits the attributes of the equipment base class and extends protection attributes, control attributes, and measurement and control attributes; and the corresponding function attributes, association attributes, and operation characteristic attributes are obtained according to the equipment category to which the primary equipment object belongs.
[0035] S24. Determine the set of secondary equipment objects associated with the primary equipment object according to the equipment association rules in the power grid equipment model; Specifically, the process involves associating and retrieving information based on the equipment's bay information, topology node information, protection configuration relationships, control configuration relationships, and measurement and control configuration relationships; identifying the protection devices, automatic devices, measurement and control devices, merging units, intelligent terminals, and control loop devices corresponding to the primary equipment objects; and forming a set of secondary equipment objects.
[0036] S25, Obtain the functional attributes of each secondary device object based on the object-oriented inheritance model; Identify the functional logical relationships between devices based on the functional attributes of each secondary device object; The functional logic relationships include at least the following: protection coordination relationships, control linkage relationships, signal acquisition relationships, interlocking constraint relationships, and status feedback relationships, forming an initial set of device relationship relationships.
[0037] S26, Obtain real-time operating status data corresponding to the association relationship with the initial device; The real-time operating status data includes at least: operating status, maintenance status, lockout status, and communication status; The validity of the initial device association is verified based on the real-time operating status. For each association, the real-time status of the source device object and the target device object corresponding to the association is read. If both the source device object and the target device object meet the following conditions: in operation, non-maintenance, non-locked, and normal communication, the corresponding association is retained. Otherwise, the corresponding association is marked as a failed association and removed to form a set of valid device associations.
[0038] S27, Construct the initial operational topology based on the set of valid device associations; In this process, secondary equipment objects are used as topology nodes, and effective equipment association relationships are used as topology edges. The edge direction is determined according to the type of association relationship: protection coordination relationship corresponds to protection dependency edge, control linkage relationship corresponds to control dependency edge, signal acquisition relationship corresponds to information transmission edge, interlocking constraint relationship corresponds to constraint dependency edge, and state feedback relationship corresponds to state feedback edge, thus forming the initial operation topology structure.
[0039] S28, assign weights to each topological edge in the initial operational topology to form the operational topology; Specifically, a weight mapping table is pre-built, and basic weight values are assigned according to the type of association relationship; the electrical importance level is divided into different levels according to the voltage level and power supply importance of the equipment in the power grid, and a corresponding level coefficient is set; the action priority is determined according to the operation sequence constraint relationship and a priority coefficient is assigned, and finally the connection edge weight value is obtained by weighted calculation of the basic weight value and the above coefficients.
[0040] The specific formula for calculating the weight value of the connecting edge is as follows:
[0041] In the formula, These are the weight values for the connecting edges. Basic weight value, For preset level coefficients, This is the preset action priority coefficient.
[0042] The operational topology is used to characterize the mapping relationship between the operation object and the secondary device, the functional dependency relationship between the secondary devices, the constraint propagation relationship during the operation execution process, and the dependency relationship during the operation sequence generation process. It also provides basic topological support for the subsequent construction of the secondary security rule knowledge base, the generation of candidate operation paths, and security verification.
[0043] It should be noted that by standardizing the mapping of operation objects in the initial operation semantic set, and combining the power grid equipment model to realize the association extension between primary and secondary equipment, and by using the object-oriented inheritance model to obtain equipment category characteristics, functional attributes, and operation characteristics, a unified equipment object expression system is established. Furthermore, based on protection coordination relationships, control linkage relationships, signal acquisition relationships, interlocking constraint relationships, and state feedback relationships, the functional logical associations between equipment are identified, and the associations are dynamically verified in conjunction with real-time operating status to eliminate failed associations and improve the accuracy and real-time performance of the associations. On this basis, a weighted operation topology structure is constructed to express the dependencies, constraint propagation relationships, and operation sequence relationships between equipment in a graph structure, so that the mapping relationship between operation objects and secondary equipment, as well as the logical association relationship within the secondary system, are uniformly modeled. This not only improves the automation level of operation object identification and equipment association analysis and reduces reliance on human experience, but also accurately reflects the actual constraint relationship between secondary equipment under different operating conditions. It provides a data foundation with topological consistency, logical integrity and dynamic adaptability for subsequent construction of secondary safety rule knowledge base, generation of candidate operation paths and safety verification, thereby improving the accuracy, security and intelligence level of the automatic generation and dynamic verification process of operation tickets.
[0044] S3, based on the initial operation semantic set, constructs a multi-layered semantic secondary security rule knowledge base including device association, state inference, and security constraints, including: S31, perform graph structure parsing on the operation topology to extract secondary device nodes, associated edges and their weight information, wherein the associated edges include protection association relationships, control linkage relationships and signal interaction relationships; S32, construct a semantic structure for the equipment layer based on the secondary equipment nodes and equipment ledger data, wherein, as shown in the figure... Figure 2As shown, the secondary equipment is classified according to protection devices, measurement and control devices and control circuits, and the equipment identification, voltage level, bay to which it belongs and operating status are structured to obtain a set of semantic nodes at the equipment layer. S33, construct the semantic structure of the operation behavior layer based on the associated edges and their relationship types, wherein the protection association relationship is mapped to the protection action type, the control linkage relationship is mapped to the control operation type, the signal interaction relationship is mapped to the signal trigger type, and the operation behavior priority is determined according to the weight of the associated edges to obtain the operation behavior semantic set; Specifically, determining the priority of operation behavior based on the weight of the associated edge involves: normalizing the weight value of the connection edge to the range of [0,1]. The larger the weight value, the higher the degree of influence between devices, and the higher the priority of the corresponding operation behavior. The initial weight value is set according to the electrical distance between devices or the historical operation frequency.
[0045] S34. Construct a dynamic graph model and map it to a Petri net model. Perform reachability analysis based on the dynamic graph model and Petri net model, and output the optimal operation transition sequence. S35. Construct a semantic structure for the security constraint layer based on the set of unreachable paths and the optimal operation transition sequence. Here, the operation behavior corresponding to the unreachable path is defined as the prohibition rule, and the operation behavior with the weight value of the connecting edge in the security transition path that is greater than a preset threshold is defined as the restriction rule, thus obtaining a set of security constraint rules. S36, based on the power grid operating conditions, including voltage level, operating mode and topology connection relationship, constructs a context condition layer semantic structure, which specifically includes: classifying voltage level into different operating level labels, classifying operating mode into normal operating mode, maintenance mode and accident mode, and encoding topology connection relationship into node connectivity constraint expression, thereby forming a set of rule applicability conditions; S37, based on the semantic structure of the device layer, the semantic structure of the operation behavior layer, the semantic structure of the security constraint layer, and the semantic structure of the context condition layer, a four-layer coupled semantic structure of "device-behavior-constraint-condition" is formed by association and fusion. Specifically, the operation behavior layer is mapped to the corresponding device node based on the semantic node of the device layer; and the security constraint layer and the context condition layer are bound to the operation behavior node as preconditions for rule triggering.
[0046] S38. Based on a four-layer coupled semantic structure, a condition-behavior-result reasoning rule layer is constructed. The context condition layer is used as the rule triggering condition, the operation behavior layer is used as the execution action, the security constraint layer is used as the execution verification condition, and the execution result status is used as the output result, forming a standardized rule expression form. S39, the semantic structure of the device layer, the semantic structure of the operation behavior layer, the semantic structure of the security constraint layer, the semantic structure of the context condition layer, and the reasoning rule layer are uniformly and structurally encapsulated to generate a multi-layer semantic secondary security rule knowledge base for power secondary operation verification.
[0047] Among them, such as Figure 3 As shown, the secondary security rule knowledge base is constructed using a hybrid storage format of "graph structure + rule base", including: a graph structure layer for storing device nodes and their relationships; a rule engine layer for storing condition-action-result reasoning rules; and an index mapping layer for enabling fast retrieval of device identifiers and rule entries.
[0048] It should be noted that by combining the operational topology with the dynamic graph-Petri net reasoning results, a multi-layer semantic structure containing devices, behaviors, constraints, and contextual conditions is constructed. This transforms the safety rules from static empirical rules into a rule system dynamically generated based on device relationships, state evolution, and optimal operation paths. This significantly improves the accuracy, consistency, and scalability of the safety rules, while also being able to adapt to different operating modes and topology changes, enabling refined constraints and intelligent verification of secondary power operations.
[0049] Further, in step S34, a dynamic graph model is constructed and mapped to a Petri net model. Reachability analysis is performed based on the dynamic graph model and the Petri net model to output the optimal operation transition sequence, including: S341, a dynamic graph model is constructed based on the operating topology and real-time power grid operating status data; In this system, secondary devices are used as nodes, functional relationships between devices are used as edges, and the weight of the connecting edges represents the degree of influence between devices. The node status is updated according to changes in device operating status. When the device status changes, the corresponding node attributes are updated. The edge connection relationship is updated according to changes in topology connection. When the connection relationship between devices changes, the corresponding edge is added or deleted.
[0050] S342, the dynamic graph model is mapped to a Petri net model, wherein different operating states of each device are defined as different places, the process of changing device state is defined as a transition, the current state of the device is initialized to the mark in the corresponding place, and the capacity of the mutually exclusive state place of the same device is set to 1 and a suppression arc is added to ensure that at any time there is at most only one mutually exclusive place containing the mark. The specific method for setting the suppression arc for the mutual exclusion state library of the same device is as follows: For the mutual exclusion state library of device A... and Add from Point to enter The inhibition arc of the transition, and from Point to enter The suppression arc of the transitions prevents the triggering of an entry transition to another location when one location contains a tag.
[0051] It should be noted that the Petri net model is a mathematical model consisting of places (representing states), transitions (representing events), and labels (representing state occupancy) to describe the dynamic evolution of state changes and concurrency, synchronization, and constraint relationships in a system.
[0052] S343, Based on the relationship and weight of the associated edges in the dynamic graph model, set trigger constraints for the transitions of the Petri net model; Specifically, for protection relationships, the corresponding transitions are set as mandatory constraint transitions: a condition place is added to the transition in the Petri net model, and this condition place is marked only when the protection device required by the protection relationship is in an allowed operation state; otherwise, the transition cannot be triggered. For control linkage relationships, the corresponding transitions are set as priority constraint transitions: priority weight values are assigned to the transitions, where the priority weight corresponding to control linkage relationships is higher than that corresponding to non-control linkage relationships. When multiple transitions simultaneously meet the triggering conditions (the triggering conditions refer to all previous places of the transition containing the mark, and the transition not being prohibited by mandatory constraint conditions), the transition with the highest priority weight is triggered first. For signal interaction relationships, the corresponding transitions are set as advisory constraint transitions: the triggering of this transition is not subject to mandatory blocking conditions, but is only used as a reference for the recommended order in the reachability analysis. When it conflicts with other constraints, it is automatically discarded first. And based on the power operation sequence rules, transition triggering sequence constraints are set to obtain an extended constraint Petri net model; It should be noted that the priority weight values of the priority constraint transitions are represented by integers, ranging from 1 to 10. The default priority of transitions corresponding to control linkage relationships is set to 7 to 10, and the default priority of transitions not related to control linkage relationships is set to 1 to 6.
[0053] S344, based on the extended constraint Petri net model, state reachability analysis is performed. By marking the flow process between warehouses, a set of transition paths from the current state to the target state is generated, and conflict detection is performed on the set of transition paths. When there are mutually exclusive operations on the same device state, repeated occupation of the same resource, or violation of constraints in different transition paths, they are identified as conflict paths and eliminated. At the same time, all paths that cannot reach the target state due to violation of constraints or mutual exclusive operations are recorded as an unreachable path set, thus obtaining a safe transition path set. S345, Update edge weights in dynamic graph models based on the set of safe transition paths; In this process, when a conflict occurs in the path corresponding to a certain associated edge, its weight is increased according to a preset incremental coefficient. When the path continuously satisfies the constraint conditions, its weight is decreased according to a preset decay coefficient, thereby obtaining a dynamically updated dynamic graph model. Based on the dynamically updated dynamic graph model and the Petri net reachability analysis results, the set of safe transition paths is optimized and selected. The optimization objectives are to minimize the weight values of the connecting edges and the number of transition steps, and to determine the optimal operation transition sequence.
[0054] Then, based on the updated dynamic graph model and Petri net reachability analysis results, with the optimization objectives of minimizing the edge weights and the number of transition steps, the optimal operation transition sequence is output through iterative calculation until the preset convergence condition is met.
[0055] The convergence condition is as follows: the absolute value of the maximum change in all edge weights in two consecutive iterations is less than a preset change threshold, or the number of iterations reaches a preset maximum number of iterations.
[0056] The edge weights are updated, and the specific calculation formula is as follows:
[0057] In the formula, At time t, the associated edges The weight values of the connecting edges, Updated edge weights This is an increment coefficient used to control the magnitude of the weight increase when a conflict occurs. The attenuation coefficient controls the rate at which the weights decrease due to the safe path. The conflict intensity factor is obtained by taking the ratio of the number of conflicting paths containing that edge to the total number of paths containing that edge at time t. The stability factor is obtained by comparing the length of the current continuous, conflict-free path with the preset maximum stable length.
[0058] It should be noted that the optimal operation transition sequence is output based on the reachability analysis of dynamic graphs and Petri nets. This means that safety constraints no longer rely on static rule judgments, but are dynamically derived from the device state evolution path, interlocking relationships, and conflict detection results. This enables unreachable paths and high-risk paths to be transformed into prohibition or restriction rules, significantly improving the accuracy and dynamic adaptability of the semantic structure of the safety constraint layer. At the same time, it enhances the ability to identify complex interlocking relationships, temporal dependencies, and potential conflicts, providing a more reliable and verifiable safety decision-making basis for subsequent operation execution.
[0059] S4. Based on the initial operation semantic set and operation topology, generate a sequence of candidate operation steps, wherein the candidate operation steps include operation tasks, operation objects and operation order information.
[0060] In this embodiment, based on the initial operation semantic set and operation topology, a candidate operation step sequence is generated, including: S41, extract each operation semantic unit from the initial operation semantic set, wherein each operation semantic unit includes operation object, operation type and target state information; S42, based on the operation objects in the operation semantic unit, match them in the operation topology to determine the corresponding device nodes and their association relationships, and obtain the operation object association subgraph; S43, Based on the operation object association subgraph, extract the association paths and dependencies between each operation object, wherein the dependencies include electrical connection dependencies, control linkage dependencies, and protection coordination dependencies, to obtain an operation dependency set; S44. Based on the set of operation dependencies, determine the pre- and post-constraint relationships of each operation semantic unit. When the execution result of one operation semantic unit is used as a precondition of another operation semantic unit, establish the order dependency relationship between the two to obtain the set of operation order constraints. S45, construct the operation priority relationship based on the operation order constraint set, wherein operation semantic units with sequential dependencies are assigned sequential execution priorities, and operation semantic units without direct dependencies are marked as operations that can be executed in parallel, thus obtaining the operation priority set; S46, Based on the operation priority set, sort the operation semantic units to generate multiple candidate operation paths that satisfy the order constraint conditions; S47, perform a legality check on the candidate operation path. If the operation steps in the candidate operation path can be executed in sequence to enable the device state to gradually transition from the current state to the target state and the changes in each intermediate state are in line with the device operation mechanism, it is determined to be a valid path and a set of candidate operation step sequences is obtained. S48, perform structured expression processing on the candidate operation step sequence set, convert the operation semantic unit in each operation path into operation step item according to the execution order, wherein each operation step item includes operation task, operation object and operation order information, and generate candidate operation step sequence.
[0061] S5. For each operation step, the secondary security rule knowledge base is called for real-time verification, and conflicting operation step items are corrected to generate a conflict-free corrected step sequence.
[0062] In this embodiment, for each operation step, the secondary security rule knowledge base is invoked for real-time verification, including: S51, obtain each operation step item in the candidate operation step sequence, wherein each operation step item includes operation task, operation object and operation sequence information; S52, the operation step item is input into the reasoning rule layer of the secondary security rule knowledge base, wherein a candidate rule set corresponding to the operation step item is constructed by semantic matching of the context condition layer semantics, the operation behavior layer semantics and the security constraint layer semantics. The semantic matching is achieved based on device identifier consistency matching, operation type mapping matching, and context condition compatibility matching. S53, construct a rule triggering function based on the candidate rule set. When the operation step item satisfies the context conditions defined by the rule triggering function, activate the corresponding security constraint rule to obtain the effective rule set. The rule trigger function The specific calculation formula is as follows:
[0063] In the formula, To represent the i-th operation step, information includes the operation task, the operation object, the operation type, and the operation sequence. For security rule j, the following are included: context conditions, operational behavior constraints, security limitations, and the scope of applicable equipment. For context-consistency matching, it indicates the degree of matching between the operation steps and the context conditions of the rules. The operation type is mapped to a matching degree, which measures whether the operation behavior conforms to the operation semantics defined by the rules. For device identifier consistency matching, it is used to measure whether the operation object is consistent with the rule device. , , These are the weighting coefficients, The threshold for triggering the rule. This is the activation function, also known as the step function, used to implement a binary determination of whether a rule is triggered.
[0064] S54, perform constraint consistency verification on the operation step item based on the set of valid rules, wherein it is determined whether the operation step item satisfies the safety constraint expression. If the function value is 1, it means the constraint is satisfied; otherwise, the constraint is not satisfied. S55, when the verification result is that the constraint is not met, the operation step item is determined to be a conflicting operation step item.
[0065] The specific calculation formula for the contextual condition compatibility matching is as follows:
[0066] In the formula, For voltage level matching, For voltage level, These are the minimum and maximum voltages, respectively. To match the operating mode, This refers to the operation steps and running mode. To determine the applicable operating mode of the rules, For topology state matching, The number of common topological connecting edges. The rule involves the total number of edges in the topology. , , These are the weights.
[0067] The specific formula for calculating the operation type mapping matching degree is as follows:
[0068] In the formula, Encode the type of operation steps. Encodes the operation type defined by the rule.
[0069] The specific calculation formula for the device identifier consistency matching is as follows:
[0070] In the formula, For the standard identification of equipment in the operation procedure, The device identifier constrained in the rule. To indicate the difference in distance between the devices. This is the preset attenuation factor.
[0071] Furthermore, conflicting operation steps are corrected to generate a conflict-free corrected step sequence, including: S56. Based on the set of conflicting step items, establish a conflict propagation relationship graph, and determine the minimum interpretation set through a set coverage optimization model. The minimum interpretation set is used to characterize the minimum subset of conflict source operation steps that can explain all conflicting step items. The minimum explanatory set is determined by the following constrained optimization model:
[0072] ,
[0073]
[0074] In the formula, n is the total number of candidate operation steps, which represents the upper limit of the size of the operation steps that can participate in constructing the minimum interpretation set. Let be the decision variable, representing whether the i-th operation step is selected into the minimum explanation set. When this occurs, it indicates that the operation step has been selected as a source of conflict interpretation. This indicates that the operation step is not selected, and m is the total number of conflicting steps, used to represent the number of conflicts detected in the system. The conflict explanation correlation coefficient (0-1 parameter) indicates whether the operational steps can explain the conflict. This indicates that the i-th operation step can resolve the j-th conflict. This indicates that the i-th operation step cannot resolve the j-th conflict.
[0075] S57. Based on the minimum interpretation set, calculate the conflict contribution degree for each conflict operation step item. The conflict contribution degree is used to characterize the degree of influence of the operation step on the overall conflict set. Based on the conflict contribution degree, prioritize the operation step items in the minimum interpretation set to generate a conflict correction priority sequence. The specific formula for calculating the conflict contribution is as follows:
[0076] In the formula, The contribution to conflict is used to characterize the strength of the impact of this step on the overall conflict set; a larger value indicates a more critical impact. For conflict weighting coefficients, This represents the shortest path distance between operation steps and conflicts within the operation topology. The stability coefficient of the operation step is used to represent the reliability of the operation step in historical execution or real-time operation.
[0077] S58, Based on the conflict correction priority sequence, the conflict operation step items in the minimum interpretation set are corrected one by one to generate a correction step sequence, wherein the correction process includes at least one of the following methods: Perform equivalent substitution processing on the operation objects in the conflicting operation steps, so that they are mapped to alternative device objects that meet the safety constraints; The execution order of conflicting operation steps is partially rearranged to satisfy the equipment state evolution constraints. Conflicting operation steps are inserted as pre-constraint steps to eliminate state dependency conflicts; S59, if the correction step sequence no longer contains conflicting step items, or the minimum interpretation set is empty, stop the correction iteration process and output the final corrected operation step sequence as an executable safe operation sequence.
[0078] It should be noted that by introducing a minimum interpretation set to model the conflict source at the set level, the traditional conflict localization method based on a single path or a single node is transformed into solving the global minimum conflict interpretation subset, thereby avoiding the problems of conflict misjudgment and path dependency error accumulation. Furthermore, the priority of correction is optimized by ranking by contribution, making the conflict correction process more globally consistent and convergent.
[0079] S6 performs structured encapsulation and format verification on the revised step sequence, outputting an executable operation ticket to guide on-site or remote operation execution in the power system, including: S61, obtain the executable safety operation sequence, and encapsulate it according to the preset operation ticket field format to form a standardized operation step data unit; S62, based on the preset operation ticket template, the standardized operation step data unit is mapped to the operation ticket field structure, and the operation ticket field structure includes at least the operation task, operation object identifier and operation sequence information; S63, Based on the operation sequence information, the operation ticket field structure is subjected to sequence solidification processing to generate ordered operation ticket structure data that meets the execution sequence requirements; S64, Perform integrity verification on the ordered operation ticket structure data to verify whether it meets the requirements of field integrity and order consistency. First, each operation ticket record undergoes a field integrity check based on the preset operation ticket field specifications. This checks whether it contains required fields such as operation task, operation object identifier, and operation sequence information, and verifies whether each field is empty, whether the format is valid, and whether it conforms to standard coding rules. Next, the consistency of the operation sequence is verified. The sequence identifiers in the operation ticket are sorted and compared according to an ascending order or a preset topology execution order to detect any sequence jumps, duplicate numbers, or inconsistencies with the equipment state evolution logic. If all operation steps meet the field integrity requirements and the sequence relationship is consistent with the equipment state change logic, the ordered operation ticket structure data is deemed to have passed the integrity check; otherwise, the corresponding abnormal field or sequence conflict position is marked and the check fails.
[0080] S65, if the ordered operation ticket structure data passes the integrity check, it is converted into an executable operation ticket and output to the scheduling execution terminal.
[0081] To verify the effectiveness of the proposed dynamic verification method for operation tickets based on a secondary safety rule knowledge base, a sample of historical operation tickets from a power grid dispatch center was selected as test data. The traditional rule matching verification method and the method of this invention were compared and verified. During the test, both methods performed operation ticket generation and safety verification under the same equipment model, operating mode, and target operating conditions. Statistical results are as follows: Figure 4 And as shown in Table 3. From Figure 4 As can be seen, the present invention significantly outperforms traditional methods in key indicators such as conflict identification rate, operation sequence accuracy, and automatic correction success rate, while also significantly reducing the average verification time. Table 3 shows that the conflict identification rate of the present invention reaches 97.8%, an improvement of 15.4 percentage points compared to the traditional method; the operation sequence accuracy reaches 98.2%, and the automatic correction success rate reaches 95.6%, both significantly higher than the traditional method; simultaneously, the average verification time is reduced from 8.9 seconds to 3.4 seconds. This indicates that the present invention not only improves the accuracy of operation ticket security verification but also enhances the efficiency of operation ticket generation and verification, verifying the feasibility and practical value of the present invention in the intelligent generation and dynamic verification scenario of power secondary operation tickets.
[0082] Table 3 Comparison of Operation Ticket Verification Results
[0083] The above formulas are all dimensionless calculations. The formulas are derived from software simulations based on a large amount of collected data to obtain the most recent real-world results. The preset parameters in the formulas are set by those skilled in the art according to the actual situation.
[0084] The above embodiments can be implemented, in whole or in part, by software, hardware, firmware, or any other combination thereof. When implemented using software, the above embodiments can be implemented, in whole or in part, in the form of a computer program product.
[0085] Those skilled in the art will recognize that the modules and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0086] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0087] In conclusion, the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for dynamic verification of operation tickets based on a secondary security rule knowledge base, characterized in that, include: An object-oriented inheritance model is used to determine the secondary devices and their functional relationships, and an operational topology structure is constructed to represent operational dependencies. Based on the aforementioned topology, a secondary security rule knowledge base with a four-layer coupled semantic structure is constructed, wherein the operational topology is used to guide the generation of the step sequence, and the knowledge base is used for subsequent verification. Dependency analysis is performed based on the initial operation semantic set and operation topology to generate a sequence of candidate operation steps that satisfy the operation order constraints. This sequence serves as the initial operation path to be verified. The knowledge base is invoked to perform real-time conflict detection on each step in the candidate step sequence, and conflicting steps are corrected to generate a conflict-free corrected step sequence. The revised sequence of steps is encapsulated in a structured manner and its format is checked, and an executable operation ticket is output.
2. The method according to claim 1, characterized in that, The acquisition of the initial operation semantic set includes: The current operating state and the target operating state of the power grid are obtained. A state difference set is generated based on the equipment state differences between the two, and the state difference set is converted into an initial operation semantic set.
3. The method according to claim 2, characterized in that, The step of converting the state difference set into an initial operation semantic set includes: Obtain the differential cells in the state differential set, remove the differential cells whose states remain unchanged, and filter them using the device state validity rules to obtain the valid state differential set; Based on predefined mapping rules for different device types and state change directions, each differential unit in the effective state differential set is converted into a corresponding operation behavior item, and then summarized to form an operation behavior set. Based on the connection relationships between devices and preset operation dependency rules, the operation behavior items in the set of operation behaviors are sorted in order to generate an ordered operation sequence. Each operation in the operation sequence is associated with its corresponding target state to generate an operation semantic unit, which is then aggregated to obtain an initial operation semantic set.
4. The method according to claim 1, characterized in that, The construction of the operational topology includes: Obtain each operation semantic unit in the initial operation semantic set, perform standardized mapping of equipment objects based on the operation object information in the operation semantic unit, and determine the corresponding primary power equipment object; Based on the hierarchical relationship between primary and secondary equipment, the corresponding set of secondary equipment objects is obtained. Extract the functional relationships between secondary devices, verify the functional relationships, remove abnormal and invalid relationships, and obtain a set of valid device relationships; A graph structure model is constructed using secondary device objects as nodes and effective device associations as edges. Weights are assigned to the edges to construct the operational topology.
5. The method according to claim 1, characterized in that, The secondary security rule knowledge base, which constructs a four-layer coupled semantic structure, includes: The operation topology is parsed to extract secondary device nodes and associated edges containing protection associations, control linkages, and signal interaction relationships, along with their weights. Based on the equipment ledger, construct equipment layer semantic nodes and generate a set of operational behavior semantics according to the associated edge type and weight; A dynamic graph model is constructed and mapped to a Petri net for reachability analysis. Prohibition rules are defined by unreachable paths, and restriction rules are defined by operations with weights greater than a threshold in the optimal transition path, thus forming safety constraint rules. Construct a context condition layer based on power grid operating conditions; Using device-level semantic nodes as anchors, the system integrates operational behavior semantics, security constraint rules, and contextual condition layers to form a four-layer coupled semantic structure, and generates a secondary security rule knowledge base.
6. The method according to claim 5, characterized in that, The construction of a dynamic graph model and its mapping to a Petri net for reachability analysis includes: Construct a dynamic graph with secondary devices as nodes and map it as a Petri net, and set suppression arcs for the state library of mutually exclusive devices; Based on the relationships of protection association, control linkage and signal interaction, the corresponding strain transitions are respectively set as mandatory constraint transitions, priority constraint transitions and advisory constraint transitions, forming an extended constraint Petri net; Reachability analysis is performed to eliminate conflicting paths. Dynamic edge weight updates are used to iteratively solve the problem with the goal of minimizing the weight of connecting edges and the number of transition steps, and the optimal operation transition sequence is output.
7. The method according to claim 1, characterized in that, The dependency analysis based on the initial operation semantic set and operation topology structure generates a sequence of candidate operation steps that satisfy the operation order constraints, including: Extract operational semantic units from the initial operational semantic set, and match them in the operational topology to obtain an operational object association subgraph; Extract the dependencies between the operation objects, including electrical connection dependencies, control linkage dependencies, and protection coordination dependencies; Based on the dependencies, operation order constraints and operation priorities are established, and multiple candidate operation paths that meet the constraints are generated; the legality of the candidate operation paths is verified to obtain a set of candidate operation step sequences.
8. The method according to claim 1, characterized in that, The step of calling the knowledge base to perform real-time conflict detection on each step in the candidate step sequence includes: Obtain each operation step item in the candidate operation step sequence; The operation steps are input into the reasoning rule layer of the secondary security rule knowledge base, and semantic matching is performed through device identifier consistency, operation type mapping and context condition compatibility to construct a candidate rule set; By activating the security constraint rules that satisfy the context conditions based on the candidate rule set, a valid rule set is obtained. The operation step items are constrained and consistent according to the set of valid rules. If the constraints are not met, they are determined to be conflicting operation step items.
9. The method according to claim 1, characterized in that, The step of correcting conflicting steps to generate a conflict-free corrected step sequence includes: Based on the relationships between conflicting steps, the minimum subset of conflict source operation steps that can explain all conflicts can be solved by set coverage optimization. Calculate the conflict contribution of each step in the subset of minimum conflict source operation steps, and generate a conflict correction priority sequence; Based on the conflict correction priority sequence, the conflict source step is corrected, and the correction includes at least one of the following: equivalent substitution of the operation object, local rearrangement of the execution order, and insertion of a pre-constraint step. Iterate and correct until there are no conflict-free steps or the subset of conflict sources is empty, then output a sequence of safe and executable operations.
10. The method according to claim 9, characterized in that, The process of structurally encapsulating and format-checking the corrected step sequence to output an executable operation ticket includes: Obtain an executable safety operation sequence, encapsulate it into standardized operation step data units according to the preset operation ticket field format, map it to the operation ticket template, and perform sequential solidification processing; Perform integrity checks on the solidified operation ticket structure data, including field integrity and sequence consistency checks; After successful verification, it is converted into an executable operation ticket and output to the scheduling execution terminal.