Virtual patient-based simulated consultation interaction method and apparatus

By acquiring atomized information of virtual patients and external medical knowledge bases, and combining them with a large language model to construct prompt words, the high cost and low fidelity of virtual patient simulation consultation methods are solved, achieving low-cost and high-fidelity simulation consultation results.

CN122245801APending Publication Date: 2026-06-19WUXI BAUHINIA ZHIKANG TECHNOLOGY CO LTD +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
WUXI BAUHINIA ZHIKANG TECHNOLOGY CO LTD
Filing Date
2026-03-21
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

Existing virtual patient simulation consultation methods based on large language models are costly, outdated, and lack traceability, failing to accurately reproduce patients' cognitive and communication logic, thus affecting the realism of the simulation consultation and the training effect.

Method used

By acquiring atomized information of virtual patients, including personality profiles, cognitive boundaries, and hidden material mapping lists, and combining it with external medical knowledge bases and large language models, prompt words are constructed and response text is output, avoiding model fine-tuning, reducing computing costs, and improving the fidelity of simulated consultations.

🎯Benefits of technology

It achieves reduced computing costs, high-fidelity reproduction of patient cognition, and elimination of the knowledge illusion of medical examination reports without changing the parameters of the large language model, thus improving the realism and security of simulated consultation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122245801A_ABST
    Figure CN122245801A_ABST
Patent Text Reader

Abstract

This invention provides a simulated consultation interaction method and apparatus based on a virtual patient. The method includes: acquiring the current consultation input for a target virtual patient; determining the associated atomic information and the current session state; the atomic information includes a personality profile, cognitive boundaries, and a hidden material mapping list; retrieving matching medical reference information from an external medical knowledge base based on the current consultation input and the current session state; fusing the atomic information, the current session state, the medical reference information, and the current consultation input to construct prompt words; inputting the prompt words into a large language model; and outputting the response text of the target virtual patient under the constraints of the personality profile and cognitive boundaries; matching the current consultation input with the hidden material mapping list to determine the matching medical accessory identifier; and outputting the response text and / or the medical accessory identifier as the response for the current round. This invention eliminates the need for model fine-tuning, reduces costs, and can faithfully reproduce patient cognition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to a method and apparatus for simulated consultation interaction based on virtual patients. Background Technology

[0002] As artificial intelligence is increasingly applied in the medical field, virtual patients based on large language models are playing a vital role in medical teaching, clinical training, and decision support. Currently, most mainstream solutions for constructing virtual patients rely on fine-tuning the model's parameters using a large amount of historical medical record data.

[0003] However, existing technologies have the following significant drawbacks: First, parameter fine-tuning is computationally expensive and updates are slow, making it impossible to perform low-cost, real-time hot updates for new medical guidelines or rare cases; second, the fine-tuned model is a black box, and its output lacks traceability, which can easily lead to knowledge illusions in medical scenarios; finally, the original medical records are mostly objective professional texts from the doctor's perspective, and if used directly, they cannot accurately reproduce the knowledge gaps and communication logic of real patients, seriously affecting the realism of simulated consultations and the effectiveness of training. Summary of the Invention

[0004] This invention provides a virtual patient-based simulated consultation interaction method and device to address the shortcomings of existing simulated consultation interaction methods that rely on fine-tuning of large model parameters, which suffer from high cost and low fidelity.

[0005] This invention provides a simulated consultation interaction method based on a virtual patient, comprising: Obtain the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state, the atomized information includes a personality profile, cognitive boundaries for constraining information disclosure, and a hidden material mapping list; Based on the current consultation input and the current session state, retrieve matching medical reference information from an external medical knowledge base; By integrating the atomic information, the current session state, the medical reference information, and the current consultation input, the prompt words for the current round are constructed. The prompt words are then input into the large language model to obtain the response text of the target virtual patient, which is output by the large language model under the constraints of the personality profile and the cognitive boundary. Match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input; Output the response body and / or the medical accessory identifier as the response for the current round.

[0006] In some embodiments, the external medical knowledge base includes a medical experience base and a historical clinical case database; retrieving matching medical reference information from the external medical knowledge base based on the current consultation input and the current session state includes: Construct the retrieval query text based on the current consultation input and the current session state; Based on the search query text, a set of candidate experience entries is retrieved from the medical experience database, and a set of candidate treatment sample entries is retrieved from the historical treatment sample database; An alternating selection strategy is adopted to extract entries from the candidate experience entry set and the candidate diagnosis and treatment example entry set in turn until the number of extracted entries reaches a preset threshold, thereby obtaining the medical reference information.

[0007] In some embodiments, the process of fusing the atomic information, the current session state, the medical reference information, and the current consultation input to construct the prompt words for the current round includes: The medical reference information is formatted into multiple reference case blocks; The atomization information is filled into the placeholders of the preset skeleton template; The current session state, the current consultation input, multiple reference case blocks, and preset fixed instructions are appended to the skeleton template to obtain the prompt words.

[0008] In some embodiments, the current session state includes: a multi-turn dialogue history list and a consultation progress summary; the method further includes: After outputting the interaction response of the current round, the large language model is called to update the consultation progress summary, using the current dialogue text as input; the current dialogue text includes: the multi-round dialogue history list, the current consultation input, and the response text; the consultation progress summary includes: the progress of the consultation and the medical information obtained; Write the updated consultation progress summary into the current session state to obtain the updated current session state.

[0009] In some embodiments, the current session state further includes an unlocked attachment list; the hidden material mapping list contains a correspondence between examination names and candidate attachment identifiers; the step of matching the current consultation input with the hidden material mapping list to determine the medical attachment identifier that matches the current consultation input includes: Perform semantic matching between the current consultation input and the examination names in the hidden material mapping list; If a match is found, the corresponding candidate attachment identifier is retrieved from the hidden material mapping list; If the candidate attachment identifier does not exist in the unlocked attachment list, then the candidate attachment identifier is identified as the medical attachment identifier, and the medical attachment identifier is added to the unlocked attachment list.

