Psychiatry pre-diagnosis triage knowledge reasoning method based on knowledge graph

By constructing a knowledge graph for pre-diagnosis psychiatry and combining it with an improved Bioformer model and AnyBURL algorithm, the semantic recognition and self-learning problems of existing pre-diagnosis triage methods for psychiatry are solved. This enables the generation of highly accurate and interpretable triage suggestions, improving the intelligence level and adaptability of the triage system.

CN121543713APending Publication Date: 2026-02-17HEFEI FOURTH PEOPLES HOSPITAL

Patent Information

Application Number
CN202511616495.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-06
Publication Date
2026-02-17

AI Technical Summary

Technical Problem

Existing pre-diagnosis triage methods in psychiatry are unable to effectively identify the deep semantic structure of patients' chief complaints, lack unified modeling of multi-source information, cannot handle complex multi-hop paths and heterogeneous symptom combinations, and lack interpretability and self-learning ability, resulting in inaccurate triage recommendations that are difficult to update.

Method used

A knowledge graph-based approach was adopted to construct a pre-diagnosis knowledge graph for psychiatry. By combining an improved Bioformer model and an improved AnyBURL algorithm, semantic matching and path rule mining were performed to generate interpretable triage suggestions. Self-learning optimization was carried out through pre-diagnosis data standardization and post-diagnosis feedback.

Benefits of technology

It improves the accuracy and interpretability of triage recommendations, enhances the system's adaptability, and enables personalized triage path recommendations and clinical decision support.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121543713A_ABST
    Figure CN121543713A_ABST
Patent Text Reader

Abstract

The invention discloses a psychiatry pre-diagnosis triage knowledge reasoning method based on a knowledge graph. The method comprises the steps that 1, pre-diagnosis original data are collected and preprocessed; 2, constructing a pre-diagnosis knowledge graph of the psychiatry department; 3, obtaining a standardized chief complaint text, and carrying out semantic coding through an improved Biofer model to generate a chief complaint semantic vector; 4, performing semantic matching on the chief complaint semantic vector and a pre-diagnosis knowledge graph of the psychiatry department, and screening and reasoning an initial node set; 5, executing rule path reasoning on the pre-diagnosis knowledge graph of the psychiatry department by adopting an improved AnyBURL algorithm; step 6, constructing a recommended triage suggestion set; 7, pushing the recommended triage suggestion set to a doctor terminal interface, and generating a triage result set; and step 8, acquiring feedback information after diagnosis, and performing incremental updating on the pre-diagnosis knowledge graph of the psychiatry department and the improved Bioformer model. According to the method, the semantic understanding ability and the reasoning decision level of the pre-diagnosis triage of the psychiatry department are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical artificial intelligence and knowledge graph reasoning technology, and in particular to a knowledge graph-based method for psychiatric pre-diagnosis triage knowledge reasoning. Background Technology

[0002] With the rapid development of intelligent healthcare and semantic reasoning technologies, intelligent systems assisting in pre-diagnosis triage and pathway recommendation in psychiatry are gradually becoming an important direction for improving the efficiency of outpatient triage and optimizing the allocation of clinical resources in hospitals. Existing psychiatric triage methods mainly rely on rule engines or knowledge base systems based on keyword matching to perform preliminary analysis of patient complaints, psychological scale scores, and historical medical data, recommending departments or priorities. However, in practical applications, the following problems commonly exist:

[0003] Patient complaints are often vague and varied, making it difficult for existing methods to effectively identify deep semantic structures. The lack of a unified modeling approach among multi-source pre-diagnosis information leads to sparse feature dimensions and semantic inconsistencies after structured processing. Rule-based triage logic cannot handle complex multi-hop paths and heterogeneous symptom combinations, hindering personalized treatment path recommendations. Existing models lack effective mechanisms for absorbing post-diagnosis confirmation and feedback from doctors, resulting in a stagnant knowledge system that cannot adapt to the dynamic changes in mental illness manifestations and treatment strategies. Triage suggestions lack interpretability and path traceability, making it difficult for doctors to quickly assess the rationality of recommendations.

[0004] Therefore, how to provide a knowledge-based reasoning method for psychiatric pre-diagnosis triage is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention

[0005] One objective of this invention is to propose a knowledge graph-based pre-diagnosis triage knowledge reasoning method for psychiatry. This invention fully integrates medical knowledge graph construction, an improved Bioformer model, and an improved AnyBURL algorithm. It describes in detail how to construct a heterogeneous semantic graph through pre-diagnosis data and generate an interpretable triage suggestion set based on semantic matching and path rule mining. It has the advantages of high accuracy of triage suggestions, strong semantic reasoning ability, excellent interpretability, and sustainable self-learning.

[0006] The knowledge graph-based pre-diagnosis triage knowledge reasoning method for psychiatric patients according to embodiments of the present invention includes the following steps: Step 1: Collect raw pre-diagnosis data and preprocess it to form a structured pre-diagnosis dataset; Step 2: Construct a psychiatric pre-diagnosis knowledge graph based on a structured pre-diagnosis dataset; Step 3: Obtain the standardized chief complaint text and input it into the improved Bioformer model for semantic encoding to generate a chief complaint semantic vector; Step 4: Perform semantic matching between the chief complaint semantic vector and the psychiatric pre-diagnosis knowledge graph, filter the set of symptom nodes that meet the threshold conditions, and obtain the initial node set for inference; Step 5: Based on the initial inference node set, the improved AnyBURL algorithm is used to perform rule-based path inference on the psychiatric pre-diagnosis knowledge graph, and output the target symptom node set and the target path rule set; Step Six: Construct a set of recommended triage suggestions based on the target symptom node set and the target path rule set; Step 7: Push the recommended triage suggestion set to the doctor's terminal interface, and generate a triage result set based on the patient's original pre-diagnosis data; Step 8: Collect post-diagnosis feedback information and perform incremental updates on the pre-diagnosis knowledge graph of psychiatry and the improved Bioformer model.

