NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

CoRelation: Boosting Automatic ICD Coding through Contextualized Code Relation Learning

Junyu Luo, Xiaochen Wang, Jiaqi Wang, Aofei Chang, Yaqing Wang, Fenglong Ma

Abstract

Automatic International Classification of Diseases (ICD) coding plays a crucial role in the extraction of relevant information from clinical notes for proper recording and billing. One of the most important directions for boosting the performance of automatic ICD coding is modeling ICD code relations. However, current methods insufficiently model the intricate relationships among ICD codes and often overlook the importance of context in clinical notes. In this paper, we propose a novel approach, a contextualized and flexible framework, to enhance the learning of ICD code representations. Our approach, unlike existing methods, employs a dependent learning paradigm that considers the context of clinical notes in modeling all possible code relations. We evaluate our approach on six public ICD coding datasets and the experimental results demonstrate the effectiveness of our approach compared to state-of-the-art baselines.

Introduction

Assigning International Classification of Diseases (ICD) codes to clinical notes is a high-stakes task essential for hospital billing and record-keeping. However, manual coding is labor-intensive and error-prone. While automated systems have been developed, they often struggle with the complexity of medical relationships.

Most existing models treat code relationships as "static," relying on fixed ontologies or co-occurrence graphs. However, medical reality is contextual; two diseases might be related in one patient's case but mutually exclusive in another. Current models often ignore this clinical context, leading to rigid predictions. CoRelation addresses this by employing a "dependent learning paradigm" that learns how relationships between medical codes shift based on the specific context of a clinical note.

Methodology

The CoRelation framework significantly improves automatic ICD coding by moving beyond static medical code hierarchies. The architecture consists of four main stages:

  1. Contextualized Code Embedding: Rather than using a single label, the model examines multiple synonyms for each ICD code. It utilizes an attention mechanism to "read" the clinical note through the lens of these synonyms, creating a document-specific representation.
  2. Contextualized Relation Learning: This core innovation builds a dynamic bipartite graph for every specific note. To maintain computational feasibility, the authors employ Major Code Substitution (grouping specific codes into broader categories) and Top-K Selection (focusing on the most likely code candidates for a given note). A Graph Transformer then updates embeddings based on these note-specific relationships.
  3. Self-adaptive Aggregation: A gating mechanism determines the optimal balance between "direct" predictions and "relation-enhanced" predictions for each code.
  4. Selective Training Strategy: To manage the massive label space (up to 26,000+ codes), the model performs backpropagation only on the most relevant codes, reducing GPU memory requirements from approximately 72.76 GB to 9.15 GB.
The CoRelation framework architecture, illustrating the multi-stage process from clinical note encoding to final code prediction.

Experimental Setup

The model was evaluated on six public ICD coding datasets derived from the MIMIC database, representing the gold standard in the field:

  • MIMIC-III: Includes both the "Top-50" frequent codes and the "Full" set (8,922 codes).
  • MIMIC-IV (ICD-9): Includes both the "Top-50" and "Full" set (11,331 codes).
  • MIMIC-IV (ICD-10): Includes both the "Top-50" and "Full" set (26,096 codes).

Results and Discussion

CoRelation outperformed almost all non-Pre-trained Language Model (non-PLM) baselines and rivaled or exceeded much larger PLM-based models. On the MIMIC-III-Full dataset, it achieved a Macro AUC of 93.3 and a Micro AUC of 95.1. The gains in Precision@K were particularly notable, suggesting the relation-learning module is highly effective at filtering out high-probability false positives.

Performance comparison of CoRelation against state-of-the-art PLM and non-PLM baselines on the MIMIC-III-Full dataset.

Beyond raw performance, CoRelation offers significant architectural advantages. It achieves state-of-the-art results with roughly 22 million parameters, compared to the 120 million+ parameters typical of PLM-based architectures. This efficiency makes it far more practical for deployment in resource-constrained hospital environments. Furthermore, the model provides explainability by identifying "Type 1" (similar codes) and "Type 2" (associated codes) relationships, allowing it to justify predictions based on recognized disease families within the text.

Conclusion

CoRelation demonstrates that contextualizing code relationships is vital for accurate ICD coding. By allowing the graph structure to change based on the clinical note, the model mimics human reasoning more closely than static methods. While the model currently relies on an initial "Top-K" selection pass, future work may explore even more flexible graph structures or integration with larger foundation models to further scale performance.

Summary updated

BibTeX
@inproceedings{luo2024corelation,
  author = {Junyu Luo and Xiaochen Wang and Jiaqi Wang and Aofei Chang and Yaqing Wang and Fenglong Ma},
  title = {{CoRelation: Boosting Automatic ICD Coding through Contextualized Code Relation Learning}},
  booktitle = {International Conference on Computational Linguistics},
  year = {2024},
  url = {https://openreview.net/forum?id=dlVBniZmKq},
}
Figure