Medical diagnosis text processing method and device

By using a preset keyword table and probability calculation method in medical diagnosis, the accuracy of automatic coding of disease diagnosis is simplified and improved, solving the problem of cumbersome processes in existing technologies.

CN116312909BActive Publication Date: 2025-09-26BEIJING UNISOUND INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211095594.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-06
Publication Date
2025-09-26
Estimated Expiration
2042-09-06

AI Technical Summary

Technical Problem

The existing automatic coding method for disease diagnosis is cumbersome and lengthy, and the coding accuracy needs to be improved.

Method used

By obtaining the diagnostic basis text, using the preset keyword table to map categories, calculating the probabilities of categories and subcategories, and performing joint probability calculations to determine the target categories and subcategories.

Benefits of technology

It simplifies the coding process of medical diagnosis texts and improves the accuracy and efficiency of coding.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116312909B_ABST
    Figure CN116312909B_ABST
Patent Text Reader

Abstract

The present invention relates to a medical diagnosis text processing method, comprising: obtaining a diagnosis basis text; obtaining a plurality of categories mapped to the diagnosis basis text based on the diagnosis basis text and a preset keyword table; wherein the preset keyword table includes keywords and categories corresponding to the keywords; determining a first probability for each category; determining a subcategory corresponding to each category; obtaining a second probability for the subcategory based on the diagnosis basis text, the subcategory and a preset model; obtaining a joint probability based on the first probability and the second probability; and determining a target category and a target subcategory based on the joint probability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a medical diagnosis text processing method and device. Background Art

[0002] Existing automatic disease diagnosis coding methods include: obtaining a disease diagnosis based on a target case; searching based on the disease diagnosis to obtain a preset number of candidate ICD disease names and codes with the highest similarity to the disease diagnosis; calculating a score for the disease diagnosis and the preset number of candidate ICD codes based on the disease diagnosis, the ICD disease name, and the chapter, section, category, and sub-category codes in the ICD code; and determining the candidate ICD code with the highest score as the code for the disease diagnosis. By utilizing the hierarchical characteristics of the code, namely the chapter, section, category, and sub-category codes in the code, the disease diagnosis is coded, which improves coding accuracy.

[0003] In the existing technical solution, the model is a channel with multiple modules, such as chapters, sections, categories, sub-categories, etc., and finally the detailed models are aligned, making the overall process too cumbersome and lengthy. Summary of the Invention

[0004] The purpose of the present invention is to provide a medical diagnosis text processing method and device to solve the problems existing in the prior art.

[0005] In a first aspect, the present invention provides a method for processing medical diagnosis text, the method comprising:

[0006] Obtain the diagnosis basis text;

[0007] According to the diagnosis basis text and a preset keyword table, a plurality of categories mapped to the diagnosis basis text are obtained; wherein the preset keyword table includes keywords and categories corresponding to the keywords;

[0008] Determine the first probability for each category;

[0009] Determine the subcategory corresponding to each category;

[0010] Obtaining a second probability of the sub-category according to the diagnosis basis text, the sub-category, and a preset model;

[0011] Obtaining a joint probability according to the first probability and the second probability;

[0012] According to the joint probability, the target category and target subcategory are determined.

[0013] In a possible implementation, the multiple categories of the diagnosis basis text mapping obtained according to the diagnosis basis text and the preset keyword table specifically include:

[0014] Obtaining keywords of the diagnosis basis text;

[0015] According to the keyword and the preset keyword table, query the category corresponding to the keyword;

[0016] Determine the category for each keyword mapping.

[0017] In a possible implementation, determining the first probability of each category specifically includes:

[0018] determining the first number of times each category is mapped;

[0019] Determine the second number of keywords mapped to categories;

[0020] A first probability of each of the multiple categories is calculated based on a ratio of the first number of times to the second number of times.

[0021] In a possible implementation, obtaining the second probability of the sub-target according to the diagnosis basis text, the sub-target, and the preset model specifically includes:

[0022] Using a word segmenter, the diagnosis basis text and the sub-item are segmented to obtain a first segmentation and a second segmentation;

[0023] Encode the first participle and the second participle respectively to obtain a first code and a second code;

[0024] Convert the first code into a first vector, and convert the second code into a second vector;

