Personalized children psychological intervention scheme generation method and device, equipment and medium

By using multimodal data analysis and narrative element mapping technology, personalized psychological intervention plans for children are generated, which solves the problem of traditional intervention plans lacking personalization and dynamism, and improves the effectiveness and participation of children's psychological intervention.

CN121460084APending Publication Date: 2026-02-03SHENZHEN CHILDRENS HOSPITAL
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511571834.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-30
Publication Date
2026-02-03

AI Technical Summary

Technical Problem

Traditional child psychological intervention programs neglect the narrative characteristics of children's psychological problems, fail to transform individualized behavioral characteristics into individualized therapeutic narratives, and the resulting intervention programs lack dynamism and personalization.

Method used

By collecting multimodal data from children, analyzing their psychological states using multimodal fusion neural networks, generating dynamic psychological state time series, and combining narrative element mapping models and natural language generation technology, personalized problem story texts are constructed. Furthermore, by optimizing the sequence of intervention steps through reinforcement learning, personalized psychological intervention plans are generated.

Benefits of technology

It enabled the generation of personalized psychological intervention programs for children, improved children's willingness to participate and the effectiveness of intervention, and met children's cognitive characteristics and individual needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121460084A_ABST
    Figure CN121460084A_ABST
Patent Text Reader

Abstract

The invention relates to a personalized child psychological intervention scheme generation method and device, equipment and a medium. According to the method, a multi-modal feature sequence is constructed by synchronously collecting facial expressions, voice signals and physiological data of children, psychological states are analyzed through a multi-modal fusion neural network to form a dynamic time sequence, and then psychological fluctuations are converted into structured narrative elements through a narrative element mapping model. According to the method, a problem story text conforming to cognitive characteristics of children is generated in combination with personalized information of the children, finally, an optimal narrative framework is matched to construct basic intervention steps, and a technical path for converting psychological characteristic data of the children into a personalized narrative intervention scheme is formed by applying reinforcement learning to optimize a step sequence. The transformation from mechanical task execution to story growth experience is realized, and the participation willingness and intervention effect of children are remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of data intelligent analysis technology, and in particular relates to a method, device, equipment and medium for generating personalized children's psychological intervention programs. Background Technology

[0002] In the field of child mental health intervention, traditional intervention program generation methods mainly rely on standardized assessment scales and pre-set intervention templates. These methods collect data through questionnaires or simple behavioral observations, simplifying children's complex psychological states into discrete emotional labels, and then matching general intervention strategies from a pre-set program library based on diagnostic results. This approach has three fundamental flaws: First, it ignores the narrative characteristics of children's psychological problems—each child's distress is rooted in their unique life experiences and emotional experiences, and current technology cannot capture this evolution of psychological states embedded in personal life stories; second, the generated intervention programs are often static task lists, which do not conform to children's cognitive characteristics of understanding the world through storytelling; and finally, it lacks the ability to deeply analyze individual differences among children, failing to transform personalized behavioral characteristics into personalized therapeutic narratives. Summary of the Invention

[0003] Therefore, it is necessary to provide a method, device, equipment, and medium for generating personalized children's psychological intervention programs to address the aforementioned technical problems.

[0004] Firstly, this application provides a method for generating personalized child psychological intervention programs, including:

[0005] S1. Collect multimodal data of children, extract features from the multimodal data, and obtain multimodal feature sequences; among which, multimodal data includes facial expression videos, speech signals, and physiological data;

[0006] S2. Based on multimodal feature sequences, psychological state analysis is performed through a multimodal fusion neural network model to generate dynamic psychological state time series;

[0007] S3. Based on the dynamic psychological state time series, narrative elements are identified through a pre-trained narrative element mapping model to generate a structured narrative element set;

[0008] S4. Based on a set of structured narrative elements and children's personalized information, personalized problem story texts are generated through a natural language generation model;

[0009] S5. Based on personalized problem story texts and a set of structured narrative elements, match the best narrative framework from the narrative prototype library and generate a basic intervention step sequence based on the best narrative framework.

[0010] S6. By optimizing the sequence of basic intervention steps through reinforcement learning, a multi-step therapeutic intervention path is obtained, which serves as a personalized psychological intervention plan for children.

[0011] Secondly, this application also provides a personalized child psychological intervention program generation device for implementing the method described in the first aspect, the device comprising:

[0012] The multimodal data acquisition and feature extraction module is used to collect multimodal data of children, extract features from the multimodal data, and obtain multimodal feature sequences; the multimodal data includes facial expression videos, speech signals, and physiological data;

[0013] The multimodal psychological state analysis module is used to perform psychological state analysis based on multimodal feature sequences and through a multimodal fusion neural network model to generate dynamic psychological state time series.

[0014] The narrative element parsing and structuring module is used to identify narrative elements based on dynamic psychological state time series through a pre-trained narrative element mapping model and generate a set of structured narrative elements.

[0015] The personalized question story generation module is used to generate personalized question story texts based on a set of structured narrative elements and children's personalized information, using a natural language generation model.

[0016] The narrative framework matching and intervention step generation module is used to match the best narrative framework from the narrative prototype library based on personalized problem story text and a set of structured narrative elements, and generate a basic sequence of intervention steps based on the best narrative framework.

[0017] The intervention path optimization and program generation module is used to optimize the step sequence of the basic intervention steps through reinforcement learning to obtain a multi-step therapeutic intervention path as a personalized child psychological intervention program.

[0018] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement a method for generating a personalized child psychological intervention program as described in the first aspect.

[0019] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a method for generating a personalized child psychological intervention program as described in the first aspect.

[0020] The aforementioned method, device, equipment, and medium for generating personalized children's psychological intervention programs construct multimodal feature sequences by simultaneously collecting children's facial expressions, voice signals, and physiological data. A multimodal fusion neural network is then used to analyze psychological states to form dynamic time series. Furthermore, a narrative element mapping model transforms psychological fluctuations into structured narrative elements. Combined with children's personalized information, problem-story texts that align with their cognitive characteristics are generated. Finally, the optimal narrative framework is matched to construct basic intervention steps, and reinforcement learning is applied to optimize the step sequence. This forms a technical path that transforms children's psychological characteristic data into personalized narrative intervention programs, achieving a shift from mechanical task execution to story-based growth experiences, significantly improving children's willingness to participate and the effectiveness of interventions. Attached Figure Description

[0021] To more clearly illustrate the technical solutions in the embodiments or related technologies of this application, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0022] Figure 1 A flowchart illustrating a method for generating personalized child psychological intervention programs provided by the present invention;

[0023] Figure 2 This is a schematic diagram of a personalized child psychological intervention program generation device provided by the present invention. Detailed Implementation

[0024] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0025] refer to Figure 1 The application presents a flowchart illustrating a method for generating personalized child psychological intervention programs, which includes the following steps:

[0026] S1. Collect multimodal data of children, extract features from the multimodal data, and obtain multimodal feature sequences; among which, multimodal data includes facial expression videos, voice signals and physiological data.

[0027] Specifically, facial expression videos are recorded in natural environments using high-definition cameras, capturing subtle changes in children's expressions. Voice signals are collected via microphones, recording characteristics such as tone of voice and speech rate. Physiological data is collected through wearable devices, including indicators such as heart rate, skin conductance, and respiratory rate, reflecting children's physiological responses in different situations.

[0028] After collecting multimodal data, feature extraction is performed on this data. Feature extraction of facial expression videos can use convolutional neural networks (CNNs) in deep learning to identify key points of facial expressions, such as eyebrows, eyes, and corners of the mouth, through pre-trained models, and extract the motion features of these key points. Feature extraction of speech signals can use Mel-frequency cepstral coefficients (MFCCs) and speech emotion features, extracting emotional features of speech through short-time Fourier transform (STFT) and deep learning models. Feature extraction of physiological data is performed through signal processing techniques, such as filtering and normalization, to extract features such as heart rate variability and skin conductance response.

[0029] Finally, these features are integrated into a multimodal feature sequence, where each feature point contains comprehensive information from facial expressions, speech, and physiological data.

[0030] S2. Based on multimodal feature sequences, psychological state analysis is performed through a multimodal fusion neural network model to generate dynamic psychological state time series.

[0031] Specifically, when performing psychological state analysis, multimodal feature sequences are input into a multimodal fusion neural network model. This model can adopt an architecture that combines convolutional neural networks (CNNs) and recurrent neural networks (RNNs). This architecture can leverage the advantages of CNNs in processing spatial data (such as spectrograms of facial expressions and speech signals) and the advantages of RNNs in processing time-series data (such as physiological data and temporal variations of speech signals).

[0032] In this model, the CNN part first extracts features from the spectrograms of the input facial expressions and speech signals. Through multiple layers of convolution and pooling operations, local features in the images and spectrograms are captured and mapped into a high-dimensional space. These high-dimensional feature vectors are then passed to the RNN part, which is responsible for processing the time-series features of the physiological data. Long Short-Term Memory (LSTM) units or Gated Recurrent Units (GRUs) in the RNN network process and predict long-term dependencies in the time-series data. In this model, the LSTM units selectively retain or discard information through a gating mechanism, thereby dynamically updating the state at each time step of the time series. This mechanism enables the model to capture the trends in physiological data at different time points and the potential connections between these changes and psychological states.

[0033] To further improve model performance, the fusion layer of this model can employ an attention mechanism. This mechanism allows the model to dynamically assign different weights to different modal features when processing multimodal data. In this way, the model automatically focuses on the features most critical to the current analysis task at different time points or in different psychological state analysis scenarios. For example, when analyzing children's anxiety, the model pays more attention to heart rate changes in physiological data and the tension level in speech signals, while when analyzing children's happiness, it pays more attention to smile features in facial expressions and cheerful tone in speech signals. In this way, the model can more accurately extract psychological state-related information from the multimodal feature sequence and generate a dynamic psychological state time series. This time series not only reflects the child's psychological state at different time points but also captures the trend of psychological state changes over time, providing a rich information foundation for subsequent narrative element recognition.

[0034] During model training, professionally labeled multimodal data is used. This data covers children of different ages, genders, and mental states, ensuring the model's generalization ability and accuracy. Supervised learning is employed during training to optimize model parameters by minimizing the difference between the model's predicted mental states and the actual labeled mental states. Specifically, the cross-entropy loss function is used to measure the difference between predicted and true values, and the backpropagation algorithm is used to update the model's weights.