[0007] Optionally, step one specifically includes: The pre-diagnosis raw data includes patient chief complaint text, psychological scale response information, past medical history text, past medication records and auxiliary diagnosis and treatment data; The patient's chief complaint text is formatted and cleaned of symbols to generate a standardized chief complaint text. Then, the standardized chief complaint text is subjected to syntactic analysis and named entity recognition to extract the set of symptom keywords and the symptom duration field. The psychological scale response information is parsed and scores are extracted to generate a set of psychological scale score fields. Perform medical terminology standard mapping and entity normalization on the past medical history text and past medication records to generate standardized disease terminology fields and standardized drug name fields; Perform field normalization and timestamp alignment on the auxiliary diagnosis and treatment data to generate structured auxiliary diagnosis and treatment fields; The standardized chief complaint text, symptom keyword set, symptom duration field, psychological scale score field set, standardized disease terminology field, standardized drug name field, and structured auxiliary diagnosis and treatment field are combined according to a predetermined format to form a structured pre-diagnosis dataset.

[0008] Optionally, step two specifically includes: Access standard medical terminology sets, disease classification systems, symptom description vocabularies, drug information sets, psychological scale indicators, and standardized treatment pathway texts in the field of psychiatry through the medical institution knowledge engineering interface; Based on the symptom description lexicon, terminology standardization mapping and semantic expansion are performed on the symptom keyword set and symptom duration field to generate a symptom node set, and symptom node attribute fields are added. The symptom node attribute fields include symptom classification label, duration, source identifier and confidence score. Based on the psychological scale indicators, standard indicator matching is performed on the psychological scale rating field set to generate a psychological feature node set, and psychological feature node attribute fields are added. The psychological feature node attribute fields include scale type, rating level and assessment dimension. Based on the disease classification system and drug information set, terminology mapping and semantic alignment are performed on the standardized disease terminology field and the standardized drug name field to generate disease node set and drug node set, and diagnosis and treatment attribute fields are added, including diagnosis time, disease stage, drug dosage and usage information. Based on the structured auxiliary diagnosis and treatment fields, an auxiliary examination node set is generated, and auxiliary examination attribute fields are added. The auxiliary examination attribute fields include examination type, examination time, and core indicators. The set of symptom nodes, the set of psychological characteristic nodes, the set of disease nodes, the set of drug nodes, and the set of auxiliary examination nodes constitute a node set; The symptom node attribute field, the psychological characteristic node attribute field, the diagnosis and treatment attribute field, and the auxiliary examination attribute field constitute a set of node attribute fields; Based on the standard medical terminology set and the standardized text of diagnosis and treatment pathways, the semantic relationships between nodes in the node set are identified, and a set of semantic relationship edges is generated. The set of semantic relationship edges includes symptom-disease edges, psychological characteristics-disease edges, drug-disease edges, and auxiliary examination-disease edges. Each semantic relation edge is injected with an edge attribute field, which includes edge type, source rule, co-occurrence frequency and confidence score, forming a set of edge attribute fields; By fusing and connecting the node set, semantic relation edge set, node attribute field set, and edge attribute field set, a psychiatric pre-diagnosis knowledge graph is generated.

[0009] Optionally, step three specifically includes: Obtain standardized chief complaint text from the structured pre-diagnosis dataset, wherein the standardized chief complaint text includes several chief complaint terms; A standard medical terminology set for psychiatry is constructed based on a standard medical terminology set, which includes several ontological terms. Each chief complaint term in the standardized chief complaint text is semantically matched with an ontology term in the standard medical terminology set for psychiatry using cosine similarity, and the ontology term with the highest cosine similarity is selected for semantic alignment with the chief complaint term. Use the category subscripts of semantically aligned ontology terms as the medical terminology category labels for the main complaint; Each semantically aligned ontology term is mapped to an embedding vector space through a predefined embedding matrix to obtain the ontology semantic vector of each subject term; A positional encoding vector is constructed for each main complaint using sine and cosine functions; The medical term category label of each chief complaint is mapped to a term category label vector through a trainable embedding matrix; The ontology semantic vector, position encoding vector and term category label vector of each main complaint term are concatenated and fused to generate an ontology semantic fusion vector; All ontology semantic fusion vectors are arranged into an ontology semantic embedding sequence according to the order of the main complaint; Based on the standard medical terminology set for psychiatry, ontology terms are mapped to medical term ontology nodes, and term ontology relation edges are constructed according to the co-occurrence relationship, superior-inferiority relationship, synonym relationship and combination relationship between ontology terms to form a medical ontology graph; Each chief complaint word in the standardized chief complaint text is mapped to a medical term ontology node in the medical ontology graph. If there is a term ontology relationship edge between the mapped medical term ontology nodes, the cosine similarity between the corresponding chief complaint words is used as the attention bias weight. Otherwise, the attention bias weight is set to 0, and an attention bias matrix is ​​generated based on the attention bias weight. The ontology semantic embedding sequence is mapped to a query matrix, a key matrix, and a value matrix through three sets of trainable weight matrices; Perform matrix multiplication and scaling normalization on the query matrix and key matrix, and combine with the attention bias matrix to calculate the attention weight matrix; The attention weight matrix and the value matrix are multiplied together to generate the ontology attention matrix. The ontology attention matrix is ​​then subjected to average pooling in the sequence dimension to generate the subject semantic vector.

[0010] Optionally, step four specifically includes: The Node2Vec graph embedding algorithm is used to model the pre-diagnosis knowledge graph of psychiatry, and the node embedding vector of each node in the node set is obtained to form a node embedding vector set. The semantic similarity score is calculated between the main complaint semantic vector and each node embedding vector in the node embedding vector set. The semantic similarity score is calculated by calculating the Euclidean distance between the main complaint semantic vector and the node embedding vector, and then taking the reciprocal of the Euclidean distance after adding 1. A semantic similarity threshold is set, and nodes in the psychiatric pre-diagnosis knowledge graph whose semantic similarity scores exceed the semantic similarity threshold are selected as the initial node set for inference.