[0025] The first vector and the second vector are concatenated, and the concatenated result is input into a preset model, and a preset function is used to calculate a first score of each sub-item with a first value and a second score of each sub-item with a second value;

[0026] A second score for each sub-goal is calculated based on the first score and the second score.

[0027] In a possible implementation, obtaining a joint probability according to the first probability and the second probability specifically includes:

[0028] The first probability of each category is multiplied by the second probability of the subcategory to which the category belongs, to obtain the joint probability of each category to its subcategory.

[0029] In a possible implementation, determining the target category and the target subcategory according to the joint probability specifically includes:

[0030] The category and subcategory corresponding to the joint probability with the largest value are selected from the joint probabilities as the target category and target subcategory.

[0031] In a second aspect, the present invention provides a medical diagnosis text processing device, the device comprising:

[0032] An acquisition module, wherein the acquisition module is used to acquire a diagnosis basis text;

[0033] A query module, the query module being configured to obtain a plurality of categories mapped to the diagnosis basis text according to the diagnosis basis text and a preset keyword table; wherein the preset keyword table includes keywords and categories corresponding to the keywords;

[0034] a first determination module, configured to determine a first probability for each category;

[0035] a second determination module, configured to determine a subcategory corresponding to each category;

[0036] a processing module, the processing module being configured to obtain a second probability of the sub-category based on the diagnosis basis text, the sub-category, and a preset model;

[0037] The processing module is further configured to obtain a joint probability based on the first probability and the second probability;

[0038] A third determination module is used to determine the target category and the target subcategory based on the joint probability.

[0039] In a third aspect, the present invention provides a chip system comprising a processor coupled to a memory, wherein the memory stores program instructions, and when the program instructions stored in the memory are executed by the processor, the medical diagnosis text processing method described in any one of the first aspects is implemented.

[0040] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, and the computer program is executed by a processor to execute the medical diagnosis text processing method described in any one of the first aspects.

[0041] In a fifth aspect, the present invention provides a computer program product, which, when executed on a computer, enables the computer to execute the medical diagnosis text processing method as described in any one of the first aspects.

[0042] By applying the medical diagnosis text processing method provided by the embodiment of the present invention, the first probability of the category and the second probability of the subcategory are utilized, and the first probability and the second probability are jointly calculated, making the encoding process of the medical diagnosis text simpler. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 A schematic diagram of a process flow for a medical diagnosis text processing method provided in Example 1 of the present invention;

[0044] Figure 2 A schematic diagram of the structure of a medical diagnosis text processing device provided in the second embodiment of the present invention;

[0045] Figure 3 A schematic diagram of the chip system structure provided in the third embodiment of the present invention;

[0046] Figure 4 A schematic diagram of a computer-readable storage medium provided in Embodiment 4 of the present invention;

[0047] Figure 5 Schematic diagram of a computer program product provided in Embodiment 5 of the present invention. DETAILED DESCRIPTION

[0048] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments.

[0049] In order to make the purpose, technical solutions and advantages of the present invention more clear, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.

[0050] The terms "first," "second," and the like in the specification and claims of this application and the accompanying drawings are used to distinguish between different objects, not to describe a particular order. Furthermore, the terms "including," "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or elements is not limited to the listed steps or elements, but may optionally include steps or elements not listed, or may optionally include other steps or elements inherent to the process, method, product, or apparatus.

[0051] Example 1

[0052] Figure 1 This is a flow chart of a method for processing medical diagnosis text provided in the first embodiment of the present invention. This method is applied in the scenario of encoding the diagnosis basis text. Figure 1 As shown, the method includes the following steps:

[0053] Step 110, obtaining the diagnosis basis text;

[0054] Step 120: obtaining a plurality of categories mapped to the diagnosis basis text according to the diagnosis basis text and a preset keyword table; wherein the preset keyword table includes keywords and categories corresponding to the keywords;

[0055] Specifically, step 120 includes: obtaining keywords of the diagnosis basis text; searching for categories corresponding to the keywords based on the keywords and a preset keyword table; and determining the category to which each keyword is mapped.

