A medical scenario simulation case automatic generation and online method, system, device and medium

By combining a large language model and an abstract syntax tree translator, the system achieves automated generation and cross-platform deployment of medical scenario simulation cases, solving the problems of high development threshold and inefficient material scheduling, and providing efficient, traceable medical logic translation and immersive interaction.

CN122450432APending Publication Date: 2026-07-24TIANFU JIANGXI LAB
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
TIANFU JIANGXI LAB
Filing Date
2026-06-26
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

Existing medical education simulation case development suffers from high development barriers, difficulties in translating medical logic into program logic, inefficient multimedia material scheduling, and cumbersome deployment processes, especially lacking the ability to generate automated cases and deploy them across platforms.

Method used

A method based on a large language model is adopted, which combines thought chain reasoning to generate standardized intermediate representation data. The medical logic is then transformed into a computer-executable script through an abstract syntax tree translator. Finally, cloud containerization technology is used to achieve automated generation and cross-platform deployment.

Benefits of technology

It achieves the rigor and traceability of medical logic, eliminates data silos and logical gaps, realizes intelligent and automated assembly of multimodal materials and cross-platform zero-threshold delivery, and improves generation efficiency and immersive feedback.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122450432A_ABST
    Figure CN122450432A_ABST
Patent Text Reader

Abstract

The application discloses a medical scenario simulation case automatic generation and online method, system, equipment and medium, and relates to the technical field of medical education informatization. The method comprises the following steps: acquiring clinical structured data containing a clinical time axis anchor point and a physiological state vector matrix; expanding and generating standardized intermediate representation data through a large language model; rendering the data into a node flow graph and performing data integrity check locking; extracting keywords using a natural language processing algorithm to complete material binding based on semantic analysis; mapping the data into an abstract syntax tree representing a nonlinear state machine based on a deterministic mapping rule using an abstract syntax tree translator, converting time axis logic into branch jump logic and serializing it into a script; and compiling and packaging into a cross-platform Web application in a containerized environment and distributing it. The application realizes safe and lossless mapping of medical logic to computer bottom layer control flow and case zero threshold delivery.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical education informatization technology, specifically to a method, system, device, and medium for the automated generation and online deployment of medical scenario simulation cases. Background Technology

[0002] The statements in this section are provided only as background information in connection with this disclosure and may not constitute prior art.

[0003] In modern nursing and medical education, simulation-based education (SBE) has become the standard paradigm. Currently, the production of digital virtual patient cases mainly relies on two traditional technical paths: one is a fully customized development model (such as using Unity 3D, Unreal Engine, or native HTML5 / JS development), in which medical experts write Word / Excel scripts, and then software engineers develop the code, similar to the traditional game development process; the other is a general courseware tool model (such as using Articulate Storyline, Adobe Captivate, or iSpring), in which teachers construct interactive logic by dragging and dropping UI components and manually setting triggers and variables.

[0004] However, the aforementioned existing technical solutions have the following significant technical and application shortcomings in the medical education vertical field: 1. The Semantic Gap Between Domain Knowledge and Code Implementation: Nursing experts think based on "clinical pathways" and "ADPIE (Advanced Medical Procedures)", while the logic of development tools is based on "state machines", "Boolean operations", and "event listeners". The lack of an automatic translation mechanism between the two makes it impossible for experts to directly verify the logic, and programmers struggle to understand medical details, leading to significant rework due to poor communication.

[0005] 2. Data silos caused by unstructured input: Most existing scripts are unstructured texts and lack standardized metadata descriptions. This means that the generated cases cannot be parsed by machines, making it difficult to carry out subsequent automated testing, difficulty grading, or cross-platform migration.

[0006] 3. Inefficiency in material resource scheduling: The development of each new case requires manual retrieval and matching of multimedia materials such as "ECG monitor alarm sound" and "specific facial features". The lack of automated resource retrieval based on medical semantics leads to a large amount of repetitive work.

[0007] 4. Lack of DevOps automated deployment loop: Existing solutions often output offline applications or compressed packages after content generation, which need to be manually uploaded to the server. They lack continuous integration / continuous deployment capabilities from "script generation" to "end-user access". Summary of the Invention

[0008] The purpose of this invention is to address the problems existing in the development of current nursing simulation teaching resources, such as high development barriers, difficulties in translating medical logic into program logic, inefficient multimedia material scheduling, and cumbersome deployment processes. In particular, directly generating code from large models can lead to illusions and a lack of traceability. This invention provides a method, system, device, and medium for the automated generation and deployment of medical scenario simulation cases. This invention employs a large language model combined with thought chain reasoning to generate standardized intermediate representation data. A hierarchical data integrity verification mechanism is used to lock in unique medical truth values. Furthermore, it innovatively utilizes an abstract syntax tree translator to map data containing clinical timeline logic into a low-level compiled script representing a nonlinear state machine based on deterministic mapping rules. Simultaneously, it integrates semantically driven material binding and cloud-based containerized compilation technology to achieve a secure and lossless mapping from rigorous medical logic to computer-executable logic, as well as minute-level generation of medical simulation cases and zero-threshold delivery of cross-platform web applications.

[0009] The technical solution of the present invention is as follows: A method for automatically generating and deploying medical scenario simulation cases includes: Acquire clinical structured data based on dynamic form collection. The clinical structured data includes clinical timeline anchor points and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor point, and teaching intervention node data. Based on the preset prompt template, the clinical structured data is input into the large language model for logical expansion to generate standardized intermediate representation data, which includes node set, edge set, trigger conditions and resource tags. The standardized intermediate representation data is rendered into a visual node flow graph, and upon receiving a confirmation instruction, a data integrity check is performed on the standardized intermediate representation data to lock it as a unique truth data source. The standardized intermediate representation data after locking is parsed, and clinical keywords are extracted from the intermediate representation data using natural language processing algorithms. The corresponding multimedia resource identifiers are matched from the pre-set multimedia knowledge graph library, and the multimedia resource identifiers are written into the resource tags to complete the material binding based on semantic analysis. Using a pre-defined abstract syntax tree translator, based on deterministic mapping rules, the standardized intermediate representation data after the completion of material binding is mapped to an abstract syntax tree representing the target compilation engine's nonlinear state machine, so as to transform the linear time axis logic in the clinical structured data into computer-executable branch jump logic and serialize it into a target engine executable script. In a cloud-based containerized environment, the build toolchain of the target compilation engine is invoked to compile and package the target engine's executable script into a cross-platform web application, and automatically distribute it to an object storage system to generate access links.

