Real-time anxiety level evaluation method and system based on electroencephalogram signals
By combining personalized baseline calibration and two-stage time-series analysis with a bimodal baseline library and exponential moving average algorithm, the robustness and accuracy issues of EEG anxiety assessment were resolved, achieving stable and individualized anxiety level assessment and multimodal feedback, thus improving the user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENZHEN KUKAI BRAIN MACHINE INTELLIGENT TECHNOLOGY CO LTD
- Filing Date
- 2025-11-28
- Publication Date
- 2026-07-21
AI Technical Summary
Existing EEG anxiety assessment techniques are not robust, are susceptible to interference, have low accuracy, and lack individualized adaptation, leading to unstable assessment results and misjudgments.
Personalized baseline dynamic calibration and two-stage time series analysis are employed, combined with a dual-modal baseline library and an exponential moving average algorithm, to generate a physiological anxiety index through Mahalanobis distance calculation and smoothing, providing multimodal biofeedback.
It achieves stable and reliable individualized anxiety level assessment in high-noise environments, improves the accuracy and robustness of the assessment, provides intuitive multimodal feedback, and enhances the user experience.
Smart Images

Figure CN121647668B_ABST
Abstract
Description
Technical Field
[0001] This patent belongs to the field of bioinformatics and mental health technology, specifically involving a method and system for real-time, continuous and personalized assessment of an individual's anxiety level using electroencephalogram (EEG) signals. It is applicable to scenarios such as proactive health management, mental state monitoring, high-pressure occupational assistance, and emotion regulation training. Background Technology
[0002] Current technologies in the field of EEG-based anxiety assessment have the following main shortcomings: Poor robustness and susceptibility to interference: EEG signals are extremely weak (microvolt level) and highly susceptible to physiological artifacts (such as blinking and muscle activity) and environmental electromagnetic noise. Existing technical solutions mostly employ "static feature mapping" logic, which directly compares the calculated EEG features (such as the β / α ratio) with a fixed threshold. This method can misinterpret feature mutations caused by noise interference as drastic emotional fluctuations, leading to frequent jumps in assessment results and low reliability.
[0003] Low accuracy and lack of individualized adaptation: There are significant individual differences in the physiological baseline of brain activity. Different users may exhibit drastically different EEG characteristics (such as baseline energy levels of alpha and beta waves) even under the same relaxed state. Most existing technologies employ a "one-size-fits-all" model based on population statistics, ignoring individual differences and comparing all users to a uniform standard. This can lead to systematic assessment biases, such as misjudging naturally high EEG activity as anxiety or underestimating the true anxiety state of users with flat EEG activity.
[0004] In summary, existing technologies struggle to achieve real-time assessment of anxiety levels with "high robustness, high accuracy, and individualization," resulting in significant room for improvement in both the actual application effect and user experience of the product. Summary of the Invention
[0005] To address the aforementioned technical problems, this invention provides a real-time anxiety level assessment method based on electroencephalogram (EEG) signals, characterized by the following steps: Raw EEG signals are collected and preprocessed to extract multi-dimensional neurophysiological features. Personalized baseline dynamic calibration is performed based on a dual-modal baseline library. The raw anxiety score is calculated and smoothed through two-stage time series analysis. The smoothed score is normalized to generate a physiological anxiety index. Multimodal situational perception biofeedback is provided based on the physiological anxiety index. The two-stage time series analysis includes: In the first stage, the original anxiety score is obtained by calculating the Mahalanobis distance between the real-time feature vector and the dual-modal baseline and fusing them according to preset weights. The weight of the personalized baseline is higher than that of the normative baseline. The second stage uses an exponential moving average algorithm to smooth the original anxiety score over time, with a smoothing coefficient set to a preset small value between 0 and 1.
[0006] Preferably, the preprocessing includes: The digital time series data stream is segmented using an overlapping sliding window, filtered from 0.5Hz to 35Hz using a fourth-order Butterworth bandpass filter, and 50Hz or 60Hz power frequency interference is filtered out using a high-Q IIR notch filter. The analysis window duration of the sliding window is a preset fixed value, and the sliding time step is less than the analysis window duration.
[0007] Preferably, the multidimensional neurophysiological features are extracted after calculating the power spectral density using the Welch average periodogram method. The feature vector includes at least relative α power, relative β power, relative θ power, and β / α power ratio, with each feature represented as a percentage of the power in the corresponding frequency band to the total power.
[0008] Preferably, the bimodal baseline library includes personalized baselines and normative baselines. The personalized baselines establish an initial profile by guiding users to collect 3-5 minutes of relaxation state data upon first use. Subsequently, the mean vector and covariance matrix are dynamically updated with a preset learning rate based on the relaxation state actively marked by the user. The normative baselines are constructed based on statistical analysis of large-scale healthy population data.
[0009] Preferably, the physiological anxiety index is normalized to the 0-100 range by a linear transformation, which includes scaling and offset processing.
[0010] Preferably, the multimodal context-aware biofeedback includes: The numerical ranges of 0-30, 30-60, 60-80, and 80-100 are mapped to four levels of states: relaxed, focused, tense, and overloaded, which correspond to green, yellow, orange, and red visual symbols, respectively. Provide state interpretation and behavioral suggestions through at least two of the following channels: visual, textual, and auditory / tactile.
[0011] This invention provides a real-time anxiety level assessment system based on electroencephalogram (EEG) signals, comprising: The module includes data acquisition and preprocessing, feature extraction and baseline calibration, time series analysis and physiological anxiety index generation, and biofeedback and data management. The data acquisition and preprocessing module interfaces with the EEG sensor, the feature extraction and baseline calibration module is associated with a dual-modal baseline library, the time series analysis and physiological anxiety index generation module performs two-stage time series analysis, and the biofeedback and data management module outputs multimodal feedback and stores relevant data.
[0012] Preferably, the data acquisition and preprocessing module supports the deployment of at least one EEG electrode in the prefrontal cortex region, acquires raw EEG signals at a preset sampling frequency and performs amplification and analog-to-digital conversion, and the preprocessing includes sliding window segmentation, bandpass filtering and power frequency notch filtering.
[0013] Preferably, the relevant data stored in the biofeedback and data management module includes user EEG characteristic data and historical records of physiological anxiety index; When the physiological anxiety index is in the range of 60-100, auditory cues or device vibration feedback can be triggered.
[0014] Compared with the prior art, the beneficial effects of the present invention are as follows: The dual-modal baseline dynamic calibration mechanism includes both "personalized baselines" and "normative baselines." Specifically, it involves guiding users to establish personalized baselines upon first use and dynamically updating them in subsequent uses based on user-marked relaxation states. This mechanism is key to addressing individual differences and achieving accurate assessments, distinguishing it from the "one-size-fits-all" models of existing technologies.
[0015] This paper presents a two-stage time-series analysis algorithm that combines "instantaneous deviation scoring" and "continuous state smoothing," particularly focusing on the technical details of "first calculating the original anxiety score using weighted Mahalanobis distance, and then performing time-series smoothing using the exponential moving average (EMA) algorithm." This algorithm is crucial for ensuring the stability and reliability of evaluation results in high-noise environments, and it addresses the issue of poor robustness in existing technologies.
[0016] The integrated system architecture, from EEG signals to the Physiological Anxiety Index (PAI) and then to multimodal biofeedback, is particularly noteworthy. It maps PAI values to four levels of states: relaxation, focus, tension, and overload, and provides closed-loop feedback through visual, textual, auditory, and tactile senses. This complete "perception-understanding-action" closed loop is the core of ensuring the practicality and user value of the technological solution, realizing the transformation from data to value. Attached Figure Description
[0017] Figure 1 This is a flowchart of the method of the present invention; Figure 2 This is a flowchart detailing the preprocessing process of the present invention; Figure 3 This is a flowchart of the two-stage timing analysis of the present invention. Detailed Implementation
[0018] Please refer to Figure 1-3 This invention provides a closed-loop "collection-calibration-assessment-feedback" scheme for assessing individual real-time anxiety levels by combining personalized baseline dynamic calibration with two-stage time-series analysis. Specifically, it includes two parts: a method and a system. The core method steps are as follows: Data acquisition and preprocessing: responsible for converting raw EEG signals into high-quality digital analysis units.
[0019] Signal acquisition: Raw EEG signals are continuously acquired through at least one EEG electrode (e.g., deployed in the prefrontal cortex region), amplified and converted to digital data using an analog-to-digital converter (ADC), and then formed into a digital time-series data stream at a preset sampling frequency (e.g., 256 Hz).
[0020] Sliding window segmentation: The data stream is segmented using an overlapping sliding window technique. A fixed-duration analysis window (e.g., 5 seconds) is set and slides forward in a smaller time step (e.g., 1 second) to ensure the continuity of the evaluation and the stability of subsequent spectral analysis.
[0021] Signal purification: Perform the following steps sequentially within each analysis window: Zero-phase bandpass filtering: A fourth-order Butterworth bandpass filter (passband 0.5Hz-35Hz) is applied to effectively filter out baseline drift and high-frequency noise, while forward-backward filtering technology is used to avoid phase distortion.
[0022] Power frequency notch filtering: A high-Q IIR notch filter is used to accurately filter out 50Hz or 60Hz power line interference, ensuring the signal-to-noise ratio.
[0023] Neurophysiological feature extraction: Extracting multidimensional biomarkers that can characterize brain state from purified data.
[0024] Power spectral density (PSD) estimation: The Welch average periodogram method is used to calculate the PSD within the analysis window. This method significantly reduces the variance of the power spectrum estimation by averaging the overlapping sub-windows after windowing (such as the Hanning window), resulting in a stable and smooth energy distribution.
[0025] Multi-dimensional feature vector construction: based on Calculate the relative power (percentage of total power) within the key frequency band and construct a real-time feature vector. The formula for calculating relative power, taking the α band as an example: ; in, For relative power, For frequency Power spectral density at that location. Eigenvectors At least including: relatively power( ): Reflects a relaxed state.
[0026] relatively power( ): Reflects a state of mental tension and alertness.
[0027] relatively power( ): Related to cognitive load, used as an auxiliary indicator.
[0028] / Power ratio ( ): A core comprehensive indicator that characterizes the excitability of the cerebral cortex.
[0029] The calculation formula is as follows: ; Personalized baseline dynamic calibration: key to achieving individualized and accurate assessment, establishing and maintaining a unique physiological baseline model for each user.
[0030] Initial calibration: Upon first use, the system collects EEG data from the user in a deeply relaxed state through a guided procedure (such as instructing the user to close their eyes, sit quietly, and breathe deeply for 3-5 minutes). The system then performs statistical analysis on the feature vectors of this period to calculate the mean vector. Covariance Matrix Together, they constitute the user's initial personalized baseline profile. And store.
[0031] Dual-modal baseline library: The system has two built-in baseline reference systems: Personalized baseline ( Customized for each user, it is the core basis for assessing the deviation of their own state.
[0032] Normative baseline ( ): A universal baseline (including a mean vector) constructed through statistical analysis of large-scale healthy population data. Covariance Matrix It serves as an auxiliary reference, providing information about a user's relative position within the group and preventing excessive drift of the personalized baseline.
[0033] Baseline Dynamic Updates: The system supports long-term dynamic updates of the baseline. When a user actively marks a period of time as "relaxed" in the application, the system updates the feature vector of that period. With a small learning rate (e.g., 0.05, integrate and update the personalized baseline profile. The mean vector update formula is as follows:) ; Meanwhile, the covariance matrix It will also be adjusted synchronously through corresponding online update algorithms to enable it to capture long-term changes in the user's physiological state.
[0034] Two-stage temporal analysis is the core of the algorithm in this invention. It achieves robust and smooth decoding of anxious states through two stages: instantaneous state evaluation and continuous temporal smoothing.
[0035] Phase 1: Transient State Bias Scoring. This phase aims to respond quickly to significant changes in brain state. It will use real-time feature vectors... The raw anxiety score was calculated by comparing it with two baselines. The calculation rules are as follows: a. Calculate the Mahalanobis distance from the personalized baseline ( This distance reflects the statistical distance between the current state and the user's optimal relaxation state, and is the core basis for the score. Its calculation formula is: ; b. Calculate the Mahalanobis distance from the norm baseline ( This serves as an auxiliary correction. Its calculation formula is: ; c. A fusion score is generated using preset weights. The weights for the personalized baseline are as follows: (e.g., 0.8) is much higher than the baseline weight of the norm. (e.g., 0.2) to ensure a highly individualized assessment: .
[0036] Phase Two: Continuous State Smoothing Tracking.
[0037] This stage aims to filter out drastic fluctuations in evaluation results caused by transient noise and physiological artifacts. It employs an exponential moving average (EMA) algorithm to smooth the raw_score sequence generated in stage one over time. Its recursive update formula is: ; Among them, the smoothing coefficient A small value between 0 and 1 (such as 0.5) is used to balance the system's sensitivity and stability. A smaller α value can achieve stronger anti-interference capability and ensure a smooth and reliable output curve.
[0038] Physiological Anxiety Index (PAI) generation: responsible for converting internal scores into standardized final output.
[0039] The smoothed_score output by the dual-path time series analysis module is normalized to a standardized range of 0-100 through a preset linear transformation (scaling and offset) to generate the final physiological anxiety index (PAI).
[0040] ; in, (scaling factor) and The offset factor is a preset constant used to map the typical distribution range of smoothed_score to the 0-100 interval.
[0041] Context-aware biofeedback: This block is the application layer implementation of the present invention, which transforms the abstract PAI score into biofeedback information that users can understand and act upon, thus constructing a closed loop of "perception-understanding-action".
[0042] A. Four-level state mapping and interpretation: The PAI numerical range is mapped to four different state levels, and corresponding interpretations and behavioral suggestions are provided.
[0043] PAI0-30 → State: Relaxed / Visual identifier: Green.
[0044] Interpretation and advice: "The brain is in a calm and relaxed state, and thinking is clear. This is a good time for creative thinking, deep learning, or simply to enjoy a break." PAI30-60 → State: Focused / Visual identifier: Yellow.
[0045] Interpretation and suggestions: "You are working or studying efficiently, and your brain activity is at a moderate level. Please stay focused, and also remember to take short breaks from time to time to avoid overexertion." PAI60-80 → State: Stressed / Visual identifier: Orange.
[0046] Interpretation and suggestions: "The system has detected a sustained mental workload, and your mind is under stress. We suggest you take a 5-minute deep breathing exercise or briefly get up and move around to relieve stress." PAI80-100 → Status: Overloaded / Visual identifier: Red.
[0047] Interpretation and suggestions: "Warning: Your brain is under high load or in a state of anxiety. Please stop your current task immediately and engage in mindfulness meditation, listen to soothing music, or do other effective relaxation activities to restore your energy balance." B. Multimodal Feedback: Provide feedback to users through multiple channels such as visual (interface colors, charts), text (status descriptions and suggestions), and auditory / tactile (prompt sounds, device vibration), to build a closed loop of "perception-understanding-action".
[0048] Visual channel: The background color, dynamic charts, or indicators of the user interface will smoothly transition to the corresponding color (green, yellow, orange, red) according to the current status level, providing the most intuitive and immediate feedback.
[0049] Text Channel: The interface displays carefully crafted descriptive text and behavioral suggestions that match the status level. These texts are not only informing you of your status, but also providing empathetic and guiding prompts, such as "You are in a highly focused state" or "Your brain has been under constant tension; try a 5-minute deep breathing exercise to effectively relieve it."
[0050] Auditory / tactile channels: When entering an orange or red zone, the system can be configured to trigger a soft alert sound or device vibration to gently remind the user to pay attention to their status in non-visual interaction scenarios (such as when the user is focused on other tasks).
[0051] Supporting systems: Develop an integrated evaluation system comprising four core modules: Data acquisition and preprocessing module: Connects to the EEG sensor to receive raw signals in real time and complete purification processing.
[0052] Feature extraction and baseline calibration module: Extracts neurophysiological features from preprocessed data and performs dynamic calibration based on a bimodal baseline library.
[0053] Time series analysis and PAI generation module: Performs two-stage time series analysis to calculate and generate a standardized physiological anxiety index (PAI).
[0054] Biofeedback and Data Management Module: This module transforms PAI scores into user-understandable status information and behavioral suggestions, presents them in a multimodal manner, and is responsible for storing the user's EEG feature data and PAI history.
[0055] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.
[0056] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A real-time anxiety level assessment method based on electroencephalogram (EEG) signals, characterized in that, Includes the following steps: Raw EEG signals are collected and preprocessed to extract multi-dimensional neurophysiological features. Personalized baseline dynamic calibration is performed based on a dual-modal baseline library. The raw anxiety score is calculated and smoothed through two-stage time series analysis. The smoothed score is normalized to generate a physiological anxiety index. Multimodal situational perception biofeedback is provided based on the physiological anxiety index. The two-stage time series analysis includes: In the first stage, the original anxiety score is obtained by calculating the Mahalanobis distance between the real-time feature vector and the dual-modal baseline and fusing them according to preset weights. The weight of the personalized baseline is higher than that of the normative baseline. The second stage uses an exponential moving average algorithm to smooth the original anxiety score over time, with a smoothing coefficient set to a preset small value between 0 and 1.
2. The method according to claim 1, characterized in that, The preprocessing includes: The digital time series data stream is segmented using an overlapping sliding window, filtered from 0.5Hz to 35Hz using a fourth-order Butterworth bandpass filter, and 50Hz or 60Hz power frequency interference is filtered out using a high-Q IIR notch filter. The analysis window duration of the sliding window is a preset fixed value, and the sliding time step is less than the analysis window duration.
3. The method according to claim 1, characterized in that, The multidimensional neurophysiological features were extracted after calculating the power spectral density using the Welch average periodogram method. The feature vector includes at least relative α power, relative β power, relative θ power, and β / α power ratio. Each feature is characterized as a percentage of the power in the corresponding frequency band to the total power.
4. The method according to claim 1, characterized in that, The bimodal baseline library includes personalized baselines and normative baselines. Personalized baselines establish an initial profile by guiding users to collect 3-5 minutes of relaxation state data upon first use. Subsequently, the mean vector and covariance matrix are dynamically updated with a preset learning rate based on the relaxation state actively marked by the user. Normative baselines are constructed based on statistical analysis of large-scale healthy population data.
5. The method according to claim 1, characterized in that, The physiological anxiety index is normalized to the 0-100 range by a linear transformation, which includes scaling and offset processing.
6. The method according to claim 1, characterized in that, The multimodal context-aware biofeedback includes: The numerical ranges of 0-30, 30-60, 60-80, and 80-100 are mapped to four levels of states: relaxed, focused, tense, and overloaded, which correspond to green, yellow, orange, and red visual symbols, respectively. Provide state interpretation and behavioral suggestions through at least two of the following channels: visual, textual, and auditory / tactile.
7. A real-time anxiety level assessment system based on electroencephalogram (EEG) signals, characterized in that, To implement the method according to any one of claims 1 to 6, comprising: The module includes data acquisition and preprocessing, feature extraction and baseline calibration, time series analysis and physiological anxiety index generation, and biofeedback and data management. The data acquisition and preprocessing module interfaces with the EEG sensor, the feature extraction and baseline calibration module is associated with a dual-modal baseline library, the time series analysis and physiological anxiety index generation module performs two-stage time series analysis, and the biofeedback and data management module outputs multimodal feedback and stores relevant data.
8. The system according to claim 7, characterized in that, The data acquisition and preprocessing module supports the deployment of at least one EEG electrode in the prefrontal cortex region, acquires raw EEG signals at a preset sampling frequency and performs amplification and analog-to-digital conversion. The preprocessing includes sliding window segmentation, bandpass filtering and power frequency notch filtering.
9. The system according to claim 7, characterized in that, The biofeedback and data management module stores relevant data including user EEG characteristic data and historical records of physiological anxiety index; When the physiological anxiety index is in the range of 60-100, auditory cues or device vibration feedback can be triggered.