Medication behavior detection method and device based on multi-device cooperation, equipment and medium

CN122531616APending Publication Date: 2026-08-07CHINA PING AN LIFE INSURANCE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA PING AN LIFE INSURANCE CO LTD
Filing Date
2026-06-04
Publication Date
2026-08-07

AI Technical Summary

Technical Problem

然而,该方式仅能反映药盒被打开的单一事件,既无法区分是正常取药还是误触开盒,也无法判断药物在被取出后是否被实际吞服

Benefits of technology

[0010]上述基于多设备协同的用药行为检测方法、装置、设备及介质,所实现的方案中,可以通过客户端获取用于协同检测用户用药行为的智能终端、智能药盒和可穿戴设备,并建立智能终端、智能药盒和可穿戴设备的通信连接;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122531616A_ABST
    Figure CN122531616A_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of behavior detection, and is suitable for the medical field, and discloses a medication behavior detection method and device based on multi-device cooperation, equipment and medium, comprising: acquiring an intelligent terminal, an intelligent medicine box and a wearable device for cooperatively detecting user medication behavior, and establishing a communication connection of the intelligent terminal, the intelligent medicine box and the wearable device; at a preset user medication time point, issuing a medication reminder through the intelligent terminal, and recording the user's response behavior to the medication reminder as a behavior starting signal; within a preset time window after the medication reminder is issued, collecting opening and closing state data of the intelligent medicine box, and collecting user hand movement data through the wearable device; the behavior starting signal, the opening and closing state data and the hand movement data are fused and judged to determine whether the user has completed the medication. The application improves the accuracy of user medication behavior detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of behavior detection technology and is applicable to the medical field. In particular, it relates to a method, device, equipment and medium for detecting medication behavior based on multi-device collaboration. Background Technology

[0002] With the increasing number of patients with chronic diseases, long-term regular medication has become an important part of healthcare management. Medication adherence, that is, whether patients take medication according to the prescribed time, dosage, and method, directly affects the treatment effect of chronic diseases and the patient's health status. However, in home medication settings, due to the lack of effective real-time monitoring methods, problems such as missed doses, incorrect doses, and delayed doses are common.

[0003] Currently, mainstream medication management primarily relies on the timed reminder function of smartphone applications, which notify users to take their medication at preset times. While this approach can record user responses to reminders, it only reflects software-level interactions and cannot determine whether the user actually performed the physical actions of retrieving and swallowing the medication after clicking the reminder, posing a risk of false positives (not taking the medication despite being reminded). Although some solutions have introduced smart pillboxes that use built-in sensors to record the opening time of the pillbox to determine if the user has touched the medication, this method only reflects the single event of the pillbox being opened. It cannot distinguish between normal medication retrieval and accidental opening, nor can it determine whether the medication was actually swallowed after being retrieved.

[0004] Therefore, improving the accuracy of user medication behavior detection is a technical problem that urgently needs to be solved. Summary of the Invention

[0005] This invention provides a method, apparatus, device, and medium for detecting medication behavior based on multi-device collaboration, in order to solve the technical problem of how to improve the accuracy of user medication behavior detection.

[0006] In a first aspect, the present invention provides a method for detecting medication behavior based on multi-device collaboration, comprising: Acquire smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior, and establish communication connections between the smart terminals, smart pillboxes, and wearable devices; At the preset medication time, the smart terminal sends a medication reminder and records the user's response to the medication reminder as a behavior start signal; Within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device; The system integrates the behavior initiation signal, the opening / closing state data, and the hand movement data to determine whether the user has completed taking the medication.

[0007] Secondly, the present invention provides a medication behavior detection device based on multi-device collaboration, comprising: The acquisition module is used to acquire smart terminals, smart pillboxes, and wearable devices used for collaborative detection of user medication behavior, and to establish communication connections between the smart terminals, smart pillboxes, and wearable devices. The recording module is used to issue a medication reminder through the smart terminal at a preset user medication time point, and record the user's response to the medication reminder as a behavior start signal; The data acquisition module is used to collect the opening and closing status data of the smart pillbox within a preset time window after the medication reminder is issued, and to collect the user's hand movement data through the wearable device. The judgment module is used to fuse and judge the behavior start signal, the opening and closing state data and the hand action data to determine whether the user has completed taking the medication.

[0008] Thirdly, the present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above-described method for detecting medication behavior based on multi-device collaboration.

[0009] Fourthly, the present invention provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the above-described method for detecting medication behavior based on multi-device collaboration.

[0010] The above-mentioned method, device, equipment and medium for detecting medication behavior based on multi-device collaboration can obtain smart terminals, smart pillboxes and wearable devices for collaborative detection of user medication behavior through the client, and establish communication connections between the smart terminals, smart pillboxes and wearable devices. At a preset medication time, a medication reminder is issued via the smart terminal, and the user's response to the reminder is recorded as a behavior initiation signal. Within a preset time window after the reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected via the wearable device. The behavior initiation signal, the opening and closing status data, and the hand movement data are fused and judged to determine whether the user has taken the medication. This invention, through multi-device collaboration, synchronously collects pillbox opening and closing data and hand movement data within a preset time window, and performs fusion and cross-validation of the behavior initiation signal, the opening and closing status data, and the hand movement data to construct a complete behavioral evidence chain. This solves the problem of false judgments such as being reminded but not taking the medication or having opened the pillbox but not swallowing the medication, thus improving the accuracy of medication behavior detection. Attached Figure Description

[0011] 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.

[0012] Figure 1 This is a schematic diagram of an application environment for a medication behavior detection method based on multi-device collaboration in one embodiment of the present invention.

[0013] Figure 2 This is a flowchart illustrating a method for detecting medication behavior based on multi-device collaboration in one embodiment of the present invention.

[0014] Figure 3 yes Figure 2 A schematic diagram of a specific implementation method for step S20.

[0015] Figure 4 yes Figure 2 A schematic diagram of a specific implementation method for step S30.

[0016] Figure 5 yes Figure 2 A flowchart illustrating a specific implementation of step S40.

[0017] Figure 6 yes Figure 5 A flowchart illustrating a specific implementation of step S41.

[0018] Figure 7 This is a schematic diagram of a medication behavior detection device based on multi-device collaboration in one embodiment of the present invention.

[0019] Figure 8This is a schematic diagram of the structure of a computer device according to an embodiment of the present invention.

