Back

Assessment of the Modified Rankin Scale in Electronic Health Records with a Fine-tuned Large Language Model

Silva, L.; Milani, M.; Bindra, S.; ikramuddin, S. S.; Tessmer, M.; Frederickson, K.; Datta, A.; Ergen, H.; Stangebye, A.; Cooper, D.; Kumar, K.; Yeung, J.; Lakshminarayan, K.; Streib, C.

2025-05-02 neurology
10.1101/2025.04.30.25326777 medRxiv
Show abstract

IntroductionThe modified Rankin scale (mRS) is an important metric in stroke research, often used as a primary outcome in clinical trials and observational studies. The mRS can be assessed retrospectively from electronic health records (EHR), though this process is labor-intensive and prone to inter-rater variability. Large language models (LLMs) have demonstrated potential in automating clinical text classification. We hypothesize that a fine-tuned LLM can analyze EHR text and classify mRS scores for clinical and research applications. MethodsWe performed a retrospective cohort study of patients admitted to a specialist stroke neurology service at a large academic hospital system between August 2020 and June 2023. Each patients medical record was reviewed at two time points: (1) hospital discharge and (2) approximately 90 days post-discharge. Two independent researchers assigned an mRS score at each time point. Two separate models were trained on EHR passages with corresponding mRS scores as labeled outcomes: (1) a multiclass model to classify all seven mRS scores and (2) a binary model to classify functional independence (mRS 0-2) versus non-independence (mRS 3-6). Four-fold cross-validation was conducted, using accuracy and Cohens kappa as model performance metrics. ResultsA total of 2,290 EHR passages with corresponding mRS scores were included in model training. The multiclass model--considering all seven scores of the mRS--attained an accuracy of 77% and a weighted Cohens Kappa of 0.92. Class-specific accuracy was highest for mRS 4 (90%) and lowest for mRS 2 (28%). The binary model--considering only functional independence vs non-independence --attained an accuracy of 92% and Cohens Kappa of 0.84. ConclusionOur findings demonstrate that LLMs can be successfully trained to determine mRS scores through EHR text analysis. With further advancements, fully automated LLMs could scale across large clinical datasets, enabling data-driven public health strategies and optimized resource allocation.

Matching journals

The top 5 journals account for 50% of the predicted probability mass.

50% of probability mass above

"Similar papers" are the closest papers from that journal in the model's embedding space. They show what the match is built on, but the ranking comes mostly from a classifier over the whole training set, not from these examples alone.