[0010] Furthermore, acquiring structured clinical data based on dynamic form collection specifically includes: Obtain multiple discrete clinical timeline anchor points defined on the timeline, and record the clinical event data associated with each anchor point; Obtain the physiological state vector matrix corresponding to each of the clinical time axis anchor points, wherein the physiological state vector matrix consists of numerical vectors including at least body temperature, pulse, respiration, blood pressure, blood oxygen saturation and pain score; Obtain the preset teaching intervention node data, which includes mandatory operation instructions that trigger teaching assessments.

[0011] Furthermore, the large language model is a large language model fine-tuned from a domain corpus; the step of inputting the clinical structured data into the large language model based on a preset prompt template for logical expansion to generate standardized intermediate representation data specifically includes: The clinical structured data is filled into a prompt template containing thought chain reasoning instructions. The thought chain reasoning instructions guide the large language model to deduce step by step according to the clinical logic chain to avoid skipping generation and construct target prompt words. The target prompt words are input into the large language model, and the large language model expands the text description information, vital sign change logic and decision branch options based on the fine-tuned corpus. The expanded logical data is structured and output as standardized intermediate representation data based on JSON format. The standardized intermediate representation data is strictly divided into node objects, edge objects, condition triggering mechanisms, and resource tags.

[0012] Furthermore, the standardized intermediate representation data is rendered into a visual node flow graph, and upon receiving a confirmation instruction, a hash check is performed on the standardized intermediate representation data to lock it as a unique truth data source, including: The standardized intermediate representation data's node and edge objects are parsed and rendered into a visual logical topology graph on the front end. In response to edit operations on the logical topology graph, the standardized intermediate representation data at the underlying level is updated synchronously. Upon receiving the confirmation lock command, the core feature string representing medical logic in the updated standardized intermediate representation data is extracted and hashed to generate a unique hash value; The node set, edge set, and triggering conditions in the standardized intermediate representation data carrying the unique hash value are marked as locked to prevent tampering, and the resource tags are reserved as writable states that allow the system to automatically fill them in, serving as the unique truth data source for subsequent code translation.

[0013] Furthermore, clinical keywords are extracted from the intermediate representation data using natural language processing algorithms, corresponding multimedia resource identifiers are matched from a pre-set multimedia knowledge graph database, and the multimedia resource identifiers are written into the resource tags, specifically including: The text fields in the standardized intermediate representation data are traversed, and natural language processing technology is used for word segmentation and entity recognition to extract clinical keywords that characterize symptoms, environment, or equipment status. Search the multimedia knowledge graph database containing the mapping relationship between medical entities and multimedia to obtain audio or image identifiers that semantically match the clinical keywords; The matched audio or image identifiers are inserted as instruction parameters into the corresponding node resource tags of the standardized intermediate representation data.

[0014] Furthermore, using a pre-defined abstract syntax tree transpiler, based on deterministic mapping rules, the standardized intermediate representation data after the material binding is completed is mapped to an abstract syntax tree representing the target compilation engine's nonlinear state machine. The deterministic mapping rules specifically include: The decision branch structure in the standardized intermediate representation data is mapped and converted into menu selection node logic in the abstract syntax tree; The numerical changes of the physiological state vectors in the standardized intermediate representation data are mapped and converted into variable assignment operation logic in the abstract syntax tree; Based on the multimedia resource identifier in the resource tag, the corresponding front-end interface rendering layer control code is automatically injected into the abstract syntax tree.

[0015] Furthermore, in a cloud-based containerized environment, the build toolchain of the target compilation engine is invoked to compile and package the target engine's executable script into a cross-platform application in WebAssembly format, and automatically distributed to an object storage system to generate access links, including: An isolated container pre-installed with the target compilation engine software development kit is dynamically launched on a cloud server; Automated build instructions are executed within the isolated container to compile the target engine's executable script and bound multimedia resource files into a Hypertext Markup Language application package based on WebAssembly technology; The application package is automatically uploaded to the cloud object storage system and a unique Uniform Resource Locator (URL) is generated. The URL is then pushed to the corresponding teaching management platform via a network hook mechanism.

[0016] This invention also proposes an automated system for generating and deploying medical scenario simulation cases, comprising: The data acquisition module is used to acquire clinical structured data based on dynamic forms. The clinical structured data includes clinical timeline anchors and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor, and teaching intervention node data. The logic expansion module is used to input the clinical structured data into the large language model for logical expansion based on the preset prompt template, and generate standardized intermediate representation data, which includes node set, edge set, trigger condition and resource tag; The integrity locking module is used to render the standardized intermediate representation data into a visual node flow graph, and after receiving a confirmation instruction, to perform data integrity verification on the standardized intermediate representation data to lock it as a unique truth data source. The semantic binding module is used to parse the locked standardized intermediate representation data, extract clinical keywords from the intermediate representation data using natural language processing algorithms, match the corresponding multimedia resource identifiers from the pre-set multimedia knowledge graph library, and write the multimedia resource identifiers into the resource tags to complete the material binding based on semantic analysis. The code translation module is used to map the standardized intermediate representation data after the completion of material binding into an abstract syntax tree representing the target compilation engine based on deterministic mapping rules using a preset abstract syntax tree translator. This transforms the linear time axis logic in the clinical structured data into computer-executable branching logic and serializes it into a target engine executable script. The compilation and distribution module is used to call the build toolchain of the target compilation engine in a cloud-based containerized environment, compile and package the target engine's executable script into a cross-platform web application, and automatically distribute it to an object storage system to generate access links.

[0017] The present invention also proposes an electronic device, comprising: At least one processor; and a memory communicatively connected to said at least one processor; The memory stores instructions that can be executed by the at least one processor, and the at least one processor executes the instructions stored in the memory to perform the method described above.

[0018] The present invention also proposes a computer-readable storage medium for storing instructions that, when executed, cause the method described above to be implemented.

