A method and system for automatically constructing a knowledge graph for steel manufacturing enterprises
Joint extraction of entity relationships through the BERT pre-training model and the bidirectional Transformer structure, combined with the knowledge evolution module, solves the problems of time-consuming and labor-intensive construction of traditional domain knowledge graphs and incomplete automatic construction, and achieves high efficiency of knowledge graphs in the steel manufacturing field. Construction and knowledge evolution.
Patent Information
- Application Number
- CN202111100811.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-18
- Publication Date
- 2024-08-27
- Estimated Expiration
- 2041-09-18
AI Technical Summary
Traditional domain knowledge graph construction methods rely on expert manual work, which is time-consuming and labor-intensive. In addition, existing automatic construction methods have accumulation of knowledge extraction errors and incompleteness, making it difficult to build high-quality and highly relevant knowledge graphs, especially in the field of steel manufacturing.
BERT pre-training model and bidirectional Transformer structure are used to jointly extract entity relationships, and entity vector representation is generated through maximum pooling and Softmax processing. It is combined with the relationship classification module for end-to-end modeling, and a knowledge evolution module is added for triple completion and Confidence scoring, using improved path sorting algorithm to mine new triples.
It achieves efficient construction of knowledge graphs in the field of steel manufacturing, reduces construction costs, reduces error accumulation, improves the integrity and construction efficiency of knowledge graphs, and enhances knowledge learning and evolution capabilities.
Smart Images

