A medical record entity-based surgical operation coding generation method, device and equipment

CN122337454BActive Publication Date: 2026-10-30ATHENAEYES CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610757071.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-05-29
Publication Date
2026-10-30
Estimated Expiration
2046-05-29

AI Technical Summary

Technical Problem

[0004]本申请实施例提供一种基于病历实体的手术操作编码生成方法、装置及设备,以解决上述如何输出待查询病历的手术操作编码,不利于提高手术操作编码生成效率的技术问题

Benefits of technology

第一方面,将匹配评分大于预设评分的多个候选实体组成标准化医学实体数据,基于标准化医学实体数据、医学知识库和大语言模型,输出待查询病历的手术操作编码,由于无需人工研读待查询病历,因此减少了待查询病历的手术操作编码的输出时间,有利于提高待查询病历的手术操作编码的输出效率;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122337454B_ABST
    Figure CN122337454B_ABST
Patent Text Reader

Abstract

The application relates to the fields of artificial intelligence and medical informatization, and discloses a surgery operation coding generation method, device and equipment based on medical record entities, which comprises the following steps: clinical text is disassembled into multiple medical record entities, and an embedding vector corresponding to each medical record entity is generated; a fusion feature vector of a to-be-inquired medical record is generated according to the embedding vector corresponding to each medical record entity; the similarity between the fusion feature vector of the to-be-inquired medical record and each standard term vector is generated; multiple standard term vectors with a similarity greater than a preset value are selected as multiple candidate term vectors, and each candidate term vector corresponding entity is selected as each candidate entity; multiple candidate entities with a matching score greater than a preset score are combined to form standardized medical entity data, and based on the standardized medical entity data, a medical knowledge base and a large language model, a surgery operation coding of the to-be-inquired medical record is output. The application can improve the reliability of the surgery operation coding of the to-be-inquired medical record.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the fields of artificial intelligence technology and medical information technology, and in particular to a method, apparatus and equipment for generating surgical operation codes based on medical record entities. Background Technology

[0002] With the rapid advancement of healthcare informatization, data sharing and business collaboration among various healthcare platforms are becoming increasingly close. Surgical operation codes in medical records to be queried serve as standardized identifiers, enabling different healthcare platforms to record and parse data based on the same rules. This eliminates comprehension barriers caused by language and rule differences, facilitating data sharing.

[0003] However, the current surgical operation codes for medical records to be queried require staff to study each medical record individually and then compare them with the coding standard library to compile the surgical operation codes for the medical records to be queried. This consumes a lot of human and time resources and increases the output time of the surgical operation codes for the medical records to be queried. Therefore, how to output the surgical operation codes for the medical records to be queried is a technical problem that urgently needs to be solved. Summary of the Invention

[0004] This application provides a method, apparatus, and device for generating surgical operation codes based on medical record entities, in order to solve the aforementioned technical problem of how to output the surgical operation codes of the medical records to be queried, which is not conducive to improving the efficiency of surgical operation code generation.

[0005] In a first aspect, embodiments of this application provide a method for generating surgical operation codes based on medical record entities, applied to electronic devices, the surgical operation code generation method comprising: Obtain clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity; Based on the embedding vector corresponding to each medical record entity and the predefined fusion model, a fusion feature vector of the medical record to be queried is generated. Based on a predefined similarity model, generate the similarity between the fused feature vector of the medical record to be queried and the vector of each standard term; Multiple standard term vectors with similarity greater than a preset value are selected as multiple candidate term vectors. The entity corresponding to each candidate term vector is selected as a candidate entity. Based on each medical record entity, each candidate entity and a predefined matching model, a matching score is generated between each medical record entity and each candidate entity. Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output.

[0006] In one possible implementation of the first aspect, clinical text is obtained, decomposed into multiple medical record entities, each medical record entity is encoded, and an embedding vector corresponding to each medical record entity is generated, including: Obtain the medical record to be queried, extract the clinical text from the medical record to be queried, and decompose the clinical text according to multiple preset subdivisions to generate multiple medical record entities; Each medical record entity is input into the encoding model, and the encoding model is used to encode each medical record entity to generate an embedding vector corresponding to each medical record entity.

[0007] In one possible implementation of the first aspect, multiple candidate entities with matching scores greater than a preset score are grouped into standardized medical entity data. Based on the standardized medical entity data, a medical knowledge base, and a large language model, the surgical operation code of the medical record to be queried is output, including: Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. The fusion features of the medical record to be queried are concatenated with the standardized medical entity data to generate the target feature vector of the medical record to be queried. The target feature vector of the medical record to be queried is submitted to the query interface of the medical knowledge base. The target feature vector of the medical record to be queried is queried in the medical knowledge base through the query interface to generate the surgical coding knowledge of the medical record to be queried. The fusion features of the medical record to be queried, the text features of the standard terminology of the medical record to be queried, and the surgical coding knowledge of the medical record to be queried are input into the big language model. The big language model generates the surgical operation code of the medical record to be queried. The scoring model generates the comprehensive confidence score of the surgical operation code. Based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the output value of the agent is generated. When the output value is 0, the surgical operation code of the medical record to be queried will be output to the medical information system.