[0010] In some embodiments, determining the atomized information associated with the target virtual patient includes: Based on the unique identifier of the target virtual patient, a search is performed in a pre-built digital patient asset database to obtain atomic information associated with the target virtual patient; the atomic information is generated based on the target virtual patient's standard clinical medical record.

[0011] In some embodiments, prior to determining the atomized information associated with the target virtual patient, the step of constructing the digital patient asset library is further included: Obtain the standard clinical medical records for each virtual patient; The professional descriptions in the standard clinical medical records are rewritten into the colloquial descriptions of the corresponding virtual patients to form the core clinical data of each virtual patient. Analyze the standard clinical medical records to construct a personality profile, information disclosure guidelines, and cognitive boundaries for each virtual patient; The completed examination items are inferred from the diagnostic results and treatment plans of the standard clinical medical records. A correspondence between examination names and attachment identifiers is established, and a hidden material mapping list is generated for each virtual patient. Based on the core clinical data, personality profile, information disclosure guidelines, cognitive boundaries, and hidden material mapping list of each virtual patient, the atomic information of each virtual patient is determined. The digital patient asset library is constructed based on the unique identifier of each virtual patient and the atomic information of each virtual patient.

[0012] In some embodiments, the method further includes: To acquire new clinical experience data and / or new case data; Extract the empirical feature vector from the new clinical diagnosis and treatment experience data, and / or extract the sample feature vector from the new diagnosis and treatment case data; Write the empirical feature vector and / or the sample feature vector into the external medical knowledge base, and update the vector index of the external medical knowledge base.

[0013] The present invention also provides a simulated consultation interaction device based on a virtual patient, comprising: The acquisition unit is used to acquire the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state, wherein the atomized information includes a personality profile, a cognitive boundary for constraining information disclosure and a hidden material mapping list; The retrieval unit is used to retrieve matching medical reference information from an external medical knowledge base based on the current consultation input and the current session state. The generation unit is used to integrate the atomic information, the current session state, the medical reference information, and the current consultation input to construct the prompt words for the current round, input the prompt words into the large language model, and obtain the response text of the target virtual patient output by the large language model under the constraints of the personality profile and the cognitive boundary; A matching unit is used to match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input; The output unit is used to output the response text and / or the medical accessory identifier as a response for the current round.

[0014] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the virtual patient-based simulated consultation interaction method as described above.

[0015] The present invention provides a virtual patient-based simulated consultation interaction method and apparatus. By acquiring the current consultation input for the target virtual patient, it determines the associated atomic information and the current session state. The atomic information includes a personality profile, cognitive boundaries, and a hidden material mapping list. Based on the current consultation input and the current session state, it retrieves matching medical reference information from an external medical knowledge base. When new clinical guidelines or rare diseases need to be introduced, only the external medical knowledge base needs to be updated, without the need for model fine-tuning, thus reducing computational costs. By fusing atomic information, the current session state, medical reference information, and the current consultation input, it constructs prompt words. These prompt words are input into a large language model, and under the constraints of the personality profile and cognitive boundaries, it outputs the response text of the target virtual patient, achieving high-fidelity reproduction of patient cognition. The current consultation input is matched with the hidden material mapping list to determine the matching medical attachment identifier. The response text and / or the medical attachment identifier are output, decoupling the text and attachment generation logic, fundamentally eliminating the knowledge illusion of medical examination reports. Attached Figure Description

[0016] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0017] Figure 1 This is one of the flowcharts of the simulated consultation interaction method based on virtual patients provided in the embodiments of the present invention.

[0018] Figure 2 This is a schematic diagram of the process for constructing a digital patient asset database provided in an embodiment of the present invention.

[0019] Figure 3 This is the second flowchart of the simulated consultation interaction method based on virtual patients provided in the embodiments of the present invention.

[0020] Figure 4 This is a schematic diagram of the structure of the virtual patient-based simulated consultation interaction device provided in an embodiment of the present invention.

[0021] Figure 5 This is a schematic diagram of the structure of the electronic device provided in an embodiment of the present invention. Detailed Implementation

[0022] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0023] For ease of understanding, the entity executing the simulated consultation interaction method based on a virtual patient in this embodiment of the invention can be referred to as an intelligent agent. This intelligent agent is a comprehensive computer program system that encapsulates the data, models, and processing logic required to execute the simulated consultation interaction. Functionally, this intelligent agent is the digital avatar and behavior-driving engine of the target virtual patient during the interaction process.

[0024] Figure 1 This is one of the flowcharts illustrating a virtual patient-based simulated consultation interaction method provided in an embodiment of the present invention. Figure 1 As shown, a simulated consultation interaction method based on a virtual patient is provided, including the following steps: steps 110 to 150. This method's steps are merely one possible implementation of the present invention.

[0025] Step 110: Obtain the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state. The atomized information includes a personality profile, cognitive boundaries used to constrain information disclosure, and a hidden material mapping list.

[0026] In this context, the target virtual patient is a predefined and created digital entity used to play a specific patient role in simulated consultation interactions. Each target virtual patient has a unique identity and is associated with a specific set of medical conditions, backgrounds, and behavioral patterns.

[0027] The current consultation input refers to the real-time text information entered into the system by the operator, usually a medical student or clinician playing the role of a doctor, through the user interface during the interaction process. For example, a natural language question entered by the operator in the dialog box, such as "Where do you feel uncomfortable today?"

[0028] Optionally, the atomized information is generated based on the target virtual patient's standard clinical medical record and includes at least: core clinical data, personality profile, information disclosure guidelines, cognitive boundaries, and a list of hidden materials. The current session state includes at least: a list of multi-turn dialogue history, a summary of consultation progress, and a list of unlocked attachments.

[0029] A persona is a series of descriptive labels or text used to define the personality, background, and emotional state of a target virtual patient. A persona includes, but is not limited to: name, age, gender, personality, speaking style, region, education level, economic status, a brief story summary, a detailed description of the medical history, and the patient's medical needs. This information is used to ensure that the virtual patient's language style and behavioral patterns are consistent with their persona.