Figure CN113868432B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of knowledge graph construction, and in particular to a method and system for automatically constructing a knowledge graph for a steel manufacturing enterprise. Background Art
[0002] With the rapid development of technologies such as the Internet, big data, and artificial intelligence, traditional manufacturing is accelerating towards a new generation of intelligent manufacturing, and the integration of informatization and industrialization has become a development trend. In the process of development from traditional manufacturing to intelligent manufacturing, with the increasing complexity of manufacturing systems and the growing personalized needs of users, the scale of industrial data generated in the manufacturing process has become increasingly large and diverse. Heterogeneous data will cause problems with information interaction. Abstracting heterogeneous data into knowledge, modeling knowledge, and using knowledge graphs to integrate and fuse heterogeneous data can not only solve operational obstacles and reduce data redundancy, but also enhance data reasoning and decision-making capabilities.
[0003] Compared with general knowledge graphs, domain knowledge graphs are built based on specific data sets and emphasize the depth of knowledge. Traditional domain knowledge graph construction methods rely on manual construction by experts, which requires a lot of human resources. Once the scale of the constructed knowledge graph is relatively large, it will take a lot of time and effort. At present, the research on knowledge modeling methods in the manufacturing field has not yet formed a mature system. Studying the knowledge modeling methods and evolution mechanisms of steel manufacturing companies, constructing high-quality, highly relevant, and semantically rich knowledge graphs and completing them can not only solve the problem of few semantic associations between information, but also improve the efficiency of knowledge graph construction and reduce the cost of knowledge graph construction, which is of great theoretical research significance.
[0004] In recent years, with the continuous development of deep learning and natural language processing technology, the automatic construction of knowledge graphs in the steel industry has become possible, but there are still the following shortcomings: (1) At present, knowledge extraction mostly adopts the traditional pipeline extraction method, which will cause error accumulation when there are multiple extraction tasks. (2) The process of knowledge modeling adopts an automatic form, which is bound to make the knowledge contained in it incomplete, that is, the knowledge base cannot contain all the knowledge. Due to the incompleteness of the knowledge graph, knowledge graph completion can be used to add new triples to the knowledge graph to realize knowledge learning and evolution. Summary of the invention
[0005] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and to provide a method and system for automatically constructing a knowledge graph for steel manufacturing enterprises, abstract heterogeneous data into knowledge, and model the knowledge. At the same time, it improves the efficiency of knowledge graph construction in the steel manufacturing field, reduces the cost of knowledge graph construction in the steel manufacturing field, and provides a solution for enterprise data management.
[0006] The purpose of the present invention can be achieved by the following technical solutions:
[0007] A method for automatically constructing a knowledge graph for a steel manufacturing enterprise comprises the following steps:
[0008] Data collection steps: Collect text data from manufacturing companies;
[0009] Data processing steps: pre-process the collected text data and construct a single sentence set;
[0010] Knowledge modeling step: loading a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector;
[0011] The word sequence vector is subjected to maximum pooling processing, and is concatenated with the [CLS] vector generated by the BERT pre-trained model according to the single sentence to obtain an entity vector representation, and finally a full connection and Softmax processing are performed to obtain an entity recognition result;
[0012] According to the entity vector representation, a candidate relationship vector is selected and loaded into a pre-established and trained relationship classification module together with the entity vector representation, and full connection and Softmax processing are performed to obtain a relationship classification result;
[0013] According to the entity recognition results and relationship classification results, entity relationship triples are obtained to complete the construction of the knowledge graph.
[0014] Furthermore, the preprocessing includes determining the completeness of sentences in the text data and performing deduplication and special symbol removal processing on each sentence.
[0015] Furthermore, the bidirectional Transformer structure adopts a multi-head attention mechanism for feature aggregation, and the calculation expression of the multi-head attention mechanism is:
[0016] MultiHead(Q,K,V)=Concat(head 1 ,…,head h )W o
[0017] head i =Attention(QW i Q ,KW i K ,VW i V )
[0018]
[0019] Where MultiHead(Q,K,V) is the output of the multi-head attention mechanism, Q, K, and V are the word vector matrix, sentence vector matrix, and position vector matrix, respectively, which are output by the BERT pre-trained model, and W O is the additional weight matrix, W i Q , W i K , W i V Indicates different linear transformations to project Q, K, V, d k is the number of columns of the Q, K, V matrices.
[0020] Furthermore, in the word sequence vector, the vector corresponding to position t is expressed as:
[0021]
[0022]
[0023] Wherein, k is a natural number.
[0024] Furthermore, the entity vector is expressed as:
[0025]
[0026] In the formula, e i is the word vector representation after the maximum pooling process, c is the [CLS] vector, and the symbol For concatenation, m is the position mark of the ending character of the candidate entity, and n is the position mark of the beginning character of the candidate entity;
[0027] The calculation expression of the entity recognition result is:
[0028]
[0029] In the formula, is the entity recognition result, softmax is the Softmax processing function, W is the multiplication coefficient, b is the addition coefficient, x e is the entity vector representation.
[0030] Furthermore, the calculation expression for the relationship classification module to obtain the relationship classification result is:
[0031]
[0032]
[0033] In the formula, is the relationship classification result, softmax is the Softmax processing function, W s is the relation classification multiplication coefficient, c r is the candidate relation vector, x e1 c r The entity vector before is represented by x e2 c r The entity vector representation after .
[0034] Furthermore, the method further comprises a knowledge evolution step: inputting the obtained entity relationship triples into a preset word vector embedding model, embedding the extracted knowledge into a low-dimensional vector space, and scoring the confidence of the entity relationship triples according to the constructed loss function, and judging whether it is a correct triple by a preset confidence threshold;
[0035] The correct triples are input into the improved path sorting algorithm to mine new triples as the evolved knowledge graph.
[0036] Furthermore, the word vector embedding model uses the TransE model to encode entity-relationship triples, encodes entities and relationships into vector spaces of the same dimension, and assumes that:
[0037] h+rt≈0
[0038] In the formula, h is the head entity vector, r is the relationship vector, and t is the tail entity vector;
[0039] The calculation expression of the loss function is:
[0040]
[0041] In the formula, f r (h, t) is the calculation result of the loss function, symbol is the L2 norm.
[0042] Furthermore, the improved path sorting algorithm uses a double-layer random walk mechanism to evaluate path features, and the double-layer random walk mechanism introduces a heuristic method of vector space similarity to obtain relationship path feature patterns.
[0043] The present invention also provides a knowledge graph automatic construction system using the above-mentioned knowledge graph automatic construction method for steel manufacturing enterprises, comprising:
[0044] The data collection module is configured to: collect text data of the manufacturing enterprise;
[0045] The data processing module is configured to: pre-process the collected text data and construct a single sentence set;
[0046] The knowledge modeling module is configured to: load a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector;
[0047] The word sequence vector is subjected to maximum pooling processing, and is concatenated with the [CLS] vector generated by the BERT pre-trained model according to the single sentence to obtain an entity vector representation, and finally a full connection and Softmax processing are performed to obtain an entity recognition result;
[0048] According to the entity vector representation, a candidate relationship vector is selected and loaded into a pre-established and trained relationship classification module together with the entity vector representation, and full connection and Softmax processing are performed to obtain a relationship classification result;
[0049] According to the entity recognition results and relationship classification results, entity relationship triples are obtained to complete the construction of the knowledge graph.
[0050] Compared with the prior art, the present invention has the following advantages:
[0051] (1) The present invention provides a method for automatically constructing a domain knowledge graph. First, a single sentence is obtained by collecting texts, and then a word sequence vector is obtained by a BERT pre-trained model, and then concatenated with a [CLS] vector to obtain an entity vector representation. On the one hand, the entity recognition result can be obtained by the entity vector representation. On the other hand, in order to overcome the defect of error accumulation in the traditional pipeline extraction method, the present invention combines the entity vector representation obtained by the BERT pre-trained model with the candidate relationship vector and loads them into a relationship classification module to obtain a relationship classification result, thereby achieving joint modeling of entity recognition and relationship extraction tasks, realizing an end-to-end model, reducing error accumulation, and achieving a better effect.
[0052] (2) The present invention takes into account that the knowledge base cannot contain all knowledge due to the knowledge modeling process, and there is incompleteness in the knowledge graph. The additional knowledge evolution module step completes the knowledge graph, thereby realizing the learning and evolution of knowledge;
[0053] In the knowledge evolution module step, the present invention first performs dimension conversion on the extracted triples, then performs confidence scoring to determine the correct triples, and then mines new triples by improving the path sorting algorithm;
[0054] The improved path sorting algorithm uses a double-layer random walk mechanism to evaluate path features, introduces a heuristic method of vector space similarity in the random walk, relaxes sampling constraints to alleviate the sparsity of path features, obtains more relational path feature patterns, and improves the discovery rate of effective relational patterns.
[0055] (3) The present invention abstracts heterogeneous data into knowledge and models the knowledge, thereby improving the efficiency of constructing the knowledge graph in the steel manufacturing field, reducing the cost of constructing the knowledge graph in the steel manufacturing field, and providing a solution for enterprise data management. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] Figure 1 Schematic diagram of a flow chart of a method for automatically constructing a knowledge graph for a steel manufacturing enterprise proposed in an embodiment of the present invention. DETAILED DESCRIPTION
[0057] 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.
[0058] 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.
[0059] Example 1
[0060] like Figure 1 As shown, this embodiment provides a method for automatically constructing a knowledge graph for a steel manufacturing enterprise, comprising the following steps:
[0061] Data collection step S1: collecting text data of manufacturing enterprises;
[0062] In this embodiment, this part is composed of internal and external information of the manufacturing enterprise, including enterprise information system data, production equipment information, and supplier and customer information on the Internet. The collected data includes expert experience, team logs, supplier information, and process systems, production scheduling plans, and rule data from the enterprise information system, as well as equipment data, steel grade data, etc. These text information are the data source for constructing the knowledge graph in the manufacturing field.
[0063] Data processing step S2: preprocessing the collected text data to construct a single sentence set;
[0064] In this embodiment, after the required data is collected, it is necessary to pre-process the data, analyze the characteristics of the data, and parse the webpage text. The integrity of the paragraphs and sentences in the text is determined, and each sentence is pre-processed by removing duplicates, special characters, etc., and finally a collection of single sentences is input to the next part;
[0065] Knowledge modeling step S3: Use entity relationship joint extraction algorithm to extract and model knowledge, which specifically includes the following steps:
[0066] S31: Loading a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector;
[0067] In this embodiment, for a single input sentence, the BERT pre-trained model is first used to segment and vectorize it; the output vector is composed of a word vector (Token Embedding), a sentence vector (Segment Embedding), and a position vector (Position Embedding), which are added and sent to a bidirectional Transformer structure for feature extraction, and finally a sequence vector containing rich semantic features is obtained. The model structure of the deep bidirectional Transformer is the core of the BERT model, which enables the model to represent the specific semantics of words in context when processing words. The Transformer encoding structure adopts a multi-head attention mechanism, abandons the time loop structure, and can process the entire input sequence at the same time. The output of the multi-head attention mechanism is:
[0068] MultiHead(Q,K,V)=Concat(head 1 ,…,head h )W o
[0069] head i =Attention(QWi i Q ,KW i K ,VW i V )
[0070]
[0071] Where MultiHead(Q,K,V) is the output of the multi-head attention mechanism, Q, K, and V are the word vector matrix, sentence vector matrix, and position vector matrix, respectively, which are output by the BERT pre-trained model, and W o is the additional weight matrix, W i Q , W i K , W i V Indicates different linear transformations to project Q, K, V, d k is the number of columns of the Q, K, V matrices.
[0072] For an input sequence of length n, the vector corresponding to position t in its word sequence vector is expressed as:
[0073]
[0074]
[0075] In the formula, k is a natural number;
[0076] S32: Perform maximum pooling on the word sequence vector output by the BERT pre-training model, average and concatenate it with the [CLS] vector generated by the BERT pre-training model based on the single sentence to obtain the entity vector representation x e ; This entity vector represents x e The expression is:
[0077]
[0078] In the formula, e i is the word vector representation after the maximum pooling process, c is the [CLS] vector, and the symbol is concatenated, m is the position mark of the ending character of the candidate entity, n is the position mark of the beginning character of the candidate entity; [CLS] vector is the semantic feature vector that can represent the entire text;
[0079] Finally, the entity vector x e Send it to the fully connected plus Softmax layer to calculate the most likely entity tag. The formula is as follows:
[0080]
[0081] In the formula, is the entity recognition result, softmax is the Softmax processing function, W is the multiplication coefficient, b is the addition coefficient, x e is the entity vector representation.
[0082] S33: Select candidate relationship vectors according to the entity vector representation, and load them together with the entity vector representation into a pre-established and trained relationship classification module, perform full connection and Softmax processing, and obtain a relationship classification result;
[0083] In this embodiment, the entity recognition results and the sentence-level representation obtained by the BERT pre-training model are input into the relation classifier, and the relation classification results are obtained after full connection and Softmax operations. The relation classification module input consists of two parts: one is the entity vector representation x obtained in the entity recognition part. e , including the word sequence vector and the semantic feature vector [CLS] that can represent the entire text; the second is the vector representation of the text between two entities, that is, the candidate relationship vector, which is concatenated with the previous and next entity vectors after the maximum pooling process and sent to the relationship classifier. The formula is as follows:
[0084]
[0085]
[0086] In the formula, is the relationship classification result, softmax is the Softmax processing function, W s is the relation classification multiplication coefficient, c r is the candidate relationship vector, which is also the word sequence vector after the maximum pooling process. e1 c r The entity vector before is represented by x e2 c r The entity vector representation after .
[0087] S34: After obtaining entity relationship triples according to the entity recognition results and relationship classification results, that is, entity relationship triples in the form of "<heating furnace, including, igniter>", screening is performed to complete knowledge modeling.
[0088] As a preferred implementation, this embodiment also provides a knowledge evolution step, which is described in detail as follows:
[0089] 4. Steps of knowledge evolution
[0090] Knowledge evolution step S4: The main task is to complete the knowledge graph and infer new unknown knowledge based on existing knowledge; it specifically includes the following steps:
[0091] S41: Input the obtained entity relationship triples into a preset word vector embedding model, embed the extracted knowledge into a low-dimensional vector space, and score the confidence of the entity relationship triples according to the constructed loss function, and determine whether it is a correct triple by a preset confidence threshold;
[0092] In this embodiment, the entity relationship triples are input into the word vector embedding model, the extracted knowledge is embedded in the low-dimensional vector space, and the word vector embedding model is used to score the confidence of the triples according to the constructed loss function. The specific operation is to project the head and tail entity vectors in the triplet onto the hyperplane corresponding to the relationship. If the triplet is true, the entity vectors will be connected with a small error. The loss function value is introduced into the scoring function, and the candidate facts are scored, and the correct facts are encouraged to obtain smaller values to judge the credibility of the triplet; this embodiment uses the TransE model to encode the candidate triples. The model regards the relationship as a transfer from the head entity to the tail entity, encodes the entities and relationships in the knowledge base into the vector space of the same dimension, and assumes:
[0093] h+rt≈0
[0094] Among them, h is the head entity vector, r is the relation vector, and t is the tail entity vector.
[0095] The loss function of this model is:
[0096]
[0097] In the formula, f r (h, t) is the calculation result of the loss function, symbol is the L2 norm.
[0098] Finally, by setting a threshold, we can determine whether it is a correct triplet based on the result of the loss function.
[0099] S42: Input the correct triples into the improved path sorting algorithm and evaluate the path characteristics using a double-layer random walk mechanism;
[0100] S43: Introducing a heuristic method of vector space similarity in random walks, relaxing sampling constraints to alleviate the sparsity of path features, obtaining more relational path feature patterns, and improving the discovery rate of effective relational patterns;
[0101] S44: The final output is the completed triple, i.e. the evolved knowledge.
[0102] This embodiment also provides a knowledge graph automatic construction system using the above-mentioned knowledge graph automatic construction method for a steel manufacturing enterprise, comprising:
[0103] The data collection module is configured to: collect text data of the manufacturing enterprise; which is equivalent to executing the above data collection step S1;
[0104] The data processing module is configured to: pre-process the collected text data to construct a single sentence set; which is equivalent to executing the above data processing step S2;
[0105] The knowledge modeling module is configured to: load a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector;
[0106] The word sequence vector is subjected to maximum pooling processing, and is concatenated with the [CLS] vector generated by the BERT pre-trained model according to the single sentence to obtain an entity vector representation, and finally a full connection and Softmax processing are performed to obtain an entity recognition result;
[0107] According to the entity vector representation, a candidate relationship vector is selected and loaded into a pre-established and trained relationship classification module together with the entity vector representation, and full connection and Softmax processing are performed to obtain a relationship classification result;
[0108] According to the entity recognition results and the relationship classification results, entity relationship triples are obtained to complete the construction of the knowledge graph; which is equivalent to executing the above-mentioned knowledge modeling step S3;
[0109] The knowledge evolution module is configured to: input the obtained entity relationship triples into a preset word vector embedding model, embed the extracted knowledge into a low-dimensional vector space, score the confidence of the entity relationship triples according to the constructed loss function, and determine whether it is a correct triple through a preset confidence threshold;
[0110] Input the correct triples into the improved path sorting algorithm to mine new triples as the evolved knowledge graph; this is equivalent to executing the above-mentioned knowledge evolution step S4.
[0111] The preferred specific embodiments of the present invention are described in detail above. It should be understood that a person skilled in the art can make many modifications and changes based on the concept of the present invention without creative work. Therefore, any technical solution that can be obtained by a person skilled in the art through logical analysis, reasoning or limited experiments based on the concept of the present invention on the basis of the prior art should be within the scope of protection determined by the claims.
Claims
1. A method for automatically constructing a knowledge graph for a steel manufacturing enterprise, characterized in that: The following steps are involved: Data collection steps: Collect text data from manufacturing companies; Data processing steps: pre-process the collected text data and construct a single sentence set; Knowledge modeling step: loading a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector; The word sequence vector is subjected to maximum pooling processing, and is concatenated with the [CLS] vector generated by the BERT pre-trained model according to the single sentence to obtain an entity vector representation, and finally a full connection and Softmax processing are performed to obtain an entity recognition result; According to the entity vector representation, a candidate relationship vector is selected and loaded into a pre-established and trained relationship classification module together with the entity vector representation, and full connection and Softmax processing are performed to obtain a relationship classification result; According to the entity recognition results and relationship classification results, entity relationship triples are obtained to complete the construction of the knowledge graph; The method further comprises a knowledge evolution step: inputting the obtained entity relationship triples into a preset word vector embedding model, embedding the extracted knowledge into a low-dimensional vector space, scoring the confidence of the entity relationship triples according to the constructed loss function, and judging whether it is a correct triple by a preset confidence threshold; Input the correct triples into the improved path sorting algorithm to mine new triples as the evolved knowledge graph; The word vector embedding model uses the TransE model to encode entity-relationship triples, encodes entities and relationships into vector spaces of the same dimension, and assumes that: h+rt≈0 In the formula, h is the head entity vector, r is the relationship vector, and t is the tail entity vector; The calculation expression of the loss function is: In the formula, f r (h, t) is the calculation result of the loss function, symbol is the L2 norm; The improved path sorting algorithm uses a double-layer random walk mechanism to evaluate path features, and a heuristic method of vector space similarity is introduced into the double-layer random walk mechanism to obtain relationship path feature patterns.
2. A method for automatically constructing a knowledge graph for a steel manufacturing enterprise according to claim 1, characterized in that: The preprocessing includes judging the completeness of sentences in the text data and removing duplicates and special symbols from each sentence.
3. The method for automatically constructing a knowledge graph for a steel manufacturing enterprise according to claim 1, characterized in that: The bidirectional Transformer structure uses a multi-head attention mechanism for feature aggregation. The calculation expression of the multi-head attention mechanism is: MultiHead(Q,K,V)=Concat(head1,…,head h )W O Where MultiHead(Q,K,V) is the output of the multi-head attention mechanism, Q, K, V are the word vector matrix, sentence vector matrix and position vector matrix respectively, which are output by the BERT pre-trained model, and W o is the additional weight matrix, Indicates different linear transformations to project Q, K, V, d k is the number of columns of the Q, K, V matrices.
4. The method for automatically constructing a knowledge graph for a steel manufacturing enterprise according to claim 3, characterized in that: In the word sequence vector, the vector corresponding to position t is expressed as: Wherein, k is a natural number.
5. The method for automatically constructing a knowledge graph for a steel manufacturing enterprise according to claim 1, characterized in that: The expression of the entity vector representation is: In the formula, e i is the word vector representation after the maximum pooling process, c is the [CLS] vector, and the symbol For concatenation, m is the position mark of the ending character of the candidate entity, and n is the position mark of the beginning character of the candidate entity; The calculation expression of the entity recognition result is: In the formula, is the entity recognition result, softmax is the Softmax processing function, W is the multiplication coefficient, b is the addition coefficient, x e is the entity vector representation.
6. The method for automatically constructing a knowledge graph for a steel manufacturing enterprise according to claim 1, characterized in that: The calculation expression for obtaining the relationship classification result by the relationship classification module is: In the formula, is the relationship classification result, softmax is the Softmax processing function, W s is the relation classification multiplication coefficient, c r is the candidate relation vector, x e1 c r The entity vector before is represented by x e2 c r The entity vector representation after .
7. A knowledge graph automatic construction system using the knowledge graph automatic construction method for a steel manufacturing enterprise as described in any one of claims 1 to 6, characterized in that: include The data collection module is configured to: collect text data of the manufacturing enterprise; The data processing module is configured to: pre-process the collected text data and construct a single sentence set; The knowledge modeling module is configured to: load a single sentence in the single sentence set into a pre-established and trained BERT pre-trained model, the BERT pre-trained model performs word segmentation and vectorization on the single sentence, and then performs feature extraction through a bidirectional Transformer structure to output a word sequence vector; The word sequence vector is subjected to maximum pooling processing, and is concatenated with the [CLS] vector generated by the BERT pre-trained model according to the single sentence to obtain an entity vector representation, and finally a full connection and Softmax processing are performed to obtain an entity recognition result; According to the entity vector representation, a candidate relationship vector is selected and loaded into a pre-established and trained relationship classification module together with the entity vector representation, and full connection and Softmax processing are performed to obtain a relationship classification result; According to the entity recognition results and relationship classification results, entity relationship triples are obtained to complete the construction of the knowledge graph.