[0035] After training, the model can automatically analyze children's psychological states from the input multimodal feature sequences and output the results in the form of a time series. This dynamic psychological state time series provides a basis for subsequent narrative element identification and personalized intervention program generation.

[0036] S3. Based on the dynamic psychological state time series, narrative elements are identified through a pre-trained narrative element mapping model to generate a structured narrative element set.

[0037] Specifically, the narrative element mapping model can be based on the sequence-to-sequence (Seq2Seq) architecture in deep learning, which is widely used in tasks such as machine translation and text summarization in natural language processing. In this invention, the Seq2Seq model is used for narrative element recognition of mental states.

[0038] In the model, the encoder receives a dynamic time series of mental states as input, consisting of multiple time steps, each containing mental state features extracted from multimodal data. The encoder encodes the input sequence using a recurrent neural network (RNN) or its variant LSTM / GRU, progressively compressing the information in the sequence into a fixed-length context vector. This context vector is a high-dimensional representation of the input sequence, containing key information from the entire time series.

[0039] Specifically, assuming the input dynamic psychological state time series is Where T is the length of the time series, each This is the feature vector of the mental state at time step t. The encoder encodes the input sequence using an RNN / LSTM / GRU network to generate the hidden state sequence. and the final context vector Taking LSTM as an example, its update formula is as follows:

[0040]

[0041]

[0042]

[0043]

[0044]

[0045]

[0046] in, , , These are the activation values ​​of the input gate, forget gate, and output gate, respectively. It is the value of the candidate memory unit. It is the value of the memory unit. It is the value of the hidden state. , , , It is a weight matrix. , , , It is a recursive weight matrix. , , , σ is the bias vector, σ is the Sigmoid activation function, and tanh is the hyperbolic tangent activation function.

[0047] The final context vector generated by the encoder is .

[0048] The decoder generates a structured set of narrative elements based on the context vector c. The decoder can also use RNN / LSTM / GRU networks, but at each time step, it not only depends on the output and hidden state of the previous time step, but also dynamically focuses on the information in the context vector most relevant to the currently generated narrative element through an attention mechanism. The introduction of the attention mechanism allows the decoder to extract information from the context vector more flexibly, thereby generating more accurate and relevant narrative elements.

[0049] Specifically, assume the hidden state of the decoder at time step t is The attention mechanism calculates the part of the context vector c that is most relevant to the current decoding state. The formula is as follows:

[0050]

[0051]

[0052]

[0053] in, The decoder hides the encoder's state at time step t. Unnormalized attention score These are the normalized attention weights. It is the weighted context vector. , is the weight matrix, v is the attention vector, and b is the bias vector.

[0054] The LSTM update formula for the decoder is as follows:

[0055]

[0056]

[0057]

[0058]

[0059]

[0060]

[0061] in, It is the decoder output at time step t−1. It is the hidden state of the decoder at time step t. It is the value of the decoder's memory cell at time step t. , , , It is a weight matrix. , , , It is a recursive weight matrix. , , , It is the bias vector.

[0062] Ultimately, the decoder generates the following set of narrative elements: .in, It is the length of the narrative element sequence generated by the decoder.

[0063] When training the narrative element mapping model, labeled data is used. This data includes time series of dynamic psychological states and their corresponding sets of narrative elements. The labeling is performed by professional psychologists and linguists to ensure the accuracy and reliability of the data. The model is trained by minimizing the difference between the predicted set of narrative elements and the true labeled set. Specifically, a sequence-level loss function, such as the cross-entropy loss function, is used to measure the difference between the predicted and true values, and the model parameters are updated using a backpropagation algorithm. The formula for the cross-entropy loss function is:

[0064]

[0065] in, These are the values ​​of the true label at time step t and category k. It is the probability value of the label predicted by the model at time step t and category k, where K is the number of categories of the narrative element.

[0066] During training, regularization techniques, such as Dropout, can be used to prevent overfitting. Furthermore, to further improve model performance, decoding strategies such as Beam Search can be employed to explore multiple possible candidate sequences when generating narrative elements, thereby selecting the most likely set of narrative elements.

[0067] Ultimately, the trained narrative element mapping model can transform dynamic psychological state time series into a structured set of narrative elements. Each narrative element has a clear semantic meaning, such as emotional state (e.g., happiness, sadness, anxiety), behavioral manifestation (e.g., withdrawal, aggression, cooperation), and contextual background (e.g., family environment, school life, social occasions). These narrative elements are organized in a structured form to form a narrative framework that comprehensively reflects children's psychological states. This structured set of narrative elements provides the foundation for the subsequent generation of personalized problem story texts, enabling the presentation of children's psychological problems in a story-like manner, thus better aligning with children's cognitive characteristics and ways of understanding.

[0068] S4. Based on a set of structured narrative elements and children's personalized information, personalized problem story texts are generated through a natural language generation model.

[0069] Specifically, the natural language generation model can adopt a deep learning-based sequence-to-sequence (Seq2Seq) architecture, combined with attention mechanisms and conditional generation techniques. This model consists of an encoder, a decoder, and a conditional embedding module. The encoder is responsible for encoding a set of structured narrative elements and personalized information about the child into context vectors, while the decoder generates personalized text stories based on these context vectors.

[0070] The encoder receives a set of structured narrative elements. The child's personalized information P is used as input. The set of structured narrative elements E is a sequence, where each... It is a narrative element that includes information such as emotional state, behavioral performance, and contextual background. The child's personalized information P can include information such as age, gender, and family background.

[0071] The encoder first assigns each narrative element The personalized information P is embedded into a high-dimensional space to form an embedding vector. and The embedding process uses a pre-trained embedding matrix. and accomplish:

[0072]

[0073]

[0074] Then, the encoder will embed the sequence of narrative elements. and personalized information As input, it is encoded through a bidirectional LSTM network. The bidirectional LSTM can capture both forward and backward dependencies in the sequence, generating a hidden state sequence. and the final context vector .

[0075]

[0076]

[0077]

[0078]

[0079] in, and These are the hidden states of the forward and reverse LSTM, respectively. This is the final hidden state of the bidirectional LSTM. It is the context vector generated by the encoder.

[0080] The decoder's task is to analyze the context vector generated by the encoder. and personalized information Generate personalized text stories. The decoder employs a unidirectional LSTM network and incorporates an attention mechanism at each time step to dynamically monitor the hidden state sequence G generated by the encoder.

[0081] The hidden state of the decoder at each time step t and output The update formula is as follows:

[0082]

[0083]

[0084]

[0085]

[0086]

[0087] in, The decoder hides the encoder's state at time step t. Unnormalized attention score These are the normalized attention weights. It is the weighted context vector. , is the weight matrix, z is the attention vector, and r is the bias vector. and These are the weight matrix and bias vector of the output layer.

[0088] To ensure that the generated text stories reflect children's personalized information, a conditional embedding module is introduced into the model. This module incorporates personalized information. Embedded into each time step of the decoder. Specifically, personalized information. Input added to the decoder and context vector middle:

[0089]

[0090]

[0091] When training the natural language generation model, labeled data was used, including a set of structured narrative elements, children's personalized information, and their corresponding personalized question-and-answer story texts. The training process employed supervised learning, optimizing model parameters by minimizing the difference between the predicted and the actually labeled text stories. Specifically, the cross-entropy loss function was used to measure the difference between the predicted and actual values, and the model parameters were updated using backpropagation.

[0092] When generating personalized question story text, the decoder starts from an initial hidden state. and initial context vector Begin by generating the text story step by step. At each time step t, the decoder calculates the current hidden state. and weighted context vector Generate the next word The generated words It is used as input for the next time step until the generated text story reaches the preset length or encounters an end marker.

[0093] Ultimately, the generated personalized problem story texts can reflect children's psychological state and individual information in a story-like manner, providing an important foundation for the generation of subsequent intervention plans.

[0094] S5. Based on personalized problem story texts and a set of structured narrative elements, the best narrative framework is matched from the narrative prototype library, and a basic sequence of intervention steps is generated based on the best narrative framework.

[0095] Specifically, the Narrative Prototype Library is a database that stores various predefined narrative frameworks. Each framework contains a series of intervention steps and story elements, categorized according to different psychological problems and intervention goals. For example, a narrative framework for anxiety might include intervention steps such as relaxation training and cognitive restructuring, while a framework for social phobia might include steps such as social skills training and exposure therapy.

[0096] Each narrative framework also includes related story elements, such as context, character settings, and plot development. These story elements help generate personalized stories that match the child's psychological state. The narrative prototype library was built based on the knowledge and experience of psychology experts, as well as extensive clinical case analysis.

[0097] To match the best narrative framework from the narrative prototype library, the similarity between the personalized problem story text and the structured set of narrative elements and each narrative framework in the library is first calculated. Similarity calculation can be performed using various methods, such as cosine similarity, Jaccard similarity, etc.

[0098] Assume the personalized problem story text is S, the set of structured narrative elements is E, and the i-th narrative frame in the narrative prototype library is... Its collection of story elements is The similarity calculation formula is as follows:

[0099]

[0100]

[0101] in, It is a personalized problem story text S and narrative framework cosine similarity, It is the set of structured narrative elements E and the set of story elements in the narrative framework. Jaccard similarity.

[0102] Choose the narrative framework with the highest similarity as the best narrative framework. :

[0103]

[0104] After matching the best narrative framework Then, a basic sequence of intervention steps is generated based on this framework. Each intervention step corresponds to a specific psychological intervention goal and method, such as emotion regulation or behavior correction. The generation of the basic sequence of intervention steps is achieved through a rule engine, which generates specific intervention steps based on the rules and logic in the narrative framework.

[0105] Assuming the optimal narrative framework The set of intervention steps included is Each intervention step There is a corresponding rule for each. The rule engine generates a basic sequence of intervention steps based on these rules. The rules engine works as follows:

[0106] 1) Initialization: Set the current intervention step sequence as follows .

[0107] 2) Traverse the set of intervention steps: For each intervention step According to the rules Check if the execution conditions are met. (Rules) It may include examinations of children's psychological state, behavior, etc.

[0108] 3) Generate intervention steps: If the conditions are met, then generate the intervention steps. Add to middle.

[0109] 4) Update status: Based on the intervention steps The results of the implementation are used to update children's mental state and behavioral performance.

[0110] 5) Generate the final sequence: Repeat the above process until all intervention steps have been checked and the corresponding intervention step sequence has been generated. .

[0111] S6. By optimizing the sequence of basic intervention steps through reinforcement learning, a multi-step therapeutic intervention path is obtained, which serves as a personalized psychological intervention plan for children.

[0112] Specifically, a reinforcement learning model includes an agent and an environment. The agent's goal is to find the optimal sequence of intervention steps through trial and error to maximize long-term rewards. The environment then rewards or punishes the agent based on changes in the child's psychological state and the achievement of the intervention goal.

[0113] The agent receives the basic intervention step sequence As input, and through a policy network, the order of each intervention step is determined, where The length of the basic intervention sequence is the number of steps contained in the generated intervention sequence. The policy network is a deep neural network whose output is a probability distribution representing the probability of selecting different intervention steps at each time step.

[0114] The policy network can be structured using a multilayer perceptron (MLP) or a recurrent neural network (RNN). Assume the input to the policy network is the current sequence of intervention steps. Given the current mental state s, the output of the policy network is a probability distribution. This indicates the intervention step to be selected in the current state s. The probability of.

[0115] The environment simulates the child's psychological state based on the sequence of intervention steps selected by the agent, and provides rewards or punishments according to the achievement of the intervention goals. Environmental feedback includes changes in psychological state and the achievement of intervention goals. The reward function R rewards the agent based on the achievement of the intervention goals; for example, if the intervention steps effectively improve the child's psychological state, the environment provides a positive reward; if the intervention steps are ineffective or have a negative impact, the environment provides a negative reward. The intervention effect can be judged based on changes in emotional state, behavioral performance, and physiological responses.

[0116] The reinforcement learning process optimizes the sequence of intervention steps through trial and error. The specific steps are as follows:

[0117] 1) Initialization: The agent receives the basic intervention step sequence. and initial psychological state .

[0118] 2) Selecting an intervention step: The agent selects an intervention step based on the policy network π. :

[0119]

[0120] 3) Implementing intervention steps: The environment is determined based on the selected intervention steps. Update your mental state arrive And give the reward according to the reward function R. .

[0121] 4) Update the policy network: The agent updates the policy network based on the reward. Update the parameters of the policy network to increase the probability of selecting an effective intervention step. Updating the policy network parameters can be done using policy gradient methods, such as the REINFORCE algorithm.

[0122]

[0123] Where N is the number of samples, θ is the parameter of the policy network, and J(θ) is the objective function, representing the agent's expected long-term reward. This represents the intervention step taken at time t in the i-th sampling. This represents the psychological state at time t in the i-th sampling. This represents the reward value at time t in the i-th sampling.

[0124] Repeat the above process: The agent repeats the above process until the policy network converges. The generated sequence of intervention steps can effectively improve the child's psychological state and achieve the intervention goal.

[0125] When training the reinforcement learning model, simulated data is used, including different sequences of basic intervention steps, initial mental states, and intervention goals. By simulating different intervention scenarios, the agent can learn strategies for selecting the optimal sequence of intervention steps under different conditions. During training, the agent continuously adjusts the parameters of the policy network through trial and error learning to improve the probability of selecting effective intervention steps. The training process employs policy gradient methods, such as the REINFORCE algorithm, to update the parameters of the policy network by maximizing long-term rewards.

[0126] In generating the optimal multi-step therapeutic intervention pathway, the agent starts from the basic intervention step sequence. Initially, intervention steps are selected incrementally. At each time step t, the agent selects an intervention step based on the policy network π. And update your mental state based on feedback from the environment. and rewards The agent repeats this process until the generated sequence of intervention steps reaches a preset length or the termination condition is met.

[0127] Ultimately, the generated multi-step therapeutic intervention pathway It can dynamically adjust the order of intervention steps according to the child's psychological state, ensuring the effectiveness and personalization of the intervention plan.

[0128] The aforementioned method for generating personalized child psychological intervention programs involves simultaneously collecting children's facial expressions, voice signals, and physiological data to construct a multimodal feature sequence. A multimodal fusion neural network is then used to analyze psychological states, forming a dynamic time series. Furthermore, a narrative element mapping model transforms psychological fluctuations into structured narrative elements. Combined with children's personalized information, problem-story texts that align with their cognitive characteristics are generated. Finally, the optimal narrative framework is matched to construct basic intervention steps, and reinforcement learning is applied to optimize the step sequence. This forms a technical path that transforms children's psychological characteristic data into personalized narrative intervention programs, achieving a shift from mechanical task execution to a story-based growth experience, significantly improving children's willingness to participate and the effectiveness of interventions.

[0129] In one optional embodiment, based on multimodal feature sequences, psychological state analysis is performed using a multimodal fusion neural network model to generate a dynamic psychological state time series vector, including the following steps:

[0130] S11. Based on the video frame sequence of the facial region in the multimodal feature sequence, the spatiotemporal expression change features are extracted by a three-dimensional convolutional neural network to obtain the video feature vector.

[0131] Specifically, video frame sequences containing facial expressions are extracted from the multimodal feature sequence. These video frame sequences undergo preprocessing, including cropping to ensure only facial regions are included, adjusting frame sizes to match network input requirements, and normalizing pixel values ​​to reduce the impact of lighting conditions. The preprocessed video frame sequences are then fed into a three-dimensional convolutional neural network (3DCNN). Each layer of the 3DCNN contains convolutional kernels that slide along the temporal and spatial dimensions to extract spatiotemporal features of facial expressions. Each layer of the network produces higher-level feature representations that capture subtle changes in facial expressions, such as eyebrow movement and the upward curve of the corners of the mouth. After multiple convolutional and pooling operations, the 3DCNN outputs a video feature vector that encapsulates the spatiotemporal expression changes in the video frame sequence, providing a feature basis for subsequent psychological state analysis.

[0132] S12. Based on speech signal segments in multimodal feature sequences, prosodic variation features and timbre variation features are extracted through a bidirectional long short-term memory network to obtain speech temporal feature vectors.

[0133] Specifically, the speech signal first undergoes preprocessing, including background noise removal, framing, and windowing, to improve its quality and analyzability. The preprocessed speech signal is then input into a Bidirectional Long Short-Term Memory (Bi-LSTM) network. The Bi-LSTM consists of two LSTMs: a forward LSTM that processes data from the start to the end of the speech signal, capturing its temporal sequence features; and a backward LSTM that processes data from the end to the start, capturing its temporal reverse sequence features. This bidirectional processing comprehensively captures prosodic variations (such as intonation and speech rate) and timbre variations (such as voice quality and pitch) in the speech signal. Each layer of the Bi-LSTM updates its hidden state based on the input speech signal segment; these hidden states contain the temporal sequence features of the speech signal. After multi-layer processing, the Bi-LSTM outputs a speech temporal feature vector, which concentrates the prosodic and timbre variation information in the speech signal, providing a speech-related feature basis for psychological state analysis.

[0134] S13. Based on video feature vectors and speech temporal feature vectors, the contribution weights of each modality feature are calculated through an attention weight allocation mechanism to obtain a weighted fusion feature vector.

[0135] Specifically, after obtaining the video feature vector and the speech temporal feature vector, the next step is the feature fusion stage. The goal of this stage is to combine the feature vectors from different modalities (video and speech), while considering that the contributions of different modalities to the analysis of psychological states may vary in different contexts. For this purpose, an attention weight allocation mechanism can be employed.

[0136] Specifically, the similarity or correlation between video feature vectors and speech temporal feature vectors is first calculated. This calculation is performed by computing the dot product between feature vectors, and a weight is dynamically assigned to each modality based on the result. This weight reflects the importance of the modality's features to the psychological state analysis in the current context. Then, the video feature vectors and speech temporal feature vectors are weighted and summed according to these weights to obtain a weighted fusion feature vector. This weighted fusion feature vector integrates feature information from both video and speech modalities and can dynamically adjust the contribution of each modality according to specific circumstances, thus providing a more comprehensive and accurate feature representation for subsequent psychological state analysis.

[0137] S14. Based on the weighted fusion feature vector and the physiological signals in the multimodal feature sequence, cross-modal feature correlation analysis is performed through a fully connected neural network to obtain the psychological state vector.

[0138] Specifically, physiological signals, such as heart rate, skin conductance, and respiratory rate, undergo preprocessing, including filtering to remove noise and normalization to unify data ranges, to ensure data quality and analyzability. Then, the weighted fused feature vector and the preprocessed physiological signals are input into a fully connected neural network. The fully connected neural network consists of multiple layers, each containing a large number of neurons that perform feature transformations using non-linear activation functions (such as ReLU). Each layer of the network performs complex combinations and transformations of the input features to capture the complex correlations between the weighted fused feature vector and the physiological signals. These correlations may include how physiological signals reflect changes in psychological state, and how video and speech features interact with physiological signals to jointly influence psychological state. After multiple layers of feature transformation and combination, the fully connected neural network outputs a psychological state vector that integrates feature information from video, speech, and physiological modalities, reflecting the child's psychological state at the current time point and providing a basis for generating subsequent intervention plans.

[0139] S15. Based on the continuously output psychological state vector, construct a sequence of psychological state data points with a preset sampling frequency to obtain a dynamic psychological state time series.

[0140] Specifically, firstly, data points are extracted from the psychological state vector according to a preset sampling frequency. The selection of the sampling frequency depends on the expected rate of change in psychological states and the required accuracy of the analysis. For example, if psychological states change rapidly, the sampling frequency can be set higher. Data points are then extracted from the psychological state vector according to the set sampling intervals; these data points contain psychological state information at the corresponding time points. Next, these data points are arranged in chronological order to form a continuous sequence of psychological state data points over time. This sequence reflects the changing trends of children's psychological states at different points in time, thus generating a dynamic psychological state time series. In this way, the dynamic changes in psychological states can be captured, providing a psychological state basis that reflects time changes for the subsequent generation of psychological intervention programs.

[0141] In one optional embodiment, based on a dynamic psychological state time series, narrative elements are identified through a pre-trained narrative element mapping model to generate a structured narrative element set, including the following steps:

[0142] S21. Based on the theoretical framework of narrative psychology, a narrative psychology knowledge graph is constructed using a graph database, which includes the definition of emotional outburst point attributes, a classification system of positive ability display periods, and association rules of behavioral pattern turning points.

[0143] Specifically, this step builds a structured knowledge graph based on the personal narrative structure and psychological transition theories in narrative psychology, combined with the characteristics of children's psychological development. A graph database supporting large-scale graph data storage and complex relationship queries is selected as the carrier; the node-relationship model of this database can express the logical connections between narrative elements. The core node types of the knowledge graph are divided into three categories: emotional outburst points, periods of positive ability display, and behavioral pattern turning points. Each node's attributes must satisfy quantifiability and labelability: emotional outburst point node attributes include outburst intensity, duration, triggering scenario type, and accompanying behavioral tags; positive ability display period node attributes include ability type, duration, intensity, and manifestation; and behavioral pattern turning point node attributes include turning point type, turning point magnitude, related events, and duration of lasting impact.

[0144] The relationships between nodes are defined to reflect the narrative logic, with the main relationship types including triggering, accompanying, progressive, and constraining. Triggering relationships reflect the inducing effect of emotional outbursts on behavioral pattern turning points; accompanying relationships reflect the co-occurrence of emotional outbursts and periods of positive ability display; progressive relationships indicate the temporal causal connection between behavioral pattern turning points; and constraining relationships reflect the influence of periods of positive ability display on emotional outbursts. Association rules are extracted from a large amount of child psychological intervention case data using association rule mining algorithms. During the extraction process, statistically significant and effective rules are selected. These rules are stored as relation attributes, containing rule confidence and support information, providing a basis for subsequent reasoning.

[0145] The knowledge graph construction process consists of four stages: The first stage involves multiple senior child psychologists performing double-blind annotation on case data to generate an original annotation set of nodes and relationships, ensuring a high level of consistency during the annotation process. The second stage uses an entity linking model fine-tuned on the child psychology corpus for entity alignment, eliminating ambiguity caused by synonymous entities and ensuring consistent entity representation. The third stage uses a graph neural network-based relationship extraction model to automatically identify the relationships between nodes in the text. The fourth stage uses a rule engine to handle conflicting relationships; when contradictory relationships exist between the same pair of nodes, the relationship supported by high-confidence rules is retained, ultimately forming a knowledge graph containing a sufficient number of nodes and relationships. This knowledge graph supports standard graph query language, enabling scenario-specific relational queries and providing a logical reasoning foundation for subsequent narrative element identification.

[0146] S22. Based on the emotional valence and arousal dimensions in the dynamic psychological state time series, a sliding time window detection is used to mark the time intervals within a continuous preset time period where the emotional valence is less than or equal to the emotional valence threshold and the arousal is greater than or equal to the arousal threshold as candidate regions for emotional outburst points. Among them, emotional valence represents the positive or negative attributes of emotion, indicating the degree of pleasure or unpleasantness of an individual's experience; arousal represents the degree of autonomic nervous system response triggered by emotion.

[0147] Specifically, the emotional valence dimension characterizes the positive or negative attributes of emotions, reflecting the degree of pleasure or displeasure in an individual's experience. It is calculated by weighting various emotional probabilities output by a multimodal fusion model, with values ​​covering the entire range from extreme displeasure to extreme pleasure. The arousal dimension characterizes the degree of autonomic nervous system response triggered by emotions, calculated by weighting physiological and behavioral characteristics. Its value range covers different states of autonomic nervous system activation, from low to high. All features involved in the calculation are standardized and mapped to a unified range to eliminate the influence of differences in dimensions.

[0148] The sliding time window parameters are adapted to the time scale of children's emotional changes. The window size ensures that the complete emotional fluctuation process can be captured, while the step size setting avoids excessive redundancy while ensuring detection accuracy. An adaptive method is used to determine the emotional valence threshold and arousal threshold. Baseline values ​​are calculated based on the child's prior emotional data. The valence threshold is set to a value slightly lower than the baseline to determine a negative emotional state; the arousal threshold is set to a value slightly higher than the baseline to determine a high arousal state. If it is the first time collecting data without baseline data, default values ​​determined based on a large amount of children's emotional data are used to ensure the thresholds have universal applicability.

[0149] The specific process for candidate region detection is as follows: Dynamic psychological state time series are segmented segment by segment using a sliding window, and the mean emotional valence and mean arousal value are calculated within each window. If multiple consecutive windows meet the condition that the mean emotional valence is less than or equal to the valence threshold and the mean arousal value is greater than or equal to the arousal threshold, these windows are merged into a single candidate region for emotional outbursts. The merging rule considers the interval between windows; adjacent windows with small intervals are automatically merged, while those with large intervals are considered independent candidate regions. Each candidate region records attributes such as start timestamp, end timestamp, duration, number of windows, mean valence value sequence, and mean arousal value sequence, forming complete candidate region metadata. To avoid false positives, candidate region filtering conditions are set, including a duration of a certain length to ensure non-instantaneous emotional fluctuations and arousal values ​​showing obvious signs of activation. After filtering, the candidate region retention rate is verified by comparison with physician annotations to ensure it remains at a reasonable level. The final output of the candidate regions for emotional outbursts is presented in a visual format for manual review to ensure the accuracy of subsequent analysis.

[0150] S23. Based on the emotional valence sequence in the candidate region of emotional outburst points, locate the emotional trough point through peak detection, and extract data segments in the candidate region of emotional outburst points with the emotional trough point as the center; extract the emotional fluctuation pattern and behavioral response features based on the data segments to obtain the description object of the emotional outburst point.

[0151] Specifically, the emotional valence sequence within the candidate region is smoothed to eliminate high-frequency noise interference while preserving the trend characteristics of the sequence. After processing, the first and second derivatives of the sequence are calculated to help locate emotional troughs. The first derivative reflects the rate of change of valence, and the second derivative reflects the acceleration of change. Combining the two can accurately identify local extreme points in the sequence.

[0152] The peak detection algorithm employs an adaptive thresholding method combined with derivative features. A sentiment trough is defined as a local minimum in the sequence where the second derivative exhibits a convex feature. When traversing the valence sequence, each point is compared to its neighboring points. If the point's value is less than all neighboring values ​​and its second derivative conforms to the convex feature, it is marked as a candidate trough. To avoid false detections caused by small local fluctuations, a trough intensity threshold is set, requiring a significant difference between the valence of the point and the initial valence of the candidate region, and a duration sufficient to ensure it is not an instantaneous point. If multiple troughs meet the criteria within the candidate region, the point with the lowest valence is selected as the final sentiment trough; if no trough meets the criteria, the midpoint of the candidate region is used as a substitute, and the substitute point's attributes are labeled for differentiation.

[0153] The data segment is truncated to cover the entire process of an emotional outburst. Centered on the emotional trough, data is truncated forward to include the emotional decline before the trough and backward to include the emotional recovery after the trough. If the candidate region length is insufficient, it is limited by the candidate region boundary to ensure that the truncated data segment can completely reflect the entire cycle of emotion from accumulation to outburst to recovery. The truncated data segment contains multimodal features, covering emotional valence sequences, arousal sequences, facial expression features, voice features, and physiological features. These features will provide comprehensive data support for subsequent extraction of emotional fluctuation patterns and behavioral response features.

[0154] Emotional fluctuation patterns are quantified and extracted from three dimensions: fluctuation amplitude reflects emotional intensity, calculated by the difference between the maximum and minimum valence values ​​within a data segment; fluctuation frequency reflects emotional stability, calculated by counting the number of zero-crossing points in the valence sequence within the data segment; and recovery rate reflects emotional regulation ability, calculated by the rate of valence change within a specific time period after a trough. Behavioral response feature extraction is conducted across three modalities: facial expression, speech, and movement. Facial expression features are identified by using a finely tuned expression recognition model on a children's facial expression dataset to determine specific emotion types and durations. Speech features are extracted by extracting emotion-related acoustic features and combining them with a classifier to identify the type of emotional speech. Movement features are calculated by tracking skeletal key points and counting the frequency of high-frequency movements to comprehensively capture children's behavioral performance during emotional outbursts.

[0155] The description of emotional outburst points is represented in a structured format, integrating all extracted features, including the timestamp of the trough point, the trough value of valence, the fluctuation pattern, the dominant emotion type, the set of behavioral responses, triggering cues, and confidence level. The dominant emotion type is determined based on multimodal feature voting. The set of behavioral responses records in detail the type, duration, and intensity of each behavior. Triggering cues are extracted from speech text or scene analysis of events that may trigger an emotional outburst. The confidence level is a feature consistency score; a higher value indicates more consistent features.

[0156] S24. Based on the emotional valence dimension and attention concentration dimension in the dynamic psychological state time series, the continuous period detection algorithm identifies the period when the emotional valence is greater than or equal to the emotional valence threshold and the attention concentration is greater than or equal to the attention concentration threshold. High-frequency behavioral features within the period are extracted to obtain the description object of the positive ability display period.

[0157] Specifically, the attention concentration dimension is calculated through the fusion of multimodal behavioral features, representing the child's level of focus within a specific time period, with values ​​covering different states from low to high focus. The calculation process comprehensively considers three dimensions: visual focus, behavioral stability, and physiological calmness. Visual focus is determined through eye tracking or facial orientation analysis, calculated based on the percentage of time the child gazes at the target. Behavioral stability is calculated using the variance of skeletal keypoint movement; a smaller variance indicates more stable behavior. Physiological calmness is calculated based on physiological characteristics reflecting the state of the autonomic nervous system; a higher characteristic value indicates a calmer autonomic nervous system. These three dimensions are weighted appropriately to obtain the attention concentration score, which is then calculated at fixed time intervals to form a time series, ensuring consistency with the temporal resolution of the emotional valence dimension.

[0158] The core of the continuous time period detection algorithm is to identify consecutive time periods that simultaneously meet both emotional and attentional conditions. The emotional valence threshold is set to a value slightly higher than the baseline for positive emotions to determine a positive emotional state; the attentional concentration threshold is set to a value that meets the standard for sustained attention in children to determine a high level of focus. The detection process first traverses the time series, marking all time points that simultaneously meet both the emotional valence and attentional concentration thresholds. Then, a connected component analysis algorithm is used to merge consecutively meeting these conditions into candidate time periods. Continuity is defined as a time interval within an allowable range, which may deviate briefly but maintain overall continuity.

[0159] Candidate time periods are screened based on criteria including a sufficient duration to ensure a valid positive state, and a high percentage of time points meeting the criteria within the time period to guarantee the representation of core time periods. The resulting candidate time periods showcasing positive capabilities will serve as the foundational data source for extracting high-frequency behavioral features.