[0056] Assume that the diagnosis basis text is S, and in the first stage, S is mapped to M categories using keywords, and n categories {d1, d2, ..., d n}, where one keyword is mapped to one category, and any two or more keywords can be mapped to the same category.

[0057] In a specific example, the keyword table is a correspondence file between keywords and categories, which is obtained from detailed sub-category information, for example: tonsillar column -> tonsil malignant tumor; gastric fundus -> gastric malignant tumor, etc.

[0058] Get multiple categories based on keyword table mapping. Each category may be mapped multiple times, for example:

[0059] Diagnosis: (cardia and pylorus) elevated moderately to poorly differentiated adenocarcinoma, some of which are signet ring cell carcinomas. The tumor invades the deep muscle layer and involves the duodenal mucosa, with tumor thrombi seen in the blood vessels.

[0060] In the keyword table, it can be mapped to cardia->gastric malignant tumor; pylorus->gastric malignant tumor; rectum->rectal malignant tumor.

[0061] Step 130, determining a first probability for each category;

[0062] Specifically, step 130 includes: determining a first number of times each category is mapped; determining a second number of times the keyword is mapped to the category; and calculating a first probability of each category in the multiple categories based on a ratio of the first number to the second number.

[0063] Continuing with the previous example, the probability value of one stage is calculated by dividing the number of category mappings of category i by the total number of mappings. The specific formula is as follows:

[0064]

[0065] Among them, c i represents the number of category keyword mappings for category i, a represents the number of all mappings, and f i Represents the score of the first stage of the i-th category.

[0066] Therefore, the probability value of the stomach malignancy category in this example (2 / 3) is higher than the probability value of the rectal malignancy category (1 / 3).

[0067] Step 140, determining the subcategory corresponding to each category;

[0068] Among them, subcategory is the upper level classification unit of category, and category has its own subcategory. The correspondence between category and subcategory can be stored in advance. For example, category {d1, d2, ..., d n} belong to the following suborders: {d 11 ,d 12 ,..,d n1 ,..,d nm}.

[0069] Step 150, obtaining a second probability of the sub-category based on the diagnosis basis text, the sub-category, and the preset model;

[0070] Specifically, step 150 includes: using a word segmenter to segment the diagnostic basis text and sub-items respectively to obtain a first word segmentation and a second word segmentation; encoding the first word segmentation and the second word segmentation respectively to obtain a first code and a second code; converting the first code into a first vector and converting the second code into a second vector; concatenating the first vector and the second vector, and inputting the concatenated result into a preset model, and calculating through a preset function to obtain a first score of each sub-item result taking a first value and a second score of each sub-item taking a second value; and calculating the second score of each sub-item based on the first score and the second score. During word segmentation, if a category has no sub-items, the category itself is input.

[0071] Continuing with the previous example, the diagnosis text is: (cardia and pylorus) elevated moderately to poorly differentiated adenocarcinoma, some of which are signet ring cell carcinomas. The tumor invades the deep muscle layer and involves the duodenal mucosa, and tumor thrombi are seen in the blood vessels.

[0072] Stage 1 categories (scores): C16 gastric malignant tumor (2 / 3), C20 rectal malignant tumor (1 / 3)

[0073] Second stage suborder:

[0074] C16.0 Malignant neoplasm of cardia

[0075] C16.1 Malignant neoplasm of gastric fundus ...

[0077] C16.8 Lesion of overlapping malignant neoplasm of stomach

[0078] C16.9 Unspecified malignant neoplasm of stomach

[0079] C20 Malignant neoplasm of rectum (no subcategory, enter the category itself)

[0080] The input of the default model is I={S,d ij}, after the word segmentation, the two S,d ij The words are segmented and encoded, converted into vectors, and the two vectors are concatenated and input into a binary classification model based on the pre-trained model BERT, as shown below:

[0081] H = BERT_Classify(I)

[0082] After the sigmoid function calculation, it is as follows:

[0083] d ij =sigmoid(H)

[0084] The final result is:

[0085]

[0086] Among them, d ij It is represented as the jth subcategory under the i-th category, S ij1_score The first score of the j-th sub-category result under the i-th category is 1, S ij0_score The second score of 0 is taken as the result, and the first score is taken as the value of the second probability, because 1 represents this suborder and 0 represents not this suborder.