[0030] The cognitive boundary explicitly defines the depth and breadth of the target virtual patient's understanding of their own condition, as well as how they express known information. For example, a cognitive boundary might stipulate that a patient knows they have "chest tightness and shortness of breath," but is unaware of the professional medical diagnostic term "myocardial infarction"; or it might stipulate that the patient, when describing pain, would use a colloquial metaphor like "like a large rock pressing down on me," rather than a professional description of pain intensity. This cognitive boundary is crucial for achieving high-fidelity simulation. Through the constraints of the cognitive boundary, the large language model, when generating response text, will not disclose the patient's own medical knowledge beyond its scope.

[0031] The hidden material mapping list is a key-value pair list used to manage the triggering logic of non-text-based medical accessories. This list establishes a mapping relationship between examination names and medical accessory identifiers.

[0032] Optionally, based on the identity information used to uniquely identify the target virtual patient attached to the front-end application or API request, the corresponding data packet is retrieved and loaded in the back-end database or data storage system to determine the atomic information associated with the target virtual patient and the current session state.

[0033] Step 120: Based on the current consultation input and the current session status, retrieve matching medical reference information from an external medical knowledge base.

[0034] The external medical knowledge base is a dynamically updated structured or unstructured medical knowledge repository independent of the inherent parameters of the large language model. This knowledge base can store various types of medical information, such as a large number of clinical practice guidelines, medical textbook chapters, authoritative medical literature, or compiled past real-world clinical cases.

[0035] Optionally, a query request can be constructed based on the current consultation input, and this query request can be used to perform information retrieval operations in an external medical knowledge base. Examples include keyword matching, Boolean search, and vector search based on semantic similarity.

[0036] Step 130: Integrate atomic information, current session state, medical reference information, and current consultation input to construct prompt words for the current round. Input the prompt words into the large language model to obtain the response text of the target virtual patient output by the large language model under the constraints of personality profile and cognitive boundaries.

[0037] The prompt words are specially constructed for this interaction and are instructional texts used to guide the large language model in generating specific responses.

[0038] Optionally, the atomic information, current session state, medical reference information, and current consultation input can be concatenated in a specific format and order to obtain prompt words.

[0039] For example, prompts may include the following: first, role setting instructions, which clearly inform the large language model of the personality profile it needs to play and the cognitive boundaries it must adhere to; then, relevant medical reference information, which serves as the knowledge basis for its answer; next, the current conversation state, i.e., the dialogue history, to ensure the continuity of the response; and finally, the user's current consultation input, i.e., the question that needs to be answered this time.

[0040] Among them, large language models refer to pre-trained generative artificial intelligence models with powerful natural language understanding and generation capabilities. The personality profile and cognitive boundary parts in the prompt words can serve as strong instructions to guide the model's output style and content scope.

[0041] Step 140: Match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input.

[0042] This step, along with step 130, is a separate logical branch that can be executed in parallel or sequentially. Its purpose is to handle non-text attachment requests to avoid the illusion of a forged inspection report generated by a large language model.

[0043] Optionally, the semantic intent of the current consultation input is analyzed and matched against a hidden material mapping list. If a match is found, a medical accessory identifier corresponding to that intent is determined. The medical accessory identifier can be a unique string pointing to a specific medical accessory resource, such as a filename, database primary key, or an accessible Uniform Resource Locator (URL). If no match is found, this step does not output any identifier.

[0044] Step 150: Output the response body and / or medical accessory identifier as the response for the current round.

[0045] This step merges and presents the results of the first two independent branches. The output process involves the system packaging the response text generated in step 130 and the medical accessory identifiers that may be determined in step 140 into a structured response body, which is then returned to the front-end application or the caller. Upon receiving the response, the front-end application displays the response text in the dialog interface and, depending on the presence of the medical accessory identifier, decides whether to simultaneously display an image or link to the examination report for the user to view.

[0046] In this embodiment of the invention, without changing the underlying parameters of the large language model, precise control of virtual patient behavior is achieved through the injection of an external knowledge base and atomic information containing cognitive boundaries. Simultaneously, by decoupling text generation from attachment triggering logic, the hallucination problem of the model on key medical data is effectively avoided, greatly improving the fidelity, controllability, and security of simulated consultation interaction, while significantly reducing the system's maintenance and update costs.

[0047] In some embodiments, the external medical knowledge base includes a medical experience base and a historical case study database.

[0048] The medical experience base is a database storing structured medical principles and key knowledge points. The stored content leans towards guiding and regular medical knowledge, such as core symptoms of specific diseases, key points for differential diagnosis, the logical relationships between different symptoms, and the recommended consultation sequence and key points in clinical guidelines. Understandably, the medical experience base provides principled behavioral guidance for the large language model.

[0049] The historical clinical case database is a collection of processed, complete real-world clinical cases. Each case includes multiple rounds of doctor-patient dialogue, examination procedures, and final diagnoses. Unlike the medical experience database, the historical clinical case database provides contextualized, narrative references.

[0050] Step 120: Based on the current consultation input and the current session state, retrieve matching medical reference information from an external medical knowledge base, including: Step 121: Construct the search query text based on the current consultation input and the current session state.

[0051] Specifically, there are several ways to construct the search query text. The current consultation input can be used directly as the search query text. To provide richer contextual information and improve search accuracy, the current consultation input can be concatenated with some or all of the historical dialogue records in the current session state to form a longer search query text.

[0052] Step 122: Based on the search query text, query the candidate experience item set from the medical experience database and the candidate diagnosis and treatment example item set from the historical diagnosis and treatment example database.

[0053] In a preferred embodiment, each piece of data in the medical experience database and the historical treatment case database is pre-converted into a high-dimensional feature vector using a deep learning model, such as a text embedding model, and a vector index is constructed. The query process specifically involves: converting the query text into a query vector using the same text embedding model; calculating semantic similarity using this query vector in both the vector index of the medical experience database and the vector index of the historical treatment case database, for example, by calculating cosine similarity or Euclidean distance, to find the several entries most similar to the query vector.

[0054] Based on the above queries, candidate experience item sets and candidate treatment example item sets are obtained. Both item sets are lists sorted from high to low similarity scores, containing the most relevant experience knowledge and historical cases to the current consultation context. For example, the top 10 items with the highest similarity scores can be retrieved from each database to form two candidate sets.