[0011] Optionally, step five specifically includes: Define a node sampling probability function, which calculates the sampling probability based on the semantic similarity score between the claim semantic vector and the nodes in the initial inference node set; Based on the sampling probability, from the nodes in the initial node set of inference... Starting from this point, multiple rounds of random walks are performed in the pre-diagnosis knowledge graph of psychiatry according to the set path length to generate a set of reasoning paths; Based on the inference path set, the entity nodes and edge relationships in each inference path are transformed into a sequence of path triples, and the sequence of path triples is constructed into a set of inference path rules according to the preset Horn rule template. For each inference path rule in the inference path rule set, a structural confidence score is calculated. The structural confidence score is equal to the ratio of the number of inference triples that can be correctly predicted by applying the inference path rule and that exist in the pre-psychiatric knowledge graph to the total number of inference triples generated after applying the inference path rule. The structural confidence score is used to measure the prediction accuracy of the path rule on the pre-psychiatric knowledge graph. All reasoning path rules are applied to the pre-diagnosis knowledge graph of psychiatry to generate a set of reasoning triples, and the tail entity node of each reasoning triple is used as a candidate symptom node. Calculate the semantic similarity score between the semantic vector of the chief complaint and the node embedding vector of the candidate symptom nodes; The structural confidence score and the corresponding semantic similarity score are weighted and fused according to a preset weight to generate the semantic rule confidence score; Based on the semantic rule confidence, all reasoning path rules in the reasoning path rule set are sorted, and the top-ranked reasoning path rules are used to form the target path rule set. The candidate symptom nodes corresponding to these reasoning path rules are used to form the target symptom node set.

[0012] Optionally, step six specifically includes: A triage rule base is established, wherein each triage rule in the triage rule base includes a symptom combination pattern, a path structure pattern, and a triage suggestion; Based on the target path rule set, structural matching is performed on the path structure patterns in the triage rule base to filter candidate triage rules that are consistent with the target path rule set. The target symptom node set is matched with the symptom combination patterns in the candidate triage rules to identify the symptom node coverage relationship and filter the triage rules that meet the symptom combination patterns. The triage suggestions corresponding to the triage rules that satisfy the path structure pattern and symptom combination pattern are summarized to form a set of recommended triage suggestions. The set of recommended triage suggestions includes triage suggestions for psychiatric outpatient clinics, suggestions for priority of visits, and suggestions for referral pathways.

[0013] Optionally, the triage result set includes triage suggestion items in the recommended triage suggestion set, target symptom nodes and target path rules corresponding to the triage suggestion items, the reason for the suggestion, optional referral suggestions and priority identification, and confirmation or modification options executed by the doctor.

[0014] Optionally, the post-diagnosis feedback information includes the doctor's confirmation of the results, modification suggestions, final diagnosis label, and actual treatment path.

[0015] The beneficial effects of this invention are: First, this invention collects patient complaint texts, psychological scale responses, past medical history texts, past medication records, and auxiliary diagnostic data, and performs standardized analysis on the pre-diagnosis data to generate a structured pre-diagnosis dataset, ensuring the integrity and standardization of the basic data for knowledge modeling and semantic reasoning.

[0016] Secondly, a psychiatric pre-diagnosis knowledge graph was constructed based on a structured pre-diagnosis dataset. This graph integrates a standard medical terminology set, a disease classification system, a symptom description lexicon, a drug information set, and standardized texts for diagnosis and treatment pathways. It also constructs a set of multiple types of nodes, including symptom nodes, psychological feature nodes, disease nodes, drug nodes, and auxiliary examination nodes, along with their semantic relationship edges. This ensures the comprehensiveness, professionalism, and scalability of the psychiatric pre-diagnosis knowledge structure.

[0017] Furthermore, the improved Bioformer model proposed in this invention is based on ontology semantic embedding and ontology attention, and combines a medical ontology graph to construct an attention bias matrix, effectively improving the ability of the chief complaint semantic vector to model the contextual structure of medical terms, and significantly enhancing the medical semantic accuracy and interpretability of the chief complaint semantic encoding results. Utilizing an improved AnyBURL reasoning algorithm driven by semantic similarity and structural confidence, a target symptom node set and a target path rule set are constructed. Combining path structure patterns and symptom combination patterns, a recommended triage suggestion set conforming to pre-diagnosis semantics and knowledge logic is generated, realizing automated knowledge reasoning for triage tasks. By pushing the recommended triage suggestion set to the doctor's terminal interface and generating a triage result set based on the patient's pre-diagnosis raw data, the implementation of pre-clinical triage auxiliary decision-making is supported.

[0018] In summary, this invention effectively improves the accuracy of triage recommendations, the intelligence level of knowledge reasoning, and the adaptive evolution capability of the system. Attached Figure Description

[0019] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:

[0020] Figure 1 This is a schematic diagram of the knowledge reasoning method for pre-diagnosis triage in psychiatry based on knowledge graphs proposed in this invention; Figure 2 This is a flowchart of the improved Bioformer model for generating chief complaint semantic vectors in the knowledge graph-based psychiatric pre-diagnosis triage knowledge reasoning method proposed in this invention; Figure 3 This is a flowchart of the improved AnyBURL rule reasoning process in the knowledge graph-based pre-diagnosis triage knowledge reasoning method for psychiatry proposed in this invention. Detailed Implementation

