Agentic Pipeline for Large-Scale Clinical Data Queries in Enterprise Electronic Health Records

Using electronic health record (EHR) data to answer clinical research questions is challenging. It requires understanding the research question, finding relevant information across different sources, and combining that information to produce meaningful results. We developed an agentic large language model (LLM) pipeline that decomposes investigator-authored requests into source-specific tasks, generates and executes SQL on EHR, integrates structured and unstructured EHR evidence, and applies study-specific clinical note adjudication. We evaluated this workflow against data analyst–identified cohorts across 50 pediatric orthopedic clinical data query requests. Of these, 43 were included in manual-review-adjusted performance analyses. The median adjusted positive predictive value, sensitivity among patients identified by either approach, and corresponding F1 score were 0.93 (95% CI, 0.88–0.98), 0.92 (95% CI, 0.90–0.95) and 0.90 (95% CI, 0.87–0.94), respectively. These findings support the feasibility of translating natural-language research intent into executable, autonomous multi-stage EHR workflows.

Authors

Institutions

Publication Details

Journal
medRxiv
Published
2026-11-06
DOI
https://doi.org/10.64898/2026.11.05.26367378
Primary Topic
Machine Learning in Healthcare
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
preprint

Agentic Pipeline for Large-Scale Clinical Data Queries in Enterprise Electronic Health Records

Ashton Williamson, Nazgol Tavabi, Ata M. Kiapour, Nishita Kalepalli et al.
medRxiv
Machine Learning in Healthcare
preprint

Agentic Pipeline for Large-Scale Clinical Data Queries in Enterprise Electronic Health Records

Ashton Williamson, Nazgol Tavabi, Ata M. Kiapour, Nishita Kalepalli, Kshitij Pawar, Anvita Kalepalli, Mallory Blackmon
preprint en

Abstract

Using electronic health record (EHR) data to answer clinical research questions is challenging. It requires understanding the research question, finding relevant information across different sources, and combining that information to produce meaningful results. We developed an agentic large language model (LLM) pipeline that decomposes investigator-authored requests into source-specific tasks, generates and executes SQL on EHR, integrates structured and unstructured EHR evidence, and applies study-specific clinical note adjudication. We evaluated this workflow against data analyst–identified cohorts across 50 pediatric orthopedic clinical data query requests. Of these, 43 were included in manual-review-adjusted performance analyses. The median adjusted positive predictive value, sensitivity among patients identified by either approach, and corresponding F1 score were 0.93 (95% CI, 0.88–0.98), 0.92 (95% CI, 0.90–0.95) and 0.90 (95% CI, 0.87–0.94), respectively. These findings support the feasibility of translating natural-language research intent into executable, autonomous multi-stage EHR workflows.

medRxiv
Boston Children's Hospital (US), Harvard University (US)
Machine Learning in Healthcare
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon