Maintenance Notice

Due to necessary scheduled maintenance, the JMIR Publications website will be unavailable from Wednesday, July 01, 2020 at 8:00 PM to 10:00 PM EST. We apologize in advance for any inconvenience this may cause you.

Who will be affected?

Currently submitted to: JMIR Diabetes

Date Submitted: Jun 30, 2026

Warning: This is an author submission that is not peer-reviewed or edited. Preprints - unless they show as "accepted" - should not be relied on to guide clinical practice or health-related behavior and should not be reported in news media as established information.

Detecting Severe Hypoglycemia in Electronic Health Record Notes of Type 2 Diabetes Outpatients: A Hybrid Natural Language Processing Approach

  • Glenn T. Gobbel; 
  • Donald R. Miller; 
  • Richard Noriega; 
  • Sarah E. McDannold; 
  • Michael E. Matheny; 
  • Ann M. Borzecki

ABSTRACT

Background:

Optimal glycemic control is essential for limiting diabetes–related complications, but the risk of hypoglycemia constrains treatment intensification. Current hypoglycemia surveillance methods relying on diagnosis codes substantially underreport events, and improved methods for identifying hypoglycemia from electronic health records (EHRs) are needed.

Objective:

To develop and validate an artificial intelligence (AI) model that can use EHR clinical notes to retrospectively identify severe hypoglycemia events among outpatients with type 2 diabetes (T2D) presenting to the Emergency Department (ED) or requiring an Inpatient Admission (IP).

Methods:

Using Veterans Health Administration data, we identified a sample of T2D patients in 2019 and classified hypoglycemia via ICD-10 codes or outpatient glucose <70 mg/dL (Hypo+) versus controls (Hypo−). Text corpora included clinical notes near ED encounters (±24 hours) or admission (−12 to +24 hours). We created a hybrid classifier to identify hypoglycemic patients by combining rule-based feature extraction with random forest–based machine learning. A rule–based concept extraction module within the RapTAT natural language processing system generated 44 assertion-aware features. Random forest models were developed and trained using these features and leave-one-out cross-validation and then tested on held-out sets. We created one model for hypoglycemia during ED visits and a second for IP admissions with hypoglycemia. Feature importance was evaluated across both models, and performance was evaluated across different cohorts (2018 vs. 2019) and clinical contexts (presence of low blood glucose <70 mg/dL, hypoglycemia treatment).

Results:

When evaluated across all clinical contexts, the ED model achieved a normalized positive predictive value (PPVN) of 82%-88% and sensitivity of 88%-92%, with specificity of 88% (2018) and 80% (2019). Performance was highest in the context of documented low glucose and hypoglycemia treatment. The IP model performed better overall: PPVN 89%–94%, sensitivity 85%-93%, and specificity 93%-94%. Requiring ≥5 documents improved IP accuracy. Feature importance rankings correlated across models (r=0.74); top predictors included counts and ratios of low glucose phrases and document–level coverage of hypoglycemia concepts. Hypoglycemia cases skewed older, male, and had higher representation of African American patients.

Conclusions:

AI in the form of a hybrid classification model applied to unstructured EHR notes accurately identified severe hypoglycemia in outpatient T2D populations, outperforming historically reported diagnosis code–based sensitivity and specificity. Models were most effective for admission–related hypoglycemia and when corroborating glucose values and treatment were present. These tools enable scalable surveillance, that may inform safer diabetes management, and support quality improvement.


 Citation

Please cite as:

Gobbel GT, Miller DR, Noriega R, McDannold SE, Matheny ME, Borzecki AM

Detecting Severe Hypoglycemia in Electronic Health Record Notes of Type 2 Diabetes Outpatients: A Hybrid Natural Language Processing Approach

JMIR Preprints. 30/06/2026:105917

DOI: 10.2196/preprints.105917

URL: https://preprints.jmir.org/preprint/105917

Download PDF


Request queued. Please wait while the file is being generated. It may take some time.

© The authors. All rights reserved. This is a privileged document currently under peer-review/community review (or an accepted/rejected manuscript). Authors have provided JMIR Publications with an exclusive license to publish this preprint on it's website for review and ahead-of-print citation purposes only. While the final peer-reviewed paper may be licensed under a cc-by license on publication, at this stage authors and publisher expressively prohibit redistribution of this draft paper other than for review purposes.