[0020] Figure 9 This is another structural schematic diagram of a computer device according to one embodiment of the present invention. Detailed Implementation

[0021] 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.

[0022] The medication behavior detection method based on multi-device collaboration provided in this invention can be applied to, for example... Figure 1 In the application environment, Figure 1 This is a schematic diagram of an application environment for a medication behavior detection method based on multi-device collaboration in one embodiment of the present invention; wherein, the client communicates with the server via a network. The server can obtain smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior through the client, and establish communication connections between the smart terminals, smart pillboxes, and wearable devices; at a preset user medication time point, a medication reminder is issued through the smart terminal, and the user's response to the medication reminder is recorded as a behavior start signal; within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device; the behavior start signal, the opening and closing status data, and the hand movement data are fused and judged to determine whether the user has completed taking the medication. This invention utilizes multi-device collaboration to synchronously collect data on the opening and closing of medicine boxes and hand movements within a preset time window. It then fuses and cross-validates the behavior starting point signal, the opening and closing state data, and the hand movement data to construct a complete chain of behavioral evidence. This solves the problem of misjudgment in cases where medication has been reminded but not taken, or where the box has been opened but not swallowed, thus improving the accuracy of medication behavior detection. The invention will be described in detail below through specific embodiments.

[0023] Please see Figure 2 As shown, Figure 2 This is a schematic flowchart of a medication behavior detection method based on multi-device collaboration provided in an embodiment of the present invention. The medication behavior detection method based on multi-device collaboration specifically includes the following steps: S10: Acquire the smart terminal, smart pillbox, and wearable device for collaborative detection of user medication behavior, and establish a communication connection between the smart terminal, smart pillbox, and wearable device. Specifically, in this embodiment of the invention, the independently operating smart terminal, smart pillbox, and wearable device are connected through communication, enabling each device to work in coordination within a unified time frame. This provides a hardware foundation for the subsequent synchronous collection and cross-validation of multi-source data, upgrading medication behavior detection in a home environment from single-point monitoring to multi-dimensional collaborative monitoring. For example, in a healthcare management scenario, a patient is equipped with a smartphone with a health management program installed, a smart pillbox with a built-in opening and closing sensor, and a smartwatch worn on the wrist. The smartphone serves as the system's control center and human-computer interaction interface, the smart pillbox stores the daily antihypertensive medication, and the smartwatch senses the movement of the arm. When the patient uses the system for the first time, it guides the three devices to establish a communication connection, forming a collaborative detection system. Thereafter, in each medication detection task, the three devices can work collaboratively within a unified time frame. Specifically, this includes the following steps S11-S12: S11: Identify smart terminals, smart pillboxes, and wearable devices in the same network environment, and establish distributed communication connections between them. Specifically, in this embodiment of the invention, HarmonyOS distributed device identification technology is used to automatically detect smart terminals, smart pillboxes, and wearable devices in the same network environment and establish distributed communication connections between them. Distributed communication connections differ from traditional point-to-point Bluetooth pairing; they allow devices to establish multiple low-latency, highly reliable data transmission channels, logically forming a collaborative whole capable of exchanging data using a unified time base. Automatic identification and distributed connections avoid the tedious manual pairing of each device by the user. For example, in a healthcare management scenario, when a patient uses the system for the first time, their smartphone, smart pillbox, and smartwatch connect to the same home Wi-Fi network. The smartphone automatically identifies the smart pillbox and smartwatch in the same network environment and establishes a communication connection between the three devices through a distributed communication protocol. For the patient, no complex Bluetooth pairing or network settings are required; the connection between devices is automatically completed in the background.

[0024] S12: Through the distributed communication connection, synchronize the sensor information of the smart pillbox and the wearable device. The sensor information of the smart pillbox includes pillbox opening / closing state detection, and the sensor information of the wearable device includes acceleration data and angular velocity data. Specifically, in this embodiment, the sensor information reported by the smart pillbox includes pillbox opening / closing state detection capability, indicating that the device can sense and report the opening / closing event of the pillbox lid; the sensor information reported by the wearable device includes acceleration data and angular velocity data acquisition capability, indicating that the device can acquire arm movement data through its built-in acceleration and angular velocity sensors. Through pre-synchronization of sensor information, the system can directly call the corresponding sensor resources based on the capabilities of each device when performing subsequent data acquisition tasks, without needing to re-query device capabilities before each acquisition, thus improving the efficiency and reliability of data acquisition. For example, in a healthcare management scenario, when the preset medication time arrives and data acquisition needs to be initiated, the smart pillbox directly sends an opening / closing state data acquisition command, and the smartwatch sends a motion data acquisition command. Each device then initiates the corresponding data acquisition task based on its own sensor capabilities.

[0025] S20: At the preset medication time, a medication reminder is issued through the smart terminal, and the user's response to the reminder is recorded as the starting signal for the behavior. Specifically, in this embodiment of the invention, the medication reminder is used as the trigger source, and the patient's initial response to the reminder is marked, enabling the system to trace the entire process from the patient becoming aware of the medication time to potentially taking the medication. Regardless of the patient's response to the medication reminder, the system can completely capture and record its initial state. For example, in a healthcare management scenario, medication is usually required to be taken by the patient at fixed times each day, such as 8:00 AM and 6:00 PM. The system triggers a medication reminder on the smartphone at the preset medication time. After perceiving the reminder, the patient may make different responses such as clicking to confirm, choosing to delay, or ignoring it. The system records the patient's actual response behavior and the response time as the starting signal for this medication behavior detection. For example, if the patient immediately clicks to confirm taking the medication after receiving the reminder at 8:00 AM, the system uses that click time as the time benchmark for all subsequent behavior analysis. Figure 3 The above, Figure 3 yes Figure 2 A flowchart illustrating a specific implementation of step S20. Specifically, it includes the following steps S21-S24: S21: At a preset medication time, a medication reminder signal is generated through the smart terminal. The medication reminder signal includes at least one of sound, vibration, and visual notification signals. Specifically, in this embodiment of the invention, the multimodal notification capability of the smart terminal is utilized to generate a medication reminder signal through at least one of sound, vibration, and visual notifications. This allows the reminder signal to cover the user's perception needs in different scenarios, increasing the probability of the user perceiving the medication reminder. The multimodal reminder mechanism reduces the risk of reminder failure due to the user ignoring a single reminder method, ensuring that the medication reminder signal can effectively reach the user. For example, in a healthcare management scenario, a hypertensive patient's smartphone simultaneously sends a medication reminder via ringtone, vibration, and pop-up window at a preset medication time. The patient may be watching TV, have the phone in their pocket, or be in another room; the multiple reminder methods complement each other, ensuring that the patient can perceive the medication reminder regardless of their location. For example, if the system triggers a medication reminder at 8:00 AM, the phone simultaneously rings, vibrates, and pops up a notification message requesting medication.