[0008] In one possible implementation of the first aspect, after inputting the fusion features of the medical record to be queried, the textual features of the standard terms of the medical record to be queried, and the surgical coding knowledge of the medical record to be queried into a large language model, generating the surgical operation code of the medical record to be queried through the large language model, generating a comprehensive confidence score of the surgical operation code through a scoring model, and generating the output value of the agent based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the surgical operation code generation method further includes: When the output value is 1, a dialog window is created, the missing information of the medical record to be queried is obtained from the dialog window, the missing information of the medical record to be queried is input into the large language model, the surgical coding knowledge of the medical record to be queried is corrected by the large language model, the corrected surgical operation code of the medical record to be queried is generated, and the corrected surgical operation code of the medical record to be queried is output to the medical information system.

[0009] In one possible implementation of the first aspect, the fusion model is defined as follows: ; ; This is the fusion feature vector of the medical record to be queried; Represents the normalization function; Indicates the number of medical record entities; The weighting coefficients for the i-th medical record entity learned through the attention network; The projection matrix; This represents the embedding vector corresponding to the i-th medical record entity; b represents the bias term, which is a common learnable parameter in the linear transformation of a neural network, used to improve the model's fitting ability.

[0010] This represents the query vector for the i-th medical record entity. This represents the key vector of the i-th medical record entity. The transpose of the key vector of the i-th medical record entity; This represents the dot product between the query vector of i medical record entities and the transpose of the key vectors of i medical record entities. It represents the square root of the length of the key vector.

[0011] In one possible implementation of the first aspect, the similarity model is defined as follows: ; This represents the similarity between the fused feature vector of the medical record to be queried and the vector of the Kth standard term; This represents the inner product of the fused feature vector of the medical record to be queried and the vector of the Kth standard term, used to measure the degree of overlap between the fused feature vector of the medical record to be queried and the vector of the Kth standard term in terms of dimensions. The larger the inner product between the fusion feature vector of the medical record to be queried and the Kth standard term vector, the higher the degree of overlap between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension; the smaller the inner product between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension, the lower the degree of overlap between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension. This represents the fusion feature vector of the medical record to be queried; Represents the vector of the Kth standard term; This represents the L2 norm of the fused feature vector of the medical record to be queried; Let L2 norm be the vector of the Kth standard term.

[0012] In one possible implementation of the first aspect, the matching model is defined as follows: ; This represents the matching score between the i-th medical record entity and the m-th candidate entity. The higher the matching score between the i-th medical record entity and the m-th candidate entity, the higher the matching degree between the i-th medical record entity and the m-th candidate entity; the lower the matching score between the i-th medical record entity and the m-th candidate entity, the lower the matching degree between the i-th medical record entity and the m-th candidate entity. Indicates the activation function; Indicates a splicing operation; Indicates to and Perform the splicing operation to generate and The concatenated vector; The weight matrix representing the classification heads; This represents the encoding component in the Cross-Encoder model; Represents the embedding vector of the i-th medical record entity; This represents the embedding vector of the m-th candidate entity; This represents the bias term of the classification head, used to adjust the baseline threshold for network classification.

[0013] In one possible implementation of the first aspect, the scoring model is defined as follows: ; This represents the overall confidence score of the surgical procedure code; a higher overall confidence score indicates a higher level of confidence in the surgical procedure code, and a lower overall confidence score indicates a lower level of confidence in the surgical procedure code. Indicates the length of the surgical procedure code; This indicates the first in the surgical procedure code. One character; Its function is to apply length penalty and normalize the surgical procedure code to prevent the overall confidence score from being artificially high due to the shortness of the surgical procedure code; This indicates the preceding character, which is all characters whose ordinal number is less than ordinal number; This indicates the medical record to be queried; Represents a set of medical record entities; This represents the conditional probability of generating the current i-th character in the autoregressive generation process of a large language model, given the input conditions and the previously generated preceding characters. The decision function is defined as follows: ; This represents the output value of the agent; The overall confidence score representing the surgical procedure code; This indicates the preset scoring threshold.

[0014] Secondly, embodiments of this application provide a surgical procedure code generation device based on medical record entities, applied to electronic devices, including: The acquisition module is used to acquire clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity. The first generation module is used to generate the fusion feature vector of the medical record to be queried based on the embedding vector corresponding to each medical record entity and the predefined fusion model. The second generation module is used to generate the similarity between the fusion feature vector of the medical record to be queried and each standard term vector according to the predefined similarity model. The matching module is used to select multiple standard term vectors with similarity greater than a preset value as multiple candidate term vectors, select the entity corresponding to each candidate term vector as a candidate entity, and generate a matching score between each medical record entity and each candidate entity based on each medical record entity, each candidate entity and a predefined matching model. The output module is used to combine multiple candidate entities with matching scores greater than preset scores into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, it outputs the surgical operation code of the medical record to be queried.