[0055] Step 123: Using an alternating selection strategy, extract items from the candidate experience item set and the candidate diagnosis and treatment sample item set in turn until the number of extracted items reaches a preset threshold, thereby obtaining medical reference information.

[0056] Specifically, the staggered selection strategy means that the system does not simply take all or the top entries from a candidate set, but instead extracts entries alternately from the candidate experience entry set and the candidate treatment example entry set. For example, it first extracts the first entry with the highest similarity from the candidate experience entry set, then extracts the first entry with the highest similarity from the candidate treatment example entry set; then it extracts the second entry with the highest similarity from the candidate experience entry set, and then extracts the second entry with the highest similarity from the candidate treatment example entry set, and so on.

[0057] This iterative extraction process continues until the total number of extracted entries reaches a preset threshold. The preset threshold is an integer that can be flexibly configured based on system performance and the model context window length; for example, it can be set to 6 or 8. The extraction process stops when the total number of extracted entries reaches this threshold. Ultimately, these extracted entries together constitute the medical reference information required for this interaction.

[0058] The retrieval method provided in this embodiment, especially by constructing a dual knowledge base and adopting an interleaved selection strategy, can provide a balanced and complementary contextual reference for the large language model. It includes both the logically rigorous diagnostic and treatment principles from the medical experience base and the vivid and specific real-world contexts from the historical diagnostic and treatment example base, thereby ensuring that the subsequently generated response text is both in line with medical logic and rich in humanized interactive details.

[0059] In some embodiments, step 130 integrates atomic information, current session state, medical reference information, and current consultation input to construct prompts for the current round, including: Step 131: Format the medical reference information into multiple reference case blocks.

[0060] Specifically, the scattered medical reference information retrieved from external medical knowledge bases is processed into data blocks with a unified structure and clear boundaries, namely reference case blocks. Each reference case block corresponds to one or a set of related medical reference information. The purpose of formatting is to help the large language model clearly distinguish between background knowledge and dialogue content.

[0061] Optionally, specific start and end markers can be added to each piece of medical reference information to achieve formatting. For example, the beginning of each section can be marked as "Case Reference Beginning" and the end as "Case Reference Ending". This formatting ensures that large language models do not misinterpret reference information as historical dialogue or content requiring direct responses when processing long texts.

[0062] Step 132: Fill in the atomization information in the placeholders of the preset skeleton template.

[0063] The preset skeleton template is a string template containing a specific text structure and multiple placeholders. This template forms the basic framework for constructing the final prompts. Placeholders are reserved in the template for later filling in specific content. For example, a skeleton template might contain placeholders such as: a character setting area, a cognitive boundary area, etc.

[0064] Specifically, the corresponding content from the atomized information is inserted into the corresponding placeholders in the skeleton template. For example, the text content from the personality profile is filled into the placeholders in the role setting area, and the text content from the cognitive boundary used to constrain information disclosure is filled into the placeholders in the cognitive boundary area.

[0065] Step 133: Add the current session state, current consultation input, multiple reference case blocks, and preset fixed instructions to the skeleton template to obtain prompt words.

[0066] The pre-defined fixed instructions are a textual guide that fundamentally and globally defines the behavior of the large language model. These instructions do not change with the specific content of the consultation; their purpose is to set the task objectives and core behavioral guidelines for the large language model. For example, a pre-defined fixed instruction might be: "You are playing the role of a patient in a simulated consultation. You must strictly adhere to the personality profile and cognitive boundaries set for you. All your answers must conform to these settings, and you are prohibited from revealing any medical expertise beyond these cognitive boundaries."

[0067] Optionally, the current session state, current consultation input, multiple reference case blocks, and preset fixed instructions can be concatenated in a certain order after the skeleton template that has been filled with atomic information.

[0068] The prompt word construction method provided in this embodiment offers a highly modular and structured input for large language models. By explicitly separating roles, constraints, reference knowledge, dialogue history, and current task, large language models can more accurately understand their roles and behavioral boundaries. This ensures that while maintaining the medical relevance of the response content, role consistency is strictly maintained, effectively preventing knowledge leakage and role-playing failure, and further enhancing the realism and effectiveness of simulated consultations.

[0069] In some embodiments, the current session state includes: a multi-turn dialogue history list and a consultation progress summary; the above method further includes: After outputting the interaction response of the current round, the large language model is called to update the consultation progress summary, taking the current dialogue text as input. The current dialogue text includes: a list of multi-round dialogue history, the current consultation input, and the reply text. The consultation progress summary includes: the progress of the consultation and the medical information obtained. Write the updated consultation progress summary to the current session state to obtain the updated current session state.

[0070] Specifically, this embodiment of the invention provides a preferred implementation of the composition and maintenance of the current session state, aiming to solve the problems of information redundancy and interaction defocus in long dialogue scenarios.

[0071] The multi-turn dialogue history list contains all user input and system responses from the start of the conversation to the current turn. The consultation progress summary is a highly condensed and structured summary of information derived from the multi-turn dialogue history list. Compared to the original dialogue history, which contains a lot of colloquial and non-critical information, the consultation progress summary is more concise and focuses more on core medical facts. The consultation progress level can be a descriptive text or a predefined stage label, such as the initial inquiry stage, the symptom detail follow-up stage, or the past medical history inquiry stage, used to mark the current macro-level progress of the consultation.

[0072] Specifically, a large language model is invoked to update the consultation progress summary. This invocation can be a re-invocation of the same large language model used in step 130, or it can be an invocation of a smaller, independent large language model specifically optimized for text summarization tasks. A specific instruction is sent to this large language model, requiring it to output an updated consultation progress summary in a preset format, taking the current dialogue text as input. For example, the instruction could be: Please summarize the following doctor-patient dialogue, extract key medical information, and determine the current stage of the consultation.

[0073] After receiving the updated consultation progress summary returned by the large language model, it is written to the data area used to store the current session state, replacing the old consultation progress summary, thus completing the update of the current session state. In this way, at the start of the next round of interaction, when determining the current session state in step 110, the state information obtained will contain this latest and most accurate summary. This summary information will be used as part of the prompt words constructed in step 130, providing a reference for the large language model.