[0021] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0022] refer to Figures 1-3 A knowledge graph-based pre-diagnosis triage knowledge reasoning method for psychiatric patients includes the following steps: Step 1: Collect raw pre-diagnosis data and preprocess it to form a structured pre-diagnosis dataset; Step 2: Construct a psychiatric pre-diagnosis knowledge graph based on a structured pre-diagnosis dataset; Step 3: Obtain the standardized chief complaint text and input it into the improved Bioformer model for semantic encoding to generate a chief complaint semantic vector; Step 4: Perform semantic matching between the chief complaint semantic vector and the psychiatric pre-diagnosis knowledge graph, filter the set of symptom nodes that meet the threshold conditions, and obtain the initial node set for inference; Step 5: Based on the initial inference node set, the improved AnyBURL algorithm is used to perform rule-based path inference on the psychiatric pre-diagnosis knowledge graph, and output the target symptom node set and the target path rule set; Step Six: Construct a set of recommended triage suggestions based on the target symptom node set and the target path rule set; Step 7: Push the recommended triage suggestion set to the doctor's terminal interface, and generate a triage result set based on the patient's original pre-diagnosis data; Step 8: Collect post-diagnosis feedback information and perform incremental updates on the pre-diagnosis knowledge graph of psychiatry and the improved Bioformer model.

[0023] In this embodiment, step one specifically includes: The pre-diagnosis raw data includes patient chief complaint text, psychological scale response information, past medical history text, past medication records and auxiliary diagnosis and treatment data; The patient's chief complaint text is formatted and cleaned of symbols to generate a standardized chief complaint text. Syntactic analysis and named entity recognition are then performed on the standardized text to extract a set of symptom keywords and a symptom duration field. Format standardization includes unifying character encoding, converting full-width and half-width characters, standardizing numerical expressions, and removing redundant punctuation and content. Symbol cleansing includes removing emoticons, garbled characters, emotional slang, and diagnostically irrelevant text. Syntactic analysis uses the HanLP tool to extract time adverbs, modifying structures, and grammatical dependencies from the standardized chief complaint text. Named entity recognition uses a BioBERT model to extract entities from the chief complaint text, identifying symptom names, durations, and triggering factors, generating a set of symptom keywords and a symptom duration field. The psychological scale response information is parsed and scores are extracted to generate a set of psychological scale scoring fields. The field parsing includes identifying the scale item number, answer options and scoring rules. The score extraction includes calculating the total score and scores of each dimension based on the item answers and the standard scale scoring template to generate a set of psychological scale scoring fields. The set of fields includes a scale name field, a total score field and a dimension score field.

[0024] The medical terminology standard mapping and entity normalization processes are performed on the past medical history text and past medication records to generate standardized disease terminology fields and standardized drug name fields. The medical terminology standard mapping is based on the ICD-10 psychiatric subclass dictionary and disease ontology database. Non-standardized disease descriptions are mapped to standard disease terminology fields through keyword matching, fuzzy matching and semantic similarity calculation. The drug entity normalization process is based on the national drug standard name database and combines the alias dictionary and drug naming rules to extract drug name entities and transform them into standard drug name fields.

[0025] The auxiliary diagnostic data is subjected to field normalization and timestamp alignment to generate structured auxiliary diagnostic fields. The field normalization includes standard terminology mapping and structured field conversion for examination results, examination names, examination units and diagnostic labels. The timestamp alignment includes unifying time granularity, filling missing values ​​and cross-field time synchronization. The standardized chief complaint text, symptom keyword set, symptom duration field, psychological scale score field set, standardized disease terminology field, standardized drug name field, and structured auxiliary diagnosis and treatment field are combined according to a predetermined format to form a structured pre-diagnosis dataset.

[0026] In this embodiment, step two specifically includes: Access standard medical terminology sets, disease classification systems, symptom description vocabularies, drug information sets, psychological scale indicators, and standardized treatment pathway texts in the field of psychiatry through the medical institution knowledge engineering interface; Based on the symptom description lexicon, terminology standardization mapping and semantic expansion are performed on the symptom keyword set and symptom duration field to generate a symptom node set, and symptom node attribute fields are added. The symptom node attribute fields include symptom classification label, duration, source identifier and confidence score. Based on the psychological scale indicators, standard indicator matching is performed on the psychological scale rating field set to generate a psychological feature node set, and psychological feature node attribute fields are added. The psychological feature node attribute fields include scale type, rating level and assessment dimension. Based on the disease classification system and drug information set, terminology mapping and semantic alignment are performed on the standardized disease terminology field and the standardized drug name field to generate disease node set and drug node set, and diagnosis and treatment attribute fields are added, including diagnosis time, disease stage, drug dosage and usage information. Based on the structured auxiliary diagnosis and treatment fields, an auxiliary examination node set is generated, and auxiliary examination attribute fields are added. The auxiliary examination attribute fields include examination type, examination time, and core indicators. The set of symptom nodes, the set of psychological characteristic nodes, the set of disease nodes, the set of drug nodes, and the set of auxiliary examination nodes constitute a node set; The symptom node attribute field, the psychological characteristic node attribute field, the diagnosis and treatment attribute field, and the auxiliary examination attribute field constitute a set of node attribute fields; Based on the standard medical terminology set and the standardized text of diagnosis and treatment pathways, the semantic relationships between nodes in the node set are identified, and a set of semantic relationship edges is generated. The set of semantic relationship edges includes symptom-disease edges, psychological characteristics-disease edges, drug-disease edges, and auxiliary examination-disease edges. Each semantic relation edge is injected with an edge attribute field, which includes edge type, source rule, co-occurrence frequency and confidence score, forming a set of edge attribute fields; By fusing and connecting the node set, semantic relation edge set, node attribute field set, and edge attribute field set, a psychiatric pre-diagnosis knowledge graph is generated.