[0015] Thirdly, embodiments of this application provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the surgical operation code generation method described in the first aspect above.

[0016] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the surgical operation code generation method described in the first aspect above.

[0017] Fifthly, embodiments of this application provide a computer program product that, when run on an electronic device, causes the electronic device to execute the surgical operation code generation method described in the first aspect.

[0018] The beneficial effects of the embodiments of this application are as follows: Firstly, multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output. Since there is no need for manual reading of the medical record to be queried, the output time of the surgical operation code of the medical record to be queried is reduced, which is conducive to improving the output efficiency of the surgical operation code of the medical record to be queried. Secondly, since the surgical operation code of the medical record to be queried is automatically output, it is not affected by human intervention, which helps to improve the reliability of the surgical operation code of the medical record to be queried. Attached Figure Description

[0019] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0020] Figure 1 This is an application scenario diagram of the surgical operation code generation method provided in the embodiments of this application; Figure 2 This is a flowchart illustrating the surgical operation code generation method provided in the embodiments of this application; Figure 3 A flowchart illustrating the implementation of S201 provided in this application embodiment; Figure 4 A schematic block diagram of a surgical operation code generation device provided in an embodiment of this application; Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0021] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.

[0022] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.

[0023] It should be understood that in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance. The terms "comprising," "including," "having," and their variations all mean "including but not limited to," unless otherwise specifically emphasized.

[0024] Furthermore, the technical solutions of the various embodiments can be combined with each other, but only if they are based on the ability of those skilled in the art to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such combination of technical solutions does not exist and is not within the scope of protection claimed in this application.

[0025] The flowchart shown in the attached diagram is for illustrative purposes only and does not necessarily include all content and operations / steps, nor does it necessarily have to be performed in the order described. For example, some operations / steps can be broken down, combined, or partially merged, so the actual execution order may change depending on the actual situation.

[0026] The surgical operation code generation method provided in this application embodiment can be applied to electronic devices, including but not limited to servers, mobile phones, tablets, wearable devices, vehicle-mounted devices, and laptops. This application embodiment does not impose any restrictions on the specific type of electronic device.

[0027] Please see Figure 1 , Figure 1 The application scenario diagram of the surgical operation code generation method provided in the embodiments of this application is described in detail below: The electronic device connects to the medical information system, retrieves the medical records to be queried from the medical information system, extracts the clinical text from the medical records to be queried, and decomposes the clinical text according to multiple preset subdivisions to generate multiple medical record entities.

[0028] The number of subdivisions can be dynamically increased or decreased according to actual needs, and there is no limit to this.

[0029] For ease of explanation, the following example is provided: For example, when the number of subdivisions is 7, the clinical text is decomposed according to the 7 subdivisions to generate multiple medical record entities. The multiple medical record entities are: surgery name, surgical side, specific surgical location, subdivision of surgical segment, core surgical operation, surgical resection range, and anastomosis and reconstruction method.

[0030] For example, when the number of subdivisions is 18, the clinical text is decomposed according to the 18 subdivisions to generate multiple medical record entities. The multiple medical record entities are: surgical name, surgical side, specific surgical location, subdivision of surgical segment, core surgical operation, surgical resection range, anastomosis and reconstruction method, surgical approach, surgical method, anesthesia method, operation duration, surgical grade, combined surgery, type of surgical instruments and consumables, special intraoperative treatment, intraoperative complications, surgical indications, and intraoperative implant information.

[0031] Surgical name: The full official name of the procedure.

[0032] Surgical side: The lateral direction in which the surgical procedure takes place, such as left, right, or both sides.

[0033] Specific surgical site: The main anatomical organ or structure where the surgical procedure takes place, such as the stomach, liver, or lungs.

[0034] Surgical segmentation: Further refined localization based on specific locations, such as the gastric antrum or the left lobe of the liver.

[0035] Core surgical procedures: Key technical actions taken during surgery to remove lesions or achieve therapeutic goals, such as resection, anastomosis, and clearance.

[0036] Surgical resection extent: A description of the boundaries or volume of the tissue to be removed, such as total resection, partial resection, or extended resection.

[0037] Anastomosis and reconstruction methods: methods for restoring the continuity of the duct or reconstructing the structural function after resection.

[0038] Surgical approach: The path or incision method by which the surgery reaches the target area, such as transabdominal or transthoracic surgery.

[0039] Surgical method: The overall technical category or operation mode of the surgery, such as open surgery, laparoscopic surgery, and robotic surgery.

[0040] Anesthesia method: The anesthetic technique used during the operation, such as general anesthesia or epidural anesthesia.

[0041] Surgical duration: The actual operation time from skin incision to suturing completion, usually measured in minutes.

[0042] Surgical grading: A classification system based on the difficulty, complexity, and risk of a surgery, such as Level 1, Level 2, Level 3, and Level 4.