[0074] In this embodiment of the invention, by introducing and dynamically updating the consultation progress summary, the large language model can effectively maintain focus in long-term multi-turn dialogues, avoid repeatedly asking for information that has already been obtained, improve the intelligence and fluency of the interaction, and further enhance the realism and effectiveness of the simulated consultation.

[0075] In some embodiments, the current session state also includes a list of unlocked attachments; the hidden material mapping list contains a mapping between check names and candidate attachment identifiers.

[0076] The unlocked attachments list is a dynamically maintained data set bound to the current session's lifecycle. It records the identifiers of all medical attachments shown to the user during this simulated consultation. Its purpose is to provide a basis for deduplication in subsequent attachment output.

[0077] The examination name is a keyword or phrase used to match user intent, such as chest CT scan or electrocardiogram. The candidate attachment identifier is a unique identifier linked to the examination name, pointing to a specific attachment resource.

[0078] Step 140 matches the current consultation input with the hidden material mapping list to determine the medical accessory identifiers that match the current consultation input, including: Step 141: Perform semantic matching between the current consultation input and the examination names in the hidden material mapping list.

[0079] Specifically, semantic matching refers to performing deep intent understanding on the natural language text input during the current consultation to determine whether it contains a request for a specific examination report.

[0080] In one implementation, a keyword-based or regular expression-based matching method can be used, for example, to detect whether the input text contains a preset check name. In another preferred implementation, to improve the robustness and accuracy of the matching, a natural language processing model-based matching method can be used. For example, all check names in the current consultation input and the hidden material mapping list are converted into feature vectors using a text embedding model. Then, by calculating the cosine similarity between the input vector and each check name vector, the check name with the highest similarity exceeding a preset threshold is selected as the matching result.

[0081] Step 142: If a match is successful, retrieve the corresponding candidate attachment identifier from the hidden material mapping list.

[0082] Optionally, the corresponding candidate attachment identifier can be retrieved from the hidden material mapping list using the matched inspection name as the key.

[0083] Step 143: If the candidate attachment identifier does not exist in the unlocked attachment list, then the candidate attachment identifier is identified as the medical attachment identifier, and the medical attachment identifier is added to the unlocked attachment list.

[0084] Specifically, check whether the candidate attachment identifier obtained in step 142 exists in the list of unlocked attachments in the current session.

[0085] If the check result indicates that the attachment does not exist, it means that the attachment has not been displayed in this session. At this point, two consecutive actions are performed: First, the candidate attachment identifier is identified as the medical attachment identifier that will ultimately be output in this interaction; second, this identified medical attachment identifier is added to the unlocked attachment list, completing the status update of that list. This addition action is crucial for implementing the deduplication function, ensuring that in subsequent interactions, if the user requests the same attachment again, it can be correctly identified as unlocked.

[0086] If the check result indicates that the attachment has already been displayed, then no further medical attachment identifiers will be determined, meaning the attachment output for this round will be empty, thus effectively avoiding repeatedly pushing the same check report to the user.

[0087] The attachment determination method provided in this embodiment, based on accurate attachment triggering, further adds session-level deduplication logic. By maintaining and utilizing the unlocked attachment list, this method can avoid repeatedly responding to the same attachment request from the user in long conversations, making the behavior of virtual patients more intelligent and human-like, and significantly improving the smoothness of simulated consultation interaction and user experience.

[0088] In some embodiments, determining atomized information associated with a target virtual patient includes: Based on the unique identifier of the target virtual patient, a search is performed in a pre-built digital patient asset database to obtain atomized information associated with the target virtual patient; the atomized information is generated based on the target virtual patient's standard clinical medical record.

[0089] The unique identifier for the target virtual patient is a string or number used to uniquely distinguish different virtual patients in the system.

[0090] The pre-built digital patient asset repository is a centralized database or data repository that exists before the simulated consultation interaction begins. This repository stores atomic information of multiple different virtual patients, and each atomic piece of information is associated with a unique identifier. It can be understood that this digital patient asset repository is the total data collection of all virtual patient roles in this embodiment of the invention, providing the system with a role resource pool that can be invoked at any time.

[0091] Standard clinical medical records refer to original medical records that conform to medical standards and serve as the data source. These can be authentic, anonymized electronic health records, inpatient medical record summaries, outpatient visit records, or discharge summaries. These original medical records typically record the patient's condition objectively from a third-person perspective and using professional medical terminology, forming the basis and factual evidence for generating high-fidelity virtual patients.

[0092] The method provided in this embodiment digitizes and centrally stores and manages the core data of virtual patients. This approach separates the creation and use of virtual patients, allowing users to quickly retrieve a complex and fully configured target virtual patient using only a simple, unique identifier during simulated consultations, greatly improving the system's usability and scalability. Simultaneously, it ensures that the same target virtual patient maintains absolutely consistent behavioral benchmarks across different interactive sessions, providing a reliable guarantee for standardized teaching and assessment.

[0093] Figure 2 This is a schematic diagram illustrating the process of constructing a digital patient asset database according to an embodiment of the present invention. Figure 2 As shown, in some embodiments, the step of constructing a digital patient asset library is included before determining the atomized information associated with the target virtual patient: Step 210: Obtain the standard clinical medical record for each virtual patient.

[0094] Optionally, anonymized real medical record data can be exported in batches from hospital information systems, electronic medical record systems, or research data platforms. Alternatively, a small amount of user information or existing brief descriptions can be used as input, and a large language model can be used to output standard clinical medical records that conform to the basic norms of medical record writing.

[0095] Optionally, a standard clinical medical record may include, but is not limited to: chief complaint, present illness, past medical history, family history, allergy history, medication history, surgical history, personal history, physical examination, diagnosis, treatment plan, and doctor's orders.

[0096] Step 220: Rewrite the professional descriptions in the standard clinical medical records into the colloquial descriptions of the corresponding virtual patients to form the core clinical data for each virtual patient.

