Development and evaluation of a text analytics algorithm for automated application of national COVID-19 shielding criteria in rheumatology patients

Meghna Jani, Ghada Alfattni, Maksim Belousov, Lynn Laidlaw, Yuanyuan Zhang, Michael Cheng, Karim Webb, Robyn Hamilton, Andrew S. Kanter, William G Dixon, Goran NenadićAnnals 2024

Abstract

An automated algorithm for risk stratification has several advantages including reducing clinician time for manual review to allow more time for direct care, improving efficiency and increasing transparency in individual patient communication. It has the potential to be adapted for future public health initiatives that require prompt automated review of hospital outpatient letters.

Introduction

At the onset of the COVID-19 pandemic, the UK government implemented "shielding" measures for extremely vulnerable individuals. For rheumatology patients, risk was determined by a complex interplay of age, specific comorbidities, and the use of immunosuppressive therapies. Much of this granular data—especially regarding specific drug dosages and historical treatment—is often trapped in unstructured outpatient letters rather than structured primary care databases. This forced rheumatologists to manually review thousands of letters to score patient risk, a process that was slow, labor-intensive, and lacked transparency. This study explores whether an automated text-mining approach could replicate this clinical decision-making process.

Methods

The researchers developed a multi-stage Natural Language Processing (NLP) pipeline to process rheumatology outpatient letters from Salford Royal Hospital (2013–2020). The pipeline consisted of:

  1. Diagnosis Extraction: Using the Intelligent Medical Objects (IMO) Concept Tagger to identify free-text diagnoses and map them to standardized SNOMED-CT codes.
  2. Medication Recognition: A custom tool called MedCore (Medication Concept Recognition) was developed using Named Entity Recognition (NER). This tool extracted drug names, doses, durations, and status (active vs. past).
  3. Risk Scoring: Extracted variables were processed by a logic-based algorithm to output a risk score based on the British Society for Rheumatology (BSR) shielding guidelines.
BSR Shielding Risk Factor Scoring Table
Definitions of Immunosuppressive Medications and Co-morbidities

Results

The study analyzed 803 patients, extracting 5,942 free-text diagnoses and 13,665 medication mentions. The automated algorithm's performance was compared against a "gold standard" of manual clinical reviews:

  • Specificity: 92.2%
  • Sensitivity: 80.3%
  • F1 Score: 0.81
  • Positive Likelihood Ratio: 10.3

The high specificity indicates the algorithm is excellent at correctly identifying patients who did not need to shield. The false negative rate (19.7%) was primarily due to the difficulty of correctly classifying medication status (active vs. past) from complex sentence structures.

Discussion and Conclusion

One of the primary challenges in clinical NLP is "negation and status detection"—distinguishing between a patient starting a drug, stopping it, or a drug being mentioned as a past failure. While the algorithm was not perfect, its high specificity suggests it can effectively "rule out" low-risk patients, allowing clinicians to focus manual review on complex cases.

Discrepancies between the algorithm and clinicians often reflected subjective interpretations of the BSR guidelines rather than simple machine errors. Future work should focus on improving medication misclassification and testing the algorithm across different institutions with varying dictation styles. This framework provides a template for prompt automated review of hospital records during future public health crises.

Summary updated

BibTeX
@article{jani2024development,
  author = {Meghna Jani and Ghada Alfattni and Maksim Belousov and Lynn Laidlaw and Yuanyuan Zhang and Michael Cheng and Karim Webb and Robyn Hamilton and Andrew S. Kanter and William G Dixon and Goran Nenadić},
  title = {{Development and evaluation of a text analytics algorithm for automated application of national COVID-19 shielding criteria in rheumatology patients}},
  journal = {Annals},
  year = {2024},
  doi = {10.1136/ard-2024-225544},
}
Figure