[0043] Combined surgery: Other non-major surgical procedures performed concurrently with this surgery, such as cholecystectomy.

[0044] Surgical instrument and consumable type: The category of the main instruments or disposable consumables used in surgery, such as ultrasonic scalpel and stapler.

[0045] Special intraoperative procedures: unconventional or additional procedures performed during the operation, such as intraoperative frozen section pathology and fluorescence imaging.

[0046] Intraoperative complications: Unexpected adverse events that occur during the operation, such as hypotension and pneumothorax.

[0047] Surgical indications: The medical reasons or diagnostic basis for performing the surgery, such as gastric adenocarcinoma or fracture.

[0048] Intraoperative implant information: Foreign body materials inserted into the body during surgery and not usually removed, along with related parameters, such as artificial joint prostheses and absorbable screws.

[0049] Among them, medical information systems refer to computer systems deployed in medical institutions for the collection, storage, processing, and transmission of medical data.

[0050] In this embodiment of the application, the electronic device is connected to the medical information system and obtains the medical records to be queried from the medical information system, saving the time of obtaining the medical records to be queried and improving the efficiency of obtaining the medical records to be queried.

[0051] Please see Figure 2 , Figure 2 This is a flowchart illustrating the surgical operation code generation method provided in this application embodiment, which can be applied to electronic devices.

[0052] like Figure 2 As shown, the surgical operation code generation method provided in this application includes the following steps, detailed below: S201, Obtain clinical text, decompose clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity; Clinical texts refer to textual data generated during clinical diagnosis and treatment activities, which record the patient's condition, treatment process, and medical behaviors in natural language.

[0053] S202, Based on the embedding vector corresponding to each medical record entity and the predefined fusion model, generate the fusion feature vector of the medical record to be queried; The fusion model is defined as follows: ; ; This is the fusion feature vector of the medical record to be queried; Represents the normalization function; Indicates the number of medical record entities; The weighting coefficients for the i-th medical record entity learned through the attention network; The projection matrix; This represents the embedding vector corresponding to the i-th medical record entity; b represents the bias term, which is a common learnable parameter in the linear transformation of a neural network, used to improve the model's fitting ability.

[0054] This represents the query vector for the i-th medical record entity. This represents the key vector of the i-th medical record entity. The transpose of the key vector of the i-th medical record entity; This represents the dot product between the query vector of i medical record entities and the transpose of the key vectors of i medical record entities. It represents the square root of the length of the key vector.

[0055] A projection matrix is ​​a linear transformation matrix that maps a vector from a high-dimensional space to a low-dimensional space.

[0056] S203, Based on a predefined similarity model, generate the similarity between the fused feature vector of the medical record to be queried and the vector of each standard term; The similarity model is defined as follows: ; This represents the similarity between the fused feature vector of the medical record to be queried and the vector of the Kth standard term; This represents the inner product of the fused feature vector of the medical record to be queried and the Kth standard term vector. It is used to measure the degree of overlap between the fused feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension. The larger the inner product between the fused feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension, the higher the degree of overlap between the fused feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension. The smaller the inner product between the fused feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension, the lower the degree of overlap between the fused feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension. This represents the fusion feature vector of the medical record to be queried; Represents the vector of the Kth standard term; This represents the L2 norm of the fused feature vector of the medical record to be queried; Let L2 norm be the vector of the Kth standard term.

[0057] S204: Select multiple standard term vectors with similarity greater than a preset value as multiple candidate term vectors, select the entity corresponding to each candidate term vector as each candidate entity, and generate a matching score between each medical record entity and each candidate entity based on each medical record entity, each candidate entity and a predefined matching model. The matching model is defined as follows: ; This represents the matching score between the i-th medical record entity and the m-th candidate entity. The higher the matching score between the i-th medical record entity and the m-th candidate entity, the higher the matching degree between the i-th medical record entity and the m-th candidate entity; the lower the matching score between the i-th medical record entity and the m-th candidate entity, the lower the matching degree between the i-th medical record entity and the m-th candidate entity. Indicates the activation function; Indicates a splicing operation; Indicates to and Perform the splicing operation to generate and The concatenated vector; The weight matrix representing the classification heads; This represents the encoding component in the Cross-Encoder model; Represents the embedding vector of the i-th medical record entity; This represents the embedding vector of the m-th candidate entity; This represents the bias term of the classification head, used to adjust the baseline threshold for network classification.

[0058] Among them, the Cross-Encoder model is a semantic matching architecture based on deep neural networks.

[0059] S205: Combine multiple candidate entities with matching scores greater than the preset score into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base, and large language model, output the surgical operation code of the medical record to be queried.

