Method, device and equipment for updating medical biological term library and readable storage medium
By combining entity and entity relationship extraction models with a pre-set medical and biological terminology database to process local medical and biological texts, the database is integrated and updated. This solves the problems of completeness and accuracy of medical terminology databases in existing technologies, achieves effective construction and redundancy removal of entity relationships, and improves the quality of the medical and biological terminology database.
Patent Information
- Application Number
- CN202210434102.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-24
- Publication Date
- 2026-02-17
- Estimated Expiration
- 2042-04-24
AI Technical Summary
Existing methods for constructing medical and biological terminology databases suffer from insufficient completeness and accuracy of medical terms, failure to effectively construct relationships between entities, and a tendency to lead to identification errors and redundant entities entering the knowledge base.
By utilizing an entity and entity relation extraction model and a pre-set medical and biological terminology database, entities and entity relations are extracted from local medical and biological texts. Candidate entity sets are integrated and mapped to the pre-set medical and biological terminology database. The database is then updated in conjunction with the entity relation set to optimize the entity and relation network of the medical and biological terminology database.
It improved the completeness and accuracy of medical terminology, avoided misidentification due to insufficient model performance, eliminated redundant entities, enriched the relational network of the medical and biological terminology database, and continuously optimized the quality of the medical and biological terminology database.
Smart Images