[0019] Compared with existing technologies, the advantages of this invention are: The beneficial technical effects brought about by this invention include at least the following: 1. This invention eliminates data silos and logical gaps, constructing a highly reliable medical data foundation. It mandates the use of dynamic forms to collect structured clinical data and effectively avoids leaps in data generation or "AI illusions" caused by large language models by introducing CoT (Cooperation of Thought) reasoning instructions into the prompt templates, ensuring the medical continuity of the logical expansion process. Simultaneously, this invention innovatively proposes a hierarchical data integrity locking mechanism that separates static and dynamic elements. It locks only the core medical logic (nodes, edge sets, trigger conditions) to prevent tampering, while leaving resource tags writable. This mechanism ensures the absolute rigor of the medical logic as the sole source of truth and avoids data access conflicts caused by subsequent automated data writing at the computer's underlying architecture.

[0020] 2. By employing a hybrid architecture and deterministic mapping rules, the security and interpretability barriers of code translation are completely overcome. Addressing the shortcomings of conventional AI-generated low-level code, such as high randomness and difficulty in tracing bugs, this invention innovatively constructs a hybrid architecture of "large model generating structured intermediate states + translator generating code using deterministic rules." Through a pre-defined Abstract Syntax Tree (AST) translator, strictly based on deterministic mapping rules, the clinical intermediate data along the linear timeline is transformed 100% losslessly into the low-level branching logic and state checkpoints representing a "non-linear state machine." This technical feature ensures that the translation process contains no probabilistic inferences, endowing the system with extremely high medical-grade execution security and fault traceability.

[0021] 3. An integrated semantic-driven engine was constructed, enabling intelligent and automated assembly of multimodal materials. This invention breaks the isolation between traditional material matching and code development, deeply integrating the material binding steps based on Natural Language Processing (NLP) and vector retrieval with the underlying syntax tree translation into a highly collaborative integrated workflow. The multimedia resource identifiers automatically matched by the system directly serve as data dependencies for the translator to generate the front-end UI code, automatically injecting rendering instructions and giving the generated cases a strong immersive audiovisual feedback (such as dynamic ECG alarm sounds and changes in patient facial expressions), completely eliminating the repetitive labor of manually piecing together materials.

[0022] 4. Achieved a closed-loop containerized DevOps distribution mechanism for cross-platform, zero-threshold delivery. This invention introduces isolated containers and automated build toolchains in the cloud, directly compiling and packaging the translated underlying scripts into cross-platform web applications (WebAssembly format). This mechanism not only enables extremely rapid cloud deployment but also frees the generated examples from the limitations of specific clients or operating systems. Students can directly access and obtain strong interactive feedback such as WebGL effects through mobile or PC browsers, truly achieving minute-level generation of medical courseware and "zero-threshold" delivery across platforms without installation. Attached Figure Description

[0023] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments recorded in the embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings.

[0024] Figure 1 A system overall business process diagram provided for embodiments of the present invention; Figure 2 This is a schematic diagram of code translation logic provided for an embodiment of the present invention; Figure 3 This is a schematic diagram of the expert structured input interface logic provided in an embodiment of the present invention; Figure 4 A flowchart of a semantically driven automated material matching algorithm provided in an embodiment of the present invention; Figure 5 This is a definition diagram of the intermediate state data structure provided in the embodiments of the present invention; Figure 6 A schematic diagram of the executable script code for the target engine provided in an embodiment of the present invention. Figure 7 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0025] It should be noted that relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0026] The features and performance of the present invention will be further described in detail below with reference to embodiments.

[0027] Example 1 This embodiment provides a method for the automated generation and deployment of medical scenario simulation cases. This method is mainly based on the concept of "Model-Driven Engineering (MDE)" and combines Large Language Model (LLM) with game engine automated compilation technology. It aims to solve the technical problems in the current nursing education vertical field, such as high development threshold, semantic gap between domain knowledge and code implementation, data silos caused by unstructured input, and lack of DevOps automated deployment closed loop.

[0028] In this embodiment, for details, please refer to... Figure 1 , Figure 1 This is a system overall business process diagram provided for an embodiment of the present invention. The method specifically includes the following steps: Step S1: Obtain clinical structured data based on dynamic form collection. The clinical structured data includes clinical timeline anchors and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor, and teaching intervention node data.

[0029] In practice, traditional script development (such as path A using a fully customized development model with Unity 3D, Unreal Engine, or native HTML5 / JS, or path B using common courseware tools like Articulate Storyline, Adobe Captivate, and iSpring) often relies on unstructured Word / Excel document input, lacking standardized metadata descriptions, making subsequent automated testing or machine parsing difficult. This embodiment constructs a web-based dynamic form (see reference). Figure 3The diagram shown illustrates the logic of the expert structured input interface. This interface is used to collect the core intent of nursing experts (i.e., the Clinical Schema Input module), and mandates the input of structured data. Specifically, it includes: (1) Obtain multiple discrete clinical timeline anchor points defined on the timeline, and record the clinical event data associated with each anchor point. For example, define... Key clinical events at any given time (e.g.: Indicates hospitalization. (This indicates a sudden onset of ventricular fibrillation).

[0030] (2) Obtain the physiological state vector matrix corresponding to each of the clinical time axis anchor points, wherein the physiological state vector matrix comprises at least body temperature (T), pulse (P), respiration (R), blood pressure (BP), and blood oxygen saturation (T). SpO 2) Composed of numerical vectors of pain scores. For example, the physiological state vector matrix is ​​defined as follows: .

[0031] (3) Obtain the preset teaching intervention node data, which includes mandatory operation instructions that trigger teaching assessment (such as "three checks and seven verifications", "aseptic operation", etc.).

[0032] Furthermore, during the scenario initialization and parameter configuration phase, users (nursing experts) can define global variables and initial states for this unit in the "Attribute Panel" of the visual editor. For example, the system generates corresponding Python variable objects in the background: bp_sys (systolic blood pressure) with an initial value of 100 (integer); bp_dia (diastolic blood pressure) with an initial value of 60 (integer); pain_level (pain level) with an initial value of 8 (0-10 scale); and is_mona_active (MONA protocol activation status) with an initial value of False (Boolean). The user inputs a natural language description of the scenario: "Emergency triage desk, 55-year-old male patient, chief complaint of substernal squeezing pain, profuse sweating, and a pained expression." Step S2: Based on the preset prompt template, the clinical structured data is input into a large language model that has been fine-tuned by the domain corpus for logical expansion, generating standardized intermediate representation data. The standardized intermediate representation data includes node sets, edge sets, trigger conditions, and resource tags.