[0060] Specifically, multiple candidate entities with matching scores greater than a preset score are grouped into standardized medical entity data. Based on this standardized medical entity data, a medical knowledge base, and a large language model, the surgical operation code for the queried medical record is output, including: Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. The fusion features of the medical record to be queried are concatenated with the standardized medical entity data to generate the target feature vector of the medical record to be queried. The target feature vector of the medical record to be queried is submitted to the query interface of the medical knowledge base. The target feature vector of the medical record to be queried is queried in the medical knowledge base through the query interface to generate the surgical coding knowledge of the medical record to be queried. The fusion features of the medical record to be queried, the text features of the standard terminology of the medical record to be queried, and the surgical coding knowledge of the medical record to be queried are input into the big language model. The big language model generates the surgical operation code of the medical record to be queried. The scoring model generates the comprehensive confidence score of the surgical operation code. Based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the output value of the agent is generated. When the output value is 0, the surgical operation code of the medical record to be queried will be output to the medical information system.

[0061] The scoring model is defined as follows: ; This represents the overall confidence score of the surgical procedure code; a higher overall confidence score indicates a higher level of confidence in the surgical procedure code, and a lower overall confidence score indicates a lower level of confidence in the surgical procedure code. Indicates the length of the surgical procedure code; This indicates the first in the surgical procedure code. One character; Its function is to apply length penalty and normalize the surgical procedure code to prevent the overall confidence score from being artificially high due to the shortness of the surgical procedure code; This indicates the preceding character, which is all characters whose ordinal number is less than ordinal number; This indicates the medical record to be queried; Represents a set of medical record entities; This represents the conditional probability of generating the current i-th character in the autoregressive generation process of a large language model, given the input conditions and the previously generated preceding characters. The decision function is defined as follows: ; This represents the output value of the agent; The overall confidence score representing the surgical procedure code; This indicates the preset scoring threshold.

[0062] The surgical operation code generation method further includes, after inputting the fusion features of the medical record to be queried, the textual features of the standard terminology of the medical record to be queried, and the surgical coding knowledge of the medical record to be queried into a large language model, generating the surgical operation code of the medical record to be queried through the large language model, generating a comprehensive confidence score of the surgical operation code through a scoring model, and generating the output value of the agent based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the surgical operation code generation method further includes: When the output value is 1, a dialog window is created, the missing information of the medical record to be queried is obtained from the dialog window, the missing information of the medical record to be queried is input into the large language model, the surgical coding knowledge of the medical record to be queried is corrected by the large language model, the corrected surgical operation code of the medical record to be queried is generated, and the corrected surgical operation code of the medical record to be queried is output to the medical information system.

[0063] The medical knowledge base refers to a knowledge base built based on surgical procedure classification standards. The medical knowledge base includes standard surgical names, classification codes, and terminology mapping relationships.

[0064] The classification criteria for surgical procedures include ICD-9-CM-3. ICD-9-CM-3 is the third volume of the clinical revision of the International Classification of Diseases (9th edition), specifically used for the classification and coding of surgical procedures.

[0065] When the output value is 0, the surgical operation code of the medical record to be queried is output to the medical information system, which can reduce human coding errors caused by memory bias or inconsistent understanding of standards, thereby improving the accuracy and consistency of the surgical operation code of the medical record to be queried.

[0066] For ease of explanation, the following example is provided: Taking medical record A as an example, the surgical operation code generation method of this application generates a surgical operation code for medical record A and automatically pushes it to the medical information system. After receiving it, the medical information system fills the surgical operation code of medical record A back into the surgical code field of medical record A in real time. The coder in the medical records room can complete the entry of medical record A without manually consulting the code book. At the same time, the surgical operation code of medical record A is automatically and synchronously pushed to the medical insurance settlement system. The medical insurance settlement personnel can complete the cost calculation of medical record A in real time without waiting for the coder to re-enter it afterward. It can be seen that automatic push realizes single coding and multiple reuse, which improves the accuracy of the surgical operation code of medical record A from the source.

[0067] The beneficial effects of the embodiments of this application are as follows: Firstly, multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output. Since there is no need for manual reading of the medical record to be queried, the output time of the surgical operation code of the medical record to be queried is reduced, which is conducive to improving the output efficiency of the surgical operation code of the medical record to be queried. Secondly, since the surgical operation code of the medical record to be queried is automatically output, it is not affected by human intervention, which helps to improve the reliability of the surgical operation code of the medical record to be queried.

[0068] Please see Figure 3 , Figure 3 The implementation flowchart of S201 provided in the embodiments of this application is described in detail below: S301, Obtain the medical record to be queried, extract the clinical text from the medical record to be queried, decompose the clinical text according to multiple preset subdivisions, and generate multiple medical record entities; The system retrieves the medical record to be queried, extracts the clinical text from the medical record, and decomposes the clinical text according to multiple preset subdivisions to generate multiple medical record entities, including: Connect to the medical information system, retrieve the medical records to be queried from the medical information system, extract the clinical text from the medical records to be queried, and decompose the clinical text according to multiple preset subdivisions to generate multiple medical record entities.