[0097] Optionally, the professional medical terminology and objective descriptions in standard clinical medical records can be converted into first-person colloquial expressions that fit the specific virtual patient's identity. This rewriting can be assisted or automated using a large language model fine-tuned with specific instructions. The resulting core clinical data serves as the narrative blueprint for the virtual patient to describe their core symptoms during simulated consultations.

[0098] Optionally, core clinical data may include, but is not limited to, fields such as chief complaint, present illness, past medical history, family history, allergy history, medication history, surgical history, and personal history.

[0099] Step 230: Analyze standard clinical medical records to construct a personality profile, information disclosure guidelines, and cognitive boundaries for each virtual patient.

[0100] Optionally, standard clinical medical records are clinically analyzed to obtain subjective descriptions perceptible to the virtual patient, such as the experience of main symptoms, symptom timeline, and trigger points for seeking medical attention. Based on the virtual patient data, background stories, language style guidelines, psychological state, family and social relationships, daily life details, and geographical location are output to construct a character profile. For pediatric cases, the character profile is uniformly constructed from the perspective of a parent. The analyzed standard clinical medical records and character profiles are integrated to output narrative weaving materials, such as a story outline, the patient's opening line, key question-and-answer scripts and their corresponding disclosure levels, ultimate concerns, emotional arcs, detailed case descriptions, and performance points. These materials are integrated into a personality profile, information disclosure guidelines, and cognitive boundaries. The information disclosure guidelines define the triggering conditions and order of information disclosure.

[0101] Step 240: Infer the completed examination items from the diagnostic results and treatment plans of the standard clinical medical records, establish the correspondence between examination names and attachment identifiers, and generate a hidden material mapping list for each virtual patient.

[0102] Step 250: Based on the clinical core data, personality profile, information disclosure guidelines, cognitive boundaries, and hidden material mapping list of each virtual patient, determine the atomized information of each virtual patient.

[0103] Step 260: Construct a digital patient asset library based on the unique identifier of each virtual patient and the atomic information of each virtual patient.

[0104] Specifically, by repeatedly performing steps 210 to 260 on multiple standard clinical medical records, a digital patient asset library containing a large number of diverse virtual patient roles can be constructed.

[0105] This embodiment systematically solves the structural data gap between original medical records and high-fidelity interactive virtual patients through the aforementioned multi-stage data processing pipeline. By transforming non-interactive, objective medical record text into structured digital assets that contain subjective cognition, emotions, and behavioral logic and can be directly used to drive large language models, it provides a solid data foundation and technical guarantee for realizing large-scale, standardized, and high-fidelity virtual patient simulation.

[0106] Figure 3 This is the second flowchart illustrating the simulated consultation interaction method based on a virtual patient provided in an embodiment of the present invention. Figure 3 As shown, the simulated consultation interaction method based on virtual patients includes the following steps: Step 310, Data Preparation Stage: This stage corresponds to Figure 3The left side shows the process from medical records to atomization and personification. This process is an offline data preprocessing workflow. First, the raw medical records, such as standard clinical medical records, are acquired as factual evidence. Then, these non-interactive, professional medical records are transformed into structured, atomized information that can be used to drive a large language model.

[0107] Step 320: External Knowledge Base Construction and Update Phase This stage corresponds to Figure 3 The External Knowledge module in the middle. The atomic information generated during the data preparation phase can be used to update this external knowledge base, namely the external medical knowledge base. This external knowledge base exists independently of the large language model and mainly consists of two parts: Experience Logic, i.e., a medical experience base, storing structured medical principles, treatment guidelines, and key knowledge points; and Sample Narratives, i.e., a historical treatment sample base, storing complete, contextualized historical real-world treatment cases.

[0108] In some embodiments, the above method further includes: To acquire new clinical experience data and / or new case data; Extract the empirical feature vector from new clinical diagnosis and treatment experience data, and / or extract the sample feature vector from new diagnosis and treatment case data; Write the empirical feature vector and / or sample feature vector into the external medical knowledge base, and update the vector index of the external medical knowledge base.

[0109] New clinical experience data refers to medical principles or knowledge points that emerge after the system is built and need to be mastered by the system, such as the latest clinical practice guidelines, expert consensus, or summaries of clinical application experience for specific drugs. New clinical case data refers to newly collected complete clinical cases that can be used as references, such as a new, desensitized electronic medical record or doctor-patient dialogue record with typical teaching significance.

[0110] Step 330, Reasoning and Interaction Phase: This stage corresponds to Figure 3 The Inference & Interaction module on the right is the core process for real-time interaction between the system and the user. This process specifically includes: First, the system receives the doctor input, which is the input for the current consultation.

[0111] Subsequently, based on this input, the system performs a retrieval operation to retrieve experiential logic and example narratives that match the current context from an external knowledge base.

[0112] Next, the system performs a prompt injection operation, which integrates the doctor's input, retrieved knowledge, and atomic information associated with the current virtual patient to construct a final prompt.

[0113] Then, the prompt words, which have been enriched by retrieval and prompt injection, are input into the Large Language Model (LLM).

[0114] Finally, under the constraints of multiple pieces of information, the large language model generates a traceable response, which is output to the user as the virtual patient's reply.

[0115] The embodiments of the present invention have the following beneficial effects: First, it enables low-cost, instant hot updates of knowledge. Knowledge updates are performed on an external knowledge base independent of the large language model, rather than fine-tuning the large language model itself. This means that newly added medical guidelines or cases can be quickly vectorized and stored in the knowledge base to take effect, completely avoiding the high computational costs and long training cycles associated with traditional parameter fine-tuning methods.

[0116] Second, it significantly improved the high fidelity of virtual patient interaction. Through atomization and role-building steps, especially by introducing the key concept of cognitive boundaries and applying it as a strong constraint to the large language model during the prompt injection stage, it ensured that the model's output strictly conformed to the preset patient's knowledge level and language habits, effectively avoiding the problem of role-playing failure due to the model using professional terminology beyond its scope.

[0117] Third, it fundamentally solves the problems of knowledge illusion and lack of traceability in models. The final response is called a traceable response because the output of the large language model is generated based on empirical logic and example narratives explicitly retrieved from external knowledge bases. This means that every key information output of the system can theoretically be traced back to the specific knowledge item or case on which it is based. This is crucial for medical application scenarios that require rigor and accuracy, greatly enhancing the reliability and security of the system.

[0118] The following describes the virtual patient-based simulated consultation interaction device provided in the embodiments of the present invention. The virtual patient-based simulated consultation interaction device described below can be referred to in correspondence with the virtual patient-based simulated consultation interaction method described above.

[0119] Figure 4 This is a schematic diagram of the structure of the virtual patient-based simulated consultation interaction device provided in an embodiment of the present invention, as shown below. Figure 4 As shown, the virtual patient-based simulated consultation interaction device 400 includes: The acquisition unit 410 is used to acquire the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state, and the atomized information includes a personality profile, cognitive boundaries for constraining information disclosure and a hidden material mapping list; The retrieval unit 420 is used to retrieve matching medical reference information from an external medical knowledge base based on the current consultation input and the current session status. The generation unit 430 is used to integrate atomic information, current session state, medical reference information and current consultation input to construct prompt words for the current round. The prompt words are then input into the large language model to obtain the response text of the target virtual patient output by the large language model under the constraints of personality profile and cognitive boundary. Matching unit 440 is used to match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input; Output unit 450 is used to output the response text and / or medical accessory identifier as a response for the current round.

[0120] Optionally, the external medical knowledge base includes a medical experience base and a historical clinical case database; based on the current consultation input and the current session state, matching medical reference information is retrieved from the external medical knowledge base, including: Construct the search query text based on the current consultation input and the current session status; Based on the retrieval query text, a set of candidate experience entries is retrieved from the medical experience database, and a set of candidate diagnosis and treatment example entries is retrieved from the historical diagnosis and treatment example database; An alternating selection strategy is adopted to extract items from the candidate experience item set and the candidate diagnosis and treatment example item set in turn until the number of extracted items reaches a preset threshold, thereby obtaining medical reference information.

[0121] Optionally, the prompts for the current round are constructed by integrating atomic information, the current session state, medical reference information, and the current consultation input, including: Format the medical reference information into multiple reference case blocks; Fill in the atomization information in the placeholders of the preset skeleton template; The current session state, current consultation input, multiple reference case blocks, and preset fixed instructions are added to the skeleton template to obtain prompt words.

[0122] Optionally, the current session state includes: a multi-turn dialogue history list and a summary of the consultation progress; the virtual patient-based simulated consultation interaction device further includes a first update unit, which is used for: After outputting the interaction response of the current round, the large language model is called to update the consultation progress summary, taking the current dialogue text as input. The current dialogue text includes: a list of multi-round dialogue history, the current consultation input, and the reply text. The consultation progress summary includes: the progress of the consultation and the medical information obtained. Write the updated consultation progress summary to the current session state to obtain the updated current session state.

[0123] Optionally, the current session state also includes an unlocked attachment list; a hidden material mapping list containing the correspondence between examination names and candidate attachment identifiers; and matching the current consultation input with the hidden material mapping list to determine the medical attachment identifiers that match the current consultation input, including: Perform semantic matching between the current consultation input and the examination names in the hidden material mapping list; If a match is found, retrieve the corresponding candidate attachment identifier from the hidden material mapping list; If the candidate attachment identifier does not exist in the unlocked attachment list, the candidate attachment identifier will be identified as a medical attachment identifier and added to the unlocked attachment list.

[0124] Optionally, atomic information associated with the target virtual patient is determined, including: Based on the unique identifier of the target virtual patient, a search is performed in a pre-built digital patient asset database to obtain atomized information associated with the target virtual patient; the atomized information is generated based on the target virtual patient's standard clinical medical record.

[0125] Optionally, the virtual patient-based simulated consultation interaction device further includes a construction unit, which is used for: Before determining the atomic information associated with the target virtual patient, perform the steps of building a digital patient asset library: Obtain the standard clinical medical records for each virtual patient; The professional descriptions in standard clinical medical records are rewritten into the colloquial descriptions of the corresponding virtual patients, forming the core clinical data for each virtual patient. Analyze standard clinical medical records to construct a personality profile, information disclosure guidelines, and cognitive boundaries for each virtual patient; The completed examination items are inferred from the diagnostic results and treatment plans in standard clinical medical records. A correspondence between examination names and attachment identifiers is established, and a hidden material mapping list is generated for each virtual patient. Based on each virtual patient's core clinical data, personality profile, information disclosure guidelines, cognitive boundaries, and hidden material mapping list, the atomic information of each virtual patient is determined. A digital patient asset library is constructed based on the unique identifier and atomic information of each virtual patient.

[0126] Optionally, the virtual patient-based simulated consultation interaction device further includes a second update unit, which is used for: To acquire new clinical experience data and / or new case data; Extract the empirical feature vector from new clinical diagnosis and treatment experience data, and / or extract the sample feature vector from new diagnosis and treatment case data; Write the empirical feature vector and / or sample feature vector into the external medical knowledge base, and update the vector index of the external medical knowledge base.

[0127] It should be noted that the virtual patient-based simulated consultation interaction device provided in this embodiment of the invention can implement all the method steps implemented in the above-mentioned virtual patient-based simulated consultation interaction method embodiment, and can achieve the same technical effect. Here, the parts that are the same as those in the method embodiment and the beneficial effects will not be described in detail.

[0128] All actions involving the acquisition of information or data in this invention are carried out in accordance with the relevant data protection laws and regulations of the locality and with the authorization granted by the owner of the relevant device.

[0129] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention, such as... Figure 5As shown, the electronic device may include: a processor 510, a communications interface 520, a memory 530, and a communications bus 540, wherein the processor 510, the communications interface 520, and the memory 530 communicate with each other through the communications bus 540. The processor 510 can call logical instructions in the memory 530 to execute a simulated consultation interaction method based on a virtual patient. This method includes: acquiring the current consultation input for a target virtual patient; determining the atomic information associated with the target virtual patient and the current session state; the atomic information includes a personality profile, cognitive boundaries for constraining information disclosure, and a hidden material mapping list; retrieving matching medical reference information from an external medical knowledge base based on the current consultation input and the current session state; fusing the atomic information, the current session state, the medical reference information, and the current consultation input to construct a prompt for the current round; inputting the prompt into a large language model to obtain the response text of the target virtual patient output by the large language model under the constraints of the personality profile and cognitive boundaries; matching the current consultation input with the hidden material mapping list to determine the medical accessory identifier matching the current consultation input; and outputting the response text and / or the medical accessory identifier as the response for the current round.