[0033] In its implementation, the system uses an API to call a Large Language Model (LLM) fine-tuned from a nursing corpus. Specifically, this includes: The clinical structured data is filled into a prompt template containing Chain-of-Thought instructions to construct a target prompt. The purpose of introducing Chain-of-Thought (CoT) instructions is that, due to the extremely high medical rigor required for medical scenario simulation, simple instruction input can easily lead to jumps in the large language model's output or create an "AI illusion." By pre-setting CoT instructions in the prompt template, the large language model can be forced to strictly follow the underlying logical chain of "clinical pathways" and "nursing procedures" for step-by-step deduction and state evaluation before generating the final text or numerical value. This effectively avoids logical breaks caused by jumps in output and ensures the continuity and accuracy of the intermediate representation data in medical logic. The target prompt words are input into the large language model, which is required to complete and expand the nurse-patient dialogue text description information, vital sign change logic and decision branch options based on the fine-tuned corpus. The large model does not directly generate underlying code. Instead, it outputs the expanded logical data in a structured manner as standardized intermediate representation data (IR) based on JSON Schema. The underlying data structure can be found in [reference needed]. Figure 5 (See the diagram showing the definition of the intermediate state data structure).

[0034] Specifically, in this underlying data structure, the top-level storyboard includes case identifiers (`case_id`), global variables (`GlobalVars`), and vital sign data (`VitalSigns`, specifically including key-value pairs such as heart rate `heart_rate` and body temperature `temperature`) stored based on a dictionary type (Dict). The node object includes speaker identifiers (`speaker_id`), text content (`text_content`), and the vital sign snapshot associated with that node (`vitals_snapshot`). The decision branch options include text tags, target node identifiers (`target_node_id`), score impact value (`score_impact`), and feedback text (`feedback_text`). In addition, the asset tags include fine-grained control fields such as resource file path (`file_path`), trigger condition (`trigger_condition`), and resource type (`type`, such as img / audio). This step effectively bridges the semantic gap between expert thinking (based on clinical pathways and nursing procedures ADPIE) and programmer logic (based on state machines, Boolean operations, and event listeners).

[0035] Step S3: Render the standardized intermediate representation data into a visual node flow graph, and after receiving the confirmation instruction, perform a hash check on the standardized intermediate representation data to lock it as a unique truth data source.

[0036] In its implementation, this step provides a visual, human-computer collaborative proofreading editor (Visual HITLEditor). Specifically, it includes: The standardized intermediate representation data's node and edge objects are parsed and rendered into a visual logical topology graph (node ​​flow graph) on the front end. Medical experts do not need to read the code; they can simply use the flowchart to verify medical logic.

[0037] In response to editing or modification operations on the logical topology graph (such as directly modifying dialogue text, adjusting branch logic, or correcting values), the system synchronously updates the underlying standardized intermediate representation data.

[0038] After experts confirm the data is correct, they issue a confirmation lock command. The system extracts the feature strings of the updated standardized intermediate representation data and performs a hash operation (e.g., SHA-256 algorithm) to generate a unique hash value. Specifically, to prevent subsequent automated resource filling operations from corrupting the medical logic confirmed by the experts, the system employs a layered locking mechanism. During the hash operation, the system only extracts the core feature strings representing the medical logic layer (i.e., text and numerical data in node objects, edge objects, and conditional triggering mechanisms) to participate in the operation and generate the unique hash value. Subsequently, the system marks the aforementioned core logic layer in the standardized intermediate representation data carrying the unique hash value as locked (prohibiting secondary tampering by humans or AI), while retaining the resource tags belonging to the material layer as writable, allowing the system to automatically fill them according to rules. This dynamic and static data control strategy ensures the absolute rigor and integrity of the medical logic as a single source of truth, and also provides the necessary data interface for semantic automated material binding in the subsequent step S4.

[0039] Step S4: Parse the locked, standardized intermediate representation data, extract clinical keywords from the intermediate representation data using natural language processing algorithms, match the corresponding multimedia resource identifiers from the preset multimedia knowledge graph library, and write the multimedia resource identifiers into the resource tags to complete the material binding based on semantic analysis.

[0040] In practice, traditional material matching requires manual matching of alarm sounds, specific facial features, etc., which is extremely inefficient. This embodiment is based on semantic-driven material binding technology (see the algorithm execution flow for details). Figure 4 The flowchart shown is for a semantically driven automated material matching algorithm, which specifically includes: The text fields in the standardized intermediate representation data are traversed, and natural language processing (NLP) techniques are used for word segmentation and entity recognition to extract clinical keywords that characterize symptoms, environment, or equipment status; for example, the keywords "emergency triage station", "sweating profusely", "pain", and "squeezing pain" are identified.

[0041] The system searches the multimedia knowledge graph database, which contains mappings between medical entities and multimedia content. For keywords such as "pale complexion," "rapid breathing," and "anxiety," the system initiates a vector retrieval process to obtain audio or image identifiers that semantically match the clinical keywords. For example, "emergency triage desk" matches the background resource `bg_emergency_room.jpg`; "drenched in sweat" and "pain" match the patient portrait layers `layer_sweat_drops.png` and `face_pain_agony.png`; "crushing pain" matches the background sound effect `sfx_heartbeat_fast.mp3` (rapid heartbeat sound); and "pale complexion" matches `face_pale.png`. In other implementation scenarios, if the clinical keywords "wheezing" or "cyanosis" are extracted during the traversal, the system will retrieve the corresponding resource IDs, such as `audio_wheezing_01.mp3` and `img_cyanosis_face.png`, and automatically write them into the resource field.

[0042] The matched audio or image identifiers are inserted as instruction parameters into the corresponding node resource tags of the standardized intermediate representation data. After converting the above mapping relationship into intermediate instructions, the system engine supports real-time rendering of dynamic images such as patients clutching their chests and sweating profusely in the front-end preview window of the visual editor, allowing nursing experts to verify them instantly. The automatic adaptation of dynamic materials greatly enhances the immersive audiovisual feedback of the subsequently generated cases.