[0160] High-frequency behavioral feature extraction is based on video behavior analysis, employing a behavior recognition model fine-tuned on a children's behavior dataset. This model supports the recognition of various common children's behaviors with high accuracy. A sliding window is used to count the frequency of each behavior, with window size and stride settings balancing detection accuracy and efficiency. The frequency of each behavior is calculated, and behaviors with higher frequencies are selected as high-frequency behaviors. If there are many high-frequency behaviors, the co-occurrence probability of behaviors is further calculated to identify common behavior combinations, comprehensively reflecting the behavioral characteristics of children during periods of active ability demonstration.

[0161] The construction of the description object for the positive ability display period is based on the associated ability type and performance characteristics, using a structured attribute representation, including the start and end times of the period, duration, average valence, average attention concentration, core ability type, behavioral performance details, environmental characteristics, and stability indicators. The core ability type is determined based on high-frequency behaviors through a predefined behavior-ability mapping table; behavioral performance details record the duration, intensity score, and interaction with others for each high-frequency behavior; environmental characteristics identify the scene type within the period through a scene classification model; the stability indicator is calculated using the standard deviation of valence and attention concentration within the period, with smaller values ​​indicating greater stability. During the construction of the description object, missing attributes are supplemented by comparing with the attributes of the positive ability display period nodes in the narrative psychology knowledge graph, such as the ability development stage determined based on age and behavioral complexity, ultimately forming a complete structured representation that supports correlation analysis with other narrative elements.

[0162] S25. Based on the dynamic psychological state time series, the turning point of psychological state is located by the first derivative mutation point detection algorithm, and the plot turning point logic is verified by the association rules of the narrative psychology knowledge graph, so as to obtain the behavioral pattern turning point marker set.

[0163] Specifically, feature dimensionality reduction of dynamic psychological state time series is a prerequisite for mutation point detection. Representative core psychological state features can be selected from the time series, covering multiple dimensions such as emotion, attention, social interaction, and self-regulation, comprehensively reflecting changes in children's psychological states. Each dimension is sampled at fixed time intervals to form a sequence. All sequences are standardized to eliminate dimensional differences, and then principal component analysis is used for dimensionality reduction to obtain a comprehensive psychological state index. The dimensionality reduction process ensures sufficient variance explanation to guarantee that core feature information is not lost, simplifying the complexity of subsequent mutation point detection.

[0164] The first-order derivative mutation point detection algorithm reflects the rate of change in state by calculating the first derivative of the comprehensive psychological state index. It uses a sliding window to calculate the statistical parameters of the derivative sequence and sets a mutation threshold based on statistical principles to identify points that significantly deviate from normal changes. When traversing the derivative sequence, if the absolute value of the derivative at a certain point reaches the mutation threshold, and the signs of the derivatives in a specific time period before and after that point are opposite, it indicates a reversal in the psychological state trend and is marked as a candidate mutation point. To avoid noise interference, candidate mutation points are verified by calculating the difference in the mean of the psychological state index in a specific time period before and after the mutation point. If the difference reaches a significant level, it is confirmed as a valid mutation point; otherwise, it is discarded to ensure the accuracy of mutation point detection.

[0165] Behavioral pattern correlation analysis at psychological state transition points is achieved by extracting multimodal data from specific time periods before and after the abrupt change. This involves comparing and analyzing changes in behavioral characteristics, including facial expression types, frequency of social interactions, and frequency of self-regulation behaviors. By calculating behavioral pattern similarity and comparing behavioral feature vectors before and after the abrupt change, a low similarity indicates a significant change in behavioral patterns. This abrupt change point is then marked as a behavioral pattern transition point, thus confirming the association between a sudden change in psychological state and a shift in behavioral patterns.

[0166] The verification of association rules using a narrative psychology knowledge graph aims to ensure the rationality of the turning point logic. Association rules related to the current turning point are retrieved from the knowledge graph; these rules contain the correspondence between changes in psychological state and changes in behavioral patterns. The matching degree between the turning point features and the rule antecedents is calculated. If the matching degree is high, the turning point logic is confirmed to conform to narrative patterns, and the turning point is retained. If the matching degree is low, a manual verification process is initiated, generating a feature comparison report before and after the turning point. The report includes curves of changes in emotional, behavioral, and physiological data, allowing a psychologist to determine whether to retain the turning point. Turning points verified by the psychologist are marked with a manual confirmation to distinguish between the results of automatic and manual verification.

[0167] The behavioral pattern turning point marker set is stored in a structured format. Each turning point includes the turning point time, turning point type, turning point magnitude, related behavioral changes, triggering factors, rule matching degree, and verification status. The turning point type is determined based on the difference between the mean values ​​of the psychological state index before and after the change. A positive mean difference indicates a positive turning point, signifying an improvement in psychological state; a negative mean difference indicates a negative turning point, signifying a deterioration in psychological state. Related behavioral changes are recorded in detail, comparing behavioral patterns before and after the change. Triggering factors are extracted from environmental data or event records, indicating events that may trigger the turning point. The rule matching degree records the matching score with knowledge graph rules. The verification status is marked by automatic verification approval or manual confirmation. The marker set is arranged chronologically and supports filtering by turning point type, magnitude, and other conditions, providing clear temporal anchors for subsequent element associations.

[0168] S26. Based on the description objects of emotional outburst points, the description objects of positive ability display periods, and the mark set of behavioral pattern turning points, the temporal relationship between elements is established through the time axis alignment algorithm to generate a set of structured narrative elements in triplets.

[0169] Specifically, using the start time of the dynamic psychological state time series as the base time, the time attributes of emotional outbursts, periods of positive ability display, and behavioral pattern turning points are all converted into a unified time unit relative to the base time, eliminating time synchronization errors between different devices. During the conversion process, linear interpolation is used to correct minor time deviations, ensuring that the time errors of all elements are controlled within a small range. A time axis with uniform time accuracy is constructed, and the time attributes of all elements are mapped onto this time axis to form a visual timeline, intuitively showing the distribution of each element in the time dimension, providing a clear time reference for subsequently establishing temporal relationships.

[0170] The establishment of temporal relationships between elements can be comprehensively determined from two dimensions: time interval and semantic features. Different time window thresholds are set based on the element association characteristics: a shorter time window threshold is used to capture short-term associations between emotional outbursts and behavioral pattern turning points; a medium time window threshold is used to capture medium-term associations between periods of positive ability demonstration and behavioral pattern turning points; and a longer time window threshold is used to capture long-term associations between emotional outbursts and periods of positive ability demonstration. The time difference between elements is calculated; if the time difference is within the corresponding time window threshold range, a preliminary temporal relationship is determined to exist.

[0171] Furthermore, semantic associations of element features are used for further verification. If the triggering scenario of an emotional outburst and the associated event of a behavioral pattern turning point have a high degree of semantic similarity, or if the core ability type during the period of positive ability demonstration and the turning point type of the behavioral pattern turning point have a supporting relationship in the knowledge graph, then the confidence of the association between the two is strengthened. Semantic similarity is calculated through a semantic model finely tuned on the children's psychological corpus, while the supporting relationships in the knowledge graph are determined based on the previously constructed association rules, ensuring the accuracy of semantic association determination.

[0172] The quantification and screening of associations integrates temporal and semantic association calculations to determine confidence levels. Temporal association scores are calculated based on the ratio of the time difference between elements to a corresponding threshold; the smaller the time difference, the higher the score. Semantic association scores are determined based on semantic similarity or knowledge graph relationship weights. The two are weighted appropriately to obtain the final confidence level. Associations with high confidence levels are retained and sorted in descending order of confidence score. The top few strong associations are selected to avoid over-association and ensure the effectiveness and simplicity of the associations. Association types are categorized according to the interaction between elements: initiating, accompanying, promoting, and inhibiting. Each association type clearly indicates the association direction and confidence level, clearly reflecting the interaction between elements.

[0173] The triplet-structured narrative element set is generated using a standard resource description framework format to ensure semantic regularity. Each narrative element, as a resource within the resource description framework, has a unique unified resource identifier. The triplet structure consists of a subject element identifier, a relation type identifier, an object element identifier, and a confidence level, fully expressing the relationships between elements. Simultaneously, the set also includes attribute triples for each element, recording core attribute information such as the valence trough value at emotional outburst points and the core ability type during periods of positive ability demonstration. The final generated structured narrative element set undergoes integrity verification using a standard graph query language, ensuring accurate querying of various elements and their relationships. It also supports interface integration with natural language generation models, providing structured knowledge support for subsequent personalized problem story text generation.

[0174] In one alternative embodiment, based on personalized problem story text and a set of structured narrative elements, the optimal narrative framework is matched from a narrative prototype library, including the following steps:

[0175] S31. Based on personalized problem story texts, extract the text sentiment polarity distribution through a pre-trained sentiment analysis model, calculate the ratio of positive sentiment words to negative sentiment words based on the text sentiment polarity distribution, and obtain the quantitative value of the story's sentiment tone.

[0176] Specifically, this step utilizes a sentiment analysis model adapted to the characteristics of children's texts to extract the emotional features of the story text. The pre-trained sentiment analysis model is fine-tuned on a corpus of texts related to children's psychological intervention to identify common emotional expressions in children's stories, avoiding recognition bias caused by training with adult-oriented corpora. The emotional polarity distribution extracted by the model covers the distribution of three categories of emotions: positive, negative, and neutral. Positive emotion words include those related to joy, safety, and confidence; negative emotion words include those related to anxiety, fear, and frustration; and neutral words are narrative words without a clear emotional tendency.

[0177] After obtaining the distribution of emotional polarity, the ratio of positive to negative emotion words is calculated. The calculation process involves first segmenting and filtering the text by part of speech, excluding function words and auxiliary words without emotional meaning, and retaining only content words with clear emotional orientation. Then, the total frequency of positive and negative emotion words is counted separately, with the frequency of positive emotion words as the numerator and the frequency of negative emotion words as the denominator, to obtain the ratio. If the frequency of negative emotion words is zero (i.e., there is no obvious expression of negative emotion in the story), the ratio is set to a fixed level reflecting a strong positive tendency; if the frequency of positive emotion words is zero, the ratio is set to a fixed level reflecting a strong negative tendency.

