Patient anxiety level assessment and feedback adjustment method based on artificial intelligence model
Patent Information
- Application Number
- CN202611460241.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-20
- Publication Date
- 2026-10-27
AI Technical Summary
[0003]然而,现有方法通常更关注最终预测结果,而对预测结果的形成过程展示不足;系统往往仅输出风险分数或焦虑等级,难以清晰说明模型经过了哪些判断过程、哪些特征对当前患者的评估结果产生了主要影响,以及多个关键特征之间如何共同作用
[0025]该基于人工智能模型的患者焦虑程度评估及反馈调节方法,通过获取患者的多维特征数据并利用决策树算法进行焦虑程度评估,在得到初始风险分数的同时保留对应的决策路径,并结合特征归因算法对决策路径中的各节点进行解析,以获得不同特征对评估结果的贡献程度,从而能够从个体层面对焦虑程度评估结果的形成依据进行解释;进一步通过筛选核心判断依据、提取决策路径中的分支节点信息并分析不同核心判断依据之间的相互作用关系,使评估结果不仅能够反映主要影响因素,还能够体现各影响因素在具体决策过程中的关联关系,提高评估过程的可追溯性和可解释性;同时,通过对初始风险分数进行数值分解并生成特征解释文本,将特征解释信息与决策路径进行结构化组合,使生成的临床评估报告能够同时体现焦虑程度预测结果、主要影响因素及对应的判断过程,便于专业人员对评估结果进行理解和复核;此外,根据焦虑程度预测标签及核心判断依据生成与患者相匹配的反馈调节信息,并根据患者响应于反馈调节信息产生的反馈数据对反馈调节策略进行调整,使焦虑程度评估与后续反馈之间形成动态关联,从而提高反馈内容与患者个体状态之间的匹配程度以及人工智能辅助焦虑评估和反馈调节的针对性、连续性和实用性。
Smart Images