[0043] Step S5: Using a preset abstract syntax tree translator, based on deterministic mapping rules, the standardized intermediate representation data after the completion of material binding is mapped to an abstract syntax tree representing the target compilation engine's nonlinear state machine, so as to transform the linear time axis logic in the clinical structured data into computer-executable branch jump logic and serialize it into a target engine executable script.

[0044] In practical implementation, this step is the core technology engine of the system (AST translator; for its internal logic, please refer to [link to relevant documentation]). Figure 2 (The diagram shows the code translation logic). This step, together with the aforementioned step S4, constitutes the core technology engine workflow of the system. It should be noted that the semantic analysis-based material binding in step S4 and the abstract syntax tree translation in this step are not two isolated systems, but rather highly collaborative integrated processing steps. The multimedia resource identifiers automatically written with resource tags in step S4 directly serve as the data foundation and dependency input for the translator to generate the front-end UI rendering code in this step.

[0045] It is particularly important to emphasize that the abstract syntax tree transpiler described in this step is entirely based on "deterministic rules" for low-level mapping. This constitutes the fundamental difference between this invention and conventional "AI-generated final code" schemes. Because code directly generated from large language models inherently possesses randomness and "AI illusions," it is highly prone to generating uncontrollable bugs and is difficult to trace and debug at the medical level. Therefore, this invention innovatively adopts a hybrid architecture of "AI-generated structured intermediate states (creative and logical expansion) + deterministic rule-based code transpilation (ensuring execution security)." During transpilation, the transpiler does not rely on any probabilistic inference but strictly follows fixed syntax tree mapping rules to transform the aforementioned intermediate representation data, which has been locked by experts. This ensures that the rigorous medical path is 100% lossless and fully interpretable into the computer's low-level program logic.

[0046] Specifically, the transpiler executes the following processing cycles in the background sequentially: parsing the JSON intermediate file (`parse`), mapping assets based on tags (`map_assets`, i.e., calling and reading the resource tags that have been bound in step S4), generating logic branch code (`generate_logic`), and finally writing the serialization result into a file with the .rpy extension (`write_file`). Taking the open-source Ren'Py game engine as the target compilation engine as an example, the specific deterministic mapping rules include: The top-level storyboard identifier in the standardized intermediate representation data is mapped to the scene entry node logic in the abstract syntax tree (e.g., converted to a `Label start` statement), and the text content is mapped to the dialogue output logic (e.g., converted to a `Say statements` statement). The decision branch structure in the standardized intermediate representation data is mapped and converted into menu selection node logic in the abstract syntax tree (e.g., converted into `menu:` statements), and state checkpoints are automatically inserted to control the non-linear plot development. The numerical changes in the physiological state vectors in the standardized intermediate representation data are mapped and converted into variable assignment operation logic in the abstract syntax tree (such as `...`). spO 2-=5`); Based on the multimedia resource identifier in the resource tag, the corresponding front-end interface rendering layer control code is automatically injected into the abstract syntax tree. For example, the system automatically converts the matched image identifier into an image display instruction (i.e., a `show` instruction) for the front-end rendering layer, and automatically converts the audio identifier into an audio playback instruction (i.e., a `play` instruction), thereby achieving automatic insertion of UI layer code (such as a simulated monitor interface).

[0047] Step S6: In the cloud containerized environment, call the build toolchain of the target compilation engine to compile and package the target engine executable script into a cross-platform application in WebAssembly format, and automatically distribute it to the object storage system to generate access links.

[0048] In practical implementation, to address the issue of manually uploading offline .exe or .scorm packages to the server, this embodiment constructs a cloud-based containerized one-click compilation and distribution pipeline (DevOps closed loop). Specifically, it includes: An isolated container (Docker) pre-installed with the target compilation engine (such as Ren'Py SDK) software development kit and web build toolchain is dynamically launched on the backend cloud server.

[0049] Automated build instructions are executed within the isolated container to automatically compile the translated target engine executable script (.rpy) and bound multimedia resource files into a Hypertext Markup Language (HTML5) application package based on WebAssembly (WASM) technology.

[0050] The application package is automatically uploaded to the cloud object storage system (OSS) and a unique access URI (URL) and QR code are generated. The access URI is then directly pushed to the corresponding teaching management platform (LMS) through a webhook mechanism.

[0051] The final execution and feedback results of this embodiment are as follows: Based on the WebAssembly technology approach, the generated medical cases can be delivered across platforms with "zero barriers". Students do not need to install any plugins or apps. They can run the courseware smoothly on mobile / PC devices by scanning the code with WeChat or a browser.

[0052] It also provides a strong interactive feedback mechanism: for example, when a student selects "Option B" in the script above, the mobile browser's main thread immediately calls the WebGL shader via JavaScript to render a full-screen red flashing effect, and simultaneously calls the Web Audio API to play a long "beep" sound, giving the student a strong sensory stimulus; if "Option C" is selected, the system backend uses AJAX to send the student's "prudent" decision-making path data back to the teaching evaluation system, which is used to dynamically generate the student's ability radar chart (such as adding a score for the "risk assessment ability" dimension). This fully automated mechanism shortens the traditional 2-3 week development cycle to "minutes," greatly improving the production efficiency of nursing education resources.

[0053] Example 2 To further clarify the specific application process of the method described in this invention in actual medical teaching scenarios, this embodiment provides a complete case study of the automated generation and online application of an "Acute Myocardial Infarction (AMI) Emergency Triage Scenario". This embodiment strictly follows the foregoing claims and the system architecture and technical flow logic in Embodiment 1.

[0054] 1. Clinical structured data acquisition and scenario initialization phase (corresponding to step S1 above) At this stage, the user (nursing expert) defines the global variables and initial state of this teaching unit in the "Properties Panel" of the visual editor.

[0055] Specifically, the system generates corresponding Python variable objects (i.e., physiological state vectors) in the background based on expert input, including: (1) bp_sys (systolic blood pressure): The initial value is set to 100 (integer type); (2) bp_dia (diastolic pressure): The initial value is set to 60 (integer type); (3) pain_level: The initial value is set to 8 (0-10 scale); (4) is_mona_active (MONA scheme activation status): The initial value is set to False (boolean).

[0056] Meanwhile, users can enter a natural language description of the scenario in the dynamic form: "Emergency triage station, 55-year-old male patient, chief complaint of squeezing pain behind the sternum, profuse sweating, and pain on his face." 2. Logic expansion and visualization locking stage (corresponding to steps S2 to S3 above) After receiving the structured input, the system fills in a prompt template containing reasoning instructions, calls a large language model for logical expansion, and generates standardized intermediate representation data in JSON format, including node sets, edge sets, and resource tags. Subsequently, the system renders this data as a visual node flow graph for nursing experts to review. Once confirmed to be correct, a hash check is performed to lock it as the unique truth data source.

[0057] 3. Semantic-driven multimedia material binding stage (corresponding to step S4 above) The system's built-in Natural Language Processing (NLP) algorithm parses the locked intermediate representation data, extracts clinical keywords from the aforementioned natural language input, and performs automated resource matching and assembly in a pre-built multimedia knowledge graph database. (1) The keyword "emergency triage station" was identified. Retrieve and load the background resource identifier `bg_emergency_room.jpg`; (2) The keywords "sweating profusely" and "pain" were identified. Retrieve the patient's portrait layer and automatically overlay the resource identifiers `layer_sweat_drops.png` and `face_pain_agony.png`; (3) The keyword "crushing pain" was identified. Automatically suggests adding the background sound effect identifier `sfx_heartbeat_fast.mp3` (rapid heartbeat sound).

[0058] Instruction set generation feedback: The target engine converts the above mapping relationship into intermediate state instructions and renders the dynamic multimedia audiovisual image of "the patient clutching his chest and sweating profusely" in real time in the front-end preview window.

[0059] 4. Abstract Syntax Tree Logic Translation and Code Generation Stage (corresponding to step S5 above) The user drags and drops on the canvas to generate three option branches. The system's abstract syntax tree (AST) transpiler maps the standardized intermediate representation data to the AST of the target compilation engine (such as the Ren'Py engine) based on the branch attributes, automatically generating low-level script code blocks containing non-linear state machine transition logic and variable assignment logic. For the complete target engine executable script generated by the system backend and its technical annotations, please refer to [link to relevant documentation]. Figure 6 The diagram shows the executable script code of the target engine.