[0178] The resulting quantitative value of the story's emotional tone directly reflects the overall emotional tendency of the story. A higher value indicates a more positive emotional tone, while a lower value indicates a more negative emotional tone. This quantitative value not only integrates the quantitative relationships of emotional words but also implicitly includes the intensity characteristics of emotional expression in the story—for example, frequently occurring core emotional words (such as "fear" and "happiness") will have a higher weight in the statistics, ensuring that the quantitative results can truly reflect the emotional atmosphere conveyed by the story and provide a core basis for the emotional dimension in subsequent narrative framework matching.

[0179] S32. Based on the number of objects describing emotional outbursts and the number of objects describing positive ability display periods in the set of structured narrative elements, calculate the outburst-ability ratio using the formula R=N_outburst_points / (N_outburst_points+N_ability_points); where R is the outburst-ability ratio, N_outburst_points is the number of objects describing emotional outbursts, and N_ability_points is the number of objects describing positive ability display periods.

[0180] Specifically, this step first clarifies the statistical rules for two types of key descriptive objects in the structured narrative element set to ensure the accuracy and consistency of the statistical data. The statistics for descriptive objects of emotional outbursts are based on the valid descriptive objects identified in step S23, excluding those marked as "alternative points" and not manually verified, retaining only those that pass multimodal feature verification and reach the set confidence level. The statistics for descriptive objects of periods showcasing positive abilities are based on the valid time periods selected in step S24, excluding those with insufficient duration or unclear high-frequency behavioral characteristics, ensuring that both types of objects have actual psychological significance.

[0181] After determining the number of objects in both categories, the outburst-ability ratio is calculated. The calculation logic is as follows: the number of objects describing emotional outbursts is used as the numerator, and the sum of the number of objects describing emotional outbursts and the number of objects describing periods of positive ability display is used as the denominator. The ratio is obtained through division. The core significance of this ratio lies in quantifying the relative relationship between "negative emotional outbursts" and "positive ability display" in a child's psychological state—a higher ratio indicates a relatively higher frequency of negative emotional outbursts and a relatively lower frequency of positive ability display in the child's recent psychological activities; a lower ratio indicates a relatively higher frequency of positive ability display and a relatively lower frequency of negative emotional outbursts.

[0182] Special cases are handled during the calculation process: If the number of both types of objects is zero (i.e., no emotional outburst points or periods of positive ability display are detected), a prompt is made to re-collect multimodal data and identify elements to ensure that subsequent matching has valid data support; if only the number of objects describing periods of positive ability display is zero, the proportion is set to a fixed level reflecting purely negative tendencies; if only the number of objects describing emotional outburst points is zero, the proportion is set to a fixed level reflecting purely positive tendencies. By reasonably handling special cases, the proportion is ensured to comprehensively cover various psychological state scenarios, providing an accurate quantitative basis for the subsequent feature vector construction.

[0183] S33. Based on the story's emotional tone quantification value and the explosion-ability ratio value, a two-dimensional feature vector is generated through vector concatenation operation to obtain the narrative matching feature vector.

[0184] Specifically, through preliminary processing, the quantitative value of the story's emotional tone and the explosion-ability ratio value have been mapped to the same numerical range to avoid a certain dimension from dominating the vector due to differences in the value range, thus affecting the fairness of the matching.

[0185] The vector concatenation operation follows a fixed dimensional order: first, the quantified value of the story's emotional tone is incorporated, followed by the burst-ability ratio value, forming a two-dimensional feature vector. This order remains consistent throughout the entire methodology, ensuring that the subsequent dimensional correspondence with the standard feature vectors in the narrative prototype library is consistent. No additional weighting is required on the two quantified values ​​during concatenation, as they represent the "emotional tendency of the story text" and the "characteristics of the child's actual psychological state," respectively—both core dimensions for narrative framework matching—and must be considered equally.

[0186] The generated narrative matching feature vector has a clear semantic interpretation. The first dimension of the vector reflects the emotional tone of the personalized problem story text itself, while the second dimension reflects the psychological state characteristics of children based on structured narrative elements. The combination of the two achieves a dual mapping between "textual emotion" and "actual psychology." This two-dimensional structure simplifies the complexity of subsequent similarity calculations and comprehensively covers the key information required for narrative framework matching, ensuring that the matching results are both consistent with the story content and the children's true psychological state.

[0187] S34. Calculate the similarity between the narrative matching feature vector and the standard feature vector of each prototype in the preset narrative prototype library, and select the prototype with the highest similarity as the best narrative framework.

[0188] Specifically, a pre-built narrative prototype library is constructed before the methodology is implemented. Each narrative prototype in the library corresponds to a typical child psychological intervention scenario, and its standard feature vector has been determined through prior data annotation and validation. The standard feature vector for each prototype is also a two-dimensional structure, with the dimensional order completely consistent with the narrative matching feature vector—the first dimension is the standard emotional tone quantification value of the story to which the prototype fits, and the second dimension is the standard burst-ability ratio value of the child's psychological state to which the prototype fits. The prototype library covers common types of child psychological problems, such as separation anxiety, social withdrawal, and academic setbacks. Each problem type corresponds to multiple differentiated narrative frameworks (such as emotional resonance type, behavioral guidance type, and scenario desensitization type), ensuring that the prototypes in the library can meet the adaptation needs of different individuals.

[0189] Similarity calculation employs a method suitable for low-dimensional vectors, measuring the spatial distance between the narrative matching feature vector and each standard feature vector, and converting this distance into a similarity value. During the calculation, it is ensured that all vectors reside in the same feature space to avoid computational biases caused by differences in prior standardization processing. A higher similarity value indicates a greater fit between the narrative matching feature vector and the prototype standard vector, meaning the prototype is more suitable for the current child's emotional state and the story text's emotional state.

[0190] When selecting the optimal narrative framework, all prototypes are first sorted in descending order of similarity scores, and the prototype with the highest similarity score is selected as an initial candidate. If multiple prototypes have the same and highest similarity scores, a secondary screening is performed using the behavioral pattern turning point marker set in the structured narrative element set. Prototypes with a higher match to the turning point type (positive / negative) are prioritized. For example, for children with multiple positive turning points, narrative prototypes emphasizing "positive ability enhancement" are prioritized. The final optimal narrative framework must simultaneously meet the requirements of "emotional tone fit," "psychological state fit," and "turning point logic fit" to ensure that subsequent intervention steps generated based on this framework accurately meet the individual needs of children and improve the effectiveness of the intervention plan.

[0191] In one alternative embodiment, a sequence of basic intervention steps is generated based on an optimal narrative framework, including the following steps:

[0192] S41. Based on the standard plot stage definition of the optimal narrative framework, extract the number of stages, stage themes, and stage transition rules to obtain a plot stage description set.

[0193] Specifically, the standard plot stages of the optimal narrative framework are pre-defined based on the logic of child psychological intervention and the laws of narrative psychology. They clearly delineate core stages with a progressive relationship, ensuring that each stage forms a complete narrative loop around the intervention goal. The number of stages is adapted to the characteristics of children's attention span and the complexity of the intervention, and can be divided into 3-5 core stages to avoid overwhelming children with too many stages. The stages include the emotional resonance stage, the problem exploration stage, the strategy attempt stage, the successful experience stage, and the transfer and application stage. Different types of narrative frameworks (such as emotional guidance and behavioral training) will adjust the stage names and emphases. For example, a framework for children with social withdrawal may add an "interaction desensitization stage" instead of the "transfer and application stage" in the general framework.

[0194] Each stage's theme corresponds to an intervention sub-goal and aligns with the child's psychological state. The emotional resonance stage focuses on "emotion recognition and acceptance," with the core goal of helping children feel understood through narrative content. For example, by having the protagonist express similar emotions in the story, children are guided to form an emotional connection. The problem exploration stage focuses on "analyzing the causes and effects of problems," helping children understand their own psychological issues through the protagonist's analysis of their predicament. The strategy experiment stage focuses on "learning and practicing coping methods," conveying actionable psychological adjustment or behavioral coping strategies through the protagonist's attempts to solve problems. The success experience stage focuses on "reinforcing positive outcomes," allowing children to experience the positive psychological changes brought about by success through the protagonist's overcoming of difficulties. The transfer and application stage focuses on "adapting to real-life scenarios," guiding children to connect the strategies in the story with their own real lives.

[0195] The transition rules clearly define the conditions that trigger the transition between each stage, ensuring that the narrative flow aligns with the child's psychological comprehension rhythm. Transition conditions are divided into two categories: content-triggered and feedback-triggered. Content-triggered conditions are based on the plot progression of the narrative text. For example, after completing the core plot of the emotional resonance stage (such as the protagonist receiving a response after expressing their emotions), the transition automatically proceeds to the problem exploration stage. Feedback-triggered conditions rely on the child's real-time feedback during the intervention process. For instance, in the strategy trial stage, if the child shows confusion about the current strategy through facial expressions, actions, or language (such as frowning or remaining silent), the duration of that stage is extended, supplementing the strategy explanation. The transition is triggered only after the child shows signs of understanding (such as nodding or actively asking questions). All transition rules avoid abrupt jumps, achieving a natural connection between stages through transitional elements (such as scene transitions in the story and character dialogue connections).

[0196] After extracting the number of stages, stage themes, and stage transition rules, the information is organized into a plot stage description set in a structured format. The description set includes a unique identifier (stage ID) for each stage, stage name, core theme, intervention sub-goals, suggested implementation duration, core plot elements, and transition conditions. The core plot elements clearly define the key narrative content that the stage must include (e.g., the emotional resonance stage must include two types of plots: "emotional expression" and "others' responses"). The transition conditions explain the specific criteria for distinguishing between content triggers and feedback triggers, ensuring a clear basis for subsequent stage activity filling and step generation.

[0197] S42. Based on the behavioral pattern turning point marker set in the structured narrative element set, the turning point and the plot stage transition point are matched by the time axis alignment algorithm to obtain the stage-turning point mapping relationship table.

[0198] Specifically, the behavioral pattern turning point marker set contains information on all valid turning points identified in the previous stage. Each turning point has a precise timestamp and a turning point type (positive / negative), and is associated with changes in behavioral patterns before and after the turning point (e.g., a positive turning point from withdrawal to attempting interaction, or a negative turning point from a calm state to anxiety). These turning points reflect key changes in the child's psychological state and are linked to the plot stage transition points of the optimal narrative framework through a timeline alignment algorithm, ensuring that the stage divisions of the narrative framework match the actual rhythm of the child's psychological changes.

