Abstract
Common Variable Immunodeficiency (CVID) is a common human inborn error of immunity characterized by antibody deficiency and impaired B-cell responses. Despite its prevalence, over half of patients lack a monogenic variant, and the absence of definitive diagnostic tests leads to a "diagnostic odyssey" of 5 to 15 years. We present PheNet, an algorithm that identifies CVID patients from electronic health record (EHR) data by learning phenotypic signatures. Using a curated cohort of 197 CVID patients from UCLA Health, PheNet achieved superior accuracy, detecting 57% of cases within the top 10% of ranked individuals. Retrospective analysis showed that 64% of patients could have been identified more than 8 months earlier than their clinical diagnosis. Validation on a discovery dataset of ~880,000 patients resulted in an immune specialist confirming 74% of the top 100 ranked individuals as highly probable CVID cases.
Introduction: The Diagnostic Odyssey of CVID
Common Variable Immunodeficiency (CVID) is often described as a "chameleon" disease. As the most common primary immunodeficiency, it presents a diverse array of symptoms across multiple medical specialties, making it notoriously difficult to diagnose. Patients frequently suffer from recurrent pneumonia, chronic enteritis, or low platelet counts, seeing various specialists who may fail to connect these disparate symptoms to an underlying immune deficiency.
This fragmentation leads to a diagnostic delay of 5 to 15 years, resulting in irreversible organ damage and increased mortality. PheNet was developed to address this by automating the identification of these "hidden" patients within massive hospital databases using their unique phenotypic signatures.
Methodology: Building the PheNet Framework
The researchers developed PheNet as a supervised learning framework to compute a CVID likelihood score for any patient in an EHR system.
Feature Engineering and Lab Integration
Unlike models that rely solely on billing codes, PheNet utilizes:
- Phecodes: Validated groupings of ICD diagnosis codes representing clinically meaningful conditions.
- Signature Building: A combination of 34 "textbook" phecodes from the OMIM database and 10 "enriched" phecodes discovered through analysis of known CVID cases.
- Laboratory Values: Discretized Immunoglobulin G (IgG) values (normal, abnormal, or missing) are integrated to enhance predictive power.
Model Training and Control Matching
The model was trained on a curated cohort of 197 confirmed CVID cases. To ensure robustness, these cases were matched with 1,106 controls based on sex, race/ethnicity, age, and EHR length.
The authors selected marginal logistic regression for the final algorithm due to its high performance (AUC-ROC of 0.95) and clinical interpretability, allowing doctors to understand the specific symptoms driving a patient's risk score.
Results: Identifying the Undiagnosed
PheNet's ability to aggregate "weak signals" from different specialties into a strong EHR signature led to significant improvements over existing methods.
Performance Benchmarks
PheNet identified 57% of CVID cases within the top 10% of ranked individuals, significantly outperforming previous phenotype risk scores like PheRS (37%) and the CMA-score (23%).
Clinical Validation and Early Detection
In a blinded clinical chart review of the top 100 patients flagged from a discovery set of 880,000 records, an immunologist confirmed that 74% were highly probable to have CVID. Furthermore, retrospective analysis indicated that the model could have flagged these patients an average of 8 months before their actual clinical diagnosis, with some signatures visible years in advance.
Generalizability
The model's effectiveness was validated across five University of California medical centers (UCLA, UCSF, UCD, UCSD, and UCI), encompassing over 4.9 million patient records. Despite institutional differences in coding practices, the CVID signature remained consistent, suggesting PheNet is ready for broad clinical deployment.
Discussion and Future Directions
While PheNet shows great promise, challenges remain. Data fragmentation—where a patient's medical history is split across different health systems—can obscure the full phenotypic signature. Future iterations of the model could incorporate temporal data, such as the frequency and order of infections, to further increase specificity. Additionally, the authors aim to link these high-risk EHR signatures with genomic sequencing to uncover new monogenic variants associated with CVID, potentially ending the diagnostic odyssey for many more patients.
Summary updated