[0060] like Figure 6As shown, the executable script of this target engine perfectly transforms a linear medical script into a nonlinear state machine. Specifically, the script logic includes: (1) Scene and character portrait rendering logic: Automatic composite rendering instructions are used to synthesize the patient's sweating and pain effects based on the aforementioned bound resources; (2) Dynamic UI prompt logic: used to display monitor readings based on the real-time values ​​of underlying blood pressure variables; (3) Interactive logic branches representing state machine transitions: If option A "immediately take nitroglycerin sublingually" is triggered, the variable calculation of pain value decrease is executed and positive feedback sound effect is played; if option B "let the patient go to the registration window to queue" is triggered (i.e., trigger the serious error handling mechanism), the variable calculation of life value drops sharply, triggering the visual and auditory effects of red screen flashing and ECG line alarm sound, and jump to the end interface; if option C "retest blood pressure" is triggered, nested high-order logic judgment (such as conditional branch) is executed, and the decision is made on whether to give bonus logic or execute different shock treatment jump strategies based on whether the systolic blood pressure variable is lower than the safety threshold (e.g., 90 mmHg).

[0061] 5. Containerized distribution and multimodal interaction feedback effects (corresponding to step S6 above) The scripts mentioned above are compiled and packaged into a cross-platform application in WebAssembly format in a cloud-based containerized environment and then immediately released online.

[0062] (1) Execution environment: Students can directly access the courseware compiled by WebAssembly through mobile or PC browsers without installing any additional plugins.

[0063] (2) Interactive feedback response: When a student selects option B, the browser's main thread immediately invokes the WebGL shader via JavaScript to render a full-screen red flashing effect, and simultaneously calls the Web Audio API to play a long beeping alarm sound from the monitor. This mechanism reinforces the student's understanding of the nursing principle that "time is life" through strong sensory stimulation. When a student selects option C, the system backend will record the student's decision path characteristics (such as "prudent"). This log data is then transmitted back to the corresponding teaching evaluation management system in real time via AJAX asynchronous request technology, which is used to dynamically generate and update the student's ability radar chart (for example, to increase the score in the "risk assessment ability" dimension).

[0064] Example 3 Based on the same inventive concept as the aforementioned method embodiments, this embodiment provides a system for automatically generating and deploying medical scenario simulation cases. Since this system corresponds to the methods described in Embodiments 1 and 2, its specific working principle and technical effects are the same as those in the aforementioned method embodiments, and will not be repeated here.

[0065] Specifically, the automated generation and deployment system for medical scenario simulation cases provided in this embodiment includes: The data acquisition module is used to acquire clinical structured data based on dynamic forms. The clinical structured data includes clinical timeline anchors and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor, and teaching intervention node data. The logic expansion module is used to input the clinical structured data into a large language model that has been fine-tuned by the domain corpus based on a preset prompt template for logical expansion, generating standardized intermediate representation data, which includes node sets, edge sets, trigger conditions and resource tags. The integrity locking module is used to render the standardized intermediate representation data into a visual node flow graph, and after receiving a confirmation instruction, to perform a hash check on the standardized intermediate representation data to lock it as a unique truth data source. The semantic binding module is used to parse the locked standardized intermediate representation data, extract clinical keywords from the intermediate representation data using natural language processing algorithms, match the corresponding multimedia resource identifiers from the pre-set multimedia knowledge graph library, and write the multimedia resource identifiers into the resource tags to complete the material binding based on semantic analysis. The code translation module is used to map the standardized intermediate representation data after the completion of material binding into an abstract syntax tree representing the target compilation engine based on deterministic mapping rules using a preset abstract syntax tree translator. This transforms the linear time axis logic in the clinical structured data into computer-executable branching logic and serializes it into a target engine executable script. The compilation and distribution module is used to call the build toolchain of the target compilation engine in a cloud containerized environment, compile and package the target engine's executable script into a cross-platform application in WebAssembly format, and automatically distribute it to an object storage system to generate access links.