[0087] Step 160, obtaining a joint probability based on the first probability and the second probability;

[0088] Specifically, the first probability of each category is multiplied by the second probability of the subcategory to which the category belongs, to obtain the joint probability of each category to its subcategory.

[0089] It can be calculated by the following formula: ij =f i *S ij1_score

[0090] Among them, f i represents the first probability of category i, S ij1_score represents the second probability of sub-category j under category i, f ij represents the joint probability of j sub-category under i category.

[0091] Step 170: Determine the target category and target subcategory based on the joint probability.

[0092] Specifically, the category and subcategory corresponding to the joint probability with the largest value are selected from the joint probabilities as the target category and target subcategory, and each category and each subcategory has a corresponding numerical number, for example, C49.6 Malignant tumor of connective tissue and soft tissue of the trunk without specifying it, thereby realizing the processing of medical diagnosis text.

[0093] By applying the medical diagnosis text processing method provided by the embodiment of the present invention, the first probability of the category and the second probability of the subcategory are utilized, and the first probability and the second probability are jointly calculated, making the encoding process of the medical diagnosis text simpler.

[0094] In a specific implementation, assuming that the diagnosis basis text is S, in the first stage, S is mapped to M categories using keywords, and n categories {d1, d2, ..., d n}, in the second stage, all subcategories under the category {d 11 ,d 12 ,..,d n1 ,..,d nm} Perform classification prediction and output the highest joint score d in the two stages max The result is, for example:

[0095] Diagnosis text: Postoperative pleomorphic liposarcoma of the left upper arm

[0096] First-stage prediction category: C49 other malignant tumors of connective tissue and soft tissue

[0097] Candidate suborders for phase 2 input:

[0098] C49.0 Malignant neoplasm of connective and soft tissue of head, face and neck

[0099] C49.1 Malignant neoplasm of connective and soft tissue of upper limb (including shoulder)

[0100] C49.2 Malignant neoplasm of connective and soft tissue of lower limb (including hip) ...

[0102] C49.6 Malignant neoplasm of unspecified connective and soft tissue of trunk

[0103] C49.8 Overlapping malignant lesion of connective and soft tissue

[0104] C49.9 Malignant neoplasm of connective and soft tissue, unspecified

[0105] Example 2

[0106] A second embodiment of the present invention provides a medical diagnosis text processing device, which includes: an acquisition module 210 , a query module 220 , a first determination module 230 , a second determination module 240 , a processing module 250 and a third determination module 260 .

[0107] The acquisition module 210 is used to obtain the diagnosis basis text;

[0108] The query module 220 is used to obtain multiple categories mapped to the diagnosis basis text according to the diagnosis basis text and the preset keyword table; wherein the preset keyword table includes keywords and categories corresponding to the keywords;

[0109] The first determination module 230 is used to determine a first probability of each category;

[0110] The second determination module 240 is used to determine the subcategory corresponding to each category;

[0111] The processing module 250 is used to obtain a second probability of the sub-category based on the diagnosis basis text, the sub-category and the preset model;

[0112] The processing module 250 is further configured to obtain a joint probability based on the first probability and the second probability;

[0113] The third determination module 260 is used to determine the target category and the target subcategory based on the joint probability.

[0114] Furthermore, the query module 220 obtains multiple categories mapped to the diagnosis basis text according to the diagnosis basis text and the preset keyword table, specifically including: obtaining keywords of the diagnosis basis text; querying categories corresponding to keywords according to the keywords and the preset keyword table; and determining the category mapped to each keyword.

[0115] Furthermore, the first determination module 230 determines the first probability of each category specifically including: determining the first number of times each category is mapped; determining the second number of times the keyword is mapped to the category; and calculating the first probability of each category in the multiple categories based on the ratio of the first number to the second number.

[0116] Furthermore, the processing module 250 obtains the second probability of the sub-item based on the diagnosis basis text, sub-item and preset model, specifically including: segmenting the diagnosis basis text and sub-item respectively through a word segmenter to obtain a first word segmentation and a second word segmentation; encoding the first word segmentation and the second word segmentation respectively to obtain a first code and a second code; converting the first code into a first vector, and converting the second code into a second vector; splicing the first vector and the second vector, and inputting the splicing result into the preset model, and calculating through a preset function to obtain a first score of each sub-item result taking the first value and a second score of each sub-item taking the second value; and calculating the second score of each sub-item based on the first score and the second score.