Figure CN122991635A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of artificial intelligence and mental health-assisted assessment technology, specifically to a method for assessing and regulating patient anxiety levels based on an artificial intelligence model. Background Technology
[0002] With the continued growth in demand for mental health services, rapid assessment of anxiety levels and subsequent intervention have gradually become important components of mental health services. Traditional anxiety assessments typically rely on scale tests, interviews, and the experience-based judgment of professionals. With the development of artificial intelligence technology, machine learning models such as decision trees can be used to analyze multidimensional characteristics of patients, including sleep patterns, work stress, social status, and past emotional states, and output anxiety risk scores or anxiety level predictions, which can improve assessment efficiency and screening coverage to some extent.
[0003] However, existing methods typically focus more on the final prediction result, while insufficiently demonstrating the process by which the result is formed. Systems often only output risk scores or anxiety levels, failing to clearly explain which judgment processes the model went through, which features had a major impact on the current patient's assessment, and how multiple key features interact. Therefore, the lack of a clear correspondence between the assessment result and the model's internal judgment process leads to insufficient traceability and interpretability of the assessment process. Furthermore, while some existing methods can provide feature importance or ranking, they often fail to accurately reflect the actual impact of features on specific individual patients, and also struggle to explain the interactions between different features. Consequently, even after receiving the assessment results, professionals may still find it difficult to review the results based on specific influencing factors and formulate targeted interpretations and follow-up recommendations. Moreover, existing anxiety assessment methods usually end processing after outputting the assessment result or report, with limited correlation between subsequent feedback and the patient's current anxiety level and major influencing factors, and also making it difficult to adjust subsequent feedback based on the patient's actual response. Summary of the Invention
[0004] The purpose of this invention is to provide a method for assessing and regulating patient anxiety levels based on an artificial intelligence model, thereby addressing the problems existing in the prior art.
[0005] To achieve the above objectives, the present invention provides the following technical solution: a method for assessing and regulating patient anxiety levels based on an artificial intelligence model, comprising:
[0006] S1. Obtain the patient's multidimensional feature data, and use the decision tree algorithm to split the multidimensional feature data into nodes to obtain the initial risk score and the decision path corresponding to the initial risk score.
[0007] S2. For the decision path, the feature attribution algorithm is used to analyze each node in the decision path to obtain the feature contribution value corresponding to each feature in the multi-dimensional feature data.
[0008] S3. Obtain the pre-established contribution determination rules and preset thresholds, determine whether the feature contribution value is greater than the preset threshold, and if the feature contribution value is greater than the preset threshold, determine the corresponding feature as the core judgment basis.
[0009] S4. Based on the core judgment criteria, extract the branch node information in the decision-making path to obtain the interaction relationship of the core judgment criteria in the decision-making path.
[0010] S5. Through the interaction relationship, the initial risk score is numerically decomposed to obtain the feature explanation text for the core judgment basis;
[0011] S6. Obtain the feature explanation text and decision path, and perform structured splicing of the feature explanation text and decision path to generate the final evaluation result containing path tracing information.
[0012] S7. Based on the final assessment results, extract the anxiety level prediction labels and output a clinical assessment report containing the anxiety level prediction labels and feature explanation text.
[0013] S8. Based on the anxiety level prediction label and core judgment criteria, determine the feedback regulation strategy corresponding to the patient, and generate feedback regulation information for the core judgment criteria based on the feedback regulation strategy.
[0014] S9. Output the feedback adjustment information to the patient, obtain the feedback data generated by the patient in response to the feedback adjustment information, and adjust the feedback adjustment strategy according to the feedback data.
[0015] Preferably, step S1 includes acquiring multidimensional feature data of the patient, which is extracted from medical history records; using a decision tree algorithm to calculate the multidimensional feature data and determine the optimal splitting feature; performing node splitting processing based on the optimal splitting feature to obtain a sub-feature matrix and branching conditions; generating a decision tree model for the sub-feature matrix, obtaining the initial risk score corresponding to the decision tree model, and recording the branching conditions to obtain the decision path corresponding to the initial risk score.
[0016] Preferably, step S2 includes acquiring decision path and multidimensional feature data, extracting node splitting conditions and sample sets of the decision path; calculating path weights and feature distribution states based on node splitting conditions and sample sets; using a feature attribution algorithm to analyze the path weights and feature distribution states to obtain marginal contribution values; if the marginal contribution value is greater than a preset contribution threshold, then the marginal contribution values are accumulated and aggregated to obtain the feature contribution value corresponding to each feature in the multidimensional feature data.
[0017] Preferably, step S3 includes acquiring a pre-established contribution determination rule and a preset threshold, parsing the feature contribution value through the contribution determination rule to obtain a numerical comparison result; if the numerical comparison result meets the threshold triggering condition, then it is determined that the feature contribution value is greater than the preset threshold, and the corresponding feature is determined as the core judgment basis.
[0018] Preferably, step S4 includes obtaining core judgment criteria, mapping the core judgment criteria, and locating initial branch nodes; traversing the decision tree graph according to the initial branch nodes to obtain a first logical link and a second logical link; comparing the first logical link and the second logical link to determine the target dependency relationship; if the target dependency relationship satisfies the preset connectivity conditions, then extracting branch node information in the decision path according to the target dependency relationship to obtain the interaction relationship of the core judgment criteria in the decision path.
[0019] Preferably, step S5 includes allocating the initial risk score according to the interaction relationship to obtain the risk contribution weight; calculating the risk contribution weight by the node attenuation ratio to obtain the link transmission value; performing a numerical decomposition operation between the link transmission value and the baseline of the basic score to obtain the deviation magnitude quantification value; if the deviation magnitude quantification value is greater than the deviation threshold, querying the semantic mapping dictionary according to the deviation magnitude quantification value to match the feature explanation text for the core judgment basis.
[0020] Preferably, step S6 includes acquiring feature explanation text and decision path; segmenting the feature explanation text to obtain semantic fragments; parsing the decision path to obtain logical nodes; determining hierarchical identifiers based on the correspondence between semantic fragments and logical nodes; arranging the semantic fragments using the hierarchical identifiers to obtain a text sequence; truncating and extracting the text sequence to obtain the core traceability chain; and performing structured splicing on the core traceability chain and feature explanation text to generate a final evaluation result containing path traceability information.
[0021] Preferably, step S7 includes obtaining the final assessment result, parsing the final assessment result to obtain a set of predicted labels and feature explanation text; identifying the set of predicted labels to obtain anxiety level prediction labels; determining a target report template based on the anxiety level prediction labels; assembling the feature explanation text using the target report template to obtain the report body content; and formatting and outputting a clinical assessment report containing anxiety level prediction labels and feature explanation text based on the report body content and anxiety level prediction labels.
[0022] Preferably, step S8 includes obtaining anxiety level prediction labels and core judgment criteria, extracting label features to obtain a psychological state representation vector; classifying cognitive bias types based on the psychological state representation vector, parsing the core judgment criteria, and extracting behavioral features; matching behavioral features and cognitive bias types to determine feedback regulation strategies; and constructing text based on the feedback regulation strategies and core judgment criteria to generate feedback regulation information targeting the core judgment criteria.
[0023] Preferably, step S9 includes parsing feedback adjustment information to obtain an intervention instruction, outputting the intervention instruction to the patient terminal; receiving feedback data, which is generated by the patient terminal in response to the intervention instruction; extracting the compliance status identifier from the feedback data and calculating the execution deviation value; if the execution deviation value is greater than a preset deviation threshold, evaluating the execution deviation value to obtain a status evaluation matrix, and updating the feedback adjustment strategy according to the status evaluation matrix, thereby realizing the adjustment of the feedback adjustment strategy based on the feedback data.
[0024] As can be seen from the above technical solution, the present invention has the following beneficial effects:
[0025] This AI-based method for assessing and regulating patient anxiety levels utilizes multidimensional feature data and a decision tree algorithm to evaluate anxiety levels. While obtaining an initial risk score, it retains the corresponding decision path and analyzes each node in the decision path using a feature attribution algorithm to determine the contribution of different features to the assessment results. This allows for an explanation of the basis for the anxiety level assessment results at the individual level. Furthermore, by selecting core judgment criteria, extracting branch node information from the decision path, and analyzing the interactions between different core judgment criteria, the assessment results not only reflect the main influencing factors but also demonstrate the correlation between these factors in the specific decision-making process, improving the traceability and reliability of the assessment process. Explanatory power; simultaneously, by numerically decomposing the initial risk score and generating feature explanation text, the feature explanation information is structurally combined with the decision-making path, enabling the generated clinical assessment report to simultaneously reflect the anxiety level prediction results, main influencing factors, and corresponding judgment process, facilitating professionals' understanding and review of the assessment results; furthermore, based on the anxiety level prediction labels and core judgment criteria, feedback regulation information matching the patient is generated, and the feedback regulation strategy is adjusted based on the feedback data generated by the patient in response to the feedback regulation information, forming a dynamic correlation between anxiety level assessment and subsequent feedback, thereby improving the matching degree between feedback content and the individual patient's state, as well as the pertinence, continuity, and practicality of AI-assisted anxiety assessment and feedback regulation. Attached Figure Description
[0026] Figure 1 This is a flowchart of the overall method of the present invention;
[0027] Figure 2 This is a flowchart illustrating the patient feedback adjustment process of the present invention.
[0028] Figure 3 The following are ROC curves of the three methods on the hold-out set during the experiment of this invention;
[0029] Figure 4 This is a normalized comparison bar chart of the three attribution / importance methods and the actual driving intensity during the experiment of this invention.
[0030] Figure 5 This is a graph showing the changes in the weekly average symptom relief rate of the two groups during the 4-week follow-up period in the experiment of this invention.
[0031] Figure 6 The graphs show the average residual risk decrease curves and protocol compliance retention rate curves for the two groups during the 4-week follow-up period in the experiment of this invention. Detailed Implementation
[0032] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0033] Example 1:
[0034] like Figure 1 and Figure 6 As shown, the present invention provides a technical solution: a method for assessing and regulating patient anxiety levels based on an artificial intelligence model, comprising:
[0035] S1. Obtain the patient's multidimensional feature data, and use the decision tree algorithm to split the multidimensional feature data into nodes to obtain the initial risk score and the decision path corresponding to the initial risk score.
[0036] S2. For the decision path, the feature attribution algorithm is used to analyze each node in the decision path to obtain the feature contribution value corresponding to each feature in the multi-dimensional feature data.
[0037] S3. Obtain the pre-established contribution determination rules and preset thresholds, determine whether the feature contribution value is greater than the preset threshold, and if the feature contribution value is greater than the preset threshold, determine the corresponding feature as the core judgment basis.
[0038] S4. Based on the core judgment criteria, extract the branch node information in the decision-making path to obtain the interaction relationship of the core judgment criteria in the decision-making path.
[0039] S5. Through the interaction relationship, the initial risk score is numerically decomposed to obtain the feature explanation text for the core judgment basis;
[0040] S6. Obtain the feature explanation text and decision path, and perform structured splicing of the feature explanation text and decision path to generate the final evaluation result containing path tracing information.
[0041] S7. Based on the final assessment results, extract the anxiety level prediction labels and output a clinical assessment report containing the anxiety level prediction labels and feature explanation text.
[0042] S8. Based on the anxiety level prediction label and core judgment criteria, determine the feedback regulation strategy corresponding to the patient, and generate feedback regulation information for the core judgment criteria based on the feedback regulation strategy.
[0043] S9. Output the feedback adjustment information to the patient, obtain the feedback data generated by the patient in response to the feedback adjustment information, and adjust the feedback adjustment strategy according to the feedback data.
[0044] In this embodiment, the patient's multidimensional feature data is first obtained, and then the multidimensional feature data is organized according to the pre-set data fields so that each feature corresponds to the input variable in the decision tree model.
[0045] For numerical features, the corresponding numerical values are used as model inputs; for categorical features, the corresponding categorical codes are used as model inputs; after data organization, the multidimensional feature data corresponding to the patient are input into the decision tree model.
[0046] Furthermore, the decision tree model performs node splitting processing starting from the root node.
[0047] Specifically, each non-leaf node corresponds to a feature variable and a splitting condition corresponding to that feature variable; the model reads the patient feature value corresponding to the current node, compares the patient feature value with the splitting condition of the node, and enters the branch node corresponding to the comparison result; the model performs judgment node by node in the above manner until it reaches a leaf node, and determines the risk output value corresponding to the leaf node as the patient's initial risk score.
[0048] In this process, while generating the initial risk score, all the nodes that the patient actually passes through from the root node to the leaf node are recorded, and for each node, the corresponding features, splitting conditions, the patient's actual feature values, and the branch direction are recorded.
[0049] Arrange the above records according to the execution order of the nodes to form a decision path corresponding to the initial risk score.
[0050] Thus, a one-to-one correspondence is established between the initial risk score and the node judgment process that forms the initial risk score.
[0051] Furthermore, after obtaining the decision path, a feature attribution algorithm is used to analyze each node in the decision path.
[0052] Specifically, the feature attribution algorithm calculates the numerical contribution of a feature to the initial risk score formation process based on the features corresponding to each node in the decision path and the changes in the node output. If the same feature corresponds to one node in the decision path, the contribution value corresponding to that node is determined as the feature contribution value. If the same feature corresponds to two or more nodes in the decision path, the contribution values of each corresponding node are merged according to the pre-established attribution rules to obtain the feature contribution value corresponding to that feature.
[0053] Through this process, each feature in the patient's multidimensional feature data obtains a feature contribution value corresponding to the evaluation results.
[0054] Subsequently, the pre-established contribution determination rules and preset thresholds are obtained, and the feature contribution values corresponding to each feature are compared with the preset thresholds according to the unified numerical comparison rules. When the feature contribution value corresponding to a feature is greater than the preset threshold, the feature is determined as the core judgment criterion. When the feature contribution value corresponding to a feature is less than or equal to the preset threshold, the feature is not determined as the core judgment criterion.
[0055] Therefore, the core judgment is based on the deterministic comparison between the feature contribution value and the preset threshold.
[0056] Furthermore, after determining the core judgment criteria, the branch node corresponding to each core judgment criterion is located in the current decision path, and the corresponding branch node information is extracted.
[0057] Specifically, the branch node information includes the core judgment criteria corresponding to the node, the node splitting conditions, the patient's actual characteristic values, the branching direction of the node, and the positional order of the node in the decision path; based on the positional order of the branch nodes corresponding to each core judgment criterion and the connection relationship between the nodes, the interaction relationship of the core judgment criteria in the decision path is established.
[0058] Specifically, when the branch node corresponding to the first core judgment criterion is located before the branch node corresponding to the second core judgment criterion, and the decision path enters the node corresponding to the second core judgment criterion from the designated branch of the node corresponding to the first core judgment criterion, the first core judgment criterion and the second core judgment criterion are recorded as associated features with a path order relationship; for core judgment criterions that appear consecutively along the same decision path, the corresponding preceding and following association relationships are established according to their node arrangement order.
[0059] The resulting interaction relationships are consistent with the decision-making path actually followed by the patient in this instance.
[0060] Furthermore, after obtaining the interaction relationship between the core judgment criteria, a numerical decomposition operation is performed on the initial risk score.
[0061] Specifically, the numerical decomposition uses the basic output value corresponding to the decision tree and the output change value generated by the corresponding node of each core judgment basis in the decision path as the decomposition basis, and according to the node order of the core judgment basis in the decision path, the initial risk score is split into numerical items corresponding to each core judgment basis.
[0062] When there is a path order relationship between two or more core judgment criteria, the corresponding numerical item is determined according to the output change between the node corresponding to the previous core judgment criterion and the node corresponding to the next core judgment criterion, so that each numerical item corresponds to a core judgment criterion or is a node change process formed by core judgment criteria with path association; after the numerical decomposition is completed, all numerical items together constitute the explanatory data corresponding to the initial risk score.
[0063] Subsequently, the core judgment criteria, the actual feature values corresponding to the patients, the splitting conditions of the corresponding branch nodes, the explanatory data obtained from numerical decomposition, and the interaction relationships among the core judgment criteria are converted into feature explanation text.
[0064] The feature explanation text is organized according to the execution order of nodes in the decision path, and for each core judgment criterion, it records the node conditions that the patient's actual feature values satisfy, the branch direction determined by the conditions, and the numerical contribution corresponding to the core judgment criterion.
[0065] In addition, for core judgment criteria that have interactive relationships, the feature explanation text describes the path association between each core judgment criterion in the order of the corresponding nodes.
[0066] For example, when the decision path is determined by the judgment result of the first core judgment basis corresponding to the node corresponding to the second core judgment basis, the feature explanation text sequentially records the node conditions and branch results corresponding to the first core judgment basis and the node conditions and branch results corresponding to the second core judgment basis, so that the text content is consistent with the node order actually executed by the model.
[0067] Furthermore, after generating the feature explanation text, the feature explanation text and the decision path are structurally concatenated.
[0068] During the structured assembly process, sequential identifiers are established for each node in the decision-making path, and the feature explanation texts corresponding to the core judgment criteria are associated with the corresponding nodes. The final evaluation result retains the decision-making path corresponding to the initial risk score, the core judgment criteria, and the feature explanation texts corresponding to the core judgment criteria, thus forming a final evaluation result containing path tracing information.
[0069] As a preferred implementation, path tracing information is stored in the order in which the decision tree is actually executed, saving node information.
[0070] By tracing the path information, we can locate the root node from the final evaluation result and reconstruct the judgment process of the patient's multidimensional feature data in the decision tree model according to the node order. At the same time, we can locate the corresponding branch node from any core judgment basis and read the splitting condition, the patient's actual feature value and the branch direction of that node, so as to establish a correspondence between the final evaluation result and the actual reasoning process of the decision tree.
[0071] Based on the final assessment results, anxiety level prediction labels are extracted.
[0072] Anxiety level prediction labels are determined by the decision tree model based on the model output results corresponding to the patient's current multidimensional feature data, and a correspondence is established with the current decision path and the initial risk score. The anxiety level prediction labels are combined with feature explanation text to form a clinical assessment report. The clinical assessment report records the anxiety level prediction labels, as well as the core judgment basis and feature explanation text corresponding to the anxiety level prediction labels.
[0073] Furthermore, after obtaining the anxiety level prediction label and core judgment criteria, the pre-established feedback regulation strategy matching relationship is invoked.
[0074] The feedback regulation strategy matching relationship uses anxiety level prediction labels and core judgment criteria as matching conditions; the system inputs the current patient's anxiety level prediction labels and core judgment criteria into the feedback regulation strategy matching relationship, and determines the feedback regulation strategy corresponding to the current patient based on the matching results.
[0075] When an anxiety level prediction label corresponds to one core judgment criterion, the feedback adjustment strategy is determined based on the combination of the anxiety level prediction label and the core judgment criterion; when an anxiety level prediction label corresponds to two or more core judgment criters, the feedback adjustment strategy is determined based on the combination relationship between the anxiety level prediction label and each core judgment criterion, and the feedback adjustment content is organized according to the node order of each core judgment criterion in the decision-making path.
[0076] Furthermore, after determining the feedback adjustment strategy, feedback adjustment information is generated based on the feedback adjustment strategy to address the core judgment criteria.
[0077] Specifically, a correspondence is established between feedback adjustment information and core judgment criteria, so that each piece of feedback adjustment information can correspond to the core judgment criteria that form the current anxiety level prediction label; after the feedback adjustment information is generated, it is output to the patient.
[0078] Furthermore, after receiving the feedback adjustment information, the patient displays the feedback adjustment information and obtains the feedback data generated by the patient in response to the feedback adjustment information.
[0079] The feedback data is associated with the corresponding feedback adjustment information and the current feedback adjustment strategy, and serves as input data for adjusting the feedback adjustment strategy.
[0080] The system reads the feedback data and processes it according to pre-established feedback judgment rules.
[0081] Based on the processing results, the adjustment direction corresponding to the current feedback regulation strategy is determined, and the corresponding content in the feedback regulation strategy is updated. The updated feedback regulation strategy continues to establish a correspondence with the patient's anxiety level prediction label and core judgment criteria, which is used to generate subsequent feedback regulation information.
[0082] Example 2:
[0083] S1 includes acquiring multidimensional feature data of the patient, which is extracted from medical history records; using a decision tree algorithm to calculate the multidimensional feature data and determine the optimal splitting feature; performing node splitting processing based on the optimal splitting feature to obtain a sub-feature matrix and branching conditions; generating a decision tree model for the sub-feature matrix, obtaining the initial risk score corresponding to the decision tree model, and recording the branching conditions to obtain the decision path corresponding to the initial risk score.
[0084] In this embodiment, multidimensional feature data for anxiety level assessment is first extracted from the patient's medical history record. The data in the medical history record are organized according to pre-defined feature fields, with each feature field corresponding to an input feature in the decision tree model.
[0085] For data recorded in numerical form, the corresponding numerical value is directly read as the feature value; for data recorded in category form, it is converted into feature values according to the pre-set category-numerical code correspondence; after extraction, the feature values corresponding to the same patient are arranged in a fixed field order to form the multidimensional feature data of the patient; the medical history records used to build the decision tree model are arranged in the same field order to form a data set for node splitting calculation.
[0086] When performing the optimal splitting feature calculation on the current node to be split, each candidate feature in the node's data set is selected in turn, and the splitting position is determined for each candidate feature.
[0087] For numerical features, all feature values corresponding to the feature are first arranged in ascending order of value, and then the positions between adjacent feature values with different values are used as candidate split positions; for categorical features, candidate split positions are formed according to a pre-determined categorical division relationship.
[0088] For each candidate split position, the data records in the current node are divided into two branches, and the number of records corresponding to each anxiety level category in each branch is counted.
[0089] Subsequently, the degree of category mixing within each branch is calculated based on the proportion of records for each anxiety level category to the total number of records in that branch.
[0090] In the specific processing, first calculate the proportion of the number of records corresponding to each anxiety level category to the total number of records in that branch, then calculate the value after multiplying each proportion by itself, and sum the values. Finally, subtract the summed result from 1 to obtain the category mixing degree corresponding to that branch. The category mixing degree corresponding to the two branches is obtained by the same method.
[0091] After obtaining the degree of class mixing of the two branches, the weight of each branch in the current node is determined based on the number of records contained in each branch.
[0092] Specifically, the weight of the first branch is obtained by dividing the number of records in the first branch by the total number of records in the current node; the weight of the second branch is obtained by dividing the number of records in the second branch by the total number of records in the current node; the class mixing degree of the first branch is multiplied by the weight of the first branch, the class mixing degree of the second branch is multiplied by the weight of the second branch, and the two products are added together to obtain the split evaluation result corresponding to the current candidate split position.
[0093] The above calculation is performed for each candidate split position of the same candidate feature, and the split evaluation results corresponding to each candidate split position are compared. The split position corresponding to the split evaluation result with the smallest value is determined as the target split position of the candidate feature.
[0094] After calculating all candidate features within the current node in the same manner, compare the splitting evaluation results of each candidate feature at its target splitting position, determine the candidate feature with the smallest value as the optimal splitting feature of the current node, and determine the target splitting position corresponding to the optimal splitting feature as the splitting condition of the current node.
[0095] Furthermore, after determining the optimal splitting feature and its splitting condition, node splitting processing is performed on the feature data in the current node using the splitting condition.
[0096] Specifically, for numerical optimal splitting features, data records with feature values less than or equal to the splitting value are assigned to the first branch, and data records with feature values greater than the splitting value are assigned to the second branch; for categorical optimal splitting features, corresponding data records are assigned to the appropriate branches according to the determined category affiliation; within each branch, the original feature fields and field order of each data record are retained, and data records belonging to the same branch are rearranged to form the sub-feature matrix corresponding to that branch; thus, a definite correspondence is formed between the sub-feature matrix and the branch conditions that generate the sub-feature matrix.
[0097] In addition, for each sub-feature matrix, the aforementioned candidate feature traversal, candidate split position determination, category mixing degree calculation, branch weighting calculation, and optimal split feature determination process are continued, and the next layer node is generated based on the calculated optimal split feature.
[0098] Each time a node split is completed, the optimal splitting feature, splitting condition, and connection relationship between the current node and its two child nodes are saved.
[0099] When all data records within a node correspond to the same anxiety level category, that node is designated as a leaf node; when further candidate splitting calculations are performed on that node and no splitting evaluation result with a level of category mixing lower than that of the current node is obtained, that node is also designated as a leaf node.
[0100] Based on the above conditions, each node is split or stopped splitting in sequence, ultimately forming a decision tree model consisting of a root node, branch nodes, and leaf nodes.
[0101] Furthermore, after the decision tree model is established, the multidimensional feature data corresponding to the patients to be evaluated are input into the decision tree model.
[0102] Starting from the root node, read the optimal splitting feature and splitting condition corresponding to the current node, and read the patient's actual feature value under the optimal splitting feature; for numerical features, compare the patient's actual feature value with the splitting value of the current node, and enter the corresponding child node according to the comparison result of less than or equal to or greater than; for categorical features, enter the corresponding child node according to the patient's actual category and the category affiliation relationship recorded in the node record; after entering the next node, continue to perform the same judgment until the leaf node is reached.
[0103] Once the patient reaches a leaf node, an initial risk score is calculated based on the medical history records included in that leaf node during the model building phase.
[0104] Specifically, the number of medical records in the leaf node that meet the pre-defined anxiety risk category is counted, and the total number of medical records contained in the leaf node is also counted. The former is divided by the latter and the result is used as the initial risk score corresponding to the leaf node. After the patient enters the leaf node, the initial risk score corresponding to the leaf node is determined as the initial risk score for the patient's current anxiety level assessment.
[0105] In addition, while the patient is being judged layer by layer from the root node to the leaf node, the sequence of each node actually traversed is recorded.
[0106] Specifically, each node record includes the optimal splitting feature used by the node, the corresponding splitting condition, the patient's actual feature value under that feature, and the branch the patient actually entered. The above records are arranged in the order in which the patient actually passed through the nodes, and the initial risk score corresponding to the terminal leaf node is associated with the node sequence, thereby forming a decision path corresponding to the initial risk score.
[0107] Through the above processing, the original data in the medical history record is transformed into multidimensional feature data after feature extraction. Then, the optimal splitting feature and branching condition of each node are determined by the item-by-item calculation of candidate features and candidate splitting positions. Based on the branching conditions, a sub-feature matrix and subsequent nodes are formed. The patient to be evaluated obtains an initial risk score by performing the determined feature comparisons along each node of the decision tree. At the same time, the actual nodes passed and the branching conditions are retained, thereby obtaining a decision path that can trace the formation process of the initial risk score.
[0108] Example 3:
[0109] S2 includes acquiring decision paths and multidimensional feature data, extracting node splitting conditions and sample sets of decision paths; calculating path weights and feature distribution states based on node splitting conditions and sample sets; using a feature attribution algorithm to analyze path weights and feature distribution states to obtain marginal contribution values; if the marginal contribution value is greater than a preset contribution threshold, then the marginal contribution values are accumulated and aggregated to obtain the feature contribution value corresponding to each feature in the multidimensional feature data.
[0110] In this embodiment, the decision path generated in Embodiment 2 and the multidimensional feature data corresponding to the current patient are first obtained. The decision path saves node information according to the actual traversal order of the patient from the root node to the leaf node of the decision tree.
[0111] Read each node in the decision path and extract the splitting features, splitting conditions, the actual feature values of the patient, and the branch that the patient actually entered from the node record; at the same time, screen all samples that actually reached the node from the medical history records used in the decision tree model building stage, and use the screened samples as the sample set of the node.
[0112] Thus, each node in the decision path forms corresponding data consisting of node splitting conditions and node sample sets.
[0113] When calculating path weights for a node sample set, the path weight of the root node is set to 1. When a patient moves from the root node to the next node, the number of samples in the branch corresponding to that next node is counted, and the total number of samples in the root node sample set is also counted. The number of samples in that branch is divided by the total number of samples in the root node, and the resulting value is used as the sample retention ratio for that branch. The path weight of the root node is then multiplied by this sample retention ratio to obtain the path weight of the next node.
[0114] When the patient continues to move to the next node, the number of samples in the branch corresponding to the next node is counted, and the sample retention ratio of the current branch is obtained by dividing the number of samples by the total number of samples in the sample set of the previous node. Then, the path weight of the current node is obtained by multiplying the path weight of the previous node by the sample retention ratio of the current branch.
[0115] Following the above calculation order up to the leaf node, each node actually traversed by the patient has a defined path weight.
[0116] As a preferred embodiment, the feature distribution state is determined based on the node splitting conditions and the node sample set.
[0117] For nodes splitting using numerical features, all values of that feature in the node's sample set are compared with the node's splitting value one by one. The number of samples satisfying the first and second branch conditions is counted, and then the sample distribution ratio of the corresponding branch is obtained by dividing the number of samples in each branch by the total number of samples in the current node. For nodes splitting using categorical features, the samples are classified according to the categorical branch conditions stored in the node, and the sample distribution ratio of each branch is determined by dividing the number of samples in each branch by the total number of samples in the current node. The splitting conditions, the number of samples in each branch, and the sample distribution ratio of each branch together constitute the feature distribution state of the corresponding feature of the node.
[0118] Furthermore, after obtaining the path weights and feature distribution status, a feature attribution algorithm is used to determine the marginal contribution value of the corresponding splitting feature of each node.
[0119] In the specific processing, first calculate the risk benchmark value corresponding to each branch of the current node; for any branch, read the existing anxiety assessment results corresponding to the sample of that branch, divide the number of samples belonging to the preset anxiety risk category by the total number of samples in that branch, and use the resulting value as the risk benchmark value of that branch.
[0120] The risk baseline value for each branch of the current node is obtained in the same way.
[0121] In addition, based on the feature distribution status of the current node, the risk baseline value of each branch is multiplied by the sample distribution ratio corresponding to that branch, and then the values obtained from each branch are added together to obtain the node reference risk value corresponding to the current node when the patient characteristics have not yet been limited to a specific branch.
[0122] Then, the risk baseline value corresponding to the branch that the patient actually entered based on the node splitting condition is read, and the difference between the risk baseline value and the node reference risk value is calculated. The absolute value of the difference is taken to obtain the risk change value caused by the node splitting feature. The risk change value is multiplied by the path weight of the current node, and the resulting value is determined as the marginal contribution value corresponding to the current node.
[0123] Each split node in the decision path is processed sequentially according to the same calculation process, so that each node traversed receives a marginal contribution value corresponding to its split feature. The path weight is used to limit the sample retention degree of the current node in the patient's actual decision path, the node reference risk value is used to reflect the risk level of the current node in all branch states, and the risk benchmark value of the patient's actual entry into the branch is used to reflect the risk level of the patient after passing through the branch. Therefore, the marginal contribution value corresponds to the numerical impact of the split feature on the risk outcome at the current path node.
[0124] The contribution threshold is predetermined before the decision tree model is used for patient evaluation.
[0125] Specifically, the medical history records used to build the decision tree model are passed through the established decision tree model one by one, and the marginal contribution value of each medical history record in each node of the actual decision path is obtained according to the aforementioned marginal contribution value calculation method. All marginal contribution values are added together and then divided by the total number of marginal contribution values involved in the summation. The resulting average value is set as the contribution threshold and saved along with the current decision tree model. After the decision tree model is retrained, the contribution threshold is recalculated using the corresponding training data to ensure that the contribution threshold is consistent with the node structure and risk output scale of the current model.
[0126] In addition, when attributing features to the current patient, the marginal contribution values obtained from each node are compared with the pre-saved contribution thresholds.
[0127] When the marginal contribution value is greater than the contribution threshold, the marginal contribution value is retained and classified according to the splitting characteristics corresponding to the node; when the marginal contribution value is less than or equal to the contribution threshold, the value is not included in the cumulative aggregation process.
[0128] When the same feature corresponds to only one retained marginal contribution value in the current decision path, the marginal contribution value is taken as the feature contribution value corresponding to the feature; when the same feature generates marginal contribution values greater than the contribution threshold in two or more nodes in the decision path, the corresponding marginal contribution values are read according to the actual order of each node in the decision path, and the marginal contribution values are added together in sequence, and the accumulated value is taken as the feature contribution value of the feature.
[0129] For features in multidimensional feature data that do not generate marginal contribution values greater than the contribution threshold, their feature contribution values are set to 0.
[0130] Therefore, the actual branch of the patient in the decision path is determined by the node splitting condition, the path weight and feature distribution of each node are calculated by the node sample set, the marginal contribution value is obtained based on the difference between the actual branch risk benchmark value and the node reference risk value, and the contribution threshold pre-calculated by the model training data is used for screening. Finally, the effective marginal contribution values belonging to the same feature are accumulated to form the feature contribution value corresponding to each feature in the multidimensional feature data.
[0131] Example 4:
[0132] S3 includes obtaining pre-established contribution determination rules and preset thresholds, parsing the feature contribution values through the contribution determination rules, and obtaining numerical comparison results; if the numerical comparison results meet the threshold triggering conditions, it is determined that the feature contribution value is greater than the preset threshold, and the corresponding feature is identified as the core judgment basis.
[0133] In this embodiment, the feature contribution values corresponding to each feature obtained in Embodiment 3 are first read, and the contribution determination rules and preset thresholds associated with the current decision tree model are called.
[0134] The contribution determination rule stipulates that: for each feature, the feature contribution value of the feature is compared with a preset threshold, the corresponding numerical comparison result is generated based on the comparison result, and the marking operation of the core judgment basis is determined based on the numerical comparison result.
[0135] The preset threshold is determined after the decision tree model has been trained.
[0136] Specifically, the medical records used to build the decision tree model are input one by one into the trained decision tree model. The feature contribution value corresponding to each feature in each medical record is calculated according to the feature attribution processing procedure described in Example 3. After deleting the feature contribution values with a value of 0, the remaining feature contribution values are added together in sequence, and the sum is divided by the number of feature contribution values participating in the accumulation. The resulting value is used as the preset threshold corresponding to the current decision tree model. The preset threshold is associated with the model version of the decision tree model and stored. When the decision tree model is retrained, the above calculation is performed again using the medical records used for retraining, and the original preset threshold is replaced with the recalculated value.
[0137] In determining the contribution, the feature contribution values are read one by one according to the feature arrangement order in the multidimensional feature data, and the difference between the current feature contribution value and the preset threshold is calculated.
[0138] When the numerical difference is greater than 0, the numerical comparison result of the current feature is recorded as greater than the threshold; when the numerical difference is equal to 0, the numerical comparison result is recorded as equal to the threshold; when the numerical difference is less than 0, the numerical comparison result is recorded as less than the threshold.
[0139] Therefore, the relationship between the feature contribution value and the preset threshold is converted into a definite numerical comparison result.
[0140] In this embodiment, the threshold triggering condition is set to the numerical comparison result being greater than the threshold.
[0141] When the numerical difference corresponding to the current feature is greater than 0, the numerical comparison result meets the threshold triggering condition. Based on this, it is determined that the feature contribution value of the feature is greater than the preset threshold, and the feature is identified as the core judgment basis. At the same time, the core judgment basis, the corresponding feature contribution value, and the field identifier of the feature in the multidimensional feature data are saved for subsequent retrieval of the corresponding node in the decision path.
[0142] When the numerical difference corresponding to the current feature is equal to or less than 0, the numerical comparison result does not meet the threshold triggering condition, and the core judgment basis marking is not performed on the feature.
[0143] After completing the item-by-item comparison of all features, all features that meet the threshold triggering conditions are gathered into the core judgment criteria set corresponding to the current patient, and the correspondence between each core judgment criterion and its feature contribution value is maintained.
[0144] When processing the decision path, the nodes that use the feature to split the decision path are retrieved according to the field identifier corresponding to the core judgment criteria. This allows the determination result of the core judgment criteria to be directly used for the extraction of branch node information, and ensures that each core judgment criterion has a corresponding feature contribution value, threshold comparison result and decision path node as data basis.
[0145] Example 5:
[0146] S4 includes obtaining the core judgment criteria, mapping the core judgment criteria, and locating the initial branch node; traversing the decision tree graph according to the initial branch node to obtain the first logical link and the second logical link; comparing the first logical link and the second logical link to determine the target dependency relationship; if the target dependency relationship meets the preset connectivity conditions, then extracting the branch node information in the decision path according to the target dependency relationship to obtain the interaction relationship of the core judgment criteria in the decision path.
[0147] In this embodiment, the core judgment criteria determined in Embodiment 4 are first read, and the splitting features, node numbers, parent node numbers, child node numbers, and branching conditions corresponding to each branch node in the current decision tree model are retrieved.
[0148] Specifically, the feature fields corresponding to the core judgment criteria are matched item by item with the splitting features of each branch node. When the feature fields match, the node number of the corresponding branch node is recorded. Then, the recorded node number is cross-checked with the current patient's decision path. Nodes that do not appear in the current decision path are deleted, and only the branch nodes that actually participate in this anxiety level judgment are retained. If the same core judgment criteria corresponds to more than 2 branch nodes in the current decision path, they are arranged in the order of the root node to the leaf node, and the branch node with the highest sequential position is determined as the initial branch node, thereby completing the mapping from the core judgment criteria to the decision tree node.
[0149] Furthermore, after locating the initial branch node, the node connection relationships in the decision tree graph are read from the starting point of the traversal using the initial branch node.
[0150] First, traverse towards the leaf nodes along the direction from the child node the patient actually enters at the current initial branch node. For each node reached, record the node number, splitting characteristics, branching conditions, and the connection direction from the previous node to this node. Stop when traversing to the leaf node corresponding to the current patient's decision path. Arrange the initial branch node and the nodes traversed in sequence according to the traversal order to obtain the first logical link.
[0151] Therefore, the first logical link corresponds to the relationship of subsequent nodes that actually participate in the formation of risk results after the initial branch node.
[0152] While forming the first logical link, the parent node number is read from the initial branch node, and backtracking is performed level by level along the parent node direction; each time backtracking is performed, the node number, splitting characteristics, branching conditions, and connection relationship between the parent node and the current node are recorded; the backtracking stops when the root node is reached.
[0153] Since the order of nodes obtained during the backtracking process is from the initial branch node to the root node, the backtracking results are reversed so that the root node is at the first position and the initial branch node is at the last position, thus obtaining the second logical link; the second logical link reflects the pre-order judgment conditions actually satisfied before the initial branch node is formed.
[0154] Furthermore, after obtaining the first and second logical links, they are compared with the corresponding branch nodes of the remaining core judgment criteria.
[0155] In specific processing, firstly, the node number of each core judgment criterion in the current decision path is determined according to the aforementioned mapping method. Then, the position of the node number in the first and second logical links is retrieved item by item. If the node corresponding to the second core judgment criterion is located in the second logical link, the second core judgment criterion is determined to be located before the current core judgment criterion according to the node order in the second logical link. If the node corresponding to the second core judgment criterion is located in the first logical link, the second core judgment criterion is determined to be located after the current core judgment criterion according to the node order in the first logical link. Based on the preceding and following positions and connection directions of the two nodes in the links, corresponding target dependencies are formed.
[0156] Furthermore, the target dependencies are further validated according to preset connectivity conditions. These connectivity conditions are determined based on the parent-child node relationships in the tree structure after the decision tree model is established.
[0157] The determination process includes: confirming that the nodes corresponding to the two core judgment criteria to be determined both exist in the current patient's decision path; starting from the preceding node, reading the actual child node number it enters, and comparing the child node number with the next node number in the decision path; if they match, continuing to read the child node number of the next node, and continuing to compare in the same way, until the subsequent node is reached; when the actual child node number of each level node from the preceding node to the subsequent node matches the next node number in the decision path, it is determined that the preceding node can continuously reach the subsequent node along the current patient's actual decision path, and the target dependency relationship satisfies the preset connectivity condition; if the child node number of any level node does not match the next node number in the decision path, the current connectivity determination is terminated, and the two core judgment criteria are not determined to have an interaction relationship.
[0158] Furthermore, after the target dependency satisfies the connectivity condition, the corresponding node of the preceding core judgment is used as the starting point, and the corresponding node of the subsequent core judgment is used as the ending point. The information of the branch nodes actually passed between the two nodes is extracted from the current patient's decision path.
[0159] For each captured node, save the node number, splitting characteristics, node branching conditions, patient's actual characteristic value, and the branch actually entered, and arrange them according to the actual order in which the patient traversed from the previous node to the next node.
[0160] If the branch nodes corresponding to two core judgment criteria are adjacent in the decision path, then the two core judgment criteria are determined to be in a direct interaction relationship based on the branch conditions of the preceding node and its parent-child connection relationship pointing to the following node; if there is an intermediate branch node between the nodes corresponding to the two core judgment criteria, then the complete node order of the preceding node, intermediate branch node and following node is retained, and the transmission interaction relationship between the two core judgment criteria is determined based on the continuous node chain.
[0161] Example 6:
[0162] S5 includes allocating the initial risk score according to the interaction relationship to obtain the risk contribution weight; calculating the risk contribution weight by the node attenuation ratio to obtain the link transmission value; performing a numerical decomposition operation on the link transmission value and the baseline score to obtain the deviation magnitude quantification value; if the deviation magnitude quantification value is greater than the deviation threshold, querying the semantic mapping dictionary according to the deviation magnitude quantification value to match the feature explanation text for the core judgment basis.
[0163] In this embodiment, the interaction relationship of the core judgment criteria obtained in Embodiment 5 is read first, and the initial risk score corresponding to the current patient is obtained.
[0164] Specifically, the interaction relationship includes the branch nodes corresponding to each core judgment basis, the order of node arrangement, and the connection relationship between nodes; according to the order of the nodes corresponding to each core judgment basis in the decision path, the core judgment basis participating in this risk interpretation is arranged, and the feature contribution values corresponding to each core judgment basis obtained in Example 3 are read.
[0165] Furthermore, the initial risk score is allocated based on the feature contribution values of each core judgment criterion.
[0166] Specifically, the feature contribution values corresponding to all core judgment criteria for the current patient are summed to obtain the total feature contribution value. Then, for each core judgment criterion, the feature contribution value of that core judgment criterion is divided by the total feature contribution value to obtain the contribution ratio of that core judgment criterion among all core judgment criteria. The initial risk score is multiplied by the contribution ratio, and the resulting value is determined as the risk contribution weight corresponding to that core judgment criterion. The risk contribution weights of the remaining core judgment criteria are calculated in the same manner, so that the initial risk score is allocated according to the feature contribution value corresponding to each core judgment criterion.
[0167] After the risk contribution weight is determined, the node attenuation ratio is calculated based on the sample retention of adjacent nodes in the interaction relationship.
[0168] For any two adjacent branch nodes that the current patient actually passes through, read the number of samples contained in the previous node and the number of samples contained in the next node. Divide the number of samples in the next node by the number of samples in the previous node, and use the resulting value as the node decay ratio between the two nodes. Since the samples in the next node come from the actual branch corresponding to the previous node, the node decay ratio is used to characterize the proportion of values that are retained when the feature influence is transmitted from the previous node to the next node.
[0169] In cases where the node corresponding to the core judgment criterion is directly adjacent to the target node, the risk contribution weight corresponding to the core judgment criterion is multiplied by the node attenuation ratio between the two nodes, and the resulting value is determined as the link transmission value.
[0170] In cases where there are intermediate nodes between the core judgment basis node and the target node, the node attenuation ratio between every two adjacent nodes is calculated according to the actual node order of the decision path. The attenuation ratios of all nodes from the core judgment basis node to the target node are multiplied sequentially to obtain the cumulative attenuation ratio of the path segment. The risk contribution weight is then multiplied by the cumulative attenuation ratio to obtain the link transmission value corresponding to the core judgment basis.
[0171] In this embodiment, the baseline score is determined after the decision tree model has been trained.
[0172] Specifically, all medical records used to build the current decision tree model are input into the trained decision tree model one by one to obtain the initial risk score corresponding to each medical record. All initial risk scores are accumulated, and the total value is divided by the number of medical records. The resulting value is determined as the baseline of the current decision tree model. The baseline of the ...
[0173] For each core judgment criterion, its link transmission value is numerically decomposed with the baseline score.
[0174] Specifically, the deviation of the core judgment criterion from the baseline score is obtained by subtracting the link transmission value from the baseline score; the absolute value of the deviation difference is then taken as the quantitative value of the deviation magnitude; when the deviation difference is greater than 0, the direction of risk change corresponding to the core judgment criterion is recorded as the direction of increase; when the deviation difference is less than 0, the direction of risk change corresponding to the core judgment criterion is recorded as the direction of decrease.
[0175] Therefore, the deviation magnitude quantification value is used to record the numerical magnitude of risk changes, and the positive or negative value of the deviation difference is used to record the direction of risk changes.
[0176] As a preferred implementation, the deviation threshold is calculated and determined based on training data before the current decision tree model is put into use.
[0177] Specifically, each medical history record used to build the decision tree model is processed according to the aforementioned risk contribution allocation, node decay, and link transmission process to obtain a deviation magnitude quantification value corresponding to each medical history record; the deviation magnitude quantification values with values greater than 0 are accumulated, and the accumulated result is divided by the number of deviation magnitude quantification values participating in the accumulation, and the resulting average value is determined as the deviation threshold; the deviation threshold is established in correspondence with the current decision tree model and the baseline of the basic score and stored, and is recalculated synchronously after the model is retrained.
[0178] When interpreting and processing the current patient, the deviation magnitude quantification value corresponding to each core judgment criterion is compared with the deviation threshold.
[0179] When the deviation magnitude quantization value is greater than the deviation threshold, the semantic mapping processing corresponding to this core judgment criterion is initiated; when the deviation magnitude quantization value is less than or equal to the deviation threshold, the text matching of this core judgment criterion is not performed.
[0180] In addition, the semantic mapping dictionary is established before the model is deployed. Its data items include at least the core judgment basis field, the direction of risk change, the deviation range, and the corresponding explanatory text template. The deviation range is divided continuously according to the deviation threshold as the starting boundary and according to the pre-set fixed numerical interval, so that any deviation range quantification value greater than the deviation threshold falls into a unique numerical range.
[0181] When the deviation magnitude quantification value is greater than the deviation threshold, the corresponding data item is first located in the semantic mapping dictionary based on the feature field corresponding to the core judgment criteria; then the direction of risk increase or risk decrease is determined according to the positive or negative value of the deviation difference; then the deviation magnitude quantification value is compared with the upper and lower boundaries of each deviation magnitude interval to determine the unique numerical interval to which it belongs, and the explanatory text template corresponding to the interval is read.
[0182] Finally, the actual feature value corresponding to the current patient, the branching conditions of the node where the feature is located, and the deviation magnitude quantification value are written into the corresponding position of the explanation text template to form the feature explanation text for this core judgment basis.
[0183] When a patient has more than two core judgment criteria that meet the deviation threshold conditions, the semantic mapping described above is executed in the order of nodes determined in Example 5, and the correspondence between each feature explanation text and its corresponding core judgment criteria, branch nodes and deviation magnitude quantification value is maintained.
[0184] Example 7:
[0185] S6 includes obtaining feature explanation text and decision path; segmenting the feature explanation text into semantic segments; parsing the decision path to obtain logical nodes; determining hierarchical identifiers based on the correspondence between semantic segments and logical nodes; arranging the semantic segments through the hierarchical identifiers to obtain a text sequence; truncating and extracting the text sequence to obtain the core traceability chain; and performing structured splicing on the core traceability chain and feature explanation text to generate a final evaluation result containing path traceability information.
[0186] In this embodiment, the feature explanation text formed in Embodiment Six and the decision path corresponding to the current patient are obtained.
[0187] Specifically, the feature explanation text records the core judgment basis, the patient's actual feature value, the branching conditions of the corresponding node, the deviation magnitude quantification value, and the explanation content; the decision path records the node number, splitting feature, branching condition, patient's actual feature value, and the branch actually entered for each node according to the actual traversal order of the patient from the root node to the leaf node; after reading the above two types of data, the feature fields and branching conditions are used as the association fields between the text information and the path information.
[0188] When segmenting the feature explanation text, semantic segments are determined according to the boundaries of the corresponding explanation content based on the core judgment criteria.
[0189] Specifically, the process involves reading the feature field corresponding to one core judgment criterion and continuously extracting the patient's actual feature value, branch conditions, deviation magnitude quantification value, and explanatory content associated with that feature field. These are then combined into a semantic segment. The current segment ends when the feature field corresponding to the next core judgment criterion is read, and a new semantic segment is established for the next core judgment criterion. Thus, each semantic segment corresponds to one core judgment criterion. If the same core judgment criterion generates explanatory content at two or more nodes in the decision path, then semantic segments are formed separately based on the branch conditions stored in each explanatory content, without merging the explanatory content from different nodes.
[0190] In addition, for the decision path, the nodes are parsed one by one according to the node connection order starting from the root node; for each branch node read, the node number, splitting feature, branching condition, actual patient feature value, actual branch, and connection relationship with the next node are extracted, and the extracted information is saved as a logical node.
[0191] Then, the next node corresponding to that node is read, and the above process is repeated until the leaf node that generates the initial risk score is read. After parsing, the order of the logical nodes is consistent with the decision path actually traversed by the patient.
[0192] As a preferred implementation, the correspondence between semantic fragments and logical nodes is determined by a level 2 matching of feature fields and branch conditions.
[0193] First, the feature fields corresponding to the core judgment criteria in the semantic segment are read, and nodes with the same splitting feature as the feature field are searched in the logical nodes. If only one logical node is found, it is directly identified as the corresponding node. If two or more logical nodes are found, the branching conditions in the semantic segment are read and compared with the branching conditions of the searched logical nodes. Logical nodes with the same feature fields and the same branching conditions are identified as the corresponding nodes. Through this process, nodes formed when the same feature is repeatedly used as a splitting feature at different levels of the decision tree can be distinguished.
[0194] Furthermore, after completing the mapping between semantic fragments and logical nodes, a hierarchical identifier is assigned based on the actual position of the corresponding logical node in the decision path.
[0195] Specifically, the hierarchical identifier of the root node is set to 1. Moving one node backward from the root node along the branch that the current patient actually entered, the hierarchical identifier is increased by 1 until the leaf node is reached. The semantic segment obtains the hierarchical identifier of its corresponding logical node. For example, when the corresponding logical node is the second node after the root node, the hierarchical identifier of the semantic segment is 3. The hierarchical identifier is directly determined by the position of the node in the decision path, and is not determined according to the text generation order.
[0196] The semantic segments were then rearranged according to their hierarchical identifiers.
[0197] First, compare the hierarchical identifiers corresponding to each semantic segment. Semantic segments with smaller hierarchical identifier values are arranged first, and semantic segments with larger hierarchical identifier values are arranged later. If two semantic segments have the same hierarchical identifier, then read the sequential number of their corresponding logical nodes in the decision path record and arrange them according to the actual record order of the nodes. After sorting all the semantic segments, a text sequence consistent with the decision tree judgment order is obtained.
[0198] When performing truncation extraction on a text sequence, first determine the logical node corresponding to the first semantic segment of the text sequence and use this logical node as the truncation start position; then determine the logical node corresponding to the last semantic segment of the text sequence and use this logical node as the truncation end position.
[0199] Subsequently, based on the starting and ending positions, the corresponding nodes and all nodes continuously passed between them are read in the decision path. Nodes before the starting position and nodes after the ending position are removed from the current traceability data, and the remaining continuous nodes constitute the core traceability chain.
[0200] When there are intermediate nodes between the starting and ending positions, the intermediate nodes are retained in their original order according to the decision path. The nodes are not deleted because there is no corresponding feature explanation text for the intermediate nodes, so as to maintain the actual node connection relationship between the core judgment basis before and after.
[0201] When there is only one core judgment criterion for the current patient, the logical node corresponding to the core judgment criterion is used as the truncation starting point, and the continuous path between the node and the leaf node that generates the initial risk score is used as the core traceability chain, so that the core judgment criterion and the risk output node are traceable.
[0202] Furthermore, after obtaining the core traceability chain, a structured assembly is performed on the core traceability chain and the feature explanation text.
[0203] Specifically, the node level, splitting features, actual patient feature values, node branching conditions, and actual branch entered are written sequentially according to the order of nodes in the core traceability chain. When the current node has a corresponding semantic fragment, the corresponding semantic fragment is called according to the node's level identifier, and the core judgment criteria, deviation magnitude quantification value, and explanation content are appended to the current node record. For intermediate nodes that do not have a corresponding semantic fragment, only the splitting features, branching conditions, and actual branch of the node are saved to maintain the continuity of the traceability chain.
[0204] Furthermore, after all nodes are assembled, the initial risk score, the feature explanations arranged according to hierarchical identifiers, and the core traceability chain are written into the same assessment data record to form the final assessment result.
[0205] Each feature in the final evaluation result has a corresponding hierarchical identifier. This identifier can be used to locate a specific logical node in the core traceability chain. This node can then read its preceding nodes, subsequent nodes, and corresponding branch conditions, thereby reconstructing the actual decision-making process by which the feature participates in the current patient's anxiety level assessment.
[0206] Example 8:
[0207] S7 includes obtaining the final assessment results, parsing the final assessment results to obtain a set of predicted labels and feature explanation text; identifying the set of predicted labels to obtain anxiety level predicted labels; determining the target report template based on the anxiety level predicted labels; assembling the feature explanation text using the target report template to obtain the report body content; and formatting and outputting a clinical assessment report containing the anxiety level predicted labels and feature explanation text.
[0208] In this embodiment, the final evaluation result is obtained and parsed according to the data fields preset in the final evaluation result.
[0209] Specifically, the final evaluation result should at least save the model output labels, initial risk scores, core judgment criteria, feature explanation text, and path tracing information. During parsing, the model output label field is read first, and all labels and their values corresponding to the anxiety level classification are extracted and arranged into a predicted label set according to the model output order. Then, the feature explanation field is read, and the corresponding text is extracted according to the core judgment criteria identifier and hierarchical identifier carried by each explanation information, thereby obtaining the feature explanation text corresponding to this evaluation result. During the parsing process, the original correspondence between the feature explanation text and its core judgment criteria is maintained, and the arrangement order determined in Example 7 is not changed.
[0210] When identifying the predicted label set, the label encoding table determined during the training phase of the decision tree model is used as the basis for identification.
[0211] Specifically, the label coding table stores a one-to-one correspondence between the model's internal label codes and the anxiety level prediction labels. For each label in the prediction label set, the output value corresponding to that label is read, and the output values of each label are compared. The model's internal label corresponding to the output value with the largest value is determined as the target label. When the decision tree model directly outputs the leaf node category label, the category label saved at the leaf node where the patient finally reaches is read as the target label. After obtaining the target label, the record that matches the target label code is retrieved in the label coding table, and the corresponding anxiety level prediction label is read, thereby obtaining the unique anxiety level prediction label corresponding to the current patient.
[0212] For cases where the model output values are labeled using an initial risk score range, a correspondence table between the risk score range and the anxiety level prediction label should be established before model deployment.
[0213] Each risk score interval is continuous and non-overlapping, and each interval is bound to only one anxiety level prediction label. During identification, the patient's initial risk score is compared sequentially with the lower and upper boundaries of the interval, starting from the interval with the smallest value. When the initial risk score meets the predefined boundary conditions of the current interval, the subsequent comparison stops, and the anxiety level prediction label corresponding to that interval is obtained. By fixing the interval boundary assignment rules, only one label identification result is generated for the same initial risk score.
[0214] Furthermore, after obtaining the anxiety level prediction label, the target report template is determined based on the label.
[0215] Specifically, a report template index is pre-built, in which each index record includes an anxiety level prediction label code and a report template number. The currently obtained anxiety level prediction label code is compared with the report template index data one by one. When the label codes match, the report template number in the record is read, and the corresponding report template is retrieved according to the report template number. The retrieved result is used as the target report template.
[0216] Therefore, the target report template is directly determined by the anxiety level prediction label, without using a manual temporary selection method.
[0217] In this embodiment, the target report template is pre-set with fields for evaluation results, explanation, and traceability.
[0218] After calling the target report template, the anxiety level prediction label is first written into the assessment result field; then the feature explanation text is read; for cases with more than two feature explanation texts, they are arranged from smallest to largest according to the hierarchical identifiers determined in Example 7, and if the hierarchical identifiers are the same, they are arranged according to the order of the corresponding logical nodes in the decision path; after sorting, the core judgment basis, the patient's actual feature value, the node branch condition, the deviation magnitude quantification value and the explanation content corresponding to each feature explanation text are read in sequence and written into the explanation content field of the target report template; the order of the report text thus formed is consistent with the order of the decision path actually traversed by the model.
[0219] When filling in the traceability content, the core traceability chain obtained in Example 7 is read. Starting from the starting node of the chain, the splitting features, actual patient feature values, branch conditions, and actual branches entered are written sequentially according to the actual node order. When the current node is associated with feature explanation text, the explanation content corresponding to the node is associated with the node record.
[0220] The traceability content entry ends after reading the end node of the core traceability chain; after completing the evaluation results, feature interpretation and path traceability data entry, the main text of the report is formed.
[0221] Furthermore, after the main body of the report is generated, it is formatted according to the layout area pre-saved in the target report template; the anxiety level prediction label is written into the assessment conclusion area; the feature explanation text is written into the feature explanation area item by item according to the aforementioned sorting results; the core traceability chain is written into the path traceability area; each feature explanation text carries a field identifier corresponding to the core judgment basis, and establishes a connection with the corresponding logical node in the path traceability area through this field identifier, thereby avoiding misalignment of the explanation content corresponding to different features.
[0222] Furthermore, after the layout data is written, an integrity check is performed on the report content.
[0223] Specifically, the system sequentially checks whether anxiety level prediction labels exist, whether each core judgment criterion has corresponding feature explanation text, and whether the hierarchical identifier carried by the feature explanation text can be located to the logical node in the core traceability chain. When all of the above data items have corresponding records, the formatted data is saved as a clinical assessment report and output.
[0224] Therefore, the output clinical assessment report includes at least anxiety level prediction labels and corresponding feature explanation text, while retaining decision path information for tracing the formation process of the assessment results.
[0225] Example 9:
[0226] S8 includes obtaining anxiety level prediction labels and core judgment criteria, extracting label features to obtain psychological state representation vectors; classifying cognitive bias types based on psychological state representation vectors, analyzing core judgment criteria, and extracting behavioral features; matching behavioral features and cognitive bias types to determine feedback regulation strategies; and constructing text based on feedback regulation strategies and core judgment criteria to generate feedback regulation information targeting the core judgment criteria.
[0227] In this embodiment, the anxiety level prediction label determined in Embodiment 8 and the core judgment criteria determined in Embodiment 4 are first obtained. At the same time, the initial risk score corresponding to the current patient, the feature contribution value of each core judgment criterion, the deviation magnitude quantification value and the node level are read.
[0228] An anxiety level prediction label coding table is pre-established, and each anxiety level prediction label is assigned a unique integer code. After the current anxiety level prediction label is determined, the corresponding integer code is obtained through the label coding table, and this integer code is used as the first data item of the psychological state representation vector.
[0229] The initial risk score, feature contribution value, and deviation magnitude quantification value are converted using the same numerical processing rules as those used in the classification model training phase.
[0230] Specifically, the minimum and maximum values of each data field in the training data are pre-calculated; for a certain field of the current patient, the minimum value of the field is subtracted from the current field value, and the difference is divided by the difference between the maximum and minimum values of the field to obtain a standardized result with a value limited to 0 to 1; the initial risk score, the feature contribution values of all core judgment criteria, and the deviation magnitude quantification value are processed in this way.
[0231] To ensure that the psychological state representation vector has a fixed data length, the data corresponding to the core judgment criteria are arranged from the largest to the smallest value according to the feature contribution value, and the feature contribution value, deviation magnitude quantization value, and node level are extracted from the sorting results in sequence.
[0232] Specifically, the node hierarchy is calculated by dividing the current node's hierarchy number by the total number of nodes in the current decision path to obtain a hierarchy position value in the range of 0 to 1. Then, the hierarchy position values are arranged in a fixed order according to the anxiety level prediction label encoding, the standardized initial risk score, the feature contribution value corresponding to the core judgment basis, the deviation magnitude quantification value, and the hierarchy position value to form the psychological state representation vector corresponding to the current patient. For data positions that do not have a corresponding core judgment basis within a pre-defined number, they are padded with 0 to keep the data dimension of the input classification model consistent.
[0233] In addition, cognitive bias types are classified using pre-established category centers.
[0234] In this embodiment, historical samples labeled with cognitive bias types are used in the model building stage. For each historical sample, a psychological state representation vector is generated according to the aforementioned process, and the samples are grouped according to the cognitive bias type. For the same cognitive bias type, the values of each historical sample at the same vector position are accumulated, and then divided by the number of historical samples corresponding to that cognitive bias type. This yields the average value of that cognitive bias type at each vector position, and the average value of all positions forms the category center corresponding to that cognitive bias type.
[0235] In addition, when classifying the current patient, the distance between the current psychological state representation vector and the category center of each cognitive bias type is calculated.
[0236] During the calculation, two values at the same position are subtracted, the difference is multiplied by itself, and the products corresponding to all positions are accumulated. The accumulated result is used as the distance value between the current patient and the cognitive bias type. The same process is used to obtain the distance values between the current patient and all cognitive bias types, and the category with the smallest distance value is determined as the cognitive bias type corresponding to the current patient. When two categories have the same distance value, the category with the earlier coded value is selected according to the pre-saved category coding order, so that each classification obtains a unique cognitive bias type.
[0237] Furthermore, after identifying the type of cognitive bias, the core judgment criteria are analyzed. A mapping table is pre-established between the core judgment criteria fields, node branch states, and behavioral characteristics.
[0238] Specifically, each record in the mapping table includes at least a feature field, a branch status, and a behavioral feature code. During parsing, the feature field corresponding to the current core judgment basis, the patient's actual feature value, and the branch conditions in the decision path are read, and the branch status is determined based on the comparison result between the patient's actual feature value and the branch conditions.
[0239] For numerical core judgment criteria, the patient's actual feature value is compared with the node split value, and the corresponding branch state is determined based on two results: less than or equal to, or greater than. For categorical core judgment criteria, the corresponding branch state is determined by matching the patient's actual category with the category branch conditions stored in the node.
[0240] Then, using the feature field and branch status as joint retrieval conditions, the corresponding record is searched in the behavior feature mapping table, and the behavior feature code and behavior feature content are read to obtain the behavior feature corresponding to the core judgment basis.
[0241] When there are more than two core judgment criteria, the above-mentioned behavioral feature extraction process is performed on each core judgment criterion.
[0242] If two or more core judgment criteria correspond to the same behavioral feature code, then the feature contribution values corresponding to each core judgment criterion are compared. The core judgment criterion with the largest feature contribution value is used as the association criterion for that behavioral feature, and its corresponding actual patient feature value and branch conditions are retained to avoid the same behavioral feature from repeatedly entering the subsequent strategy matching process.
[0243] As a preferred embodiment, the feedback regulation strategy is determined through a pre-established strategy matching table.
[0244] Specifically, the strategy matching table uses cognitive bias type coding and behavioral feature coding as a joint index, with each joint index corresponding to one feedback regulation strategy number. After obtaining the current patient's cognitive bias type and behavioral features, the cognitive bias type coding and behavioral feature coding are combined to form search conditions. The table is then searched for records with completely identical fields. The feedback regulation strategy number stored in the record is read, and the corresponding feedback regulation strategy is retrieved based on the strategy number.
[0245] If a patient has more than two behavioral characteristics, strategy matching is performed separately to obtain the feedback regulation strategy corresponding to each behavioral characteristic.
[0246] If two behavioral features match and obtain the same feedback regulation strategy number, only one record of that strategy is retained, and the core judgment criteria associated with it are also saved; if different feedback regulation strategy numbers are matched, the feature contribution values corresponding to each core judgment criterion are arranged from the largest to the smallest to form the execution order of the feedback regulation strategy.
[0247] When generating feedback adjustment information, a pre-established text template is read according to the feedback adjustment strategy number.
[0248] Each text template should at least set the data locations corresponding to the core judgment criteria, the patient's actual characteristic state, the type of cognitive bias, the behavioral characteristics, and the adjustment content. First, write the feature name corresponding to the current core judgment criteria and the patient's actual characteristic value into the corresponding location. Then, write the cognitive bias type obtained from the classification and the behavioral characteristics obtained from the analysis. Finally, read the adjustment content saved in the feedback adjustment strategy and write it into the corresponding location to form a feedback text corresponding to the core judgment criteria.
[0249] When a patient corresponds to more than two feedback texts, they are arranged according to the execution order of the feedback adjustment strategy, and the texts corresponding to the same core judgment criteria are merged into the same data segment without changing the correspondence between the core judgment criteria and behavioral characteristics, cognitive bias types, and feedback adjustment strategies.
[0250] After the text is constructed, the resulting content will be output as feedback adjustment information based on the core judgment criteria for the current patient.
[0251] Example 10:
[0252] S9 includes parsing feedback adjustment information to obtain intervention instructions, outputting the intervention instructions to the patient terminal; receiving feedback data, which is generated by the patient terminal in response to the intervention instructions; extracting the compliance status identifier from the feedback data to calculate the execution deviation value; if the execution deviation value is greater than a preset deviation threshold, evaluating the execution deviation value to obtain a status evaluation matrix, and updating the feedback adjustment strategy according to the status evaluation matrix, thereby realizing the adjustment of the feedback adjustment strategy based on the feedback data.
[0253] In this embodiment, the feedback adjustment information generated in Embodiment 9 is read first, and the fields are parsed according to the core judgment criteria, feedback adjustment strategy number, adjustment content and execution order recorded therein.
[0254] One intervention instruction is generated for each adjustment item. Each intervention instruction includes at least the instruction number, core judgment basis identifier, feedback adjustment strategy number, execution content, execution order, and feedback status fields. After parsing all adjustment items, the intervention instructions are arranged according to the execution order, and the arranged intervention instructions are sent to the patient terminal corresponding to the current patient.
[0255] Furthermore, after receiving the intervention command, the patient terminal establishes a corresponding execution record using the command number.
[0256] After the patient completes the prescribed response operation according to the intervention instructions, the patient terminal assigns a value of 1 to the compliance status identifier corresponding to the instruction; if the corresponding response operation is not completed by the end of the prescribed response period, the compliance status identifier is assigned a value of 0; the patient terminal writes the instruction number, compliance status identifier and response result into the same feedback record, and returns the feedback data composed of each feedback record; after receiving the feedback data, it matches the instruction number with the sent intervention instructions one by one, thereby determining the core judgment basis and feedback adjustment strategy corresponding to each compliance status identifier.
[0257] After obtaining the feedback data, the compliance status indicators are statistically analyzed to obtain the execution deviation value.
[0258] Specifically, the total number of intervention instructions sent this time is read, and the number of intervention instructions with a compliance status of 0 is counted. The number of intervention instructions with a compliance status of 0 is divided by the total number of intervention instructions sent this time, and the resulting value is used as the execution deviation value of this feedback adjustment. When all compliance status indicators are 1, the execution deviation value is 0. When there is 0 in the compliance status indicators, the execution deviation value is determined according to the proportion of the number of unexecuted instructions to the total number of instructions.
[0259] As a preferred embodiment, the preset deviation threshold is predetermined based on the historical execution records of the feedback adjustment strategy.
[0260] Specifically, historical feedback records that use the current feedback adjustment strategy and are confirmed by subsequent results to require no strategy adjustment are selected. The execution deviation value corresponding to each historical feedback record is calculated using the same execution deviation value calculation method as the current patient. The obtained execution deviation values are arranged in ascending order, and the maximum value is read and used as the deviation threshold corresponding to the current feedback adjustment strategy. The corresponding deviation thresholds for different feedback adjustment strategies are saved separately. After the feedback adjustment strategy updates the training samples, the corresponding deviation thresholds are recalculated according to the above process.
[0261] Compare the current patient's execution deviation value with the deviation threshold corresponding to the current feedback adjustment strategy.
[0262] When the execution deviation value is less than or equal to the deviation threshold, the current feedback adjustment strategy is maintained; when the execution deviation value is greater than the deviation threshold, the state evaluation matrix generation process is initiated.
[0263] The status assessment matrix uses the core judgment criteria involved in the current feedback adjustment information as row data, and the feature contribution value, the number of intervention instructions sent, the number of intervention instructions not executed, and the local execution deviation value as column data.
[0264] For each core judgment criterion, firstly, all intervention instructions associated with that core judgment criterion are read, the total number of instructions corresponding to that core judgment criterion is counted, and then the number of instructions with a compliance status of 0 is counted. The number of instructions with a compliance status of 0 is divided by the total number of instructions corresponding to that core judgment criterion to obtain the local execution deviation value corresponding to that core judgment criterion. Then, the feature contribution value obtained by that core judgment criterion in the aforementioned anxiety assessment process is read, and the feature contribution value, the total number of instructions, the number of unexecuted instructions, and the local execution deviation value are written into the same line to form the status record corresponding to that core judgment criterion.
[0265] The above processing is performed sequentially on all core judgment criteria to obtain the state evaluation matrix.
[0266] When using the state evaluation matrix to determine the feedback adjustment strategy that needs to be adjusted, the local execution deviation value corresponding to each core judgment basis is read line by line and compared with the deviation threshold corresponding to the current feedback adjustment strategy.
[0267] When the local execution deviation value is greater than the deviation threshold, the core judgment basis is identified as the object to be adjusted; when the local execution deviation value is less than or equal to the deviation threshold, the feedback adjustment strategy currently used by the core judgment basis is retained.
[0268] For the core judgment criteria for identifying the object to be adjusted, read its corresponding cognitive bias type, behavioral characteristics and current feedback adjustment strategy number, and re-retrieve strategy records in the strategy matching data used in Example 9 where the cognitive bias type and behavioral characteristics are consistent.
[0269] During the retrieval, the current feedback adjustment strategy number is excluded, and the first feedback adjustment strategy number that has not been excluded is read according to the pre-saved strategy priority order. This strategy is then used as the current core judgment basis for the updated feedback adjustment strategy.
[0270] If there are more than two objects to be adjusted in the state assessment matrix, the strategy rematch will be completed independently based on the cognitive bias type and behavioral characteristics of each object to be adjusted; the core judgment criteria for those not identified as objects to be adjusted will continue to use the original feedback adjustment strategy.
[0271] After the strategy update is completed, the new feedback adjustment strategy number will be re-associated with the corresponding core judgment criteria. At the same time, the execution deviation value, local execution deviation value, state evaluation matrix and the original feedback adjustment strategy number will be saved as a historical record for subsequent feedback adjustments.
[0272] Furthermore, after the feedback adjustment strategy is updated, feedback adjustment information for the corresponding core judgment criteria is regenerated based on the updated feedback adjustment strategy and sent to the patient terminal in the next feedback cycle.
[0273] Therefore, the patient's feedback data on the intervention instructions is statistically analyzed to form an execution deviation value. Then, the deviation threshold is used to determine the core criteria for adjustment through the status assessment matrix, and finally the corresponding feedback adjustment strategy is updated.
[0274] Example 11:
[0275] Design experiments to verify this application:
[0276] Validation data and experimental environment:
[0277] The simulated screening sample consisted of 800 cases, which were stratified in an 8:2 ratio into a training set (640 cases) and a retention set (160 cases).
[0278] The anxiety state is driven by a known logistic regression-type generative equation. The generative coefficient β has been set and does not participate in any modeling or parameter tuning in this method. It is only used to calculate the objective benchmark.
[0279] Model configuration: Decision tree (maximum depth 6, minimum number of leaf nodes 12); Comparison models: Logistic regression (trained after standardization), Random forest (200 trees);
[0280] Performance evaluation employed 5-fold stratified cross-validation (mean ± standard deviation) and holdout ROC analysis.
[0281] Feature attribution comparison: This method (path Shapley marginal attribution, i.e., calculating the marginal contribution of each node along the decision path and accumulating and aggregating it), random forest permutation importance, and logistic regression standardized coefficient |β|;
[0282] Follow-up experiment: 500 simulated individuals were followed up for 4 weeks to compare this method (targeted intervention based on core judgment criteria and adjusted weekly based on feedback data) with a static general strategy (suggestions are given uniformly according to severity, without adjustment based on feedback).
[0283] Experiment 1: Performance Comparison Evaluation
[0284] like Figure 3 As shown in Table 1, 5-fold stratified cross-validation was performed on the three methods, and the ROC curves of the hold-out set were plotted.
[0285] Table 1. Performance Comparison of Three Methods (5-fold Cross-validation, Mean ± Standard Deviation)
[0286]
[0287] This method employs a simplified single decision tree for evaluation, with a cross-validation AUC of 0.703, a hold-out AUC of 0.715, and sensitivity and specificity of approximately 0.53 and 0.75, respectively. Compared to logistic regression and random forest, the overall discrimination is slightly lower, but it remains usable on medium-sized screening datasets. It should be noted that the distinguishing advantage of this method lies not in the discrimination itself, but in the interpretability, traceability, and verifiability of the evaluation results—the decision tree naturally retains the complete decision path while outputting the risk score (leaf node positivity rate). This path can be directly used for subsequent node-by-node attribution and reporting traceability, which is difficult for logistic regression and random forest to provide directly. The purpose of this experiment is to demonstrate that, without significantly sacrificing evaluation performance, this method can provide clinicians with evaluation results that demonstrate a visible judgment process.
[0288] Experiment 2: Reliability of Feature Attribution and Core Judgment Criteria
[0289] Since the anxiety state of the validation population is driven by a known equation, the true driving strength (normalized |β|·σ) of each feature can be calculated based on the generation coefficient and feature dispersion, serving as the sole objective benchmark. This method performs feature attribution (node-by-node marginal contribution, accumulating and aggregating to obtain the contribution values of each feature) along each sample's decision path, and then selects the core judgment criteria based on the contribution values. The control group uses random forest permutation importance and logistic regression standardized coefficients. The results are shown in Table 2.
[0290] Table 2. Comparison of consistency between three attribution / importance methods and actual driving strength.
[0291]
[0292] In Table 2, importance / contribution were normalized to 0-1; correlation was Spearman rank correlation; the top 3 driving factors were: sleep disorders, stressful events, and disease course.
[0293] like Figure 4 As shown in Table 2, the top three strongest features under the known driving equation are sleep disturbance, stressful events, and disease course. The top three core judgment criteria given by the path attribution method in this paper are completely consistent with these (3 / 3 hit), with a Spearman correlation of 0.929, which is higher than the standardized coefficient of logistic regression (0.821, 2 / 3 hit) and is in the same high correlation interval as the importance of random forest permutation (1.000, 3 / 3 hit). Both the importance of random forest permutation and the logistic regression coefficient can only give the overall importance and cannot be applied to specific individuals. This method calculates the marginal contribution of each sample along its own true decision path node by node and accumulates and aggregates them. Based on this, it can generate an individual explanation text of why the patient is judged to be high-risk, which is consistent with the explanation of the basis for the assessment results from the individual level. This method decomposes the sample path, and features other than strong signals (such as social support, attribution contribution 0.547) will be retained according to their actual splitting effect in a single path, avoiding averaging and masking key individual factors, which is more in line with the single-case review scenario.
[0294] Clinical assessment report traceability example:
[0295] One real positive patient was selected from the hold-out set (160 cases, the model was not used for training). The results of the anxiety level prediction label, core judgment criteria, and decision path tracing generated by this method are presented:
[0296] Predictive label: High risk (leaf node positivity rate 1.000);
[0297] True label: positive;
[0298] Tracing the decision-making path: Sleep disturbance >1.5 → No stressful events → Social support ≤8.8 → Disease duration >3.9 → Disease duration ≤4.2;
[0299] This pathway can be directly summarized into a clinically readable explanatory text: This patient has significant sleep disturbances, insufficient social support (social support ≤ 8.8), and a disease duration of 3.9-4.2 years. Based on these factors, the patient is assessed as high-risk for anxiety, and it is recommended that sleep improvement and social support enhancement be the main intervention directions. As can be seen, the assessment results output by this method simultaneously include predictive conclusions, main influencing factors (core judgment criteria), and judgment process (decision-making path).
[0300] Experiment 3: Feedback Regulation Closed Loop (4-week follow-up)
[0301] Two intervention strategies were compared in a simulated population of 500 (4 weeks, with each week being the minimum intervention-feedback period):
[0302] This method group: determined the intensity of personalized intervention based on anxiety level prediction labels and core judgment criteria (prominent sleep disorders, stressful events, etc.); and dynamically adjusted the strategy weekly based on patient feedback (symptom item response, compliance indicators), for example, increasing the dosage for those with slow sleep improvement and fine-tuning the reinforcement coefficient weekly for those with good compliance.
[0303] Static general strategy group: Provides fixed suggestions based solely on light / moderate / severe severity, without being oriented according to core judgment criteria or adjusted based on feedback.
[0304] During the follow-up, the following criteria were established: individual susceptibility differences existed (those with severe sleep disorders, advanced age, or stressful events had higher response rates); in the mid-to-late stages (weeks 3-4), the adherence retention rate in the static group decreased from 90% to 74%, while the retention rate in the method group remained at around 88% due to more targeted feedback; the weekly average symptom relief and the average residual risk for the group are shown in Table 3, and the trends are shown in […]. Figure 5 and Figure 6 .
[0305] Table 3. Comparison of remission rate and residual risk at 4-week follow-up (group mean)
[0306]
[0307] like Figure 5 and Figure 6 As shown, the remission rate in this method group was higher than that in the static group at each week, and remained at a high level as feedback was adjusted (15.3% vs 11.7% in week 4); the cumulative remission rate over 4 weeks was 67.2%, which was about 10.5 percentage points higher than that in the static group (56.7%), suggesting that intervention based on core judgment and targeted intervention is more suitable for individual problems than uniform recommendations; the difference between the two groups was not significant in week 1 (18.4% vs 16.8%), but as feedback data was gradually incorporated into the adjustment, the gap widened to 3.4-3.6 percentage points in weeks 3-4, indicating that the mechanism of adjusting the feedback adjustment strategy based on feedback data brought continuous gains rather than a one-off effect; by the end of week 4, the average residual risk in this method group decreased to 0.211, which was about 0.027 lower than that in the static group (0.238); combined with the adherence retention rate (88% vs 74%), it shows that personalized intervention information updated with feedback is superior to static general strategies in maintaining patient engagement and long-term effects.
[0308] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A method for assessing and regulating patient anxiety levels based on an artificial intelligence model, characterized in that, include: S1. Obtain the patient's multidimensional feature data, and use the decision tree algorithm to split the multidimensional feature data into nodes to obtain the initial risk score and the decision path corresponding to the initial risk score. S2. For the decision path, the feature attribution algorithm is used to analyze each node in the decision path to obtain the feature contribution value corresponding to each feature in the multi-dimensional feature data. S3. Obtain the pre-established contribution determination rules and preset thresholds, determine whether the feature contribution value is greater than the preset threshold, and if the feature contribution value is greater than the preset threshold, determine the corresponding feature as the core judgment basis. S4. Based on the core judgment criteria, extract the branch node information in the decision-making path to obtain the interaction relationship of the core judgment criteria in the decision-making path. S5. Through the interaction relationship, the initial risk score is numerically decomposed to obtain the feature explanation text for the core judgment basis; S6. Obtain the feature explanation text and decision path, and perform structured splicing of the feature explanation text and decision path to generate the final evaluation result containing path tracing information. S7. Based on the final assessment results, extract the anxiety level prediction labels and output a clinical assessment report containing the anxiety level prediction labels and feature explanation text. S8. Based on the anxiety level prediction label and core judgment criteria, determine the feedback regulation strategy corresponding to the patient, and generate feedback regulation information for the core judgment criteria based on the feedback regulation strategy. S9. Output the feedback adjustment information to the patient, obtain the feedback data generated by the patient in response to the feedback adjustment information, and adjust the feedback adjustment strategy according to the feedback data.
2. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S1 includes: The patient's multidimensional feature data is obtained from medical history records; The decision tree algorithm is used to calculate the multidimensional feature data and determine the optimal splitting feature; Node splitting is performed using the optimal splitting features to obtain the sub-feature matrix and branching conditions; A decision tree model is generated for the sub-feature matrix, the initial risk score corresponding to the decision tree model is obtained, and the branch conditions are recorded to obtain the decision path corresponding to the initial risk score.
3. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S2 includes: Obtain decision path and multidimensional feature data, and extract node splitting conditions and sample sets of decision path; Calculate the path weights and feature distribution states based on the node splitting conditions and the sample set; The feature attribution algorithm is used to analyze the path weights and feature distribution status to obtain the marginal contribution values; If the marginal contribution value is greater than the preset contribution threshold, the marginal contribution value is accumulated and aggregated to obtain the feature contribution value corresponding to each feature in the multidimensional feature data.
4. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S3 includes: Obtain the pre-established contribution determination rules and preset thresholds, analyze the feature contribution values through the contribution determination rules, and obtain the numerical comparison results; If the numerical comparison result meets the threshold triggering condition, the feature contribution value is determined to be greater than the preset threshold, and the corresponding feature is determined as the core judgment basis.
5. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S4 includes: Obtain the core judgment criteria, map the core judgment criteria, and locate the initial branch node; Traverse the decision tree graph based on the initial branch nodes to obtain the first logical link and the second logical link; Compare the first logical link with the second logical link to determine the target dependency; If the target dependency relationship meets the preset connectivity conditions, the branch node information in the decision path is extracted based on the target dependency relationship to obtain the interaction relationship of the core judgment basis in the decision path.
6. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S5 includes: The initial risk scores are allocated based on the interaction relationships to obtain the risk contribution weights; The risk contribution weight is calculated by the node attenuation ratio to obtain the link transmission value; The deviation magnitude quantization value is obtained by performing a numerical decomposition operation between the link transmission value and the baseline of the basic score; If the deviation magnitude quantization value is greater than the deviation threshold, the semantic mapping dictionary is queried based on the deviation magnitude quantization value to match the feature explanation text for the core judgment basis.
7. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S6 includes: Obtain feature explanation text and decision path; segment the feature explanation text to obtain semantic fragments; and parse the decision path to obtain logical nodes. The hierarchical identifier is determined based on the correspondence between semantic fragments and logical nodes. The semantic fragments are then arranged using the hierarchical identifiers to obtain the text sequence. The text sequence is truncated and extracted to obtain the core traceability chain; The core traceability chain and feature explanation text are structurally concatenated to generate a final evaluation result containing path tracing information.
8. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S7 includes: Obtain the final evaluation results, analyze the final evaluation results, and obtain the predicted label set and feature explanation text; Identify the set of predicted labels to obtain predicted labels for anxiety levels; The target report template is determined based on the anxiety level prediction label. The feature explanation text is then assembled using the target report template to obtain the report content. The system formats and outputs a clinical assessment report that includes anxiety level prediction labels and explanatory text.
9. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S8 includes: Obtain anxiety level prediction labels and core judgment criteria, extract label features, and obtain psychological state representation vectors; Cognitive bias types are identified by classifying psychological state representation vectors, core judgment criteria are analyzed, and behavioral features are extracted. Based on behavioral characteristics and cognitive bias types, a matching strategy for feedback regulation is determined. Based on the feedback adjustment strategy and core judgment criteria, text is constructed, and feedback adjustment information is generated for the core judgment criteria.
10. The method for assessing and regulating patient anxiety levels based on an artificial intelligence model according to claim 1, characterized in that: S9 includes: The intervention instructions are obtained by analyzing the feedback adjustment information and then output to the patient's terminal. Receive feedback data, which is generated by the patient terminal in response to intervention commands; The compliance status identifiers in the feedback data are extracted to calculate the execution deviation value; If the execution deviation value is greater than the preset deviation threshold, the execution deviation value is evaluated to obtain the state evaluation matrix. The feedback adjustment strategy is updated according to the state evaluation matrix, so as to adjust the feedback adjustment strategy according to the feedback data.