[0026] S22: After issuing the medication reminder signal, monitor the user's feedback operation to the medication reminder signal within a preset response time. Specifically, in this embodiment of the invention, after issuing the medication reminder signal, a preset response time is set as a monitoring window to continuously monitor the user's feedback operation to the medication reminder signal, providing a complete time interval basis for determining the response status of this medication reminder. The preset response time setting enables the system to distinguish between two states: the user responds within a reasonable time and the user does not respond. For example, in a medical and health management scenario, the preset response time is set to 60 seconds. The system starts timing after issuing the medication reminder signal and monitors whether the patient has operated on the reminder notification within 60 seconds.

[0027] S23: When a feedback operation to the medication reminder signal is detected within the preset response time, the operation time and operation type of the feedback operation are recorded, and the operation time of the feedback operation is used as the timestamp of the behavior start signal. The operation type includes a medication confirmation operation and a delayed reminder operation. Specifically, in this embodiment of the invention, when a user's feedback operation to the medication reminder signal is detected within the preset response time, the time of occurrence of the operation is used as the timestamp of the behavior start signal, and the specific type of the operation is recorded. By recording the operation type and timestamp, the system can accurately distinguish between the user's immediate intention to confirm medication and their intention to delay medication. For example, in a healthcare management scenario, after receiving a medication reminder, the patient clicks the "confirm medication" button in the notification. The system records the operation type of this feedback operation as a medication confirmation operation and uses the time the patient clicks the button as the timestamp of the behavior start signal. In another scenario, if a patient cannot take medication immediately because they are eating, they click the "10-minute reminder" button. The system records the operation type as a delayed reminder operation and similarly uses the time of clicking the button as the timestamp of the behavior start signal.

[0028] S24: When no feedback operation is detected within the preset response time, it is recorded as an ignored medication reminder state, and the end time of the preset response time is used as the timestamp of the behavior start signal. Specifically, in this embodiment of the invention, when no feedback operation is detected within the preset response time, the system marks the reminder as an ignored medication reminder state and uses the end time of the preset response time as the timestamp of the behavior start signal to capture the patient's behavior of taking medication independently without a reminder response. For example, in a medical and health management scenario, after a patient's medication reminder is issued at 8:00 AM, the patient does not take any action on the reminder notification within 60 seconds. The system records this reminder as an ignored medication reminder state and uses the end time of the 60-second countdown as the timestamp of the behavior start signal. The patient may go to the medicine box to take the medication on their own habit, even with their phone on silent or without their phone. Using this timestamp as a basis to start subsequent medicine box opening and closing detection and hand movement data collection, it is still possible to capture the patient's independent medication behavior, thereby avoiding simply judging such situations as missed doses.

[0029] S30: Within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device. Specifically, in this embodiment of the invention, using the behavior start signal as the time reference, two types of physical behavior data—pillbox dimension and limb dimension—are collected simultaneously within a preset effective time window. Time constraints ensure that the collected data is highly correlated with the current medication behavior, and objective evidence is obtained from the two physical dimensions of drug contact and limb execution using the sensing capabilities of different devices. The time window mechanism effectively eliminates the interference of irrelevant behaviors outside the window on the judgment result; simultaneous collection by multiple devices enables the system to simultaneously obtain two types of objective evidence reflecting drug contact behavior and limb execution behavior, providing multi-source data support for subsequent cross-validation. For example, in a medical and health management scenario, the preset time window is set to within 5 minutes after the medication reminder is issued. After the patient clicks to confirm medication, the system activates this time window. During this period, the smart pillbox continuously detects and reports the opening and closing of the pillbox lid, recording whether the pillbox has been opened; the smartwatch continuously collects movement data of the patient's arm (the side wearing the pillbox) through its built-in motion sensor to detect whether the patient has performed any medication-related limb movements such as raising their hand to retrieve the medication or putting the medication in their mouth. For example, after clicking confirm, the patient walks to the pillbox, opens it, takes out the medication, and then raises their hand to put the medication in their mouth and swallow it. Both the smart pillbox and the smartwatch record the corresponding opening event and hand movement data, all of which fall within a 5-minute time window and are determined by the system to be relevant to this medication reminder. Specifically, as shown... Figure 4 The above, Figure 4 yes Figure 2 A flowchart illustrating a specific implementation of step S30. Specifically, it includes the following steps S31-S33: S31: Within a first preset time after the medication reminder is triggered, the opening and closing status data of the smart pillbox is collected by the opening and closing sensor of the smart pillbox. The opening and closing status data includes an opening timestamp, a closing timestamp, and the duration of the opening. Specifically, in this embodiment of the invention, within a first preset time after the medication reminder is triggered, the opening and closing event of the pillbox lid is sensed by the opening and closing sensor built into the smart pillbox, the opening timestamp and the closing timestamp are recorded, and the duration of the opening is obtained by calculating the difference between the two timestamps. By recording the complete time information of opening and closing, it is possible not only to determine whether the pillbox has been opened, but also to distinguish normal medication retrieval behavior from abnormal situations such as accidental opening or prolonged failure to close the lid, based on the duration of the opening, providing more refined drug contact behavior data for subsequent fusion judgment. For example, in a medical and health management scenario, the first preset time is set to within 5 minutes after the medication reminder is triggered. After receiving a medication reminder from the smartphone at 8:00 AM, the patient walks to the pillbox and opens the lid to take out the medication at 8:01 AM, and then closes the lid at 8:02 AM. The smart pillbox's opening and closing sensors record the opening timestamp as 08:01:30 and the closing timestamp as 08:02:10. The system automatically calculates the opening duration as 40 seconds. This duration is within a reasonable range for normal medication retrieval behavior, and the system marks it as a valid opening and closing event. If the patient only touches the pillbox, causing the lid to open momentarily and then immediately close, and the opening duration is less than 1 second, the system identifies it as a false touch event and does not include it in the criteria for determining valid medication retrieval behavior.

