Intelligent sleep monitoring evaluation method and system based on openclaw
Patent Information
- Application Number
- CN202610859148.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-15
- Publication Date
- 2026-08-21
AI Technical Summary
[0005]本发明提供一种基于OpenClaw的智能睡眠监测评估方法及系统,以解决现有睡眠监测准确性较低的技术问题
[0008]上述基于OpenClaw的智能睡眠监测评估方法及系统所实现的方案中,可以采集用户睡眠过程中的多维度生理参数,对所述多维度生理参数进行预处理和特征提取,生成多模态特征数据;通过所述多Agent调度层中的睡眠监测Agent将所述多模态特征数据共享给姿态调节Agent、智能唤醒Agent以及场景联动Agent;通过所述多Agent调度层协调所述睡眠监测Agent、所述姿态调节Agent、所述智能唤醒Agent以及所述场景联动Agent从所述持久化记忆模块中获取用户睡眠特征数据;将所述用户睡眠特征数据及所述多模态特征数据上传至云端数据处理平台,以使所述云端数据处理平台根据所述多模态特征数据进行多模态特征融合与睡眠阶段识别得到睡眠阶段序列,根据所述睡眠阶段序列和所述用户睡眠特征数据生成睡眠监测评估报告。在本发明中,通过采集多维度生理参数生成多模态特征数据,克服了单一传感器监测维度不足的缺陷;通过多Agent调度层协调各Agent从持久化记忆模块获取用户睡眠特征数据,实现个性化适配;云端数据处理平台对多模态特征数据进行融合与睡眠阶段识别,并结合用户睡眠特征数据生成睡眠监测评估报告,利用多模态数据互补性和用户历史数据基准,提升了睡眠监测的准确性。
Smart Images

