Chinese medicine syndrome differentiation method and device combining syndrome differentiation and ten syndrome differentiation
By combining the TCM diagnostic methods of syndrome element differentiation and ten-principle differentiation, the location and nature of the disease in the medical record text are determined and graphically presented in the ten-principle diagram. This solves the problem of the independence of syndrome element differentiation and ten-principle differentiation, and achieves the accuracy of etiology determination and the intuitiveness of analysis results.
Patent Information
- Application Number
- CN202310933716.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-27
- Publication Date
- 2026-11-24
- Estimated Expiration
- 2043-07-27
AI Technical Summary
In existing TCM diagnostic methods, the two systems of syndrome element differentiation and ten-principle differentiation have not been organically integrated, resulting in inaccurate determination of etiology and less intuitive analysis results.
Combining the TCM diagnostic methods of syndrome element differentiation and ten-principle differentiation, this paper derives the coordinates of syndrome elements in the ten-principle diagram by determining the list of syndrome elements of disease location and disease nature in the medical record text, and presents the diagnostic results graphically.
It achieves greater accuracy in determining the etiology and greater intuitiveness in the results of syndrome differentiation and analysis, thereby improving the accuracy of etiological diagnosis and presenting the results graphically.
Smart Images

Figure CN117198544B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of information processing technology, and in particular relates to a TCM diagnostic method, device and computer-readable storage medium that combines syndrome element differentiation and ten-principle differentiation. Background Technology
[0002] Throughout the long history of Traditional Chinese Medicine (TCM) theory, the deepening understanding of disease differentiation has gradually led to the development of various diagnostic methods, such as the Eight Principles of Differentiation, Etiology Differentiation, Meridian Differentiation, Qi, Blood, and Body Fluid Differentiation, Triple Energizer Differentiation, Zang-Fu Organ Differentiation, Six Channels Differentiation, and Wei-Qi-Ying-Xue Differentiation. Among these, the TCM Syndrome Element Differentiation and the Eight Principles of Differentiation serve as the guiding principles for various TCM diagnostic methods, both possessing the function of simplifying complex concepts and providing a clear framework. Based on the Eight Principles of Differentiation system, the Ten Principles of Differentiation adds two more principles (upper and lower), forming ten diagnostic categories, making it more complete and comprehensive than the Eight Principles of Differentiation. However, Syndrome Element Differentiation and the Ten Principles of Differentiation remain two independent diagnostic systems, and no single system can organically integrate these two systems. Summary of the Invention
[0003] This application provides a TCM diagnostic method, device, and computer-readable storage medium that combines syndrome element differentiation and ten-principle differentiation, which can combine syndrome element differentiation and ten-principle differentiation to solve the problem that traditional TCM diagnostic methods are relatively independent.
[0004] In a first aspect, embodiments of this application provide a TCM diagnostic method that combines syndrome element differentiation and ten-principle differentiation, including:
[0005] Based on the patient's medical record text, determine the list of disease location syndrome elements and the list of disease nature syndrome elements in the medical record text;
[0006] Based on the list of disease location syndrome elements and the list of disease nature syndrome elements, a syndrome element grouping list is obtained;
[0007] Based on the evidence element grouping list, determine the point coordinates of each evidence element in the ten-line diagram.
[0008] Based on the coordinates of each group of evidence elements in the Ten-Point Diagram, auxiliary points are derived, and the evidence element identification results are graphically presented in the Ten-Point Diagram.
[0009] In one possible implementation, obtaining the syndrome element grouping list based on the disease location syndrome element list and the disease nature syndrome element list includes:
[0010] One disease location syndrome element and one disease nature syndrome element are sequentially taken from the disease location syndrome element list and the disease nature syndrome element list and written into the group syndrome element queue until the number of syndrome elements in the group syndrome element queue reaches a preset threshold.
[0011] Add the grouped evidence element queue to the evidence element grouping list;
[0012] Repeat the above two steps until the number of grouped evidence queues in the evidence grouping list reaches a preset threshold.
[0013] In one possible implementation, determining the point coordinates of each group of evidence elements in the ten-line diagram based on the evidence element grouping list includes:
[0014] Based on the evidence element grouping list and combined with the evidence element dictionary, the ten-category attributes of each evidence element group in the evidence element grouping list are obtained.
[0015] Based on the ten-category attributes of each group of evidence elements, determine the relevant information of the coordinates of each group of evidence elements in the ten-category diagram, and store them in the coordinate term list.
[0016] Based on the list of coordinate terms, the point coordinates of each group of evidence elements in the ten-line diagram are obtained.
[0017] In one possible implementation, obtaining the point coordinates of each group of evidence elements in the ten-line diagram based on the coordinate term list includes:
[0018] Based on the list of coordinate terms, determine the list of positive coordinate terms and the list of negative coordinate terms;
[0019] Based on the lists of positive and negative coordinate terms, determine the list of primary coordinate terms;
[0020] The point coordinates are obtained based on the list of main coordinate terms and the list of coordinate types arranged according to the ten-category attribute types.
[0021] In one possible implementation, obtaining the point coordinates based on the list of main coordinate terms and the list of coordinate types arranged according to the ten-category attribute types includes:
[0022] Match the records in the main term list with the coordinate type list arranged according to the ten-category attribute type. If a match is found, record the index position of the coordinate type list and assign the relevant information of the record in the main coordinate term list to the index position of the predefined variable list.
[0023] Repeat the above steps until the number of matched records reaches the preset value.
[0024] In one possible implementation, the relevant information of the point coordinates includes: the score value of the corresponding point coordinates, the participating elements, the number of element derivations, and the point coordinate display name. The step of determining the relevant information of the point coordinates of each group of elements in the element grouping list on the ten-line map based on the ten-line attributes of each group of elements includes:
[0025] Write the elements with the same point coordinate type in each group of the syndrome element grouping list into a temporary syndrome element list, wherein the point coordinate type includes: heat, lower, interior, deficiency, cold, upper, surface and solid.
[0026] Based on the temporary evidence list, determine the scoring value of the corresponding point coordinates, the evidence involved, the number of elements derived, and the display name of the point coordinates.
[0027] In one possible implementation, deriving auxiliary points based on the coordinates of each set of elements in the ten-line diagram includes:
[0028] Based on the number and location of the point coordinates, determine the coordinates of the auxiliary points.
[0029] In one possible implementation, determining the coordinates of the auxiliary points based on the number and location of the point coordinates includes:
[0030] If the number of points with values in the coordinates of the given point is one, then an auxiliary point is added to its left and right based on the position of the given point.
[0031] If there are two points with values in the coordinates of the point, then determine whether the two coordinates are opposing points, and determine the coordinates of the auxiliary point based on the opposing situation and the position of the coordinates of the point.
[0032] If there are three points with values in the coordinates of the points, then based on the coordinates of the points with values, determine whether the coordinates of the auxiliary points return to the center point or to the points with values.
[0033] If the number of points with values in the coordinate system is four, then determine whether the four coordinate systems are at points that are mutually opposing each other, and determine the coordinates of the auxiliary points based on the opposing situation and the position of the coordinate systems.
[0034] Secondly, embodiments of this application provide a traditional Chinese medicine diagnostic device that combines syndrome element differentiation and ten-principle differentiation, comprising:
[0035] The syndrome element list determination module determines the syndrome element list of the location of the disease and the syndrome element list of the disease nature in the patient's medical record text.
[0036] The syndrome element grouping list determination module obtains the syndrome element grouping list based on the disease location syndrome element list and the disease nature syndrome element list;
[0037] The point coordinate determination module determines the point coordinates of each group of evidence in the ten-line diagram based on the evidence grouping list.
[0038] The results display module derives auxiliary points based on the coordinates of each group of evidence elements in the Ten-Outline Diagram and presents the evidence element identification results graphically in the Ten-Outline Diagram.
[0039] Thirdly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described above.
[0040] Beneficial effects of this application
[0041] This application relates to the field of information processing technology and provides a TCM diagnostic method and apparatus that combines syndrome element differentiation and ten-principle differentiation. The method includes: determining a list of disease location syndrome elements and a list of disease nature syndrome elements in the patient's medical record text; obtaining a syndrome element grouping list based on the disease location syndrome element list and the disease nature syndrome element list; determining the coordinates of each syndrome element group in the ten-principle diagram based on the syndrome element grouping list; deriving auxiliary points based on the coordinates of each syndrome element group in the ten-principle diagram; and graphically presenting the syndrome element differentiation results in the ten-principle diagram. The TCM diagnostic method provided by this application integrates the syndrome element differentiation method and the ten-principle differentiation method for comprehensive analysis of medical record data. Using this method, the determination of the etiology can be more accurate, and the results of the diagnostic analysis can be displayed in a more intuitive graphical manner. Attached Figure Description
[0042] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0043] Figure 1 This is one of the flowcharts of a traditional Chinese medicine diagnostic method provided in an embodiment of this application;
[0044] Figure 2 This is a second flowchart illustrating a traditional Chinese medicine diagnostic method provided in an embodiment of this application;
[0045] Figure 3 This is the third flowchart of a traditional Chinese medicine diagnostic method provided in an embodiment of this application;
[0046] Figure 4 This is the fourth flowchart of a traditional Chinese medicine diagnostic method provided in an embodiment of this application;
[0047] Figure 5 This is the fifth flowchart of a traditional Chinese medicine diagnostic method provided in an embodiment of this application;
[0048] Figure 6 This is a diagram of ten outlines provided in one embodiment of this application;
[0049] Figure 7 This is a schematic diagram of auxiliary points provided in an embodiment of this application;
[0050] Figure 8 This is a schematic diagram of the etiology determination device provided in the embodiments of this application. Detailed Implementation
[0051] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.
[0052] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0053] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0054] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."
[0055] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0056] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0057] Throughout the long history of Traditional Chinese Medicine (TCM) theory, the deepening understanding of disease differentiation has gradually led to the development of various diagnostic methods, such as the Eight Principles of Differentiation, Etiology Differentiation, Meridian Differentiation, Qi, Blood, and Body Fluid Differentiation, Triple Energizer Differentiation, Zang-Fu Organ Differentiation, Six Channels Differentiation, and Wei-Qi-Ying-Xue Differentiation. Among these, Syndrome Element Differentiation and the Eight Principles of Differentiation serve as the guiding principles for various TCM diagnostic methods, both possessing the function of simplifying complex concepts and providing a clear framework. Based on the Eight Principles of Differentiation system, the Ten Principles of Differentiation adds two more principles (upper and lower), forming ten diagnostic categories, making it more complete and comprehensive than the Eight Principles of Differentiation. However, Syndrome Element Differentiation and the Ten Principles of Differentiation remain two independent diagnostic systems, and no single system can organically integrate these two systems.
[0058] This application relates to the field of information processing technology and provides a TCM diagnostic method, apparatus, and computer-readable storage medium that combines syndrome element differentiation and ten-principle differentiation. The method includes: acquiring medical record data to be determined; inputting the medical record data into a TCM diagnostic model to obtain syndrome element differentiation results, wherein the TCM diagnostic model is established based on the methods of syndrome element differentiation and ten-principle differentiation; and presenting the TCM diagnostic results in a ten-principle diagram. The TCM diagnostic method provided by this application integrates syndrome element differentiation and ten-principle differentiation to comprehensively analyze medical record data. Using this method, the determination of etiology can be more accurate, and the results of the diagnostic analysis can be displayed in a more intuitive graphical manner.
[0059] To illustrate the technical solution of this application, specific embodiments are described below.
[0060] See Figure 1 The flowchart of one embodiment of the TCM diagnostic method combining syndrome element differentiation and ten-principle differentiation, shown as an example and not a limitation, includes the following steps:
[0061] Step S1: Based on the patient's medical record text, determine the list of disease location syndrome elements and the list of disease nature syndrome elements in the medical record text;
[0062] Step S2: Based on the list of disease location syndrome elements and the list of disease nature syndrome elements, obtain a syndrome element grouping list;
[0063] Step S3: Based on the evidence element grouping list, determine the point coordinates of each evidence element in the ten-line diagram;
[0064] Step S4: Based on the coordinates of each group of evidence elements in the Ten-Element Diagram, deduce the auxiliary points and graphically present the evidence element identification results in the Ten-Element Diagram.
[0065] To better understand this plan, we will first give a brief introduction to the syndrome element differentiation and the ten principles differentiation.
[0066] The concept of syndrome element differentiation was proposed and researched by Professor Zhu Wenfeng in 1976, and has gradually developed into a TCM syndrome differentiation system centered on syndrome elements. Syndrome element differentiation is a complete cognitive process, with syndrome elements representing the essence of pathology. Clinically, it combines the four diagnostic methods (inspection, auscultation and olfaction, palpation, and inquiry) of patients to quantitatively determine the syndrome elements and identify the location, nature, and other characteristics of the disease. Syndrome element differentiation reveals the universal laws, essence, and characteristics of TCM syndrome differentiation. It is easy to learn, convenient to operate clinically, and allows for flexible identification and treatment of various clinical syndromes, fully embodying the scientific nature of TCM. It is a new system of syndrome differentiation with significant implications for the development of TCM.
[0067] The Eight Principles of Differentiation is the general framework and fundamental method of all syndrome differentiation in Traditional Chinese Medicine (TCM). It involves a comprehensive analysis of the patient's four diagnostic methods (inspection, auscultation and olfaction, palpation, and palpation) to explore the nature of the disease, the location of the lesion, the severity of the disease, the strength of the body's reaction, and the balance between pathogenic factors and the body's resistance. This is summarized into eight major categories: Yin, Yang, Exterior, Interior, Cold, Heat, Deficiency, and Excess, encompassing various manifestations of the disease. The Ten Principles of Differentiation, building upon the Eight Principles system, adds two more categories, Upper and Lower, forming ten diagnostic categories. Originating in the *Neijing* (Inner Canon of Medicine), it supplements and enriches the Eight Principles. The Ten Principles Diagram best embodies the Ten Principles of Differentiation. Yin and Yang are the overarching principles; in the Ten Principles Diagram, categories may not be listed, but rather the Yin and Yang divisions are used to unify the four pairs of the Eight Principles.
[0068] It should be noted that in this embodiment, the syndrome elements are first intelligently grouped based on the location and nature of the disease; then, based on the ten-principle attributes of the syndrome elements, the coordinates of the grouped syndrome elements in the ten-principle diagram are calculated, and auxiliary points are derived based on the coordinates of the grouped syndrome elements in the ten-principle diagram; finally, the syndrome element differentiation results are graphically presented in the ten-principle diagram. Through the above method, while defining the location and nature of the disease elements, the ten-principle attributes can be assigned to them, organically integrating the TCM syndrome element differentiation system and the ten-principle differentiation expression. After integrating the syndrome element differentiation method and the ten-principle differentiation method, the medical record data can be comprehensively analyzed. Therefore, using this scheme can make the determination of etiology more accurate and comprehensive, and the results of the differentiation analysis can be displayed in a more intuitive graphical way.
[0069] In one possible approach, step S1 (determining the list of location elements and the list of nature elements in the patient's medical record text) includes:
[0070] M1: Based on the patient's medical record text, obtain the set of four diagnostic elements;
[0071] M2: Based on the combination of the four diagnostic elements, a list of syndrome elements is obtained;
[0072] M3: Based on the list of syndrome elements, obtain the list of syndrome elements at the location of the disease and the list of syndrome elements related to the nature of the disease.
[0073] It should be noted that step M1 specifically includes: M11: obtaining medical record keywords based on the medical record data to be determined; M12: matching the medical record keywords with the element dictionary to obtain an element set; M13: obtaining the four diagnostic elements set based on the element set.
[0074] It should be noted that in step M11, the medical record data to be determined is natural language text, which can be the medical record text of a virtual patient or the medical record text from a clinical patient. Natural language processing technology is used to parse the medical record data to be determined to obtain medical record keywords.
[0075] It should be noted that in step M12, the element dictionary content includes: element ID, element name, element gender, minimum element age, maximum element age, pregnancy indicator, and other element information, wherein: element ID represents the unique identifier of the element; element name represents the standardized element name; element gender represents the gender to which the element is applicable, such as 0 for both men and women, 1 for men only, and 2 for women only; minimum and maximum element ages represent the age range to which the element is applicable; pregnancy indicator indicates whether it is applicable during pregnancy, such as 0 for general, 1 for prohibited during pregnancy, and 2 for available during pregnancy; and other element information represents other relevant information about the element.
[0076] In step M12, the medical record keywords obtained in step M11 are matched with the element names in the element dictionary, and the successfully matched elements are added to the element collection.
[0077] It should be noted that since the medical record data to be determined is not necessarily a purely TCM text description, the set of elements may contain descriptions commonly used in Western medicine. Therefore, it is necessary to convert the elements in the set of elements into TCM four diagnostic elements according to the correspondence between the elements and the TCM four diagnostic elements to obtain the TCM four diagnostic elements set.
[0078] Through steps M11, M12, and M13, the set of four diagnostic elements can be obtained based on the medical record data to be determined.
[0079] It should be noted that, in one possible implementation, step M2 includes: based on the set of four diagnostic elements, and combining the correspondence between the four diagnostic elements and the syndrome elements and syndrome element scores, a list of syndrome elements containing syndrome element scores is obtained.
[0080] It should be noted that, in one possible implementation, step M3 includes: according to the syndrome element list, combined with the syndrome element score, arranging the syndrome elements in the syndrome element list in descending order of score to obtain a syndrome element list arranged in descending order of score, and further combining with the TCM syndrome element dictionary to divide the syndrome element list into a disease location syndrome element list and a disease nature syndrome element list.
[0081] It should be noted that in step M3, based on the syndrome element scores, the syndrome element list is first sorted in descending order to obtain a syndrome element list sorted by score in descending order. Then, for each syndrome element in the syndrome element list sorted in descending order of score, the syndrome element ID is matched and searched in the TCM syndrome element dictionary to obtain the classification label of the syndrome element. The syndrome elements with disease location are added to the disease location syndrome element list, and the syndrome elements with disease nature are added to the disease nature syndrome element list.
[0082] It should be noted that the TCM syndrome element dictionary includes: syndrome element ID, syndrome element name, syndrome element classification marker, syndrome element gender, minimum age of syndrome element, maximum age of syndrome element, pregnancy marker, ten-principle attributes of syndrome element, and other information about syndrome elements. Specifically: syndrome element ID represents the unique identifier of the syndrome element; syndrome element name represents the standardized name of the syndrome element; syndrome element classification marker indicates that the syndrome element is divided into two categories: disease location syndrome element and disease nature syndrome element, for example, 1 represents disease location syndrome element, and 2 represents disease nature syndrome element; syndrome element gender indicates the gender to which the syndrome element is applicable, for example, 0 indicates unisex, 1 indicates only applicable to males, and 2 indicates only applicable to females; minimum age and maximum age of syndrome element indicate the age range to which the syndrome element is applicable; pregnancy marker indicates that the syndrome element is... Whether it is applicable during pregnancy is indicated by a number, such as 0 for general, 1 for contraindications during pregnancy, and 2 for availability during pregnancy. The ten-category attribute of the syndrome element indicates the specific category within the ten categories to which the syndrome element belongs, identified by letters, such as B for exterior, L for interior, H for cold, R for heat, X for deficiency, S for excess, U for upper, and D for lower. Yin and Yang govern the eight categories (cold, deficiency, interior, and lower belong to Yin, while heat, excess, exterior, and upper belong to Yang), which is already shown in the ten-category diagram and therefore does not need to be described in the ten-category attribute of the syndrome element. It should be noted that a certain syndrome element may have multiple ten-category attributes. For example, the bladder (syndrome) has both exterior and lower attributes, and its syndrome element ten-category attribute is marked as "BD". Other information of the syndrome element indicates other corresponding information of the syndrome element.
[0083] In one possible implementation, before step M3 is executed, the validity of the upper limit of the number of groups and the upper limit of the number of syndrome elements in each group in the syndrome element grouping rule configuration needs to be judged. If the upper limit of the number of groups is less than 1, or the upper limit of the number of syndrome elements in each group is not any of the values 2, 4, and 6, then an error message will be directly displayed indicating that the grouping syndrome element rule setting is abnormal and needs to be reset, and the subsequent implementation steps will be exited. It should be noted that because syndrome element grouping is based on the combination of disease location syndrome elements and disease nature syndrome elements, the upper limit of the number of syndrome elements in each group must be configured to be an even number. On the other hand, the number of syndrome elements related to a syndrome is generally 2 to 4, and will not exceed 6. Therefore, the upper limit of the number of syndrome elements in each group should not be configured too large here, and its configuration value of 2, 4, or 6 is more appropriate.
[0084] In one possible implementation, step S2 (obtaining a list of syndrome groupings based on the list of syndrome elements at the location of the disease and the list of syndrome elements of the disease nature) includes:
[0085] Step S21: Take out one disease location syndrome element and one disease nature syndrome element from the disease location syndrome element list and the disease nature syndrome element list in sequence, and write them into the group syndrome element queue until the number of syndrome elements in the group syndrome element queue reaches a preset threshold.
[0086] Step S22: Add the grouped evidence element queue to the evidence element grouping list;
[0087] Step S23: Repeat the above two steps until the number of grouped evidence queues in the evidence grouping list reaches a preset threshold.
[0088] The implementation process of step S2 is illustrated below with a specific example.
[0089] First, a disease location syndrome element is obtained from the disease location syndrome element list, and then a disease nature syndrome element is obtained from the disease nature syndrome element list. These are then written into a grouped syndrome element queue.
[0090] Next, it is determined whether the number of elements in this grouped syndrome element queue is less than a preset threshold (i.e., the maximum number of elements per group). If the number of elements in this grouped syndrome element queue is less than the preset threshold, the next disease location syndrome element and disease nature syndrome element are obtained from the disease location syndrome element list and the disease nature syndrome element list, respectively, and written into this grouped syndrome element queue. If the number of elements in this grouped syndrome element queue is equal to the preset threshold, this grouped syndrome element queue is added to a pre-allocated syndrome element grouping list.
[0091] Next, it is determined whether the number of syndrome element groups in the list is less than a preset threshold (i.e., the upper limit of the number of groups). If the number of syndrome element groups is less than the preset threshold, the above two steps are continued. If the number of syndrome element groups is equal to the preset threshold, the processing ends. The syndrome element group list obtained at this point is the final grouping result obtained in this step. It should be noted that both the disease location syndrome element list and the disease nature syndrome element list are obtained starting from the next one; that is, syndrome elements already obtained in previous steps will not be obtained again.
[0092] It should be noted that some abnormal situations may occur during the execution of step S2. The following is a supplementary explanation of the possible abnormal situations and their handling mechanisms.
[0093] i. If the number of elements in the syndrome element list obtained in the above steps is less than the maximum number of groups multiplied by the maximum number of elements per group, but all syndrome elements in the disease location syndrome element list and the disease nature syndrome element list have been obtained, then the grouping process ends. The final number of syndrome element group lists may be less than the preset maximum number of groups, and the length of the last group syndrome element queue in the syndrome element group list may be less than the preset maximum number of elements per group;
[0094] ii. If all disease location syndrome elements in the disease location syndrome element list have been acquired, but the disease nature syndrome element list has not been acquired, and the maximum number of groupings has not been reached, then the corresponding number of syndrome elements can be acquired from the disease nature syndrome element list based on the maximum number of syndrome elements per group and the maximum number of groupings, until the disease nature syndrome element list is acquired, or the maximum number of syndrome elements per group and the maximum number of groupings are reached. That is, in this case, the syndrome element queues in each grouping list are not necessarily obtained according to the combination of disease location syndrome elements and disease nature syndrome elements.
[0095] iii. Similarly, if all disease-related syndrome elements in the disease-related syndrome element list have been acquired, but the disease-location syndrome element list has not yet been acquired, and the maximum number of groupings has not been reached, then the corresponding number of syndrome elements can be acquired from the disease-location syndrome element list based on the maximum number of syndrome elements per group and the maximum number of groupings, until the disease-location syndrome element list is acquired, or the maximum number of syndrome elements per group and the maximum number of groupings are reached. That is, in this case, each group of syndrome elements in the syndrome element grouping list is not necessarily obtained according to the combination of disease-location syndrome elements and disease-related syndrome elements.
[0096] See Figure 2 In one possible implementation, step S3 includes:
[0097] Step S31: Based on the evidence element grouping list and the evidence element dictionary, obtain the ten-category attributes of each evidence element group in the evidence element grouping list.
[0098] Step S32: Based on the ten-category attributes of each group of evidence elements, determine the relevant information of the coordinates of each group of evidence elements in the ten-category diagram, and store them in the coordinate term list.
[0099] Step S33: Based on the list of coordinate terms, obtain the point coordinates of each group of evidence elements in the ten-line diagram.
[0100] It should be noted that in step S31, each group of syndrome elements in the syndrome element grouping list needs to be matched according to the syndrome element ID, the corresponding syndrome element needs to be found in the TCM syndrome element dictionary, and its ten-category attributes need to be obtained and added to each group of syndrome elements.
[0101] See Figure 3 In one possible implementation, step S32 includes:
[0102] Step S321: Write the evidence elements with the same point coordinate type in each group of evidence elements in the evidence element grouping list into a temporary evidence element list, wherein the point coordinate type includes: heat, lower, interior, deficiency, cold, upper, surface and solid.
[0103] Step S322: Based on the temporary evidence list, determine the scoring value of the corresponding point coordinates, the evidence involved, the number of elements derived, and the display name of the point coordinates.
[0104] It should be noted that the coordinates of the elements in the Ten-Principles Diagram are based on their Ten-Principles attributes; that is, the coordinates of the Ten-Principles attributes on the Ten-Principles Diagram are clearly defined, such as... Figure 6 As shown, Yin and Yang are the overarching principles, not listed as sub-principles in the diagram. They are distinguished by black and white poles, governing the other four pairs of eight principles. North and South represent heat and cold, East and West represent exterior and interior, and Up and Down, and Deficiency and Excess, also form opposing points. Therefore, when deriving the relevant information of each group of syndrome elements' coordinates in the Ten Principles diagram, we can use the "heat, lower interior, deficiency, cold, upper exterior, excess" attribute from the Ten Principles as a basis, statistically analyze the syndrome elements with the relevant Ten Principles attributes at each coordinate point, and derive the relevant information for that coordinate point. The following details the process of determining several relevant pieces of information.
[0105] (1) The process of determining the total score of all evidence elements at each point coordinate includes: calculating the total score of all evidence elements at each point coordinate based on the evidence element scores and their corresponding weights in the temporary evidence element list.
[0106] The process will be described in detail below with specific examples.
[0107] If the number of temporary evidence elements (templist) corresponding to a certain point coordinate is 1, and this evidence element is not marked as a primary evidence element in the derivation, then the total score S for that point coordinate is... 总percentageis the score of this syndrome element multiplied by Percentage_Weight2;
[0108] In other cases, the total score S of the point coordinate 总percentage is the sum of the scores of the main syndrome elements marked in the temporary syndrome element list templist multiplied by Percentage_Weight1, plus the sum of the scores of non-main syndrome elements in the temporary syndrome element list templist multiplied by Percentage_Weight3.
[0109] It should be noted that Percentage_Weight1, Percentage_Weight2 and Percentage_Weight3 in the algorithm are the weights configured by the coordinate calculation algorithm rules for syndrome elements participating in the calculation of point coordinate scores. Percentage_Weight1 marks the weight when the main syndrome element participates in the calculation of point coordinate scores, which is configured as 1 in this example; Percentage_Weight2 marks the weight when there is only one syndrome element related to a certain point coordinate and this syndrome element is not a main syndrome element, which is configured as 0.6 in this example; Percentage_Weight3 marks the weight when there are more than one syndrome elements related to a certain point coordinate and non-main syndrome elements participate in the calculation of the point coordinate score, which is configured as 0.2 in this example.
[0110] (2) The determination process of the participating syndrome elements displayed in the Ten Principles Diagram includes:
[0111] Step L1: Perform redundant information processing on the syndrome element names of all syndrome elements in the temporary syndrome element list to obtain simplified syndrome element names;
[0112] Step L2: According to the simplified syndrome element names, obtain the participating syndrome elements displayed in the Ten Principles Diagram corresponding to the point coordinates.
[0113] It should be noted that in Step L1, the redundant information processing refers to removing the Snf_ReduChar characters in the syndrome element names of all syndrome elements in the temporary syndrome element list templist to obtain simplified syndrome element names. Among them, Snf_ReduChar marks the redundant character information that needs to be cleaned up for the relevant syndrome elements when counting the information of syndrome elements participating in point coordinates, which is configured as "(证)" in this example.
[0114] It should be noted that in Step L2, the simplified syndrome element names obtained in Step L1 are connected through the "+" sign to obtain the participating syndrome elements displayed in the Ten Principles Diagram corresponding to the point coordinates.
[0115] For example, the point coordinates are the ten categories of "table", and the related syndrome elements include "half-table and half-interior (syndrome)" and "bladder (syndrome)". After this step, the participating syndrome element information to be displayed in the figure for this point coordinates is: half-table and half-interior + bladder.
[0116] (3) The process of determining the number of all evidence elements at the coordinates of this point includes: the number of all evidence elements at the coordinates of this point is obtained by summing the number of all evidence elements in the temporary evidence element list.
[0117] (4) The process of determining the coordinate display name includes:
[0118] Step R1: Based on the temporary evidence list, determine the first temporary coordinate display name for the corresponding point;
[0119] Step R2: Based on the first temporary coordinate display name, determine the coordinate display name of each group of evidence elements in the ten-line diagram in the evidence element grouping list, and record the coordinate display name in the coordinate term list.
[0120] It should be noted that since there may be multiple evidence elements corresponding to a certain point coordinate, it is necessary to determine which evidence element name to use as the display name on that point coordinate.
[0121] Specifically, the name of the evidence element that includes the ten-category attribute of the coordinate type will be prioritized (for example, if two evidence elements, "Half-Surface Half-Inside (Evidence)" and "Bladder (Evidence)," both have the attribute "Surface" in the ten-category attribute, then when processing the ten-category attribute of the coordinate type "Surface", "Half-Surface Half-Inside (Evidence)" includes the ten-category attribute name of the coordinate type, while "Bladder (Evidence)" does not include the ten-category attribute name of the coordinate type), and the evidence element with the highest score will be used as the displayed name of the coordinate of that point.
[0122] In one possible implementation, step R1 includes:
[0123] The temporary evidence list is sorted in descending order of evidence score, and the name of the first evidence in the sorted temporary evidence list is used as the first temporary coordinate display name of the corresponding point.
[0124] Determine whether the first temporary coordinate display name contains the name of the corresponding point type attribute;
[0125] If not, determine whether the names of other elements in the temporary evidence element list contain the corresponding point type ten-category attribute;
[0126] If the names of other elements in the temporary evidence element list contain the corresponding point type ten-line attribute, then a new coordinate display name is obtained based on the score of the element in the temporary evidence element list that contains the corresponding point type ten-line attribute, and the new coordinate display name is used as the first temporary coordinate display name.
[0127] The above process is illustrated in detail below with an example.
[0128] First, set the coordinate display name of this point to the name of the first record in the temporary evidence list templist, i.e., coordinateShowName = templist[0].Name;
[0129] Next, determine whether the coordinate display name contains the name of the coordinate type's ten-category attribute. If not, search the temporary evidence list templist for all evidence records whose names contain the coordinate type's ten-category attribute name. If the evidence record list is not empty, sort the evidence record list in descending order by score and number of derivations, and determine whether the difference between the score of the first record and the score of templist[0] is less than Percentage_Differ (Percentage_Differ is a difference criterion used when deducing the point coordinate display name and comparing the evidence score; in this example, it is configured as 10). If the difference is greater than Percentage_Differ, set the first evidence name in this evidence record list to the coordinate display name. (If the difference is not greater than Percentage_Differ, it means that the score of the evidence corresponding to the determined coordinate display name is much higher than the evidence score in templist that includes the coordinate type's ten-category attribute name, and the coordinate display name does not need to be adjusted.)
[0130] In one possible implementation, step R2 includes:
[0131] Determine whether the first temporary coordinate display name of the current group is the same as the first temporary coordinate display name of other groups in the evidence element grouping list;
[0132] If not, the first temporary coordinate display name of the current group will be used as the coordinate display name in the ten-line diagram;
[0133] If so, then based on the first temporary coordinate display name of the current group and the temporary evidence element list, determine the coordinate display name of each group of evidence elements in the ten-line diagram.
[0134] The above process is illustrated in detail below with an example.
[0135] First, determine whether the records in the derived coordinates list already contain the coordinate display name determined in step R1 (Note: Since a certain element may have multiple coordinate type attributes, the coordinate display name determined in step R1 may already exist in the derived coordinates list. To avoid multiple points in the graph displaying the same name, this step is necessary). There are two possibilities:
[0136] The first scenario: If the coordinates list obtained from the previous steps does not contain a record with the coordinate display name determined in step R1, then the point coordinate information obtained in this loop is added to the coordinates list. This is achieved by defining a coordinates type variable CoordinateModel (CoordinateModel is a coordinates model, defined as: CoordinateShowName -- coordinate display name; CoordinateName -- coordinate type name; CoordinateType -- coordinate type identifier; Percentage -- score; Count -- number of derivations; ParticipateSnf -- participating elements). After assigning the point coordinate information obtained in the previous steps to this variable, the variable is added to the coordinates list, and the loop continues to return to step S321.
[0137] The second scenario: If the derived coordinates list contains records that include the coordinate display names determined in step R1, then the following processing is required:
[0138] d1. Write the display name records of the coordinates determined in step R1 in coordinates into the temporary variable tempData;
[0139] d2. Make judgments and handle the following four situations:
[0140] Case 1: If the coordinate display name of the temporary variable tempData does not include its corresponding coordinate type name, and templist contains records that include the coordinate type name for this processing, then the processing is as follows:
[0141] If the temporary evidence list templist contains only one record, it means that the evidence name of that record includes the coordinate type name of this processing, and its evidence name is the coordinate display name determined in step R1. In this case, the graphical display should prioritize the result of this processing. Records containing the coordinate display name determined in step R1 should be deleted from the coordinate term list coordinates, and the point coordinate information obtained in this processing should be added to the coordinate term list coordinates (the method has been described above and will not be repeated here). Then, return to step S321 for iterative processing.
[0142] ii. If the temporary evidence list templist contains multiple records, continue searching templist for records that meet the following two conditions: ① The name is not equal to the coordinate display name determined in step R1; ② The name contains the coordinate type name processed in this step. At this point, there are still two possibilities:
[0143] Case 1: If the list of records that meet both conditions is empty, then directly select the record in templist whose name is not equal to the coordinate display name determined in step R1 and whose score is the highest, and use that record's name as the coordinate display name for this processing.
[0144] Case 2: If the record list that meets both conditions is not empty, select the record with the highest score, Record1, from this record list, and select the record with the highest score, Record2, from templist, whose name is not equal to the coordinate display name determined in step R1. Calculate the difference between the score of Record1 and the score of Record2. If the difference is less than or equal to the Percentage_Differ value, use the name of the evidence recorded in Record1 as the coordinate display name for this processing; otherwise, use the name of the evidence recorded in Record2 as the coordinate display name for this processing.
[0145] After adjusting the display name of the coordinates of the points processed in this operation, the relevant information of the coordinates obtained in this operation is added to the coordinates entry list, and then the process returns to step S321 for loop processing.
[0146] Case 2: If the coordinate display name of the temporary variable tempData includes its corresponding coordinate type name, and templist does not contain a record that includes the coordinate type name for this processing, then the processing is as follows:
[0147] If there is only one record in the temporary evidence list templist, it means that the evidence name of the record does not include the coordinate type name of the current processing, and its name is the coordinate display name determined in step R1 above. In this case, the display on the graph should be based on the record that already includes the coordinate display name determined in step R1 in the coordinate term list coordinates. Therefore, the point coordinates of the current processing do not need to be added to the coordinate term list, and the process should directly return to step S321 for loop processing.
[0148] ii. If there are multiple records in the temporary evidence list templist, select the record with the highest score whose name is not equal to the coordinate display name determined in step R1, and use the evidence name of that record as the coordinate display name for this processing. After adjusting the coordinate display name of the point coordinates, add the relevant information of the point coordinates obtained in this processing to the coordinate term list coordinates, and then continue to return to step S321 for loop processing.
[0149] Case 3: If the coordinate display name of the temporary variable tempData contains its corresponding coordinate type name, and templist contains records that include the coordinate type name for this processing, then the processing is as follows:
[0150] If the temporary evidence list templist contains only one record, it means that the evidence name of this record includes the coordinate type name of this processing, and its name is the coordinate display name determined in step R1 above. In this case, the following comparison needs to be performed: if the total score of the temporary variable tempData is greater than the total score of the coordinates of the point being processed, or if the total score of the temporary variable tempData is equal to the total score of the coordinates of the point being processed, and the total number of derivations of the temporary variable tempData is greater than the total number of derivations of the coordinates of the point being processed.
[0151] If one of these conditions is met, and the coordinates displayed on the graph already includes the coordinate display name record determined in step R1, then the coordinates of the point being processed in this step do not need to be added to the coordinates list, and the process can directly return to step S321 for loop processing.
[0152] If either of these two conditions is not met, the result of this processing should be prioritized in the graphical display. Records containing the coordinate display name determined in step R1 should be deleted from the coordinates list, and the point coordinate information obtained in this processing should be added to the coordinates list (the method has been described above and will not be repeated here). Then, the process returns to step S321 for iterative processing.
[0153] ii. If the temporary evidence list templist contains multiple records, continue searching templist for records that meet the following two conditions: ① The name is not equal to the coordinate display name determined in step R1; ② The name contains the coordinate type name processed in this step. At this point, there are still two possibilities:
[0154] Case 1: If the record that meets both conditions is empty, then directly select the record in templist whose name is not equal to the coordinate display name determined in step R1 and whose score is the highest, and use that record's name as the coordinate display name for this processing.
[0155] Case 2: If the record list that meets both conditions is not empty, select the record with the highest score, Record1, from this record list, and select the record with the highest score, Record2, from templist, whose name is not equal to the coordinate display name determined in step R1. Calculate the difference between the score of Record1 and the score of Record2. If the difference is less than or equal to the Percentage_Differ value, use the name of the evidence recorded in Record1 as the coordinate display name for this processing; otherwise, use the name of the evidence recorded in Record2 as the coordinate display name for this processing.
[0156] After adjusting the display name of the coordinates of the points processed in this operation, the relevant information of the coordinates obtained in this operation is added to the coordinates entry list, and then the process returns to step S321 for loop processing.
[0157] Case 4: If the coordinate display name of the temporary variable tempData does not contain its corresponding coordinate type name, and templist does not record any coordinate type name included in this processing, then the processing is as follows:
[0158] If there is only one record in the temporary evidence list templist, it means that the evidence name of the record does not include the coordinate type name of the current processing, and its name is the coordinate display name determined in step R1 above. Then, the following comparison needs to be performed: if the total score of the temporary variable tempData is greater than the total score of the coordinates of the current processing point, or the total score of the temporary variable tempData is equal to the total score of the coordinates of the current processing point, and the total number of derivations of the temporary variable tempData is greater than the total number of derivations of the coordinates of the current processing point.
[0159] If any one of these conditions is met, the graphic display should primarily use the coordinates name record determined in step R1 that is already included in the coordinates entry list. In this case, the coordinates of the point being processed do not need to be added to the coordinates entry list, and the process can directly return to step S321 for loop processing.
[0160] If either of these two conditions is not met, the result of this processing should be prioritized in the graphical display. Records containing the coordinate display name determined in step R1 should be deleted from the coordinates list, and the point coordinate information obtained in this processing should be added to the coordinates list (the method has been described above and will not be repeated here). Then, the process returns to step S321 for iterative processing.
[0161] ii. If there are multiple records in the temporary evidence list templist, select the record with the highest score whose name is not equal to the coordinate display name determined in step R1, and use the evidence name of that record as the coordinate display name for this processing. After adjusting the coordinate display name of the point coordinates, add the relevant coordinate information obtained in this processing to the coordinate term list coordinates, and then return to step S321 for loop processing.
[0162] See Figure 4 In one possible implementation, step S33 includes:
[0163] Step S331: Based on the list of coordinate terms, determine the list of positive coordinate terms and the list of negative coordinate terms;
[0164] Step S332: Determine the main coordinate term list based on the positive coordinate term list and the negative coordinate term list;
[0165] Step S333: Obtain the point coordinates based on the main coordinate term list and the coordinate type list arranged according to the ten-category attribute types.
[0166] It should be noted that step S331 specifically includes: grouping the coordinate term list (coordinates) into a positive coordinate term list and a negative coordinate term list. This grouping is mainly based on the ten-category attributes of the coordinate type, where "lower interior cold" is classified as Yin and "heat excess upper surface" as Yang. After grouping, a positive coordinate term list (positiveList) and a negative coordinate term list (negativeList) are obtained, and then sorted in descending order by score and number of derivations, respectively.
[0167] It should be noted that the implementation process of step S332 includes: counting the number of positive coordinate term entries in the positiveList and negative coordinate term entries in the negativeList respectively. If the number of positive coordinate term entries in the positiveList is less than 2 and the number of negative coordinate term entries in the negativeList is greater than or equal to 2; or if the number of negative coordinate term entries in the negativeList is greater than 0 and the coordinate type of the first record in the coordinates list is negative, then the graph display should be based on the coordinates of the negative points; otherwise, the graph display should be based on the coordinates of the positive points.
[0168] It should be noted that step S33 also includes: defining the corresponding variables. This includes defining a coordinateArray of point coordinates, a namelist of names displayed on the graph, an attributelist of coordinate types, and a list of elements involved in the superposition of point scores, which is called a participatelist.
[0169] In one possible implementation, step S333 includes:
[0170] Match the records in the main term list with the coordinate type list arranged according to the ten-category attribute type. If a match is found, record the index position of the coordinate type list and assign the relevant information of the record in the main coordinate term list to the index position of the predefined variable list.
[0171] Repeat the above steps until the number of matched records reaches the preset value.
[0172] The implementation process of step S333 is illustrated below with a specific embodiment.
[0173] Based on the execution result of step S332, if the graph displays mainly the coordinates of negative points, then execute steps D1 to D3; if the graph displays mainly the coordinates of positive points, then execute steps E1 to E4.
[0174] Step D1: Retrieve records from the negative coordinate term list negativeList. This is achieved by iterating through the negativeList list, matching its coordinate type against a list of coordinate types already sorted by the ten categories of attribute types. If no match is found, continue the loop. If a match is found, record the index of the coordinate type list and assign the relevant information of that record from the negative coordinate term list to the corresponding index in the variable list defined in C. For example, if the matched negative coordinate term list record is negativeList[i], then the assignment would be: namelist[index] = negativeList[i].CoordinateSh owName; participatelist[index]=negativeList[i].ParticipateSnf; attributelist[index]=negativeList[i].coordinateName; coordinateArray[index,0]=49 (when negativeList[i].Percentage>49), or coordinateArray[index,0]=negativeList[i].Percentage (when negativeList[i].Percentage<=49).
[0175] Step D2: Determine if the number of matched records is greater than or equal to 4. If the condition is not met, continue to process and obtain records in the negative coordinate term list negativeList until the number of matched records is greater than or equal to 4. Then exit the loop processing, or the negative coordinate term list negativeList has been processed in the loop.
[0176] Step D3: Continue to determine if the number of matched records is greater than or equal to 4. If this condition is not met, and the negative coordinate term list (negativeList) has finished looping through the list, then loop through the positive coordinate term list (positiveList), with the same processing mechanism as described in step D1. The processing ends when the number of matched records is greater than or equal to 4, or when the positive coordinate term list has also finished looping through the list.
[0177] Step E1: Retrieve the first 3 records from the positive coordinate term list positiveList, sort them in ascending order of score, and rewrite them into the positive coordinate term list positiveList;
[0178] Step E2: Retrieve records from the positive coordinate term list positiveList. This is achieved by: looping through the positiveList list and matching its coordinate type with the coordinate type list already sorted by the ten categories of attribute types "hot, lower, interior, deficiency, cold, upper, surface, solid". If no match is found, continue looping. If a match is found, record the index of the coordinate type list and assign the relevant information of the record in the positive coordinate term list to the corresponding index in the variable list defined in C. Assuming the matched positive coordinate term list record is positiveList[i], the assignment is: namelist[index] = positiveList[i].CoordinateShowName; participantlist[index] = positiveList[i].ParticipateSnf; attributelist[index] = positiveList[i].coordinateName; coordinateArray[index,0] = 49 (when positiveList[i].Percentage>49), or coordinateArray[index,0] = positiveList[i].Percentage (when positiveList[i].Percentage<=49).
[0179] Step E3: Determine if the number of matched records is greater than or equal to 4. If the condition is not met, continue to process and obtain records in the positive coordinate term list positiveList until the number of matched records is greater than or equal to 4. Then exit the loop processing, or the positive coordinate term list positiveList has been processed in the loop.
[0180] Step E4: Continue to determine if the number of matched records is greater than or equal to 4. If this condition is not met, and the positive coordinate term list (positiveList) has been processed in a loop, then process the negative coordinate term list (negativeList) in a loop, with the same processing mechanism as described in step E2. The processing ends when the number of matched records is greater than or equal to 4, or when the negative coordinate term list has also been processed in a loop.
[0181] In one possible implementation, step S4 includes: determining the coordinates of auxiliary points based on the number and location of the point coordinates.
[0182] It should be noted that the purpose of auxiliary points is to make the diagram clearer; please refer to [reference needed]. Figure 7 The setting of auxiliary points is explained. Figure 7 There are four coordinate points. The graph formed by connecting these four coordinate points can clearly depict the patient's condition, which is mainly spleen and lung qi deficiency. If the previous derivation and calculation only yields one coordinate point, it is impossible to connect them into a graph. Therefore, it is necessary to add one auxiliary point on each side to connect the graph. The auxiliary points have a small score and have little impact on the display of the calculated results.
[0183] See Figure 5 It should be noted that the setting of auxiliary points needs to be determined based on the number and location of the point coordinates. The specific process is as follows:
[0184] Step S411: If the number of points with values in the coordinates is one, then add an auxiliary point to the left and right of the point according to its position.
[0185] Step S412: If the number of points with values in the coordinates is two, determine whether the two coordinates are opposing points, and determine the coordinates of the auxiliary point based on the opposing situation and the position of the coordinates.
[0186] Step S413: If the number of points with values in the coordinate system is three, then determine whether the coordinates of the auxiliary point should return to the center point or the points with values based on the coordinates of the points with values.
[0187] Step S414: If the number of points with values in the coordinate system is four, determine whether the four coordinate systems are on opposite points and determine the coordinates of the auxiliary points based on the opposite situation and the position of the coordinate systems.
[0188] The above process is illustrated below with a specific embodiment.
[0189] Based on the number of points with values in the coordinate array, auxiliary points are added and set accordingly. There are four possible scenarios:
[0190] In the first case, if the coordinate array `coordinateArray` contains only one point with a value, then two auxiliary points need to be added.
[0191] It should be noted that `index` represents the coordinates of the points with values in the coordinate array `coordinateArray`. An auxiliary point needs to be added to the left and right of the point with values, with indices `leftIndex` and `rightIndex` respectively. The left auxiliary point's coordinates `leftIndex` is `index-2` (because the Yin-Yang attributes in the diagram do not distinguish between entries, and only 8 positions are displayed; therefore, if `index-2<0`, `leftIndex` needs to be increased by 8). The right auxiliary point's coordinates `rightIndex` is `index+2` (similarly, if `index+2>8`, `rightIndex` needs to be subtracted by 8). The scores for both auxiliary points are set to `AuxPoint_Value1`.
[0192] The second scenario: The coordinate array `coordinateArray` contains 2 points with values. We need to further determine if these two points with values lie on opposite points on a straight line. The criterion for this is whether the difference between the coordinates of these two points is 4. In this case, there are two possibilities:
[0193] Case 1: If the difference between the coordinates of these two points with values is 4, then two auxiliary points need to be added for each of these two points with values, and two triangles will be displayed in the graph.
[0194] It should be noted that `index` represents the coordinate position of a point with a value in the coordinate array. When the `index` value is any one of 0, 3, 4, or 7, two auxiliary points need to be added sequentially to the left; otherwise, two auxiliary points need to be added sequentially to the right. Since the subscript position of the point coordinates in the figure is determined to be 0 to 7, when the coordinate position of a point is 0, the subscript of the next auxiliary point added sequentially to the left should be set to 7; when the coordinate position of a point is 7, the subscript of the next auxiliary point added sequentially to the right should be set to 0. Two auxiliary points need to be added to the coordinates of two points with values respectively. The algorithm is as shown in the attached figure above. The score of the first auxiliary point is set to `AuxPoint_Value1`, and the score of the second auxiliary point is set to `AuxPoint_Value2` (returning to the center point).
[0195] Scenario 2: If the difference between the coordinates of these two points is not 4, it indicates that they are not located at the coordinates of a paired opposition point. In this case, the following two scenarios need to be handled:
[0196] Case 1: If the difference between the coordinates of two points with values is 1, the graphic display will return to the center point and the coordinates of the last point will be set to be equal to the coordinates of the first point. If the coordinates of the first point are null, they will be uniformly set to 0.
[0197] Case 2: If the difference between the coordinates of two points with values is not 1, the graphic display will return to the point with values, and the coordinates of the last point will be set to the coordinates of the first point with values.
[0198] The third scenario: The coordinate array `coordinateArray` contains 3 points with values. The key here is determining whether to use the "return to center point" or "return to points with values" method for the graphic display. The default is to return to the center point. However, the "return to points with values" method will be used in the following situations:
[0199] Case 1: Obtain the score of the middle point among the points with value, and subtract the score of the middle point from the scores of the points to its left and the points to its right respectively. If any of the differences is greater than 5, then return to the point with value.
[0200] Case 2: Determine whether the indices of these three points with values are connected. If they are not connected, return to the point with values.
[0201] It should be noted that when using the return-to-center method, the coordinates of the last point need to be set to be equal to the coordinates of the first point. If the coordinates of the first point are null, they should be set to 0. When using the return-to-a-value method, the coordinates of the last point should be set to be equal to the coordinates of the first point.
[0202] The fourth scenario: The coordinate array `coordinateArray` contains 4 points with values. In this case, it's necessary to further determine whether these four points are in pairs of opposing points. This determination involves matching the coordinate type attribute list (obtained in step D) with predefined opposing types (such as "cold / hot", "up / down", "surface / interior", and "real / virtual" being opposing types). There are two possible outcomes in this scenario:
[0203] Case 1: If the attributelist can match any two pairs of hedging types, it means that these four points with values are at points that are hedging in pairs. To make the graph display better, the following auxiliary point addition processing is required.
[0204] It should be noted that the four points with values should first be grouped in pairs according to their coordinate order. The first two points with values should be written to the `front` group, and the last two points with values should be written to the `after` group. Next, an auxiliary point needs to be added to both the `front` and `after` groups to construct two triangles. The index of the added auxiliary point depends on whether there is a value between the points in the `front` or `after` groups. If there is a value, the coordinates of the newly added auxiliary point are the next point after the first point in the `front` or `after` group. If the coordinates of the newly added auxiliary point are 8, they are set to 0. If there is no value, the coordinates of the newly added auxiliary point are the next point after the second point in the `front` or `after` group. If the coordinates of the newly added auxiliary point are 8, they are set to 0. Finally, the value of the newly added auxiliary point in both the `front` and `after` groups is uniformly set to `AuxPoint_Value2`.
[0205] Scenario 2: If no two sets of opposing types are matched in the attributelist, it means that these four points with values are not located at pairs of opposing points. In this case, it is necessary to further determine whether these four points with values are in the same direction on the ten-line diagram. The determination is based on: looping through the coordinate array list coordinateArray and counting whether there are three or more consecutive coordinates with null values. If there are such cases, it means that the coordinates of these four points with values are in the same direction on the ten-line diagram. In this case, to avoid large differences in the scores of these four points with values, which could lead to diagram intersections or deviations from the center point, an auxiliary point needs to be added in the corresponding direction of these four points with values. The coordinates of this auxiliary point are set to the coordinates of the middle point among the three consecutive points with null values. Its value is set to AuxPoint_Value2.
[0206] In addition, in case 2, it is also necessary to return to the point with a value, that is, set the coordinate value of the last point to be equal to the coordinate value of the first point with a value. This completes the processing for this step.
[0207] It should be noted that the above steps are performed on each group of evidence in the evidence grouping list. The above operation needs to be performed on each group of evidence in the evidence grouping list to obtain the relevant information of the coordinates of each group of evidence points (including auxiliary points that need to be added).
[0208] In one possible implementation, the results of the dialectical analysis of the evidence elements are graphically presented in the Ten Principles Diagram, including:
[0209] The results of the syndrome differentiation, combined with the coordinate array of each syndrome group obtained in the previous steps, are presented in the Ten-Character Diagram. The results of the differentiation of the first group of syndrome elements are displayed by default, and can be dynamically refreshed based on user interface operations. Users can select any group of syndrome elements to display their results, or select multiple groups of syndrome elements to display their results simultaneously.
[0210] This application provides a TCM diagnostic device that combines syndrome element differentiation and ten-principle differentiation. (See attached document.) Figure 8 ,include:
[0211] The syndrome element list determination module 301 determines the syndrome element list of the location of the disease and the syndrome element list of the nature of the disease in the patient's medical record text.
[0212] The syndrome element grouping list determination module 302 obtains the syndrome element grouping list based on the disease location syndrome element list and the disease nature syndrome element list;
[0213] The point coordinate determination module 303 determines the point coordinates of each group of evidence elements in the ten-line diagram based on the evidence element grouping list.
[0214] The results display module 304 derives auxiliary points based on the coordinates of each group of evidence elements in the Ten-Outline Diagram and presents the evidence element identification results graphically in the Ten-Outline Diagram.
[0215] The TCM diagnostic device provided in this application integrates the syndrome element differentiation method and the ten-principle differentiation method to comprehensively analyze medical record data. Therefore, using this solution can make the determination of etiology more comprehensive and accurate, and can display the diagnostic results more intuitively.
[0216] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0217] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, can implement the steps in the above-described method embodiments.
[0218] This application provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the above-described method embodiments.
[0219] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying computer program code to a photographing device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electrical carrier signals or telecommunication signals.
[0220] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0221] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0222] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0223] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0224] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A traditional Chinese medicine syndrome differentiation method combining syndrome differentiation with ten-criterion syndrome differentiation, characterized in that, All steps are performed by a computer, including: Based on the patient's medical record text, determine the list of disease location syndrome elements and the list of disease nature syndrome elements in the medical record text; Based on the list of disease location syndrome elements and the list of disease nature syndrome elements, a syndrome element grouping list is obtained; Based on the evidence element grouping list, determine the point coordinates of each evidence element in the ten-line diagram. Based on the coordinates of each group of evidence elements in the Ten-Outline Diagram, auxiliary points are derived, and the evidence element identification results are graphically presented in the Ten-Outline Diagram. The step of determining the point coordinates of each group of evidence elements in the ten-line diagram based on the evidence element grouping list includes: Based on the evidence element grouping list and combined with the evidence element dictionary, the ten-category attributes of each evidence element group in the evidence element grouping list are obtained. Based on the ten-category attributes of each group of evidence elements, determine the relevant information of the coordinates of each group of evidence elements in the ten-category diagram, and store them in the coordinate term list. Based on the list of coordinate terms, the point coordinates of each group of evidence elements in the group list are obtained in the ten-line diagram; The relevant information for the point coordinates includes: the score value of the corresponding point coordinates, the participating elements, the number of element derivations, and the point coordinate display name. The process of determining the relevant information for the point coordinates of each group of elements in the element grouping list on the ten-level map based on the ten-level attributes of each group of elements includes: Write the elements with the same point coordinate type in each group of the syndrome element grouping list into a temporary syndrome element list, wherein the point coordinate type includes: heat, lower, interior, deficiency, cold, upper, surface and solid. Based on the temporary evidence list, determine the scoring value of the corresponding point coordinates, the evidence involved, the number of elements derived, and the display name of the point coordinates.
2. The TCM diagnostic method as described in claim 1, characterized in that, The step of obtaining a syndrome grouping list based on the syndrome location list and the syndrome nature list includes: One disease location syndrome element and one disease nature syndrome element are sequentially taken from the disease location syndrome element list and the disease nature syndrome element list and written into the group syndrome element queue until the number of syndrome elements in the group syndrome element queue reaches a preset threshold. Add the grouped evidence element queue to the evidence element grouping list; Repeat the above two steps until the number of grouped evidence queues in the evidence grouping list reaches a preset threshold.
3. The TCM diagnostic method as described in claim 1, characterized in that, The step of obtaining the point coordinates of each group of evidence elements in the ten-line diagram based on the coordinate term list includes: Based on the list of coordinate terms, determine the list of positive coordinate terms and the list of negative coordinate terms; Based on the lists of positive and negative coordinate terms, determine the list of primary coordinate terms; The point coordinates are obtained based on the list of main coordinate terms and the list of coordinate types arranged according to the ten-category attribute types.
4. The TCM diagnostic method as described in claim 3, characterized in that, The process of obtaining the point coordinates based on the list of main coordinate terms and the list of coordinate types arranged according to the ten-category attribute types includes: The records in the main coordinate term list are matched with the coordinate type list arranged according to the ten-category attribute type. If a match is found, the index position of the coordinate type list is recorded, and the relevant information of the record in the main coordinate term list is assigned to the index position of the predefined variable list. Repeat the above steps until the number of matched records reaches the preset value.
5. The TCM diagnostic method as described in claim 1, characterized in that, The step of deriving auxiliary points based on the coordinates of each set of evidence elements in the ten-line diagram includes: Based on the number and location of the point coordinates, determine the coordinates of the auxiliary points.
6. The TCM diagnostic method as described in claim 5, characterized in that, The step of determining the coordinates of auxiliary points based on the number and location of the point coordinates includes: If the number of points with values in the coordinates of the given point is one, then an auxiliary point is added to its left and right based on the position of the given point. If there are two points with values in the coordinates of the point, then determine whether the two coordinates are opposing points, and determine the coordinates of the auxiliary point based on the opposing situation and the position of the coordinates of the point. If there are three points with values in the coordinates of the points, then based on the coordinates of the points with values, determine whether the coordinates of the auxiliary points return to the center point or to the points with values. If the number of points with values in the coordinate system is four, then determine whether the four coordinate systems are at points that are mutually opposing each other, and determine the coordinates of the auxiliary points based on the opposing situation and the position of the coordinate systems.
7. A TCM diagnostic device combining syndrome element differentiation and ten-principle differentiation, characterized in that, include: The syndrome element list determination module determines the syndrome element list of the location of the disease and the syndrome element list of the disease nature in the patient's medical record text. The syndrome element grouping list determination module obtains the syndrome element grouping list based on the disease location syndrome element list and the disease nature syndrome element list; The point coordinate determination module determines the point coordinates of each group of evidence in the ten-line diagram based on the evidence grouping list. The results display module derives auxiliary points based on the coordinates of each group of evidence elements in the Ten-Outline Diagram and presents the evidence element identification results graphically in the Ten-Outline Diagram. The step of determining the point coordinates of each group of evidence elements in the ten-line diagram based on the evidence element grouping list includes: Based on the evidence element grouping list and combined with the evidence element dictionary, the ten-category attributes of each evidence element group in the evidence element grouping list are obtained. Based on the ten-category attributes of each group of evidence elements, determine the relevant information of the coordinates of each group of evidence elements in the ten-category diagram, and store them in the coordinate term list. Based on the list of coordinate terms, the point coordinates of each group of evidence elements in the group list are obtained in the ten-line diagram; The relevant information for the point coordinates includes: the score value of the corresponding point coordinates, the participating elements, the number of element derivations, and the point coordinate display name. The process of determining the relevant information for the point coordinates of each group of elements in the element grouping list on the ten-level map based on the ten-level attributes of each group of elements includes: Write the elements with the same point coordinate type in each group of the syndrome element grouping list into a temporary syndrome element list, wherein the point coordinate type includes: heat, lower, interior, deficiency, cold, upper, surface and solid. Based on the temporary evidence list, determine the scoring value of the corresponding point coordinates, the evidence involved, the number of elements derived, and the display name of the point coordinates.
8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Constructing method for traditional Chinese medicine dialectical medical principle model based on directed graph structure
CN107220509A
Multi-guide meridian dynamic intelligent detection system and method
CN116312975A
