TimeX: Phenotype Onset Extraction from Clinical Narratives
摘要
Disease phenotype onset is critical for timely and accurate diagnosis and clinical decision-making, yet it remains poorly characterized in the literature. Estimating phenotype onset using electronic health record (EHR) data holds promise but remains challenging. Researchers often resort to EHR documentation timestamps as proxies for phenotype onset, which can be inaccurate. Conventional natural language processing (NLP) approaches suffer from limited scalability and generalizability, and struggle to interpret implicit or vague temporal expressions. To address these gaps, we introduce TimeX, a novel open-source pipeline that leverages Llama-3.1, using instruction-based prompting for extracting phenotype onset from clinical narratives. TimeX employs a modular workflow comprising family history filtering, phenotype extraction, negation handling, and temporal information extraction to estimate phenotype onset. It yielded an average accuracy of 81.24% in timestamp extraction using 102 manually annotated clinical notes from the Columbia University Irving Medical Center, substantially outperforming all five baselines by at least 14.86%. A case study of four rare disease cohorts revealed that narrative-derived phenotype onset is more precise than that based on documentation timestamps. TimeX supports accurate and scalable phenotype onset extraction, with the potential to enable more precise disease trajectory characterization and timely disease diagnosis.