Figure CN122604313A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of sleep monitoring technology, and in particular to an intelligent sleep monitoring and assessment method and system based on OpenClaw. Background Technology
[0002] With increasing health awareness and the rapid development of artificial intelligence technology, sleep quality is receiving more and more attention. Sleep stage identification is the core foundation of sleep quality assessment; accurate sleep stage identification helps users understand sleep structure, identify sleep problems, and develop improvement plans. However, the accuracy rate of existing sleep monitoring technologies is generally low, making it difficult to meet users' needs for precise sleep assessment. Therefore, improving the accuracy of sleep monitoring has become an important research direction in the field of smart sleep devices.
[0003] A related technology discloses a sleep monitoring method based on wearable devices. This method integrates photoelectric sensors and accelerometers into a smartwatch or smart bracelet, collecting the user's heart rate and body movement data, and combining heart rate variability analysis and body movement frequency characteristics to determine sleep stages. However, this method suffers from wearing comfort issues; some users experience discomfort from wearing the wearable device for extended periods, affecting their sleep experience. Furthermore, its data collection dimensions are limited, relying primarily on heart rate and body movement data, making it difficult to comprehensively reflect sleep states. Since the heart rate difference between light and deep sleep stages is small, relying solely on heart rate data is insufficient for accurate sleep stage identification. In addition, the battery life limitations of wearable devices prevent continuous overnight monitoring, and the accuracy of identification is also limited.
[0004] A related technology discloses a sleep monitoring system based on a pressure sensor array. This system collects pressure distribution data of a user lying on the mattress by arranging an array of pressure sensors inside the mattress. It then determines the user's sleeping posture and body movement based on changes in pressure distribution, thereby identifying sleep stages. However, the pressure sensors in this system have difficulty distinguishing between the user's static activity state, such as whether the user is reading in bed or falling asleep. Furthermore, single-modal data is easily affected by environmental interference, and misjudgments can occur when the user turns over or interacts with their partner, resulting in low accuracy in sleep stage identification and overall low accuracy in sleep monitoring. Summary of the Invention
[0005] This invention provides an intelligent sleep monitoring and assessment method and system based on OpenClaw to solve the technical problem of low accuracy in existing sleep monitoring.
[0006] Firstly, an intelligent sleep monitoring and evaluation method based on OpenClaw is provided, applied to a smart bed. The smart bed includes a main control module, which includes a multi-agent scheduling layer and a persistent memory module built based on OpenClaw. The method includes: Collect multi-dimensional physiological parameters during the user's sleep process, preprocess and extract features from the multi-dimensional physiological parameters to generate multimodal feature data; The sleep monitoring agent in the multi-agent scheduling layer shares the multimodal feature data with the posture adjustment agent, the smart wake-up agent, and the scene linkage agent. The multi-agent scheduling layer coordinates the sleep monitoring agent, posture adjustment agent, smart wake-up agent, and scene linkage agent to obtain user sleep feature data from the persistent memory module. The user's sleep feature data and the multimodal feature data are uploaded to a cloud data processing platform, so that the cloud data processing platform can perform multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, and generate a sleep monitoring and evaluation report based on the sleep stage sequence and the user's sleep feature data.
[0007] Secondly, an intelligent sleep monitoring and assessment system based on OpenClaw is provided, including a smart bed and a cloud data processing platform, wherein the smart bed includes: A multimodal sensor module is used to collect multi-dimensional physiological parameters during the user's sleep process; An edge computing module is used to preprocess and extract features from the multi-dimensional physiological parameters to generate multimodal feature data; The main control module includes a multi-agent scheduling layer built on OpenClaw, a persistent memory module, and a skill library. The multi-agent scheduling layer includes a sleep monitoring agent, a posture adjustment agent, a smart wake-up agent, and a scene linkage agent, used to coordinate the acquisition of user sleep feature data from the persistent memory module by each agent. The sleep monitoring agent shares the multimodal feature data with the posture adjustment agent, the smart wake-up agent, and the scene linkage agent. The skill library is used to issue control commands generated by each agent. The cloud-based data processing platform is communicatively connected to the edge computing module and the multi-agent scheduling layer. It is used to receive the multimodal feature data and the user sleep feature data, perform multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, and generate a sleep monitoring and evaluation report based on the sleep stage sequence and the user sleep feature data.
[0008] The aforementioned solution based on OpenClaw for intelligent sleep monitoring and evaluation involves collecting multi-dimensional physiological parameters during a user's sleep process, preprocessing and extracting features from these parameters to generate multimodal feature data. The sleep monitoring agent in the multi-agent scheduling layer shares this multimodal feature data with the posture adjustment agent, intelligent wake-up agent, and scene linkage agent. The multi-agent scheduling layer coordinates the sleep monitoring agent, posture adjustment agent, intelligent wake-up agent, and scene linkage agent to retrieve user sleep feature data from the persistent memory module. The user sleep feature data and the multimodal feature data are then uploaded to a cloud data processing platform. This platform performs multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence. Finally, a sleep monitoring and evaluation report is generated based on the sleep stage sequence and the user sleep feature data. In this invention, multimodal feature data is generated by collecting multidimensional physiological parameters, overcoming the shortcomings of insufficient monitoring dimensions by a single sensor; personalized adaptation is achieved by coordinating each agent to obtain user sleep feature data from the persistent memory module through a multi-agent scheduling layer; the cloud data processing platform fuses the multimodal feature data and identifies sleep stages, and generates a sleep monitoring evaluation report by combining the user sleep feature data, thereby improving the accuracy of sleep monitoring by utilizing the complementarity of multimodal data and the benchmark of user historical data. Attached Figure Description
[0009] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0010] Figure 1 This is a system block diagram of an intelligent sleep monitoring and evaluation method based on OpenClaw in one embodiment of the present invention; Figure 2 This is a flowchart illustrating an intelligent sleep monitoring and evaluation method based on OpenClaw in one embodiment of the present invention; Figure 3 yes Figure 1 A schematic diagram of a specific implementation of step S110; Figure 4 yes Figure 1 A schematic diagram of a specific implementation of step S130; Figure 5 yes Figure 1A schematic diagram of a specific implementation of step S140; Figure 6 This is a flowchart illustrating an intelligent sleep monitoring and evaluation method based on OpenClaw in another embodiment of the present invention; Figure 7 This is a flowchart illustrating an intelligent sleep monitoring and evaluation method based on OpenClaw in another embodiment of the present invention; Figure 8 This is a schematic block diagram of a smart bed provided as an embodiment of the present invention.
[0011] Figure label: 10. OpenClaw-based intelligent sleep monitoring and assessment system; 11. Smart bed; 111. Multimodal sensor module; 112. Edge computing module; 113. Main control module; 1131. Multi-Agent scheduling layer; 1132. Persistent memory module; 1133. Skill library; 12. Cloud data processing platform. Detailed Implementation
[0012] 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, not all, of the embodiments of the present invention. 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.
[0013] The intelligent sleep monitoring and evaluation method based on OpenClaw provided in this invention can be applied to smart beds. Currently, the accuracy of existing sleep monitoring methods is relatively low. To address this problem, this invention proposes an intelligent sleep monitoring and evaluation method based on OpenClaw. This method generates multimodal feature data by collecting multi-dimensional physiological parameters, overcoming the shortcomings of insufficient monitoring dimensions by a single sensor; it coordinates each agent to obtain user sleep feature data from a persistent memory module through a multi-agent scheduling layer, achieving personalized adaptation; a cloud data processing platform fuses the multimodal feature data and identifies sleep stages, and generates a sleep monitoring and evaluation report by combining the user's sleep feature data. By utilizing the complementarity of multimodal data and the user's historical data benchmark, the accuracy of sleep monitoring is improved. The invention will be described in detail below through specific embodiments.
[0014] Please see Figure 1 As shown, Figure 1 A system block diagram of an intelligent sleep monitoring and assessment system based on OpenClaw provided in an embodiment of the present invention is shown below. Figure 1As shown, an intelligent sleep monitoring and assessment system 10 based on OpenClaw, an intelligent bed 11, and a cloud data processing platform 12 are presented. The intelligent bed 11 includes a multimodal sensor module 111, an edge computing module 112, and a main control module 113. The multimodal sensor module 111 is used to collect multi-dimensional physiological parameters during the user's sleep process. The edge computing module 112 is used to preprocess and extract features from the multi-dimensional physiological parameters to generate multimodal feature data. The main control module 113 includes a multi-Agent scheduling layer 1131 built based on OpenClaw, a persistent memory module 1132, and a skill library 1133. The multi-Agent scheduling layer 1131 includes a sleep monitoring agent, a posture adjustment agent, and an intelligent wake-up agent. The system includes a scene-linking agent, which coordinates the acquisition of user sleep feature data from the persistent memory module 1132 by each agent. The sleep monitoring agent shares the multimodal feature data with the posture adjustment agent, the intelligent wake-up agent, and the scene-linking agent. The skill library 1133 is used to issue control commands generated by each agent. The cloud data processing platform 12 is communicatively connected to the edge computing module 112 and the multi-agent scheduling layer 1131. It receives the multimodal feature data and the user sleep feature data, performs multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, and generates a sleep monitoring and evaluation report based on the sleep stage sequence and the user sleep feature data. It should be noted that the specific implementation processes of the multimodal sensor module 111, edge computing module 112, and main control module 113 in the multi-smart bed 11, as well as the cloud data processing platform 12, will be described in detail later in the section on the intelligent sleep monitoring and evaluation method based on OpenClaw. For simplicity, these details will not be elaborated here.
[0015] Please see Figure 2 As shown, Figure 2 A flowchart of an intelligent sleep monitoring and evaluation method based on OpenClaw provided in an embodiment of the present invention includes the following steps: S110-S140.
[0016] S110. Collect multi-dimensional physiological parameters during the user's sleep process, preprocess and extract features from the multi-dimensional physiological parameters, and generate multimodal feature data.
[0017] Specifically, the multi-dimensional physiological parameters include pressure distribution data, sound data, body movement data, and heart rate data; the multi-modal feature data includes pressure features, sound features, body movement features, and heart rate features. It should be noted that multi-dimensional physiological parameters during the user's sleep process are collected through a multi-modal sensor assembly configured in the smart bed. This multi-modal sensor assembly includes a pressure sensor array, an acoustic sensor, a body movement sensor, and a non-contact heart rate sensor. It should also be noted that the pressure sensor array is located at the interface between the bed support layer and the human body in the smart bed. It consists of multiple independent pressure sensing units arranged in a matrix to collect pressure distribution data generated when a person lies on the bed. The acoustic sensor is located at the head of the smart bed and uses a MEMS microphone array with a sampling rate of 16kHz. It is used to collect ambient sound data and physiological sound signals such as the user's breathing sounds and snoring. The acoustic sensor is equipped with a sound activity detection module, which starts high-quality recording when the detected sound signal intensity exceeds a preset threshold. The body motion sensor is an infrared sensor or a millimeter-wave radar sensor, located on the side or head of the smart bed, for non-contact collection of the user's body motion data and respiratory rate data. The non-contact heart rate sensor is located inside the mattress or in the bed frame structure of the smart bed. It uses capacitive or optical heart rate sensing technology to collect the user's heart rate data and heart rate variability data with a sampling rate of 4 times per second. The non-contact heart rate sensor is automatically activated when it detects that the user is lying on the bed.
[0018] Among them, such as Figure 3 As shown, step S110 includes steps S111-S114: S111. Perform noise reduction filtering, baseline drift correction and outlier removal on the pressure distribution data, calculate the centroid position and variance of the processed pressure distribution data, and obtain the pressure characteristics. S112. Perform pre-emphasis, framing, and windowing processing on the sound data, and extract audio feature vectors from the processed sound data to obtain the sound features; S113. Perform motion detection on the body movement data to identify body movement events and record timestamps, calculate respiratory rate and respiratory rhythm characteristics, and obtain the body movement characteristics; S114. Perform outlier removal and missing value imputation on the heart rate data, and calculate the time-domain and frequency-domain features of heart rate variability based on the processed heart rate data to obtain the heart rate features.
[0019] Specifically, the edge computing module performs noise filtering on the pressure distribution data to remove sensor noise interference, performs baseline drift correction to eliminate the effects of long-term drift, removes outliers to eliminate abrupt data interference, calculates the centroid position of the processed pressure distribution data to reflect the user's body position distribution, and calculates the pressure distribution variance to characterize the degree of pressure dispersion. The audio data undergoes pre-emphasis processing to enhance high-frequency components, and frame and windowing processing to extract short-term features. Audio feature vectors are extracted from the processed audio data using the Mel-frequency cepstral coefficient method. Valid sound segments are identified through a speech activity detection model, and snoring detection is performed. The model identifies snoring events and records timestamps and intensity levels to obtain sound features; it performs motion detection on body movement data to identify user movement status, identifying body movement events including turning over, getting up, and getting out of bed, and recording the timestamps of each event; it calculates respiratory rate to reflect the user's breathing speed and calculates respiratory rhythm features to characterize respiratory stability, thus obtaining body movement features; it removes outliers from heart rate data to eliminate measurement errors and imputes missing values to ensure data continuity; it calculates heart rate variability time-domain features, including SDNN and RMSSD indices, based on the processed heart rate data, and calculates heart rate variability frequency-domain features, including low-frequency and high-frequency components, thus obtaining heart rate features.
[0020] S120. The sleep monitoring agent in the multi-agent scheduling layer shares the multimodal feature data with the posture adjustment agent, the intelligent wake-up agent, and the scene linkage agent.
[0021] Specifically, the multi-agent scheduling layer is built on the OpenClaw framework and includes a sleep monitoring agent, a posture adjustment agent, a smart wake-up agent, and a scene linkage agent, used to share multimodal feature data through an event bus. It should be noted that the sleep monitoring agent acts as the data hub, responsible for coordinating data sharing among the agents. The posture adjustment agent generates bed angle adjustment commands based on sleep stage and user posture, and obtains user preference data through a persistent memory module to achieve personalized adjustments. The smart wake-up agent identifies the light sleep stage within a preset wake-up time window and triggers a gradual wake-up, avoiding discomfort caused by forced awakening during deep sleep. The scene linkage agent communicates with smart home devices and controls lights, curtains, and air conditioning based on sleep status to create a suitable sleep environment. The four agents work collaboratively with the persistent memory module to achieve sleep monitoring, adjustment, wake-up, and scene linkage functions.
[0022] In one embodiment, such as this embodiment, the collaborative interaction mechanism between the sleep monitoring agent and other agents includes: when the sleep monitoring agent detects that an unhealthy posture persists for more than a preset time or that the snoring intensity exceeds a warning value, it triggers the posture adjustment agent. After receiving the trigger signal, the posture adjustment agent calculates the optimal adjustment strategy by combining the user's historical posture preferences and adjustment effect feedback data obtained from the persistent memory module, and adjusts the smart bed according to the optimal adjustment strategy; the sleep monitoring agent continuously pushes a sleep stage sequence to the smart wake-up agent, and the smart wake-up agent calculates the optimal wake-up window based on the sleep stage sequence and the historical sleep cycle pattern obtained from the persistent memory module, and triggers a wake-up signal; after detecting a sleep stage switching event, the sleep monitoring agent pushes the event tag to the scene linkage agent, and the scene linkage agent matches the scene linkage rules obtained from the persistent memory module according to the event type, and executes the linkage control of smart home devices.
[0023] It should be noted that the sleep monitoring agent, acting as the data hub of the entire system, continuously receives multi-dimensional physiological parameters from pressure array sensors, acoustic sensors, body motion sensors, and non-contact heart rate sensors. Based on these multi-dimensional physiological parameters, when the duration of an undesirable sleep posture exceeds a preset threshold or the snoring intensity exceeds a warning decibel level, the sleep monitoring agent immediately generates a trigger signal and sends it to the posture adjustment agent. Upon receiving the trigger signal, the posture adjustment agent first reads the user's historical posture preference data from the personality style memory layer in the persistent memory module, including the user's habitual sleep angle and past adjustment acceptance information; simultaneously, it obtains historical adjustment effect feedback data from the long-term experience memory layer, analyzing the effectiveness of various adjustment strategies in similar past scenarios. Based on the above data, the posture adjustment agent generates the optimal adjustment strategy through weighted calculations, including the headboard lifting angle, bed tilt direction, and adjustment speed parameters, and then sends control commands to the smart bed's actuator to complete the physical adjustment. The sleep monitoring agent continuously pushes sleep stage sequences to the smart wake-up agent. The smart wake-up agent, combining user historical sleep cycle patterns obtained from its long-term experience memory layer, calculates the optimal wake-up window for the following morning. Within 30 minutes before or after the preset wake-up time, it triggers a gradual wake-up signal during a period of light sleep, achieving a comfortable wake-up through gradual light brightening and slight bed vibration. When the sleep monitoring agent detects a sleep stage transition event, it pushes the event tag to the scene linkage agent. The scene linkage agent matches scene linkage rules obtained from the core consensus memory layer and personality style memory layer based on the event type. For example, it automatically turns off the lights and adjusts the air conditioner temperature after detecting that the user has entered deep sleep, and automatically opens the curtains and plays morning music after detecting that the user has woken up, achieving seamless linkage control with smart home devices.
[0024] S130. The sleep monitoring agent, posture adjustment agent, smart wake-up agent, and scene linkage agent are coordinated by the multi-agent scheduling layer to obtain user sleep feature data from the persistent memory module.
[0025] Specifically, the persistent memory module includes a core consensus memory layer, a personality style memory layer, and a long-term experience memory layer; the user sleep characteristic data includes physiological baseline values, sleep onset pattern characteristics, user group sleep posture preferences, user historical posture preferences, adjustment effect feedback data, optimal wake-up window prediction values, historical sleep cycle patterns, user sleep environment preferences, and scene linkage rules.
[0026] Among them, such as Figure 4 As shown, step S130 includes steps S131-S134: S131. The sleep monitoring agent is coordinated by the multi-agent scheduling layer to obtain the physiological baseline value from the core consensus memory layer and the sleep pattern characteristics from the long-term experience memory layer. S132. The posture adjustment agent is coordinated by the multi-Agent scheduling layer to obtain the user group's sleeping posture preference from the personality style memory layer, and to obtain the user's historical posture preference and the adjustment effect feedback data from the long-term experience memory layer. S133. The intelligent wake-up agent obtains the optimal wake-up window prediction value and the historical sleep cycle pattern from the long-term experience memory layer through the multi-agent scheduling layer. S134. The multi-Agent scheduling layer coordinates the scene linkage agent to obtain the user's sleep environment preference from the personality style memory layer and the scene linkage rule from the long-term experience memory layer.
[0027] Specifically, physiological benchmarks include sleep cycle structure standards, sleep characteristic standard values for each age group, and physiological indicator ranges for each sleep stage, serving as general benchmarks for abnormality detection and judgment. Sleep onset pattern characteristics include average sleep onset time, historical statistics of sleep latency, and sleep maintenance rate benchmarks, used to optimize the monitoring strategy and sampling frequency for the current session, making the monitoring plan more aligned with individual sleep habits. User group sleeping posture preferences include the proportion of side-lying preference, supine preference, and prone avoidance tendencies matching the current user's tag, serving as a starting point for decision-making when dealing with new users or those with insufficient data accumulation, avoiding cold start problems. User historical posture preferences include the user's main sleeping posture types in past sleep, the duration threshold of undesirable postures, and preference adjustment methods. Adjustment effect feedback data includes the execution results of historical adjustment actions, user satisfaction scores, and snoring relief effect assessments, serving as the basis for calculating the optimal adjustment strategy and achieving personalized posture intervention. The optimal wake-up window prediction is trained based on the user's historical wake-up data, reflecting the temporal pattern of the user's light sleep initiation point, ensuring that the wake-up timing is selected during the light sleep stage of the sleep cycle. The historical sleep cycle pattern includes the number of nighttime sleep cycle cycles, the duration distribution of each cycle, and the occurrence period of REM sleep, used to calculate the optimal wake-up time for the current session. It selects the light sleep stage near the preset wake-up time to trigger a multi-dimensional wake-up signal chain, achieving a seamless wake-up experience and reducing drowsiness after waking up. User sleep environment preferences include the group's preferred room temperature range, light brightness type, and background sound preferences matched with user tags, serving as initialization parameters for scene linkage rules and providing reasonable default configurations for new users. Scene linkage rules include user-defined sleep-on-fall, deep sleep, wake-up, and bed-leaving linkage actions, as well as the corresponding smart home device control instruction sets for each linkage action. These are used to match and execute corresponding light control, air conditioning control, curtain control, and fresh air system control after detecting a sleep stage switching event, achieving intelligent linkage between the sleep environment and sleep state.
[0028] In one embodiment, such as this embodiment, the persistent memory module further includes a temporary context memory layer. This temporary context memory layer stores temporary context data for the current session. The sleep monitoring agent obtains the temporary context data for the current session from the temporary context memory layer and adjusts the sleep monitoring strategy based on this data. It should be noted that the four-layer memory architecture in the persistent memory module works collaboratively with the agent scheduling layer. The core consensus memory layer provides cross-user shared physiological knowledge, the personality style memory layer provides group preference patterns, the long-term experience memory layer stores individual long-term sleep characteristics, and the temporary context memory layer stores temporary data for the current session. The multi-agent scheduling layer retrieves relevant data from the corresponding memory layer according to the functional requirements of each agent, achieving hierarchical decision support from general to personalized, and from long-term to temporary, thereby improving the accuracy and personalization of sleep monitoring assessment.
[0029] It should also be noted that the core consensus layer stores system-level basic configurations and global rules, including device parameters, security thresholds, and physiological baseline values, all of which can be read by the agents to ensure system consistency. The personality style layer records users' personalized preferences and behavioral habits, including user group sleeping posture preferences, wake-up sensitivity, and temperature preferences, providing personalized decision-making basis for posture adjustment agents and intelligent wake-up agents. The long-term experience memory layer accumulates historical sleep data and optimization experience, including sleep onset pattern characteristics, user historical posture preferences, adjustment effect feedback data, optimal wake-up window prediction values, historical sleep cycle patterns, and scene linkage rules, supporting model training and strategy optimization on cloud data processing platforms. The temporary context memory layer stores temporary context data for the current session, including real-time sleep data, temporary adjustment commands, and inter-agent interaction context, supporting real-time decision response.
[0030] It should also be noted that the four-layer persistent memory module adopts a bidirectional data flow mechanism to achieve dynamic updates and knowledge accumulation. Specifically, the accumulation is from bottom to top: the temporary context memory layer collects sleep data in real time, and after analysis by the sleep monitoring agent, effective features (such as sleep cycle distribution and abnormal events) are periodically incorporated into the long-term experience memory layer; the pattern data accumulated in the long-term experience memory layer is updated to the personality style memory layer by extracting user preference patterns through the cloud data processing platform. The guidance is from top to bottom: the core consensus memory layer distributes system rules and threshold configurations to each agent; the personality style memory layer provides personalized parameters for the posture adjustment agent and the intelligent wake-up agent; and the long-term experience memory layer provides historical training data for the temporal neural network model in the cloud data processing platform. The update trigger mechanism is as follows: the temporary context memory layer is automatically cleared and updated according to the session cycle; the long-term experience memory layer is batch-accumulated on a weekly / monthly basis; the personality style memory layer is triggered to update when user feedback or behavioral patterns change significantly; and the core consensus memory layer is only updated during system upgrades or configuration changes. Each layer is set with a version identifier to ensure the consistency of data read by the agents and supports rollback and traceability.
[0031] S140. Upload the user's sleep characteristic data and the multimodal characteristic data to the cloud data processing platform, so that the cloud data processing platform can perform multimodal feature fusion and sleep stage identification based on the multimodal characteristic data to obtain a sleep stage sequence, and generate a sleep monitoring and evaluation report based on the sleep stage sequence and the user's sleep characteristic data.
[0032] Specifically, the cloud data processing platform is configured with a time-series neural network model, which adopts a Transformer architecture with a multi-head self-attention mechanism.
[0033] Among them, such as Figure 5 As shown, step S140 includes steps S141-S148: S141. The cloud data processing platform aligns the multimodal feature data according to timestamps to establish a multimodal time series including the pressure feature, the sound feature, the body movement feature, and the heart rate feature; S142. Perform feature fusion on the multimodal time series to obtain fused multimodal features; S143. Input the fused multimodal features into the sleep stage classifier and output the initial sleep stage sequence; S144. The initial sleep stage sequence is smoothed using a hidden Markov model to obtain the sleep stage sequence, wherein the sleep stage sequence includes time-series label sequences of wakefulness, REM sleep, light sleep, and deep sleep. S145. Calculate sleep efficiency, the proportion of each stage, and sleep continuity index based on the sleep stage sequence, wherein the proportion of each stage includes the ratio of the duration of the wakefulness period, the REM sleep period, the light sleep period, and the deep sleep period to the total sleep time. S146. Generate personalized evaluation results based on the physiological baseline values, sleep efficiency, percentage of each stage, and sleep continuity index in the user's sleep characteristic data. S147. Compare the personalized assessment results with the historical assessment results in the user's sleep characteristic data to generate a sleep quality trend analysis; S148. Generate the sleep monitoring and assessment report based on the personalized assessment results and the sleep quality trend analysis.
[0034] Specifically, after receiving multimodal feature data uploaded by the edge computing unit, the cloud-based data processing platform first performs timestamp alignment. Since pressure, sound, body movement, and heart rate features originate from different sensors and have varying sampling frequencies, a combination of linear interpolation and nearest neighbor matching is used to unify all feature data to the same temporal granularity, establishing a complete multimodal time series to ensure temporal consistency in subsequent fusion analysis. After time alignment, an attention-based fusion algorithm dynamically calculates the weight contribution of each modality feature in different sleep stages, and obtains the fused multimodal features through weighted concatenation, effectively preserving the discriminative information of each sensor's data. The fused multimodal features are then input into a sleep stage classifier. This classifier, built on a Transformer architecture, includes multi-layer self-attention mechanisms and a feedforward neural network, capable of capturing long-term temporal dependencies and outputting an initial sleep stage sequence. Because sensor noise or transient interference may cause unreasonable jumps in classification results, the platform uses a Hidden Markov Model to smooth the initial sleep stage sequence, utilizing sleep stage transition probability constraints (such as the extremely low probability of a direct jump from wakefulness to deep sleep) to obtain a sleep stage sequence that conforms to physiological patterns. It should be noted that multiple sleep quality indicators are calculated based on the cloud-based data processing platform for sleep stage sequences. Sleep efficiency is the ratio of actual sleep onset time to total time spent in bed; sleep continuity indicators include parameters such as the number of awakenings during the night and the longest continuous sleep duration. Physiological baseline values are derived from the user's historical sleep data statistics or from people of the same age group. By comparing the deviation between the actual indicators and the physiological baseline values, a personalized assessment result containing scores for each dimension is generated. The personalized assessment results are compared with historical assessment results, and a sliding time window is used to analyze sleep quality change trends, identify improvement or deterioration patterns, and generate a sleep quality trend analysis. Finally, by combining the personalized assessment results and the sleep quality trend analysis, a sleep monitoring assessment report containing scores, charts, and improvement suggestions is generated. It should also be noted that the cloud-based data processing platform also pushes the sleep monitoring assessment report to the user terminal and the multi-agent scheduling layer of the smart bed.
[0035] Figure 6 A flowchart illustrating another embodiment of the intelligent sleep monitoring and assessment method based on OpenClaw provided by the present invention is shown below. Figure 6 As shown, in this embodiment, the method includes steps S210-S260. Steps S210-S240 are the same as steps S110-S140. In this embodiment, after step S240, steps S250-S260 are also included.
[0036] S250. Based on the sleep monitoring and evaluation report, control instructions are generated through the multi-Agent scheduling layer, wherein the control instructions include posture adjustment instructions, intelligent wake-up instructions, and scene linkage instructions; S260. Issue the control command through the skill library to perform posture adjustment and / or sleep environment linkage control, and feed back the execution result to the corresponding Agent.
[0037] Specifically, the multi-agent scheduling layer generates control commands based on sleep monitoring and assessment reports. If the report indicates excessive spinal pressure, the sleep monitoring agent triggers the posture adjustment agent to generate commands to adjust the bed angle. If the report mentions morning wake-up, the smart wake-up agent generates commands and sets a gradual strategy. Scene-linking agents generate scene-linking commands based on the sleep state in the report, controlling lights and air conditioning. Control commands are sent to the smart bed through a skill library that supports hot-loading to ensure accurate command response. After execution, the smart bed feeds back the results to the corresponding agent. The agent then updates the long-term experience memory layer in its persistent memory module based on the results, forming a closed-loop optimization to improve sleep quality.
[0038] Figure 7 A flowchart illustrating the intelligent sleep monitoring and evaluation method based on OpenClaw provided in another embodiment of the present invention is shown below. Figure 7 As shown, in this embodiment, the method includes steps S310-S390. Steps S310-S360 are the same as steps S210-S260. In this embodiment, after step S360, steps S370-S390 are also included.
[0039] S370: Record the complete link data of each sleep monitoring, posture adjustment and wake-up control task to the task execution trajectory library; S380. Periodically scan the task execution trajectory library through the skill library, identify high-frequency task patterns, extract decision logic to generate reusable sleep management skills, and register the sleep management skills to the skill library; S390. When a skill in the skill library is invoked and executed, the skill execution effect is fed back to the learning module built on OpenClaw.
[0040] Specifically, the entire process of sleep monitoring, posture adjustment, and wake-up control tasks is recorded. This complete data chain includes input data, decision-making process, execution actions, and result feedback. Input data encompasses sensor readings and user settings; the decision-making process includes the inference paths of each agent and read records from the persistent memory module; execution actions correspond to specific control commands; and result feedback includes the user's physiological response and subjective evaluation. All data is timestamped and stored in the task execution trajectory database, forming a traceable historical dataset. It's worth noting that the skill library periodically scans the task execution trajectory database, using clustering algorithms to identify high-frequency task patterns. When a certain type of decision is found to be repeatedly successful and consistently effective in a specific scenario, the core decision logic is extracted, encapsulated to generate a reusable sleep management skill, and registered in the skill library for global access. This process transforms experience into skills, reduces real-time computational overhead, and improves response speed.
[0041] Once a skill from the skill library is invoked and executed, the system collects real-time data on its performance, including the degree of sleep improvement and user satisfaction. This feedback data is then sent to a learning module built on OpenClaw. The learning module analyzes the feedback data, optimizes skill parameters or decision weights, and enables the system to self-evolve. Through this closed-loop feedback mechanism, the system continuously accumulates optimization experience, improves personalized service levels, ensures long-term effectiveness and adaptability, and forms an intelligent sleep management ecosystem that becomes increasingly user-friendly with use.
[0042] The intelligent sleep monitoring and assessment method based on OpenClaw in this invention has the following beneficial effects: It collects pressure distribution data, sound data, body movement data, and heart rate data through a multimodal sensor module. After preprocessing and feature extraction, pressure features, sound features, body movement features, and heart rate features are generated. Multimodal feature fusion and sleep stage identification are performed through a cloud-based data processing platform. A sleep stage classifier combined with a Hidden Markov Model is used to obtain a sleep stage sequence, including time-series label sequences for wakefulness, REM sleep, light sleep, and deep sleep, thus improving the accuracy of sleep monitoring. A multi-Agent scheduling layer built based on OpenClaw coordinates the sleep monitoring agent, posture adjustment agent, intelligent wake-up agent, and scene linkage agent to obtain user sleep feature data from a persistent memory module, achieving personalized decision-making and collaborative interaction while avoiding command conflicts. The persistent memory module includes a core consensus memory layer, a personality style memory layer, a long-term experience memory layer, and a temporary context memory layer, providing hierarchical decision-making data support for each agent. The skill library supports the generation of reusable sleep management skills, records complete link data through a task execution trajectory library, and feeds the skill execution effect back to the learning module built on OpenClaw for continuous optimization. It generates sleep monitoring and evaluation reports that include personalized assessment results and sleep quality trend analysis, effectively improving users' sleep quality and health management level, and forming an intelligent sleep management ecosystem that becomes more and more user-friendly the more it is used.
[0043] The aforementioned intelligent sleep monitoring and assessment method based on OpenClaw can be implemented as a computer program, which can be used in various ways, such as... Figure 8 The smart bed shown is in operation.
[0044] Please see Figure 8 , Figure 8 This is a schematic block diagram of a smart bed provided in an embodiment of the present invention. The smart bed 300 is a device capable of sleep monitoring.
[0045] See Figure 8 The smart bed 300 includes a processor 302, a memory, and a network interface 305 connected via a system bus 301. The memory may include a non-volatile storage medium 303 and internal memory 304.
[0046] The non-volatile storage medium 303 can store an operating system 3031 and a computer program 3032. When the computer program 3032 is executed, it causes the processor 302 to execute an intelligent sleep monitoring and evaluation method based on OpenClaw.
[0047] The processor 302 provides computing and control capabilities to support the operation of the entire smart bed 300.
[0048] The internal memory 304 provides an environment for the operation of the computer program 3032 in the non-volatile storage medium 303. When the computer program 3032 is executed by the processor 302, the processor 302 can execute an intelligent sleep monitoring and evaluation method based on OpenClaw.
[0049] This network interface 305 is used for network communication with other devices. Those skilled in the art will understand that... Figure 8 The structure shown is merely a block diagram of a portion of the structure related to the present invention and does not constitute a limitation on the smart bed 300 to which the present invention is applied. The specific smart bed 300 may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0050] The processor 302 is used to run a computer program 3032 stored in a memory to implement any embodiment of the above-described intelligent sleep monitoring and evaluation method based on OpenClaw.
[0051] It should be understood that, in this embodiment of the invention, the processor 302 may be a Central Processing Unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.
[0052] It will be understood by those skilled in the art that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a storage medium, which is a computer-readable storage medium. The computer program is executed by a processor in the computer system to implement the process steps of the embodiments of the above methods.
[0053] Therefore, the present invention also provides a storage medium. This storage medium can be a computer-readable storage medium. The storage medium stores a computer program. When executed by a processor, the computer program causes the processor to perform any embodiment of the above-described OpenClaw-based intelligent sleep monitoring and evaluation method.
[0054] The storage medium can be any computer-readable storage medium capable of storing program code, such as a USB flash drive, portable hard drive, read-only memory (ROM), magnetic disk, or optical disk.
[0055] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0056] In the several embodiments provided by this invention, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For example, the division of each unit is merely a logical functional division, and there may be other division methods in actual implementation. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed.
[0057] The steps in the method of this invention can be adjusted, merged, or reduced in order according to actual needs. The units in the device of this invention can be merged, divided, or reduced according to actual needs. Furthermore, the functional units in the various embodiments of this invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0058] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a smart bed to execute all or part of the steps of the methods described in the various embodiments of the present invention.
[0059] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail in a certain embodiment, please refer to the relevant descriptions in other embodiments.
[0060] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Since these modifications and variations fall within the scope of the claims and their equivalents, this invention also intends to include these modifications and variations.
[0061] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and these modifications or substitutions should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A smart sleep monitoring and evaluation method based on OpenClaw, applied to a smart bed, the smart bed including a main control module, the main control module including a multi-agent scheduling layer and a persistent memory module built based on OpenClaw, characterized in that, The method includes: Collect multi-dimensional physiological parameters during the user's sleep process, preprocess and extract features from the multi-dimensional physiological parameters to generate multimodal feature data; The sleep monitoring agent in the multi-agent scheduling layer shares the multimodal feature data with the posture adjustment agent, the smart wake-up agent, and the scene linkage agent. The multi-agent scheduling layer coordinates the sleep monitoring agent, posture adjustment agent, smart wake-up agent, and scene linkage agent to obtain user sleep feature data from the persistent memory module. The user's sleep feature data and the multimodal feature data are uploaded to a cloud data processing platform, so that the cloud data processing platform can perform multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, and generate a sleep monitoring and evaluation report based on the sleep stage sequence and the user's sleep feature data.
2. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 1, characterized in that, The multidimensional physiological parameters include pressure distribution data, sound data, body movement data, and heart rate data; the multimodal feature data includes pressure features, sound features, body movement features, and heart rate features. The steps of preprocessing and extracting features from the multidimensional physiological parameters to generate multimodal feature data include: The pressure distribution data is subjected to noise reduction filtering, baseline drift correction and outlier removal. The centroid position and variance of the processed pressure distribution data are calculated to obtain the pressure characteristics. The audio data is pre-emphasized, framed, and windowed. Audio feature vectors are extracted from the processed audio data to obtain the audio features. Motion detection is performed on the body movement data to identify body movement events and record timestamps, and respiratory rate and respiratory rhythm characteristics are calculated to obtain the body movement characteristics; The heart rate data is subjected to outlier removal and missing value imputation. Based on the processed heart rate data, the time-domain features and frequency-domain features of heart rate variability are calculated to obtain the heart rate features.
3. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 2, characterized in that, The cloud-based data processing platform performs multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, including: The cloud-based data processing platform aligns the multimodal feature data according to timestamps to establish a multimodal time series that includes the pressure feature, the sound feature, the body movement feature, and the heart rate feature; The multimodal time series is fused to obtain fused multimodal features; The fused multimodal features are input into the sleep stage classifier, which outputs the initial sleep stage sequence. The initial sleep stage sequence is smoothed using a Hidden Markov Model to obtain the sleep stage sequence, which includes time-series label sequences of wakefulness, REM sleep, light sleep, and deep sleep.
4. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 3, characterized in that, The step of generating a sleep monitoring and evaluation report based on the sleep stage sequence and the user's sleep characteristic data includes: Sleep efficiency, the proportion of each stage, and sleep continuity indicators are calculated based on the sleep stage sequence. The proportion of each stage includes the ratio of the duration of the wakefulness period, the REM sleep period, the light sleep period, and the deep sleep period to the total sleep time. Personalized assessment results are generated based on the physiological baseline values, sleep efficiency, percentage of each stage, and sleep continuity indicators in the user's sleep characteristic data. The personalized assessment results are compared with the historical assessment results in the user's sleep characteristic data to generate a sleep quality trend analysis; The sleep monitoring and assessment report is generated based on the personalized assessment results and the sleep quality trend analysis.
5. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 1, characterized in that, The persistent memory module includes a core consensus memory layer, a personality style memory layer, and a long-term experience memory layer; the user sleep characteristic data includes physiological baseline values, sleep onset pattern characteristics, user group sleep posture preferences, user historical posture preferences, adjustment effect feedback data, optimal wake-up window prediction values, historical sleep cycle patterns, user sleep environment preferences, and scene linkage rules; the step of coordinating the sleep monitoring agent, the posture adjustment agent, the intelligent wake-up agent, and the scene linkage agent to obtain user sleep characteristic data from the persistent memory module through the multi-agent scheduling layer includes: The sleep monitoring agent is coordinated by the multi-agent scheduling layer to obtain the physiological baseline value from the core consensus memory layer and the sleep pattern characteristics from the long-term experience memory layer. The multi-agent scheduling layer coordinates the posture adjustment agent to obtain the user group's sleeping posture preferences from the personality style memory layer, and to obtain the user's historical posture preferences and the adjustment effect feedback data from the long-term experience memory layer; The multi-agent scheduling layer coordinates the intelligent wake-up agent to obtain the optimal wake-up window prediction value and the historical sleep cycle pattern from the long-term experience memory layer. The multi-agent scheduling layer coordinates the scene-linking agents to obtain the user's sleep environment preferences from the personality style memory layer and the scene-linking rules from the long-term experience memory layer.
6. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 5, characterized in that, The persistent memory module also includes a temporary context memory layer, which is used to store the temporary context data of the current session. The sleep monitoring agent obtains the temporary context data of the current session from the temporary context memory layer and adjusts the sleep monitoring strategy according to the temporary context data of the current session.
7. The intelligent sleep monitoring and assessment method based on OpenClaw as described in claim 1, characterized in that, The collaborative interaction mechanism between the sleep monitoring agent and other agents includes: When the sleep monitoring agent detects that an unhealthy posture persists for more than a preset time or that the snoring intensity exceeds a warning value, it triggers the posture adjustment agent. After receiving the trigger signal, the posture adjustment agent combines the user's historical posture preferences and adjustment effect feedback data obtained from the persistent memory module to calculate the optimal adjustment strategy and adjust the smart bed according to the optimal adjustment strategy. The sleep monitoring agent continuously pushes the sleep stage sequence to the smart wake-up agent. The smart wake-up agent calculates the optimal wake-up window based on the sleep stage sequence and the historical sleep cycle pattern obtained from the persistent memory module, and triggers a wake-up signal. After the sleep monitoring agent detects a sleep stage switching event, it pushes the event tag to the scene linkage agent. The scene linkage agent matches the scene linkage rules obtained from the persistent memory module according to the event type and executes the linkage control of smart home devices.
8. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 1, characterized in that, The main control module also includes a skill library built on OpenClaw; after the step of generating a sleep monitoring and evaluation report based on the sleep stage sequence and the user's sleep characteristic data, it further includes: Based on the sleep monitoring and evaluation report, control instructions are generated through the multi-agent scheduling layer, wherein the control instructions include posture adjustment instructions, intelligent wake-up instructions, and scene linkage instructions; The control commands are issued through the skill library to perform posture adjustment and / or sleep environment linkage control, and the execution results are fed back to the corresponding Agent.
9. The intelligent sleep monitoring and evaluation method based on OpenClaw as described in claim 8, characterized in that, After the step of feeding back the execution result to the corresponding Agent, the method further includes: Record the complete link data of each sleep monitoring, posture adjustment, and wake-up control task to the task execution trajectory library; The skill library is used to periodically scan the task execution trajectory library to identify high-frequency task patterns, extract decision logic to generate reusable sleep management skills, and register the sleep management skills to the skill library. Once a skill in the skill library is invoked and executed, the skill execution effect is fed back to the learning module built on OpenClaw.
10. An intelligent sleep monitoring and assessment system based on OpenClaw, characterized in that, Includes a smart bed and a cloud data processing platform, wherein the smart bed includes: A multimodal sensor module is used to collect multi-dimensional physiological parameters during the user's sleep process; An edge computing module is used to preprocess and extract features from the multi-dimensional physiological parameters to generate multimodal feature data; The main control module includes a multi-agent scheduling layer built on OpenClaw, a persistent memory module, and a skill library. The multi-agent scheduling layer includes a sleep monitoring agent, a posture adjustment agent, a smart wake-up agent, and a scene linkage agent, used to coordinate the acquisition of user sleep feature data from the persistent memory module by each agent. The sleep monitoring agent shares the multimodal feature data with the posture adjustment agent, the smart wake-up agent, and the scene linkage agent. The skill library is used to issue control commands generated by each agent. The cloud-based data processing platform is communicatively connected to the edge computing module and the multi-agent scheduling layer. It is used to receive the multimodal feature data and the user sleep feature data, perform multimodal feature fusion and sleep stage identification based on the multimodal feature data to obtain a sleep stage sequence, and generate a sleep monitoring and evaluation report based on the sleep stage sequence and the user sleep feature data.