[0069] S302, input each medical record entity into the encoding model, use the encoding model to encode each medical record entity, and generate the embedding vector corresponding to each medical record entity.

[0070] The encoding model is a pre-trained encoder. Pre-trained encoders are better able to capture semantic information, contextual dependencies, and domain-specific knowledge in text.

[0071] In the embodiments of this application, the embedding vectors corresponding to each medical record entity have the same dimension, which enables the fusion model to efficiently integrate the embedding vectors corresponding to each medical record entity.

[0072] For the surgical procedure code generation method described in the above embodiments, please refer to [link / reference]. Figure 4 , Figure 4 This is a schematic block diagram of the surgical operation code generation device provided in the embodiments of this application. Figure 4 The surgical procedure code generation device 400 shown can be applied to, for example... Figure 1 The application scenario diagram shows electronic devices. The following section uses electronic devices as an example to illustrate this. Figure 4 The surgical operation code generation device 400 shown will be described in detail. The surgical operation code generation device 400 may include an acquisition module 401, a first generation module 402, a second generation module 403, a matching module 404, and an output module 405.

[0073] The acquisition module 401 is used to acquire clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity. The first generation module 402 is used to generate a fusion feature vector of the medical record to be queried based on the embedding vector corresponding to each medical record entity and a predefined fusion model. The second generation module 403 is used to generate the similarity between the fusion feature vector of the medical record to be queried and each standard term vector according to the predefined similarity model. The matching module 404 is used to select multiple standard term vectors with similarity greater than a preset value as multiple candidate term vectors, select the entity corresponding to each candidate term vector as a candidate entity, and generate a matching score between each medical record entity and each candidate entity based on each medical record entity, each candidate entity and a predefined matching model. Output module 405 is used to combine multiple candidate entities with matching scores greater than preset scores into standardized medical entity data, and output the surgical operation code of the medical record to be queried based on the standardized medical entity data, medical knowledge base and large language model.

[0074] It should be noted that the various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.

[0075] The beneficial effects of the embodiments of this application are as follows: Firstly, multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output. Since there is no need for manual reading of the medical record to be queried, the output time of the surgical operation code of the medical record to be queried is reduced, which is conducive to improving the output efficiency of the surgical operation code of the medical record to be queried. Secondly, since the surgical operation code of the medical record to be queried is automatically output, it is not affected by human intervention, which helps to improve the reliability of the surgical operation code of the medical record to be queried.

[0076] Please see Figure 5 , Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.

[0077] like Figure 5 As shown, Figure 5 The electronic device includes: at least one processor 20, a memory 21, and a computer program 22 stored in the memory 21 and executable on the at least one processor 20, wherein the processor 20 executes the computer program 22 to implement the steps in any of the above method embodiments.

[0078] The electronic device may include, but is not limited to, processor 20 and memory 21. Those skilled in the art will understand that... Figure 5 This is merely an example of an electronic device and does not constitute a limitation on electronic devices. It may include more or fewer components than shown in the illustration, or combinations of certain components, or different components. For example, it may also include input / output devices, network access devices, etc.

[0079] The processor 20 is used to run a computer program 22 stored in the memory 21, and performs the following steps when executing the computer program 22: Obtain clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity; Based on the embedding vector corresponding to each medical record entity and the predefined fusion model, a fusion feature vector of the medical record to be queried is generated. Based on a predefined similarity model, the similarity between the fused feature vector of the medical record to be queried and the vector of each standard term is generated. Multiple standard term vectors with similarity greater than a preset value are selected as multiple candidate term vectors. The entity corresponding to each candidate term vector is selected as a candidate entity. Based on each medical record entity, each candidate entity and a predefined matching model, a matching score is generated between each medical record entity and each candidate entity. Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output.

[0080] The processor 20 may be a Central Processing Unit (CPU), or it may be other general-purpose processors, digital signal processors, field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.

[0081] In some embodiments, the memory 21 may be an internal storage unit of the electronic device, such as a hard disk or memory of the electronic device. In other embodiments, the memory 21 may also be an external storage device of the electronic device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc. equipped on the electronic device.

[0082] Furthermore, the memory 21 may include both internal storage units and external storage devices of the electronic device. The memory 21 is used to store the operating system, applications, boot loader, data, and other programs, such as the program code of the computer program. The memory 21 can also be used to temporarily store data that has been output or will be output.

[0083] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, and they will not be repeated here.

[0084] This application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.

[0085] The computer-readable storage medium may also be an external storage device of the surgical operation code generation device or electronic device, such as a plug-in hard drive, smart media card (SMC), secure digital (SD) card, flash card, or non-transitory computer-readable storage medium equipped on the surgical operation code generation device or electronic device.

[0086] Since the computer program stored in the computer-readable storage medium can execute any of the surgical operation code generation methods based on medical record entities provided in the embodiments of this application, the computer-readable storage medium can achieve the beneficial effects that any of the surgical operation code generation methods based on medical record entities provided in the embodiments of this application can achieve, as detailed in the preceding embodiments, and will not be repeated here.

