NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

DETECT: Data-Driven Evaluation of Treatments Enabled by Classification Transformers

Yuanheng Mao, Lillian Yang, Stephen Yang, Ethan Shao, Zihan Li2025

TL;DR

This paper introduces DETECT, a novel data-driven framework that uses smartphone sensor data and transformer models to objectively assess the impact of chronic pain treatments. By analyzing changes in daily activities before and after treatment, DETECT offers a more reliable and accessible alternative to subjective self-reported pain scales, paving the way for personalized patient care.

What Problem Does This Paper Address?

Chronic pain is a widespread issue that significantly impacts millions of lives, leading to reduced productivity and quality of life. A critical challenge in managing chronic pain is accurately measuring the effectiveness of treatments. Current methods, like the Numeric Rating Scale (NRS), rely on subjective self-reporting, which is prone to bias and variability. This makes it difficult for physicians to objectively gauge functional improvements and tailor treatments effectively. The paper aims to bridge this gap by providing an objective, data-driven, and accessible system for evaluating treatment outcomes.

Methods

The core of the DETECT framework is a transformer-based deep learning model designed for activity classification. This model is trained on pre-treatment daily activity data collected from smartphone sensors (accelerometer and gyroscope). To assess treatment impact, the model is then tested on post-treatment activity data. The key idea is that a successful treatment should lead to noticeable changes in a patient's movement patterns. If the transformer model's classification accuracy drops significantly when tested on post-treatment data compared to pre-treatment data, it indicates a substantial behavioral shift, suggesting a positive treatment effect.

The paper also introduces a "Treatment Effect Score" (TES) for each patient, calculated as the difference between pre-treatment and post-treatment classification accuracy. A TES threshold is then established based on patients who show meaningful improvement in their NRS scores. Patients with a TES exceeding this threshold are considered to have experienced significant treatment effects.

For data collection, the authors developed a mobile application called "ActiPain Tracker," designed for iOS and Android. This app allows patients to record their activities of daily living (ADL) using their smartphones, making data collection accessible and convenient for both clinical and home environments.

Datasets

The study utilized a combination of datasets:

  • Simulated Patient Data: The authors created a simulated dataset to mimic patient activity before and after treatment. This dataset included ADLs such as walking, sitting, and climbing stairs, collected from volunteers who also provided NRS pain values. Data was collected with the phone in two locations: the non-dominant hand and the same pant pocket.
  • Public Benchmark Datasets:
    • KU-HAR: An Open Dataset for Human Activity Recognition: Used for sit, upstairs, and walk activities.
  • IMU-based Human Activity Recognition Dataset: Used for activity recognition.

The paper also mentions ongoing real patient data collection with a chronic pain physician at Massachusetts General Hospital (MGH), though results from this are still pending.

Key Insights and Ideas

  • Objective Measurement of Functional Improvement: The most significant insight is the potential to move beyond subjective pain scales to objectively measure how treatments impact a patient's daily functional abilities.
  • Transformer Models for Subtle Behavioral Shifts: The paper demonstrates that transformer models, known for their ability to capture sequential dependencies, are effective at detecting subtle but meaningful changes in human activity patterns that may not be apparent through simple metrics.
  • Accessibility through Smartphones: Leveraging ubiquitous smartphone sensors makes this approach highly accessible, removing the need for expensive, specialized equipment and enabling continuous monitoring in real-world settings.
  • Personalized Treatment Evaluation: By training the model on each patient's pre-treatment data, DETECT creates a personalized baseline, allowing for the detection of individual behavioral shifts rather than relying on generic population-level changes.

Key Results

  • Simulated Data: When tested on simulated patient data, the DETECT framework showed significant differences in test accuracy compared to training accuracy. For example, four TES values exceeded the TES threshold, indicating significant treatment impact. The DETECT framework and NRS assessments were consistent in 87.50% of the trials.
  • Public Benchmark Data: The model achieved high accuracies on public datasets: 99.69% train accuracy and 98.74% test accuracy on KU-HAR, and 98.69% train accuracy and 95.06% test accuracy on the IMU dataset. These high accuracies suggest that the observed drops in accuracy on post-treatment data are indeed due to meaningful data shifts, not model flaws.

Limitations and Future Work

Limitations:

  • Simulated Data: The current findings are based on simulated data, which are approximations of real-world patient data. Direct clinical outcomes require further validation with real patient data.
  • Short Study Duration: The study's short duration prevented the analysis of long-term treatment impacts.
  • Limited Activity Types: The current study focused on a limited set of activities (sitting, walking, stair climbing), which may not capture the full spectrum of movements relevant to chronic pain patients.

Future Work:

  • Real-time Integration: Integrating the DETECT framework directly into the mobile app for real-time treatment assessment.
  • Diverse Data: Expanding the study with more diverse real-world patient data to improve generalizability.
  • Broader Activity Scope: Incorporating a wider range of activity types to enhance the framework's effectiveness.
  • Longer-term Monitoring: Collecting longer-term data to understand the sustained impact of treatments.

Summary updated

BibTeX
@misc{mao2025detect,
  author = {Yuanheng Mao and Lillian Yang and Stephen Yang and Ethan Shao and Zihan Li},
  title = {{DETECT: Data-Driven Evaluation of Treatments Enabled by Classification Transformers}},
  year = {2025},
  doi = {10.1109/icdmw69685.2025.00431},
}
Figure