Medical file conversion method, device and equipment
The method uses a large language model to initialize a medical file processing engine for converting medical files into target formats, addressing the challenge of format variability and enhancing medical knowledge management in digital healthcare.
Patent Information
- Application Number
- CN202411977767.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-07-15
- Estimated Expiration
- 2044-12-30
AI Technical Summary
Due to the different formats of medical files and strong professionalism, it is difficult for the existing technology to efficiently and conveniently realize the format conversion of medical files, resulting in a large amount of manpower and material resources required for formatted data extraction.
By receiving the pending medical files and target format requirements input by the user, the large language model is used to generate attribute information, initialize the medical file processing engine, and convert the format according to the target format requirements, including parameter configuration and correlation calculation of text and format attribute information to ensure that the file format meets the target requirements.
It realizes fast, efficient and accurate conversion of medical files, meets the format requirements of different systems, and improves the utilization rate of medical files and data management efficiency.
Smart Images

Figure CN120316083A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the technical field of language models, and particularly relates to a method, device, and equipment for converting medical documents. Background Art
[0002] With the development of technology, the medical industry is gradually moving towards digitalization, and the systematic organization and efficient application of medical knowledge have gradually become key factors in improving the quality of medical services. However, due to the professionalism and complexity of medical knowledge, coupled with the emerging new research results and new technical standards in the field, the management and update of medical knowledge have become a challenging task.
[0003] In related technologies, medical technicians can organize and classify medical documents so that the medical knowledge in the medical documents can be extracted in a standardized form for subsequent tasks. However, different medical document formats are diverse, and it often requires a large amount of manpower and material resources to achieve the extraction of formatted data. Therefore, how to efficiently and conveniently convert the format of medical documents is a technical problem that needs to be solved urgently by relevant technical personnel. Summary of the Invention
[0004] The embodiments of this application provide a method, device, and equipment for converting medical documents, which can convert different formats of medical documents.
[0005] In a first aspect, the embodiments of this application provide a method for converting medical documents, including: receiving a medical document to be processed input by a user and a target format requirement for the medical document to be processed; determining a target attribute file template according to the target format requirement, where the target attribute file template includes a prediction task prompt for attribute information, and the attribute information corresponds to the attributes of the target format requirement; inputting the attribute file template into a large language model to obtain the attribute information output by the large language model, where the large language model executes a task of generating attribute information according to a preset task prompt for the attribute information; initializing target file conversion parameters for a medical document processing engine according to the attribute information to obtain a target medical document processing engine; and using the target medical document processing engine to perform format conversion on the medical document to be processed to obtain a medical document corresponding to the target format requirement.
[0006] In one implementation, the attribute information includes text attribute information and format attribute information. Initializing the file conversion parameters of the medical document processing engine according to the attribute information to obtain a target medical document processing engine includes: determining target text content conversion parameters corresponding to the text attribute information according to a first correspondence relationship, where the first correspondence relationship represents the correspondence between different text attribute information and text content conversion parameters; determining target format conversion parameters corresponding to the format attribute information according to a second correspondence relationship, where the second correspondence relationship represents the correspondence between different format attribute information and format conversion parameters; and configuring the parameters of the medical document processing engine according to the target text content conversion parameters and the target format conversion parameters to obtain a target medical document processing engine.
[0007] In one implementation, using the target medical document processing engine to perform format conversion on a medical document to be processed to obtain a medical document corresponding to the target format requirement includes: through the target medical document processing engine, calculating the relevance between the text attribute information and multiple related documents in the medical document to be processed according to the text attribute information saved in the text content conversion parameters to obtain a relevance calculation result; through the target medical document processing engine, obtaining target document content whose relevance result meets a preset relevance condition from multiple related documents according to the relevance calculation result; through the target medical document processing engine, determining a text content extraction template according to the text attribute information and the target document content, where the text content extraction template includes a prediction task prompt for extracting the text content corresponding to the text attribute information from the target document content; inputting the text content extraction template into a large language model to obtain the text content corresponding to the text attribute information extracted by the large language model from the target document content according to the text content extraction template; and performing format conversion on the text content according to the format attribute information saved in the target format conversion parameters to obtain a medical document corresponding to the target format requirement.
[0008] In one implementation, calculating the relevance between the text attribute information and multiple related documents in the medical document to be processed according to the text attribute information saved in the text content conversion parameters to obtain a relevance calculation result includes: determining the word frequency and inverse document frequency of the text attribute information in the medical document; and calculating a relevance score corresponding to the medical document according to the word frequency, inverse document frequency, and length of the medical document.
[0009] In one implementation, through the target medical document processing engine, obtaining target document content whose relevance result meets a preset relevance condition from multiple related documents according to the relevance calculation result includes: determining a relevance threshold according to the target format requirement; and in the case where it is determined that the relevance score is greater than or equal to the relevance threshold, using the document content of the medical document corresponding to the relevance score as the target document content.
[0010] In one implementation manner, determining the attribute file template according to the target format requirement includes: determining the target attribute file template corresponding to the target format requirement from multiple preset attribute templates according to the third correspondence relationship, where the third correspondence relationship represents the correspondence relationship between different preset attribute templates and format requirements.
[0011] In one implementation manner, the method further includes: determining the target system authentication parameters according to the target format requirement; establishing a target connection channel with the target system based on the target system authentication parameters; after using the target medical file processing engine to perform format conversion on the medical file to be processed to obtain the medical file corresponding to the target format requirement, the method further includes: sending the medical file corresponding to the target format requirement to the target system through the target connection channel.
[0012] In one implementation manner, before calculating the relevance between the text attribute information saved in the text content conversion parameters and multiple related files in the medical file to be processed to obtain the relevance calculation result, the method further includes: determining the paragraph processing requirement according to the target format requirement; performing paragraph processing on the medical file to be processed according to the paragraph processing requirement to obtain multiple medical file segments; in the case where it is determined that the nth medical file segment is less than or equal to the preset length threshold, splicing the nth medical file segment and the (n + 1)th medical file segment to obtain the spliced medical file to be processed, where n is a positive integer; calculating the relevance between the text attribute information saved in the text content conversion parameters and multiple related files in the medical file to be processed to obtain the relevance calculation result, including: calculating the relevance between the text attribute information saved in the text content conversion parameters and multiple related files in the spliced medical file to be processed to obtain the relevance calculation result.
[0013] In a second aspect, an embodiment of the present application provides a conversion device for medical files, and the device includes:
[0014] A receiving module, configured to receive the medical file to be processed input by the user and the target format requirement of the medical file to be processed;
[0015] A first determination module, configured to determine a target attribute file template according to the target format requirement, where the target attribute file template includes a prediction task prompt word for attribute information, and the attribute information corresponds to the attribute of the target format requirement;
[0016] A second determination module, configured to input the attribute file template into a large language model to obtain the attribute information output by the large language model, where the large language model performs a task of generating attribute information according to the preset task prompt word of the attribute information;
[0017] An initialization module for initializing the target file conversion parameters of the medical file processing engine according to the attribute information to obtain a target medical file processing engine;
[0018] A conversion module for converting the medical file to be processed into a medical file corresponding to the target format requirement by using the target medical file processing engine.
[0019] In a third aspect, an embodiment of the present application provides a medical file conversion device, including: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, the conversion method of the medical file in the first aspect or any implementation manner of the first aspect is implemented.
[0020] In a fourth aspect, a computer-readable storage medium stores computer program instructions, and when the computer program instructions are executed by a processor, the conversion method of the medical file in the first aspect or any implementation manner of the first aspect is implemented.
[0021] In a fifth aspect, an embodiment of the present application provides a computer program product. When the instructions in the computer program product are executed by the processor of an electronic device, the electronic device is caused to execute the conversion method of the medical file as in the first aspect or any implementation manner of the first aspect.
[0022] The medical file conversion method, device and equipment in the embodiments of the present application can obtain the medical file to be processed input by the user and the target format requirement corresponding to the medical file to be processed, and use the target attribute template corresponding to the target format requirement determined by the target format requirement. By inputting the target attribute template into the trained large language model, the large language model executes the task of generating attribute information according to the preset task prompt words of the attribute information in the target attribute template, so as to obtain the attribute information. Further, the format of the medical file processing engine is converted by using the attribute information, so as to obtain a target medical file processing engine that meets the target format conversion requirements, and then the medical file to be processed is converted in format by using the target medical file processing engine. It can be understood that the medical file conversion method in the embodiments of the present application can obtain the initialization parameters corresponding to the medical file processing engine according to the target format requirement through the large language model, and initialize the medical file processing engine according to the initialization parameters corresponding to the target format requirement, so that the initialized target medical file processing engine realizes the conversion of the medical file format. Description of the Drawings
[0023] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings required to be used in the embodiments of the present application. For those of ordinary skill in the art, other drawings can also be obtained based on these drawings without creative efforts.
[0024] Figure 1 Shows a schematic flowchart of a method for converting medical documents provided by an embodiment of the present application;
[0025] Figure 2 Shows a schematic flowchart of a method for converting medical documents provided by another embodiment of the present application;
[0026] Figure 3 Shows a schematic flowchart of a method for converting medical documents provided by yet another embodiment of the present application;
[0027] Figure 4 Shows a schematic flowchart of a process for determining a relevance calculation result provided by yet another embodiment of the present application;
[0028] Figure 5 Shows a schematic flowchart of a process for determining the content of a target document provided by yet another embodiment of the present application;
[0029] Figure 6 Shows a schematic flowchart of a method for converting medical documents provided by yet another embodiment of the present application;
[0030] Figure 7 Shows a schematic flowchart of a method for converting medical documents provided by yet another embodiment of the present application;
[0031] Figure 8 Shows a schematic flowchart of a method for converting medical documents provided by yet another embodiment of the present application;
[0032] Figure 9 Shows a schematic diagram of the architecture of a medical document conversion system provided by an embodiment of the present application;
[0033] Figure 10 Is a schematic structural diagram of a medical document conversion device provided by another embodiment of the present application;
[0034] Figure 11 Is a schematic structural diagram of a medical document conversion device provided by yet another embodiment of the present application. Detailed Description of the Invention
[0035] The features and exemplary embodiments of various aspects of the present application will be described in detail below. To make the objectives, technical solutions, and advantages of the present application clearer and more understandable, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain the present application and not to limit the present application. For those skilled in the art, the present application can be implemented without some of these specific details. The following description of the embodiments is only intended to provide a better understanding of the present application by showing examples of the present application.
[0036] It should be noted that in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprising", "including" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements not only includes those elements, but also includes other elements not expressly listed, or also includes elements inherent to such process, method, article or device. Without further limitation, the elements defined by the statement "comprising..." do not exclude the presence of additional identical elements in the process, method, article or device comprising the said elements.
[0037] With the digital transformation of the medical industry, the systematic collation and efficient application of medical knowledge have gradually become key factors in improving the quality of medical services. However, due to the professionalism and complexity of medical knowledge, coupled with the emerging new research results and new technical standards in the field, the management and update of medical knowledge have become a challenging task.
[0038] In the related art, medical technicians can sort and classify medical documents, so as to obtain standardized medical knowledge data. Among them, medical documents can include clinical records of doctors and medical experts, or relevant medical literature, etc. Among them, medical literature can include books and their photocopies, electronic files and other contents. It can be understood that due to the different working habits of different medical personnel, the formats of medical documents are various, which will cause great difficulties in formatting.
[0039] In addition, for different systems, the required formats may also be different. Therefore, how to quickly and accurately generate corresponding formats for different systems is also a technical problem that relevant technicians need to solve.
[0040] To solve the problems of the prior art, the embodiments of the present application provide a method, device and equipment for converting medical documents. First, the method for converting medical documents provided by the embodiments of the present application will be introduced below.
[0041] Figure 1 The flowchart of the method for converting medical documents provided by an embodiment of the present application is shown. As Figure 1 shown, the method for converting medical documents includes the following steps:
[0042] S110. Receive the medical document to be processed input by the user and the target format requirement of the medical document to be processed.
[0043] Exemplarily, the medical document to be processed may represent a medical document that needs to be format-converted. Among them, the medical document to be processed may be a medical document entered or imported by the user through a dialog box at the front end of different systems. For example, the medical document to be processed may be a document related to the clinical treatment experience of a specific disease; or the medical document to be processed may be a document related to case analysis.
[0044] Exemplarily, the medical documents to be processed input by the user may include one or more, and the formats of the medical documents to be processed may be different formats. In one example, the formats of the medical documents to be processed may include online notes, paper notes, artwork, and temporary drafts, etc. In another example, the medical documents to be processed may include documents in multiple language forms, such as medical documents corresponding to multiple languages such as Chinese, English, etc.
[0045] Exemplarily, the target format requirement may be a format requirement for format-converting the document to be processed. In one example, the target format requirement may be selected by the user according to different needs; or, according to the target system selected by the user, the target format requirement corresponding to the target system may be automatically identified. Among them, the target system may include a patient consultation system, a doctor diagnosis system, and a scientific research query system, etc.
[0046] S120. Determine the target attribute file template according to the target format requirement.
[0047] Among them, the target attribute file template includes preset task prompt words for attribute information, and the attribute information corresponds to the attributes of the target format requirement.
[0048] Exemplarily, different target format requirements may correspond to different target attribute file templates. Among them, the target attribute file template includes preset task prompt words corresponding to the attribute information.
[0049] In one example, in the case analysis task, the target attribute file template may be "illness is [MASK]". Further, the template can be concatenated with the original text, and the input of the prompt word is "I like the Disney films very much. It was [MASK]." It can be understood that [MASK] can be used to mark the creation of a prediction task. When the model sees [MASK] in the input text, it can predict the word or phrase that should be filled in the [MASK] position based on the context.
[0050] Exemplarily, the attribute information can be used to characterize the attribute information to be predicted in the target attribute file template. For example, in the case analysis task, the attribute information may include attribute information such as disease type, medical history, and family history.
[0051] S130. Input the target attribute file template into the large language model to obtain the attribute information output by the large language model.
[0052] Among them, the large language model executes the task of generating attribute information according to the preset task prompt words of the attribute information.
[0053] Exemplarily, the target attribute file template can be input into the large language model, so that the large language model executes the task of generating attribute information according to the preset task prompt words in the target attribute file template, thereby obtaining the attribute information.
[0054] Exemplarily, the large language model (Large Language Model, LLM) can be a language model that supports multiple tasks.
[0055] S140. Initialize the target file conversion parameters of the medical document processing engine according to the attribute information to obtain the target medical document processing engine.
[0056] Exemplarily, the target file conversion parameters of the medical document processing engine can be initialized by using the attribute information determined by the large language model to obtain the target medical document processing engine.
[0057] Exemplarily, the medical document processing engines corresponding to different systems are different. The file conversion parameters of the medical document processing engine can be initialized according to different attribute information, so that the medical document processing engine can process the medical document to be processed according to different format requirements.
[0058] In one example, the medical document processing engine can be a software system or a hardware component that can execute data processing tasks. For example, the medical processing engine can include a search engine, a database processing engine, and a data preprocessing engine, etc.
[0059] S150. Use the target medical document processing engine to perform format conversion on the medical document to be processed to obtain the medical document corresponding to the target format requirement.
[0060] Exemplarily, the medical document to be processed can be format-converted by the formatted target medical document processing engine, thereby obtaining the medical document corresponding to the target format requirement.
[0061] In the embodiments of the present application, it is possible to obtain the medical document to be processed input by the user and the corresponding target format requirements of the medical document to be processed, and use the target attribute template corresponding to the target format requirements determined by the target format requirements. By inputting the target attribute template into the trained large language model, the large language model executes the task of generating attribute information according to the preset task prompt words of the attribute information in the target attribute template, so as to obtain the attribute information. Further, the format of the medical document processing engine is converted using the attribute information, so as to obtain the target medical document processing engine that meets the target format conversion requirements, and then the target medical document processing engine is used to perform format conversion on the medical document to be processed. It can be understood that the medical document conversion method in the embodiments of the present application can, according to the target format requirements, obtain the initialization parameters corresponding to the medical document processing engine through the large language model, and perform initialization on the medical document processing engine according to the initialization parameters corresponding to the target format requirements, so that the initialized target medical document processing engine realizes the conversion of the medical document format. That is, in the embodiments of the present application, the combination of the medical document processing engine realizes the format conversion of the medical document, and can quickly, efficiently and accurately convert the medical document to be processed into the medical document corresponding to the target format requirements.
[0062] Exemplarily, different format requirements may correspond to different attribute information, and the attribute information can be used to implement the parameter initialization of the medical document processing engine. Among them, the attribute information may include text attribute information and format attribute information.
[0063] In order to be able to realize the parameter initialization of the medical document processing engine through the attribute information, as another implementation manner of the present application, the present application also provides another implementation manner of the medical document conversion method, specifically refer to the following embodiments.
[0064] Figure 2 The flowchart of the medical document conversion method provided by another embodiment of the present application is shown. As Figure 2 shown, the medical document conversion method includes the following steps:
[0065] S210. Receive the medical document to be processed input by the user and the target format requirements of the medical document to be processed.
[0066] S220. Determine the target attribute file template according to the target format requirements.
[0067] S230. Input the target attribute file template into the large language model to obtain the attribute information output by the large language model.
[0068] Exemplarily, steps S210-S230 are the same as steps S110-S130, and step S270 is the same as step S150, and will not be elaborated here.
[0069] S240. Determine the target text content conversion parameters corresponding to the text attribute information according to the first correspondence relationship.
[0070] Among them, the first correspondence relationship represents the correspondence relationship between different text attribute information and text content conversion parameters.
[0071] Exemplarily, the target text content conversion parameters corresponding to the text attribute information in the attribute information can be determined through the first correspondence relationship. Among them, the target text content conversion parameters are used to initialize the parameters for the text extraction process in the medical document processing engine.
[0072] In one example, the text attribute information can be used to represent the text features corresponding to the target format requirements. For example, in the case analysis task, the text attribute information can include text features such as disease types, medical histories, and family histories.
[0073] Exemplarily, the first correspondence relationship can be set by relevant technical personnel based on experience or experiments.
[0074] S250. Determine the target format conversion parameters corresponding to the format attribute information according to the second correspondence relationship, where the second correspondence relationship represents the correspondence relationship between different format attribute information and format conversion parameters.
[0075] Exemplarily, the target format conversion parameters corresponding to the format attribute information in the attribute information can be determined through the second correspondence relationship. Among them, the target format conversion parameters are used to initialize the parameters for the format conversion process in the medical document processing engine.
[0076] In one example, the format attribute information can be used to represent the format requirements corresponding to the target format requirements. Moreover, the format attribute information can correspond to the text attribute information. For example, in the case analysis task, the format attribute information corresponding to the disease type can be that the disease type is text, the number of characters is within 256 characters, and the disease type should conform to the enumeration of disease types in the International Classification of Diseases (ICD).
[0077] Exemplarily, the second correspondence relationship can be set by relevant technical personnel based on experience or experiments.
[0078] S260. Configure the parameters of the medical document processing engine according to the target text content conversion parameters and the target format conversion parameters to obtain the target medical document processing engine.
[0079] Exemplarily, the target medical document processing engine can be obtained by initializing the parameters of the medical document processing engine with the target text content conversion parameters and the target format conversion parameters determined according to the first correspondence and the second correspondence.
[0080] S270. Use the target medical document processing engine to perform format conversion on the medical document to be processed, and obtain the medical document corresponding to the target format requirements.
[0081] In the embodiments of the present application, through the first correspondence and the second correspondence, the target text content conversion parameters and the target format conversion parameters corresponding to the text attribute features and the format attribute features corresponding to the target format requirements are respectively obtained. Then, the target text content conversion parameters and the target format conversion parameters are used to initialize the medical document processing engine, and the target medical document processing engine that meets the target format requirements is obtained. Furthermore, the target medical document processing engine can be used to process the medical document to be processed, ensuring that the medical document to be processed can be accurately converted by the target medical document processing engine.
[0082] In order to accurately convert the medical document to be processed, as another implementation manner of the present application, the present application also provides another implementation manner of the medical document conversion method. For specific details, please refer to the following embodiments.
[0083] Figure 3 FIG. shows a schematic flow chart of a medical document conversion method provided by another embodiment of the present application. As Figure 3 shown, the medical document conversion method includes the following steps:
[0084] S310. Receive the medical document to be processed input by the user and the target format requirements of the medical document to be processed.
[0085] S320. Determine the target attribute file template according to the target format requirements.
[0086] S330. Input the target attribute file template into the large language model, and obtain the attribute information output by the large language model.
[0087] S340. Initialize the target file conversion parameters of the medical document processing engine according to the attribute information, and obtain the target medical document processing engine.
[0088] S350. Through the target medical document processing engine, calculate the correlation between the text attribute information and multiple related documents in the medical document to be processed according to the text attribute information saved in the text content conversion parameters, and obtain the correlation calculation result.
[0089] S360. Obtain the content of the target file whose relevance result meets the preset relevance condition from multiple relevant files through the target medical file processing engine according to the relevance calculation result.
[0090] S370. Determine the text content extraction template through the target medical file processing engine according to the text attribute information and the content of the target file. The text content extraction template includes preset task prompt words for extracting the text content corresponding to the text attribute information from the content of the target file.
[0091] S380. Input the text content extraction template into the large language model to obtain the text content corresponding to the text attribute information extracted by the large language model from the content of the target file according to the text content extraction template.
[0092] S390. Convert the format of the text content according to the format attribute information saved in the target format conversion parameters to obtain a medical file corresponding to the target format requirements.
[0093] Exemplarily, steps S310 - S340 are the same as steps S110 - S140, and will not be elaborated here.
[0094] In some embodiments, in S350, the initialized target medical file processing engine can calculate the relevance between the text attribute information and multiple relevant files in the medical file to be processed according to the text attribute information saved in the text content conversion parameters, and obtain the relevance calculation result.
[0095] In some alternative embodiments, the determination of relevant files can be achieved through a relevance calculation formula. Figure 4 Shows a schematic flowchart of determining the relevance calculation result provided by another embodiment of the present application. As Figure 4 shown, the conversion method of the medical file includes the following steps:
[0096] S351. Determine the word frequency and inverse document frequency of the text attribute information in the medical file.
[0097] Exemplarily, the word frequency and inverse document frequency (Inverse Document Frequency, IDF) of the text attribute information in each medical file can be determined.
[0098] In one example, the inverse document frequency IDF corresponding to the text attribute information can be calculated through the following formula (1):
[0099]
[0100] Among them, N is the total number of documents; n(qi) is the number of documents containing the word "qi".
[0101] S352. Calculate the correlation score corresponding to the medical document based on the word frequency, inverse document frequency, and the length of the medical document.
[0102] In one example, the correlation score score corresponding to the medical document can be calculated by the following formula (2):
[0103]
[0104] Where score(D,Q) represents the correlation score between the medical document D and the query Q, IDF(qi) represents the inverse document frequency of the term qi, f(q,D) represents the frequency of occurrence of the term q in the medical document D, k1 and b are adjustable parameters, avgdl represents the average document length, and |D| represents the length of the medical document D.
[0105] In the embodiments of the present application, by determining the word frequency and inverse document frequency of the text attribute information in the medical document, and calculating the correlation score corresponding to the medical document based on the word frequency, inverse document frequency, and the length of the medical document, the correlation between the target format requirements and each medical document can be determined.
[0106] In some embodiments, in S360, the target file content that meets the preset correlation condition can be obtained from multiple relevant files through the target medical document processing engine according to the correlation calculation result.
[0107] Exemplarily, the target file content can be a medical document or a text segment in the medical document that has a high correlation with the text attribute information.
[0108] In one example, the medical document or the text segment in the medical document with the highest correlation score can be used as the target file content.
[0109] Exemplarily, different target format requirements can correspond to different preset correlation conditions.
[0110] In one example, the preset correlation condition can be to select the most relevant file from multiple relevant texts as the target file content. For example, the file or text segment with the highest correlation score can be selected as the target file content.
[0111] In some alternative embodiments, Figure 5 shows a schematic flowchart of determining the target file content provided by another embodiment of the present application. As Figure 5 shown, the conversion method of the medical document includes the following steps:
[0112] S361. Determine the correlation threshold according to the target format requirements.
[0113] Exemplarily, the correlation threshold can characterize the correlation between the content of the target file and the text attribute information. In one example, the larger the value corresponding to the correlation threshold, the higher the correlation between the target text content and the text attribute information; conversely, the smaller the value corresponding to the correlation threshold, the weaker the correlation between the target text content and the text attribute information.
[0114] Exemplarily, different target format requirements correspond to different correlation thresholds. Among them, the correlation threshold can be determined by relevant technicians according to different requirements of the target format.
[0115] S362. In the case where it is determined that the correlation score is greater than or equal to the correlation threshold, the file content of the medical document corresponding to the correlation score is used as the target file content.
[0116] Exemplarily, in the case where it is determined that the correlation score is greater than or equal to the correlation threshold, the file content of the medical document corresponding to the correlation score can be used as the target file content; in the case where it is determined that the correlation score is less than the correlation threshold, the file content of the medical document corresponding to the correlation score can be used as the target file content.
[0117] In the embodiments of the present application, by comparing the correlation score with the correlation threshold, it is thereby determined whether the medical document content corresponding to the correlation score is the target file content. Among them, the correlation threshold is determined according to different target format requirements, and by comparing the correlation score with the correlation thresholds corresponding to different format requirements, the determined target format content can meet different format requirements, thereby improving the accuracy of the format conversion process.
[0118] In some embodiments, in S370, the target medical document processing engine can determine a text content extraction template according to the text attribute information and the target file content.
[0119] Among them, the text content extraction template includes preset task prompt words for extracting the text content corresponding to the text attribute information from the target file content.
[0120] Exemplarily, the target medical document processing engine can construct a text content extraction target according to the text attribute information and the target file content. Among them, the text content extraction template can include preset task prompt words, and the preset task prompt words can be used to extract the text content corresponding to the text attribute information from the target file content.
[0121] In one example, when the determined text attribute information is the disease type and the target file content is related to heart disease, a text content extraction template can be constructed according to the disease type and the heart disease-related content.
[0122] In some embodiments, in S380, the text content extraction template is input into the large language model, and the text content corresponding to the text attribute information is extracted from the target file content by the large language model according to the text content extraction template.
[0123] Exemplarily, the text content extraction template can be input into the large language model, so that the large language model predicts the corresponding text content according to the text content extraction template. Among them, the text content predicted by the large language model corresponds to the text attribute information.
[0124] In one example, if the text content extraction template is that the text attribute information is the disease type, and the target file content is the content related to heart disease, and the determined text content extraction template, at this time, the predicted text content that the large language model can output can be heart disease.
[0125] In some embodiments, in S390, the text content can be format-converted according to the format attribute information saved by the target format conversion parameter to obtain a medical document corresponding to the target format requirement.
[0126] Exemplarily, the target medical document processing engine can verify and format-convert the determined text content according to the corresponding format attribute information.
[0127] In one example, it is possible to verify the predicted text content that the large language model can output, such as heart disease, to determine whether it is text content, whether it is less than 256 characters, and whether it conforms to the examples enumerated in ICD. After determining that the content predicted by the large language model meets the requirements, it can be converted according to a preset format. For example, the text content can be converted into the text (text, TXT) format. Or, the text content can be vectorized through a pre-trained model for text-to-vector (such as text2vec-large-chinese) of the text content, so that the downstream task can retrieve the formatted medical document.
[0128] In the embodiments of the present application, the relevance calculation results of multiple related files in the medical file to be processed can be obtained to determine the target file content, and a text content extraction template can be constructed through the target file content and the text attribute information. The text content in the text content extraction template is predicted by the large language model to obtain the corresponding text content, and then the text content is format-converted by the target medical document processing engine according to the format attribute information saved by the target format conversion parameter to obtain a medical document corresponding to the target format requirement. That is, the embodiments of the present application can effectively express and organize the file to be processed, so that it can correctly and standardly implement format conversion.
[0129] To achieve the determination of the attribute template, as another implementation manner of the present application, the present application also provides another implementation manner of the medical document conversion method. For details, see the following embodiments.
[0130] Figure 6 The flowchart of the medical document conversion method provided by another embodiment of the present application is shown. As Figure 6 shown, the medical document conversion method includes the following steps:
[0131] S610. Receive the medical document to be processed input by the user and the target format requirement of the medical document to be processed.
[0132] Exemplarily, step S610 is the same as step S110, and steps S630-S650 are the same as steps S130-S150, and will not be elaborated here.
[0133] S620. Determine the target attribute file template corresponding to the target format requirement from multiple preset attribute templates according to the third correspondence.
[0134] Among them, the third correspondence represents the correspondence between different preset attribute file templates and format requirements.
[0135] Exemplarily, after determining the target format requirement required by the user, the target attribute file template corresponding to the target format requirement can be determined from multiple preset attribute file templates through the third correspondence.
[0136] Among them, the preset attribute file template can be an attribute file template set by technicians according to different requirements. And the third correspondence can be established by technicians according to the correspondence between the preset attribute file template and the target format requirement.
[0137] Exemplarily, the corresponding attribute information in different preset attribute file templates can be different, or there can be some identical attribute information in different preset attribute file templates. In one example, different preset attribute file templates can include information such as name and gender. In another example, for example, in the template corresponding to the case analysis task, its unique attribute information can include attribute information such as disease type, medical history, and family history.
[0138] S630. Input the target attribute file template into the large language model to obtain the attribute information output by the large language model.
[0139] S640. Initialize the target file conversion parameters of the medical document processing engine according to the attribute information to obtain the target medical document processing engine.
[0140] S650. Use the target medical document processing engine to perform format conversion on the medical document to be processed, and obtain the medical document corresponding to the target format requirements.
[0141] In the embodiments of the present application, by matching the target format requirements with the format requirements in the third corresponding relationship, the target attribute file template corresponding to the target format requirements is determined, ensuring that the target attribute file template can meet the format requirements needed by different users. It can be understood that in the embodiments of the present application, by determining the target attribute file template corresponding to the target format requirements, the medical document to be processed can be converted into medical documents in multiple formats, improving the utilization rate of medical documents and providing a good foundation for downstream tasks.
[0142] To ensure data transmission security, as another implementation manner of the present application, the present application also provides another implementation manner of the conversion method of medical documents. For details, refer to the following embodiments.
[0143] Figure 7 FIG. shows a schematic flowchart of the conversion method of medical documents provided by another embodiment of the present application. As Figure 7 shown, the conversion method of medical documents includes the following steps:
[0144] S710. Receive the medical document to be processed input by the user and the target format requirements of the medical document to be processed.
[0145] Exemplarily, step 710 is the same as step S110, and steps S740 - S770 are the same as steps S120 - S150, and will not be elaborated here.
[0146] S720. Determine the target system authentication parameters according to the target format requirements.
[0147] Exemplarily, the target system can be determined according to the target format requirements. Among them, the target system can be a system specified by the user. Further, the authentication parameters corresponding to the target system can be determined according to the target system.
[0148] In one example, the authentication parameters of the authentication component of the target system can be used. For example, the authentication parameters can include credentials for verifying the target system, such as username and password, digital certificate, biometric information, etc.
[0149] S730. Establish a target connection channel with the target system based on the target system authentication parameters.
[0150] Exemplarily, in the case where the authentication of the authentication parameters is successful, a target connection channel can be established with the target system. In one example, the connection parameters, such as IP address, port number, encryption protocol, etc., can be configured, and the security of communication can be ensured through a handshake process, such as TLS / SSL handshake.
[0151] S740. Determine the target property file template according to the target format requirements.
[0152] S750. Input the target property file template into the large language model to obtain the property information output by the large language model.
[0153] S760. Initialize the target file conversion parameters for the medical file processing engine according to the property information to obtain the target medical file processing engine.
[0154] S770. Use the target medical file processing engine to perform format conversion on the medical file to be processed to obtain the medical file corresponding to the target format requirements.
[0155] S780. Send the medical file corresponding to the target format requirements to the target system through the target connection channel.
[0156] Exemplarily, the medical file corresponding to the target format requirements can be sent to the target system by using the target connection channel.
[0157] Exemplarily, before establishing the connection channel, the pre-set configuration of the system can be retrieved to check the system environment and allocate Central Processing Unit (CPU) resources, memory, and storage resources to ensure the operation of the medical file formatting process and the transmission process.
[0158] Exemplarily, the medical file corresponding to the target format requirements can be compressed by a compression algorithm to improve the data transmission speed.
[0159] In the embodiment of the present application, the target connection channel can be established with the target system through the authentication parameters, so that the medical file corresponding to the target format requirements can be transmitted to the target system. It can be understood that through the target data transmission, the security of data transmission can be improved, and personal privacy and confidential data will not be leaked.
[0160] In order to ensure the quick determination of the relevant technical structure, as another implementation manner of the present application, the present application also provides another implementation manner of the conversion method of the medical file. For details, refer to the following embodiments.
[0161] Figure 8 The flowchart of the conversion method of the medical file provided by another embodiment of the present application is shown. As Figure 8 shown, the conversion method of the medical file includes the following steps:
[0162] S801. Receive the medical file to be processed input by the user and the target format requirements of the medical file to be processed.
[0163] S802. Determine the target property file template according to the target format requirements.
[0164] S803. Input the target property file template into the large language model to obtain the property information output by the large language model.
[0165] S804. Initialize the target file conversion parameters for the medical file processing engine according to the property information to obtain the target medical file processing engine.
[0166] Exemplarily, steps S801 - S804 are the same as steps S310 - S340, and steps S809 - S812 are the same as steps S360 - S390, so no further elaboration will be made here.
[0167] S805. Determine the paragraph processing requirements according to the target format requirements.
[0168] Exemplarily, the paragraph processing requirements are used to characterize the processing requirements for each paragraph in the medical file. Among them, different target format requirements can correspond to different preset paragraph processing requirements.
[0169] Exemplarily, the paragraph processing requirements corresponding to the target format requirements can be determined through a preset correspondence. The preset correspondence can represent the correspondence between different format requirements and different paragraph processing requirements.
[0170] In one example, the paragraph processing requirements may include paragraph segmentation processing requirements and the processing requirement of deleting blank lines.
[0171] S806. Perform paragraph processing on the medical file to be processed according to the paragraph processing requirements to obtain multiple medical file segments.
[0172] Exemplarily, perform paragraph segmentation processing and blank line removal processing on the medical file to be processed according to the paragraph processing requirements to obtain multiple medical file segments.
[0173] S807. When it is determined that the nth medical file segment is less than or equal to the preset length threshold, splice the nth medical file segment with the (n + 1)th medical file segment to obtain the spliced medical file to be processed, where n is a positive integer.
[0174] Exemplarily, when it is determined that the nth medical document segment in the medical document segment is less than or equal to the preset length threshold, the nth medical document segment can be spliced with the (n + 1)th medical document segment to obtain the to-be-processed medical document after splicing. It can be understood that the title segment in the to-be-processed medical document is often very short, and the following paragraphs are generally used to explain and elaborate on the title segment. During the retrieval process, it is found that short title segments will affect the retrieval effect and it is easy to retrieve irrelevant and incomplete short titles. Therefore, merging it with the subsequent paragraphs can effectively improve the retrieval efficiency and accuracy.
[0175] Exemplarily, the preset length threshold can be set by technicians according to experiments or relevant experience.
[0176] S808. According to the text attribute information saved in the text content conversion parameter, calculate the relevance between the text attribute information and multiple relevant documents in the to-be-processed medical document after splicing to obtain the relevance calculation result.
[0177] Exemplarily, according to the text attribute information saved in the text content conversion parameter, calculate the relevance between the text attribute information and multiple relevant documents in the to-be-processed medical document after splicing to obtain the relevance calculation result. It can be understood that by performing relevance calculation on the spliced medical document, the relevance calculation efficiency and accuracy can be effectively improved.
[0178] S809. Through the target medical document processing engine, according to the relevance calculation result, obtain the target document content whose relevance result meets the preset relevance condition from multiple relevant documents.
[0179] S810. Through the target medical document processing engine, according to the text attribute information and the target document content, determine the text content extraction template, and the text content extraction template includes preset task prompt words for extracting the text content corresponding to the text attribute information from the target document content.
[0180] S811. Input the text content extraction template into the large language model to obtain the text content corresponding to the text attribute information extracted by the large language model from the target document content according to the text content extraction template.
[0181] S812. According to the format attribute information saved in the target format conversion parameter, perform format conversion on the text content to obtain the medical document corresponding to the target format requirements.
[0182] Exemplarily, before splicing the medical document paragraphs, the to-be-processed medical document can also be classified and the document format can be normalized, etc. After splicing the medical document paragraphs, the spliced medical document can also be de-duplicated and text vectorized for subsequent processes.
[0183] In one example, classifying the document to be processed can be classifying the document according to medical knowledge and storing it in different directories. For example, the classification categories can be customized by technicians, including categories such as basic medical knowledge, clinical treatment methods, disease examination plans, and clinical treatment opinions.
[0184] In one example, processing such as document format normalization can normalize medical document formats, such as zip files, text format documents such as word format, Portable Document Format (PDF) documents, txt format documents, and table format documents. Use Optical Character Recognition (OCR) to read the content in the document and generate a medical document with a unified file format of txt format.
[0185] In one example, removing redundancy from the medical file information to be processed can be removing redundant information in the medical file information to be processed. For example, removing useless information such as the file title, directory, contacts, contact information, cc, send, proofread, etc. at the beginning.
[0186] In one example, performing text vectorization processing on the medical file information to be processed can be based on a pre-trained model to vectorize (Embedding) each text segment in the medical file to be processed and store it in a vector database. The vector database contains the document path information (such as document classification information) of each text segment and the vector information of the text segment.
[0187] In the embodiments of the present application, by performing corresponding preprocessing on the medical file to be processed, the efficiency and accuracy of relevance calculation are improved, laying a good foundation for the follow-up.
[0188] Exemplarily, in combination with Figure 9 and the following examples, the conversion method of the medical file in the present application will be described.
[0189] Exemplarily, the conversion method of the medical file in the embodiments of the present application can be applied to a medical file conversion system. Among them, Figure 9 shows a schematic diagram of the architecture of a medical file conversion system provided by an embodiment of the present application. As Figure 9 shown, the medical file conversion system 900 can include a large language model 901, a medical file processing engine 902, and a client system 903.
[0190] Exemplarily, the user can enter medical knowledge or import medical files in the customer system 903, i.e., the front-end dialog box. For example: import the Clinical Treatment Experience of Special Diseases.doc. Further, the user can select the target system or target format for the medical file or medical knowledge to be imported at the front end, where there may be a corresponding relationship between the target system and the target format. Based on the large language model, analyze the requirements of the target format; based on the LLM, construct a template corresponding to the requirements of the target format through prompts to obtain the description file of the processing engine (Agent) corresponding to different format requirements, and initialize the processing engine (Agent) according to this description file. The initialized Agent extracts features from the medical knowledge or medical files submitted by the user, and based on the large language model, sorts out, analyzes, and transforms the content submitted by the user according to the requirements of the target format, and extracts data through a relevance algorithm, such as the BM25 algorithm, and fills it back into the generated target format document. After processing, the system displays the content of the target document for the front-end user to review. Or the system automatically reviews it. After the review is completed, the data is output or imported into the target repository through the initialized processing engine.
[0191] Based on the medical file conversion method provided in the above embodiments, correspondingly, the present application also provides a specific implementation manner of the medical file conversion device. Please refer to the following embodiments.
[0192] First, refer to Figure 10 , the medical file conversion device 1000 provided in the embodiments of the present application includes the following modules:
[0193] The receiving module 1001 is used to receive the medical file to be processed input by the user and the target format requirements of the medical file to be processed;
[0194] The first determination module 1002 is used to determine a target attribute file template according to the target format requirements, where the target attribute file template includes a prediction task prompt for attribute information, and the attribute information corresponds to the attributes of the target format requirements;
[0195] The second determination module 1003 is used to input the attribute file template into the large language model to obtain the attribute information output by the large language model, where the large language model executes the task of generating the attribute information according to the preset task prompt for the attribute information;
[0196] The initialization module 1004 is used to initialize the target file conversion parameters of the medical file processing engine according to the attribute information to obtain a target medical file processing engine;
[0197] A conversion module 1005, configured to use the target medical document processing engine to perform format conversion on the medical document to be processed, so as to obtain a medical document corresponding to the target format requirement.
[0198] In the embodiments of the present application, by obtaining a medical document to be processed input by a user and the target format requirement corresponding to the medical document to be processed, and using the target attribute template corresponding to the target format requirement determined by the target format requirement, the target attribute template is input into a trained large language model, so that the large language model executes the task of generating attribute information according to the preset task prompt words of the attribute information in the target attribute template, thereby obtaining the attribute information. Further, the format of the medical document processing engine is converted by using the attribute information, so as to obtain a target medical document processing engine that meets the target format conversion requirement, and then the target medical document processing engine is used to perform format conversion on the medical document to be processed. It can be understood that the medical document conversion method in the embodiments of the present application can obtain the initialization parameters corresponding to the medical document processing engine according to the target format requirement through the large language model, and perform initialization on the medical document processing engine according to the initialization parameters corresponding to the target format requirement, so that the initialized target medical document processing engine realizes the conversion of the medical document format.
[0199] As an implementation manner of the present application, the attribute information includes text attribute information and format attribute information. The initialization module 1004 initializes the file conversion parameters of the medical document processing engine according to the attribute information in the following manner to obtain a target medical document processing engine: determining the target text content conversion parameters corresponding to the text attribute information according to the first correspondence relationship, where the first correspondence relationship represents the correspondence relationship between different text attribute information and text content conversion parameters; determining the target format conversion parameters corresponding to the format attribute information according to the second correspondence relationship, where the second correspondence relationship represents the correspondence relationship between different format attribute information and format conversion parameters; configuring the parameters of the medical document processing engine according to the target text content conversion parameters and the target format conversion parameters to obtain a target medical document processing engine.
[0200] As an implementation manner of the present application, the conversion module 1005 uses the following method to perform format conversion on the medical document to be processed by using the target medical document processing engine, so as to obtain the medical document corresponding to the target format requirement: through the target medical document processing engine, according to the text attribute information saved in the text content conversion parameter, calculate the relevance between the text attribute information and multiple related documents in the medical document to be processed, and obtain the relevance calculation result; through the target medical document processing engine, according to the relevance calculation result, obtain the target document content whose relevance result meets the preset relevance condition from multiple related documents; through the target medical document processing engine, according to the text attribute information and the target document content, determine the text content extraction template, and the text content extraction template includes the prediction task prompt words for extracting the text content corresponding to the text attribute information from the target document content; input the text content extraction template into the large language model, and obtain the text content corresponding to the text attribute information extracted by the large language model from the target document content according to the text content extraction template; according to the format attribute information saved in the target format conversion parameter, perform format conversion on the text content to obtain the medical document corresponding to the target format requirement.
[0201] As an implementation manner of the present application, the conversion module 1005 uses the following method to calculate the relevance between the text attribute information and multiple related documents in the medical document to be processed according to the text attribute information saved in the text content conversion parameter, and obtain the relevance calculation result: determine the word frequency and inverse document frequency of the text attribute information in the medical document; calculate the corresponding relevance score of the medical document according to the word frequency, inverse document frequency and the length of the medical document.
[0202] As an implementation manner of the present application, the conversion module 1005 uses the following method to obtain the target document content whose relevance result meets the preset relevance condition from multiple related documents through the target medical document processing engine according to the relevance calculation result: determine the relevance threshold according to the target format requirement; in the case where it is determined that the relevance score is greater than or equal to the relevance threshold, use the document content of the medical document corresponding to the relevance score as the target document content.
[0203] As an implementation manner of the present application, the first determination module 1002 uses the following method to determine the attribute file template according to the target format requirement: determine the target attribute file template corresponding to the target format requirement from multiple preset attribute templates according to the third correspondence relationship, and the third correspondence relationship represents the correspondence relationship between different preset attribute templates and format requirements.
[0204] In one implementation, the device further includes: an authentication module, configured to determine target system authentication parameters according to target format requirements; establish a target connection channel with the target system based on the target system authentication parameters; after using the target medical file processing engine to perform format conversion on the medical file to be processed to obtain a medical file corresponding to the target format requirements, the device further includes a sending module, configured to send the medical file corresponding to the target format requirements to the target system through the target connection channel.
[0205] In one implementation, before calculating the correlation between the text attribute information and multiple related files in the medical file to be processed according to the text attribute information saved in the text content conversion parameters to obtain a correlation calculation result, the initialization module 1004 is further configured to: determine paragraph processing requirements according to the target format requirements; perform paragraph processing on the medical file to be processed according to the paragraph processing requirements to obtain multiple medical file segments; in the case where it is determined that the nth medical file segment is less than or equal to a preset length threshold, splice the nth medical file segment and the (n + 1)th medical file segment to obtain a spliced medical file to be processed, where n is a positive integer; calculate the correlation between the text attribute information and multiple related files in the medical file to be processed according to the text attribute information saved in the text content conversion parameters to obtain a correlation calculation result, including: calculating the correlation between the text attribute information and multiple related files in the spliced medical file to be processed according to the text attribute information saved in the text content conversion parameters to obtain a correlation calculation result.
[0206] Figure 11 The hardware structure diagram of the medical file conversion method provided by the embodiments of the present application is shown.
[0207] The 11 device may include a processor 1101 and a memory 1102 storing computer program instructions.
[0208] Specifically, the above-mentioned processor 1101 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured as one or more integrated circuits implementing the embodiments of the present application.
[0209] The memory 1102 may include a mass storage for data or instructions. By way of example and not limitation, the memory 1102 may include a hard disk drive (HDD), a floppy disk drive, flash memory, an optical disc, a magneto-optical disc, a magnetic tape, or a universal serial bus (USB) drive, or a combination of two or more of these. Where appropriate, the memory 1102 may include removable or non-removable (or fixed) media. Where appropriate, the memory 1102 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, the memory 1102 is a non-volatile solid-state memory.
[0210] The memory may include a read-only memory (ROM), a random access memory (RAM), a magnetic disk storage media device, an optical storage media device, a flash memory device, an electrical, optical, or other physical / tangible memory storage device. Thus, in general, the memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described in reference to the method according to an aspect of the present disclosure.
[0211] The processor 1101 reads and executes the computer program instructions stored in the memory 1102 to implement any one of the medical document conversion methods in the above embodiments.
[0212] In one example, the medical document conversion device may further include a communication interface 1103 and a bus 1110. Among them, as Figure 11 shown, the processor 1101, the memory 1102, and the communication interface 1103 are connected through the bus 1110 and complete communication with each other.
[0213] The communication interface 1103 is mainly used to implement communication between the various modules, devices, units, and / or devices in the embodiments of the present application.
[0214] The bus 1110 includes hardware, software, or both, and couples components of the online data flow metering device to each other. By way of example and not limitation, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), a HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an InfiniBand interconnect, a Low Pin Count (LPC) bus, a memory bus, a MicroChannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable bus or a combination of two or more of these. Where appropriate, the bus 1110 may include one or more buses. Although the embodiments of the present application describe and illustrate specific buses, the present application contemplates any suitable bus or interconnect.
[0215] The conversion device of the medical document can execute the conversion method of the medical document in the embodiments of the present application based on the medical document to be processed input by the user and the target format requirements, so as to implement the combination Figure 1 and Figure 11 the conversion method and device of the medical document described.
[0216] In addition, in combination with the conversion method of the medical document in the above embodiments, the embodiments of the present application can be implemented by providing a computer storage medium. Computer program instructions are stored on the computer storage medium; when the computer program instructions are executed by a processor, any one of the conversion methods of the medical document in the above embodiments is implemented.
[0217] The embodiments of the present application also provide a computer program product, including a computer program, and when the computer program is executed by a processor, any one of the conversion methods of the medical document in the above embodiments is implemented.
[0218] It should be clear that the present application is not limited to the specific configurations and processes described above and illustrated in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and illustrated as examples. However, the method process of the present application is not limited to the specific steps described and illustrated, and those skilled in the art can make various changes, modifications, and additions, or change the order between steps after understanding the spirit of the present application.
[0219] The functional blocks shown in the above-described structural block diagrams can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application-specific integrated circuit (ASIC), appropriate firmware, a plug-in, a functional card, and so on. When implemented in software, the elements of the present application are programs or code segments for performing the required tasks. The program or code segment can be stored in a machine-readable medium or transmitted over a transmission medium or communication link via a data signal carried in a carrier wave. "Machine-readable medium" can include any medium that can store or transmit information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical discs, hard disks, fiber optic media, radio frequency (RF) links, and so on. The code segment can be downloaded via a computer network such as the Internet, an intranet, and so on.
[0220] It should also be noted that the exemplary embodiments mentioned in the present application describe some methods or systems based on a series of steps or devices. However, the present application is not limited to the order of the above steps, that is, the steps can be executed in the order mentioned in the embodiments, or different from the order in the embodiments, or several steps can be executed simultaneously.
[0221] Aspects of the present disclosure have been described above with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to embodiments of the present disclosure. It should be understood that each block in the flowcharts and / or block diagrams, and the combinations of blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the functions / actions specified in one or more blocks of the flowchart and / or block diagram. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It should also be understood that each block in the block diagram and / or flowchart, and the combinations of blocks in the block diagram and / or flowchart, can also be implemented by dedicated hardware for performing the specified functions or actions, or by a combination of dedicated hardware and computer instructions.
[0222] As described above, this is only the specific implementation manner of the present application. Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the systems, modules, and units described above can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein. It should be understood that the protection scope of the present application is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present application can easily think of various equivalent modifications or substitutions, and these modifications or substitutions should all be covered within the protection scope of the present application.
Claims
1. A method for converting medical documents, characterized in that, It includes: Receiving a medical file to be processed input by a user and a target format requirement for the medical file to be processed; Determining a target attribute file template according to the target format requirement, where the target attribute file template includes preset task prompt words for attribute information, and the attribute information corresponds to the attributes of the target format requirement; Inputting the target attribute file template into a large language model to obtain the attribute information output by the large language model, where the large language model executes the task of generating the attribute information according to the preset task prompt words of the attribute information; Initializing target file conversion parameters for a medical file processing engine according to the attribute information to obtain a target medical file processing engine; Using the target medical file processing engine to perform format conversion on the medical file to be processed to obtain a medical file corresponding to the target format requirement.
2. The method according to claim 1, wherein The attribute information includes text attribute information and format attribute information. The initializing the file conversion parameters of the medical file processing engine according to the attribute information to obtain a target medical file processing engine includes: Determining target text content conversion parameters corresponding to the text attribute information according to a first correspondence relationship, where the first correspondence relationship represents the correspondence relationship between different text attribute information and text content conversion parameters; Determining target format conversion parameters corresponding to the format attribute information according to a second correspondence relationship, where the second correspondence relationship represents the correspondence relationship between different format attribute information and format conversion parameters; Configuring the parameters of the medical file processing engine according to the target text content conversion parameters and the target format conversion parameters to obtain a target medical file processing engine.
3. The method according to claim 1 or 2, characterized in that, The using the target medical file processing engine to perform format conversion on the medical file to be processed to obtain a medical file corresponding to the target format requirement includes: Through the target medical file processing engine, calculating the correlation between the text attribute information and multiple related files in the medical file to be processed according to the text attribute information saved in the text content conversion parameters to obtain a correlation calculation result; Through the target medical file processing engine, obtaining target file content whose correlation result meets a preset correlation condition from the multiple related files according to the correlation calculation result; Through the target medical file processing engine, determining a text content extraction template according to the text attribute information and the target file content, where the text content extraction template includes preset task prompt words for extracting the text content corresponding to the text attribute information from the target file content; Inputting the text content extraction template into a large language model to obtain the text content corresponding to the text attribute information extracted by the large language model from the target file content according to the text content extraction template; Performing format conversion on the text content according to the format attribute information saved in the target format conversion parameters to obtain a medical file corresponding to the target format requirement.
4. The method according to claim 3, wherein Calculating the relevance between the text attribute information saved in the conversion parameter according to the text content and multiple relevant files in the medical file to be processed to obtain a relevance calculation result, including: Determining the word frequency and inverse document frequency of the text attribute information in the medical file; Calculating a relevance score corresponding to the medical file according to the word frequency, the inverse document frequency, and the length of the medical file.
5. The method according to claim 4, characterized in that The method of obtaining, by the target medical file processing engine, the content of the target file whose relevance result meets the preset relevance condition from the multiple relevant files according to the relevance calculation result includes: Determining a relevance threshold according to the target format requirement; When it is determined that the relevance score is greater than or equal to the relevance threshold, using the content of the medical file corresponding to the relevance score as the content of the target file.
6. The method according to claim 1, wherein Determining the attribute file template according to the target format requirement includes: Determining the target attribute file template corresponding to the target format requirement from multiple preset attribute templates according to the third correspondence relationship, where the third correspondence relationship represents the correspondence relationship between different preset attribute templates and format requirements.
7. The method according to claim 1, characterized in that, The method further includes: Determining target system authentication parameters according to the target format requirement; Establishing a target connection channel with the target system based on the target system authentication parameters; After using the target medical file processing engine to perform format conversion on the medical file to be processed to obtain a medical file corresponding to the target format requirement, the method further includes: Sending the medical file corresponding to the target format requirement to the target system through the target connection channel.
8. The method according to claim 3, wherein Before calculating the relevance between the text attribute information saved in the conversion parameter according to the text content and multiple relevant files in the medical file to be processed to obtain a relevance calculation result, the method further includes: Determining paragraph processing requirements according to the target format requirement; Performing paragraph processing on the medical file to be processed according to the paragraph processing requirements to obtain multiple medical file segments; When it is determined that the nth medical file segment is less than or equal to a preset length threshold, splicing the nth medical file segment and the (n + 1)th medical file segment to obtain a spliced medical file to be processed, where n is a positive integer; Calculating the relevance between the text attribute information saved in the conversion parameter according to the text content and multiple relevant files in the medical file to be processed to obtain a relevance calculation result, including: Calculating the relevance between the text attribute information and multiple relevant files in the spliced medical file to be processed according to the text attribute information saved in the conversion parameter according to the text content to obtain a relevance calculation result.
9. A conversion device for medical documents, characterized in that, The device includes: A receiving module, configured to receive the medical file to be processed input by the user and the target format requirement of the medical file to be processed; A first determination module, configured to determine a target property file template according to the target format requirement, where the target property file template includes a prediction task prompt for property information, and the property information corresponds to the property required by the target format requirement; A second determination module, configured to input the property file template into a large language model to obtain the property information output by the large language model, where the large language model executes the task of generating the property information according to the preset task prompt for the property information; An initialization module, configured to initialize the target file conversion parameters of the medical file processing engine according to the property information to obtain a target medical file processing engine; A conversion module, configured to use the target medical file processing engine to perform format conversion on the medical file to be processed to obtain a medical file corresponding to the target format requirement.
10. A conversion device for medical documents, characterized in that, The device includes: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, the conversion method of the medical file according to any one of claims 1-8 is implemented.
Citation Information
Patent Citations
Dialogue system intention recognition method and tool based on large language model
CN116955618A
Parameter configuration file format conversion method and device, equipment and storage medium
CN117725892A
Data format conversion method and device, server, medium and computer program
CN118194826A
Method for generating diversified instruction data in medical field based on large language model
CN119069138A
Text abstract generation method and device, equipment, storage medium and product
CN119149726A
Cited By
Method for converting medical documents, apparatus, and device
WO2026144964A1