[0199] The implementation of the timeline alignment algorithm first unifies the time base, taking the earliest recorded time in the set of structured narrative elements as the starting point, and converting the timestamps of behavioral pattern turning points into a unified time unit (such as minutes) relative to the starting point; at the same time, the transition points of each plot stage in the optimal narrative framework are also set with a standard time position relative to the starting time of the framework. This standard time position is determined based on the statistics of a large number of similar intervention cases. For example, the transition point between the emotional resonance stage and the problem exploration stage is set at 15-20 minutes after the start of the framework narrative, and the transition point between the problem exploration stage and the strategy attempt stage is set at 30-35 minutes.

[0200] The matching process calculates the time difference between each behavioral pattern inflection point and each stage transition point, prioritizing the inflection point with the smallest time difference to establish an initial association with the transition point. If a stage transition point corresponds to multiple inflection points (e.g., two positive inflection points appear within 10 minutes before and after the transition point), a secondary screening is performed by combining the associated behavioral changes of the inflection point with the stage transition goal: the stage transition goal refers to the change in psychological state achieved during the transition between two adjacent stages. For example, the goal of the transition from the emotional resonance stage to the problem exploration stage is "the child shifts from emotional expression to problem thinking." In this case, inflection points related to "cognitive focus" are prioritized for matching (e.g., the behavioral inflection of the child starting to actively mention problem details), while inflection points unrelated to the transition goal (e.g., a simple emotional calming inflection point) are excluded.

[0201] If a behavioral pattern inflection point does not match any stage transition point (e.g., the inflection point time exceeds the time range of all transition points), then the importance of the inflection point is determined: if it is a positive inflection point and is associated with the demonstration of core positive abilities (e.g., the first time to take the initiative to initiate social interaction), then the transition point time of the corresponding stage is adjusted to include the inflection point in the matching range to avoid missing key psychological changes; if it is a negative inflection point and is associated with short-term emotional fluctuations (e.g., brief crying), then it is marked as a "non-core inflection point" and is not included in the mapping relationship for the time being, but is only used as a reference in subsequent activity screening.

[0202] The final stage-turning-point mapping table is presented in tabular form, including stage transition point ID, standard time position within the framework, matched turning point ID, turning point timestamp, time difference, turning point type, associated behavioral changes, and matching confidence level. Matching confidence level is calculated based on a combination of time difference and behavioral goal matching degree; the smaller the time difference and the higher the behavioral goal matching degree, the higher the confidence level. This table will serve as an important basis for subsequent intervention activity retrieval, ensuring that selected activities can specifically respond to children's key psychological turning points.

[0203] S43. Based on the stage-turning point mapping relationship table and the plot stage description set, retrieve candidate activities that match the stage theme from the preset intervention activity library.

[0204] Specifically, a pre-designed intervention activity library is constructed before the implementation of the methods. Activities in the library are categorized and stored according to three dimensions: "stage theme - psychological goal - implementation method," ensuring accurate location of suitable activities during retrieval. The activity library covers the needs of different stage themes. For example, the emotional resonance stage corresponds to "emotional expression" and "emotional connection" activities; the problem exploration stage corresponds to "problem analysis" and "cause analysis" activities; the strategy trial stage corresponds to "method practice" and "simulation practice" activities; the successful experience stage corresponds to "results demonstration" and "positive reinforcement" activities; and the transfer and application stage corresponds to "scenario simulation" and "real-world relevance" activities. Each activity includes detailed technical parameters, such as the appropriate age range, implementation duration, required materials, implementing entity (parent / doctor / teacher), core operating steps, appropriate psychological transition type, and expected results. For example, the "Emotion Card Expression Activity" is suitable for children aged 6-8, with an implementation duration of 10-15 minutes. The materials are cards printed with different emotional expressions. The implementing entity is the parent. The core step is to guide the child to select the corresponding emotion card and describe their feelings. It is suitable for the emotional expression needs after a negative emotional transition. The expected result is that the child can clearly identify and express their own emotions.

[0205] The retrieval process employs a multi-condition joint matching strategy. First, using the stage theme within the plot stage description set as the core search condition, all activities under that theme category in the database are filtered to form a preliminary candidate set. Then, combining the stage-turning-point mapping relationship table with the turning-point type and associated behavioral changes corresponding to the current stage, the preliminary candidate set undergoes a second round of filtering. For example, if the emotional resonance stage matches "the turning point after an anxiety outburst," activities suitable for "anxiety relief" (such as "comforting doll dialogue activities") are further filtered from "emotional connection" activities, while activities suitable for "anger management" (such as "emotional venting ball activities") are excluded. If the stage corresponds to "a positive turning point after social attempts," activities containing "social interaction scenario analysis" (such as "social story puzzle activities") are prioritized in the "problem sorting" activities of the problem exploration stage to strengthen guidance for positive behaviors.

[0206] The matching degree between activities and stage requirements is calculated during the search process. Matching indicators include theme matching degree, transition fit degree, and goal alignment degree. Theme matching degree is calculated based on the keyword overlap between the activity's category and the stage theme (e.g., if the stage theme contains "emotion recognition" and the activity name contains "emotion cards," the overlap degree is high). Transition fit degree is calculated based on the consistency between the transition type adapted to the activity and the transition point type of the current stage. Goal alignment degree is calculated based on the similarity between the activity's psychological goals and the stage's intervention sub-goals. The three indicators can be weighted in a 4:3:3 ratio to obtain a comprehensive matching degree. The top 5 activities with the highest comprehensive matching degree are selected as candidate activities for that stage, ensuring sufficient activity selection space for each stage while avoiding an excessive number of candidates that would reduce subsequent screening efficiency.

[0207] For stages with multiple turning points (such as a stage that matches both positive and negative turning points), priority should be given to searching for activities with "two-way adaptation" capabilities. That is, activities that can respond to the problems caused by negative turning points (such as anxiety) and reinforce the positive behaviors caused by positive turning points (such as proactive expression). For example, "emotion-behavior association mapping activities" can guide children to mark their behavior when anxious and also record the positive results after proactive expression. Such activities can improve the comprehensiveness of stage intervention.

[0208] S44. Based on candidate activities, activities that match children's cognitive abilities are selected through a rule engine to generate a phased activity filling plan, and a basic intervention step sequence is obtained based on the phased activity filling plan.

[0209] Specifically, the core of the rules engine is to pre-set a set of screening rules that are adapted to children's cognitive abilities. These rules are formulated based on the research results of child development psychology and intervention practice experience, covering five dimensions: age, attention span, language comprehension ability, hands-on ability and psychological stability. This ensures that the selected activities are within the range that children can understand and participate in, and avoids the intervention effect being affected by activities that are too difficult or too easy.

[0210] Each dimension's screening rules have clear judgment criteria. The age dimension rules categorize activities by difficulty level based on the child's age. For example, activities primarily involving concrete imagery and play (such as role-playing with dolls) are suitable for children aged 3-5; activities involving simple logical thinking (such as matching emotional cause-and-effect cards) are suitable for children aged 6-8; and activities emphasizing abstract thinking and self-planning (such as creating personal coping strategy charts) are suitable for children aged 9-12. Attention span rules limit the duration of each activity session, generally not exceeding the upper limit corresponding to the child's age (e.g., no more than 10 minutes for 5-year-olds and no more than 15 minutes for 8-year-olds). If the activity duration exceeds the upper limit, it is broken into multiple sub-activities and implemented in different time slots. Language comprehension rules are based on the child's language expression and comprehension level. The selection criteria include: 1) the language complexity of the activities; for example, activities primarily involving physical movement and images (such as games imitating emotional expressions) are suitable for children with weaker language skills, while activities primarily involving dialogue and story creation (such as continuing emotional stories) are suitable for children with stronger language skills; 2) the fine motor skills rule, which targets activities requiring manipulation of materials, ensuring that the difficulty of the materials matches the child's fine motor development level, for example, large building blocks and thick cardboard are suitable for younger children, while older children can use materials requiring fine control, such as scissors and paintbrushes; and 3) the psychological stability rule, which considers the frequency of behavioral pattern turning points. If a child has experienced frequent negative turning points recently, activities with a slow pace and low stress (such as mindful breathing and painting) should be selected, while competitive or high-intensity interactive activities (such as group competitions) should be avoided.

[0211] The rule engine's screening process is as follows: The attributes of each candidate activity (suitable age, duration, language difficulty, and material manipulation difficulty) and the child's cognitive ability assessment results (determined based on prior multimodal data and personalized information) are input into the rule engine. The engine verifies whether each activity conforms to the rules of each dimension. If an activity violates any core rule (e.g., duration exceeds the attention limit), it is directly eliminated. If it only partially conforms (e.g., the activity's language difficulty is slightly higher than the child's current level, but can be adjusted by simplifying the wording), it is marked as an "activity to be adjusted," and adjustment suggestions are generated (e.g., changing complex instructions to short sentences or adding visual aids). Activities that fully conform to all rules are marked as "suitable activities," sorted by overall matching degree, with 2-3 suitable activities retained as final candidates at each stage.

[0212] Based on the selected suitable activities, a phase activity plan is generated. The plan clearly defines the core activities, implementation order, time allocation, material preparation, and contingency plans for each phase: the implementation order follows the principle of "easy to difficult" and "low pressure to high participation," for example, in the emotional resonance phase, "emotion card recognition" (low difficulty) is carried out first, followed by "emotion story sharing" (high participation); the time allocation combines the suggested total time for the phase with the characteristics of the activities to ensure that the total time of each activity does not exceed the phase's time limit, and reserves 5-10 minutes of flexible time to deal with possible emotional fluctuations or operational delays in children; the material preparation lists specific materials and alternative solutions (e.g., hand-drawn expressions can be used instead if there are no dedicated emotion cards); the contingency plan addresses possible problems (e.g., children refusing to participate, or the activity not achieving the expected results), and clarifies alternative activities and switching conditions (e.g., if children refuse to share, "emotion drawing" can be used instead of "emotion story sharing").

[0213] The activity plans for each stage are integrated according to the stage sequence of the narrative framework to form a basic intervention step sequence. The sequence arranges each intervention step in linear order, and each step includes a step number, corresponding stage, activity name, implementing entity, specific operation procedure, duration, materials, adaptation goals, and related turning points. The specific operation procedure needs to be detailed with action instructions and language examples for each step (such as "Parents hold up emotion cards and show them to the child one by one, asking: 'How does this expression look? Have you ever felt this way?'") to ensure that implementers (such as parents) can follow the steps without additional training. The final result is a logically coherent and highly operable basic intervention step sequence, providing a complete initial plan for subsequent reinforcement learning optimization.