[0030] S32: Within a second preset time period after the medication reminder is triggered, acceleration data is collected through the accelerometer of the wearable device, and angular velocity data is collected through the angular velocity sensor of the wearable device. Specifically, in this embodiment of the invention, within a second preset time period after the medication reminder is triggered, acceleration data and angular velocity data of the patient's arm are collected by the accelerometer and angular velocity sensor built into the wearable device, respectively. The accelerometer measures the linear acceleration change of the arm movement, and the angular velocity sensor measures the angular velocity change of the arm rotating around each axis. The two types of data together constitute complete information describing the three-dimensional motion state of the arm. The joint collection of acceleration data and angular velocity data can completely capture the arm's motion trajectory and posture changes in space, providing a raw data basis for subsequent identification of specific action features related to medication. For example, in a medical and health management scenario, the second preset time is also set to within 5 minutes after the medication reminder is triggered, consistent with the first preset time. The smartwatch worn by the patient automatically starts the motion data collection mode after the medication reminder is triggered, continuously collecting motion data of the wrist through the built-in accelerometer and gyroscope. After the patient opens the medicine box and takes out the medication, they raise their arm from its natural hanging position, bring the medication to their mouth, and hold it at their mouth to swallow it. The changes in the linear acceleration and angular velocity of the arm throughout the entire process are fully recorded by the smartwatch.

[0031] S33: Based on the acceleration data and the angular velocity data, extract the user's key hand movement features and record the action timestamps corresponding to each key hand movement feature. The key hand movement features include hand lifting features, hand reaching mouth features, and hand hovering features. Specifically, in this embodiment of the invention, based on the collected acceleration and angular velocity data, key hand movement features related to medication administration are extracted through signal processing and feature recognition algorithms, and a corresponding action timestamp is recorded for each identified feature. The hand lifting feature, hand reaching mouth feature, and hand hovering feature correspond to the kinematic feature patterns of the three continuous sub-actions in the medication administration action chain: lifting the hand to take the medicine, putting the medicine into the mouth, and pausing to swallow. The original sensor data is transformed into a sequence of action features with clear behavioral semantics, enabling the system to identify whether medication-related actions have occurred from a continuous motion data stream. The occurrence time of each feature is marked with a timestamp, providing structured behavioral evidence for subsequent cross-validation with reminder response data and medicine box opening / closing data in the time dimension. For example, in a healthcare management scenario, the system analyzes and processes acceleration and angular velocity data collected by the patient's smartwatch. When it detects that the arm starts moving upward from a stationary state and the acceleration exceeds a preset threshold, it is identified as a hand raising feature, and the action timestamp is recorded as 08:01:35; when it detects a change in wrist posture angle and the palm moving towards the face, it is identified as a hand reaching the mouth feature, and the action timestamp is recorded as 08:01:38; when it detects that the arm movement tends to stop and the wrist maintains a stable posture at the mouth position for a duration exceeding a preset threshold, it is identified as a hand hovering feature, and the action timestamp is recorded as 08:01:39.

[0032] S40: The system fuses and judges the behavior initiation signal, the opening / closing state data, and the hand movement data to determine whether the user has taken the medication. Specifically, in this embodiment of the invention, the behavior initiation signal, the medicine box opening / closing state data, and the hand movement data are cross-validated in terms of time and behavioral logic, and the user's actual medication behavior is judged through a complete chain of evidence. For example, in a medical and health management scenario, the system performs time alignment and logical analysis on the reminder response data, medicine box opening / closing data, and hand movement data. For example, if a patient clicks to confirm medication at 8:00 AM, and then within a 5-minute window the smart medicine box detects an opening event with a reasonable duration, and the smartwatch detects hand movement data, and the occurrence times of the above events are sequential and logically coherent, the system comprehensively determines that the patient has taken the antihypertensive medication on time. Conversely, if the patient only clicks to confirm but there is no record of the medicine box being opened and the smartwatch does not detect any related actions, the system determines that the patient has not taken the medication and records this abnormality in the health management log for subsequent review and follow-up by medical staff or family members. Figure 5 The above, Figure 5 yes Figure 2 A flowchart illustrating a specific implementation of step S40. Specifically, it includes the following steps S41-S43: S41: Based on the behavior start signal, the opening / closing state data, and the hand movement data, determine whether the reminder response condition, the medicine box opening condition, and the medication taking action condition are simultaneously met. Specifically, in this embodiment of the invention, the behavior start signal, the opening / closing state data, and the hand movement data are mapped to three independent judgment dimensions: reminder response condition, medicine box opening condition, and medication taking action condition. Each dimension is judged according to preset rules, thereby realizing the transformation of multi-source data into standardized behavior conditions. By unifying heterogeneous multi-source data into three standardized behavior conditions, the system can evaluate evidence from different sources within a unified logical framework, avoiding the problem of inconsistent judgment rules due to differences in data types. For example, in a healthcare management scenario, after a patient receives a medication reminder from their smartphone at 8 PM, the system enters a fusion judgment process. The system first extracts the patient's behavior start signal for the reminder and analyzes its operation type; simultaneously, it retrieves the opening / closing state data reported by the smart medicine box within a 5-minute time window; and obtains the hand movement feature sequence collected and extracted by the smartwatch within the same time window. The system compares the three types of data mentioned above with preset reminder response conditions, pillbox opening conditions, and medication taking action conditions one by one. For example, the reminder response condition requires the operation type to be a confirmation of medication taking; the pillbox opening condition requires a valid opening event to occur within the time window and the opening duration to be reasonable; the medication taking action condition requires the sequential recognition of three features within the time window: hand raised, hand reaching the mouth, and hand hovering. Specifically... Figure 6 The above, Figure 6 yes Figure 5 A flowchart illustrating a specific implementation of step S41. Specifically, it includes the following steps S411-S413: S411: When the operation type of the behavior starting signal is a medication confirmation operation, the reminder response condition is determined to be met; when the operation type of the behavior starting signal is a delayed reminder operation or an ignored medication reminder state, the reminder response condition is determined to be unmet. Specifically, in this embodiment of the invention, the operation type in the behavior starting signal is used as the basis for determining the reminder response condition. A medication confirmation operation indicates that the patient has actively confirmed the intention to take medication, thus meeting the condition; a delayed reminder operation indicates that the patient is aware of the medication reminder but chooses to postpone processing; an ignored medication reminder state indicates that the patient has not responded to the reminder. Neither of these situations indicates that the patient has formed an immediate intention to take medication, therefore the condition is not met. For example, in a medical and health management scenario, a patient needs to take medication at 9:00 AM every day. After the smartphone triggers a medication reminder at 9:00 AM, the system determines the response condition based on the type of operation indicated by the initial signal: if the patient clicks the "Confirm Medication Take" button within the response time, the operation type is "Confirm Medication Take," and the system determines that the reminder response condition is met; if the patient clicks the "Remind in 30 Minutes" button, the operation type is "Delay Reminder," and the system determines that the reminder response condition is not met; if the patient does not make any response within the preset response time, the patient is recorded as ignoring the medication reminder.

