Paz-Arbaizar Leire, Lopez-Castroman Jorge, Artés-Rodríguez Antonio, Olmos Pablo M, Ramírez David
Signal Theory and Communications Department, Universidad Carlos III de Madrid, Leganés, Spain.
Department of Psychiatry, Public Health, Radiology, Nursing and Medicine, University of Santiago de Compostela, Santiago de Compostela, Spain.
J Med Internet Res. 2025 Mar 18;27:e63962. doi: 10.2196/63962.
Monitoring the emotional states of patients with psychiatric problems has always been challenging due to the noncontinuous nature of clinical assessments, the effect of the health care environment, and the inherent subjectivity of evaluation instruments. However, mental states in psychiatric disorders exhibit substantial variability over time, making real-time monitoring crucial for preventing risky situations and ensuring appropriate treatment.
This study aimed to leverage new technologies and deep learning techniques to enable more objective, real-time monitoring of patients. This was achieved by passively monitoring variables such as step count, patient location, and sleep patterns using mobile devices. We aimed to predict patient self-reports and detect sudden variations in their emotional valence, identifying situations that may require clinical intervention.
Data for this project were collected using the Evidence-Based Behavior (eB2) app, which records both passive and self-reported variables daily. Passive data refer to behavioral information gathered via the eB2 app through sensors embedded in mobile devices and wearables. These data were obtained from studies conducted in collaboration with hospitals and clinics that used eB2. We used hidden Markov models (HMMs) to address missing data and transformer deep neural networks for time-series forecasting. Finally, classification algorithms were applied to predict several variables, including emotional state and responses to the Patient Health Questionnaire-9.
Through real-time patient monitoring, we demonstrated the ability to accurately predict patients' emotional states and anticipate changes over time. Specifically, our approach achieved high accuracy (0.93) and a receiver operating characteristic (ROC) area under the curve (AUC) of 0.98 for emotional valence classification. For predicting emotional state changes 1 day in advance, we obtained an ROC AUC of 0.87. Furthermore, we demonstrated the feasibility of forecasting responses to the Patient Health Questionnaire-9, with particularly strong performance for certain questions. For example, in question 9, related to suicidal ideation, our model achieved an accuracy of 0.9 and an ROC AUC of 0.77 for predicting the next day's response. Moreover, we illustrated the enhanced stability of multivariate time-series forecasting when HMM preprocessing was combined with a transformer model, as opposed to other time-series forecasting methods, such as recurrent neural networks or long short-term memory cells.
The stability of multivariate time-series forecasting improved when HMM preprocessing was combined with a transformer model, as opposed to other time-series forecasting methods (eg, recurrent neural network and long short-term memory), leveraging the attention mechanisms to capture longer time dependencies and gain interpretability. We showed the potential to assess the emotional state of a patient and the scores of psychiatric questionnaires from passive variables in advance. This allows real-time monitoring of patients and hence better risk detection and treatment adjustment.
由于临床评估的不连续性、医疗环境的影响以及评估工具固有的主观性,监测有精神问题患者的情绪状态一直具有挑战性。然而,精神疾病中的精神状态随时间表现出很大的变异性,这使得实时监测对于预防危险情况和确保适当治疗至关重要。
本研究旨在利用新技术和深度学习技术,实现对患者更客观、实时的监测。这是通过使用移动设备被动监测步数、患者位置和睡眠模式等变量来实现的。我们旨在预测患者的自我报告,并检测其情绪效价的突然变化,识别可能需要临床干预的情况。
本项目的数据使用循证行为(eB2)应用程序收集,该应用程序每天记录被动和自我报告的变量。被动数据是指通过eB2应用程序通过嵌入移动设备和可穿戴设备中的传感器收集的行为信息。这些数据来自与使用eB2的医院和诊所合作开展的研究。我们使用隐马尔可夫模型(HMM)来处理缺失数据,并使用Transformer深度神经网络进行时间序列预测。最后,应用分类算法来预测包括情绪状态和对患者健康问卷-9的反应等几个变量。
通过对患者的实时监测,我们展示了准确预测患者情绪状态并预测随时间变化的能力。具体而言,我们的方法在情绪效价分类方面实现了高准确率(0.93)和曲线下面积(AUC)为0.98的受试者工作特征(ROC)。对于提前1天预测情绪状态变化,我们获得的ROC AUC为0.87。此外,我们证明了预测对患者健康问卷-9的反应的可行性,对于某些问题表现尤为突出。例如,在与自杀意念相关的问题9中,我们的模型在预测第二天的反应时准确率达到0.9,ROC AUC为0.77。此外,我们还说明了与其他时间序列预测方法(如递归神经网络或长短期记忆单元)相比,当HMM预处理与Transformer模型相结合时,多元时间序列预测的稳定性增强。
与其他时间序列预测方法(如递归神经网络和长短期记忆)相比,当HMM预处理与Transformer模型相结合时,多元时间序列预测的稳定性得到提高,利用注意力机制来捕获更长的时间依赖性并获得可解释性。我们展示了从被动变量中提前评估患者情绪状态和精神科问卷分数的潜力。这允许对患者进行实时监测,从而更好地进行风险检测和治疗调整。