[0130] Furthermore, the logical instructions in the aforementioned memory 530 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0131] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0132] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0133] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A simulated consultation interaction method based on virtual patients, characterized in that, include: Obtain the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state, the atomized information includes a personality profile, cognitive boundaries for constraining information disclosure, and a hidden material mapping list; Based on the current consultation input and the current session state, retrieve matching medical reference information from an external medical knowledge base; By integrating the atomic information, the current session state, the medical reference information, and the current consultation input, the prompt words for the current round are constructed. The prompt words are then input into the large language model to obtain the response text of the target virtual patient, which is output by the large language model under the constraints of the personality profile and the cognitive boundary. Match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input; Output the response body and / or the medical accessory identifier as the response for the current round.

2. The virtual patient-based simulated consultation interaction method according to claim 1, characterized in that, The external medical knowledge base includes a medical experience base and a historical clinical case database; the step of retrieving matching medical reference information from the external medical knowledge base based on the current consultation input and the current session state includes: Construct the retrieval query text based on the current consultation input and the current session state; Based on the search query text, a set of candidate experience entries is retrieved from the medical experience database, and a set of candidate treatment sample entries is retrieved from the historical treatment sample database; An alternating selection strategy is adopted to extract entries from the candidate experience entry set and the candidate diagnosis and treatment example entry set in turn until the number of extracted entries reaches a preset threshold, thereby obtaining the medical reference information.

3. The virtual patient-based simulated consultation interaction method according to claim 1, characterized in that, The process of integrating the atomic information, the current session state, the medical reference information, and the current consultation input to construct the prompt words for the current round includes: The medical reference information is formatted into multiple reference case blocks; The atomization information is filled into the placeholders of the preset skeleton template; The current session state, the current consultation input, multiple reference case blocks, and preset fixed instructions are appended to the skeleton template to obtain the prompt words.

4. The simulated consultation interaction method based on a virtual patient according to claim 1, characterized in that, The current session state includes: a multi-turn dialogue history list and a consultation progress summary; the method also includes: After outputting the interaction response of the current round, the large language model is called to update the consultation progress summary, using the current dialogue text as input; the current dialogue text includes: the multi-round dialogue history list, the current consultation input, and the response text; the consultation progress summary includes: the progress of the consultation and the medical information obtained; Write the updated consultation progress summary into the current session state to obtain the updated current session state.

5. The simulated consultation interaction method based on a virtual patient according to claim 1, characterized in that, The current session state also includes a list of unlocked attachments; the hidden material mapping list includes the correspondence between check names and candidate attachment identifiers; The step of matching the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input includes: Perform semantic matching between the current consultation input and the examination names in the hidden material mapping list; If a match is found, the corresponding candidate attachment identifier is retrieved from the hidden material mapping list; If the candidate attachment identifier does not exist in the unlocked attachment list, then the candidate attachment identifier is identified as the medical attachment identifier, and the medical attachment identifier is added to the unlocked attachment list.

6. The simulated consultation interaction method based on a virtual patient according to claim 1, characterized in that, The determination of the atomized information associated with the target virtual patient includes: Based on the unique identifier of the target virtual patient, a search is performed in a pre-built digital patient asset database to obtain atomic information associated with the target virtual patient; the atomic information is generated based on the target virtual patient's standard clinical medical record.

7. The virtual patient-based simulated consultation interaction method according to claim 6, characterized in that, Prior to determining the atomized information associated with the target virtual patient, the method further includes the step of constructing the digital patient asset library: Obtain the standard clinical medical records for each virtual patient; The professional descriptions in the standard clinical medical records are rewritten into the colloquial descriptions of the corresponding virtual patients to form the core clinical data of each virtual patient. Analyze the standard clinical medical records to construct a personality profile, information disclosure guidelines, and cognitive boundaries for each virtual patient; The completed examination items are inferred from the diagnostic results and treatment plans of the standard clinical medical records. A correspondence between examination names and attachment identifiers is established, and a hidden material mapping list is generated for each virtual patient. Based on the core clinical data, personality profile, information disclosure guidelines, cognitive boundaries, and hidden material mapping list of each virtual patient, the atomic information of each virtual patient is determined. The digital patient asset library is constructed based on the unique identifier of each virtual patient and the atomic information of each virtual patient.

8. The simulated consultation interaction method based on a virtual patient according to any one of claims 1 to 7, characterized in that, The method further includes: To acquire new clinical experience data and / or new case data; Extract the empirical feature vector from the new clinical diagnosis and treatment experience data, and / or extract the sample feature vector from the new diagnosis and treatment case data; Write the empirical feature vector and / or the sample feature vector into the external medical knowledge base, and update the vector index of the external medical knowledge base.

9. A simulated consultation interaction device based on a virtual patient, characterized in that, include: The acquisition unit is used to acquire the current consultation input for the target virtual patient, determine the atomized information associated with the target virtual patient and the current session state, wherein the atomized information includes a personality profile, a cognitive boundary for constraining information disclosure and a hidden material mapping list; The retrieval unit is used to retrieve matching medical reference information from an external medical knowledge base based on the current consultation input and the current session state. The generation unit is used to integrate the atomic information, the current session state, the medical reference information, and the current consultation input to construct the prompt words for the current round, input the prompt words into the large language model, and obtain the response text of the target virtual patient output by the large language model under the constraints of the personality profile and the cognitive boundary; A matching unit is used to match the current consultation input with the hidden material mapping list to determine the medical accessory identifier that matches the current consultation input; The output unit is used to output the response text and / or the medical accessory identifier as a response for the current round.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the virtual patient-based simulated consultation interaction method as described in any one of claims 1 to 8.