[0033] S412: When an opening timestamp exists within the preset time window and the duration of opening is within the first preset threshold range, the opening condition of the medicine box is determined to be met; otherwise, the opening condition is determined not to be met. Specifically, in this embodiment of the invention, the existence of an opening timestamp within the preset time window is used as the basic criterion for judging the opening of the medicine box, and a comparison between the duration of opening and the first preset threshold range is further introduced to exclude invalid events such as instantaneous opening and closing. Through the dual judgment mechanism, the occurrence of the opening event is confirmed, and invalid opening and closing events such as accidental touch and instantaneous touch are filtered out by the duration, avoiding misjudgment caused by sensor mis-triggering. In the medical and health management scenario, the first preset threshold range is set to 10 seconds to 120 seconds. The lower limit of this threshold range is used to exclude instantaneous accidental touch, and the upper limit is used to exclude abnormally long periods of not being closed. After receiving the medication reminder, the patient walks to the medicine box to take the medicine. The smart medicine box records the opening timestamp as 09:01:15 and the closing timestamp as 09:01:50. The system automatically calculates the duration of opening as 35 seconds. Since an opening timestamp exists within the preset time window, and the duration of 35 seconds falls within the first preset threshold range of 10 to 120 seconds, the system determines that the conditions for opening the medicine box are met. In another scenario, a patient's family member accidentally touches the medicine box while tidying the table, causing the lid to pop open and immediately close. The opening duration is only 1 second, which is lower than the lower limit of the first preset threshold range, and the system determines that the conditions for opening the medicine box are not met.

[0034] S413: When the hand-raising feature, the hand-to-mouth feature, and the hand-hanging feature are detected within the preset time window, and the time interval between the action timestamps corresponding to each key hand action feature is within the range of the second preset threshold, it is determined that the medication-taking action condition is met; otherwise, it is determined that the medication-taking action condition is not met. Specifically, in this embodiment of the invention, whether the hand-raising feature, the hand-to-mouth feature, and the hand-hanging feature are sequentially detected within the preset time window is used as the basic criterion for judging the medication-taking action. Furthermore, a comparison is introduced between the time interval corresponding to each action feature and the second preset threshold range to ensure that the three action features form a coherent sequence that is closely connected in time, rather than isolated actions that are dispersed in time. For example, in a medical and health management scenario, the second preset threshold range is set to a time interval between adjacent action features that does not exceed 5 seconds. After the patient opens the medicine box and takes out the medication, the smartwatch continuously collects hand movement data. The system sequentially identified the following data stream features: hand raised (timestamp 09:01:40), hand reaching mouth (timestamp 09:01:43), and hand hovering (timestamp 09:01:44). These three action features were identified sequentially within a preset time window, with time intervals of 3 seconds and 1 second between adjacent features, both within the second preset threshold range. This indicates that the patient's actions constituted a continuous medication-taking behavior, and the system determined that the medication-taking condition was met.

[0035] S42: When the reminder response condition, the pillbox opening condition, and the medication taking action condition are all met simultaneously, it is determined that the user has completed taking the medication. Specifically, in this embodiment of the invention, when the three conditions are met simultaneously, through a three-condition joint determination mechanism, the system determines that medication has been taken only when there is evidence from three independent dimensions: reminder response, pillbox opening / closing, and medication taking action. This fundamentally avoids erroneous conclusions caused by misjudgment based on a single data source, and significantly improves the accuracy of medication behavior detection. For example, in a healthcare management scenario, after receiving a reminder at 8:00 PM, the patient clicked to confirm taking medication, and the system determined that the reminder response conditions were met. Within the following 5 minutes, the smart pillbox recorded an opening timestamp of 20:01 and a closing timestamp of 20:02. The 60-second opening duration was within a reasonable range, and the system determined that the pillbox opening condition was met. During the same period, the smartwatch detected the patient's arm successively raising at 20:01:20, reaching the mouth at 20:01:25, and hovering at 20:01:28. These three actions progressed sequentially and the time intervals were reasonable, so the system determined that the medication taking action condition was met. Since all three conditions were met, and the timestamps of each event progressed sequentially, the system comprehensively determined that the patient had completed taking the medication.

[0036] S43: If at least one of the reminder response condition, the pillbox opening condition, and the medication taking action condition is not met, the system determines that the user's medication taking has been abnormal. Specifically, in this embodiment of the invention, if at least one of the three conditions is not met, it means that the system has failed to obtain a complete chain of evidence for medication taking behavior, and there is a possibility that the patient has not taken the medication, has not completed all medication taking actions, or that data collection is abnormal. For example, in a medical and health management scenario, the patient receives a reminder at 8 pm and clicks to confirm medication, but then forgets to actually take the medication because of a phone call. There is no record of the pillbox being opened or closed, and the watch does not detect the medication taking action. In this case, only the reminder response condition is met, but the pillbox opening condition and the medication taking action condition are not met, and the system determines that this medication taking has been abnormal.

[0037] In this embodiment of the invention, after fusing and judging the behavior initiation signal, the opening and closing state data, and the hand movement data to determine whether the user has completed taking the medication, the method further includes: S51: Obtain the timestamp of the behavior starting point signal, the timestamp of opening the box in the opening and closing state data, and the action timestamps corresponding to each key hand action feature in the hand action data. Specifically, in this embodiment of the invention, the timestamp is extracted from the behavior starting point signal, the timestamp of opening the box is extracted from the opening and closing state data, and the action timestamps corresponding to each key hand action feature are extracted from the hand action data. By uniformly extracting the time information from each data source, different types of heterogeneous data can be compared and analyzed on the same time dimension, providing a data foundation for subsequent time-series correlation calculation. For example, in a medical and health management scenario, patients have a fixed medication time of 7:00 AM every Monday. After completing the fusion judgment, the system starts the confidence calculation process, first extracting time information from each data source. The patient clicked to confirm medication at 07:00:00, with the timestamp of the action's initiation signal being 07:00:00; the smart pillbox recorded the opening timestamp as 07:01:30; the smartwatch detected the hand raising feature at 07:01:35, the hand reaching the mouth at 07:01:40, and the hand hovering at 07:01:42. The system extracted all these timestamps and passed them to the next step for time difference calculation. These precise timestamp data constituted the complete time series for subsequent time series analysis.

[0038] S52: Calculate the first time difference between the timestamp of the behavior start signal and the timestamp of opening the box, and the second time difference between the timestamp of opening the box and the action timestamps corresponding to each key hand movement feature. Specifically, in this embodiment of the invention, the first time difference between the timestamp of the behavior start signal and the timestamp of opening the box is calculated, which reflects the time interval between the patient responding to the reminder and touching the medication; the second time difference between the timestamp of opening the box and the action timestamps corresponding to each key hand movement feature is calculated, which reflects the time interval between the patient opening the medicine box and performing the medication taking action. For example, in a medical and health management scenario, the timestamp of the behavior start signal is 07:00:00, the timestamp of opening the box is 07:01:30, and the first time difference between the two is 90 seconds. The second time difference between the box opening timestamp and the hand-raising timestamp (07:01:35) is 5 seconds; the second time difference between the hand-reaching-mouth timestamp (07:01:40) and the hand-holding timestamp (07:01:42) is 10 seconds; and the second time difference between the hand-holding-mout timestamp (07:01:42) is 12 seconds. The system passes the first time difference of 90 seconds and the second time differences of 5, 10, and 12 seconds to the next step for determining the temporal correlation. The first time difference reflects that one and a half minutes have passed between the patient confirming medication and actually picking up the medication, which is consistent with the actual situation that the patient needs to walk from the living room to the bedroom to pick up the medication; each of the second time differences is on the order of several seconds, indicating that the patient immediately performed a continuous medication-taking action after picking up the medication.

[0039] S53: Determine the temporal correlation between the reminder response behavior, the opening / closing behavior, and the hand gesture behavior based on the first time difference and the second time difference. Specifically, in this embodiment of the invention, based on the specific values ​​of the first and second time differences, determine whether the reminder response behavior, the opening / closing behavior, and the hand gesture behavior form a sequential and reasonably spaced sequence on the time axis. When both the first and second time differences are within their respective preset reasonable time ranges, it indicates that there is a high temporal correlation between the three behaviors; when any time difference exceeds the reasonable range, it indicates that there is a time discontinuity between the behaviors, and the temporal correlation is low. For example, in a medical and health management scenario, the patient clicks to confirm medication at 07:00, but the medicine box is opened at 07:20. The first time difference is 1200 seconds, which exceeds the reasonable range, so the system determines that the temporal correlation is low.

[0040] S54: Calculate the medication behavior confidence score based on the determination results of the reminder response condition, the medicine box opening condition, the medication action condition, and the temporal correlation. Specifically, in this embodiment of the invention, the determination results of the reminder response condition, the medicine box opening condition, the medication action condition, and the temporal correlation are comprehensively calculated to obtain the medication behavior confidence score. The confidence score can correctly determine the actual medication behavior even when some conditions are not met but the remaining evidence is strongly correlated, through the compensating effect of the temporal correlation. For example, in a medical and health management scenario, the system uses a weighted calculation method to obtain the confidence score. When the reminder response condition, the medicine box opening condition, and the medication action condition are met, and the temporal correlation is high, the system calculates a confidence score of 95. In another scenario, the patient did not trigger the reminder because their phone was not nearby. However, based on their habit, they went to the medicine box at a fixed time to take their medication. The reminder response conditions were not met, but the conditions for opening the medicine box and taking the medication were met. Furthermore, the second time difference between the timestamp of opening the medicine box and the timestamp of the hand action were within a reasonable range, indicating a high temporal correlation. The system calculated a confidence score of 72. Although this score is lower than the score when all three conditions are met, it is still at a relatively high level, reflecting the system's reasonable assessment ability of the patient's self-medication behavior.

[0041] S55: When the confidence score of the medication behavior is greater than or equal to a preset threshold, the user is determined to have completed medication. Specifically, in this embodiment of the invention, the calculated confidence score of the medication behavior is compared with a preset threshold. When the score is greater than or equal to the preset threshold, the user is determined to have completed medication. The preset threshold is a judgment standard line set by the system based on statistical analysis of a large amount of actual medication behavior data. It is used to divide the decision boundary between completed and incomplete medication in the continuous numerical space of the confidence score. By setting a reasonable judgment threshold, the system can make a judgment on near-complete evidence links beyond the strict three-condition judgment rule. For example, in a medical and health management scenario, the preset threshold is set to 65 points. If the patient meets all three conditions and has a confidence score of 95 points, which is greater than the preset threshold of 65 points, the system determines that the user has completed medication.

[0042] As can be seen, in the above solution, by coordinating multiple devices, the opening and closing data of the medicine box and the hand movement data are collected synchronously within a preset time window. The behavior starting signal, the opening and closing state data and the hand movement data are fused and cross-validated to construct a complete behavioral evidence chain, which solves the problem of misjudgment of medication not being taken despite being reminded or the box being opened but not swallowed, and improves the accuracy of medication behavior detection.

[0043] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.

[0044] In one embodiment, a medication behavior detection device based on multi-device collaboration is provided, which corresponds one-to-one with the medication behavior detection method based on multi-device collaboration described in the above embodiments. For example... Figure 7 As shown, Figure 7 This is a schematic diagram of a medication behavior detection device based on multi-device collaboration according to an embodiment of the present invention. The device includes an acquisition module 71, a recording module 72, a data collection module 73, and a judgment module 74. Detailed descriptions of each functional module are as follows: The acquisition module 71 is used to acquire the smart terminal, smart pillbox and wearable device used for collaborative detection of user medication behavior, and to establish communication connection between the smart terminal, smart pillbox and wearable device. The recording module 72 is used to issue a medication reminder through the smart terminal at a preset user medication time point, and record the user's response to the medication reminder as a behavior start signal; The acquisition module 73 is used to acquire the opening and closing status data of the smart pillbox within a preset time window after the medication reminder is issued, and to acquire the user's hand movement data through the wearable device. The judgment module 74 is used to perform a fusion judgment on the behavior start signal, the opening and closing state data and the hand action data to determine whether the user has completed taking the medication.

