Doctor AI: Predicting Clinical Events via Recurrent Neural Networks

Keywords
recurrent neural networks
electronic health records
clinical prediction
machine learning
differential diagnosis
deep learning
GRU
transfer learning

Comprehensive Overview

Presented at the 2016 Machine Learning for Healthcare conference, this study asked whether a computer model trained on patients' past medical records could accurately anticipate what would happen at their next doctor's visit, including likely diagnoses, medications, and even how soon that visit would occur. Researchers built "Doctor AI," a recurrent neural network designed to process the sequence of diagnosis, medication, and procedure codes in a patient's electronic health record over time, treating each visit as a snapshot that updates the model's understanding of the patient's evolving health status. The model was trained and tested on de-identified records from 263,706 primary care patients at a large US health system, averaging nearly 55 visits per person over up to 8 years, with codes grouped into 1,183 diagnosis categories and 595 medication categories to keep predictions clinically meaningful. The team also tested whether a model trained on this large dataset could be transferred to a smaller, different hospital system to boost predictions there. The topline result was that Doctor AI substantially outperformed conventional prediction methods at forecasting a patient's future diagnoses and medications, correctly capturing up to 79% of true diagnoses within its top 30 predictions.

Outcomes and Implications

The single most important finding was that Doctor AI substantially outperformed all baseline approaches, achieving 79.58% recall for diagnosis prediction and 72.48% recall for the combined task of predicting diagnoses, medications, and visit timing together within its top 30 guesses, compared with just 66% for a simple frequency-based baseline and 26.25% for a naive model assuming the next visit would resemble the last one. Performance improved further, and grew more consistent, the longer a patient's medical history extended, since the network could build an increasingly refined picture of that individual's health trajectory. Testing the model directly, the researchers found it generated sharp, confident predictions for common conditions like hypertension but broader, more exploratory predictions for rare diagnoses like Klinefelter's syndrome, mirroring how physician confidence naturally varies with disease prevalence. Critically, when the model was pretrained on the large health system's data and adapted to a much smaller, independent hospital dataset, its accuracy improved by over 10 percentage points compared with training on the small dataset alone, demonstrating that knowledge learned at one institution can transfer meaningfully to another with limited data. A blinded medical expert review further confirmed Doctor AI's predictions were clinically plausible and meaningfully related to patients' true diagnoses. The authors conclude that recurrent neural networks can learn rich, generalizable patient representations from routine EHR data to support differential diagnosis, though they caution that mimicking only average physician behavior has real limits, and future systems should aim to outperform, not just replicate, typical clinical judgment.

OAM LogoOpenAccess Medicine

Centralizing medical knowledge through open access research, transparent peer review, and collaborative scientific inquiry.

© 2026 OpenAccess Medicine. All rights reserved.

Connect

OPEN ACCESS • PEER REVIEWED • EVIDENCE BASED
LIVE RESEARCH FEED