[0066] It should be noted that the system described in this embodiment can be implemented in software form using computer program instruction sets, or in hardware form (such as Application-Specific Integrated Circuits (ASICs), Field-Programmable Gate Arrays (FPGAs), or a combination of software and hardware. The above division of modules is only a logical functional division. In practical applications, they can be partially or completely integrated into a single physical entity, or they can be physically separated.

[0067] Based on the same inventive concept, embodiments of the present invention also provide an electronic device that can implement the automated generation and online deployment method for medical scenario simulation cases provided in the above embodiments of the present invention. In one embodiment, the electronic device can be a server, a terminal device, or other electronic devices. Figure 7 As shown, the electronic device may include: At least one processor and a memory connected to the at least one processor. In this embodiment of the invention, the specific connection medium between the processor and the memory is not limited. Figure 7 The example used is the connection between the processor and memory via a bus. The bus... Figure 7 The connections between other components are indicated by thick lines and are for illustrative purposes only, not as limiting information. Buses can be divided into address buses, data buses, control buses, etc., but for ease of representation, [the specific bus type is not shown here]. Figure 7 The processor is represented by a single thick line, but this does not imply that there is only one bus or one type of bus. Alternatively, a processor can also be called a controller; there are no restrictions on the name.

[0068] In this embodiment of the invention, the memory stores instructions executable by at least one processor. By executing the instructions stored in the memory, the at least one processor can perform the aforementioned method for automatically generating and deploying medical scenario simulation cases. The processor can implement... Figure 7 The functions of each module in the device shown.

[0069] The processor is the control center of the device. It can connect to various parts of the control equipment through various interfaces and lines. By running or executing instructions stored in memory and calling data stored in memory, it can monitor the various functions and data processing of the device as a whole.

[0070] In an alternative design, the processor may include one or more processing units. The processor may integrate an application processor and a modem processor, wherein the application processor primarily handles the operating system, user interface, and applications, while the modem processor primarily handles wireless communication. It is understood that the modem processor may also not be integrated into the processor. In some embodiments, the processor and memory may be implemented on the same chip; in some embodiments, they may also be implemented separately on separate chips.

[0071] The processor can be a general-purpose processor, such as a CPU, digital signal processor, application-specific integrated circuit, field-programmable gate array or other programmable logic device, discrete gate or transistor logic device, or discrete hardware component, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this invention. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method for automatically generating and deploying medical scenario simulation cases disclosed in the embodiments of this invention can be directly manifested as execution by a hardware processor, or execution by a combination of hardware and software modules within the processor.

[0072] Memory, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. Memory can include at least one type of storage medium, such as flash memory, hard disk, multimedia cards, card-type memory, random access memory (RAM), static random access memory (SRAM), programmable read-only memory (PROM), read-only memory (ROM), and electrically erasable programmable read-only memory (EPROM). Only memory (EEPROM), magnetic storage, magnetic disks, optical disks, etc. A memory is any other medium capable of carrying or storing desired program code in the form of instructions or data structures, and accessible by a computer, but is not limited thereto. The memory in embodiments of this invention can also be a circuit or any other device capable of performing storage functions for storing program instructions and / or data.

[0073] By designing and programming the processor, the code corresponding to the automated generation and deployment method of a medical scenario simulation case described in the foregoing embodiments can be embedded into the chip, enabling the chip to execute the steps of the method described in the foregoing embodiments during runtime. How to design and program the processor is a technique well-known to those skilled in the art and will not be elaborated upon here.

[0074] Based on the same inventive concept, embodiments of the present invention also provide a storage medium storing computer instructions that, when executed on a computer, cause the computer to perform a method for automatically generating and deploying medical scenario simulation cases as described above.

[0075] In some alternative embodiments, the present invention also provides a method for the automated generation and deployment of medical scenario simulation cases, which can also be implemented as a program product including program code. When the program product is run on a device, the program code is used to cause the control device to perform the steps in the method for the automated generation and deployment of medical scenario simulation cases according to various exemplary embodiments of the present invention as described above.

[0076] It should be noted that although several units or sub-units of the apparatus have been mentioned in the detailed description above, this division is merely exemplary and not mandatory. In fact, according to embodiments of the invention, the features and functions of two or more units described above can be embodied in one unit. Conversely, the features and functions of one unit described above can be further divided and embodied by multiple units. Furthermore, although the operation of the method of the invention is described in a specific order in the drawings, this does not require or imply that these operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0077] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media containing computer-usable program code.

[0078] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a server, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0079] Program code for performing the operations of this invention can be written using any combination of one or more programming languages, including object-oriented programming languages ​​such as Java and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computing device, partially on the user's device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0080] In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).

[0081] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0082] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0083] The embodiments described above merely illustrate specific implementation methods of this application, and while the descriptions are detailed and specific, they should not be construed as limiting the scope of protection of this application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the technical solution of this application, and these modifications and improvements all fall within the scope of protection of this application.

[0084] This background section is provided to generally present the context of the invention. The work of the currently named inventors, the work to the extent described in this background section, and aspects of this section that did not constitute prior art at the time of application are neither expressly nor impliedly acknowledged as prior art to the invention.

Claims

1. A method for automatically generating and deploying medical scenario simulation cases, characterized in that, include: Acquire clinical structured data based on dynamic form collection. The clinical structured data includes clinical timeline anchor points and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor point, and teaching intervention node data. Based on the preset prompt template, the clinical structured data is input into the large language model for logical expansion to generate standardized intermediate representation data, which includes node set, edge set, trigger conditions and resource tags. The standardized intermediate representation data is rendered into a visual node flow graph, and upon receiving a confirmation instruction, a data integrity check is performed on the standardized intermediate representation data to lock it as a unique truth data source. The standardized intermediate representation data after locking is parsed, and clinical keywords are extracted from the intermediate representation data using natural language processing algorithms. The corresponding multimedia resource identifiers are matched from the pre-set multimedia knowledge graph library, and the multimedia resource identifiers are written into the resource tags to complete the material binding based on semantic analysis. Using a pre-defined abstract syntax tree translator, based on deterministic mapping rules, the standardized intermediate representation data after the completion of material binding is mapped to an abstract syntax tree representing the target compilation engine's nonlinear state machine, so as to transform the linear time axis logic in the clinical structured data into computer-executable branch jump logic and serialize it into a target engine executable script. In a cloud-based containerized environment, the build toolchain of the target compilation engine is invoked to compile and package the target engine's executable script into a cross-platform web application, and automatically distribute it to an object storage system to generate access links.