Figure CN114741514B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of natural language processing technology, and in particular to a method, apparatus, device, and computer-readable storage medium for updating a medical and biological terminology database. Background Technology
[0002] In today's highly information-driven world, computers are widely used in all aspects of production and daily life. The application of computers in the medical field not only greatly improves the efficiency of medical treatment but also effectively preserves and manages medical information (such as electronic medical records), thereby continuously enriching medical resources and increasing the scale of medical data. To make good use of the accumulated valuable medical data, researchers often first structure the large-scale data and then preserve the structured data by constructing knowledge graphs. They then further realize intelligent medical treatment based on these knowledge graphs. Medical and biological terminology, as an entity within the medical and biological knowledge graph, is an indispensable part of its construction process. Therefore, constructing a medical and biological terminology database is of great significance.
[0003] Existing methods for constructing medical and biological terminology databases mainly include the following: The first method utilizes terminology mapping and translation technologies to construct a localized medical terminology database based on "medical terms, medical terminology concepts, concept descriptions, and terminology relationships." The second method uses a pre-trained CRF model and a medical ontology terminology database to obtain a set of candidate terminology entities, then uses pre-defined syntactic analysis to filter out the final terminology sequence and store it. The third method uses "medical lexicon matching + manual proofreading" to annotate entity information in medical texts, obtaining an annotated corpus; based on the obtained corpus, this patent trains an entity recognition model, and uses the trained model to extract entities from medical texts; it utilizes existing knowledge systems to extract relationships between entities; and combines the extracted entities and entity relationships to construct a disease-specific knowledge graph.
[0004] However, all of the above methods for constructing medical and biological terminology databases have certain drawbacks. First, the first approach, which selects candidate terms based on the frequency of words or phrases in the text, is prone to accidentally deleting low-frequency useful terms and retaining high-frequency useless terms. Moreover, common word segmentation tools often split a medical term into multiple words, which is detrimental to the completeness and accuracy of the medical terminology. Second, the second approach only stores terminology entities without constructing relationships between entities. Third, the third approach is highly dependent on model performance; when the model performance is insufficient, it is easy to identify incorrect or redundant entities (after removing stop words, they are almost identical to existing terms in the knowledge base) entering the knowledge base. Furthermore, the method of simply adding relationships to candidate entities based on the knowledge base cannot appropriately expand the relationship tags of entities.
[0005] In summary, how to effectively address the problems of existing medical and biological terminology database construction methods that are not conducive to the completeness and accuracy of medical terms, fail to construct relationships between entities, and are prone to identification errors or redundant entities entering the knowledge base, is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0006] The purpose of this invention is to provide a method for updating a medical and biological terminology database. This method avoids erroneous identification caused by insufficient model performance and can remove redundant entities, enriching the relational network of the entire medical and biological terminology database and improving the completeness and accuracy of medical terms. Another purpose of this invention is to provide an apparatus, device, and computer-readable storage medium for updating a medical and biological terminology database.
[0007] To solve the above-mentioned technical problems, the present invention provides the following technical solution:
[0008] A method for updating a medical and biological terminology database, comprising:
[0009] Retrieve local medical and biological text;
[0010] The entity and entity relation extraction model is used to extract entities and entity relations from the local medical and biological text to obtain a first candidate entity set and a first entity relation set.
[0011] The local medical and biological text is used to extract entities and entity relationships using a preset medical and biological terminology database to obtain a second candidate entity set and a second entity relationship set.
[0012] The first candidate entity set is integrated based on the second candidate entity set to obtain the target candidate entity set.
[0013] The target candidate entity set is mapped to the preset medical and biological terminology database to obtain the target entity set;
[0014] The target entity relationship set corresponding to the target entity set is determined based on the first entity relationship set and the second entity relationship set;
[0015] The preset medical and biological terminology database is updated using the target entity set and the target entity relationship set.
[0016] In one specific embodiment of the present invention, after updating the preset medical and biological terminology database using the target entity set and the target entity relationship set, the method further includes:
[0017] The entity and entity relationship extraction model are updated using the updated medical and biological terminology database.
[0018] In one specific embodiment of the present invention, the integration operation of the first candidate entity set according to the second candidate entity set includes:
[0019] Obtain the first start and end positions corresponding to each of the first candidate entities in the first candidate entity set;
[0020] Obtain the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set;
[0021] Determine whether there exists a first beginning and end position contained within the second beginning and end position;
[0022] If so, the first candidate entity corresponding to the first start and end position contained in the second start and end position is determined as the first entity to be replaced, and the second candidate entity corresponding to the second start and end position contained in the first start and end position is determined as the first replacement entity;
[0023] The first replacement entity is used to replace the first entity to be replaced.
[0024] In one specific embodiment of the present invention, after obtaining the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set, the method further includes:
[0025] Determine whether there exists a second beginning and end position that is contained within the first beginning and end position;
[0026] If so, the second candidate entity corresponding to the second start and end position contained in the first start and end position is determined as the second replacement entity, and the first candidate entity corresponding to the first start and end position contained in the second start and end position is determined as the second entity to be replaced.
[0027] The second replacement entity is subjected to a stop word removal operation to obtain a first sequence, and the second entity to be replaced is subjected to a stop word removal operation to obtain a second sequence;
[0028] Calculate the first similarity between the first sequence and the second sequence;
[0029] Determine whether the first similarity reaches a first preset threshold;
[0030] If so, the second replacement entity is used to replace the second entity to be replaced.
[0031] In one specific embodiment of the present invention, after obtaining the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set, the method further includes:
[0032] Determine whether there is partial overlap between the first and second start-end positions;
[0033] If so, the first candidate entity corresponding to the first partially overlapping start and end positions is determined as the third entity to be replaced, and the second candidate entity corresponding to the second partially overlapping start and end positions is determined as the third replacement entity.
[0034] The third entity to be replaced is subjected to a stop word removal operation to obtain a third sequence, and the third entity to be replaced is subjected to a stop word removal operation to obtain a fourth sequence;
[0035] Calculate the second similarity between the third sequence and the fourth sequence;
[0036] Determine whether the second similarity reaches the second preset threshold;
[0037] If so, the third replacement entity is used to replace the third entity to be replaced.
[0038] In one specific embodiment of the present invention, mapping the target candidate entity set to the preset medical and biological terminology database includes:
[0039] The entity and entity relationship extraction model is used to calculate the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set.
[0040] The second representation vector with the highest similarity and the maximum similarity value corresponding to each of the first representation vectors are determined using a similarity calculation algorithm.
[0041] Based on the maximum similarity value corresponding to each of the first representation vectors, the target candidate entity set is mapped to the preset medical and biological terminology database.
[0042] In one specific embodiment of the present invention, determining the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set includes:
[0043] Obtain the set of entity pairs and relation triples that have corresponding relationships in the first entity relation set and the second entity relation set;
[0044] Calculate the similarity between corresponding entities in a set of entity pairs and relation triples that have a corresponding relationship;
[0045] The target entity relationship set corresponding to the target entity set is determined based on the similarity.
[0046] An update device for a pharmaceutical and biological terminology database includes:
[0047] The text acquisition module is used to acquire local medical and biological text.
[0048] The first entity and relation extraction module is used to extract entities and entity relations from the local medical and biological text using an entity and entity relation extraction model, so as to obtain a first candidate entity set and a first entity relation set.
[0049] The second entity and relation extraction module is used to extract entities and entity relations from the local medical and biological text using a preset medical and biological terminology library, so as to obtain a second candidate entity set and a second entity relation set.
[0050] The set integration module is used to integrate the first candidate entity set according to the second candidate entity set to obtain the target candidate entity set;
[0051] The set mapping module is used to map the target candidate entity set to the preset medical and biological terminology database to obtain the target entity set;
[0052] The set determination module is used to determine the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set;
[0053] The terminology database update module is used to update the preset medical and biological terminology database using the target entity set and the target entity relationship set.
[0054] An update device for a pharmaceutical and biological terminology database includes:
[0055] Memory, used to store computer programs;
[0056] A processor, used to implement the steps of the method for updating the medical and biological terminology database as described above when executing the computer program.
[0057] A computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the aforementioned method for updating a medical and biological terminology database.
[0058] The method for updating a pharmaceutical and biological terminology database provided by this invention involves: acquiring local pharmaceutical and biological text; extracting entities and entity relationships from the local pharmaceutical and biological text using an entity and entity relationship extraction model to obtain a first candidate entity set and a first entity relationship set; extracting entities and entity relationships from the local pharmaceutical and biological text using a preset pharmaceutical and biological terminology database to obtain a second candidate entity set and a second entity relationship set; integrating the first candidate entity set with the second candidate entity set to obtain a target candidate entity set; mapping the target candidate entity set to the preset pharmaceutical and biological terminology database to obtain a target entity set; determining the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set; and updating the preset pharmaceutical and biological terminology database using the target entity set and the target entity relationship set.
[0059] As described in the above technical solution, after extracting entities and entity relationships from local medical and biological text using both the entity and entity relationship extraction model and a preset medical and biological terminology database, the first candidate entity set extracted by the entity and entity relationship extraction model is integrated using the second candidate entity set extracted from the preset medical and biological terminology database. The integrated target candidate entity set is then mapped to the preset medical and biological terminology database to obtain the target candidate entity set. The target entity relationship set corresponding to the target entity set is determined based on the first entity relationship set extracted by the entity and entity relationship extraction model and the second entity relationship set extracted from the preset medical and biological terminology database. The preset medical and biological terminology database is then updated using the target entity set and the target entity relationship set. By integrating entities extracted from the terminology database with entities extracted by the model, erroneous identification due to insufficient model performance is avoided, and redundant entities are removed. Compared to methods that use the terminology database as the sole source of entity relationships, this approach appropriately expands the relationships between terminology entity pairs, thereby enriching the relationship network of the entire medical and biological terminology database. Continuous iteration and updates to the medical and biological terminology database can help optimize its quality and improve the completeness and accuracy of medical terminology.
[0060] Accordingly, the present invention also provides an apparatus, device, and computer-readable storage medium for updating a medical and biological terminology database, which corresponds to the above-mentioned method for updating the medical and biological terminology database and has the above-mentioned technical effects, which will not be elaborated here. Attached Figure Description
[0061] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0062] Figure 1 This is a flowchart illustrating one implementation of the method for updating the medical and biological terminology database in this invention.
[0063] Figure 2 This is a flowchart illustrating another implementation of the method for updating the medical and biological terminology database in this invention.
[0064] Figure 3 This is a structural block diagram of a device for updating a medical and biological terminology database according to an embodiment of the present invention;
[0065] Figure 4 This is a structural block diagram of a medical and biological terminology database update device according to an embodiment of the present invention;
[0066] Figure 5 This is a schematic diagram of the specific structure of a device for updating a medical and biological terminology database provided in this embodiment. Detailed Implementation
[0067] To enable those skilled in the art to better understand the present invention, the invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. Obviously, the described embodiments are merely some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0068] See Figure 1 , Figure 1 This is a flowchart illustrating an implementation method for updating a medical and biological terminology database according to an embodiment of the present invention. The method may include the following steps:
[0069] S101: Obtain local medical and biological text.
[0070] When local medical and biological text is generated, retrieve the local medical and biological text. Local medical and biological text can include electronic medical records, medical and biological literature, guidelines, textbooks, drug instructions, and website information, etc.
[0071] S102: Use the entity and entity relation extraction model to extract entities and entity relations from local medical and biological texts to obtain the first candidate entity set and the first entity relation set.
[0072] A pre-trained entity and entity relation extraction model is developed for extracting entities and entity relations from medical and biological texts. This can be achieved by pre-setting the semantic types of the concepts to which the entities to be extracted belong, filtering medical and biological terms in the UMLS (The Unified Medical Language System) based on these semantic types, and obtaining a pre-defined medical and biological terminology database. The pre-defined terminology database is then used to extract entities and entity relations from pre-obtained local medical and biological text data, forming an annotated corpus. This annotated corpus is then used to train the entity and entity relation extraction model.
[0073] After obtaining the local medical and biological text, the entity and entity relation extraction model is used to extract the entities and entity relations from the local medical and biological text, resulting in the first candidate entity set and the first entity relation set.
[0074] S103: Use a pre-set medical and biological terminology database to extract entities and entity relationships from local medical and biological texts to obtain a second candidate entity set and a second entity relationship set.
[0075] After obtaining the local medical and biological text, the system uses a pre-defined medical and biological terminology database to extract entities and entity relationships from the local medical and biological text, resulting in a second candidate entity set and a second entity relationship set.
[0076] It should be noted that the first and second in the first candidate entity set, second candidate entity set, first entity relation set, and second entity relation set are not distinguished by size or order. They are only used to differentiate the candidate entity and entity relation sets extracted using the entity and entity relation extraction model and the preset medical and biological terminology database.
[0077] S104: Perform an integration operation on the first candidate entity set based on the second candidate entity set to obtain the target candidate entity set.
[0078] When using the same local medical and biological text, the entity and entity relation extraction model may yield a certain degree of difference between the candidate entity set obtained and that extracted using a pre-defined medical and biological terminology database. After extracting a first candidate entity set and a first entity relation set using the entity and entity relation extraction model, and then extracting a second candidate entity set and a second entity relation set using the pre-defined medical and biological terminology database, the first candidate entity set is integrated based on the second candidate entity set to obtain the target candidate entity set. This optimizes the first candidate entity set and the first entity relation set extracted by the entity and entity relation extraction model.
[0079] S105: Map the target candidate entity set to the preset medical and biological terminology database to obtain the target entity set.
[0080] After integrating the first candidate entity set with the second candidate entity set to obtain the target candidate entity set, the target candidate entity set is mapped to the preset medical and biological terminology database to obtain the target entity set, thereby optimizing the second candidate entity set and the second entity relationship set extracted from the preset medical and biological terminology database.
[0081] S106: Determine the target entity relation set corresponding to the target entity set based on the first entity relation set and the second entity relation set.
[0082] For the same local medical and biological text, there may be some differences between the entity and entity relation extraction model and the entity relation set extracted using a preset medical and biological terminology database. After extracting a first entity relation set using the entity and entity relation extraction model and a second entity relation set using the preset medical and biological terminology database, the target entity relation set corresponding to the target entity set is determined based on the first entity relation set and the second entity relation set.
[0083] S107: Update the preset medical and biological terminology database using the target entity set and the target entity relationship set.
[0084] After determining the target entity relation set corresponding to the target entity set based on the first entity relation set and the second entity relation set, the target entity set and the target entity relation set are used to update the preset medical and biological terminology database, thereby realizing the iterative update of the preset medical and biological terminology database and continuously optimizing its performance.
[0085] As described in the above technical solution, after extracting entities and entity relationships from local medical and biological text using both the entity and entity relationship extraction model and a preset medical and biological terminology database, the first candidate entity set extracted by the entity and entity relationship extraction model is integrated using the second candidate entity set extracted from the preset medical and biological terminology database. The integrated target candidate entity set is then mapped to the preset medical and biological terminology database to obtain the target candidate entity set. The target entity relationship set corresponding to the target entity set is determined based on the first entity relationship set extracted by the entity and entity relationship extraction model and the second entity relationship set extracted from the preset medical and biological terminology database. The preset medical and biological terminology database is then updated using the target entity set and the target entity relationship set. By integrating entities extracted from the terminology database with entities extracted by the model, erroneous identification due to insufficient model performance is avoided, and redundant entities are removed. Compared to methods that use the terminology database as the sole source of entity relationships, this approach appropriately expands the relationships between terminology entity pairs, thereby enriching the relationship network of the entire medical and biological terminology database. Continuous iteration and updates to the medical and biological terminology database can help optimize its quality and improve the completeness and accuracy of medical terminology.
[0086] It should be noted that, based on the above embodiments, the present invention also provides corresponding improvements. In subsequent embodiments, steps identical or corresponding to those in the above embodiments can be referenced interchangeably, and the corresponding beneficial effects can also be referred to each other. These improvements will not be elaborated upon in the following improved embodiments.
[0087] See Figure 2 , Figure 2 This is another implementation flowchart of the method for updating the medical and biological terminology database in this invention. The method may include the following steps:
[0088] S201: Obtain local medical and biological text.
[0089] S202: Use the entity and entity relation extraction model to extract entities and entity relations from local medical and biological texts to obtain the first candidate entity set and the first entity relation set.
[0090] S203: Use a pre-defined medical and biological terminology database to extract entities and entity relationships from local medical and biological texts to obtain a second candidate entity set and a second entity relationship set.
[0091] The second candidate entity set can be denoted as DB. UMLS .
[0092] S204: Obtain the first start and end positions of each first candidate entity in the first candidate entity set.
[0093] After extracting the first candidate entity set using the entity and entity relationship extraction model, the first start and end positions corresponding to each first candidate entity in the first candidate entity set are obtained.
[0094] S205: Obtain the second start and end positions corresponding to each second candidate entity in the second candidate entity set.
[0095] After extracting the second candidate entity set using a pre-defined medical and biological terminology database, the second start and end positions corresponding to each second candidate entity in the second candidate entity set are obtained.
[0096] S206: Determine whether there exists a first start-end position contained within the second start-end position. If yes, proceed to step S207; otherwise, proceed to step S209.
[0097] After obtaining the first start and end positions corresponding to each first candidate entity and the second start and end positions corresponding to each second candidate entity, determine whether there is a first start and end position contained in the second start and end position. If yes, it means that there is an entity extracted from the preset medical and biological terminology database that contains an entity and an entity extracted from the entity relationship extraction model, and execute step S207. If no, it means that there is no entity extracted from the preset medical and biological terminology database that contains an entity and an entity extracted from the entity relationship extraction model, and execute step S209.
[0098] S207: The first candidate entity corresponding to the first beginning and end position contained in the second beginning and end position is determined as the first entity to be replaced, and the second candidate entity corresponding to the second beginning and end position contained in the first beginning and end position is determined as the first replacement entity.
[0099] When it is determined that a first beginning-end position is contained within the second beginning-end position, it indicates that an entity extracted from the pre-defined medical and biological terminology database contains an entity extracted by the entity and entity relationship extraction model. The first candidate entity corresponding to the first beginning-end position contained within the second beginning-end position is then determined as the first entity to be replaced, denoted as ENT. MD The second candidate entity corresponding to the second start and end position containing the first start and end position is determined as the first replacement entity, denoted as ENT. DB .
[0100] S208: Use the first replacement entity to perform a replacement operation on the first entity to be replaced.
[0101] The first candidate entity corresponding to the first beginning and end position contained in the second beginning and end position is determined as the first entity to be replaced, ENT. MD And the second candidate entity corresponding to the second start and end position containing the first start and end position is determined as the first replacement entity ENT. DB Then, using the first replacement entity ENT DBFor the first entity to be replaced, ENT MD Perform the replacement operation.
[0102] S209: Determine whether there exists a second start and end position contained within the first start and end position. If yes, proceed to step S210; otherwise, proceed to step S215.
[0103] After obtaining the first start and end positions corresponding to each first candidate entity in the first candidate entity set and the second start and end positions corresponding to each second candidate entity in the second candidate entity set, it is determined whether there is a second start and end position contained in the first start and end position. If yes, it means that there is an entity extracted by the entity and entity relationship extraction model that contains an entity extracted by the preset medical and biological terminology database, and step S210 is executed. If no, it means that there is no entity extracted by the entity and entity relationship extraction model that contains an entity extracted by the preset medical and biological terminology database, and step S215 is executed.
[0104] S210: The second candidate entity corresponding to the second beginning and end position contained in the first beginning and end position is determined as the second replacement entity, and the first candidate entity corresponding to the first beginning and end position containing the second beginning and end position is determined as the second entity to be replaced.
[0105] When it is determined that there is a second beginning and end position contained in the first beginning and end position, it indicates that an entity extracted by the entity and entity relationship extraction model contains an entity extracted by the preset medical and biological terminology database. The second candidate entity corresponding to the second beginning and end position contained in the first beginning and end position is determined as the second replacement entity, and the first candidate entity corresponding to the first beginning and end position containing the second beginning and end position is determined as the second entity to be replaced.
[0106] S211: Perform stop word removal on the second replacement entity to obtain the first sequence, and perform stop word removal on the second entity to be replaced to obtain the second sequence.
[0107] After determining the second candidate entity corresponding to the second start and end position contained in the first start and end position as the second replacement entity, and determining the first candidate entity corresponding to the first start and end position containing the second start and end position as the second entity to be replaced, a stop word removal operation is performed on the second replacement entity to obtain the first sequence, and a stop word removal operation is performed on the second entity to be replaced to obtain the second sequence.
[0108] S212: Calculate the first similarity between the first sequence and the second sequence.
[0109] After removing stop words from the second replacement entity to obtain the first sequence, and then removing stop words from the second entity to be replaced to obtain the second sequence, the first similarity between the first sequence and the second sequence is calculated.
[0110] S213: Determine whether the first similarity reaches the first preset threshold. If yes, proceed to step S214; otherwise, proceed to step S215.
[0111] A first preset threshold for similarity, denoted as K1, is pre-set to determine whether entity replacement should be performed. After calculating the first similarity between the first sequence and the second sequence, it is determined whether the first similarity reaches the first preset threshold. If yes, it means that the first sequence obtained after removing stop words from the second replacement entity has a high similarity to the second sequence obtained after removing stop words from the second entity to be replaced, and step S214 is executed. If no, it means that the first sequence obtained after removing stop words from the second replacement entity has a low similarity to the second sequence obtained after removing stop words from the second entity to be replaced, and step S215 is executed.
[0112] It should be noted that the first preset threshold can be set and adjusted according to the actual situation, and the embodiments of the present invention do not limit this.
[0113] S214: Use the second replacement entity to perform a replacement operation on the second entity to be replaced.
[0114] When the first similarity reaches the first preset threshold, it means that the first sequence obtained by the second replacement entity after removing stop words is highly similar to the second sequence obtained by the second entity to be replaced after removing stop words. The second replacement entity is then used to replace the second entity to be replaced.
[0115] S215: Determine whether there are partially overlapping first and second start-end positions. If yes, proceed to step S216; otherwise, proceed to step S221.
[0116] After obtaining the first start and end positions corresponding to each first candidate entity in the first candidate entity set and the second start and end positions corresponding to each second candidate entity in the second candidate entity set, it is determined whether there are partially overlapping first start and end positions and second start and end positions. If yes, it means that the start and end positions of an entity extracted by the entity and entity relationship extraction model partially overlap with the start and end positions of an entity extracted by the preset medical and biological terminology database, and step S216 is executed. If no, it means that the start and end positions of an entity extracted by the entity and entity relationship extraction model do not partially overlap with the start and end positions of an entity extracted by the preset medical and biological terminology database, and step S221 is executed.
[0117] S216: The first candidate entity corresponding to the partially overlapping first start and end positions is determined as the third entity to be replaced, and the second candidate entity corresponding to the partially overlapping second start and end positions is determined as the third replacement entity.
[0118] When it is determined that there is partial overlap between the first and second start-end positions, it indicates that there is partial overlap between the start-end position of an entity extracted by the entity and entity relationship extraction model and the start-end position of an entity extracted by the preset medical and biological terminology database. The first candidate entity corresponding to the partially overlapping first start-end position is determined as the third entity to be replaced, and the second candidate entity corresponding to the partially overlapping second start-end position is determined as the third replacement entity.
[0119] S217: Perform stop word removal on the third entity to be replaced to obtain the third sequence, and perform stop word removal on the third entity to be replaced to obtain the fourth sequence.
[0120] After determining the first candidate entity corresponding to the partially overlapping first start and end positions as the third entity to be replaced, and the second candidate entity corresponding to the partially overlapping second start and end positions as the third entity to be replaced, a stop word removal operation is performed on the third entity to be replaced to obtain the third sequence, and a stop word removal operation is performed on the third entity to be replaced to obtain the fourth sequence.
[0121] S218: Calculate the second similarity between the third sequence and the fourth sequence.
[0122] After removing stop words from the third entity to be replaced to obtain the third sequence, and then removing stop words from the third entity to be replaced to obtain the fourth sequence, the second similarity between the third sequence and the fourth sequence is calculated.
[0123] S219: Determine whether the second similarity reaches the second preset threshold. If yes, proceed to step S220; otherwise, proceed to step S221.
[0124] A second preset threshold for similarity, denoted as K2, is pre-set to determine whether entity replacement should be performed. After calculating the second similarity between the third sequence and the fourth sequence, it is determined whether the second similarity reaches the second preset threshold. If yes, it means that the fourth sequence obtained after removing stop words from the third replacement entity has a high similarity to the third sequence obtained after removing stop words from the third entity to be replaced, and step S220 is executed. If no, it means that the fourth sequence obtained after removing stop words from the third replacement entity has a low similarity to the third sequence obtained after removing stop words from the third entity to be replaced, and step S221 is executed.
[0125] S220: Use the third replacement entity to perform a replacement operation on the third entity to be replaced.
[0126] When the second similarity is determined to reach the second preset threshold, it means that the fourth sequence obtained by the third replacement entity after removing stop words is highly similar to the third sequence obtained by the third entity to be replaced after removing stop words. The third replacement entity is then used to replace the third entity to be replaced.
[0127] S221: Obtain the target candidate entity set.
[0128] After performing replacement selection on each entity extracted by the entity and entity relation extraction model based on the first start and end positions corresponding to each first candidate entity in the first candidate entity set and the second start and end positions corresponding to each second candidate entity in the second candidate entity set, the final target candidate entity set corresponding to the entity and entity relation extraction model is obtained, denoted as ENT. CANDI .
[0129] S222: Calculate the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set using the entity and entity relationship extraction model.
[0130] After obtaining the final target candidate entity set corresponding to the entity and entity relationship extraction model, the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set are calculated using the entity and entity relationship extraction model.
[0131] S223: Use a similarity calculation algorithm to determine the second representation vector with the highest similarity and the maximum similarity value corresponding to each first representation vector.
[0132] After calculating the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set, the similarity calculation algorithm is used to determine the second representation vector with the highest similarity and the maximum similarity value corresponding to each first representation vector.
[0133] The process of calculating the similarity between vectors can include the following calculation paths:
[0134] (1) Based on the obtained entity representation vectors, similarity calculation methods (including but not limited to cosine similarity and Euclidean distance) are used to generate the target candidate entity set ENT. CANDI For each entity, find the second candidate entity set DB with the highest similarity. UMLS The entity in the image is identified, and the similarity value sim is saved. max ;
[0135] (2) Based on the obtained entity representation vectors, the second candidate entity set DB is first obtained. UMLS The representation vector of each concept (optional methods include, but are not limited to, the mean of the vectors of all entities included in the concept, weighted sum, and attention mechanisms) is then used to calculate similarity (including but not limited to cosine similarity and Euclidean distance) to form the target candidate entity set ENT. CANDIFor each entity, find the second candidate entity set DB with the highest similarity. UMLS The entity in the image is identified, and the similarity value sim is saved. max ;
[0136] (3) Utilize the similarity of n-character fragments between entities (the calculation process is shown in the formula below, where N is the maximum string length) to define the target candidate entity set ENT. CANDI For each entity, find the second candidate entity set DB with the highest similarity. UMLS The entity in the image is identified, and the similarity value sim is saved. max Optional calculation of similarity for the second candidate entity set DB UMLS The string can be each entity or the second candidate entity set DB. UMLS Each concept in the standard entity corresponds to a standard entity.
[0137]
[0138] S224: Based on the maximum similarity value corresponding to each first representation vector, map the target candidate entity set to the preset medical and biological terminology database to obtain the target entity set.
[0139] After determining the second representation vector with the highest similarity and the maximum similarity value corresponding to each first representation vector using a similarity calculation algorithm, the target candidate entity set is mapped to a preset medical and biological terminology database based on the maximum similarity value corresponding to each first representation vector, thus obtaining the target entity set.
[0140] The process of mapping a target candidate entity set to a pre-defined medical and biological terminology database may include: based on the obtained similarity, if the maximum similarity sim involved by a candidate entity in the target candidate entity set is... max If the value is less than the threshold K3, the candidate entity is discarded; if sim max ∈[K3,K4], where K4≥K3, then the results will be checked and selected by medical experts; if sim max If K > K4, then the second candidate entity set DB UMLS The concept to which the entity with the highest similarity in the dataset belongs is the concept to which the candidate entity belongs. Based on this rule, the target candidate entity set is mapped to the second candidate entity set DB. UMLS middle.
[0141] Based on DB UMLS The pharmaceutical and biological entities extracted by the exact matching method are merged and filtered with those extracted by the model, which can effectively prevent them from existing in the preset database. UMLS The entity words in the database are incorrectly identified due to insufficient model performance. This can also, to some extent, remove redundant entities (from the database). UMLSThe existing entities differ only in stop words, and entities to be expanded are retained (compared to DB). UMLS (Existing entities have low similarity). Using similarity to classify and select candidate medical and biological terms can effectively eliminate erroneous candidate entities (such as non-medical and biological terminology entities) and can also classify and standardize candidate entities more accurately and intelligently.
[0142] S225: Obtain the set of entity pairs and relation triples that have corresponding relations in the first entity relation set and the second entity relation set.
[0143] For each pair of entities in the first candidate entity set, the relationship to which the "entity pair" belongs is predicted based on the entity and entity relationship extraction model. If the relationship labels whose predicted probability is greater than the threshold K5 are saved, a first entity relationship set LAB is formed. MD And combine entity pairs to form triples (in the form of: (ENT1, ENT2, LAB) MD )) set TRIPS MD ENT1 and ENT2 represent entities; in the second candidate entity set DB UMLS Find TRIPS in the middle. MD The entity pairs in the array involve relations and are used to obtain triples (in the form of: (ENT1, ENT2, LAB) UMLS )) set TRIPS UMLS Retrieve the sets of entity pairs and relation triples that have corresponding relationships in the first entity relation set and the second entity relation set.
[0144] S226: Calculate the similarity between corresponding entities in a set of entity pairs and relation triples that have a corresponding relationship.
[0145] After obtaining the entity pairs and relation triples that have corresponding relationships in the first entity relation set and the second entity relation set, the similarity between each corresponding entity in the entity pairs and relation triples that have corresponding relationships is calculated.
[0146] S227: Determine the target entity relationship set corresponding to the target entity set based on similarity.
[0147] After calculating the similarity between corresponding entities in the set of entity pairs and relation triples that have a corresponding relationship, the target entity relation set corresponding to the target entity set is determined based on the similarity.
[0148] In two sets of triples TRIPS MD and TRIPS UMLS In this context, for any entity pair (ENT1, ENT2):
[0149] (1) When ENT1, ENT2 and DB UMLSWhen the maximum similarity value of all entities in LAB is greater than K4, if LAB MD ∈LAB UMLS Then the relationship between entities ENT1 and ENT2 is LAB. UMLS ;like Then it needs to be determined manually whether to add LAB MD It does not exist in LAB UMLS Relationship tags stored in DB UMLS middle.
[0150] (2) When ENT1 or ENT2 exists and DB exists UMLS If the maximum similarity value between entities does not exceed K4, then the relationship between entities ENT1 and ENT2 is LAB. UMLS .
[0151] By introducing a relational network between terms into a traditional local pharmaceutical and biological database that only contains pharmaceutical and biological terminology, previously scattered entities can be effectively linked and organized. Compared with methods that use the terminology database as the sole source of entity relationships, the "model + terminology database + manual proofreading" approach can appropriately expand the relationships between entity pairs, thereby enriching the relational network of the entire pharmaceutical and biological terminology database.
[0152] S228: Update the preset medical and biological terminology database using the target entity set and the target entity relationship set.
[0153] S229: Update the entity and entity relationship extraction model using the updated medical and biological terminology database.
[0154] After updating the pre-defined medical and biological terminology database using the target entity set and target entity relation set, the updated database is used to update the entity and entity relation extraction model. The updated database is then used to annotate local text data, and the annotated corpus is used to train the entity and entity relation extraction model, allowing both the model and the database to be continuously updated and optimized. Compared to traditional word segmentation methods, the model trained on annotated data from the medical and biological terminology database can extract more accurate and complete medical and biological terminology entities.
[0155] This embodiment differs from Embodiment 1 corresponding to the technical solution claimed in Independent Claim 1, and also adds the technical solutions claimed in Dependent Claims 2 to 7. Of course, depending on the actual situation and requirements, the technical solutions claimed in each dependent claim can be flexibly combined without affecting the integrity of the solution, so as to better meet the requirements of different usage scenarios. This embodiment only provides one solution that includes the most solutions and has the best effect. Because the situation is complex, it is impossible to list all possible solutions. Those skilled in the art should realize that there can be many examples based on the basic method principle provided in this application combined with the actual situation. Without sufficient creative effort, they should all be within the protection scope of this application.
[0156] Corresponding to the above method embodiments, the present invention also provides an updating device for a pharmaceutical and biological terminology database. The updating device for the pharmaceutical and biological terminology database described below and the updating method for the pharmaceutical and biological terminology database described above can be referred to in correspondence with each other.
[0157] See Figure 3 , Figure 3 This is a structural block diagram of a medical and biological terminology database update device according to an embodiment of the present invention. The device may include:
[0158] Text acquisition module 31 is used to acquire local medical and biological text;
[0159] The first entity and relation extraction module 32 is used to extract entities and entity relations from local medical and biological text using an entity and entity relation extraction model to obtain a first candidate entity set and a first entity relation set.
[0160] The second entity and relation extraction module 33 is used to extract entities and entity relations from local medical and biological texts using a preset medical and biological terminology library, so as to obtain a second candidate entity set and a second entity relation set.
[0161] The set integration module 34 is used to integrate the first candidate entity set according to the second candidate entity set to obtain the target candidate entity set;
[0162] The set mapping module 35 is used to map the target candidate entity set to a preset medical and biological terminology database to obtain the target entity set;
[0163] The relation set determination module 36 is used to determine the target entity relation set corresponding to the target entity set based on the first entity relation set and the second entity relation set.
[0164] The terminology database update module 37 is used to update the preset medical and biological terminology database using the target entity set and the target entity relationship set.
[0165] As described in the above technical solution, after extracting entities and entity relationships from local medical and biological text using both the entity and entity relationship extraction model and a preset medical and biological terminology database, the first candidate entity set extracted by the entity and entity relationship extraction model is integrated using the second candidate entity set extracted from the preset medical and biological terminology database. The integrated target candidate entity set is then mapped to the preset medical and biological terminology database to obtain the target candidate entity set. The target entity relationship set corresponding to the target entity set is determined based on the first entity relationship set extracted by the entity and entity relationship extraction model and the second entity relationship set extracted from the preset medical and biological terminology database. The preset medical and biological terminology database is then updated using the target entity set and the target entity relationship set. By integrating entities extracted from the terminology database with entities extracted by the model, erroneous identification due to insufficient model performance is avoided, and redundant entities are removed. Compared to methods that use the terminology database as the sole source of entity relationships, this approach appropriately expands the relationships between terminology entity pairs, thereby enriching the relationship network of the entire medical and biological terminology database. Continuous iteration and updates to the medical and biological terminology database can help optimize its quality and improve the completeness and accuracy of medical terminology.
[0166] In one specific embodiment of the present invention, the device may further include:
[0167] The model update module is used to update the entity and entity relationship extraction model using the updated medical and biological terminology database after updating the preset medical and biological terminology database with the target entity set and the target entity relationship set.
[0168] In one specific embodiment of the present invention, the collection integration module 34 includes:
[0169] The first start-end position acquisition submodule is used to acquire the first start-end position corresponding to each first candidate entity in the first candidate entity set;
[0170] The second start-end position acquisition submodule is used to acquire the second start-end position corresponding to each second candidate entity in the second candidate entity set.
[0171] The first judgment submodule is used to determine whether there exists a first start-end position contained in the second start-end position;
[0172] The first entity to be replaced and the entity to be replaced determination submodule is used to determine the first candidate entity corresponding to the first beginning and end position containing the second beginning and end position as the first entity to be replaced, and to determine the second candidate entity corresponding to the second beginning and end position containing the first beginning and end position as the first entity to be replaced when it is determined that there is a first beginning and end position containing the second beginning and end position;
[0173] The first entity replacement submodule is used to replace the first entity to be replaced with the first replacement entity.
[0174] In one specific embodiment of the present invention, the device may further include:
[0175] The second judgment submodule is used to determine whether there is a second start-end position contained in the first start-end position;
[0176] The second candidate entity to be replaced and the replacement entity determination submodule is used to determine the second candidate entity corresponding to the second beginning and end position containing the first beginning and end position as the second replacement entity when it is determined that there is a second beginning and end position containing the first beginning and end position, and to determine the first candidate entity corresponding to the first beginning and end position containing the second beginning and end position as the second candidate entity to be replaced.
[0177] The first sequence obtaining submodule is used to perform stop word removal operation on the second replacement entity to obtain the first sequence, and to perform stop word removal operation on the second entity to be replaced to obtain the second sequence;
[0178] The first similarity calculation submodule is used to calculate the first similarity between the first sequence and the second sequence;
[0179] The third judgment submodule is used to determine whether the first similarity reaches the first preset threshold.
[0180] The second entity replacement submodule is used to replace the second entity to be replaced with the second replacement entity when the first similarity is determined to reach the first preset threshold.
[0181] In one specific embodiment of the present invention, the device may further include:
[0182] The fourth judgment submodule is used to determine whether there are partially overlapping first and second start and end positions after obtaining the second start and end positions corresponding to each second candidate entity in the second candidate entity set.
[0183] The third entity to be replaced and the entity to be replaced determination submodule is used to determine the first candidate entity corresponding to the partially overlapping first start and end position as the third entity to be replaced, and the second candidate entity corresponding to the partially overlapping second start and end position as the third entity to be replaced when it is determined that there is a partially overlapping first start and end position and a partially overlapping second start and end position.
[0184] The second sequence obtaining submodule is used to perform stop word removal operation on the third entity to be replaced to obtain the third sequence, and to perform stop word removal operation on the third entity to be replaced to obtain the fourth sequence;
[0185] The second similarity calculation submodule is used to calculate the second similarity between the third sequence and the fourth sequence;
[0186] The fifth judgment submodule is used to determine whether the second similarity reaches the second preset threshold;
[0187] The third entity replacement submodule is used to replace the third entity to be replaced with the third replacement entity when the second similarity is determined to reach the second preset threshold.
[0188] In one specific embodiment of the present invention, the set mapping module 35 includes:
[0189] The vector calculation submodule is used to calculate the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set using the entity and entity relationship extraction model.
[0190] The third similarity calculation submodule is used to determine the second representation vector with the highest similarity and the maximum similarity value corresponding to each first representation vector using a similarity calculation algorithm.
[0191] The set mapping submodule is used to map the target candidate entity set to a preset medical and biological terminology database based on the maximum similarity value corresponding to each first representation vector.
[0192] In one specific embodiment of the present invention, the relation set determination module 36 includes:
[0193] The triple set acquisition submodule is used to acquire entity pairs and relation triple sets that have corresponding relations in the first entity relation set and the second entity relation set;
[0194] The fourth similarity calculation submodule is used to calculate the similarity between corresponding entities in the set of entity pairs and relation triples that have a corresponding relationship;
[0195] The Relationship Set Determination Submodule is used to determine the target entity relationship set corresponding to the target entity set based on similarity.
[0196] For the method embodiments described above, see [link to relevant documentation]. Figure 4 , Figure 4 This is a schematic diagram of the device for updating the pharmaceutical and biological terminology database provided by the present invention. The device may include:
[0197] Memory 332 is used to store computer programs;
[0198] The processor 322 is configured to execute a computer program to implement the steps of the method for updating the medical and biological terminology database in the above method embodiments.
[0199] For details, please refer to Figure 5 , Figure 5This is a schematic diagram illustrating the specific structure of a pharmaceutical and biological terminology database update device provided in this embodiment. The update device can vary significantly due to differences in configuration or performance. It may include a processor (central processing unit, CPU) 322 (e.g., one or more processors) and a memory 332. The memory 332 stores one or more computer application programs 342 or data 344. The memory 332 can be temporary or persistent storage. The program stored in the memory 332 may include one or more modules (not shown in the diagram), each module including a series of instruction operations on the data processing device. Furthermore, the processor 322 may be configured to communicate with the memory 332 and execute the series of instruction operations stored in the memory 332 on the pharmaceutical and biological terminology database update device 301.
[0200] The updating device 301 for the medical and biological terminology database may also include one or more power supplies 326, one or more wired or wireless network interfaces 350, one or more input / output interfaces 358, and / or one or more operating systems 341.
[0201] The steps in the method for updating the medical and biological terminology database described above can be implemented by the structure of the updating device for the medical and biological terminology database.
[0202] Corresponding to the above method embodiments, the present invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can perform the following steps:
[0203] The process involves: acquiring local medical and biological text; extracting entities and entity relationships from the local medical and biological text using an entity and entity relationship extraction model to obtain a first candidate entity set and a first entity relationship set; extracting entities and entity relationships from the local medical and biological text using a pre-defined medical and biological terminology database to obtain a second candidate entity set and a second entity relationship set; integrating the first candidate entity set with the second candidate entity set to obtain a target candidate entity set; mapping the target candidate entity set to the pre-defined medical and biological terminology database to obtain a target entity set; determining the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set; and updating the pre-defined medical and biological terminology database using the target entity set and the target entity relationship set.
[0204] The computer-readable storage medium may include various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0205] For a description of the computer-readable storage medium provided by the present invention, please refer to the above method embodiments; the present invention will not be described in detail here.
[0206] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatuses, devices, and computer-readable storage media disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the descriptions are relatively simple; relevant parts can be referred to the method section.
[0207] This article uses specific examples to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the technical solutions and core ideas of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made to the present invention without departing from the principles of the present invention, and these improvements and modifications also fall within the protection scope of the claims of the present invention.
Claims
1. A method for updating a medical and biological terminology database, characterized in that, include: Retrieve local medical and biological text; The entity and entity relation extraction model is used to extract entities and entity relations from the local medical and biological text to obtain a first candidate entity set and a first entity relation set. The local medical and biological text is used to extract entities and entity relationships using a preset medical and biological terminology database to obtain a second candidate entity set and a second entity relationship set. The first candidate entity set is integrated based on the second candidate entity set to obtain the target candidate entity set. The target candidate entity set is mapped to the preset medical and biological terminology database to obtain the target entity set; The target entity relationship set corresponding to the target entity set is determined based on the first entity relationship set and the second entity relationship set; The preset medical and biological terminology database is updated using the target entity set and the target entity relationship set. The integration operation of the first candidate entity set based on the second candidate entity set includes: Obtain the first start and end positions corresponding to each of the first candidate entities in the first candidate entity set; Obtain the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set; Determine whether there exists a first beginning and end position contained within the second beginning and end position; If so, the first candidate entity corresponding to the first start and end position contained in the second start and end position is determined as the first entity to be replaced, and the second candidate entity corresponding to the second start and end position contained in the first start and end position is determined as the first replacement entity; The first replacement entity is used to replace the first entity to be replaced.
2. The method for updating the pharmaceutical and biological terminology database according to claim 1, characterized in that, After updating the preset medical and biological terminology database using the target entity set and the target entity relationship set, the process further includes: The entity and entity relationship extraction model are updated using the updated medical and biological terminology database.
3. The method for updating the pharmaceutical and biological terminology database according to claim 1, characterized in that, After obtaining the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set, the process further includes: Determine whether there exists a second beginning and end position that is contained within the first beginning and end position; If so, the second candidate entity corresponding to the second start and end position contained in the first start and end position is determined as the second replacement entity, and the first candidate entity corresponding to the first start and end position contained in the second start and end position is determined as the second entity to be replaced. The second replacement entity is subjected to a stop word removal operation to obtain a first sequence, and the second entity to be replaced is subjected to a stop word removal operation to obtain a second sequence; Calculate the first similarity between the first sequence and the second sequence; Determine whether the first similarity reaches a first preset threshold; If so, the second replacement entity is used to replace the second entity to be replaced.
4. The method for updating the pharmaceutical and biological terminology database according to claim 3, characterized in that, After obtaining the second start and end positions corresponding to each of the second candidate entities in the second candidate entity set, the process further includes: Determine whether there is partial overlap between the first and second start-end positions; If so, the first candidate entity corresponding to the first partially overlapping start and end positions is determined as the third entity to be replaced, and the second candidate entity corresponding to the second partially overlapping start and end positions is determined as the third replacement entity. The third entity to be replaced is subjected to a stop word removal operation to obtain a third sequence, and the third entity to be replaced is subjected to a stop word removal operation to obtain a fourth sequence; Calculate the second similarity between the third sequence and the fourth sequence; Determine whether the second similarity reaches the second preset threshold; If so, the third replacement entity is used to replace the third entity to be replaced.
5. The method for updating the pharmaceutical and biological terminology database according to any one of claims 1 to 4, characterized in that, Mapping the target candidate entity set to the preset medical and biological terminology database includes: The entity and entity relationship extraction model is used to calculate the first representation vector corresponding to each target candidate entity in the target candidate entity set and the second representation vector corresponding to each second candidate entity in the second candidate entity set. The second representation vector with the highest similarity and the maximum similarity value corresponding to each of the first representation vectors are determined using a similarity calculation algorithm. Based on the maximum similarity value corresponding to each of the first representation vectors, the target candidate entity set is mapped to the preset medical and biological terminology database.
6. The method for updating the pharmaceutical and biological terminology database according to claim 1, characterized in that, Determining the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set includes: Obtain the set of entity pairs and relation triples that have corresponding relationships in the first entity relation set and the second entity relation set; Calculate the similarity between corresponding entities in a set of entity pairs and relation triples that have a corresponding relationship; The target entity relationship set corresponding to the target entity set is determined based on the similarity.
7. A device for updating a medical and biological terminology database, characterized in that, include: The text acquisition module is used to acquire local medical and biological text. The first entity and relation extraction module is used to extract entities and entity relations from the local medical and biological text using an entity and entity relation extraction model, so as to obtain a first candidate entity set and a first entity relation set. The second entity and relation extraction module is used to extract entities and entity relations from the local medical and biological text using a preset medical and biological terminology library, so as to obtain a second candidate entity set and a second entity relation set. The set integration module is used to integrate the first candidate entity set according to the second candidate entity set to obtain the target candidate entity set; The set mapping module is used to map the target candidate entity set to the preset medical and biological terminology database to obtain the target entity set; The set determination module is used to determine the target entity relationship set corresponding to the target entity set based on the first entity relationship set and the second entity relationship set; The terminology database update module is used to update the preset medical and biological terminology database using the target entity set and the target entity relationship set. The collection and integration module includes: The first start-end position acquisition submodule is used to acquire the first start-end position corresponding to each first candidate entity in the first candidate entity set; The second start-end position acquisition submodule is used to acquire the second start-end position corresponding to each second candidate entity in the second candidate entity set. The first judgment submodule is used to determine whether there exists a first start-end position contained in the second start-end position; The first entity to be replaced and the entity to be replaced determination submodule is used to determine the first candidate entity corresponding to the first beginning and end position containing the second beginning and end position as the first entity to be replaced, and to determine the second candidate entity corresponding to the second beginning and end position containing the first beginning and end position as the first entity to be replaced when it is determined that there is a first beginning and end position containing the second beginning and end position; The first entity replacement submodule is used to replace the first entity to be replaced with the first replacement entity.
8. A device for updating a medical and biological terminology database, characterized in that, include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the steps of the method for updating the medical and biological terminology database as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the method for updating the medical and biological terminology database as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Text data processing method, device, electronic device and computer-readable medium
CN109299472A
Medical term system construction method, device and equipment and storage medium
CN111274400A