[0027] In this embodiment, step three specifically includes: Obtain standardized chief complaint text from the structured pre-diagnosis dataset, wherein the standardized chief complaint text includes several chief complaint terms; A standard medical terminology set for psychiatry is constructed based on a standard medical terminology set, which includes several ontological terms. Each chief complaint term in the standardized chief complaint text is semantically matched with an ontology term in the standard medical terminology set for psychiatry using cosine similarity, and the ontology term with the highest cosine similarity is selected for semantic alignment with the chief complaint term. Use the category subscripts of semantically aligned ontology terms as the medical terminology category labels for the main complaint; Each semantically aligned ontology term is mapped to an embedding vector space through a predefined embedding matrix to obtain the ontology semantic vector of each subject term; A positional encoding vector is constructed for each main complaint using sine and cosine functions; The medical term category label of each chief complaint is mapped to a term category label vector through a trainable embedding matrix; The ontology semantic vector, position encoding vector and term category label vector of each main complaint term are concatenated and fused to generate an ontology semantic fusion vector; All ontology semantic fusion vectors are arranged into an ontology semantic embedding sequence according to the order of the main complaint; Based on the standard medical terminology set for psychiatry, ontology terms are mapped to medical term ontology nodes, and term ontology relation edges are constructed according to the co-occurrence relationship, superior-inferiority relationship, synonym relationship and combination relationship between ontology terms to form a medical ontology graph; Each chief complaint word in the standardized chief complaint text is mapped to a medical term ontology node in the medical ontology graph. If there is a term ontology relationship edge between the mapped medical term ontology nodes, the cosine similarity between the corresponding chief complaint words is used as the attention bias weight. Otherwise, the attention bias weight is set to 0, and an attention bias matrix is ​​generated based on the attention bias weight. The ontology semantic embedding sequence is mapped to a query matrix using three sets of trainable weight matrices. Key matrix AND-value matrix ; Perform matrix multiplication and scaling / normalization on the query matrix and key matrix, and then calculate the attention weight matrix by combining it with the attention bias matrix. : ; in, This represents the column dimension of the key matrix. This represents the attention bias matrix. This is the normalization function; The attention weight matrix and the value matrix are multiplied together to generate the ontology attention matrix. The ontology attention matrix is ​​then subjected to average pooling in the sequence dimension to generate the subject matter semantic vector, which represents the overall semantic features of the standardized subject matter text.

[0028] In this embodiment, step four specifically includes: The Node2Vec graph embedding algorithm is used to model the pre-diagnosis knowledge graph of psychiatry, and the node embedding vector of each node in the node set is obtained to form a node embedding vector set. The semantic similarity score is calculated between the main complaint semantic vector and each node embedding vector in the node embedding vector set. The semantic similarity score is calculated by calculating the Euclidean distance between the main complaint semantic vector and the node embedding vector, and then taking the reciprocal of the Euclidean distance after adding 1. A semantic similarity threshold is set, and nodes in the psychiatric pre-diagnosis knowledge graph whose semantic similarity scores exceed the semantic similarity threshold are selected as the initial node set for inference.

[0029] In this embodiment, step five specifically includes: Define a node sampling probability function, which calculates the sampling probability based on the semantic similarity score between the claim semantic vector and the nodes in the initial inference node set: ; in, Represents the semantic vector of the main complaint. Represents the nodes in the initial node set for inference. Represents a node In the adjacent nodes of the knowledge graph for pre-diagnosis psychiatry, Represents a node The set of adjacent nodes, Representing the semantic vector of the main complaint and nodes The semantic similarity score between the embedded vectors; Based on the sampling probability, from the nodes in the initial node set of inference... Starting from this point, multiple rounds of random walks are performed in the pre-diagnosis knowledge graph of psychiatry according to the set path length to generate a set of inference paths. Each inference path in the set of inference paths is an ordered combination sequence of entity nodes and edge relationships. Based on the inference path set, the entity nodes and edge relationships in each inference path are transformed into a sequence of path triples, and the sequence of path triples is constructed into a set of inference path rules according to the preset Horn rule template. For each inference path rule in the inference path rule set, a structural confidence score is calculated. The structural confidence score is equal to the ratio of the number of inference triples that can be correctly predicted by applying the inference path rule and that exist in the pre-psychiatric knowledge graph to the total number of inference triples generated after applying the inference path rule. The structural confidence score is used to measure the prediction accuracy of the path rule on the pre-psychiatric knowledge graph. All reasoning path rules are applied to the pre-diagnosis knowledge graph of psychiatry to generate a set of reasoning triples, and the tail entity node of each reasoning triple is used as a candidate symptom node. Calculate the semantic similarity score between the semantic vector of the chief complaint and the node embedding vector of the candidate symptom nodes; The structural confidence score and the corresponding semantic similarity score are weighted and fused according to a preset weight to generate the semantic rule confidence score; Based on the semantic rule confidence, all reasoning path rules in the reasoning path rule set are sorted, and the top-ranked reasoning path rules are used to form the target path rule set. The candidate symptom nodes corresponding to these reasoning path rules are used to form the target symptom node set.

[0030] For example, a patient's chief complaint is "recently experiencing insomnia, low mood, and reluctance to communicate." An improved Bioformer model is used to generate a semantic vector for the chief complaint. This vector is then matched against initial inference nodes in the pre-diagnosis psychiatric knowledge graph that have high semantic similarity to the chief complaint's semantic vector: "low mood" and "sleep disorder." With a path length of 3, multiple rounds of random walks are performed starting from these initial inference nodes to generate several inference paths. For example, inference path 1: "low mood → representation → depressive mood → representation in → depressive disorder," with the corresponding path triple sequence: (low mood, representation, depressive mood) (depressive mood, representation in, depressive disorder). This path triple sequence is matched against a pre-defined Horn rule template to obtain the inference path rule: (low mood, representation, depressive mood) ∧ (depressive mood, representation in, depressive disorder) ⇒ (low mood, significant association, depressive disorder). This rule is then applied to the pre-diagnosis psychiatric knowledge graph to obtain the inference triple (low mood, significant association, depressive disorder). The structural confidence score is calculated as follows: path rule 1 yields 10 inference triples in the knowledge graph, 7 of which actually exist in the pre-diagnosis knowledge graph of psychiatry, resulting in a structural confidence score of 0.7. Simultaneously, the semantic similarity score between the chief complaint semantic vector and "depressive disorder" is calculated to be 0.82. With a fusion weight of 0.6, the semantic rule confidence score is 0.748. All inference path rules are ranked according to their fusion confidence scores, and the top-ranked path rules are selected to form the target path rule set. The corresponding tail entity nodes, such as "depressive disorder," "anxiety disorder," and "social withdrawal," constitute the target symptom node set.