2. The method for automatically generating and deploying medical scenario simulation cases according to claim 1, characterized in that, Acquiring structured clinical data based on dynamic form collection, specifically including: Obtain multiple discrete clinical timeline anchor points defined on the timeline, and record the clinical event data associated with each anchor point; Obtain the physiological state vector matrix corresponding to each of the clinical time axis anchor points, wherein the physiological state vector matrix consists of numerical vectors including at least body temperature, pulse, respiration, blood pressure, blood oxygen saturation and pain score; Obtain the preset teaching intervention node data, which includes mandatory operation instructions that trigger teaching assessments.

3. The method for automatically generating and deploying medical scenario simulation cases according to claim 2, characterized in that, The large language model is a large language model fine-tuned from a domain corpus; the step of inputting the clinical structured data into the large language model based on a preset prompt template for logical expansion to generate standardized intermediate representation data specifically includes: The clinical structured data is filled into a prompt template containing thought chain reasoning instructions. The thought chain reasoning instructions guide the large language model to deduce step by step according to the clinical logic chain to avoid skipping generation and construct target prompt words. The target prompt words are input into the large language model, and the large language model expands the text description information, vital sign change logic and decision branch options based on the fine-tuned corpus. The expanded logical data is structured and output as standardized intermediate representation data based on JSON format. The standardized intermediate representation data is strictly divided into node objects, edge objects, condition triggering mechanisms, and resource tags.

4. The method for automatically generating and deploying medical scenario simulation cases according to claim 1, characterized in that, The standardized intermediate representation data is rendered into a visual node flow graph, and upon receiving a confirmation instruction, a hash check is performed on the standardized intermediate representation data to lock it as a unique truth data source, including: The standardized intermediate representation data's node and edge objects are parsed and rendered into a visual logical topology graph on the front end. In response to edit operations on the logical topology graph, the standardized intermediate representation data at the underlying level is updated synchronously. Upon receiving the confirmation lock command, the core feature string representing medical logic in the updated standardized intermediate representation data is extracted and hashed to generate a unique hash value; The node set, edge set, and triggering conditions in the standardized intermediate representation data carrying the unique hash value are marked as locked to prevent tampering, and the resource tags are reserved as writable states that allow the system to automatically fill them in, serving as the unique truth data source for subsequent code translation.

5. The method for automatically generating and deploying medical scenario simulation cases according to claim 4, characterized in that, Clinical keywords are extracted from the intermediate representation data using natural language processing algorithms. Corresponding multimedia resource identifiers are matched from a pre-built multimedia knowledge graph database, and these identifiers are written into the resource tags. Specifically, this includes: The text fields in the standardized intermediate representation data are traversed, and natural language processing technology is used for word segmentation and entity recognition to extract clinical keywords that characterize symptoms, environment, or equipment status. Search the multimedia knowledge graph database containing the mapping relationship between medical entities and multimedia to obtain audio or image identifiers that semantically match the clinical keywords; The matched audio or image identifiers are inserted as instruction parameters into the corresponding node resource tags of the standardized intermediate representation data.

6. The method for automatically generating and deploying medical scenario simulation cases according to claim 1, characterized in that, Using a pre-defined abstract syntax tree transpiler, based on deterministic mapping rules, the standardized intermediate representation data after the material binding is completed is mapped to an abstract syntax tree representing the target compilation engine's nonlinear state machine. The deterministic mapping rules specifically include: The decision branch structure in the standardized intermediate representation data is mapped and converted into menu selection node logic in the abstract syntax tree; The numerical changes of the physiological state vectors in the standardized intermediate representation data are mapped and converted into variable assignment operation logic in the abstract syntax tree; Based on the multimedia resource identifier in the resource tag, the corresponding front-end interface rendering layer control code is automatically injected into the abstract syntax tree.

7. The method for automatically generating and deploying medical scenario simulation cases according to claim 1, characterized in that, In a cloud-based containerized environment, the build toolchain of the target compilation engine is invoked to compile and package the target engine's executable scripts into a cross-platform application in WebAssembly format, and automatically distributed to an object storage system to generate access links, including: An isolated container pre-installed with the target compilation engine software development kit is dynamically launched on a cloud server; Automated build instructions are executed within the isolated container to compile the target engine's executable script and bound multimedia resource files into a Hypertext Markup Language application package based on WebAssembly technology; The application package is automatically uploaded to the cloud object storage system and a unique Uniform Resource Locator (URL) is generated. The URL is then pushed to the corresponding teaching management platform via a network hook mechanism.

8. A system for automatically generating and deploying medical scenario simulation cases, characterized in that, include: The data acquisition module is used to acquire clinical structured data based on dynamic forms. The clinical structured data includes clinical timeline anchors and their associated clinical event data, physiological state vector matrices corresponding to each clinical timeline anchor, and teaching intervention node data. The logic expansion module is used to input the clinical structured data into the large language model for logical expansion based on the preset prompt template, and generate standardized intermediate representation data, which includes node set, edge set, trigger condition and resource tag; The integrity locking module is used to render the standardized intermediate representation data into a visual node flow graph, and after receiving a confirmation instruction, to perform data integrity verification on the standardized intermediate representation data to lock it as a unique truth data source. The semantic binding module is used to parse the locked standardized intermediate representation data, extract clinical keywords from the intermediate representation data using natural language processing algorithms, match the corresponding multimedia resource identifiers from the pre-set multimedia knowledge graph library, and write the multimedia resource identifiers into the resource tags to complete the material binding based on semantic analysis. The code translation module is used to map the standardized intermediate representation data after the material binding is completed to the abstract syntax tree of the target compilation engine, which represents the nonlinear state machine, using a preset abstract syntax tree translator based on deterministic mapping rules. This transforms the linear time axis logic in the clinical structured data into computer-executable branching logic and serializes it into a target engine executable script. The compilation and distribution module is used to call the build toolchain of the target compilation engine in a cloud-based containerized environment, compile and package the target engine's executable script into a cross-platform web application, and automatically distribute it to an object storage system to generate access links.

9. An electronic device, characterized in that, include: At least one processor; and a memory communicatively connected to the at least one processor; The memory stores instructions executable by the at least one processor, which executes the instructions stored in the memory to perform the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium is used to store instructions that, when executed, cause the method as described in any one of claims 1-7 to be implemented.