[0117] Furthermore, the processing module 250 obtains the joint probability based on the first probability and the second probability, specifically including: multiplying the first probability of each category by the second probability of the subcategory to which the category belongs, to obtain the joint probability of each category to its subcategory.

[0118] Furthermore, the third determination module 260 determines the target category and target subcategory based on the joint probability, specifically including: selecting the category and subcategory corresponding to the joint probability with the largest value from the joint probabilities as the target category and target subcategory.

[0119] The device provided in the second embodiment of the present invention can execute the method steps in the above-mentioned method embodiment 1. Its implementation principle and technical effects are similar and will not be repeated here.

[0120] It should be noted that it should be understood that the division of the various modules of the above device is merely a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. Moreover, these modules can all be implemented in the form of software called by a processing element; or they can all be implemented in the form of hardware; or some modules can be implemented in the form of software called by a processing element, and some modules can be implemented in the form of hardware. For example, the determination module can be a separately established processing element, or it can be integrated into a chip of the above device. In addition, it can also be stored in the memory of the above device in the form of program code, and called by a processing element of the above device to perform the functions of the above determination module. The implementation of other modules is similar. In addition, these modules can all or partly be integrated together, or they can be implemented independently. The processing element described here can be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method or each of the above modules can be completed by the hardware integrated logic circuit in the processor element or by instructions in the form of software.

[0121] For example, the above modules may be one or more integrated circuits configured to implement the above methods, such as one or more application-specific integrated circuits (ASICs), one or more microprocessors (DSPs), or one or more field programmable gate arrays (FPGAs). For another example, when a module is implemented by scheduling program code through a processing element, the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call program code. For another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).

[0122] In the above embodiments, all or part of the embodiments may be implemented using software, hardware, firmware, or any combination thereof. When implemented using software, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The above-mentioned computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the above-mentioned computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center via wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, Bluetooth, microwave, etc.) means. The above-mentioned computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media. The above-mentioned available medium can be a magnetic medium (such as a floppy disk, hard disk, tape), an optical medium (such as a DVD), or a semiconductor medium (such as a solid state disk (SSD)), etc.

[0123] Example 3

[0124] The third embodiment of the present invention provides a chip system, such as Figure 3 As shown, it includes a processor, a coupling between the processor and a memory, the memory stores program instructions, and when the program instructions stored in the memory are executed by the processor, any one of the medical diagnosis text processing methods provided in Example 1 is implemented.

[0125] Example 4

[0126] A fourth embodiment of the present invention provides a computer-readable storage medium, such as Figure 4 As shown, it includes a program or instruction, and when the program or instruction is run on a computer, it implements any medical diagnosis text processing method provided in Example 1.

[0127] Example 5

[0128] Embodiment 5 provides a computer program product including instructions, such as Figure 5 As shown, when the computer program product is run on a computer, the computer is enabled to execute any one of the medical diagnosis text processing methods provided in Example 1.