[0045] In one embodiment, the recording module 72 is specifically used for: At preset user medication time points, a medication reminder signal is generated through the smart terminal, and the medication reminder signal includes at least one of sound signal, vibration signal and visual notification signal; After the medication reminder signal is issued, the user's feedback on the medication reminder signal is monitored within a preset response time. When a feedback operation of the medication reminder signal is detected within the preset response time, the operation time and operation type of the feedback operation are recorded, and the operation time of the feedback operation is used as the timestamp of the behavior start signal. The operation type includes medication confirmation operation and delayed reminder operation. If no feedback operation of the medication reminder signal is detected within the preset response time, it is recorded as ignoring the medication reminder, and the end time of the preset response time is used as the timestamp of the behavior start signal.

[0046] In one embodiment, the acquisition module 73 is specifically used for: Within a first preset time after the medication reminder is triggered, the smart pillbox's opening and closing status data is collected by the smart pillbox's opening and closing sensor. The opening and closing status data includes the opening timestamp, closing timestamp, and duration of opening. Within a second preset time after the medication reminder is triggered, acceleration data is collected by the accelerometer of the wearable device, and angular velocity data is collected by the angular velocity sensor of the wearable device. Based on the acceleration data and the angular velocity data, the user's key hand movement features are extracted, and the action timestamps corresponding to each key hand movement feature are recorded. The key hand movement features include hand lifting features, hand reaching mouth features, and hand hovering features.

[0047] In one embodiment, the determination module 74 is specifically used for: Based on the behavior start signal, the opening and closing state data, and the hand action data, determine whether the reminder response condition, the medicine box opening condition, and the medication taking action condition are met simultaneously. When the reminder response condition, the pillbox opening condition, and the medication taking action condition are all met simultaneously, it is determined that the user has completed taking the medication. If at least one of the reminder response conditions, the pillbox opening conditions, and the medication taking action conditions is not met, it is determined that the user's medication taking has become abnormal.

[0048] In one embodiment, the determination module 74 is further configured to: When the operation type of the behavior start signal is a medication confirmation operation, it is determined that the reminder response condition is met; when the operation type of the behavior start signal is a delayed reminder operation or an ignored medication reminder status, it is determined that the reminder response condition is not met. When an opening timestamp exists within the preset time window and the duration of opening is within the first preset threshold range, the opening condition of the medicine box is determined to be met; otherwise, the opening condition of the medicine box is determined to be unmet. When the hand raising feature, the hand reaching the mouth feature, and the hand hovering feature are detected within the preset time window, and the time interval of the action timestamps corresponding to each key hand action feature is within the range of the second preset threshold, it is determined that the medication taking action condition is met; otherwise, it is determined that the medication taking action condition is not met.

[0049] In one embodiment, the acquisition module 71 is specifically used for: Identify smart terminals, smart pillboxes, and wearable devices in the same network environment, and establish distributed communication connections between the smart terminals, smart pillboxes, and wearable devices; The distributed communication connection synchronizes the sensor information of the smart pillbox and the wearable device. The sensor information of the smart pillbox includes detection of the pillbox's open / closed state, and the sensor information of the wearable device includes acceleration data and angular velocity data.

[0050] In one embodiment, the medication behavior detection device based on multi-device collaboration is further used for: The timestamp of the behavior start signal, the timestamp of the box opening in the opening and closing state data, and the timestamp of each key hand movement feature in the hand movement data are obtained. Calculate the first time difference between the timestamp of the behavior start signal and the timestamp of the box opening, and the second time difference between the timestamp of the box opening and the timestamps of the actions corresponding to each key hand movement feature; Based on the first time difference and the second time difference, determine the temporal correlation between the reminder response behavior, the opening and closing behavior, and the hand movement behavior; Based on the determination results of the reminder response conditions, the determination results of the medicine box opening conditions, the determination results of the medication taking action conditions, and the temporal correlation degree, a medication behavior confidence score is calculated. When the confidence score of the medication behavior is greater than or equal to a preset threshold, it is determined that the user has completed taking the medication.

[0051] This invention provides a medication behavior detection device based on multi-device collaboration. Through multi-device collaboration, it synchronously collects data on the opening and closing of the medicine box and hand movements within a preset time window. It then fuses and cross-verifies the behavior starting signal, the opening and closing state data, and the hand movement data to construct a complete chain of behavioral evidence. This solves the problem of misjudgment in cases where the patient has been reminded but has not taken the medication, or where the medicine box has been opened but the medication has not been swallowed, thus improving the accuracy of medication behavior detection.

[0052] Specific limitations regarding the medication behavior detection device based on multi-device collaboration can be found in the limitations of the medication behavior detection method based on multi-device collaboration mentioned above, and will not be repeated here. Each module in the aforementioned medication behavior detection device based on multi-device collaboration can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in the computer device in hardware form, or stored in the memory of the computer device in software form, so that the processor can call and execute the corresponding operations of each module.

[0053] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 8 As shown, Figure 8This is a schematic diagram of a computer device according to an embodiment of the present invention. The computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage media stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface is used to communicate with external clients via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a server-side method for detecting medication behavior based on multi-device collaboration.

[0054] In one embodiment, a computer device is provided, which may be a client, and its internal structure diagram may be as follows: Figure 9 As shown, Figure 9 This is another schematic diagram of a computer device according to an embodiment of the present invention. The computer device includes a processor, memory, network interface, display screen, and input device connected via a system bus. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a client-side method for detecting medication behavior based on multi-device collaboration.

[0055] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps: Acquire smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior, and establish communication connections between the smart terminals, smart pillboxes, and wearable devices; At the preset medication time, the smart terminal sends a medication reminder and records the user's response to the medication reminder as a behavior start signal; Within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device; The system integrates the behavior initiation signal, the opening / closing state data, and the hand movement data to determine whether the user has completed taking the medication.

[0056] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor: Acquire smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior, and establish communication connections between the smart terminals, smart pillboxes, and wearable devices; At the preset medication time, the smart terminal sends a medication reminder and records the user's response to the medication reminder as a behavior start signal; Within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device; The system integrates the behavior initiation signal, the opening / closing state data, and the hand movement data to determine whether the user has completed taking the medication.

[0057] It should be noted that the functions or steps that can be implemented by the computer-readable storage medium or computer device described above can be referred to the relevant descriptions on the server side and client side in the foregoing method embodiments. To avoid repetition, they will not be described one by one here.

[0058] Those skilled in the art will understand 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 non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0059] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0060] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.

