Synthetic Clinical Notes for Rare ICD Codes: A Data-Centric Framework for Long-Tail Medical Coding
Organizations: Northwestern University · Dartmouth University
Abstract
Automatic ICD coding from clinical text is a critical task in medical NLP but remains hindered by the extreme long-tail distribution of diagnostic codes. Thousands of rare and zero-shot ICD codes are severely underrepresented in datasets like MIMIC-III, leading to low macro-F1 scores. In this work, we propose a data-centric framework that generates high-quality synthetic discharge summaries to mitigate this imbalance. Our method constructs realistic multi-label code sets anchored on rare codes by leveraging real-world co-occurrence patterns, ICD descriptions, synonyms, taxonomy, and similar clinical notes. Using these structured prompts, we generate 90,000 synthetic notes covering 7,902 ICD codes, significantly expanding the training distribution. We fine-tune two state-of-the-art transformer-based models, PLM-ICD and GKI-ICD, on both the original and extended datasets. Experiments show that our approach modestly improves macro-F1 while maintaining strong micro-F1, outperforming prior SOTA. While the gain may seem marginal relative to the computational cost, our results demonstrate that carefully crafted synthetic data can enhance equity in long-tail ICD code prediction.
Figures & tables
| Model | AUC-Micro | AUC-Macro | F1-Micro | F1-Macro | P@8 | P@15 |
|---|---|---|---|---|---|---|
| CNN | 96.9 | 80.6 | 41.9 | 4.2 | 58.1 | 48.8 |
| Bi-GRU | 97.1 | 82.2 | 41.7 | 3.8 | 58.5 | 44.5 |
| CAML | 98.6 | 89.5 | 53.9 | 8.8 | 70.9 | 56.1 |
| MultiResCNN | 98.6 | 91.0 | 55.2 | 9.2 | 73.4 | 58.4 |
| LAAT | 98.8 | 91.9 | 57.5 | 9.9 | 74.5 | 59.1 |
| PLM-ICD | 98.9 | 92.6 | 59.8 | 10.4 | 77.1 | 61.3 |
Automated Medical Coding
Automated medical coding uses clinical records and coding rules to assign standardized diagnosis and procedure codes for billing, care, and research.
See all 29 papers