[0087] This application provides a computer program product that, when run on an electronic device, causes the electronic device to execute the surgical operation code generation method described above.

[0088] When a computer program is loaded into an electronic device, it can perform the following steps: Obtain clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity; Based on the embedding vector corresponding to each medical record entity and the predefined fusion model, a fusion feature vector of the medical record to be queried is generated. Based on a predefined similarity model, the similarity between the fused feature vector of the medical record to be queried and the vector of each standard term is generated. Multiple standard term vectors with similarity greater than a preset value are selected as multiple candidate term vectors. The entity corresponding to each candidate term vector is selected as a candidate entity. Based on each medical record entity, each candidate entity and a predefined matching model, a matching score is generated between each medical record entity and each candidate entity. Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. Based on the standardized medical entity data, medical knowledge base and large language model, the surgical operation code of the medical record to be queried is output.

[0089] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium.

[0090] Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium includes: an entity or device for carrying computer program code to an electronic device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium.

[0091] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0092] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A method for generating surgical operation codes based on medical record entities, characterized in that, The surgical procedure code generation method, applied to electronic devices, includes: Obtain clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity; Based on the embedding vector corresponding to each medical record entity and the predefined fusion model, a fusion feature vector of the medical record to be queried is generated. Based on a predefined similarity model, the similarity between the fused feature vector of the medical record to be queried and the vector of each standard term is generated. Multiple standard term vectors with similarity greater than a preset value are selected as multiple candidate term vectors. The entity corresponding to each candidate term vector is selected as a candidate entity. Based on each medical record entity, each candidate entity and a predefined matching model, a matching score is generated between each medical record entity and each candidate entity. Multiple candidate entities with matching scores greater than the preset score are combined into standardized medical entity data. The fusion features of the medical record to be queried are concatenated with the standardized medical entity data to generate the target feature vector of the medical record to be queried. The target feature vector of the medical record to be queried is submitted to the query interface of the medical knowledge base. The target feature vector of the medical record to be queried is queried in the medical knowledge base through the query interface to generate the surgical code knowledge of the medical record to be queried. The fusion features of the medical record to be queried, the text features of the standard terminology of the medical record to be queried, and the surgical code knowledge of the medical record to be queried are input into the large language model. The large language model generates the surgical operation code of the medical record to be queried. Through the scoring model, the comprehensive confidence score of the surgical operation code is generated. Based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the output value of the agent is generated. When the output value is 0, the surgical operation code of the medical record to be queried is output to the medical information system. The scoring model is defined as follows: ; This represents the overall confidence score of the surgical procedure code; a higher overall confidence score indicates a higher level of confidence in the surgical procedure code, and a lower overall confidence score indicates a lower level of confidence in the surgical procedure code. Indicates the length of the surgical procedure code; This indicates the first in the surgical procedure code. One character; Its function is to apply length penalty and normalize the surgical procedure code to prevent the overall confidence score from being artificially high due to the shortness of the surgical procedure code; This represents the preceding character, which is the character whose sequence number is less than or equal to 1. All characters; This indicates the medical record to be queried; Represents a set of medical record entities; This indicates that in the autoregressive generation process of a large language model, given the input conditions and the previously generated preceding characters, the current character is generated. The conditional probability of each character; The decision function is defined as follows: ; This represents the output value of the agent; The overall confidence score representing the surgical procedure code; This indicates the preset scoring threshold.

2. The surgical procedure code generation method according to claim 1, characterized in that, Obtain clinical text, decompose it into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity, including: Obtain the medical record to be queried, extract the clinical text from the medical record to be queried, and decompose the clinical text according to multiple preset subdivisions to generate multiple medical record entities; Each medical record entity is input into the encoding model, and the encoding model is used to encode each medical record entity to generate an embedding vector corresponding to each medical record entity.

3. The surgical operation code generation method according to claim 1, characterized in that, After inputting the fusion features of the medical record to be queried, the textual features of the standard terminology of the medical record to be queried, and the surgical coding knowledge of the medical record to be queried into a large language model, generating the surgical operation code of the medical record to be queried through the large language model, generating a comprehensive confidence score of the surgical operation code through a scoring model, and generating the output value of the agent based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, the surgical operation code generation method further includes: When the output value is 1, a dialog window is created, the missing information of the medical record to be queried is obtained from the dialog window, the missing information of the medical record to be queried is input into the large language model, the surgical coding knowledge of the medical record to be queried is corrected by the large language model, the corrected surgical operation code of the medical record to be queried is generated, and the corrected surgical operation code of the medical record to be queried is output to the medical information system.