Claims

1. A method for detecting medication use behavior based on multi-device collaboration, characterized in that, include: Acquire smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior, and establish communication connections between the smart terminals, smart pillboxes, and wearable devices; At the preset medication time, the smart terminal sends a medication reminder and records the user's response to the medication reminder as a behavior start signal; Within a preset time window after the medication reminder is issued, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device; The system integrates the behavior initiation signal, the opening / closing state data, and the hand movement data to determine whether the user has completed taking the medication.

2. The method for detecting medication behavior based on multi-device collaboration according to claim 1, characterized in that, The step of issuing a medication reminder via the smart terminal at a preset user medication time point and recording the user's response to the medication reminder as a behavior start signal includes: At preset user medication time points, a medication reminder signal is generated through the smart terminal, and the medication reminder signal includes at least one of sound signal, vibration signal and visual notification signal; After the medication reminder signal is issued, the user's feedback on the medication reminder signal is monitored within a preset response time. When a feedback operation of the medication reminder signal is detected within the preset response time, the operation time and operation type of the feedback operation are recorded, and the operation time of the feedback operation is used as the timestamp of the behavior start signal. The operation type includes medication confirmation operation and delayed reminder operation. If no feedback operation of the medication reminder signal is detected within the preset response time, it is recorded as ignoring the medication reminder, and the end time of the preset response time is used as the timestamp of the behavior start signal.

3. The method for detecting medication behavior based on multi-device collaboration according to claim 1, characterized in that, Within a preset time window after the medication reminder is triggered, the opening and closing status data of the smart pillbox is collected, and the user's hand movement data is collected through the wearable device, including: Within a first preset time after the medication reminder is triggered, the smart pillbox's opening and closing status data is collected by the smart pillbox's opening and closing sensor. The opening and closing status data includes the opening timestamp, closing timestamp, and duration of opening. Within a second preset time after the medication reminder is triggered, acceleration data is collected by the accelerometer of the wearable device, and angular velocity data is collected by the angular velocity sensor of the wearable device. Based on the acceleration data and the angular velocity data, the user's key hand movement features are extracted, and the action timestamps corresponding to each key hand movement feature are recorded. The key hand movement features include hand lifting features, hand reaching mouth features, and hand hovering features.

4. The method for detecting medication behavior based on multi-device collaboration according to claim 3, characterized in that, The process of fusing and judging the behavior initiation signal, the opening and closing state data, and the hand movement data to determine whether the user has completed medication administration includes: Based on the behavior start signal, the opening and closing state data, and the hand action data, determine whether the reminder response condition, the medicine box opening condition, and the medication taking action condition are met simultaneously. When the reminder response condition, the pillbox opening condition, and the medication taking action condition are all met simultaneously, it is determined that the user has completed taking the medication. If at least one of the reminder response conditions, the pillbox opening conditions, and the medication taking action conditions is not met, it is determined that the user's medication taking has become abnormal.

5. The method for detecting medication behavior based on multi-device collaboration according to claim 4, characterized in that, The step of determining whether the reminder response condition, the pillbox opening condition, and the medication taking action condition are simultaneously met based on the behavior initiation signal, the opening / closing state data, and the hand movement data includes: When the operation type of the behavior start signal is a medication confirmation operation, it is determined that the reminder response condition is met; when the operation type of the behavior start signal is a delayed reminder operation or an ignored medication reminder status, it is determined that the reminder response condition is not met. When an opening timestamp exists within the preset time window and the duration of opening is within the first preset threshold range, the opening condition of the medicine box is determined to be met; otherwise, the opening condition of the medicine box is determined to be unmet. When the hand raising feature, the hand reaching the mouth feature, and the hand hovering feature are detected within the preset time window, and the time interval of the action timestamps corresponding to each key hand action feature is within the range of the second preset threshold, it is determined that the medication taking action condition is met; otherwise, it is determined that the medication taking action condition is not met.

6. The method for detecting medication behavior based on multi-device collaboration according to claim 1, characterized in that, The acquisition of smart terminals, smart pillboxes, and wearable devices for collaborative detection of user medication behavior, and the establishment of communication connections between the smart terminals, smart pillboxes, and wearable devices, includes: Identify smart terminals, smart pillboxes, and wearable devices in the same network environment, and establish distributed communication connections between the smart terminals, smart pillboxes, and wearable devices; The distributed communication connection synchronizes the sensor information of the smart pillbox and the wearable device. The sensor information of the smart pillbox includes detection of the pillbox's open / closed state, and the sensor information of the wearable device includes acceleration data and angular velocity data.

7. The method for detecting medication behavior based on multi-device collaboration according to claim 5, characterized in that, After fusing and judging the behavior initiation signal, the opening and closing state data, and the hand movement data to determine whether the user has completed medication administration, the method further includes: The timestamp of the behavior start signal, the timestamp of the box opening in the opening and closing state data, and the timestamp of each key hand movement feature in the hand movement data are obtained. Calculate the first time difference between the timestamp of the behavior start signal and the timestamp of the box opening, and the second time difference between the timestamp of the box opening and the timestamps of the actions corresponding to each key hand movement feature; Based on the first time difference and the second time difference, determine the temporal correlation between the reminder response behavior, the opening and closing behavior, and the hand movement behavior; Based on the determination results of the reminder response conditions, the determination results of the medicine box opening conditions, the determination results of the medication taking action conditions, and the temporal correlation degree, a medication behavior confidence score is calculated. When the confidence score of the medication behavior is greater than or equal to a preset threshold, it is determined that the user has completed taking the medication.

8. A medication behavior detection device based on multi-device collaboration, characterized in that, include: The acquisition module is used to acquire smart terminals, smart pillboxes, and wearable devices used for collaborative detection of user medication behavior, and to establish communication connections between the smart terminals, smart pillboxes, and wearable devices. The recording module is used to issue a medication reminder through the smart terminal at a preset user medication time point, and record the user's response to the medication reminder as a behavior start signal; The data acquisition module is used to collect the opening and closing status data of the smart pillbox within a preset time window after the medication reminder is issued, and to collect the user's hand movement data through the wearable device. The judgment module is used to fuse and judge the behavior start signal, the opening and closing state data and the hand action data to determine whether the user has completed taking the medication.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the drug use behavior detection method based on multi-device collaboration as described in any one of claims 1 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the drug use behavior detection method based on multi-device collaboration as described in any one of claims 1 to 7.