Toward Automated Detection of Documentation Inconsistencies in Electronic Health Records
A two-stage LLM pipeline using Gemini 2.5 Pro and Gemini 2.5 Flash was applied to detect documentation inconsistencies in 3,000 MIMIC-IV discharge summaries. The pipeline identified 3,460 candidate inconsistencies affecting 69.7% of admissions across domains like demographics, allergies, diagnoses, medications, and lab results. Expert review revealed recurring failure modes due to lack of temporal reasoning, evolving-diagnosis context, and outpatient-prescribing knowledge in general-domain LLMs.
Analysis
TL;DR
- A two-stage LLM pipeline using Gemini 2.5 Pro and Gemini 2.5 Flash was applied to detect documentation inconsistencies in 3,000 MIMIC-IV discharge summaries.
- The pipeline identified 3,460 candidate inconsistencies affecting 69.7% of admissions across domains like demographics, allergies, diagnoses, medications, and lab results.
- Expert review revealed recurring failure modes due to lack of temporal reasoning, evolving-diagnosis context, and outpatient-prescribing knowledge in general-domain LLMs.
- The study proposes a graded ontology for inconsistency classification (from strict contradiction to ambiguity) with a schema based on category, section, domain, and inconsistency axis.
- This work establishes a methodological framework for large-scale EHR inconsistency detection but highlights the need for domain-specific enhancements to improve reliability.
Why It Matters
This research is critical for AI practitioners and healthcare informatics teams aiming to deploy LLMs in clinical settings, as it reveals both the potential and limitations of general-purpose models in detecting subtle documentation errors that could impact patient safety. The findings underscore the necessity of integrating domain-specific reasoning capabilities into healthcare AI systems to reduce false positives/natives and ensure trustworthy automated quality assurance tools. Additionally, the proposed ontology provides a structured approach for evaluating and improving consistency-checking algorithms in electronic health records.
Technical Details
- Pipeline Architecture: Two-stage process: (1) Open-ended candidate identification using Gemini 2.5 Pro to flag potential inconsistencies; (2) Context-grounded verification via Gemini 2.5 Flash to assess flagged pairs against surrounding clinical context.
- Dataset: 3,000 randomly sampled discharge summaries from MIMIC-IV-Note, a widely used public dataset containing de-identified health data from ICU patients at Beth Israel Deaconess Medical Center.
- Inconsistency Domains Covered: Demographics, allergies, procedures, diagnoses, laboratory values, medications, and care planning—each representing high-stakes areas where discrepancies may compromise clinical decision-making or regulatory compliance.
- Failure Modes Identified: Temporal reasoning gaps (e.g., failing to account for changes over time), insufficient understanding of evolving diagnostic criteria during hospitalization, and unawareness of standard outpatient prescribing practices not reflected in inpatient notes.
- Ontology Proposal: A hierarchical classification system ranging from “strict contradiction” (clear factual conflict) through intermediate levels like “partial mismatch” to “ambiguity” (insufficient information to determine truth value), annotated with metadata fields including source section, clinical domain, and type of inconsistency axis (e.g., value mismatch, missing entity).
Industry Insight
Healthcare organizations investing in AI-driven documentation quality control should prioritize hybrid approaches combining general LLMs with specialized modules trained on longitudinal patient trajectories and domain-specific guidelines to mitigate current blind spots. Future development efforts must focus on embedding temporal awareness and contextual adaptability into verification stages to handle dynamic clinical narratives effectively. Furthermore, adopting standardized ontologies for inconsistency categorization—as proposed here—will enable cross-institutional benchmarking, facilitate iterative model improvement, and support regulatory alignment with emerging standards for safe AI deployment in medicine.
Disclaimer: The above content is generated by AI and is for reference only.