Abnormal sleep state reminding method and system, terminal and storage medium

By combining large-scale model technology with sensors, edge devices, and cloud analytics, low-cost, continuous sleep abnormality monitoring and personalized reminders are achieved, solving the problem that traditional devices cannot accurately identify sleep abnormalities and improving users' sleep health management capabilities.

CN121867692APending Publication Date: 2026-04-17JIAXING ZHONGQING YIDA INTELLIGENT MANUFACTURING CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
JIAXING ZHONGQING YIDA INTELLIGENT MANUFACTURING CO LTD
Filing Date
2025-12-31
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Traditional sleep monitoring devices cannot achieve daily, continuous, low-cost, multi-dimensional data collection and accurate identification of sleep abnormalities, and lack personalized reminder functions, thus failing to meet the public's long-term and convenient monitoring needs for sleep health.

Method used

Employing large-scale modeling technology, sleep data is collected in real time through sensors. After preprocessing by edge devices, the data is uploaded to the cloud, where it is modeled and analyzed. Combined with multi-source physiological data, abnormal states are identified, and personalized reminders are generated, supporting user terminal display and voice broadcast.

Benefits of technology

It enables continuous home monitoring, improves the usability and convenience of sleep data, accurately identifies sleep abnormalities and provides personalized suggestions, reduces equipment costs, and enhances user experience and health management capabilities.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121867692A_ABST
    Figure CN121867692A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of sleep health monitoring, in particular to an abnormal sleep state reminding method and system, a terminal and a storage medium. The method comprises the following steps: collecting original data of a user during sleep in real time through a sensor; the edge device performs preprocessing and feature extraction on the original data to obtain sleep feature data and uploads the sleep feature data to the cloud; the cloud stores the data, and when the data size reaches a preset threshold value, a sleep data distribution model is established based on historical data; continuing to upload real-time and night sleep data in a subsequent sleep cycle, and judging whether the sleep state of the user is abnormal or not by the cloud in combination with the model; and when the judgment result shows that the abnormality exists, inputting the abnormal condition into a large language model by utilizing a cue word technology to generate a sleep abnormality prompt, and generating an improvement suggestion based on the sleep knowledge base and pushing the improvement suggestion to the user. According to the invention, household continuous sleep monitoring can be realized, sleep abnormity can be accurately identified, personalized improvement guidance can be provided, and sleep health management efficiency and user experience can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of sleep monitoring, and more specifically, to a method, system, terminal, and storage medium for alerting abnormal sleep states. Background Technology

[0002] As people increasingly pursue a healthy quality of life, sleep health is receiving more and more attention. Sleep occupies about one-third of a person's life, and good sleep is crucial for physical recovery and the maintenance of cognitive function. According to statistics, about one-third of adults worldwide suffer from sleep disorders. Sleep abnormalities not only affect the quality of daily life, but long-term accumulation may also lead to serious health risks such as cardiovascular and cerebrovascular diseases and mental illnesses.

[0003] Traditional sleep monitoring methods, such as simple motion monitoring devices, can only roughly determine sleep duration and the approximate periods of light and deep sleep, and cannot accurately capture the complex physiological changes during sleep. While polysomnography (PSG) is the "gold standard" for sleep monitoring, its equipment is complex, it needs to be conducted in a professional sleep laboratory, and it is expensive, making it impossible to achieve daily and continuous sleep monitoring and failing to meet the public's need for long-term and convenient monitoring of sleep health.

[0004] In recent years, artificial intelligence technology has flourished, especially large-scale modeling technology, which has made breakthroughs in fields such as natural language processing and image recognition. Large-scale models possess powerful data analysis and pattern recognition capabilities, enabling them to process massive, multi-source, and complex data. Introducing large-scale modeling technology into the field of sleep monitoring offers a new opportunity to overcome the limitations of traditional sleep monitoring methods. By integrating various sleep-related physiological and environmental data, large-scale models are expected to accurately identify abnormal sleep states, provide users with timely personalized alerts for sleep abnormalities, help improve sleep quality, and prevent health risks caused by sleep problems.

[0005] Currently, traditional sleep monitoring methods can only roughly determine sleep duration and the approximate periods of light and deep sleep, and cannot accurately capture the complex physiological changes during sleep. While polysomnography (PSG) is the "gold standard" for sleep monitoring, its equipment is complex, it needs to be conducted in a professional sleep laboratory, and it is expensive, making it impossible to achieve daily and continuous sleep monitoring and failing to meet the public's demand for long-term and convenient monitoring of sleep health.

[0006] Even though some devices can collect multiple data sources, they lack powerful data analysis capabilities, making it impossible to effectively integrate and comprehensively analyze multi-dimensional data. This prevents the discovery of potential correlations between different data points, hindering the accurate identification of complex sleep abnormalities and limiting the diagnosis and intervention of sleep problems. Summary of the Invention

[0007] In view of the shortcomings of the existing technology, the purpose of this invention is to provide a method, system, terminal and storage medium for alerting abnormal sleep states based on a large model.

[0008] To achieve the above objectives, the present invention provides the following technical solution: The method, system, terminal, and storage medium for alerting sleep abnormalities based on a large model include the following aspects: A method for alerting sleep abnormalities, which includes the following steps: Data Acquisition: Real-time acquisition of raw data during the user's sleep, including sound signals and body movement signals, through sensors.

[0009] Edge processing: The edge device preprocesses the raw data, including filtering, noise reduction, and feature extraction, to obtain sleep feature data and upload it to the cloud.

[0010] Data storage: The cloud server receives the sleep characteristic data and stores it in the database.

[0011] Modeling and Analysis: When the amount of data reaches a preset threshold, the cloud performs modeling based on historical sleep data, and uses maximum likelihood estimation to determine the mean and variance of the feature data distribution, forming a sleep data distribution model.

[0012] Real-time monitoring: Real-time data continues to be collected and uploaded during subsequent sleep cycles, with edge devices periodically uploading sleep data for the entire night to the cloud.

[0013] Anomaly detection: The cloud platform uses real-time data and data from the entire night, combined with the sleep data distribution model, to determine whether there are any abnormal sleep states.

[0014] Prompt word generation and alerts: When an anomaly is detected, a prompt word is generated in the cloud and input into the large language model to generate a sleep anomaly alert in natural language text, which is then sent to the user's terminal.

[0015] Knowledge base matching and suggestion generation: When an anomaly occurs, the system queries the pre-built sleep knowledge base for corresponding improvement solution keywords, inputs them into a large model to generate personalized improvement suggestions, and pushes them to the user.

[0016] Furthermore, a sleep disorder alert system, which includes: Sensors are used to collect sleep data in real time; Edge devices are used for data preprocessing and uploading; The cloud server includes a data storage module, a modeling module, an anomaly detection module, an alert generation module, and a knowledge base module; The user terminal is used to receive and display reminders and improvement suggestions.

[0017] Furthermore, the user terminal is used to receive sleep abnormality alerts and improvement suggestions from the cloud and present them to the user through voice broadcast or interface display.

[0018] Furthermore, a computer-readable storage medium: a computer program is stored on the storage medium, which, when executed by a processor, implements the steps of the above-described sleep abnormality alert method.

[0019] By adopting the above technical solution, the beneficial effects of the present invention are as follows: 1. Enable continuous home monitoring and improve usability This invention enables users to collect long-term, continuous sleep data in their home environment through the collaborative work of sensors, edge devices, and the cloud. It overcomes the limitations of polysomnography (PSG), which requires laboratory testing, is costly, and cumbersome, allowing ordinary users to obtain professional-grade sleep monitoring data at low cost and without invasive procedures.

[0020] The system supports automatic data upload and cloud storage, allowing users to automate the entire process without manual intervention, greatly improving ease of use and compliance.

[0021] 2. Multi-source data fusion and accurate identification By collecting multi-dimensional physiological characteristics such as sound signals, respiratory rate, heart rate, and heart rate variability (HRV), this invention can more comprehensively reflect the user's sleep state.

[0022] By using maximum likelihood estimation to model historical data and forming an individualized sleep feature distribution model, the sensitivity and specificity of anomaly identification can be improved, and false alarms and false negatives can be reduced.

[0023] The system supports dual judgment of real-time data and overnight data, which can both identify dangerous situations in real time and comprehensively assess the quality of sleep throughout the night.

[0024] 3. Intelligent and personalized reminders Based on prompt word technology and a large language model, this invention can generate personalized, natural and fluent sleep abnormality reminders, avoiding rigid technical prompts and enhancing user experience.

[0025] By combining a sleep knowledge base, detected abnormalities are mapped to specific health recommendations, such as "suggest improving the sleep environment" or "suggesting breathing training," thereby enhancing the operability and scientific validity of the guidance.

[0026] 4. Adaptive optimization and continuous improvement The cloud-based model can be dynamically updated based on long-term user data, enabling the system to adapt to individual differences and improve recognition accuracy.

[0027] User feedback can be used to improve the knowledge base and optimize the prompt word generation logic, enabling closed-loop learning and continuous improvement, and ensuring that reminders and suggestions become increasingly accurate.

[0028] 5. Health Management and Risk Prevention By tracking and analyzing sleep data over a long period, this invention can detect trends of declining sleep quality in advance, providing a reference for users and doctors and preventing risks such as chronic insomnia and sleep apnea syndrome.

[0029] The real-time alert function can immediately notify the user when an anomaly is detected, helping to avoid potential dangers from sudden situations during sleep. Attached Figure Description

[0030] Figure 1 This is a flowchart of the method according to an embodiment of the present invention. Detailed Implementation

[0031] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0032] In the description of this invention, it should be understood that the terms "upper", "lower", "front", "rear", "left", "right", "top", "bottom", "inner", "outer", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this invention.

[0033] A method, system, terminal, and storage medium for alerting sleep abnormalities based on a large model, with the process as follows: Figure 1 As shown, the method includes: Step 1: The sensor collects raw data from the user during sleep in real time; specifically, a capacitive microphone sensor is used for collection and measurement.

[0034] Step 2: The edge device calculates sleep characteristic data from the raw data collected by the sensors and uploads it to the cloud.

[0035] Step 3: The cloud stores the processed data into the database.

[0036] Step 4: When the amount of data reaches a certain level, the cloud uses historical data to model the sleep data.

[0037] Step 5: The sensor collects the user's sleep data in real time.

[0038] Step 6: The edge device uploads the sleep data from the entire night to the cloud.

[0039] Step 7: The cloud platform determines the user's sleep status based on the sleep data and the model established in Step 4.

[0040] Step 8: Based on the judgment results, the cloud uses prompt word technology to generate sleep abnormality reminders for the user through a large language model and sends the generated results to the user.

[0041] Step 9: Based on professional knowledge in the field of sleep, construct a sleep knowledge base. When user data shows abnormalities or alerts, input the alerts or abnormalities into the knowledge base to obtain corresponding suggested keywords. The large model generates suggestions for the user based on the keywords and sends them to the user.

[0042] Step 2 includes the following steps: Step 2.1: Perform Fourier transform on the collected sound data to obtain the frequency domain characteristics of the continuous waveform, and sample the frequency domain data according to HRV theory to obtain human characteristic data such as human respiratory rate, heart rate and cardiac variability that are of practical significance.

[0043] Step 2.2: Upload the collected data to Alibaba Cloud every three minutes.

[0044] In the specific implementation of this invention, the edge device preprocesses the raw data to ensure the accuracy and stability of feature extraction.

[0045] 1. Filtering and Denoising Methods Bandpass filters were used to effectively filter out environmental noise and high-frequency interference from the collected sound and heart rate signals; wavelet denoising algorithms or empirical mode decomposition (EMD) were introduced for body movement and respiratory signals to eliminate baseline drift and random noise; median filtering was used to smooth residual spike noise.

[0046] 2. Fourier Transform and Feature Extraction The acquired continuous signal is segmented according to a time window, and each segment is processed using a windowing function (such as the Hanning window) to avoid spectral leakage; assuming the sampling frequency is f_s If the window length is N, then the Fourier transform formula for the k-th frequency point is:

[0047] Where w(n) is the window function and N is the number of sampling points. The peak frequencies and power distributions of respiratory rate and heart rate are extracted through spectral analysis.

[0048] 3. HRV Calculation Method Based on the detection of RR intervals from heart rate signals, a time series was constructed. Time-domain metrics included: SDNN (standard deviation) and RMSSD (root mean square of squared adjacent differences). Frequency-domain metrics included: calculating low-frequency power (LF: 0.04–0.15 Hz) and high-frequency power (HF: 0.15–0.40 Hz) using Fast Fourier Transform, and calculating the LF / HF ratio. These HRV features served as important inputs to the subsequent anomaly detection model.

[0049] Step 3 includes the following steps: Step 3.1: The Alibaba Cloud server receives sleep data uploaded from the edge device every three minutes.

[0050] Step 3.2: The server integrates the newly received data with historical data and determines whether the amount of data stored by the smart bed exceeds the data limit. If it exceeds the storage limit, the older portion of the data in the database is deleted.

[0051] This invention employs anomaly detection to identify abnormal sleep data. The first step is data modeling, which is primarily done in step 4. Step 4 includes the following steps: Step 4.1: Determine if the amount of data in the database is sufficient. If the amount of data does not meet the set requirement, return to step 1 and continue collecting data from the sensor. If the amount of data meets the set requirement, proceed to the next step, 4.2. Step 4.2: Make assumptions about the data distribution using historical data; Step 4.3: Calculate the specific data distribution using the maximum likelihood estimation method.

[0052] In a specific embodiment of the present invention, the detailed steps of step 4 are as follows: Step 4.1: Determine whether the amount of data in the Alibaba Cloud server database has reached 7 days. If the amount of data has not reached 7 days, return to step 1 and continue to collect data from the smart bed. If the amount of data has reached 7 days, proceed to step 4.2. Step 4.2: By analyzing historical sleep data, determine whether the calculated sleep data characteristics conform to a normal distribution; Step 4.3: Calculate the mean and variance of the normal distribution corresponding to each sleep feature data using the maximum likelihood estimation method.

[0053] In the modeling and analysis process of this invention, statistical models or machine learning models are used to model user sleep characteristics in order to achieve accurate identification of abnormal states.

[0054] 1. Model Type Statistical Model: This invention uses a normal distribution model. 2. Maximum likelihood estimation formula Taking the normal distribution as an example, the parameter estimation formula is:

[0055] in, and These are the maximum likelihood estimates of the mean and variance, respectively.

[0056] 3. Threshold setting rules When real-time data deviates from the distribution model by more than 2σ or the 95% confidence interval, it is judged as a mild anomaly; when it deviates by more than 3σ or the 99% confidence interval, it is judged as a severe anomaly and an immediate alert is triggered.

[0057] 4. Model update cycle The model is updated using a sliding window, with the window size being the data from the past 7–14 days. The model parameters are automatically retrained or corrected at the end of each new cycle. When a long-term trend change in the user's physiological state is detected, the model's adaptive update mechanism is triggered to ensure that the model is dynamically optimized over time.

[0058] Step 6 includes the following steps: Step 6.1: During the nighttime sleep period, the edge device uploads data to the cloud every 3 minutes.

[0059] Step 6.2: After the sleep period ends, the cloud integrates the sleep data from every 3 minutes into a single night's sleep data.

[0060] Step 7 is the core part of the system architecture of this invention, and the specific process is shown below. Step 7 includes the following steps: Step 7.1: At the start of each night's sleep period, the cloud will retrieve information on edge devices that need to access the reminder function from the database; Step 7.2: For newly added devices, determine whether the amount of data for the corresponding device in the database is sufficient. If the amount of data is sufficient, proceed to step 4, calculate the data distribution parameters, and add the device to the list of alert devices. Step 7.3: Create a thread for each device in the reminder device list in the cloud, set a scheduled task, and start executing it during the sleep period; Step 7.4: When the set start time is reached, the scheduled task begins execution. First, it is determined whether the current time period is within the sleep period. If not, the thread task is terminated. If it is within the sleep period, step 7.5 is executed sequentially. Step 7.5: The edge device uploads real-time data to the thread task. The thread task then uses the real-time data to determine whether any abnormalities have occurred in the user's sleep data.

[0061] Step 7.6: Based on the data from the entire night, the cloud inputs the data from the entire night into the data model obtained in step 4 to determine whether there are any abnormalities in the user's data from the entire night.

[0062] In a specific embodiment of the present invention, the detailed steps of step 7 are as follows: Step 7.1: At the start of each night's sleep period, the cloud retrieves information on edge devices that need to access the reminder function from the database. The sleep period is the time period set by the user. If the user does not set a sleep period, the default sleep period will be used. Step 7.2: Detect whether the smart bed is a new device that needs to be reminded. If it is a new device, check if there is 7 days of historical data for the smart bed in the database. If there is no 7 days of data, continue to collect data. If there is enough data, calculate the parameters of the device and record them in the database and the reminder device list. Step 7.3: Create a separate thread in the cloud for each edge device that needs the reminder function, and set a scheduled task to be executed during the sleep period; Step 7.4: When the start time of the sleep period is reached, the scheduled task is executed. First, it is determined whether the current time has exceeded the user-set sleep end time. If the sleep end time has been reached, the thread task is terminated. Otherwise, step 7.5 is executed sequentially. Step 7.5: The executing thread task obtains the current user's real-time sleep data from the edge device and determines whether the data is abnormal.

[0063] Step 7.6: Based on the data from the entire night, the cloud inputs the data from the entire night into the data model obtained in step 4 to determine whether there are any abnormalities in the user's data from the entire night.

[0064] Step 8 includes the following steps: Step 8.1: The cloud system integrates real-time sleep abnormalities and sleep abnormalities throughout the night to determine whether to issue a warning to the user. Step 8.2: Automatically generate prompt words based on abnormal situations; Step 8.3: Use the generated prompt words as input to the large language model, obtain the generated text, and send it to the user.

[0065] Step 9 includes the following steps: Step 9.1: Establish a knowledge base for sleep problems based on knowledge in the field of sleep. Step 9.2: When abnormal sleep data is detected, search the knowledge base for the corresponding solution keywords. Step 9.3: Input the keywords into the large model and obtain the corresponding text output; Step 9.4: Send the text to the user.

[0066] In a specific embodiment of the present invention, the detailed steps of step 9 are as follows: Step 9.1: Based on existing sleep theories, establish reasonable ranges for sleep-related data (such as heart rate, HRV data, etc.) and improvement plans for data exceeding reasonable ranges, and save them as a dictionary to the cloud. Step 9.2: When abnormal sleep data is received from the cloud, search for corresponding improvement solutions or suggestions for users in the stored dictionary; Step 9.3: Input the results obtained in 9.2 as prompt words into the large model. The large model will convert the prompt words into more easily understood text.

[0067] Step 9.4: The cloud sends the text to the terminal, and the terminal reads it to the user.

[0068] This invention employs a large-scale model-based approach to comprehensively analyze various user data, providing suggestions and identifying specific anomalies to offer corresponding guidance. Simultaneously, it enables real-time voice interaction with users, collecting and analyzing user feedback for a better understanding of user issues.

[0069] This invention can track users' sleep data over a long period of time, analyze time-series data, and provide a comprehensive analysis of users' sleep abnormalities based on their daily sleep patterns.

[0070] This invention adds a sleep knowledge base to the large model, which can provide improvement suggestions for users' daily abnormalities and combine with the large model to convey them to users through easy-to-understand voice.

[0071] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any ordinary changes and substitutions made by those skilled in the art within the scope of the technical solution of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for alerting to abnormal sleep states, characterized in that, include: Step 1: Collect raw data from the user during sleep in real time using sensors; Step 2: The edge device performs feature processing on the raw data to obtain sleep feature data and uploads it to the cloud; Step 3: The cloud receives the sleep feature data and stores it in the database; Step 4: When the amount of data in the database reaches a preset threshold, establish a sleep data distribution model based on the historical data. Step 5: Continue to collect the user's sleep characteristic data in real time during subsequent sleep cycles; Step 6: The edge device uploads the sleep data for the entire night during the sleep cycle to the cloud; Step 7: The cloud platform determines whether the user's sleep status is abnormal based on the entire night's sleep data and the sleep data distribution model. Step 8: When sleep abnormality is determined, the cloud uses prompt word technology to take the sleep abnormality as input, calls the large language model to generate a sleep abnormality reminder for the user and sends it to the user terminal. Step 9: When sleep abnormalities occur, search for corresponding improvement suggestion keywords in the sleep knowledge base, input the keywords into the large language model to generate improvement suggestion text, and send it to the user terminal.

2. The method according to claim 1, characterized in that, The sensor is a capacitive microphone sensor used to collect sound signals during the user's sleep.

3. The method according to claim 1, characterized in that, Step 2 includes: The collected sound data is subjected to Fourier transform to obtain frequency domain features; Based on the theory of heart rate variability, respiratory rate, heart rate, and cardiac variability human characteristic data are extracted from the frequency domain features.

4. The method according to claim 1, characterized in that, In step 4, the sleep data distribution model is a normal distribution model, and the model parameters are determined by the maximum likelihood estimation method.

5. The method according to claim 1, characterized in that, The cloud retrieves information on edge devices that need to access the reminder function from the database at the beginning of each night's sleep cycle, and creates an independent thread timed task for each device to monitor sleep abnormalities in real time.

6. The method according to claim 1, characterized in that, The sleep knowledge base includes reasonable ranges for sleep characteristic parameters such as heart rate, HRV, and respiratory rate, as well as corresponding improvement plans.

7. A sleep abnormality alert system based on a large model, characterized in that, include: Sensors are used to collect raw data from users during sleep. An edge device is used to receive the raw data, calculate sleep feature data, and upload the sleep feature data to the cloud; Cloud servers, including: Data storage module, used to store the sleep characteristic data; The modeling module is used to build a sleep data distribution model based on historical data when the amount of data reaches a preset threshold. The anomaly detection module is used to determine whether the user's sleep state is abnormal based on real-time and overnight sleep data; The reminder generation module is used to generate sleep abnormality reminder text based on the judgment result and send it to the user terminal. The knowledge base module stores reasonable ranges for sleep parameters and improvement plans, and provides keywords for the reminder generation module to call when an anomaly occurs.

8. A user terminal, characterized in that, The user terminal receives the sleep abnormality reminder text or improvement suggestions issued by the system of claim 7, and outputs them to the user in the form of voice or text.

9. A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method according to any one of claims 1 to 6.