[0129] Professionals should also be further aware that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the components and steps of each example according to their functions. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0130] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein may be implemented using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0131] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for processing medical diagnosis text, characterized in that: The method comprises: Obtain the diagnosis basis text; According to the diagnosis basis text and the preset keyword table, a plurality of categories mapped to the diagnosis basis text are obtained; wherein the preset keyword table includes keywords and categories corresponding to the keywords; Determine the first probability for each category; Determine the subcategory corresponding to each category; Obtaining a second probability of the sub-category according to the diagnosis basis text, the sub-category, and a preset model; Obtaining a joint probability according to the first probability and the second probability; Determining a target category and a target subcategory based on the joint probability; Determining the first probability of each category specifically includes: determining the first number of times each category is mapped; Determine the second number of keywords mapped to categories; Calculating a first probability of each of the multiple categories based on a ratio of the first number of times to the second number of times; The obtaining of the second probability of the sub-target according to the diagnosis basis text, the sub-target and the preset model specifically includes: Using a word segmenter, the diagnosis basis text and the sub-item are segmented to obtain a first segmentation and a second segmentation; Encode the first participle and the second participle respectively to obtain a first code and a second code; Convert the first code into a first vector, and convert the second code into a second vector; The first vector and the second vector are concatenated, and the concatenation result is input into a binary classification model based on the pre-trained BERT model, as shown below: H = BERT_Classify(I), where I is the concatenation result; After the sigmoid function calculation, it is as follows: sigmoid(H) The final result is: Among them, S ij1_score The first score of the j-th sub-category result under the i-th category is 1, S ij0_score The second score of 0 is taken for the result of the jth sub-category under the i-th category, and the first score is taken as the value of the second probability, because 1 represents this sub-category and 0 represents it is not this sub-category; The obtaining of a joint probability according to the first probability and the second probability specifically includes: Multiply the first probability of each category by the second probability of the subcategory to which the category belongs to obtain the joint probability of each category and its subcategory; Determining the target category and target subcategory based on the joint probability specifically includes: The category and subcategory corresponding to the joint probability with the largest value are selected from the joint probabilities as the target category and target subcategory.

2. The method according to claim 1, characterized in that The multiple categories of the diagnosis basis text mapping obtained according to the diagnosis basis text and the preset keyword table specifically include: Obtaining keywords of the diagnosis basis text; According to the keyword and the preset keyword table, query the category corresponding to the keyword; Determine the category for each keyword mapping.

3. A medical diagnosis text processing device, characterized in that: The device comprises: An acquisition module, wherein the acquisition module is used to acquire a diagnosis basis text; A query module, the query module being configured to obtain a plurality of categories mapped to the diagnosis basis text according to the diagnosis basis text and a preset keyword table; wherein the preset keyword table includes keywords and categories corresponding to the keywords; a first determination module, configured to determine a first probability for each category; a second determination module, configured to determine a subcategory corresponding to each category; a processing module, the processing module being configured to obtain a second probability of the sub-category based on the diagnosis basis text, the sub-category, and a preset model; The processing module is further configured to obtain a joint probability based on the first probability and the second probability; a third determination module, configured to determine a target category and a target subcategory based on the joint probability; Determining the first probability of each category specifically includes: determining the first number of times each category is mapped; Determine the second number of keywords mapped to categories; Calculating a first probability of each of the multiple categories based on a ratio of the first number of times to the second number of times; The obtaining of the second probability of the sub-target according to the diagnosis basis text, the sub-target and the preset model specifically includes: Using a word segmenter, the diagnosis basis text and the sub-item are segmented to obtain a first segmentation and a second segmentation; Encode the first participle and the second participle respectively to obtain a first code and a second code; Convert the first code into a first vector, and convert the second code into a second vector; The first vector and the second vector are concatenated, and the concatenation result is input into a binary classification model based on the pre-trained BERT model, as shown below: H = BERT_Classify(I), where I is the concatenation result; After the sigmoid function calculation, it is as follows: The final result of sigmoid(H) is: Among them, S ij1_score The first score of the j-th sub-category result under the i-th category is 1, S ij0_score The second score of 0 is taken for the result of the jth sub-category under the i-th category, and the first score is taken as the value of the second probability, because 1 represents this sub-category and 0 represents it is not this sub-category; The obtaining of a joint probability according to the first probability and the second probability specifically includes: Multiply the first probability of each category by the second probability of the subcategory to which the category belongs to obtain the joint probability of each category and its subcategory; Determining the target category and target subcategory based on the joint probability specifically includes: The category and subcategory corresponding to the joint probability with the largest value are selected from the joint probabilities as the target category and target subcategory.

4. A chip system, characterized in that: The invention comprises a processor coupled to a memory, wherein the memory stores program instructions, and when the program instructions stored in the memory are executed by the processor, the medical diagnosis text processing method according to claim 1 is implemented.

5. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the medical diagnosis text processing method according to claim 1.

6. A computer program product, characterized in that When the computer program product is run on a computer, the computer is caused to execute the medical diagnosis text processing method according to claim 1 .

Citation Information

Patent Citations

  • Medical record file coding method, server, and computer readable storage medium

    CN109493931A

  • Text processing method and device, equipment and storage medium

    CN114328807A