[0031] In this embodiment, step six specifically includes: A triage rule base is established, wherein each triage rule in the triage rule base includes a symptom combination pattern, a path structure pattern, and a triage suggestion; Based on the target path rule set, structural matching is performed on the path structure patterns in the triage rule base to filter candidate triage rules that are consistent with the target path rule set. The target symptom node set is matched with the symptom combination patterns in the candidate triage rules to identify the symptom node coverage relationship and filter the triage rules that meet the symptom combination patterns. The triage suggestions corresponding to the triage rules that satisfy the path structure pattern and symptom combination pattern are summarized to form a set of recommended triage suggestions. The set of recommended triage suggestions includes triage suggestions for psychiatric outpatient clinics, suggestions for priority of visits, and suggestions for referral pathways.

[0032] In this embodiment, the triage result set includes triage suggestion items in the recommended triage suggestion set, target symptom nodes and target path rules corresponding to the triage suggestion items, suggestion reasons, optional referral suggestions and consultation priority identifiers, and confirmation or modification options executed by the doctor.

[0033] In this embodiment, the post-diagnosis feedback information includes the doctor's confirmation of the results, modification suggestions, final diagnosis label, and actual treatment path.

[0034] Example 1: To verify the feasibility of this invention in practice, it was applied to the intelligent triage system of a top-tier psychiatric center. This hospital receives over 200,000 patients annually and faces challenges such as heavy outpatient workload, unclear patient pathways for first-time patients, and scattered and unstructured chief complaints. This often results in mis-registration, patients with severe conditions being referred to general outpatient clinics, and patients with mild symptoms crowding out specialized resources. Particularly in diagnostic categories with high comorbidity rates, such as anxiety disorders, depressive disorders, and bipolar disorder, the overlapping symptoms make it difficult for patients to accurately describe their condition. Traditional triage methods relying on manual inquiry and experience-based judgment are inaccurate and inefficient, posing a significant risk of misclassification.

[0035] During implementation, the intelligent triage system first collects the patient's original chief complaint text, structured psychological scale answers, brief medical history, medication records for the past three months, and summaries of recent auxiliary examinations submitted before the consultation. This data is then transformed into a structured pre-diagnosis dataset through a standardized processing flow, and a psychiatric pre-diagnosis knowledge graph is constructed using standard terminology mapping and syntactic analysis. This psychiatric pre-diagnosis knowledge graph contains 3145 nodes and 9126 edge relationships, including 1231 symptom nodes, 502 disease nodes, 391 medication nodes, 703 psychological feature nodes, and 318 auxiliary examination nodes. Edge types include "symptom-indication-disease," "psychological feature-association-symptom," "medication-treatment-disease," and "examination-support-diagnosis," and auxiliary semantics such as symptom duration and medication dosage are supplemented through attribute injection.

[0036] During use, when a patient submits the following chief complaint: "I often can't sleep at night, and I have no energy during the day. I feel like I don't want to do anything or see anyone lately," the intelligent triage system first performs ontology semantic modeling using an improved Bioformer model, generating a 128-dimensional chief complaint semantic vector. It then calculates the Euclidean distance similarity between this vector and the node embedding vectors in the psychiatric pre-diagnosis knowledge graph, selecting initial nodes with high semantic similarity to the chief complaint, such as "insomnia," "loss of interest," and "social avoidance," to form the initial inference node set. Subsequently, the intelligent triage system calls the improved AnyBURL algorithm to construct inference path rules based on path confidence and semantic similarity. For example, the path from "insomnia" to "depressive disorder" includes the inference path of "loss of interest → sleep disorder → low mood → depressive disorder."

[0037] Based on the target symptom node set and path rule set, the intelligent triage system queries the preset triage rule library and finds multiple rules that match the current inference result. One of the rules is: if the chief complaint covers "insomnia", "loss of interest", and "social avoidance" and the path pattern is "symptoms → emotional characteristics → disease", then it is recommended to recommend "depression specialist clinic" and set the priority to 2. The output set of recommended triage suggestions includes: "It is recommended to register at the depression disorder specialist clinic", "It is recommended to conduct preliminary screening for suicide risk", "Referred path: if accompanied by manic symptoms, please refer to the bipolar disorder clinic", "Priority level: P2".

[0038] A comparative experiment was conducted using data from 1200 initial-visit patients. Of these, 600 patients underwent triage assistance using the method of this invention, while the remaining 600 patients were triaged using traditional manual methods. Evaluation indicators included: initial registration accuracy, initial referral rate, consistency of doctor's confirmed recommendations, average pre-consultation waiting time, doctor satisfaction score, patient satisfaction score, and misclassification correction rate. The experimental results are shown in Table 1.

[0039] Table 1. Performance Comparison of the Method of the Present Invention and Traditional Manual Guidance Methods

[0040] As shown in Table 1, the method of this invention outperforms the traditional manual triage method in all comparative indicators. Regarding the accuracy rate of initial registration, the method of this invention reaches 92.8%, an improvement of 14.4 percentage points compared to the traditional manual triage method, significantly improving the accuracy of initial registration and reducing mis-registration and missed registrations. In terms of the initial referral rate, the method of this invention is only 5.1%, significantly lower than the 14.6% of the traditional manual triage method, indicating that the method of this invention can provide more accurate triage suggestions at the initial recommendation stage, effectively reducing resource waste and process delays caused by subsequent referrals. Regarding the consistency of doctor recommendations, the method of this invention reaches 89.5%, nearly 18 percentage points higher than the traditional manual triage method, reflecting a high degree of alignment between the recommended triage suggestions and the clinical doctor's judgment, which helps to improve doctor trust and system collaboration efficiency.