4. The surgical operation code generation method according to claim 1, characterized in that, The fusion model is defined as follows: ; ; This is the fusion feature vector of the medical record to be queried; Represents the normalization function; Indicates the number of medical record entities; The weighting coefficients for the i-th medical record entity learned through the attention network; The projection matrix; This represents the embedding vector corresponding to the i-th medical record entity; b represents the bias term, which is a common learnable parameter in the linear transformation of a neural network and is used to improve the model's fitting ability. This represents the query vector for the i-th medical record entity. This represents the key vector of the i-th medical record entity. The transpose of the key vector of the i-th medical record entity; This represents the dot product between the query vector of i medical record entities and the transpose of the key vectors of i medical record entities; It represents the square root of the length of the key vector.

5. The surgical procedure code generation method according to claim 1, characterized in that, The similarity model is defined as follows: ; This represents the similarity between the fused feature vector of the medical record to be queried and the vector of the Kth standard term; This represents the inner product of the fused feature vector of the medical record to be queried and the vector of the Kth standard term, used to measure the degree of overlap between the fused feature vector of the medical record to be queried and the vector of the Kth standard term in terms of dimensions. The larger the inner product between the fusion feature vector of the medical record to be queried and the Kth standard term vector, the higher the degree of overlap between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension; the smaller the inner product between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension, the lower the degree of overlap between the fusion feature vector of the medical record to be queried and the Kth standard term vector in terms of dimension. This represents the fusion feature vector of the medical record to be queried; Represents the vector of the Kth standard term; This represents the L2 norm of the fused feature vector of the medical record to be queried; Let L2 norm be the vector of the Kth standard term.

6. The surgical procedure code generation method according to claim 1, characterized in that, The matching model is defined as follows: ; This represents the matching score between the i-th medical record entity and the m-th candidate entity. The higher the matching score between the i-th medical record entity and the m-th candidate entity, the higher the matching degree between the i-th medical record entity and the m-th candidate entity; the lower the matching score between the i-th medical record entity and the m-th candidate entity, the lower the matching degree between the i-th medical record entity and the m-th candidate entity. Indicates the activation function; Indicates a splicing operation; Indicates to and Perform the splicing operation to generate and The concatenated vector; The weight matrix representing the classification heads; This represents the encoding component in the Cross-Encoder model; Represents the embedding vector of the i-th medical record entity; This represents the embedding vector of the m-th candidate entity; This represents the bias term of the classification head, used to adjust the baseline threshold for network classification.

7. A surgical procedure code generation device based on medical record entities, characterized in that, Applied to electronic devices, including: The acquisition module is used to acquire clinical text, decompose the clinical text into multiple medical record entities, encode each medical record entity, and generate an embedding vector corresponding to each medical record entity. The first generation module is used to generate the fusion feature vector of the medical record to be queried based on the embedding vector corresponding to each medical record entity and the predefined fusion model. The second generation module is used to generate the similarity between the fusion feature vector of the medical record to be queried and each standard term vector according to the predefined similarity model. The matching module is used to select multiple standard term vectors with similarity greater than a preset value as multiple candidate term vectors, select the entity corresponding to each candidate term vector as a candidate entity, and generate a matching score between each medical record entity and each candidate entity based on each medical record entity, each candidate entity and a predefined matching model. The output module is used to combine multiple candidate entities with matching scores greater than preset scores into standardized medical entity data. It concatenates the fusion features of the medical record to be queried with the standardized medical entity data to generate the target feature vector of the medical record to be queried. It submits the target feature vector of the medical record to the query interface of the medical knowledge base. Through the query interface, it queries the target feature vector of the medical record to be queried in the medical knowledge base to generate the surgical code knowledge of the medical record to be queried. It inputs the fusion features of the medical record to be queried, the text features of the standard terminology of the medical record to be queried, and the surgical code knowledge of the medical record to be queried into the large language model. The large language model generates the surgical operation code of the medical record to be queried. Through the scoring model, it generates the comprehensive confidence score of the surgical operation code. Based on the comprehensive confidence score of the surgical operation code and the decision function of the agent, it generates the output value of the agent. When the output value is 0, the surgical operation code of the medical record to be queried is output to the medical information system. The scoring model is defined as follows: ; This represents the overall confidence score of the surgical procedure code; a higher overall confidence score indicates a higher level of confidence in the surgical procedure code, and a lower overall confidence score indicates a lower level of confidence in the surgical procedure code. Indicates the length of the surgical procedure code; This indicates the first in the surgical procedure code. One character; Its function is to apply length penalty and normalize the surgical procedure code to prevent the overall confidence score from being artificially high due to the shortness of the surgical procedure code; This represents the preceding character, which is the character whose sequence number is less than or equal to 1. All characters; This indicates the medical record to be queried; Represents a set of medical record entities; This indicates that in the autoregressive generation process of a large language model, given the input conditions and the previously generated preceding characters, the current character is generated. The conditional probability of each character; The decision function is defined as follows: ; This represents the output value of the agent; The overall confidence score representing the surgical procedure code; This indicates the preset scoring threshold.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the surgical operation code generation method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Multi-language medical term code conversion method based on intelligent agent

    CN121171447A

  • Chinese electronic medical record data processing method and system based on large language model

    CN121439062A