Knowledge graph construction method and system for continuous casting quality engineering field
By constructing a continuous casting quality knowledge graph and using deep learning models to extract entities and relationships, the problem of low efficiency in traceability analysis of continuous casting billets was solved, rapid location of defect causes and process optimization were achieved, and billet quality was improved.
Patent Information
- Application Number
- CN202410916190.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-09
- Publication Date
- 2024-10-15
- Estimated Expiration
- 2044-07-09
AI Technical Summary
The quality traceability analysis of continuous cast steel billets is inefficient and lacks knowledge accumulation and sharing, resulting in complex production processes and difficulty in finding the causes of quality defects. Reliance on manual experience leads to low knowledge utilization.
The knowledge graph construction method is used to obtain relevant data describing defects in steel billets during the continuous casting process, build an ontology model, define entity categories and relationship categories, and use deep learning models for entity-relationship extraction and semantic annotation to construct the continuous casting quality engineering field. knowledge graph to reduce reliance on manual experience.
It improves the accuracy and efficiency of continuous casting quality traceability, quickly locates the cause of defects, optimizes the production process, reduces the difficulty of analysis, reduces the influence of false samples, and improves the quality of the slab.
Smart Images

Figure CN118780356A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of knowledge graph construction, and relates to a knowledge graph construction method and system for the field of continuous casting quality engineering. Background Art
[0002] In the production process of continuous steel casting, factors such as the quality of process raw materials, the values of process operating parameters, the operating status of equipment, the experience and status of operators and inspectors will affect the quality of continuous casting billets. The root cause analysis of continuous casting billet defects is to determine the cause of the quality defect by analyzing the data information and event information in the continuous casting billet production process when the continuous casting billet has quality defects. With the help of quality traceability, product quality can be continuously improved and the production process can be optimized.
[0003] In the current actual production environment, there are problems such as complex production processes and difficulty in finding the causes of quality defects. The causes of quality defects in continuous casting billets are mainly divided into parameter anomalies and event anomalies. In the production process of continuous casting billets, there are many types of data and a large amount of data, which is prone to data redundancy, which is not conducive to data analysis; and quality defects may be caused by abnormal events, which are difficult to find, making manual quality traceability analysis inefficient. At the same time, steel companies have low utilization rates of knowledge on quality traceability, and lack knowledge accumulation and knowledge sharing.
[0004] At present, the empirical knowledge of continuous casting billet quality traceability is in the hands of a few people. There is a lack of sufficient application of this knowledge, resulting in knowledge waste and the inability to conduct traceability analysis efficiently and accurately.
[0005] These fragmented knowledge should be mined and organized into standardized, structured and systematic knowledge to guide the quality traceability of continuous casting steel billets and improve the accuracy and comprehensiveness of traceability. Summary of the invention
[0006] The purpose of the present invention is to solve the problems in the prior art that the production process of continuous steel casting is complicated and it is difficult to find the causes of quality defects. However, due to the excessive reliance on manual experience and the lack of empirical knowledge on the traceability of the quality of continuous casting steel billets, the knowledge utilization rate of quality traceability is not high, and the traceability analysis cannot be performed efficiently and accurately, and the data in the production process of continuous steel casting cannot be analyzed in time. A knowledge graph construction method and system for the field of continuous casting quality engineering are provided.
[0007] In order to achieve the above object, the present invention adopts the following technical solutions:
[0008] A knowledge graph construction method for continuous casting quality engineering field, comprising the following steps:
[0009] Obtain relevant data describing defects in steel billets during continuous casting;
[0010] Construct an ontology model of continuous casting quality knowledge graph, and define entity categories and relationship categories of continuous casting quality based on the ontology model;
[0011] Annotate the acquired relevant data describing the defects of the steel billet based on the entity category and the relationship category to obtain the annotated data;
[0012] A deep learning model for joint extraction of continuous casting quality based on segmentation and recombination is constructed, and the labeled data is used as the input of the deep learning model for joint extraction of continuous casting quality based on segmentation and recombination to obtain entity-relationship-entity triple data of continuous casting quality;
[0013] Performing semantic annotation on the acquired entity-relationship-entity triple data to acquire semantically annotated data;
[0014] Construct a continuous casting quality knowledge alignment model, use the semantic annotation data as the input of the continuous casting quality knowledge alignment model, obtain the aligned triple data, and construct a knowledge graph in the field of continuous casting quality engineering based on the aligned triple data.
[0015] A further improvement of the present invention is:
[0016] The entity categories include: names of continuous casting quality defects, continuous casting quality events, causes of continuous casting quality defects, characteristics of continuous casting quality defects, solutions to continuous casting quality problems and characteristics of continuous casting events;
[0017] The relationship categories include: causes, causes, describes, takes, and is characterized by.
[0018] The continuous casting quality joint extraction deep learning model based on segmentation and recombination includes an input layer, a continuous casting quality sequence segmentation and recombination module, a continuous casting quality entity recognition module and a continuous casting quality relationship extraction module;
[0019] The labeled data is used as the input of the input layer, and the output of the input layer is connected to the input of the continuous casting quality sequence segmentation and reorganization module;
[0020] The continuous casting quality sequence segmentation and reorganization module includes a continuous casting quality sequence segmentation module, a self-attention mechanism module and a continuous casting quality sequence reorganization module which are connected in sequence;
[0021] The output end of the continuous casting quality sequence reorganization module is connected to the input end of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module, and the output results of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module are the continuous casting quality entity relationship extraction results.
[0022] The calculation results of the continuous casting quality sequence segmentation and recombination module are:
[0023]
[0024] Where: e , s , r Respectively represent the entity recognition sequence, sharing sequence, and relationship extraction sequence results after segmentation; Represents the entity recognition partial sequence, shared sequence, and relation extraction sequence of the current word.
[0025] The calculation process of the self-attention mechanism module includes:
[0026] ρ e , s , r As the input of the self-attention mechanism module, we calculate:
[0027] Q=W q P,K=W k P,V=W v P
[0028] Where: Q, K, V represent the Query, Key, and Value matrices in the self-attention mechanism respectively; W q , W k , W v Represent the weight matrices of Query, Key, and Value respectively; P represents the input sequence;
[0029] The calculation results of each part of the self-attention mechanism module are:
[0030] B=V(softmax(K T Q))
[0031] Where: B represents the output of each head of the multi-head self-attention mechanism; Q, K and V represent the Query matrix, Key matrix and Value matrix in the self-attention mechanism respectively;
[0032] The final calculation result of the self-attention mechanism module is:
[0033] O=W b (Linear([B e ,B s ,B r ]))
[0034] Where: O represents the final output of the self-attention mechanism module; W b The weight matrix representing the splicing continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence; B e , B s and B rThey respectively represent the results of continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence after corresponding self-attention mechanism.
[0035] The continuous casting quality entity recognition module and the continuous casting quality relationship extraction module both include a fully connected layer, an activation function layer and a feedforward neural network layer.
[0036] The output results of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module include:
[0037] Given a set of relations R, for each relation l, construct a relation table whose elements Indicates w i and w j is the probability of the head and tail entities of the continuous casting quality of the relation, extract all triples related to the relation l, and for each triple (w i ,l,w j ), by connecting and Get the feature representation of the triple:
[0038]
[0039] Where: Represents word w i and the word w j Representation of the continuous casting quality triplet as head and tail entities; and Represents word-level features; Represents global features at the sentence level;
[0040] According to the feature representation of the triplet, the correct probability of the continuous casting quality triplet is obtained through the feedforward neural network:
[0041]
[0042] Where: Represents word w i and the word w j The probability that the continuous casting quality triplet as the head and tail entities is the lth type of relationship; Represents word w i and the word w j Representation of the casting quality triplet as the head and tail entities; σ denotes the sigmoid activation function.
[0043] A knowledge graph construction system for continuous casting quality engineering, comprising:
[0044] The original data acquisition module is used to obtain relevant data describing defects in the steel billet during the continuous casting process;
[0045] An ontology model building module is used to build an ontology model of the continuous casting quality knowledge graph and define entity categories and relationship categories of continuous casting quality based on the ontology model;
[0046] A data annotation module is used to annotate the acquired relevant data describing the defects of the steel billet based on entity categories and relationship categories to obtain the annotated data;
[0047] A triple acquisition module is used to build a deep learning model for joint extraction of continuous casting quality based on segmentation and recombination, and use the labeled data as the input of the deep learning model for joint extraction of continuous casting quality based on segmentation and recombination to obtain entity-relationship-entity triple data of continuous casting quality;
[0048] A semantic annotation module, used to semantically annotate the acquired entity-relationship-entity triple data to obtain semantically annotated data;
[0049] The knowledge graph acquisition module is used to build a continuous casting quality knowledge alignment model, take the semantic annotation data as the input of the continuous casting quality knowledge alignment model, obtain the aligned triple data, and build a knowledge graph in the field of continuous casting quality engineering based on the aligned triple data.
[0050] A terminal device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of any method described in the present invention when executing the computer program.
[0051] A computer-readable storage medium stores a computer program, wherein the computer program, when executed by a processor, implements the steps of any method described in the present invention.
[0052] Compared with the prior art, the present invention has the following beneficial effects:
[0053] The present invention discloses a knowledge graph construction method for the field of continuous casting quality engineering. An ontology model is constructed according to relevant data describing defects generated in steel billets during the continuous casting process, and entity categories and relationship categories between entities of the knowledge graph are defined. The entities and relationships defined by the ontology model can describe the continuous casting event more concisely, which is conducive to highlighting and grasping the key points of the event. Then, as the basis for constructing the knowledge graph, the continuous casting quality entities and the relationships between entities are extracted from the relevant data describing defects generated in steel billets using a deep learning method, and the continuous casting quality entity categories and relationship categories are judged according to the continuous casting quality knowledge graph ontology model. Compared with the assembly line mode of first identifying the continuous casting quality entity and then extracting the continuous casting quality relationship according to the entity recognition result, the method proposed in the present invention can take into account the close relationship between the continuous casting quality entity and the relationship, and can avoid the error propagation problem of the entity recognition error affecting the relationship extraction. Finally, according to the deep learning method, the continuous casting quality knowledge alignment problem is converted into a paired continuous casting quality entity matching problem. The semi-supervised incremental learning method is used to divide the training process into two stages to reduce the demand for data in the continuous casting quality field. At the same time, in order to reduce the impact of pseudo samples on model performance, the knowledge graph constructed by the present invention can reduce the difficulty of analyzing the root causes of continuous casting quality defects, reduce the dependence on manual experience, and is conducive to quickly locating the causes of defects and optimizing the process, thereby improving the quality of the ingot, which is very meaningful and valuable. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0055] Figure 1 A graph is constructed for the continuous casting quality knowledge graph ontology model of the present invention;
[0056] Figure 2 It is the entity relationship conversion diagram of continuous casting quality of the present invention;
[0057] Figure 3 It is the design diagram of the continuous casting quality joint extraction model of the present invention;
[0058] Figure 4 This is a detailed design diagram of the self-attention mechanism module described in the present invention;
[0059] Figure 5 It is the overall design diagram of the continuous casting quality knowledge alignment model of the present invention;
[0060] Figure 6 This is a design diagram of the pre-trained language model fine-tuning module described in the present invention. DETAILED DESCRIPTION
[0061] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0062] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0063] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.
[0064] In the description of the embodiments of the present invention, it should be noted that if the terms "upper", "lower", "horizontal", "inner", etc. indicate an orientation or positional relationship based on the orientation or positional relationship shown in the drawings, or the orientation or positional relationship in which the product of the invention is usually placed when in use, it is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. In addition, the terms "first", "second", etc. are only used to distinguish the description, and cannot be understood as indicating or implying relative importance.
[0065] In addition, if the term "horizontal" appears, it does not mean that the component must be absolutely horizontal, but can be slightly tilted. For example, "horizontal" only means that its direction is more horizontal than "vertical", which does not mean that the structure must be completely horizontal, but can be slightly tilted.
[0066] In the description of the embodiments of the present invention, it is also necessary to explain that, unless otherwise clearly specified and limited, the terms "set", "install", "connect", and "connect" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal connection of two components. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0067] The present invention is further described in detail below in conjunction with the accompanying drawings:
[0068] See also Figures 1 to 6 The present invention discloses a knowledge graph construction method for the field of continuous casting quality engineering, which is used to fill the gap in the knowledge graph construction method of continuous casting billet defects, and further solve the complexity and over-reliance on experience in the query and root cause analysis of continuous casting billet defects in the production process. The deep learning method is used to identify the continuous casting quality entities and relationships from the natural language description of the continuous casting quality; a continuous casting quality knowledge alignment method is proposed, which can eliminate ambiguous continuous casting quality entity pairs, and further construct a knowledge graph in the field of continuous casting quality engineering; it is helpful to quickly locate the causes of defects in the continuous casting production process, optimize the production process, and improve the continuous casting quality, which is innovative.
[0069] The specific steps include:
[0070] Step 1, obtaining relevant data describing defects of the steel billet during the continuous casting process, that is, obtaining relevant natural language descriptions of defects of the steel billet during the continuous casting process according to professional books on continuous casting quality control and core standards for continuous steel casting, and performing sorting and preprocessing;
[0071] The natural language sources mentioned in this step include professional books on continuous casting quality control and defects, and a compilation of core standards for continuous casting. When extracting natural language, tables and pictures are deleted, and then the sentences are segmented according to periods. Next, the sentences are preprocessed, including:
[0072] Convert traditional Chinese characters to simplified Chinese characters, remove uncommon characters, remove '#' and '*' symbols, verify the closure of closed punctuation marks, unify the symbolic expression and Chinese character expression of chemical elements, and unify the symbolic expression and Chinese character expression of size comparison.
[0073] This step builds an ontology model based on professional books and industry standards in the field of continuous steel casting, and defines the entity categories and entity relationship categories of the knowledge graph. Compared with the entire sentence, the entities and relationships defined by the ontology model can describe the continuous casting event more concisely, which is conducive to highlighting and grasping the key points of the event, and then serves as the basis for building the knowledge graph.
[0074] Step 2: Construct the ontology model of the continuous casting quality knowledge graph and define the entity categories and relationship categories of continuous casting quality. Figure 1 to Figure 2 .
[0075] See also Figure 1First, by analyzing the content of continuous casting quality text, the entity categories and relationship categories of continuous casting quality are defined, and the pattern layer of the continuous casting quality knowledge graph is designed in a top-down manner. Then, under the guidance of the pattern layer, the data layer of the continuous casting quality knowledge graph is constructed in a bottom-up manner. According to the characteristics of the continuous casting field data set, a continuous casting quality entity-relationship joint extraction method is designed to extract the continuous casting quality entity and relationship knowledge, and form entity-relationship-entity triples as the basis for knowledge graph construction.
[0076] See also Figure 2 ,Specifically, the ontology model defines six entity categories, namely: continuous casting quality ,defect name, continuous casting quality event, continuous casting quality ,defect cause, continuous casting quality defect feature, continuous casting quality ,problem solution measures and continuous casting event feature;
[0077] The ontology model defines five relationship categories, namely: cause, lead, take, describe, and characteristic.
[0078] Among them, continuous casting events can cause other continuous casting events, solutions and defect causes, and defect causes lead to defect names; defects have defect characteristics and need to take corresponding solutions; characteristics can describe the conditions and specific requirements for the occurrence of continuous casting events, solutions and defect causes.
[0079] Step 3, labeling the continuous casting quality data preprocessed in step 1 according to the continuous casting quality entities and relationship categories defined in step 2;
[0080] Step 4: Build a deep learning model for joint extraction of continuous casting quality based on segmentation and recombination. Use the dataset annotated in step 3 to train the model for joint extraction of entities and relations. Figure 3 to Figure 4 .
[0081] See also Figure 3 ,The continuous casting quality joint extraction deep learning model based on segmentation and ,reorganization of continuous casting quality ,sequence segmentation and recombination module, continuous casting quality entity recognition module and continuous ,casting quality relationship extraction module.
[0082] The input layer:
[0083] The input of the input layer is the annotated natural language text of continuous casting quality obtained in step 3.
[0084] The continuous casting quality sequence segmentation and reorganization module:
[0085] The continuous casting quality sequence segmentation and reorganization module includes a continuous casting quality sequence segmentation module, a self-attention mechanism module and a continuous casting quality sequence reorganization module.
[0086] Among them, the output end of the continuous casting quality sequence segmentation module is connected to three self-attention modules, the output end of the self-attention module is connected to the input end of the continuous casting quality sequence reorganization module, and the output end of the continuous casting quality sequence reorganization module is connected to the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module; the output ends of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module are the continuous casting quality entity relationship extraction results.
[0087] The self-attention module includes an entity gate, a relation gate and a three-head self-attention mechanism layer;
[0088] The continuous casting quality sequence reorganization module includes a connection layer and an activation function layer;
[0089] The continuous casting quality entity recognition module includes a fully connected layer, an activation function layer and a feedforward neural network layer;
[0090] The continuous casting quality relationship extraction module includes a fully connected layer, an activation function layer and a feedforward neural network layer
[0091] Specifically, the structure of the continuous casting quality sequence segmentation module is:
[0092] The continuous casting quality sequence segmentation module includes an entity gate, a relation gate and a connection layer. The specific calculation process includes:
[0093] The continuous casting quality sequence segmentation module contains a solid gate with the following formula:
[0094]
[0095] Where: represents the segmentation sequence of the entity gate; x t represents the continuous casting quality field currently being processed; h represents the hidden layer output of the previous round, which is used as the input for the current round of training; cummax(·) is defined as follows:
[0096] cummax(x)=cumsum(softmax(x))
[0097] Where: cumsum(·) is the cumulative sum function, and cummax(·) can be used to serialize it into (0,…,0,1,…,1).
[0098] Furthermore, the relation gate formula is as follows:
[0099]
[0100] Where: represents the partition sequence of the relation gate; cummax(·) is defined as above; x tRepresents the continuous casting quality field currently being processed; h represents the hidden layer output of the previous round, which is used as the input for the current round of training.
[0101] The entity gate splits a piece of continuous casting quality corpus into two parts: the part related to entity recognition and the part not related to entity recognition. Similarly, the relation gate splits a piece of continuous casting quality corpus into the part related to relation extraction and the part not related to relation extraction.
[0102] Furthermore, according to the formula:
[0103]
[0104] Where: Represents the shared partial sequence of the current continuous casting quality field; x i Indicates the word currently being processed; e i Indicates the entity gate division result; r i Represents the result of relational gate division; (x i ·e i ) represents a sequence related to entity recognition; (x i ·r i ) represents a sequence related to relation extraction; operator It means taking the intersection of the two.
[0105]
[0106] Where: Represents the entity recognition partial sequence of the current word; (x i ·e i ) represents a sequence related to entity recognition; Indicates the shared part sequence of the current word; the operator - indicates taking the difference between the two;
[0107]
[0108] Where: Represents the partial sequence of relation extraction of the current word; (x i ·r i ) represents a sequence related to relation extraction; Represents the shared part sequence of the current word; the operator - represents taking the difference between the two.
[0109] Furthermore, the input data is divided into three parts, namely, the continuous casting quality sequence entity recognition part Continuous casting quality sequence relationship identification part Shared with continuous casting quality sequence Then, through the formula:
[0110]
[0111] Where: e , s , r Respectively represent the entity recognition sequence, sharing sequence, and relationship extraction sequence results after segmentation; Represents the entity recognition partial sequence, shared sequence, and relation extraction sequence of the current word.
[0112] Furthermore, the input of the self-attention mechanism module is the ρ obtained above. e , s , r , see Figure 3 ,
[0113] The self-attention mechanism module is a structure similar to the three-head self-attention mechanism, which is divided into three groups. The input of each group corresponds to the entity recognition part, relationship recognition part and sharing part mentioned above. Calculate each group of self-attention mechanisms, as shown in the formula:
[0114] Q=W q P,K=W k P,V=W v P
[0115] Where: Q, K, V represent the Query, Key, and Value matrices in the self-attention mechanism respectively; W q , W k , W v Respectively represent the weight matrices of Query, Key, and Value; P represents the input sequence.
[0116] The result of each part is as follows:
[0117] B=V(softmax(K T Q))
[0118] Where: B represents the output of each head of the multi-head self-attention mechanism; Q, K, V represent the Query, Key, and Value matrices in the self-attention mechanism respectively.
[0119] The final output of the self-attention mechanism module is as follows:
[0120] O=W b (Linear([B e ,B s ,B r ]))
[0121] Where: O represents the final output of the self-attention mechanism module; W b The weight matrix representing the splicing continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence; B e , B s, B r They respectively represent the results of continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence after corresponding self-attention mechanism.
[0122] Furthermore, the continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence are respectively passed through the self-attention mechanism module, and the output obtained is connected to the continuous casting quality sequence reorganization module. The reorganization process is as follows:
[0123] μ e =o e +o s ,μ s =o s ,μ r =o r +o s
[0124] Where: μ e , μ s , μ r They represent the reorganized entity recognition sequence, sharing sequence and relation extraction sequence of the continuous casting quality field respectively; e , o s , o r They respectively represent the results of continuous casting quality entity recognition sequence, sharing sequence and relationship extraction sequence through the self-attention mechanism module.
[0125] The final output of the continuous casting quality sequence segmentation and recombination module is as follows:
[0126] h=tanh(Linear([μ e , μ s ,μ r ]))
[0127] h e =tanh(μ e )
[0128] h r =tanh(μ r )
[0129] Where: h is the hidden layer output, which is used to help the next round of training; h e and h r They represent the outputs for continuous casting quality entity recognition and continuous casting quality relationship extraction respectively; μ e , μ s , μ r They respectively represent the transformed and reorganized continuous casting quality entity recognition sequence, sharing sequence and relationship extraction sequence.
[0130] Furthermore, the output layer of the continuous casting quality sequence segmentation and reorganization module is connected to the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module. The continuous casting quality entity recognition module needs to recognize and classify the entities in a given continuous casting quality sequence.
[0131] Specific:
[0132] Given a set of entity types ε, for each type k, fill in the continuous casting quality entity recognition table, whose elements Represents word w i and the word w j As the probability of the start and end position of an entity of type k. For each group (w i ,w j ), features at the connective level and sentence-level global features And pass it through a fully connected layer and ELU activation function to get the entity representation of the group of words, as shown in the formula:
[0133]
[0134] Where: Represents word w i and the word w j Representation of the continuous casting mass entity as the beginning and the end; and Represents word-level features; Represents the global features at the sentence level.
[0135] according to The probability that the continuous casting quality entity is of the kth category is obtained through a feedforward neural network, as shown in the formula:
[0136]
[0137] Where: Represents word w i and the word w j The probability that the entities at the beginning and end are entities of the kth type of continuous casting quality; Represents word w i and the word w j as the representation of the continuous casting mass entity at the beginning and end; σ represents the sigmoid activation function.
[0138] The continuous casting quality relation extraction module aims to identify all triples in the continuous casting quality sentence. In this module, only the starting position of the entity needs to be predicted, because the scope of the entire entity has been identified by the continuous casting quality entity recognition module. Similar to the continuous casting quality entity recognition module, the continuous casting quality relation extraction module is also regarded as a table filling problem for a specific relationship. Given a relation set R, for each relation l, a relation table is constructed, whose elements Indicates w i and w j is the probability of the head and tail entities of the continuous casting quality of the relation. Therefore, we can use a table to extract all triples related to the relation l. For each triple (w i ,l,w j ), by connecting and Get the feature representation of the triple, such as the formula:
[0139]
[0140] Where: Represents word w i and the word w j Representation of the continuous casting quality triplet as head and tail entities; and Represents word-level features; Represents the global features at the sentence level.
[0141] Furthermore, according to the triplet feature representation, the probability that the continuous casting quality triplet is correct is obtained through a feedforward neural network, as shown in the formula:
[0142]
[0143] Where: Represents word w i and the word w j The probability that the continuous casting quality triplet as the head and tail entities is the lth type of relationship; Represents word w i and the word w j Representation of the casting quality triplet as the head and tail entities; σ denotes the sigmoid activation function.
[0144] The loss used in the embodiment of the present invention is BCELoss, and the formula is as follows:
[0145] BCELoss(x,y)=-(ylogx+(1-y)log(1-x))
[0146] The task of the embodiment of the present invention is to identify entities and relationships in the natural language of the continuous casting field. Therefore, the loss function is defined for the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module, respectively, as shown in the formula:
[0147]
[0148] Where: L ner and L re They represent the loss function of continuous casting quality entity recognition and the loss function of continuous casting quality relationship extraction respectively; BCELoss is defined as above; and Label classifications representing real continuous casting quality entities and relations, respectively; and Label assortment representing calculated casting quality entities and relationships.
[0149] The overall loss function is as follows:
[0150] L=L ner +L re
[0151] Where: L is the total loss function; L ner is the loss function for continuous casting quality entity recognition; L re is the loss function for continuous casting quality relationship extraction
[0152] Using deep learning methods, continuous casting quality entities and relationships between entities are extracted from the natural language of continuous casting quality, and the continuous casting quality entity categories and relationship categories are determined based on the continuous casting quality knowledge graph ontology model. Compared with the assembly line mode of first identifying the continuous casting quality entity and then extracting the continuous casting quality relationship based on the entity recognition result, the method proposed in the present invention can take into account the close relationship between the continuous casting quality entity and the relationship, and can avoid the error propagation problem of the error of entity recognition affecting the relationship extraction.
[0153] Step 5, based on the continuous casting quality entity-relationship-entity triples obtained in step 4, annotate them according to whether the semantics are the same, and prepare data for entity alignment. Based on this, the present invention discloses a specific embodiment, see Table 1.
[0154] The entity pairs of the continuous casting quality triples obtained in step 4 are labeled to construct positive samples; any entity in the positive sample is replaced and under-sampled to construct negative samples.
[0155] Table 1
[0156]
[0157]
[0158] Using the deep learning method, the continuous casting quality knowledge alignment problem is converted into a paired continuous casting quality entity matching problem. Using the semi-supervised incremental learning method, the training process is divided into two stages to reduce the demand for data in the continuous casting quality field. At the same time, in order to reduce the impact of pseudo samples on model performance, adversarial training is introduced to improve the robustness of the model.
[0159] Step 6: Based on the data obtained in step 5, a continuous casting quality knowledge alignment model based on semi-supervised incremental learning is constructed to perform knowledge alignment. Based on the aligned triples, a knowledge graph in the field of continuous casting quality engineering is constructed. For the specific process, see Figures 5 and 6 .
[0160] The continuous casting quality knowledge alignment model based on semi-supervised incremental learning includes an input layer, a pre-trained language model fine-tuning module, a continuous casting quality knowledge pseudo-label generation module and a continuous casting quality knowledge alignment incremental learning module. Figure 5 This is the overall flow chart of the entity alignment model based on semi-supervised incremental learning.
[0161] The input of the continuous casting knowledge alignment method is the labeled continuous casting quality data obtained in step 5. First, the BERT (CHINESE) model is fine-tuned using the labeled data. The input sequence of the entity pair data is as follows:
[0162] I={[CLS],x1,x2,…,x n [SEP],y1,y2,…,y m ,[SEP]}
[0163] Where: I represents the input continuous casting quality sequence; [CLS] and [SEP] are special separators for BERT model input; x i and j Characters representing entity 1 and entity 2 respectively.
[0164] Furthermore, the pre-trained language model fine-tuning module includes a BERT (CHINESE) module and a result prediction module, such as Figure 6 As shown. The BERT (CHINESE) module contains 12 Transformer encoders; the Transformer encoder contains a multi-head self-attention mechanism, a feedforward neural network and a normalization layer. The continuous casting quality knowledge alignment result prediction module contains an aggregation module and a softmax classifier, as shown in the formula:
[0165]
[0166] Where: H is the output of the pre-trained language model fine-tuning module, that is, the prediction result; Represents the parameter aggregation of the 12th layer, or the last layer, of the BERT(CHINESE) model.
[0167] The continuous casting quality knowledge pseudo-label generation module comprises an input layer, a prediction layer and an output layer. The input of the input layer is an unlabeled continuous casting quality entity pair sample; the prediction layer is a model fine-tuned by the pre-trained language model fine-tuning module; the output layer outputs whether the unlabeled continuous casting quality entity pair sample needs to be fused and gives a confidence probability.
[0168] The continuous casting quality knowledge alignment incremental learning module first selects pseudo-labeled continuous casting quality samples as incremental data according to the confidence probability and adds them to the labeled samples, and then fine-tunes BERT (CHINESE) again. The continuous casting quality knowledge alignment incremental learning module includes a BERT (CHINESE) module and a result prediction module. In order to overcome the negative impact of random noise on model performance and further enhance the generalization ability and robustness of the entity alignment model in the continuous casting quality knowledge fusion process, the present invention introduces adversarial training in the incremental learning module. Adversarial training uses the BERT ATTACK model to generate perturbation samples. The BERT ATTACK model is an adversarial sample generation technology based on BERT, which generates continuous casting quality adversarial samples by finding vulnerable words in continuous casting quality texts and replacing them. After obtaining the continuous casting quality adversarial samples, the continuous casting quality adversarial samples, labeled continuous casting quality data, and pseudo-labeled continuous casting quality data are used as inputs for incremental learning of continuous casting quality knowledge alignment. The pre-trained language model is further fine-tuned using incremental learning to improve the robustness and accuracy of the continuous casting quality entity alignment model of the present invention, and the final prediction result is obtained through the continuous casting quality knowledge alignment result prediction module.
[0169] According to the aligned continuous casting quality entity pairs and relationship triplets, they can be used as the head and tail entities and relationships of the continuous casting quality knowledge graph to construct the knowledge graph in the field of continuous casting quality engineering.
[0170] The present invention can reduce the difficulty of analyzing the root causes of continuous casting quality defects, is conducive to quickly locating the causes of defects and optimizing the process, and improves the quality of the casting, which is very meaningful and valuable.
[0171] This embodiment also discloses a knowledge graph construction system for the field of continuous casting quality engineering, including:
[0172] The original data acquisition module is used to obtain relevant data describing defects in the steel billet during the continuous casting process;
[0173] An ontology model building module is used to build an ontology model of the continuous casting quality knowledge graph and define entity categories and relationship categories of continuous casting quality based on the ontology model;
[0174] A data annotation module is used to annotate the acquired relevant data describing the defects of the steel billet based on entity categories and relationship categories to obtain the annotated data;
[0175] A triple acquisition module is used to build a deep learning model for joint extraction of continuous casting quality based on segmentation and recombination, and use the labeled data as the input of the deep learning model for joint extraction of continuous casting quality based on segmentation and recombination to obtain entity-relationship-entity triple data of continuous casting quality;
[0176] A semantic annotation module, used to semantically annotate the acquired entity-relationship-entity triple data to obtain semantically annotated data;
[0177] The knowledge graph acquisition module is used to build a continuous casting quality knowledge alignment model, take the semantic annotation data as the input of the continuous casting quality knowledge alignment model, obtain the aligned triple data, and build a knowledge graph in the field of continuous casting quality engineering based on the aligned triple data.
[0178] A schematic diagram of a terminal device provided in an embodiment of the present invention. The terminal device of this embodiment includes: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps in the above-mentioned method embodiments are implemented. Alternatively, when the processor executes the computer program, the functions of the modules / units in the above-mentioned device embodiments are implemented.
[0179] The computer program may be divided into one or more modules / units, and the one or more modules / units are stored in the memory and executed by the processor to accomplish the present invention.
[0180] The terminal device may be a computing device such as a desktop computer, a notebook, a PDA, a cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.
[0181] The processor can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
[0182] The memory may be used to store the computer programs and / or modules, and the processor implements various functions of the terminal device by running or executing the computer programs and / or modules stored in the memory and calling the data stored in the memory.
[0183] If the module / unit integrated in the terminal device is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.
[0184] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A knowledge graph construction method for continuous casting quality engineering, characterized in that: The following steps are involved: Obtain relevant data describing defects in steel billets during continuous casting; Construct an ontology model of continuous casting quality knowledge graph, and define entity categories and relationship categories of continuous casting quality based on the ontology model; Annotate the acquired relevant data describing the defects of the steel billet based on the entity category and the relationship category to obtain the annotated data; A deep learning model for joint extraction of continuous casting quality based on segmentation and recombination is constructed, and the labeled data is used as the input of the deep learning model for joint extraction of continuous casting quality based on segmentation and recombination to obtain entity-relationship-entity triple data of continuous casting quality; Performing semantic annotation on the acquired entity-relationship-entity triple data to acquire semantically annotated data; Construct a continuous casting quality knowledge alignment model, use the semantic annotation data as the input of the continuous casting quality knowledge alignment model, obtain the aligned triple data, and construct a knowledge graph in the field of continuous casting quality engineering based on the aligned triple data.
2. A knowledge graph construction method for continuous casting quality engineering according to claim 1, characterized in that: The entity categories include: names of continuous casting quality defects, continuous casting quality events, causes of continuous casting quality defects, characteristics of continuous casting quality defects, solutions to continuous casting quality problems and characteristics of continuous casting events; The relationship categories include: causes, causes, describes, takes, and is characterized by.
3. A knowledge graph construction method for continuous casting quality engineering according to claim 1, characterized in that: The continuous casting quality joint extraction deep learning model based on segmentation and recombination includes an input layer, a continuous casting quality sequence segmentation and recombination module, a continuous casting quality entity recognition module and a continuous casting quality relationship extraction module; The labeled data is used as the input of the input layer, and the output of the input layer is connected to the input of the continuous casting quality sequence segmentation and reorganization module; The continuous casting quality sequence segmentation and reorganization module includes a continuous casting quality sequence segmentation module, a self-attention mechanism module and a continuous casting quality sequence reorganization module which are connected in sequence; The output end of the continuous casting quality sequence reorganization module is connected to the input end of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module, and the output results of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module are the continuous casting quality entity relationship extraction results.
4. A knowledge graph construction method for continuous casting quality engineering according to claim 3, characterized in that: The calculation results of the continuous casting quality sequence segmentation and recombination module are: Where: e , s , r Respectively represent the entity recognition sequence, sharing sequence, and relationship extraction sequence results after segmentation; Represents the entity recognition partial sequence, shared sequence, and relation extraction sequence of the current word.
5. A knowledge graph construction method for continuous casting quality engineering according to claim 4, characterized in that: The calculation process of the self-attention mechanism module includes: ρ e , s , r As the input of the self-attention mechanism module, we calculate: Q=W q P,K=W k P,V=W v P Where: Q, K, V represent the Query, Key, and Value matrices in the self-attention mechanism respectively; W q , W k , W v Represent the weight matrices of Query, Key, and Value respectively; P represents the input sequence; The calculation results of each part of the self-attention mechanism module are: B=V(softmax(K T Q)) Where: B represents the output of each head of the multi-head self-attention mechanism; Q, K and V represent the Query matrix, Key matrix and Value matrix in the self-attention mechanism respectively; The final calculation result of the self-attention mechanism module is: O=W b (Linear([B e ,B s ,B r ])) Where: O represents the final output of the self-attention mechanism module; W b The weight matrix representing the splicing continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence; B e , B s and B r They respectively represent the results of continuous casting quality entity recognition sequence, relationship extraction sequence and sharing sequence after corresponding self-attention mechanism.
6. A knowledge graph construction method for continuous casting quality engineering according to claim 3, characterized in that: The continuous casting quality entity recognition module and the continuous casting quality relationship extraction module both include a fully connected layer, an activation function layer and a feedforward neural network layer.
7. A knowledge graph construction method for continuous casting quality engineering according to claim 6, characterized in that: The output results of the continuous casting quality entity recognition module and the continuous casting quality relationship extraction module include: Given a set of relations R, for each relation l, construct a relation table whose elements Indicates w i and w j is the probability of the head and tail entities of the continuous casting quality of the relation, extract all triples related to the relation l, and for each triple (w i ,l,w j ), by connecting and Get the feature representation of the triple: Where: Represents word w i and the word w j Representation of the continuous casting quality triplet as head and tail entities; and Represents word-level features; Represents global features at the sentence level; According to the feature representation of the triplet, the correct probability of the continuous casting quality triplet is obtained through the feedforward neural network: Where: Represents word w i and the word w j The probability that the continuous casting quality triplet as the head and tail entities is the lth type of relationship; Represents word w i and the word w j Representation of the casting quality triplet as the head and tail entities; σ denotes the sigmoid activation function.
8. A knowledge graph construction system for continuous casting quality engineering, characterized in that: include: The original data acquisition module is used to obtain relevant data describing defects in the steel billet during the continuous casting process; An ontology model building module is used to build an ontology model of the continuous casting quality knowledge graph and define entity categories and relationship categories of continuous casting quality based on the ontology model; A data annotation module is used to annotate the acquired relevant data describing the defects of the steel billet based on entity categories and relationship categories to obtain the annotated data; A triple acquisition module is used to build a deep learning model for joint extraction of continuous casting quality based on segmentation and recombination, and use the labeled data as the input of the deep learning model for joint extraction of continuous casting quality based on segmentation and recombination to obtain entity-relationship-entity triple data of continuous casting quality; A semantic annotation module is used to semantically annotate the acquired entity-relationship-entity triple data to obtain semantically annotated data; The knowledge graph acquisition module is used to build a continuous casting quality knowledge alignment model, take the semantic annotation data as the input of the continuous casting quality knowledge alignment model, obtain the aligned triple data, and build a knowledge graph in the field of continuous casting quality engineering based on the aligned triple data.
9. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Steel product surface longitudinal crack defect tracing and analyzing method based on knowledge graph
CN113420157A
Improved dynamic data mining method and device for continuous casting quality judgment model
CN115345434A
Continuous casting slab quality tracing method based on decision tree and knowledge graph
CN117009586A
Cited By
Continuous casting process knowledge graph construction and process parameter prediction method, system and equipment
CN119311901A
A method, system, and equipment for constructing a knowledge graph of continuous casting process and predicting process parameters.
CN119311901B
Knowledge graph and deep learning fusion-based slab longitudinal crack forecasting method
CN122778318A