[0214] The aforementioned method for generating personalized child psychological intervention programs involves simultaneously collecting children's facial expressions, voice signals, and physiological data to construct a multimodal feature sequence. A multimodal fusion neural network is then used to analyze psychological states, forming a dynamic time series. Furthermore, a narrative element mapping model transforms psychological fluctuations into structured narrative elements. Combined with children's personalized information, problem-story texts that align with their cognitive characteristics are generated. Finally, the optimal narrative framework is matched to construct basic intervention steps, and reinforcement learning is applied to optimize the step sequence. This forms a technical path that transforms children's psychological characteristic data into personalized narrative intervention programs, achieving a shift from mechanical task execution to a story-based growth experience, significantly improving children's willingness to participate and the effectiveness of interventions.

[0215] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0216] Based on the same inventive concept, this application also provides an apparatus for implementing the personalized child psychological intervention program generation method described above. The solution provided by this apparatus is similar to the solution described in the above method; therefore, the specific limitations in one or more embodiments of the personalized child psychological intervention program generation apparatus provided below can be found in the limitations of the personalized child psychological intervention program generation method described above, and will not be repeated here.

[0217] In one exemplary embodiment, such as Figure 2 As shown, a personalized child psychological intervention program generation device 20 is provided to implement the methods in the above-described method embodiments. The device includes:

[0218] The multimodal data acquisition and feature extraction module 21 is used to acquire multimodal data of children, extract features from the multimodal data, and obtain multimodal feature sequences; among which, multimodal data includes facial expression videos, speech signals and physiological data.

[0219] The multimodal psychological state analysis module 22 is used to perform psychological state analysis based on multimodal feature sequences and through a multimodal fusion neural network model to generate dynamic psychological state time series.

[0220] The narrative element parsing and structuring module 23 is used to identify narrative elements based on dynamic psychological state time series and generate a structured narrative element set through a pre-trained narrative element mapping model.

[0221] The personalized question story generation module 24 is used to generate personalized question story texts based on a set of structured narrative elements and children's personalized information through a natural language generation model.

[0222] The narrative framework matching and intervention step generation module 25 is used to match the best narrative framework from the narrative prototype library based on the personalized problem story text and the structured narrative element set, and generate a basic intervention step sequence based on the best narrative framework.

[0223] The intervention path optimization and program generation module 26 is used to optimize the step sequence of the basic intervention steps through reinforcement learning to obtain a multi-step therapeutic intervention path as a personalized child psychological intervention program.

[0224] Embodiments of this application also provide a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the aforementioned method embodiments.

[0225] Embodiments of this application also provide a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps in the above-described method embodiments.

[0226] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to in the description of the method embodiments. The device embodiments described above are merely illustrative. The components described as separate parts may or may not be physically separate, and 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 disclosure according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0227] The above-described embodiments are merely illustrative of several implementation methods of the embodiments of this application, and their descriptions are relatively specific and detailed. However, they should not be construed as limiting the scope of the patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the embodiments of this application, and these modifications and improvements all fall within the protection scope of the embodiments of this application.

Claims

1. A method for generating personalized child psychological intervention programs, characterized in that, The method includes: S1. Collect multimodal data of children, extract features from the multimodal data to obtain a multimodal feature sequence; wherein, the multimodal data includes facial expression videos, speech signals and physiological data; S2. Based on the multimodal feature sequence, perform psychological state analysis through a multimodal fusion neural network model to generate a dynamic psychological state time series; S3. Based on the dynamic psychological state time series, identify narrative elements through a pre-trained narrative element mapping model and generate a structured narrative element set; S4. Based on the structured narrative element set and the child's personalized information, generate personalized problem story text using a natural language generation model; S5. Based on the personalized problem story text and the set of structured narrative elements, match the best narrative framework from the narrative prototype library, and generate a basic intervention step sequence according to the best narrative framework. S6. By optimizing the sequence of the basic intervention steps through reinforcement learning, a multi-step therapeutic intervention path is obtained, which serves as a personalized psychological intervention plan for children.

2. The method according to claim 1, characterized in that, The step of performing psychological state analysis based on the multimodal feature sequence using a multimodal fusion neural network model to generate a dynamic psychological state time series vector includes: S11. Based on the facial region video frame sequence in the multimodal feature sequence, extract the spatiotemporal expression change features through a three-dimensional convolutional neural network to obtain the video feature vector; S12. Based on the speech signal segments in the multimodal feature sequence, extract prosodic variation features and timbre variation features through a bidirectional long short-term memory network to obtain a speech temporal feature vector; S13. Based on the video feature vector and the speech temporal feature vector, the contribution weight of each modality feature is calculated through an attention weight allocation mechanism to obtain a weighted fusion feature vector; S14. Based on the weighted fusion feature vector and the physiological signals in the multimodal feature sequence, cross-modal feature correlation analysis is performed through a fully connected neural network to obtain a psychological state vector; S15. Based on the continuously output psychological state vector, construct a sequence of psychological state data points with a preset sampling frequency to obtain the dynamic psychological state time series.

3. The method according to claim 1 or 2, characterized in that, The process of identifying narrative elements and generating a structured narrative element set based on the dynamic psychological state time series through a pre-trained narrative element mapping model includes: S21. Based on the theoretical framework of narrative psychology, a narrative psychology knowledge graph is constructed using a graph database, which includes the definition of emotional outburst point attributes, a classification system of positive ability display periods, and association rules of behavioral pattern turning points. S22. Based on the emotional valence and arousal dimensions in the dynamic psychological state time series, a sliding time window detection method is used to mark the time intervals within a continuous preset time period where the emotional valence is less than or equal to the emotional valence threshold and the arousal is greater than or equal to the arousal threshold as candidate regions for emotional outburst points; wherein, the emotional valence represents the positive or negative attribute of the emotion, indicating the degree of pleasure or unpleasantness of the individual's experience; the arousal represents the degree of autonomic nervous system response triggered by the emotion; S23. Based on the emotional valence sequence in the candidate region of emotional outburst points, locate the emotional trough point through peak detection, and extract a data segment in the candidate region of emotional outburst points with the emotional trough point as the center; extract the emotional fluctuation pattern and behavioral response features based on the data segment to obtain the emotional outburst point description object; S24. Based on the emotional valence dimension and attention concentration dimension in the dynamic psychological state time series, the continuous period detection algorithm identifies the period when the emotional valence is greater than or equal to the emotional valence threshold and the attention concentration is greater than or equal to the attention concentration threshold, extracts the high-frequency behavioral features in the period, and obtains the positive ability display period description object. S25. Based on the dynamic psychological state time series, the psychological state turning point is located by the first derivative mutation point detection algorithm, and the plot turning point logic is verified by combining the association rules of the narrative psychology knowledge graph to obtain the behavioral pattern turning point marker set. S26. Based on the description objects of the emotional outburst points, the description objects of the positive ability display periods, and the mark set of the behavioral pattern turning points, the temporal relationship between elements is established through the time axis alignment algorithm to generate the structured narrative element set of the triple.

4. The method according to claim 3, characterized in that, The process of matching the optimal narrative framework from the narrative prototype library based on the personalized problem story text and the structured narrative element set includes: S31. Based on the personalized problem story text, extract the text sentiment polarity distribution through a pre-trained sentiment analysis model, calculate the ratio of positive sentiment words to negative sentiment words according to the text sentiment polarity distribution, and obtain the quantitative value of the story sentiment tone. S32. Based on the number of objects describing emotional outbursts and the number of objects describing positive ability display periods in the structured narrative element set, calculate the outburst-ability ratio using the formula R=N_outburst_points / (N_outburst_points+N_ability_points); where R is the outburst-ability ratio, N_outburst_points is the number of objects describing emotional outbursts, and N_ability_points is the number of objects describing positive ability display periods. S33. Based on the quantitative value of the story's emotional tone and the value of the explosion-ability ratio, a two-dimensional feature vector is generated through vector concatenation to obtain the narrative matching feature vector; S34. Calculate the similarity between the narrative matching feature vector and the standard feature vector of each prototype in the preset narrative prototype library, and select the prototype with the highest similarity as the best narrative framework.

5. The method according to claim 4, characterized in that, The generation of the basic intervention step sequence based on the optimal narrative framework includes: S41. Based on the standard plot stage definition of the optimal narrative framework, extract the number of stages, stage themes and stage transition rules to obtain a plot stage description set. S42. Based on the behavioral pattern turning point marker set in the structured narrative element set, each turning point is matched with the plot stage transition point using a timeline alignment algorithm to obtain a stage-turning point mapping relationship table. S43. Based on the stage-turning point mapping relationship table and the plot stage description set, retrieve candidate activities that match the stage theme from the preset intervention activity library; S44. Based on the candidate activities, activities that match the child's cognitive abilities are selected through a rule engine, a phased activity filling plan is generated, and the basic intervention step sequence is obtained according to the phased activity filling plan.

6. A personalized child psychological intervention program generation device, used to implement the method according to any one of claims 1 to 5, characterized in that, The device includes: A multimodal data acquisition and feature extraction module is used to acquire multimodal data of children, extract features from the multimodal data, and obtain multimodal feature sequences; wherein, the multimodal data includes facial expression videos, speech signals, and physiological data; The multimodal psychological state analysis module is used to perform psychological state analysis based on the multimodal feature sequence through a multimodal fusion neural network model, and generate a dynamic psychological state time series. The narrative element parsing and structuring module is used to identify narrative elements based on the dynamic psychological state time series, through a pre-trained narrative element mapping model, and generate a set of structured narrative elements. The personalized question story generation module is used to generate personalized question story texts based on the structured narrative element set and the child's personalized information through a natural language generation model; The narrative framework matching and intervention step generation module is used to match the best narrative framework from the narrative prototype library based on the personalized problem story text and the set of structured narrative elements, and generate a basic intervention step sequence based on the best narrative framework. The intervention path optimization and program generation module is used to optimize the step sequence of the basic intervention steps through reinforcement learning to obtain a multi-step therapeutic intervention path as a personalized child psychological intervention program.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the method of any one of claims 1 to 5.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 5.