A method, system, terminal, and storage medium for processing medical information
By adopting the online and offline dual-mode and dual-wheel sorting symptom recommendation method in the traditional Chinese medicine auxiliary diagnosis and treatment system, and using the criterion classification model and sequence prediction model, the existing system's rigid and ignoring professional diagnostic thinking is solved, and more flexible and accurate medical information processing is achieved.
Patent Information
- Application Number
- CN202210160957.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-22
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2042-02-22
AI Technical Summary
The existing traditional Chinese medicine auxiliary diagnosis and treatment system has rigid, poor applicability and expansion in main complaints and accompanying symptoms collection, and ignores professional diagnostic thinking, resulting in inaccurate or difficult to understand the consultation results.
The symptom recommendation method is adopted for both online and offline dual-mode and dual-round sorting. Through the symptom classification model and sequence prediction model, historical consultation symptoms and main complaint symptoms are predicted, candidate symptoms are generated, and the candidate symptoms are updated based on patient feedback to finally determine the target syndrome type.
It realizes a more flexible, more scalable and more accurate medical information processing method, replaces human input methods, reduces human resources costs, and improves the accuracy and readability of diagnostic results.
Smart Images

Figure CN114520053B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular, to a method, a system, a terminal, and a storage medium for processing medical information. Background Art
[0002] In the related art, the collection of chief complaints and accompanying symptoms in most traditional Chinese medicine assisted diagnosis and treatment systems is usually manually input by physicians, and usually standardized symptoms; or in other application scenarios, a new type of assisted diagnosis and treatment system is adopted, which is based on direct communication with patients to ask about their discomfort symptoms, and uses natural language understanding (NLU) technology to extract symptom entities from patients' responses to drive automatic interrogation. However, the two solutions provided in the related art have corresponding defects or deficiencies: firstly, the related art usually asks questions completely according to the template settings, which is very rigid and has poor applicability and scalability; secondly, it ignores professional diagnostic thinking and simplifies the interrogation process too much, resulting in inaccurate or difficult-to-understand results. Summary of the Invention
[0003] The main purpose of the embodiments of the present invention is to propose a more flexible, more scalable, and more accurate method for processing medical information, as well as a system, a terminal, and a corresponding storage medium that can implement this method.
[0004] To achieve the foregoing purpose, an embodiment of the present invention provides a method for processing medical information, the method including the following steps:
[0005] Obtain historical interrogation symptoms, and predict the historical interrogation symptoms through a syndrome element classification model to obtain first syndrome elements corresponding to the historical interrogation symptoms;
[0006] Add the historical interrogation symptoms to a candidate symptom sequence according to the first syndrome elements;
[0007] Identify a chief complaint symptom from the symptom description of a target object;
[0008] Predict the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence;
[0009] In response to feedback information on the first symptom sequence, update the candidate symptom sequence to obtain a second symptom sequence;
[0010] Determine a target syndrome type of the target object according to second syndrome elements corresponding to each symptom in the second symptom sequence.
[0011] To achieve the foregoing purpose, an embodiment of the present invention further provides a system for processing medical information, the system including:
[0012] The first symptom screening unit is configured to obtain historical consultation symptoms, predict the historical consultation symptoms through a syndrome element classification model to obtain first syndrome elements corresponding to the historical consultation symptoms; and add the historical consultation symptoms to a candidate symptom sequence according to the first syndrome elements.
[0013] The second symptom screening unit is configured to identify a chief complaint symptom from the symptom description of a target object; predict the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence.
[0014] The target symptom generation unit is configured to update the candidate symptom sequence in response to feedback information on the first symptom sequence to obtain a second symptom sequence.
[0015] The target syndrome determination unit is configured to determine a target syndrome of the target object according to second syndrome elements corresponding to each symptom in the second symptom sequence.
[0016] To achieve the foregoing objective, an embodiment of the present invention further provides a processing terminal for medical information. The terminal includes a memory, a processor, a program stored on the memory and executable on the processor, and a data bus for realizing connection communication between the processor and the memory. When the program is executed by the processor, the steps of the foregoing method are implemented.
[0017] To achieve the above objective, the present invention provides a storage medium for computer-readable storage. The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps of the foregoing method.
[0018] The advantages and beneficial effects of the present invention will be partially given in the following description, partially become obvious from the following description, or be understood through the practice of the present invention.
[0019] A method, system, terminal, and storage medium for processing medical information proposed by the present invention. The method predicts syndrome elements offline based on historical consultation symptoms through a syndrome element classification model, and sorts the historical consultation symptoms under each syndrome element in units of syndrome elements; online, the method predicts the first symptom sequence of the consultation content through a sequence prediction model based on the main complaint symptoms of the target object, and performs a second-round comprehensive sorting on the sorting of the historical consultation symptoms offline, adjusts the sorting priority of the symptoms to be asked next, and determines the target syndrome type of the target object based on the syndrome elements confirmed after the second-round comprehensive sorting; the present application adopts a symptom prediction method with dual modes and two-round sorting online and offline, replacing the manual input method, making the consultation process more intelligent, and determining the final target syndrome type through the prediction results of two models online and offline, reducing the human resource cost, making the consultation process more convenient, and also improving the scalability of the solution; the solution predicts the final diagnosis result of the consultation based on the correspondence relationship between symptoms, syndrome elements, and syndrome types through machine learning, effectively utilizes the traditional Chinese medicine diagnosis thinking, and improves the accuracy and readability of the prediction result. Brief Description of the Drawings
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0021] Figure 1 Schematic diagram of the relationship between symptoms, syndrome elements, and syndrome types in traditional Chinese medicine diagnosis and treatment.
[0022] Figure 2 Flowchart of the steps of a method for processing medical information provided by an embodiment of the present invention.
[0023] Figure 3 Schematic diagram of the structure of the syndrome element classification model in an embodiment of the present invention.
[0024] Figure 4 Schematic diagram of the structure of the sequence prediction model in an embodiment of the present invention.
[0025] Figure 5 Schematic diagram of the structure of a system for processing medical information provided by an embodiment of the present invention.
[0026] Figure 6 Schematic diagram of the structure of a terminal for processing medical information provided by an embodiment of the present invention. Detailed Embodiments
[0027] It should be understood that the specific embodiments described herein are merely used to explain the present invention and are not intended to limit the present invention.
[0028] In the following description, suffixes such as "module", "component", or "unit" used to represent elements are only for the convenience of explaining the present invention and have no specific meaning per se. Therefore, "module", "component", or "unit" can be used interchangeably.
[0029] As described in the background section, in the related art, the method of manually inputting the main complaints and accompanying symptoms of patients by physicians is adopted. The information entered is the symptoms that have undergone necessary standardization processing, which results in the interrogation during the consultation or diagnosis and treatment process being completely carried out according to the template settings, very rigid, lacking flexibility and expandability. Or in some other application scenarios, the NLU technology is used to extract symptom entities from the patient's response to drive automatic interrogation. This method usually checks the slot filling rate under each disease in real time according to the preset symptom slots for each disease to conduct interrogation. In this method, the symptoms in the disease with a lower slot filling rate are selected for key interrogation; however, the limitation of the method of using the NLU technology for interrogation is that the method completely ignores the professional diagnostic thinking of physicians, overly simplifies the complexity of interrogation, and the results are usually unexplainable or inaccurate.
[0030] It should be noted that as Figure 1 shown, the traditional Chinese medicine diagnostic thinking is to infer syndrome elements from symptoms. The process mainly involves identifying the nature, cause, and location of the disease, and then, through the combination of syndrome elements, inferring the final syndrome type to obtain the diagnosis result.
[0031] Based on the technical problems existing in the related art pointed out above and the relevant principles of traditional Chinese medicine diagnosis, the technical solution of this application provides a symptom recommendation method that adopts an online and offline dual-mode and two-round ranking, and finally determines the diagnosis result of the target patient based on the correspondence relationship between symptoms, syndrome elements, and syndrome types. As Figure 2 shown, the technical solution of this application provides a method for processing medical information, which may include steps S100 - S700:
[0032] S100. Obtain historical consultation symptoms, and predict the historical consultation symptoms through a syndrome element classification model to obtain the first syndrome element corresponding to the historical consultation symptoms;
[0033] Among them, the historical inquiry symptoms refer to the symptom records of the patient obtained and stored through historical inquiry. The syndrome element classification model in the embodiment can adopt a deep learning model with an attention mechanism (Attention). For example, in the embodiment, a classification model with a Transformer structure can be adopted. The model includes a self-attention layer and a fully connected layer, which can effectively solve the problem of combinatorial optimization between symptoms for syndrome element prediction. The first syndrome element in the embodiment refers to the corresponding syndrome element obtained by classifying and predicting the historical inquiry symptoms through the syndrome element classification model.
[0034] It should be noted that the process of predicting syndrome elements for historical inquiry symptoms in the embodiment is carried out offline, and the historical inquiry symptoms also belong to offline stored data. Exemplarily, according to the related symptoms such as cold limbs, pale face, and low blood pressure recorded in the historical inquiry symptoms, the syndrome element prediction model is used for prediction to determine that the disease nature of the foregoing related symptoms is yang collapse. It should be further explained that the content of syndrome elements in the embodiment includes but is not limited to the disease nature and disease location in traditional Chinese medicine, etc.; for example, the output result of the syndrome element prediction model is yang collapse in terms of disease nature, or the disease location is in the heart.
[0035] S200. Add the historical inquiry symptoms to the candidate symptom sequence according to the first syndrome element;
[0036] Among them, the candidate symptom sequence can include the historical inquiry symptoms obtained in several steps S100. Specifically, in the embodiment, several attention-based classification models can be constructed according to the core syndrome elements in traditional Chinese medicine diagnosis and treatment, and according to the syndrome elements finally predicted by the classification models, the historical inquiry symptoms input into the classification models are grouped according to the output syndrome elements. The symptoms included in each group of a syndrome element are the symptoms that this syndrome element may show in the patient. The symptoms included in each group of a syndrome element constitute the candidate symptoms of this syndrome element. For example, for the syndrome element of yang collapse in terms of disease nature, its group may include cold limbs, pale face, and low blood pressure, etc., all of which are the candidate symptoms of this syndrome element. In order to improve the accuracy of the correspondence between syndrome elements and symptoms, in some alternative embodiments, the attention weight between the input symptoms and the corresponding symptoms under this syndrome element can be calculated, and the ones with larger weights are preferentially selected as the preferred candidate symptoms, and the candidate symptom sequence is formed accordingly.
[0037] S300. Identify the chief complaint symptom from the symptom description of the target object;
[0038] Among them, the target object may include, but is not limited to, the target patient who needs traditional Chinese medicine diagnosis and treatment; the chief complaint symptoms refer to the patient's self-reported symptoms, signs, nature, and duration of the illness, etc. Specifically, in the embodiment, the content of the discomfort symptoms of the target patient can be obtained through a human-computer interaction device or manual input, and then the chief complaint symptoms of the target patient can be extracted through corresponding word segmentation and natural language processing processes.
[0039] Exemplarily, the content of the target patient's symptom description is: It may be that I accidentally caught a cold while taking a bath; in the embodiment, through word segmentation and natural language processing processes, the chief complaint symptoms of the target patient are extracted as: feeling cold.
[0040] S400. Predict the chief complaint symptoms through a sequence prediction model to obtain a first symptom sequence;
[0041] Among them, the elements in the first symptom sequence are that the target patient may have other undetected symptoms including the chief complaint symptoms; for symptoms that are undetected or not easily actively recognized by the patient, in order to improve the accuracy of the final predicted diagnosis result or syndrome type in the embodiment, such symptoms should also be considered. Specifically, in the embodiment, a sequence prediction model is trained, and the chief complaint symptoms extracted in step S300 are input into the sequence prediction model to predict the symptoms that need to be confirmed with the target patient next. Among them, the sequence prediction model may include, but is not limited to, a generative language model.
[0042] It should be noted that in the embodiment, according to the current question topic and the symptom content replied by the patient, the next major question to be asked is predicted. Among them, according to the traditional "ten questions" experience of traditional Chinese medicine diagnosis, the specific categories of the major questions are: cold and heat, sweating, pain, head, body, chest and abdomen, sleep, defecation and urination, appetite, diet and taste, menstruation and leucorrhea, etc. Taking the disease label of cough - wind-dryness injuring the lung as an example, the mapping table between the historical interrogation symptoms and the ten-question categories in the embodiment is shown in Table 1:
[0043] Table 1
[0044]
[0045] In the embodiment, the symptom questioning order generated by the sequence prediction model is not a fixed order of interrogation, but is selectively and systematically interrogated according to the patient's feedback; for example: in the embodiment, if the patient's chief complaint is catching a cold after getting cold while taking a bath, the next interrogation may be about the cold and heat problem, whether there are symptoms of aversion to cold and fever, and then further ask the patient whether there is limb pain.
[0046] S500. Update the candidate symptom sequence in response to the feedback information on the first symptom sequence to obtain a second symptom sequence;
[0047] Among them, the feedback information refers to the response or feedback of the target object to the symptom problems predicted by the sequence prediction model in step S400. Specifically, in the embodiment, the disease problems predicted through step S400 are: Are there symptoms of aversion to cold and fever? Further, is there a situation of limb pain? The feedback from the target object is: There is a situation of aversion to cold, occasional fever, but there is no situation of limb pain. According to the feedback content of the target object, in the candidate symptom sequence generated in step S200, limb pain is removed, and then the second symptom sequence is obtained.
[0048] It should be added that in most cases, the feedback content of the target object in the embodiment is free text content without format. In the process of screening the second symptom sequence in the embodiment, necessary natural language processing processes can be carried out to obtain corresponding corpus content for more convenient subsequent processing; in addition, there may be a large number of descriptions of degree adverbs in the feedback content of the target object. In the embodiment, the degree adverbs in the feedback content can be sorted by priority to determine the priority of each symptom in the second symptom sequence, further improving the accuracy of the final prediction result.
[0049] S600. Determine the target syndrome type of the target object according to the second syndrome elements corresponding to each symptom in the second symptom sequence;
[0050] Among them, the second syndrome element refers to the target syndrome element screened and sorted according to the feedback information of the target object through step S500; the target syndrome type refers to the diagnostic result determined by mapping the relationship between the target syndrome element and the traditional Chinese medicine syndrome type. Exemplarily, in the embodiment, after step S500, two second symptom sequences are generated; one sequence includes symptoms such as cold limbs, pale face, and low blood pressure, and it is determined that the corresponding target syndrome element is yang collapse in terms of disease nature; the symptom in the other sequence is weak heart sound, and it is determined that the corresponding target syndrome element is the heart in terms of disease location; according to the two target syndrome elements of yang collapse in terms of disease nature and the heart in terms of disease location, and according to the mapping relationship between the syndrome element and the syndrome type, the syndrome type of this patient is determined to be collapse of heart yang.
[0051] In order to improve the accuracy of the final prediction result of the method, in the process of offline solving the combination optimization between symptoms for syndrome element prediction in the embodiment, parameters such as entropy value and correlation relationship can be introduced to screen and adjust the syndrome element prediction result, and the availability of data in the intermediate process can be improved by means of quantile statistics; therefore, in some alternative embodiments, in the process of step S200 of adding historical interrogation symptoms to the candidate symptom sequence according to the first syndrome element, steps S210-S230 can be included:
[0052] S210. Determine the first entropy value of the first syndrome element, and screen the historical interrogation symptoms according to the first entropy value to obtain the first candidate symptom set;
[0053] Exemplarily, as Figure 3 shown, in the embodiment, classification models based on attention can be established for 50 core syndrome elements respectively; in the prediction stage of the embodiment, in order to evaluate the confidence of the overall prediction, the entropy of the prediction results of 50 syndrome element models is calculated. The greater the entropy, the greater the certainty of the overall prediction, and it is considered that the combination of symptoms is relatively clear for the predicted syndrome element. For example, in an embodiment, all 50 syndrome element models select the result with the largest entropy value in the output result as the predicted syndrome element, and use the symptoms input into the model as the candidate symptom set under this syndrome element, denoted as the first candidate symptom set. Specifically, the calculation formula of the entropy H(X) in the embodiment is:
[0054] H(X) = -∑ x∈X p(x)logp(x)
[0055] where p(x) is the probability of predicting the x-th syndrome element, x represents a certain syndrome element, and X represents the total number of syndrome elements.
[0056] S220. Screen out the target segment from the probability density function of the first syndrome element according to the configured quantile;
[0057] Specifically in the embodiment, using the statistical method of quantiles, select the symptoms among the syndrome elements with relatively high predicted probability density for 50 syndrome elements as the candidate symptoms to be screened. Among them, after setting the quantile, in each segment obtained, a relatively high probability density indicates that the discrimination of the syndrome element in this segment is not high, and this segment is denoted as the target segment, and further screening needs to be carried out according to the entropy value calculated in step S210.
[0058] Exemplarily, the model prediction probabilities of 50 syndrome elements can be divided according to the 4 - quantile, as shown in the newly added schematic diagram. Among them, Q1, Median, and Q3 represent the 25 - th quantile, 50 - th quantile, and 75 - th quantile respectively, and IQR represents the inter - quartile range. First, remove the outliers and extreme outliers in the lower quantile. The outliers and extreme outliers are the syndrome element points with low probability. Then, focus on identifying the syndrome element points in the remaining segments: Q1, Q1 - Q3, Q3 - upper outlier interval. For example, there are 3 different syndrome elements: yin deficiency, fire, and dryness, which are very close and overlapping syndrome elements between Q1 and Q3, and at this time, key identification is required.
[0059] S230. Determine the corresponding first candidate symptoms according to the attention weights between the first syndrome element and each candidate symptom in the first candidate symptom set in the target segment, and construct a candidate symptom sequence;
[0060] Specifically in the embodiment, the entropy value obtained according to step S210 and the result of the quantile statistics in step S220 are combined to obtain a candidate symptom set. To further improve the accuracy of the correspondence between syndrome elements and symptoms, in the embodiment, the candidate symptom set pair is further screened by calculating the attention weight; in the embodiment, the attention weight between the input symptom and the corresponding symptom under the syndrome element is used, and the one with the larger weight is preferentially selected as the candidate symptom. The greater the attention weight, the higher the correlation between the syndrome element and the input symptom. Finally, the candidate symptoms obtained by screening are combined to form a candidate symptom sequence.
[0061] To further improve the accuracy of the syndrome element prediction result, after the process of screening the historical interrogation symptoms according to the first entropy value in method step S210 to obtain the first candidate symptom set, the embodiment may include step S211 and step S212:
[0062] S211. Input the first candidate symptom into the syndrome element classification model to predict the third syndrome element;
[0063] Among them, the second entropy value of the third syndrome element is not less than the first entropy value. Specifically in the embodiment, to ensure that in steps S220 and S230, a series of candidate symptoms to be interrogated can be selected for each syndrome element that needs to be distinguished. The embodiment can add the candidate symptoms corresponding to different syndrome elements to the original input symptoms, and then input them into the syndrome element prediction model again. Calculate the entropy value of the syndrome element obtained from the prediction result, and compare it with the entropy before adding the candidate symptoms. Use the group of candidate symptoms with a larger entropy increase as the symptoms to be interrogated in this round.
[0064] S212. Construct a candidate symptom sequence according to the second candidate symptoms corresponding to the third syndrome element;
[0065] Exemplarily, when the embodiment adds the candidate symptoms corresponding to the syndrome element predicted in the first round to the historical interrogation symptoms, and then uses them as the original input symptoms in the second round and inputs them into the syndrome element classification model to obtain the syndrome element predicted in the second round. After calculating the entropy value in step S210, if it is determined that the entropy value in the second round is greater than that in the first round, then select the syndrome element in the second round and its corresponding symptoms to construct a candidate symptom sequence.
[0066] In some embodiments, during the process of dividing the quantile in step S220, the situation where the syndrome element point is located at the boundary may occur. To solve the boundary problem, in the embodiment, in the process of method S220 of screening the target segment from the probability density function of the first syndrome element according to the configured quantile, it may include step S221 and step S222:
[0067] S221. When the first syndrome element point in the probability density function is located in the segmented junction area, calculate the first distance between the first syndrome element point and the segment;
[0068] Among them, the first distance refers to the absolute value between the mean point of all evidence element points in the target segment and the first evidence element point. Specifically, in the embodiment, for evidence element points that are very close across segments, for example, the evidence element point of "fire" is between Q1-Q3 and is very close to the evidence element point of "yin deficiency" located in the >Q3 segment, then the two also need to be distinguished. The embodiment can calculate the distance between the evidence element point and each segment by calculating the absolute value between the means of all points in different quantile segments, and select the segment with a smaller distance as the belonging segment of the evidence element point.
[0069] It should be noted that in some alternative embodiments, the first distance can also be calculated by using the absolute value between the maximum value of the upper quantile and the minimum value of the lower quantile; or, the belonging segment of the evidence element point at the boundary can be determined by setting an empirical distance threshold.
[0070] S222. Determine the segment to which the first evidence element point belongs according to the first distance;
[0071] Exemplarily, in the embodiment, the calculated first distance (absolute value) between the evidence element point of "fire" and the Q1-Q3 segment is 10, and the calculated first distance (absolute value) between this evidence element point and the >Q3 segment is 12; then it is determined that the belonging segment of the evidence element point of "fire" is the Q1-Q3 segment.
[0072] In some alternative embodiments, the process of predicting the chief complaint symptoms by the sequence prediction model in the embodiment method S400 to obtain the first symptom sequence may include steps S410-S450:
[0073] S410. Perform vectorization processing on the chief complaint symptoms to obtain the first word embedding vector;
[0074] Exemplarily, as Figure 4 shown, the chief complaint symptoms R obtained by the embodiment: "red tongue, thick tongue coating, tooth marks on the tongue", first obtain the vectorized representation W of each word through word embedding; or character embedding can also be used. The embedding techniques adopted in the embodiment are all standard and general embedding techniques, so they will not be elaborated here. It should be noted that in the embodiment, since the chief complaint symptoms or symptom descriptions are usually a sentence, in some embodiments, a convolutional layer can be further used to convert multiple word vectors at the sentence level into a sentence vector representation S.
[0075] S420. Generate the first category embedding vector according to the way of obtaining the patient's symptom description;
[0076] Specifically, in the embodiments, the ways to obtain the symptom descriptions of patients include, but are not limited to, the chief complaints of patients or the ways of question-and-answer. To further improve the accuracy and usability of the output results of the sequence prediction model, the embodiments also use different symptom acquisition methods such as chief complaints and question-and-answer as the input data of the model and as one of the consideration factors for the output results. Exemplarily, in the embodiments, the vectorized representation C of the category is obtained according to the chief complaint of the patient through category embedding or entity embedding.
[0077] S430. Construct a first hidden layer vector from the first word embedding vector and the first category embedding vector;
[0078] Specifically, in the embodiments, in the hidden layer of the sequence prediction model, the category vector and the symptom description sentence vector are combined and concatenated to generate a hidden layer vector h = [C; S].
[0079] S440. Generate the distribution information of the target symptom through the softmax function according to the first hidden layer vector;
[0080] Specifically, in the sequence prediction model of the embodiments, the hidden layer vector h obtained in step S430 is input into the softmax function to finally obtain the distribution information of the target symptom; among them, the distribution information gives several candidate symptoms and the probability of the target symptom.
[0081] S450. Determine the target symptom according to the distribution information of the target symptom and construct a first symptom sequence;
[0082] Specifically, according to the distribution information in step S440, the candidate symptom with the highest probability is selected as the finally predicted target symptom. Exemplarily, as Figure 4 shown, in the embodiments, the acquisition method input into the sequence prediction model is the chief complaint; the specific symptom content of the chief complaint is: aversion to cold, fever, headache; a category embedding vector is generated according to the chief complaint, a word embedding vector is generated according to the symptom content of the chief complaint, and the category embedding vector and the word embedding vector are input into the hidden layer, and finally the target symptom to be determined in the next inquiry is cold and heat. It should be noted that in the embodiments, multiple iterations can be performed to generate several target symptoms to construct a first symptom sequence.
[0083] In some alternative embodiments, in order to accurately reflect the patient's context condition and improve the continuity of the interrogation process, after step S430. Construct a first hidden layer vector from the first word embedding vector and the first category embedding vector in the method, the following S431 - S434 may also be included:
[0084] S431. Perform vectorization processing on the interrogation content of the target object to obtain a second word embedding vector;
[0085] Among them, taking the generation of the first word embedding vector as the previous moment, the second word embedding vector refers to the embedding vector generated from the symptom content obtained by the target object's feedback on the previous moment's interrogation content at the next moment.
[0086] S432. Generate the second category embedding vector of the interrogation content;
[0087] Among them, the second category embedding vector refers to the category embedding vector of the way to obtain the target object's symptoms at the next moment. Exemplarily, at the current moment t>0, the category Q of the question is: asking about tongue diagnosis, and the symptom description R of the reply is: red tongue, thick tongue coating, and tooth marks on the tongue. First, in the embodiment, through category embedding or entity embedding, the vectorized representation C of the category is obtained; then through word embedding, the vectorized representation W of each word is obtained; alternatively, a convolutional layer is further used to convert multiple word vectors at the sentence level into a sentence vector representation S.
[0088] S433. Combine the first hidden layer vector, the second word embedding vector, and the second category embedding vector to obtain the second hidden layer vector;
[0089] Exemplarily, combine the question category vector and the symptom description sentence vector to generate the hidden layer vector h = [C; S]. The output of the previous moment t-1 is h'. Combine the hidden layers of the current moment and the previous moment to obtain h_o = [h; h'].
[0090] S434. Process the second hidden layer vector through the softmax function to obtain the target symptom;
[0091] Exemplarily, obtain the symptom distribution at the current moment through Softmax(W_o*h_o); similar to step S450, finally obtain the target symptom that needs to be determined by interrogation at the next moment.
[0092] It should be noted that in the technical solution of this application, the application of the sequence prediction model is not a simple application of the traditional language model. Instead, at the input layer, the category and symptom description of the interrogation are respectively processed with distributed representations, which generally serves to solve the problem in the process of traditional Chinese medicine interrogation that, dynamically based on the patient's answers, the relevance between the previous question and the next question is made closer. Similarly, other language models can also be applied in the implementation; through the category generation method, it has high content controllability and avoids the problem of uncontrollable content generation by language models with a large number of parameters.
[0093] In some alternative embodiments, in the process of step S230 of the method according to the attention weights between the first syndrome element and each candidate symptom in the first candidate symptom set in the target segment, steps S231-234 may be included:
[0094] S231. Vectorize the historical interview symptoms to obtain a number of third word embedding vectors, and vectorize the first syndrome element to obtain a syndrome element vector;
[0095] Specifically in the embodiment, first, perform word segmentation on the historical interview symptoms to obtain a number of single-word corpora, vectorize the obtained single-word corpora to obtain word embedding vectors, denoted as third word vectors; and also vectorize the syndrome elements obtained through the syndrome element classification model to obtain syndrome element vectors.
[0096] S232. Multiply the third word embedding vector by a preset first weight matrix to obtain a key vector;
[0097] Specifically in the embodiment, first, take both the third word embedding vector and the syndrome element vector as input vectors, and generate three new vectors through an encoder. The three new vectors include: a query vector, a key vector, and a value vector. These three vectors are created by multiplying the word embedding by three weight matrices. It should be noted that in the embodiment, the three new vectors have a lower dimension than the word embedding vector, and their dimension is 64, while the dimension of the input and output vectors of the encoder is 512.
[0098] S233. Multiply the syndrome element vector by a preset second weight matrix to obtain a query vector;
[0099] Specifically in the embodiment, create a query vector, a key vector, and a value vector for each word, where the words include syndrome elements and the words obtained by word segmentation of the historical interview symptoms.
[0100] S234. Normalize the dot product operation result of the key vector and the query vector to obtain an attention weight;
[0101] Specifically in the embodiment, the score of the attention weight is calculated by taking the dot product of the key vector of the scoring word and the query vector of the syndrome element. Among them, the scoring word refers to all the words obtained by word segmentation in step S231; then divide the score by 8, and 8 is the square root of the dimension 64 of the key vector used in the embodiment, which makes the gradient more stable. Other values can also be used here, and 8 is just the default value, and then pass the result through softmax. The role of softmax is to normalize the scores of all words, and the obtained scores are all positive values and sum to 1.
[0102] According to the appendix Figure 2 , taking a specific application scenario as an example, specifically illustrate the actual application of a medical information processing method of the technical solution of the present application:
[0103] In the embodiment, a first-round sorting is first performed. An offline classification model with an attention mechanism is trained to solve the problem of combinatorial optimization among symptoms for syndrome element prediction. The entropy increase of the prediction results of the offline model and the correlation degree among symptoms in the offline model are used to sort the candidate symptoms to be inquired under each syndrome element in units of syndrome elements.
[0104] Then, a second-round sorting is performed. The embodiment trains a sequence prediction model for the question category asking order of traditional Chinese medicine interrogation. According to the current question theme and the symptom content replied by the patient, the next question category to be asked is predicted. The embodiment obtains the real conversation content as the input of the sequence prediction model, and transforms the process of the ten questions of traditional Chinese medicine into a sequence prediction problem. By default, the interrogation starting with collecting the main complaint symptoms of the patient is used to predict the next ten-question category to be inquired. Given the mapping relationship between symptoms and ten-question categories, a second-round comprehensive sorting is performed on the symptoms in the first-round sorting to adjust the sorting priority of the symptoms under the next ten-question classification to be inquired.
[0105] Finally, all the symptoms of the patient are determined according to the patient's feedback, and the syndrome elements of the symptoms are further determined. Finally, the final diagnosis result can be determined according to the mapping relationship between syndrome elements and syndrome types.
[0106] Those skilled in the art can understand that the embodiments or implementation manners of the present application can be extended to other application scenarios other than traditional Chinese medicine interrogation, which will not be elaborated one by one here.
[0107] As Figure 5 shown, the embodiment of the present invention provides a processing system for medical information, and the system includes:
[0108] A first symptom screening unit 500, configured to obtain historical interrogation symptoms, predict the historical interrogation symptoms through a syndrome element classification model to obtain the first syndrome element corresponding to the historical interrogation symptoms; and add the historical interrogation symptoms to the candidate symptom sequence according to the first syndrome element;
[0109] A second symptom screening unit 510, configured to identify the main complaint symptoms from the symptom description of the target object; predict the main complaint symptoms through a sequence prediction model to obtain a first symptom sequence;
[0110] A target symptom generation unit 520, configured to update the candidate symptom sequence in response to the feedback information on the first symptom sequence to obtain a second symptom sequence;
[0111] A target syndrome type determination unit 530, configured to determine the target syndrome type of the target object according to the second syndrome element corresponding to each symptom in the second symptom sequence.
[0112] Exemplarily, the first symptom screening unit 500 in the embodiment system first trains an attention model for predicting syndrome elements. In the prediction stage of the attention model, in order to evaluate the confidence of the overall prediction of the solution, the entropy of the prediction results of 50 syndrome element models is calculated, and the combination of symptoms corresponding to the predicted syndrome element with a larger entropy value is selected for further screening processing; next, the first symptom screening unit 500 uses the statistical method of quantiles to focus on the syndrome elements in the segments with a relatively high prediction probability density of 50 kinds of syndrome elements, and selects the symptoms among them as candidate symptoms to be questioned. Among them, the criterion for symptom selection is: the magnitude of the attention weight between the input symptom and the corresponding symptom under this syndrome element, and the symptom with a larger weight is preferentially selected as the candidate symptom, and a candidate symptom sequence is obtained according to the candidate symptoms.
[0113] Then, the second symptom screening unit 510 outputs a first symptom sequence through the sequence prediction model. Among them, the input of the sequence prediction model includes the intermediate hidden layer vector of the predicted inquiry category at the previous moment, the entity embedding vector of the real inquiry category at the current moment, and the vector encoded from the list of patient response symptoms for the inquiry category at the current moment. The default initial state of the inquiry category of the sequence prediction model is the chief complaint. The output of the sequence prediction model is the discomfort symptoms that the patient may have, that is, the symptoms that need to be inquired about at the next moment, and a first symptom sequence is formed in chronological order.
[0114] After that, the target symptom generation unit 520 obtains the second symptom sequence of the patient for the candidate symptom sequence according to the user's feedback on the symptoms in the first symptom sequence.
[0115] Finally, the second symptom sequence is input into the target syndrome type determination unit 530. The target syndrome element is determined according to the second symptom sequence, and the target syndrome type is further determined to obtain a diagnosis result.
[0116] As Figure 6 shown, an embodiment of the present invention proposes a medical information processing terminal 600. The terminal 600 includes a memory 610, a processor 620, a program stored on the memory and executable on the processor, and a data bus 630 for realizing the connection and communication between the processor 610 and the memory 620. When the program is executed by the processor, the following specific steps as Figure 2 shown are implemented:
[0117] Step S100, obtain historical inquiry symptoms, predict the historical inquiry symptoms through a syndrome element classification model, and obtain the first syndrome element corresponding to the historical inquiry symptoms;
[0118] Specifically, the syndrome element classification model in the embodiment can adopt a deep learning model with an attention mechanism (Attention). For example, a classification model with a Transformer structure can be adopted in the embodiment. The model includes a self-attention layer and a fully connected layer, which can effectively solve the problem of combinatorial optimization between symptoms for syndrome element prediction.
[0119] Step S200: Add the historical interrogation symptoms to the candidate symptom sequence according to the first syndrome element;
[0120] Specifically, the embodiment can construct several attention-based classification models according to the core syndrome elements in traditional Chinese medicine diagnosis and treatment, and group the historical interrogation symptoms input into the classification model according to the syndrome elements finally predicted by the classification model. That is, the symptoms included in each syndrome element group are the symptoms that this syndrome element may show in the patient. The symptoms included in each syndrome element group constitute the candidate symptoms of this syndrome element.
[0121] Step S300: Identify the chief complaint symptom from the symptom description of the target object;
[0122] Specifically, the embodiment can obtain the symptom description content of the target patient's discomfort through a human-computer interaction device or manual input, and then extract the chief complaint symptom of the target patient through corresponding word segmentation and natural language processing processes.
[0123] Step S400: Predict the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence;
[0124] Specifically, the embodiment trains a sequence prediction model, inputs the chief complaint symptom extracted in step S300 into the sequence prediction model to predict the symptom situation that needs to be confirmed with the target patient next. Among them, the sequence prediction model can include but is not limited to a generative language model.
[0125] Step S500: Update the candidate symptom sequence in response to the feedback information on the first symptom sequence to obtain a second symptom sequence;
[0126] Specifically, according to the feedback content of the target object, the embodiment removes limb pain from the candidate symptom sequence generated in step S200 to obtain a second symptom sequence.
[0127] Step S600: Determine the target syndrome type of the target object according to the second syndrome elements corresponding to the symptoms in the second symptom sequence;
[0128] Among them, the second syndrome element refers to the target syndrome element after screening and sorting according to the feedback information of the target object through step S500; the target syndrome type refers to the diagnostic result determined by mapping the relationship between the target syndrome element and the traditional Chinese medicine syndrome type.
[0129] An embodiment of the present invention also provides a computer-readable storage medium, which stores one or more programs, and the one or more programs can be executed by one or more processors to implement the following as Figure 2 shown specific steps:
[0130] S100. Obtain historical interrogation symptoms, and predict the historical interrogation symptoms through a syndrome element classification model to obtain the first syndrome element corresponding to the historical interrogation symptoms;
[0131] S200. Add the historical interrogation symptoms to the candidate symptom sequence according to the first syndrome element;
[0132] S300. Identify the main complaint symptom from the symptom description of the target object;
[0133] S400. Predict the main complaint symptom through a sequence prediction model to obtain the first symptom sequence;
[0134] S500. In response to the feedback information on the first symptom sequence, update the candidate symptom sequence to obtain the second symptom sequence;
[0135] S600. Determine the target syndrome type of the target object according to the second syndrome element corresponding to each symptom in the second symptom sequence;
[0136] Exemplarily, the embodiment first performs the first-round sorting. An offline classification model with an attention mechanism is trained to solve the problem of combinatorial optimization between symptoms for syndrome element prediction; and the entropy increase situation of the prediction result of the offline model and the correlation degree between symptoms in the offline model are used to sort the candidate symptoms to be interrogated under each syndrome element in units of syndrome elements.
[0137] Then, the second-round sorting is performed. The embodiment trains a sequence prediction model for the question category asking order of traditional Chinese medicine interrogation. According to the current question theme and the symptom content replied by the patient, the next question category to be asked is predicted. The embodiment obtains the real conversation content as the input of the sequence prediction model, and transforms the process of traditional Chinese medicine's ten questions into a sequence prediction problem; by default, it starts with the interrogation of collecting the main complaint symptoms of the patient, and predicts the next ten-question category to be interrogated. Given the mapping relationship between symptoms and ten-question categories, for the symptoms in the first-round sorting, the second-round comprehensive sorting is performed to adjust the sorting priority of the symptoms under the next ten-question classification to be interrogated.
[0138] Finally, all the symptoms of the patient are determined based on the patient's feedback, and the syndrome elements of the symptoms are further determined. Finally, the final diagnosis result can be determined according to the mapping relationship between the syndrome elements and the syndrome types.
[0139] In summary, a method, system, computer terminal, and storage medium for processing medical information proposed in the embodiments of the present application have the following advantages or advantages compared with the existing technical solutions for text sentiment analysis:
[0140] 1) The symptom recommendation process centered on syndrome elements in the technical solution of the present application can fully reflect the general thinking of traditional Chinese medicine diagnosis.
[0141] 2) The symptom recommendation based on the ten questions of traditional Chinese medicine in the technical solution of the present application reflects the experience precipitation of the interrogation strategy of traditional Chinese medicine; at the same time, the solution is not limited to template-based questions and can achieve dynamic communication with the patient.
[0142] 3) The technical solution of the present application can realize the organic integration of the inheritance of traditional Chinese medicine experience and modern technology.
[0143] 4) The intermediate results of syndrome element prediction and interrogation action prediction in the technical solution of the present application are interpretable and can be visually presented during the interaction with the user, with stronger interactivity.
[0144] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results. The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. And the artificial intelligence software technology can include, but is not limited to: several major directions such as computer vision technology, robotics, biometric technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0145] In addition, the present application can be used in numerous general-purpose or special-purpose computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, and so on. The present application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in a distributed computing environment where tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in both local and remote computer storage media including storage devices.
[0146] In some other alternative embodiments, the functions / operations mentioned in the block diagrams may not occur in the order mentioned in the operation diagrams. For example, depending on the functions / operations involved, two consecutive blocks shown may actually be executed substantially simultaneously or the blocks can sometimes be executed in the reverse order. In addition, the embodiments presented and described in the flowcharts of the present invention are provided by way of example for the purpose of providing a more comprehensive understanding of the technology. The disclosed methods are not limited to the operations and logical flows presented herein. Alternative embodiments are contemplated where the order of various operations is changed and where sub-operations described as part of a larger operation are executed independently.
[0147] It should be understood that unless otherwise stated to the contrary, one or more of the functions and / or features can be integrated in a single physical device and / or software module, or one or more functions and / or features can be implemented in separate physical devices or software modules. It can also be understood that a detailed discussion of the actual implementation of each module is not necessary for understanding the present invention. Rather, given the attributes, functions, and internal relationships of the various functional modules in the devices disclosed herein, the actual implementation of the modules will be understood within the ordinary skill of an engineer. Thus, those skilled in the art can implement the present invention as set forth in the claims without undue experimentation. It can also be understood that the specific concepts disclosed are illustrative only and are not intended to limit the scope of the present invention, which is determined by the full scope of the appended claims and their equivalents.
[0148] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a definable sequence list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, apparatus or terminal (such as a computer-based system, a system including a processor, or other systems that can fetch instructions from the instruction execution system, apparatus or terminal and execute the instructions), or used in combination with these instruction execution systems, apparatuses or terminals.
[0149] In the description of this specification, the description referring to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. means that the specific features, structures, materials or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic expressions of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in a suitable manner in any one or more embodiments or examples.
[0150] Although the embodiments of the present invention have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, substitutions and variations can be made to these embodiments without departing from the principles and purposes of the present invention, and the scope of the present invention is defined by the claims and their equivalents.
[0151] The above has specifically described the preferred embodiments of the present invention, but the present invention is not limited to the above embodiments. Those skilled in the art can also make various equivalent deformations or substitutions without departing from the spirit of the present invention, and these equivalent deformations or substitutions are all included within the scope defined by the claims of this application.
Claims
1. A method for processing medical information, characterized in that, the method comprises the following steps: Obtain historical consultation symptoms, and predict the historical consultation symptoms through a syndrome element classification model to obtain a first syndrome element corresponding to the historical consultation symptoms; Determine a first entropy value of the first syndrome element, and screen the historical consultation symptoms according to the first entropy value to obtain a first candidate symptom set; Screen a target segment from the probability density function of the first syndrome element according to a configured quantile; Determine corresponding first candidate symptoms according to the attention weights between the first syndrome element in the target segment and each candidate symptom in the first candidate symptom set, and construct a candidate symptom sequence; Identify the chief complaint symptom from the symptom description of the target object; Predict the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence; wherein, the first symptom sequence is used to represent the symptom questioning order; In response to the feedback information on the first symptom sequence, update the candidate symptom sequence to obtain a second symptom sequence, including at least: performing a priority ranking on the degree adverbs in the feedback information to determine the priority of each symptom in the second symptom sequence; Determine the target syndrome type of the target object according to the second syndrome elements corresponding to the respective symptoms in the second symptom sequence.
2. The method for processing medical information according to claim 1, characterized in that, after the step of screening the historical consultation symptoms according to the first entropy value to obtain a first candidate symptom set, the processing method comprises: Input the first candidate symptom into the syndrome element classification model, and predict to obtain a third syndrome element; wherein, a second entropy value of the third syndrome element is not less than the first entropy value; Construct the candidate symptom sequence according to the second candidate symptoms corresponding to the third syndrome element.
3. The method for processing medical information according to claim 1, characterized in that, the screening of the target segment from the probability density function of the first syndrome element according to a configured quantile includes: When the first syndrome element point in the probability density function is located in the segment intersection region, calculate a first distance between the first syndrome element point and the segment adjacent to the segment intersection region; Determine the segment to which the first syndrome element point belongs according to the first distance; wherein, the first distance is the absolute value between the mean point of all syndrome element points in the target segment and the first syndrome element point.
4. The method for processing medical information according to claim 1, characterized in that, the prediction of the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence includes: Perform a vectorization process on the chief complaint symptom to obtain a first word embedding vector; Generate a first category embedding vector according to the symptom description mode of the obtained patient; Construct a first hidden layer vector by combining the first word embedding vector and the first category embedding vector; Generate distribution information of the target symptom according to the first hidden layer vector through a softmax function; Determine the target symptom according to the distribution information of the target symptom, and construct the first symptom sequence.
5. The method for processing medical information according to claim 4, characterized in that, After the step of constructing the first hidden layer vector by using the first word embedding vector and the first category embedding vector, the processing method includes: Performing vectorization processing on the inquiry content of the target object to obtain a second word embedding vector; Generating a second category embedding vector of the inquiry content; Combining the first hidden layer vector, the second word embedding vector, and the second category embedding vector to obtain a second hidden layer vector; Processing the second hidden layer vector through the softmax function to obtain the target symptom.
6. A method for processing medical information according to claim 1, wherein, the attention weights between the first syndrome element in the target segment and each candidate symptom in the first candidate symptom set include: Performing vectorization processing on the historical inquiry symptoms to obtain a plurality of third word embedding vectors, and performing vectorization processing on the first syndrome element to obtain a syndrome element vector; Multiplying the third word embedding vector by a preset first weight matrix to obtain a key vector; Multiplying the syndrome element vector by a preset second weight matrix to obtain a query vector; Normalizing the dot product operation result of the key vector and the query vector to obtain the attention weight.
7. A medical information processing system, wherein, it includes: A first symptom screening unit, configured to obtain historical inquiry symptoms, predict the historical inquiry symptoms through a syndrome element classification model to obtain the first syndrome element corresponding to the historical inquiry symptoms; and determine the first entropy value of the first syndrome element, screen the historical inquiry symptoms according to the first entropy value to obtain a first candidate symptom set, screen a target segment from the probability density function of the first syndrome element according to a configured quantile, and determine a corresponding first candidate symptom to construct a candidate symptom sequence according to the attention weights between the first syndrome element in the target segment and each candidate symptom in the first candidate symptom set; A second symptom screening unit, configured to identify the chief complaint symptom from the symptom description of the target object; predict the chief complaint symptom through a sequence prediction model to obtain a first symptom sequence; wherein, the first symptom sequence is used to represent the symptom questioning order; A target symptom generation unit, configured to update the candidate symptom sequence in response to the feedback information of the first symptom sequence to obtain a second symptom sequence, including at least: sorting the degree adverbs in the feedback information by priority to determine the priority of each symptom in the second symptom sequence; A target syndrome determination unit, configured to determine the target syndrome of the target object according to the second syndrome elements corresponding to the respective symptoms in the second symptom sequence.
8. A medical information processing terminal, wherein, the terminal includes a memory, a processor, a program stored on the memory and executable on the processor, and a data bus for realizing connection communication between the processor and the memory. When the program is executed by the processor, it implements the method for processing medical information according to any one of claims 1-6.
9. A storage medium for computer-readable storage, wherein, The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement a method for processing medical information according to any one of claims 1 to 6.
Citation Information
Patent Citations
Named entity labeling method and device, computer equipment and storage medium
CN111651992A
Method, system, electronic equipment and readable storage medium for identifying TCM syndrome elements
CN111768842A
Traditional Chinese medicine intelligent inquiry tongue diagnosis comprehensive system based on syndrome elements and deep learning
CN112216383A
Syndrome differentiation model-based Chinese and western fusion special disease syndrome differentiation method
CN112397160A
Intelligent medical inquiry device, equipment and medium
CN112750529A