[0041] Furthermore, the method of this invention also demonstrates a significant advantage in average pre-consultation waiting time, at only 5.8 minutes, nearly half that of traditional manual triage methods, further optimizing the consultation process and resource allocation. In terms of subjective evaluation, doctor satisfaction scores and patient satisfaction scores reached 9.1 and 8.8 respectively, significantly higher than the 7.2 and 6.9 scores of traditional manual triage methods, indicating that the method of this invention has gained widespread recognition in practical applications and can effectively improve the consultation experience and work convenience. Regarding the error registration correction rate, the method of this invention has a rate of only 1.2%, far lower than the 7.5% of traditional manual triage methods, further verifying its stability and accuracy in judging complex symptoms.

[0042] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A pre-admission triage knowledge reasoning method for psychiatry based on a knowledge graph, characterized in that, The method comprises the following steps: Step one: collecting pre-diagnosis original data and pre-processing to form a structured pre-diagnosis data set; Step two: constructing a pre-diagnosis knowledge graph of psychiatry based on the structured pre-diagnosis data set; Step three: obtaining a standardized chief complaint text and inputting it into an improved Bioformer model for semantic coding to generate a chief complaint semantic vector; Step four: performing semantic matching of the chief complaint semantic vector with the pre-diagnosis knowledge graph of psychiatry to screen a symptom node set meeting the threshold condition to obtain an initial node set for reasoning; Step five: based on the initial node set for reasoning, an improved AnyBURL algorithm is used to perform rule path reasoning on the pre-diagnosis knowledge graph of psychiatry to output a target symptom node set and a target path rule set; Step six: constructing a recommended triage suggestion set based on the target symptom node set and the target path rule set; Step seven: pushing the recommended triage suggestion set to a doctor terminal interface and generating a triage result set according to the pre-diagnosis original data of the patient; Step eight: collecting post-diagnosis feedback information and performing incremental updating on the pre-diagnosis knowledge graph of psychiatry and the improved Bioformer model.

