Method and system for intelligent identification of electric power setting sheet and construction of feature library
By separating the structured and unstructured regions of fixed-value sheets using image recognition and entity extraction algorithms, and combining adaptive associated element subgraphs and a quantified confidence rule base, the problems of low efficiency and poor accuracy in traditional fixed-value sheet management are solved, and intelligent fixed-value sheet recognition and feature library construction are realized.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- STATE GRID JIANGSU ELECTRIC POWER CO LTD SUZHOU BRANCH
- Filing Date
- 2026-05-19
- Publication Date
- 2026-08-04
AI Technical Summary
Traditional fixed-value sheet management relies on manual processing, which consumes a lot of manpower and is prone to errors. Existing OCR tools lack adaptability and structured data recognition capabilities, resulting in low recognition efficiency and accuracy.
Image recognition algorithms are used to separate the structured and unstructured regions of a fixed-value unit. An entity extraction model is used to identify set and discrete entities. An adaptive associated element subgraph is constructed and a rule base management mechanism with quantified confidence is introduced. The rule base is updated and optimized through Bayesian methods.
It achieves accurate structured text recognition and supplements unstructured text context information in value sheets, improving the accuracy and completeness of recognition and extraction. The rule base can self-optimize to prevent human error.
Smart Images

Figure CN122223738B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of fixed value recognition technology, and more specifically, relates to a method and system for intelligent recognition and feature library construction of power fixed value sheets. Background Technology
[0002] In the operation and maintenance of power systems, setting sheets serve as crucial technical documents recording the operating parameters, protection configurations, and control logic of various electrical equipment. Their accuracy and timeliness directly impact the safe and stable operation of the power system. Traditional setting sheet management relies on manual processing, requiring staff to manually identify, input, and verify various parameters from paper documents or scanned images. This process not only consumes significant manpower and time but is also prone to data errors due to human negligence.
[0003] As the scale of power systems continues to expand, the number and complexity of setting sheets have increased significantly, and the number of parameter fields they cover has also increased, including equipment model, rated current, protection settings, and operating time limits.
[0004] While some existing technologies utilize Optical Character Recognition (OCR) for processing fixed-value sheets, these tools primarily target single-format sheets and lack the ability to adapt to different types of sheets. When the fixed-value sheet changes, the recognition rules need to be readjusted, resulting in poor flexibility. Furthermore, these tools often treat the fixed-value sheet as a single piece of text, making it difficult to distinguish between structured data (such as parameter values in tables) and unstructured text (such as notes). This leads to mixed extracted parameter information, requiring significant manual intervention for subsequent processing, and the recognition efficiency and accuracy still need improvement. Summary of the Invention
[0005] To address the shortcomings of existing technologies, this invention provides a method and system for intelligent identification and feature library construction of power setting sheets.
[0006] The present invention adopts the following technical solution.
[0007] like Figure 1 As shown, the first aspect of this invention proposes a method for intelligent identification and feature library construction of power setting sheets, specifically as follows: After preprocessing the fixed value sheet image, the table portion is extracted from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. After extracting text from the structural area using the first entity extraction model, entity recognition was performed, identifying multiple set entities, each set entity consisting of a name, a value, and a unit. After extracting text from the unstructured region using a second entity extraction model, entity recognition is performed to identify multiple discrete entities, including name entities, numerical entities, unit entities, condition entities, time entities, procedure entities, and action entities. All discrete entities are then used as nodes to construct a graph structure. The name entities in the discrete entities are semantically aligned with the names in the set entities. The name entities in the semantically aligned discrete entities are used as the root nodes to construct an adaptive associated element subgraph. The associated element subgraph is then transformed into structured fields as supplementary information. A rule base is constructed, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names. Each set entity and the corresponding supplementary information are judged to determine whether the numerical entities and unit entities in the supplementary information satisfy all the corresponding constraints. When the supplementary information does not contain numerical entities and unit entities, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, the corresponding set entity and the supplementary information are not added to the feature library.
[0008] Preferably, the first entity extraction model first uses an optical character recognition algorithm to convert the structural text into a set of text blocks with position coordinates; then, it uses a table structure recognition algorithm to determine the row and column numbers of the text blocks identified by the optical character recognition algorithm based on their corresponding position coordinates; it then uses a sequence labeling algorithm to label each row or column of text blocks to identify the type of the text blocks, the type of which includes name, value, and unit; and finally, it combines the name, value, and unit of each row or column into a set entity. The second entity extraction model first uses a named entity recognition model to extract discrete entities, and then uses a relation extraction model to extract the relationships between the discrete entities, using discrete entities as nodes and relations as edges to construct a graph structure.
[0009] Preferably, the semantic alignment of the name entities in discrete entities with the names in set entities specifically involves: Both the name entities in discrete entities and the names in set entities are input into a pre-trained word vector model for the power domain. The name entities in discrete entities and the names in set entities are converted into vectors. The cosine similarity between the two vectors is calculated. If the cosine similarity exceeds the set similarity threshold, then the name entity in the discrete entity and the corresponding name in the set entity are considered to be in a corresponding relationship.
[0010] Preferably, the construction of the adaptive associated element subgraph specifically involves: The named entity in the discrete entities with semantic alignment is taken as the root node. All chain paths from the root node to each tail node are obtained. For each chain path, it is extended along the edge starting from the root node. For each node extended, the semantic relevance of the path is calculated based on the type of all nodes passed. If the semantic relevance of the path is greater than the set relevance weight and the latest node extended is not the tail node, the extension continues until the semantic relevance of the path is less than or equal to the set relevance weight or the latest node extended is the tail node. The extension stops then. All edges and nodes traversed in the current extension form a sub-path. All sub-paths form the associated element font.
[0011] Preferably, the step of calculating the path semantic relevance based on the types of all traversed nodes specifically involves: The node type is the same as the corresponding discrete entity type, including name entity, numerical entity, unit entity, condition entity, time entity, procedure entity, and action entity; During the initial expansion, the path semantic relevance between the root node and its connected nodes is calculated by multiplying the decay factor corresponding to the current expansion by the weight corresponding to the type of the connected nodes. Continue to expand, multiply the decay factor corresponding to the current expansion by the weight corresponding to the type of the latest node to which it has been expanded, and then multiply by the path semantic relevance obtained from the previous expansion to obtain the current path semantic relevance. If the path semantic relevance is greater than the set relevance weight and the latest node to which it has been expanded is not the tail node, then repeat the above steps from the start of the expansion. If the number of nodes traversed by the current extension is less than or equal to the set first threshold, then the decay factor corresponding to the current extension is 1; otherwise, the decay factor corresponding to the current extension is a set constant less than 1. The number of nodes traversed does not include the root node.
[0012] Preferably, if the node type is a name entity, a numeric entity, or a unit entity, then the corresponding weight is 1; If it is a condition entity or an action entity, the corresponding weight is the set first weight coefficient; If it is a time entity or a procedure entity, the corresponding weight is the set second weight coefficient; The first weight coefficient is set to be greater than the second weight coefficient, and both the first weight coefficient and the second weight coefficient are less than 1.
[0013] Preferably, if a set of entities does not satisfy all the corresponding constraints in the rule base, then candidate rules are generated based on the set of entities corresponding to the constraint-violation set, and the initial confidence levels of the candidate rules and the violated constraints are set. If there are more than a set of fixed-value units that violate the constraint and generate the same candidate rule, continuous verification is performed. If, after a set of fixed-value units that violate the constraint for more than a set of fixed-value units, the confidence level of the candidate rule is less than or equal to the set confidence level threshold after Bayesian update, the rule base remains unchanged. Otherwise, the violated constraint is deleted, and it is determined whether the confidence level of the violated constraint is less than or equal to the set confidence level threshold after Bayesian update. If so, the candidate rule is added to the rule base. Otherwise, the union of the violated constraint and the candidate rule is used as a correction constraint, and the correction constraint is added to the rule base. If there are more than a set first threshold number of supplementary information in the fixed value list that do not meet the same constraints in the rule base, and all the corresponding supplementary information contains conditional entities and the conditional entities are the same, then candidate rules under the set premise conditions are generated based on all the corresponding supplementary information, and the corresponding initial confidence level is set. Continuous verification is performed. If, after setting a second data threshold for a number of consecutive fixed values, the confidence level of the candidate rule under the set preconditions exceeds the set confidence threshold after Bayesian update, then the candidate rule under the set preconditions will be added to the rule base; otherwise, the rule base will remain unchanged.
[0014] Preferably, the step of generating candidate rules based on the set entities corresponding to the constraint-violation set specifically includes: If the violated constraint is a range constraint, the value in the set entity that violates the constraint is divided by the set range value, rounded up, and then multiplied by the set range value to obtain the upper limit of the candidate rule. The upper limit is then subtracted from the set range value to obtain the lower limit of the candidate rule. If the violated constraint is a unit constraint, then the units in the set of entities that currently violate the constraint are taken as candidate rules. If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule.
[0015] Preferably, the step of generating candidate rules under set preconditions based on all corresponding supplementary information is as follows: The corresponding supplementary information is used as a conditional entity; under the conditional entity, the original violated constraint does not apply. If the violated constraint is a range constraint, then the maximum value of the numerical entity of all supplementary information that violates the constraint and has the same condition entity is at the upper limit of the candidate rule under the set premise condition, and the minimum value of all supplementary information that violates the constraint and has the same condition entity is at the lower limit of the candidate rule under the set premise condition. If the violated constraint is a unit constraint, then the unit entity that appears most frequently in the supplementary information of all entities that violate the constraint and have the same condition entity is selected as the candidate rule under the set preconditions. If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule under the given premise.
[0016] Preferably, the Bayesian update specifically includes: For each verified setpoint, the confidence level of the rule is updated. The rule includes candidate rules, candidate rules under the set preconditions, and the violated constraints. The confidence level before the update is multiplied by the likelihood function of the correct rule as the numerator. The difference between the confidence level before the update multiplied by the likelihood function of the correct rule plus 1 and the confidence level before the update is multiplied by the likelihood function of the incorrect rule as the denominator. The numerator is divided by the denominator to obtain the updated confidence level. If the current order meets the corresponding rule, the likelihood function for a correct rule is the set reliability parameter; otherwise, the likelihood function for a correct rule is 1 minus the set reliability parameter. The likelihood function for a correct rule is the sum of the likelihood function for an incorrect rule and 1.
[0017] The second aspect of this invention proposes an intelligent identification and feature library construction system for power setting sheets using the method described in the first aspect of this invention, comprising a region division module, a structured region extraction module, an unstructured region extraction module, and a feature library construction module, specifically as follows: Region segmentation module: After preprocessing the fixed value sheet image, it extracts the table portion from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. Structural Region Extraction Module: This module is used to extract text from the structural region using the first entity extraction model and then perform entity recognition to identify multiple sets of entities. Each set of entities consists of a name, a value, and a unit. The unstructured region extraction module extracts text from unstructured regions using a second entity extraction model, then performs entity recognition to identify multiple discrete entities, including name entities, numerical entities, unit entities, condition entities, time entities, procedure entities, and action entities. It constructs a graph structure using all discrete entities as nodes, semantically aligns the name entities within discrete entities with the names in the set entities, and uses the name entities in the semantically aligned discrete entities as root nodes to build an adaptive associated element subgraph. Finally, it transforms the associated element subgraph into structured fields as supplementary information. Feature library construction module: used to construct a rule library, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names; it determines whether the numerical entities and unit entities in each set entity and the corresponding supplementary information satisfy all the corresponding constraints. When there are no numerical entities and unit entities in the supplementary information, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, neither the corresponding set entity nor the supplementary information is added to the feature library.
[0018] A third aspect of the invention provides an apparatus comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, the processor performing steps of the method described in the first aspect of the invention.
[0019] A fourth aspect of the present invention provides a computer-readable storage medium storing a computer program that, when executed by a processor, uses the steps of the method described in the first aspect of the present invention.
[0020] The beneficial effects of this invention are as follows: Compared with the prior art, through the collaborative parsing of structured and unstructured regions, it can accurately identify various fixed values in structured text, and through adaptive association element subgraphs, it can supplement the contextual information of unstructured text into structured text; it solves the problem that traditional OCR tools are difficult to understand complex power system fixed value sheets; and it introduces a dynamic management mechanism for the rule base based on quantitative confidence, which automatically generates and verifies new general rules or conditional rules from the rule base through Bayesian updates; enabling the rule base to continuously optimize and improve itself along with business practices, preventing the recording of a large amount of redundant or erroneous content in unstructured text due to the instability of human annotations; and improving the accuracy and completeness of fixed value sheet recognition and extraction. Attached Figure Description
[0021] Figure 1 This is a flowchart of the present invention. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of this invention. The embodiments described in this application are merely some embodiments of this invention, and not all embodiments. Based on the spirit of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of this invention.
[0023] Embodiment 1 of the present invention proposes a method for intelligent identification and feature library construction of power setting sheets, including: After preprocessing the fixed value sheet image, the table portion is extracted from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. After extracting text from the structural area using the first entity extraction model, entity recognition was performed, identifying multiple set entities, each set entity consisting of a name, a value, and a unit. It should be noted that the power setting sheet is in tabular form. For example, the first column of the table is the name, the second column is the value, and the third column is the unit. For example, the three columns in the first row are the operating current, 800, and A, respectively.
[0024] After extracting text from the unstructured region using a second entity extraction model, entity recognition is performed to identify multiple discrete entities, including but not limited to name entities, numerical entities, unit entities, condition entities, time entities, procedure entities, and action entities. All discrete entities are then used as nodes to construct a graph structure. The name entities in the discrete entities are semantically aligned with the names in the set entities. The name entities in the semantically aligned discrete entities are used as the root nodes to construct an adaptive associated element subgraph. The associated element subgraph is then transformed into structured fields as supplementary information. It should be noted that other areas, i.e., non-structural areas, contain human-made notes and explanations, as well as information on calculation basis and special adjustments. For example, the standard operating current in summer is 800A, and it should be adjusted to 750A in winter. This is set by the dispatching department according to Article 5.2.3 of the Relay Protection Setting Regulations. In this case, the operating current is the name entity; 800 and 750 are numerical entities; A is the unit entity; summer and winter are condition entities; and Article 5.2.3 of the Relay Protection Setting Regulations is the regulation entity. Another example is that before each adjustment of the operating current of device x, the relevant protection switch must be removed, with the effective date being 2023. In this case, device x is the condition entity, the operating current is the name entity, 2023 is the time entity, and removing the relevant protection switch is the operating entity.
[0025] The supplementary information mentioned is that the associated feature subgraph is converted into a structured field. Specifically, all discrete entities of each path in the associated feature subgraph are grouped into a structure for storage. The path is a path that starts with the root node and ends with no other connected nodes.
[0026] A rule base is constructed, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names. Each set entity and the corresponding supplementary information are judged to determine whether the numerical entities and unit entities in the supplementary information satisfy all the corresponding constraints. When the supplementary information does not contain numerical entities and unit entities, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, the corresponding set entity and the supplementary information are not added to the feature library.
[0027] In this preferred embodiment, the image recognition algorithm adopts the YOLO series algorithm. The first entity extraction model first uses an optical character recognition algorithm to convert the structural text into a set of text blocks with position coordinates; then, a table structure recognition algorithm is used to determine the row and column number of the text blocks identified by the optical character recognition algorithm according to their corresponding position coordinates; a sequence labeling algorithm is used to label each row or column of text blocks to identify the type of text blocks, which includes name, value and unit; and the name, value and unit of each row or column are combined into a set entity.
[0028] The second entity extraction model first uses a named entity recognition model to extract discrete entities, and then uses a relation extraction model to extract the relationships between these discrete entities. Discrete entities are treated as nodes, and relationships as edges, constructing a graph structure. It should be noted that the edges in the graph structure are directed edges.
[0029] Specifically, in this embodiment, the table structure recognition algorithm adopts the TableNet algorithm; the sequence labeling algorithm adopts the BERT-CRF algorithm; the named entity recognition model is a BERT-based NER model; and the relation extraction model specifically adopts a Span-based joint extraction framework or uses a rule engine based on dependency parsing.
[0030] In this preferred embodiment, the semantic alignment of the name entities in discrete entities with the names in set entities specifically involves: Both the name entities in discrete entities and the names in set entities are input into a pre-trained word vector model for the power domain. The name entities in discrete entities and the names in set entities are converted into vectors. The cosine similarity between the two vectors is calculated. If the cosine similarity exceeds the set similarity threshold, then the name entity in the discrete entity and the corresponding name in the set entity are considered to be in a corresponding relationship.
[0031] Specifically, the word vector model in the power field is the Word2Vec algorithm. When training this algorithm, the training samples include the standard name, synonyms and abbreviations of all names. The labels corresponding to the standard name, synonyms and abbreviations of a name are all the same vector.
[0032] In this preferred embodiment, the construction of the adaptive associated element subgraph specifically includes: The named entity in the discrete entities with semantic alignment is taken as the root node. All chain paths from the root node to each tail node are obtained. For each chain path, it is extended along the edge starting from the root node. For each node extended, the semantic relevance of the path is calculated based on the type of all nodes passed. If the semantic relevance of the path is greater than the set relevance weight and the latest node extended is not the tail node, the extension continues until the semantic relevance of the path is less than or equal to the set relevance weight or the latest node extended is the tail node. The extension stops then. All edges and nodes traversed in the current extension form a sub-path. All sub-paths form the associated element font.
[0033] The tail node is a node that no longer points to the next node.
[0034] In this preferred embodiment, the step of calculating the path semantic relevance based on the types of all traversed nodes specifically involves: The node type is the same as the corresponding discrete entity type, including name entity, numerical entity, unit entity, condition entity, time entity, procedure entity, and action entity; During the initial expansion, the path semantic relevance between the root node and its connected nodes is calculated by multiplying the decay factor corresponding to the current expansion by the weight corresponding to the type of the connected nodes. Continue to expand, multiply the decay factor corresponding to the current expansion by the weight corresponding to the type of the latest node to which it has been expanded, and then multiply by the path semantic relevance obtained from the previous expansion to obtain the current path semantic relevance. If the path semantic relevance is greater than the set relevance weight and the latest node to which it has been expanded is not the tail node, then repeat the above steps from the start of the expansion. If the number of nodes traversed by the current extension is less than or equal to the set first threshold, then the decay factor corresponding to the current extension is 1; otherwise, the decay factor corresponding to the current extension is a set constant less than 1. The number of nodes traversed does not include the root node.
[0035] In this preferred embodiment, if the node type is a name entity, a numeric entity, or a unit entity, then the corresponding weight is 1; If it is a condition entity or an action entity, the corresponding weight is the set first weight coefficient; If it is a time entity or a procedure entity, the corresponding weight is the set second weight coefficient; The first weight coefficient is set to be greater than the second weight coefficient, and both the first weight coefficient and the second weight coefficient are less than 1.
[0036] Specifically, the first weighting coefficient is set to 0.98, and the second weighting coefficient is set to 0.85.
[0037] In this preferred embodiment, if a set entity does not satisfy all the corresponding constraints in the rule base, then a candidate rule is generated based on the set entity corresponding to the constraint violation, and the initial confidence level of the candidate rule and the violated constraint is set. If there are more than a set of fixed-value units that violate the constraint and generate the same candidate rule, continuous verification is performed. If, after a set of fixed-value units that violate the constraint for more than a set of fixed-value units, the confidence level of the candidate rule is less than or equal to the set confidence level threshold after Bayesian update, the rule base remains unchanged. Otherwise, the violated constraint is deleted, and it is determined whether the confidence level of the violated constraint is less than or equal to the set confidence level threshold after Bayesian update. If so, the candidate rule is added to the rule base. Otherwise, the union of the violated constraint and the candidate rule is used as a correction constraint, and the correction constraint is added to the rule base. It should be noted that the union means that satisfying any one of the sub-constraints satisfies the correction constraint. If the confidence of the violated constraint is less than or equal to the set confidence threshold after Bayesian update, it means that the violated constraint is wrong and needs to be deleted and the candidate rule added to the rule base. Otherwise, it means that the scope of the violated constraint is too small. Therefore, the union of the violated constraint and the candidate rule is used as the correction constraint and added to the rule base.
[0038] If there are more than a set first threshold number of supplementary information in the fixed value list that do not meet the same constraints in the rule base, and all the corresponding supplementary information contains conditional entities and the conditional entities are the same, then candidate rules under the set premise conditions are generated based on all the corresponding supplementary information, and the corresponding initial confidence level is set. Continuous verification is performed. If, after setting a second data threshold for a number of consecutive fixed values, the confidence level of the candidate rule under the set preconditions exceeds the set confidence threshold after Bayesian update, then the candidate rule under the set preconditions will be added to the rule base; otherwise, the rule base will remain unchanged.
[0039] It should be noted that the conditional entities being identical means that they are semantically identical. Specifically, the conditional entities are input into a pre-trained word vector model for the power industry, and all conditional entities are converted into vectors. The cosine similarity of the vectors of every two conditional entities is calculated. If the similarity exceeds a set threshold, it means that the corresponding two conditional entities are identical.
[0040] In this preferred embodiment, the step of generating candidate rules based on the set entities corresponding to the constraint-violation set specifically involves: If the violated constraint is a range constraint, the value in the set entity that violates the constraint is divided by the set range value, rounded up, and then multiplied by the set range value to obtain the upper limit of the candidate rule. The upper limit is then subtracted from the set range value to obtain the lower limit of the candidate rule. For example, if a given set of fixed-value pairs contains a set of entities with the value 53, but the original value range constraint is [0,50], and the first set range is set to 5, then the candidate rule is [50,55]. If, after setting a second data threshold for several consecutive fixed-value pairs, the confidence level of the candidate rule is less than or equal to the set confidence threshold after Bayesian update, then the rule base remains unchanged; otherwise, if the confidence level of the violated constraint is less than or equal to the set confidence threshold after Bayesian update, then the original value range constraint is deleted, and the added value range constraint is [50,55]; otherwise, the constraint is corrected to [0,50]∪[50,55], that is, the corrected constraint is [0,55], where ∪ is the union symbol.
[0041] If the violated constraint is a unit constraint, then the units in the set of entities that currently violate the constraint are taken as candidate rules. For example, for action voltage, the unit constraint for action voltage in the original rule base is: the unit must be kV. However, the unit of the corresponding set entity (named action voltage) in the current set value is V. Therefore, the candidate rule is: the unit must be V.
[0042] If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule.
[0043] It should be noted that for relational constraints, the modified constraint is the union of the relational constraint and the complementary constraint, which equals the entire set. This means that no constraint is applied to the relationship between the corresponding parameters. For example, for the action current and return current, the original rule base's relational constraint is that the action current is greater than the return current. However, if the setpoint does not satisfy this relational constraint, the candidate rule becomes: the action current is less than or equal to the return current. If the confidence level of the violated constraint, after Bayesian update, is less than or equal to the set confidence threshold; if, after consecutive setpoints with the second data threshold set, the confidence level of the candidate rule, after Bayesian update, is greater than the set confidence threshold, and the confidence level of the violated constraint, after Bayesian update, is still greater than the set confidence threshold, then no constraint is applied to the relationship between the action current and the return current.
[0044] In this preferred embodiment, the step of generating candidate rules under set preconditions based on all corresponding supplementary information is as follows: The corresponding supplementary information is used as a conditional entity; under the conditional entity, the original violated constraint does not apply. If the violated constraint is a range constraint, then the maximum value of the numerical entity of all supplementary information that violates the constraint and has the same condition entity is at the upper limit of the candidate rule under the set premise condition, and the minimum value of all supplementary information that violates the constraint and has the same condition entity is at the lower limit of the candidate rule under the set premise condition. If the violated constraint is a unit constraint, then the unit entity that appears most frequently in the supplementary information of all entities that violate the constraint and have the same condition entity is selected as the candidate rule under the set preconditions. If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule under the given premise.
[0045] In this preferred embodiment, the Bayesian update specifically refers to: For each verified setpoint, the confidence level of the rule is updated. The rule includes candidate rules, candidate rules under the set preconditions, and the violated constraints. The confidence level before the update is multiplied by the likelihood function of the correct rule as the numerator. The difference between the confidence level before the update multiplied by the likelihood function of the correct rule plus 1 and the confidence level before the update is multiplied by the likelihood function of the incorrect rule as the denominator. The numerator is divided by the denominator to obtain the updated confidence level. If the current order meets the corresponding rule, the likelihood function for a correct rule is the set reliability parameter; otherwise, the likelihood function for a correct rule is 1 minus the set reliability parameter. The likelihood function for a correct rule is the sum of the likelihood function for an incorrect rule and 1.
[0046] Specifically, the formula is:
[0047] in, To obtain the updated confidence level; The confidence level before the update; The likelihood function is the one that follows the correct rules; This indicates the corresponding rule; It is the likelihood function for rule errors.
[0048] Specifically, in this embodiment, the reliability parameter is set to 1; the initial confidence level is set to 0.95 for all constraints at the beginning of the rule base, and the initial confidence level is set to 0.5 for candidate rules and candidate rules under the set preconditions.
[0049] Embodiment 2 of the present invention proposes an intelligent identification and feature library construction system for power setting sheets using the method described in Embodiment 1 of the present invention, including a region division module, a structured region extraction module, an unstructured region extraction module, and a feature library construction module, specifically as follows: Region segmentation module: After preprocessing the fixed value sheet image, it extracts the table portion from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. Structural Region Extraction Module: This module is used to extract text from the structural region using the first entity extraction model and then perform entity recognition to identify multiple sets of entities. Each set of entities consists of a name, a value, and a unit. The unstructured region extraction module extracts text from unstructured regions using a second entity extraction model, then performs entity recognition to identify multiple discrete entities, including name entities, numerical entities, unit entities, condition entities, time entities, procedure entities, and action entities. It constructs a graph structure using all discrete entities as nodes, semantically aligns the name entities within discrete entities with the names in the set entities, and uses the name entities in the semantically aligned discrete entities as root nodes to build an adaptive associated element subgraph. Finally, it transforms the associated element subgraph into structured fields as supplementary information. Feature library construction module: used to construct a rule library, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names; it determines whether the numerical entities and unit entities in each set entity and the corresponding supplementary information satisfy all the corresponding constraints. When there are no numerical entities and unit entities in the supplementary information, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, neither the corresponding set entity nor the supplementary information is added to the feature library.
[0050] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the protection scope of the claims of the present invention.
Claims
1. A method for intelligent identification and feature library construction of power setting sheets, characterized in that: After preprocessing the fixed value sheet image, the table portion is extracted from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. After extracting text from the structural area using the first entity extraction model, entity recognition was performed, identifying multiple set entities, each set entity consisting of a name, a value, and a unit. After extracting text from unstructured regions using a second entity extraction model, entity recognition is performed to identify multiple discrete entities, including name entities, numerical entities, unit entities, conditional entities, time entities, procedure entities, and action entities. All discrete entities are then used as nodes to construct a graph structure. Name entities within discrete entities are semantically aligned with names within set entities. Name entities within semantically aligned discrete entities are used as root nodes to construct an adaptive subgraph of associated elements. Specifically: The named entity in the discrete entities with semantic alignment is taken as the root node. All chain paths from the root node to each tail node are obtained. For each chain path, it is extended along the edge starting from the root node. For each node extended, the semantic relevance of the path is calculated based on the type of all nodes passed. If the semantic relevance of the path is greater than the set relevance weight and the latest node extended is not the tail node, the extension continues until the semantic relevance of the path is less than or equal to the set relevance weight or the latest node extended is the tail node. The extension stops then. All edges and nodes traversed in the current extension form a sub-path. All sub-paths form an associated feature subgraph. The associated feature subplots are converted into structured fields as supplementary information; A rule base is constructed, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names. Each set entity and the corresponding supplementary information are judged to determine whether the numerical entities and unit entities in the supplementary information satisfy all the corresponding constraints. When the supplementary information does not contain numerical entities and unit entities, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, the corresponding set entity and the supplementary information are not added to the feature library.
2. The method for intelligent identification and feature library construction of power setting sheets according to claim 1, characterized in that: The first entity extraction model first uses an optical character recognition algorithm to convert the structural text into a set of text blocks with position coordinates; then, it uses a table structure recognition algorithm to determine the row and column numbers of the text blocks identified by the optical character recognition algorithm based on their corresponding position coordinates; then, it uses a sequence labeling algorithm to label each row or column of text blocks and identify the type of the text blocks, which includes name, value, and unit; finally, it combines the name, value, and unit of each row or column into a set entity. The second entity extraction model first uses a named entity recognition model to extract discrete entities, and then uses a relation extraction model to extract the relationships between the discrete entities, using discrete entities as nodes and relations as edges to construct a graph structure.
3. The method for intelligent identification and feature library construction of power setting sheets according to claim 1, characterized in that: The semantic alignment of the names in discrete entities with the names in set entities specifically involves: Both the name entities in discrete entities and the names in set entities are input into a pre-trained word vector model for the power domain. The name entities in discrete entities and the names in set entities are converted into vectors. The cosine similarity between the two vectors is calculated. If the cosine similarity exceeds the set similarity threshold, then the name entity in the discrete entity and the corresponding name in the set entity are considered to be in a corresponding relationship.
4. The method for intelligent identification and feature library construction of power setting sheets according to claim 1, characterized in that: The calculation of path semantic relevance based on the types of all traversed nodes specifically involves: The node type is the same as the corresponding discrete entity type, including name entity, numerical entity, unit entity, condition entity, time entity, procedure entity, and action entity; During the initial expansion, the path semantic relevance between the root node and its connected nodes is calculated by multiplying the decay factor corresponding to the current expansion by the weight corresponding to the type of the connected nodes. Continue to expand, multiply the decay factor corresponding to the current expansion by the weight corresponding to the type of the latest node to which it has been expanded, and then multiply by the path semantic relevance obtained from the previous expansion to obtain the current path semantic relevance. If the path semantic relevance is greater than the set relevance weight and the latest node to which it has been expanded is not the tail node, then repeat the above steps from the start of the expansion. If the number of nodes traversed by the current extension is less than or equal to the set first threshold, then the decay factor corresponding to the current extension is 1; otherwise, the decay factor corresponding to the current extension is a set constant less than 1. The number of nodes traversed does not include the root node.
5. The method for intelligent identification and feature library construction of power setting sheets according to claim 4, characterized in that: If the node type is a name entity, a numeric entity, or a unit entity, then the corresponding weight is 1; If it is a condition entity or an action entity, the corresponding weight is the set first weight coefficient; If it is a time entity or a procedure entity, the corresponding weight is the set second weight coefficient; The first weight coefficient is set to be greater than the second weight coefficient, and both the first weight coefficient and the second weight coefficient are less than 1.
6. The method for intelligent identification and feature library construction of power setting sheets according to claim 1, characterized in that: If a set of entities does not satisfy all the corresponding constraints in the rule base, then candidate rules are generated based on the set of entities corresponding to the constraint violation, and the initial confidence levels of the candidate rules and the violated constraints are set. If there are more than a set of fixed-value units that violate the constraints and generate the same candidate rule, continuous verification is performed. If, after a set of fixed-value units that violate the constraints, the confidence of the candidate rule is less than or equal to the set confidence threshold after Bayesian update, the rule base remains unchanged. Otherwise, delete the violated constraint, and determine whether the confidence of the violated constraint after Bayesian update is less than or equal to the set confidence threshold. If so, add the candidate rule to the rule base; otherwise, use the union of the violated constraint and the candidate rule as the correction constraint and add the correction constraint to the rule base. If there are more than a set first threshold number of supplementary information in the fixed value list that do not meet the same constraints in the rule base, and all the corresponding supplementary information contains conditional entities and the conditional entities are the same, then candidate rules under the set premise conditions are generated based on all the corresponding supplementary information, and the corresponding initial confidence level is set. Continuous verification is performed. If, after setting a second data threshold for a number of consecutive fixed values, the confidence level of the candidate rule under the set preconditions exceeds the set confidence threshold after Bayesian update, then the candidate rule under the set preconditions will be added to the rule base; otherwise, the rule base will remain unchanged.
7. The method for intelligent identification and feature library construction of power setting sheets according to claim 6, characterized in that: The process of generating candidate rules based on the set entities corresponding to the constraint-violation set is as follows: If the violated constraint is a range constraint, the value in the set entity that violates the constraint is divided by the set range value, rounded up, and then multiplied by the set range value to obtain the upper limit of the candidate rule. The upper limit is then subtracted from the set range value to obtain the lower limit of the candidate rule. If the violated constraint is a unit constraint, then the units in the set of entities that currently violate the constraint are taken as candidate rules. If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule.
8. The method for intelligent identification and feature library construction of power setting sheets according to claim 6, characterized in that: The process involves generating candidate rules based on all corresponding supplementary information under set preconditions: The corresponding supplementary information is used as a conditional entity; under the conditional entity, the original violated constraint does not apply. If the violated constraint is a range constraint, then the maximum value of the numerical entity of all supplementary information that violates the constraint and has the same condition entity is at the upper limit of the candidate rule under the set premise condition, and the minimum value of all supplementary information that violates the constraint and has the same condition entity is at the lower limit of the candidate rule under the set premise condition. If the violated constraint is a unit constraint, then the unit entity that appears most frequently in the supplementary information of all entities that violate the constraint and have the same condition entity is selected as the candidate rule under the set preconditions. If the violated constraint is a relational constraint, then the violated constraint is logically negated, and a complementary constraint is generated as a candidate rule under the given premise.
9. The method for intelligent identification and feature library construction of power setting sheets according to claim 6, characterized in that: The Bayesian update is specifically as follows: For each verified setpoint, the confidence level of the rule is updated. The rule includes candidate rules, candidate rules under the set preconditions, and the violated constraints. The confidence level before the update is multiplied by the likelihood function of the correct rule as the numerator. The difference between the confidence level before the update multiplied by the likelihood function of the correct rule plus 1 and the confidence level before the update is multiplied by the likelihood function of the incorrect rule as the denominator. The numerator is divided by the denominator to obtain the updated confidence level. If the current order meets the corresponding rule, the likelihood function for a correct rule is the set reliability parameter; otherwise, the likelihood function for a correct rule is 1 minus the set reliability parameter. The likelihood function for a correct rule is the sum of the likelihood function for an incorrect rule and 1.
10. A power setting sheet intelligent identification and feature library construction system using the method of any one of claims 1-9, comprising a region division module, a structured region extraction module, an unstructured region extraction module, and a feature library construction module, characterized in that: Region segmentation module: After preprocessing the fixed value sheet image, it extracts the table portion from the preprocessed fixed value sheet image using an image recognition algorithm. The table portion is used as the structured region, and the other portions are used as the unstructured region. Structural Region Extraction Module: This module is used to extract text from the structural region using the first entity extraction model and then perform entity recognition to identify multiple sets of entities. Each set of entities consists of a name, a value, and a unit. The unstructured region extraction module extracts text from unstructured regions using a second entity extraction model, then performs entity recognition to identify multiple discrete entities, including name entities, numerical entities, unit entities, condition entities, time entities, procedure entities, and action entities. It constructs a graph structure using all discrete entities as nodes, semantically aligns the name entities within discrete entities with the names in the set entities, and uses the name entities in the semantically aligned discrete entities as root nodes to build an adaptive associated element subgraph. Finally, it transforms the associated element subgraph into structured fields as supplementary information. Feature library construction module: used to construct a rule library, which includes value range constraints, unit constraints, and relationship constraints between parameters and other parameters with different names; it determines whether the numerical entities and unit entities in each set entity and the corresponding supplementary information satisfy all the corresponding constraints. When there are no numerical entities and unit entities in the supplementary information, it is considered that the supplementary information satisfies all constraints. If all constraints are satisfied, the supplementary information is added to the corresponding set entity and added to the feature library. If only the set entity satisfies the constraints, the set entity is directly added to the feature library. Otherwise, neither the corresponding set entity nor the supplementary information is added to the feature library.
11. An apparatus comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, the processor performing steps of the method according to any one of claims 1-9.
12. A computer-readable storage medium storing a computer program that, when executed by a processor, uses the steps of the method according to any one of claims 1-9.