Patent text knowledge graph creation method and device, storage medium and equipment
By extracting entities and relationships from patent texts using the Sentence-BERT-BiGRU-CRF model and language rules, the problems of high training difficulty and low accuracy in existing technologies are solved, and efficient construction and visualization of knowledge graphs in the field of traditional Chinese medicine are achieved.
Patent Information
- Application Number
- CN202211452940.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-21
- Publication Date
- 2026-01-23
- Estimated Expiration
- 2042-11-21
AI Technical Summary
When creating knowledge graphs of patent texts, existing technologies require extraction models to extract both entities and relationships, which is difficult to train and has low accuracy.
An entity extraction model based on Sentence-BERT-BiGRU-CRF is adopted, which combines language rules of overall concept-component concept and object concept-effect concept to extract entities and relationships from patent texts and display the knowledge graph in the Gephi graph database.
It improved the accuracy of entity extraction, expanded the scale of the knowledge graph, and enhanced the accuracy of patent examination and analysis through visualization tools.
Smart Images

Figure CN115757827B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of machine learning, in particular to a patent text knowledge graph creation method and device, a storage medium and equipment. BACKGROUND
[0002] A knowledge graph represents entities and their relationships in the objective world in the form of a graph. The existing traditional Chinese medicine knowledge graph is constructed according to the characteristics of the traditional Chinese medicine field, and includes a knowledge graph of traditional Chinese medicine diseases, prescriptions, traditional Chinese medicines, chemical components of traditional Chinese medicines, pharmacological effects, traditional Chinese medicine experiments, and chemical experiment methods.
[0003] When creating a knowledge graph from patent text, a model is usually trained to extract entities and relationships from the patent text, and then a knowledge graph is created based on the entities and relationships. The entities include patent application numbers, patent titles, inventors, patent drugs, herbal medicines, diseases, dosages, and pharmacological effects. The relationships include patent titles, patent inventors, patent drugs, drug treatment of diseases, drug efficacy, drug components, drug manufacturing steps, herbal medicine dosages, and herbal medicine properties, meridians, etc.
[0004] However, the extraction model not only extracts entities, but also extracts relationships between entities, which makes the training of the extraction model difficult and the accuracy of the model is not high. SUMMARY
[0005] The present application provides a patent text knowledge graph creation method and device, a storage medium and equipment, which solves the problem of high training difficulty and low accuracy when the extraction model extracts entities and relationships. The technical solution is as follows:
[0006] On the one hand, a patent text knowledge graph creation method is provided, which comprises:
[0007] Obtaining fields in multiple patent texts in the field of traditional Chinese medicine, the fields including invention names, abstracts, claims, and descriptions;
[0008] Extracting entities from the fields using a trained entity extraction model, the entity extraction model being created and trained based on Sentence-BERT-BiGRU-CRF;
[0009] Extracting entities and relationships from the fields based on the overall concept-component concept and the object concept-effect concept language rules;
[0010] Creating a knowledge graph based on the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules.
[0011] In a possible implementation, the knowledge graph is created based on the entity extracted by the entity extraction model and the entity and relationship extracted by the language rule, and the method comprises the following steps of:
[0012] The entity extracted by the entity extraction model and the entity and relationship extracted by the language rule are saved in the form of a triple, and the triple comprises a head entity, a head entity label, a relationship, a relationship label, a tail entity and a tail entity label;
[0013] The knowledge graph is created based on the triple.
[0014] In a possible implementation, the method further comprises the following steps of:
[0015] The knowledge graph is stored by using a Gephi graph database;
[0016] The knowledge graph is displayed in the Gephi graph database.
[0017] In a possible implementation, the method further comprises the following steps of:
[0018] A training sample is obtained, text content in a field of the training sample is segmented and part-of-speech tagged, and an entity label is annotated based on a regular expression and the part-of-speech tagging;
[0019] The model is created based on the Sentence-BERT-BiGRU-CRF.
[0020] The model is trained by using the training sample, and the entity extraction model is obtained.
[0021] In a possible implementation, the entity is extracted from the field by using the trained entity extraction model, and the method comprises the following steps of:
[0022] The entity is extracted from the field without an annotated entity label by using the entity extraction model.
[0023] In a possible implementation, the entity and relationship are extracted from the field based on the language rule of the overall concept-component concept and the object concept-effect concept, and the method comprises the following steps of:
[0024] A predefined constant term is obtained, and the constant term is a word or symbol extracted based on a fixed sentence pattern;
[0025] The first language rule is created according to the fixed sentence pattern, the overall concept, the component concept and the constant term, and the entity and relationship are extracted from the field based on the first language rule;
[0026] The second language rule is created according to a fixed pattern for an object concept, an effect concept and a constant term, and entities and relations are extracted from the fields based on the second language rule.
[0027] In a possible implementation, the first language rule comprises: whole concept-constant term-component concept, component concept-constant term-whole concept.
[0028] The second language rule comprises: object concept-constant term-effect concept.
[0029] In an aspect, a device for creating a knowledge graph of patent text is provided, and the device comprises:
[0030] An acquisition module is configured to acquire fields in a plurality of patent texts in the field of traditional Chinese medicine, the fields comprising an invention name, an abstract, a claim and a specification.
[0031] An extraction module is configured to extract entities from the fields by using a trained entity extraction model, the entity extraction model being created and trained based on Sentence-BERT-BiGRU-CRF.
[0032] The extraction module is further configured to extract entities and relations from the fields based on language rules of whole concept-component concept and object concept-effect concept.
[0033] A creation module is configured to create a knowledge graph based on the entities extracted by the entity extraction model and the entities and relations extracted by the language rules.
[0034] In an aspect, a computer-readable storage medium is provided, and the storage medium stores at least one instruction, which is loaded and executed by a processor to implement the method for creating a knowledge graph of patent text.
[0035] In an aspect, a computer device is provided, and the computer device comprises a processor and a memory, and the memory stores at least one instruction, which is loaded and executed by the processor to implement the method for creating a knowledge graph of patent text.
[0036] The technical scheme provided in the application has at least the following beneficial effects:
[0037] The entity extraction model is created and trained based on Sentence-BERT-BiGRU-CRF. Sentence-BERT can learn the expected semantic features under the premise of removing the word limit, and the time complexity grows linearly. BiGRU can learn the long context relationship between words and can speed up the reasoning of the NER (Named Entity Recognition) model. CRF can correct the sequence errors predicted by BiGRU, thereby improving the accuracy of the entity extraction model in identifying entities.
[0038] The fields in the patent text usually contain many fixed sentence patterns. Based on the fields, language rules based on overall concept-component concept and object concept-effect concept can be extracted. Based on the language rules, entities and relationships can be extracted from the fields, which can effectively improve the coverage of knowledge acquisition and expand the size of the knowledge graph in the field of traditional Chinese medicine.
[0039] By displaying the knowledge graph in the Gephi graph database, the accuracy of patent review and analysis can be improved through the visual knowledge graph, and the best way for professionals and non-professionals to learn knowledge in the field of traditional Chinese medicine can be provided. BRIEF DESCRIPTION OF DRAWINGS
[0040] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0041] Figure 1 is a method flowchart of a patent text knowledge graph creation method provided by an embodiment of the present application;
[0042] Figure 2 is a visual graph of a knowledge graph provided by an embodiment of the present application;
[0043] Figure 3 is a structural block diagram of a patent text knowledge graph creation device provided by another embodiment of the present application;
[0044] Figure 4 is a structural block diagram of a patent text knowledge graph creation device provided by another embodiment of the present application. DETAILED DESCRIPTION
[0045] In order to make the purpose, technical solutions and advantages of the embodiments of the present application more clear, the embodiments of the present application will be further described in detail with reference to the drawings.
[0046] The purpose of the present application is to create a knowledge graph of patent texts in the field of traditional Chinese medicine. The knowledge graph includes patent application numbers, invention names, inventors, invention drugs, herbs, diseases, dosages, pharmacological effects, and other entities, as well as patent titles, patent inventors, patent invention drugs, drug treatment diseases, drug efficacy, drug ingredients, drug manufacturing steps, herb dosages, herb properties, and other relationships. In the present application, the core knowledge of patent texts in the field of traditional Chinese medicine is structured and formalized, and the extracted knowledge information is connected to form a knowledge graph. The knowledge graph contains rich semantic relationships, enabling knowledge reasoning, auxiliary analysis, and decision support functions. It helps enterprises or users quickly and conveniently query related knowledge and their relationships in the field of traditional Chinese medicine patents, and further utilize these data for subsequent work. The key to building a knowledge graph in the field of traditional Chinese medicine is knowledge extraction. In the present application, existing patent texts in the field of traditional Chinese medicine in China are collected and organized, and various data cleaning is performed. Then, deep learning methods and language rule-based methods are used for knowledge extraction. The extracted entities and relationships are structured into a knowledge graph in the form of triples, and the knowledge graph is imported into a graph database to realize the structuring and visualization of patent knowledge in the field of traditional Chinese medicine.
[0047] Please refer to Figure 1 which shows a method flowchart of a patent text knowledge graph creation method provided by an embodiment of the present application. The patent text knowledge graph creation method can be applied in a computer device. The patent text knowledge graph creation method can include:
[0048] Step 101: obtaining fields in multiple patent texts in the field of traditional Chinese medicine, the fields including invention names, abstracts, claims, and descriptions.
[0049] Patent texts include invention names, abstracts, claims, descriptions, and other parts, wherein the invention names, abstracts, claims, and descriptions contain entities and relationships required for constructing a knowledge graph of traditional Chinese medicine patents, such as invention drugs, preparation methods, and various herb dosages.
[0050] It should be noted that since the text content in the description is relatively large, it takes a long time to extract entities and relationships from it. Therefore, in one instance, the computer device can extract entities and relationships from invention names, abstracts, and claims.
[0051] Step 102: extracting entities from the fields using a trained entity extraction model, which is created and trained based on Sentence-BERT-BiGRU-CRF.
[0052] In this embodiment, the computer device first creates an entity extraction model based on a deep learning method, and then extracts multiple entities from the fields using the entity extraction model.
[0053] When creating the entity extraction model, the computer device first acquires training samples, performs word segmentation and part-of-speech tagging on the text content in the fields of the training samples, and annotates entity labels based on regular expressions and part-of-speech tagging; then creates a model based on Sentence-BERT-BiGRU-CRF; and finally trains the model using the training samples to obtain the entity extraction model.
[0054] Specifically, the entity labels are first annotated, and a set of model parameters is then defined, so as to obtain a model corresponding to the set of model parameters and indicators such as precision and recall rate of the model. Different models can be obtained by changing the combination of model parameters, and the computer device can select the combination of model parameters with the highest precision, recall rate, or F value according to needs, so as to obtain the optimal model. In this embodiment, the finally selected model is referred to as the entity extraction model.
[0055] Sentence-BERT+BiGRU+CRF is an end-to-end deep learning model. The advantage of using BERT is that it can learn the semantic features of the corpus. However, the construction of BERT has a word limit. The advantage of using Sentence-BERT is that it can solve the word limit and the time complexity grows linearly. BiGRU can learn the long context relationship between words, and using the GRU model can speed up the inference of the NER model compared with the LSTM model. CRF can correct the sequence errors predicted by BiGRU, thereby improving the accuracy of the entity extraction model in identifying entities.
[0056] When extracting entities from the fields using the entity extraction model, the computer device extracts entities from the fields without annotated entity labels using the entity extraction model. The computer device can use the jieba word segmentation toolkit for text content segmentation and part-of-speech tagging.
[0057] In step 103, entities and relationships are extracted from the fields based on the language rules of the overall concept-component concept and the object concept-effect concept.
[0058] Through extensive reading of patent files, we found that the structure of the invention name, abstract, and claims in the patent text is relatively standard and general, and the content theme is relatively fixed (i.e., technical theme, technical solution, and technical effect). Also, many fixed sentence patterns are used, which can be summarized into some language rules based on which entities and relationships are extracted.
[0059] Specifically, based on language rules that combine the overall concept with the component concept and the object concept with the effect concept, extracting entities and relationships from fields can include the following sub-steps:
[0060] (1) Obtain predefined constant items, which are words or symbols extracted based on fixed sentence patterns.
[0061] Many constants are the same across different language rules. To facilitate enumerating language rules, the following constants are defined in this embodiment:
[0062] Defconstant constant term
[0063] {
[0064] Punctuation marks: ,|。 |.|? |! |:|:|,|.|? |;|;
[0065] Number: <0|1|2|3|4|5|6|7|8|9>*<.|NULL><0|1|2|3|4|5|6|7|8|9>*
[0066] Measure words: portion | flavor | gram | tael | coin | pound
[0067] "is" is a verb meaning "to be / are / to become / to serve as".
[0068] Verbs with: to have, to possess, to contain, to exist
[0069] Active verbs: able to | capable of | can
[0070] Realization words: achieve | reach | obtain
[0071] Solution keywords: solution | treatment | radical cure | prevention | avoidance | main treatment
[0072] Effect words: effect | therapeutic effect | efficacy | result
[0073] Object words: will | by | with
[0074] Subordinate word: belongs to | subordinate to
[0075] Publicly disclosed terms: disclosed | involved | provided
[0076] Raw material terms: raw materials | materials | ingredients
[0077] Containing words: contain, include, imply, include
[0078] Compositional words: configuration | structure | composition | component | part | assembly | accessory | component | device | equipment | element | attachment | component Step-by-step words: activity | cycle | process | step | link | stage | operation | degree | unit | action | aspect | method | process Consequence words: lead to | cause | in order to | for the purpose of
[0079] Cause words: because | due to
[0080] Existential words: at | located
[0081] Location words: above | below | left | right | inside | outside
[0082] The following words: as follows | below | below | the following
[0083] Coordinate words: and | with | together with | and
[0084] Related words: related | connected | related | associated
[0085] }
[0086] This embodiment only uses the above-mentioned constant items as examples. In practical applications, more or fewer constant items can be set according to needs.
[0087] (2) Create first language rules for overall concepts, component concepts and constant items based on fixed sentence patterns, and extract entities and relations from fields based on the first language rules.
[0088] In this embodiment, the first language rules include: overall concept - constant term - component concept, and component concept - constant term - overall concept. Examples of combinations between overall concept, component concept, and different constant terms are given below.
[0089]
[0090]
[0091] In first language rules, the parts marked with "?" are technical feature words that need to be extracted, such as "?" for overall concept and "?" for component concept; the parts marked with "!" represent constant words of different categories, such as "<!" for solution word>, which means that any one of the words "solve, treat, cure, prevent, avoid, treat" needs to be matched at this position.
[0092] This embodiment only uses the above-mentioned overall concept, component concept and different constant terms combination as an example. In practical applications, other combinations can be set according to requirements.
[0093] (3) Create second language rules for object concepts, effect concepts and constant items based on fixed sentence patterns, and extract entities and relations from fields based on the second language rules.
[0094] In this embodiment, the second language rules include: object concept - constant term - effect concept. Examples of combinations between object concept, effect concept, and different constant terms are given below.
[0095]
[0096] In the second language rule, the part with the "?" symbol is the technical feature word that needs to be extracted, such as
? object concept
? effect concept
[0097] In this embodiment, only the combination of the above object concept, effect concept, and different constant items is used as an example. In actual application, other combinations can be set according to requirements.
[0098] Taking the application of the first language rule to extract entities and relationships from the abstract and the claims as an example, it is assumed that the extracted result is that
rose eight treasure tea
rose flower
huangshan tribute chrysanthemum
huangshan green tea
[0099] Taking the application of the second language rule to extract entities and relationships from the invention name and the abstract as an example, it is assumed that the extracted result is that the drug has the effect of
enhancing human immunity
[0100] Of course, the user can also customize some language rules to identify entities and relationships based on these language rules.
[0101] In this embodiment, entities and relationships can be extracted based on language rules, and then professional personnel can be organized for processing and auditing to ensure the accuracy of entity and relationship extraction.
[0102] Step 104, creating a knowledge graph based on the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules.
[0103] Specifically, creating a knowledge graph based on the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules can include: saving the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules in the form of triplets, the triplets including head entity, head entity label, relationship, relationship label, tail entity, and tail entity label; creating a knowledge graph based on the triplets.
[0104] In this embodiment, the entities and relationships extracted from the patent text are saved in the form of triplets, each triplet including: head entity, head entity label, relationship, relationship label, tail entity, and tail entity label. The triplets are illustrated as follows:
[0105]
[0106] After obtaining the knowledge graph, the computer device can also store the knowledge graph by using a Gephi graph database; and display the knowledge graph in the Gephi graph database.
[0107] Gephi is a data visualization processing software in the field of network analysis, and the developer hopes that it will become "Photoshop in the field of data visualization". Gephi has the following three major features:
[0108] (1) supported by a built-in fast OpenGL engine, Gephi can push envelopes with very large networks, and visualize networks with up to one million elements, all of which can be run in real time, such as layout, filters;
[0109] (2) simple to install and use, UI (User Interface) centered on visualization, similar to Photoshop graphics processing;
[0110] (3) support for modular extension Gephi and plug-in development, the architecture is built on the Netbeans platform, and can be easily extended or reused through carefully written API (Application Program Interface).
[0111] By displaying the knowledge graph in the Gephi graph database, the relationship between various entities can be clearly shown (as shown in Figure 2 ), which can further improve the accuracy of patent review and analysis, and provide the best way for professionals and non-professionals to learn knowledge in the field of patents.
[0112] In summary, the knowledge graph creation method for patent text provided by the embodiments of the present application, the entity extraction model is created and trained based on Sentence-BERT-BiGRU-CRF, Sentence-BERT can learn the expected semantic features under the premise of removing the word limit, and the time complexity grows linearly; BiGRU can learn the long context relationship between words, and can speed up the reasoning of the NER model; CRF can correct the sequence errors predicted by BiGRU, thereby improving the accuracy of the entity extraction model in identifying entities.
[0113] The fields in the patent text usually contain many fixed sentence patterns, and based on the fields, language rules based on overall concept-component concept and object concept-effect concept can be extracted, and entities and relationships can be extracted from the fields based on the language rules, which can effectively improve the coverage of knowledge acquisition and expand the size of the knowledge graph in the field of traditional Chinese medicine.
[0114] By displaying the knowledge graph in the Gephi graph database, the accuracy of patent review and analysis can be promoted through the visual knowledge graph, and the best way for professionals and non-professionals to learn knowledge in the field of traditional Chinese medicine can be provided.
[0115] Please refer to Figure 3 , which shows a structural block diagram of a patent text knowledge graph creation device provided by an embodiment of the present application. The patent text knowledge graph creation device can be applied to a computer device. The patent text knowledge graph creation device can include:
[0116] The acquisition module 310 is configured to acquire fields in multiple patent texts in the field of traditional Chinese medicine, the fields including invention names, abstracts, claims, and specifications;
[0117] The extraction module 320 is configured to extract entities from the fields by using a trained entity extraction model, the entity extraction model being created and trained based on Sentence-BERT-BiGRU-CRF;
[0118] The extraction module 320 is further configured to extract entities and relationships from the fields based on language rules of overall concept-component concept and object concept-effect concept.
[0119] The creation module 330 is configured to create a knowledge graph based on the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules.
[0120] In an optional embodiment, the creation module 330 is further configured to:
[0121] Save the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules in the form of triples, the triples including a head entity, a head entity label, a relationship, a relationship label, a tail entity, and a tail entity label;
[0122] Create the knowledge graph based on the triples.
[0123] Please refer to Figure 4 In an optional embodiment, the device further includes:
[0124] The storage module 340 is configured to store the knowledge graph by using a Gephi graph database;
[0125] The display module 350 is configured to display the knowledge graph in the Gephi graph database.
[0126] In an optional embodiment, the acquisition module 310 is further configured to acquire training samples, perform word segmentation and part-of-speech tagging on text content in the fields of the training samples, and tag entity labels based on regular expressions and part-of-speech tagging.
[0127] The creating module 330 is further configured to create the model based on Sentence-BERT-BiGRU-CRF.
[0128] The device further comprises a training module 360 configured to train the model by using the training samples to obtain the entity extraction model.
[0129] In an optional embodiment, the extracting module 320 is further configured to:
[0130] extract the entity from the field without the labeled entity by using the entity extraction model.
[0131] In an optional embodiment, the extracting module 320 is further configured to:
[0132] obtain a predefined constant term, the constant term being a word or symbol extracted based on a fixed pattern;
[0133] create a first language rule based on the fixed pattern for the overall concept, the component concept and the constant term, and extract the entity and the relationship from the field based on the first language rule;
[0134] create a second language rule based on the fixed pattern for the object concept, the effect concept and the constant term, and extract the entity and the relationship from the field based on the second language rule.
[0135] In an optional embodiment, the first language rule comprises: overall concept-constant term-component concept, component concept-constant term-overall concept.
[0136] The second language rule comprises: object concept-constant term-effect concept.
[0137] In summary, the knowledge graph creation device for patent text provided by the embodiments of the present application, the entity extraction model is created and trained based on Sentence-BERT-BiGRU-CRF, Sentence-BERT can learn the expected semantic features under the premise of removing the word limit, and the time complexity grows linearly; BiGRU can learn the long context relationship between words, and can speed up the reasoning of the NER model; CRF can correct the sequence error predicted by BiGRU, thereby improving the accuracy of the entity extraction model in identifying entities.
[0138] The field in the patent text usually contains many fixed patterns, and based on the field, language rules based on overall concept-component concept and object concept-effect concept can be extracted, and entities and relationships can be extracted from the field based on the language rules, which can effectively improve the coverage of knowledge acquisition and expand the size of the knowledge graph in the field of traditional Chinese medicine.
[0139] By displaying the knowledge graph in the Gephi graph database, the accuracy of patent examination and analysis can be promoted through the visual knowledge graph, and the best way for professionals and non-professionals to learn knowledge in the field of traditional Chinese medicine can be provided.
[0140] An embodiment of the present application provides a computer readable storage medium, wherein at least one instruction is stored in the storage medium, and the at least one instruction is loaded and executed by a processor to implement the knowledge graph creation method of the patent text.
[0141] An embodiment of the present application provides a computer device, comprising a processor and a memory, wherein at least one instruction is stored in the memory, and the instruction is loaded and executed by the processor to implement the knowledge graph creation method of the patent text.
[0142] It should be noted that: the patent text knowledge graph creation device provided in the above embodiments is used to create the knowledge graph of the patent text, and the above-mentioned division of each functional module is only used as an example for illustration, and in actual application, the above-mentioned functions can be distributed to different functional modules to complete, that is, the internal structure of the patent text knowledge graph creation device is divided into different functional modules to complete all or part of the functions described above. In addition, the patent text knowledge graph creation device and the patent text knowledge graph creation method provided in the above embodiments belong to the same concept, and the specific implementation process is described in the method embodiments, which will not be repeated here.
[0143] Those skilled in the art can understand that all or part of the steps of the above-mentioned embodiments can be completed by hardware, or by a program instructing related hardware, and the program can be stored in a computer readable storage medium, and the storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk.
[0144] The above description does not limit the embodiments of the present application, and any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the embodiments of the present application shall be included in the protection scope of the embodiments of the present application.
Claims
1. A method for creating a knowledge graph of patent texts, characterized in that, The method includes: Obtain fields from multiple patent texts in the field of traditional Chinese medicine, including invention title, abstract, claims, and specification. Entities are extracted from the field using a trained entity extraction model, which is created and trained based on Sentence-BERT-BiGRU-CRF; Based on the language rules of the overall concept-component concept and the object concept-effect concept, entities and relations are extracted from the fields; A knowledge graph is created based on the entities extracted by the entity extraction model and the entities and relationships extracted based on the language rules.
2. The method for creating a knowledge graph of patent texts according to claim 1, characterized in that, The creation of a knowledge graph based on the entities extracted by the entity extraction model and the entities and relations extracted by the language rules includes: The entities extracted by the entity extraction model, as well as the entities and relations extracted based on the language rules, are stored in the form of triples. Each triple includes a head entity, a head entity label, a relation, a relation label, a tail entity, and a tail entity label. The knowledge graph is created based on the triples.
3. The method for creating a knowledge graph of patent texts according to claim 1, characterized in that, The method further includes: The knowledge graph is stored using the Gephi graph database; The knowledge graph is displayed in the Gephi graph database.
4. The method for creating a knowledge graph of patent texts according to claim 1, characterized in that, The method further includes: Obtain training samples, perform word segmentation and part-of-speech tagging on the text content in the fields of the training samples, and label the word segments with entity tags based on regular expressions and the part-of-speech tags; A model is created based on the Sentence-BERT-BiGRU-CRF; The model is trained using the training samples to obtain the entity extraction model.
5. The method for creating a knowledge graph of patent texts according to claim 4, characterized in that, The step of extracting entities from the field using a trained entity extraction model includes: The entity extraction model is used to extract entities from the fields that are not labeled with entity tags.
6. The method for creating a knowledge graph of patent texts according to any one of claims 1 to 5, characterized in that, The language rules based on the overall concept-component concept and the object concept-effect concept extract entities and relations from the fields, including: Obtain predefined constant items, which are words or symbols extracted based on fixed sentence patterns; First language rules are created for overall concepts, component concepts, and constant items based on fixed sentence patterns. Entities and relations are then extracted from the fields based on these first language rules. Second language rules are created for object concepts, effect concepts, and constant items based on fixed sentence patterns, and entities and relations are extracted from the fields based on the second language rules.
7. The method for creating a knowledge graph of patent texts according to claim 6, characterized in that, The first language rule includes: whole concept - constant term - component concept, component concept - constant term - whole concept; The second language rule includes: object concept - constant term - effect concept.
8. A knowledge graph creation device for patent texts, characterized in that, The device includes: The acquisition module is used to acquire fields from multiple patent texts in the field of traditional Chinese medicine, including invention title, abstract, claims and description. The extraction module is used to extract entities from the field using a trained entity extraction model, which is created and trained based on Sentence-BERT-BiGRU-CRF. The extraction module is also used to extract entities and relationships from the fields based on language rules of the overall concept-component concept and the object concept-effect concept; A creation module is used to create a knowledge graph based on the entities extracted by the entity extraction model and the entities and relationships extracted by the language rules.
9. A computer-readable storage medium, characterized in that, The storage medium stores at least one instruction, which is loaded and executed by a processor to implement the knowledge graph creation method for patent texts as described in any one of claims 1 to 7.
10. A computer device, characterized in that, The computer device includes a processor and a memory, the memory storing at least one instruction, which is loaded and executed by the processor to implement the knowledge graph creation method for patent texts as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Knowledge graph construction method based on Chinese electronic medical records
CN113688255A
Document mining with relation extraction
US20140082003A1