2. The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, The step one specifically comprises: The pre-diagnosis original data comprises a patient complaint text, psychological scale answer information, a past medical history text, a past medication record and auxiliary diagnosis and treatment data; The patient complaint text is subjected to format standardization and symbol cleaning to generate a standardized complaint text, and the standardized complaint text is subjected to syntax analysis and named entity recognition to extract a symptom keyword set and a symptom duration field; The psychological scale answer information is subjected to field analysis and score extraction to generate a psychological scale score field set; The past medical history text and the past medication record are subjected to medical terminology standard mapping and entity standardization processing to generate a standardized disease terminology field and a standardized drug name field; The auxiliary diagnosis and treatment data are subjected to field normalization and timestamp alignment processing to generate a structured auxiliary diagnosis and treatment field; The standardized complaint text, the symptom keyword set, the symptom duration field, the psychological scale score field set, the standardized disease terminology field, the standardized drug name field and the structured auxiliary diagnosis and treatment field are combined according to a predetermined format to form a structured pre-diagnosis data set. 3.The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, The step two specifically comprises: A standard medical terminology set, a disease classification system, a symptom description library, a drug information set, a psychological scale index and a diagnosis and treatment path specification text in the field of psychiatry are obtained through a medical institution knowledge engineering interface; Based on the symptom description library, the symptom keyword set and the symptom duration field are subjected to terminology standardization mapping and semantic expansion to generate a symptom node set, and a symptom node attribute field is added, the symptom node attribute field comprising a symptom classification label, a duration, a source identifier and a confidence score; Based on the psychological scale index, the psychological scale score field set is subjected to standard index matching to generate a psychological feature node set, and a psychological feature node attribute field is added, the psychological feature node attribute field comprising a scale type, a score level and an evaluation dimension; Based on the disease classification system and the drug information set, the standardized disease term field and the standardized drug name field are mapped and semantically aligned to generate a disease node set and a drug node set, and a diagnosis and treatment attribute field is added, which includes diagnosis time, disease stage, drug dose and usage information; According to the structured auxiliary diagnosis and treatment field, an auxiliary examination node set is generated, and an auxiliary examination attribute field is added, which includes examination type, examination time and core indicators; The symptom node set, the psychological feature node set, the disease node set, the drug node set and the auxiliary examination node set form a node set; The symptom node attribute field, the psychological feature node attribute field, the diagnosis and treatment attribute field and the auxiliary examination attribute field form a node attribute field set; Based on the standard medical term set and the diagnosis and treatment path specification text, the semantic relationship between each node in the node set is identified, and a semantic relationship edge set is generated, which includes symptom-disease edges, psychological feature-disease edges, drug-disease edges and auxiliary examination-disease edges; Each semantic relationship edge is injected with an edge attribute field, which includes edge type, source rule, co-occurrence frequency and confidence score, forming an edge attribute field set; The node set, the semantic relationship edge set, the node attribute field set and the edge attribute field set are fused and connected to generate a pre-diagnosis knowledge graph for psychiatry. 4.The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, The step three specifically includes: Obtaining the standardized chief complaint text in the structured pre-diagnosis data set, the standardized chief complaint text including a plurality of chief complaint words; Building a psychiatric standard medical term set based on the standard medical term set, the psychiatric standard medical term set including a plurality of ontology terms; Each chief complaint word in the standardized chief complaint text is semantically matched with the ontology terms in the psychiatric standard medical term set through cosine similarity, and the ontology term with the largest cosine similarity is selected for semantic alignment with the chief complaint word; The class index of the semantically aligned ontology term is used as the medical term class label of the chief complaint word; Each semantically aligned ontology term is mapped to an embedding vector space through a pre-set embedding matrix to obtain an ontology semantic vector for each chief complaint word; A position encoding vector is constructed for each chief complaint word through a positive cosine function; The medical term class label of each chief complaint word is mapped to a term class label vector through a trainable embedding matrix; The ontology semantic vector, the position encoding vector and the term class label vector of each chief complaint word are fused to generate an ontology semantic fusion vector; All ontology semantic fusion vectors are grouped into an ontology semantic embedding sequence according to the order of the chief complaint words; Based on the psychiatric standard medical term set, the ontology terms are mapped to medical term ontology nodes, and term ontology relationship edges are constructed according to the co-occurrence relationship, the upper-lower relationship, the synonym relationship and the combination relationship between the ontology terms to form a medical ontology. Map each chief complaint word in the standardized chief complaint text to a medical terminology ontology node in the medical ontology graph. If there is a term ontology relationship between the mapped medical terminology ontology nodes, use the cosine similarity between the corresponding chief complaint words as the attention bias weight. Otherwise, set the attention bias weight to 0. Generate an attention bias matrix based on the attention bias weight. Embed the ontology semantic sequence into a query matrix, a key matrix, and a value matrix through three groups of trainable weight matrices. Perform matrix multiplication on the query matrix and the key matrix, scale and normalize the result, and combine it with the attention bias matrix to calculate an attention weight matrix. Multiply the attention weight matrix and the value matrix to generate an ontology attention matrix. Perform average pooling on the ontology attention matrix in the sequence dimension to generate a chief complaint semantic vector. 5.The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, Step four specifically includes: Model the pre-admission knowledge graph of the psychiatric department using the Node2Vec graph embedding algorithm to obtain node embedding vectors for each node in the node set, forming a node embedding vector set. Calculate the semantic similarity score between the chief complaint semantic vector and each node embedding vector in the node embedding vector set. The semantic similarity score is calculated by computing the Euclidean distance between the chief complaint semantic vector and the node embedding vector, and then taking the reciprocal of the Euclidean distance plus 1. Set a semantic similarity threshold and select nodes in the pre-admission knowledge graph of the psychiatric department with a semantic similarity score exceeding the semantic similarity threshold as the initial set of reasoning nodes. 6.The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, Step five specifically includes: Define a node sampling probability function that calculates the sampling probability based on the semantic similarity score between the chief complaint semantic vector and the nodes in the initial set of reasoning nodes. According to the sampling probability, nodes in the set of inference initial nodes are sampled Starting from the psychiatric pre-examination knowledge graph, a plurality of rounds of random walk operations are performed according to the set path length to generate a set of inference paths; Based on the set of reasoning paths, convert the entity nodes and edge relationships in each reasoning path into a path triple sequence, and construct the reasoning path rule set from the path triple sequence according to the pre-set Horn rule template. For each reasoning path rule in the reasoning path rule set, calculate the structural confidence, which is equal to the ratio of the number of reasoning triples that can be correctly predicted by applying the reasoning path rule and exist in the pre-admission knowledge graph of the psychiatric department to the total number of reasoning triples generated after applying the reasoning path rule. The structural confidence measures the prediction accuracy of the path rule in the pre-admission knowledge graph of the psychiatric department. Apply all reasoning path rules to the pre-admission knowledge graph of the psychiatric department to generate a set of reasoning triples, and use the tail entity node of each reasoning triple as a candidate symptom node. Calculate the semantic similarity score between the chief complaint semantic vector and the node embedding vector of the candidate symptom node. Weight and fuse the structural confidence and the corresponding semantic similarity score according to the pre-set weight to generate a semantic rule confidence. Based on the semantic rule confidence, sort all reasoning path rules in the reasoning path rule set, and construct a target path rule set from the top-ranking reasoning path rules. Construct a target symptom node set from the candidate symptom nodes corresponding to the reasoning path rules in the target path rule set.

7. The knowledge graph-based psychiatric pre-admission triage knowledge reasoning method according to claim 1, characterized in that, Step six specifically includes: A triage rule library is set, each triage rule in the triage rule library including a symptom combination mode, a path structure mode and a triage suggestion; Based on the target path rule set, the path structure mode in the triage rule library is matched in structure, and candidate triage rules consistent with the target path rule set are screened; The target symptom node set and the symptom combination mode in the candidate triage rule are matched in node, the symptom node coverage relationship is identified, and the triage rule meeting the symptom combination mode is screened; The triage suggestions corresponding to the triage rules meeting the path structure mode and the symptom combination mode are summarized to form a recommended triage suggestion set, the recommended triage suggestion set including a psychiatric outpatient triage suggestion, a treatment priority suggestion and a transfer path suggestion. 8.The knowledge graph based psychiatric pre-hospital triage knowledge reasoning method according to claim 1, characterized in that, The triage result set includes a triage suggestion item in the recommended triage suggestion set, a target symptom node and a target path rule corresponding to the triage suggestion item, a suggestion reason, an optional transfer suggestion, a treatment priority identifier and a confirmation or modification option executed by a doctor. 9.The knowledge graph based psychiatric pre-hospital triage knowledge reasoning method according to claim 1, characterized in that, The post-diagnosis feedback information includes a doctor's confirmation result, a modification opinion, a final diagnosis label and an actual treatment path.

Citation Information

Patent Citations

  • Sequence generation type knowledge reasoning method and system based on Decision Transform

    CN115526322A

  • Diagnosis division and guidance method and system for large medical model, electronic equipment and storage medium

    CN119580970A

  • Reinforced learning sparse graph reasoning method and system based on fusion reward

    CN119918648A

  • Knowledge graph construction method for structural information aggregation

    CN120598017A

  • Traditional Chinese medicine high-content screening resource library management method and platform based on multi-modal representation learning

    CN120748548A

Cited By

  • Intelligent triage method and system based on pre-inquiry text clustering and mode recognition

    CN121747878A