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

A Unified Review of Deep Learning for Automated Medical Coding

Shaoxiong Ji, Wei Sun, Xiaobo Li, Hang Dong, Ara Taalas, Yijia Zhang, Honghan Wu, Esa Pitkänen, Pekka Marttinen · DOI

TL;DR

This paper provides a comprehensive, unified review of deep learning techniques for automated medical coding, organizing a fragmented literature into a cohesive encoder-decoder framework. By decomposing models into encoders, deep connection mechanisms, decoders, and auxiliary data usage, the authors offer a clear roadmap for navigating the challenges of high-dimensional, imbalanced clinical text classification.

What Problem Does This Paper Address?

Automated medical coding is the process of assigning standardized medical codes (such as ICD-9 or ICD-10) to unstructured clinical notes written by healthcare professionals. These codes are vital for hospital operations, billing, and public health tracking. However, manual coding is expensive, slow, and prone to human error.

While deep learning (DL) and natural language processing (NLP) have drastically improved automated coding, the research landscape has become highly fragmented. Different teams use wildly different neural architectures, making it hard to compare methods or understand which components actually drive performance.

The task itself is uniquely difficult due to three core challenges:

  1. Noisy and Lengthy Clinical Notes: Documents can span thousands of words, filled with abbreviations, misspellings, and non-standard jargon.
  2. High-Dimensional Code Spaces: Ontologies like ICD-10 contain over 68,000 codes, turning this into an extreme multi-label classification problem.
  3. Severe Class Imbalance: A few common conditions appear in almost every document, while thousands of rare diseases form a massive "long tail" with very few training examples.
Fig. 1. A medical coding model maps an example clinical note to the corresponding ICD procedure and diagnosis codes.
Fig. 2. The distribution of ICD codes in the MIMIC-III dataset curated by Mullenbach et al. [131].

Methods

To make sense of the literature, the authors propose a Unified Encoder-Decoder Framework that breaks any medical coding model down into four fundamental building blocks:

Fig. 3. An illustration of the unified encoder-decoder framework for automated medical coding
  1. Encoder Modules: Responsible for text feature extraction. The review categorizes these into Recurrent Neural Networks (RNNs), Convolutional Neural Networks (CNNs), Transformers/Attention, Graph Encoders (which capture structural relationships), and Hierarchical Encoders (which model the token-sentence-document layout).
  2. Deep Connections: Mechanisms used to build deep architectures without losing information or suffering from vanishing gradients. These include simple stacking, Residual Networks, and Embedding Injection (re-introducing original word embeddings at intermediate layers).
  3. Decoder Modules: Transform hidden representations into code probabilities. Beyond standard linear layers, this includes Label-wise Attention Networks (LAN), Hierarchical Decoders (which mirror the tree structure of the medical ontology), Multitask Decoders, and Few-shot/Zero-shot decoders.
  4. Auxiliary Data: Incorporating external knowledge sources—such as Wikipedia articles, official code descriptions, clinical ontologies (UMLS, SNOMED CT), and structured patient chart data—to boost feature learning.
Categorization of building blocks under the unified framework.

Datasets

The review outlines the primary benchmarks used in the field:

  • MIMIC-II & MIMIC-III: The undisputed de facto standards for medical coding research, consisting of de-identified intensive care unit (ICU) data.
  • MIMIC-IV-Note: The latest iteration, serving as a modern testbed for long-text clinical models.
  • CodiEsp: A Spanish-language clinical dataset providing a benchmark for non-English and cross-lingual medical coding.
  • Private Datasets: The authors note that many studies rely on in-house datasets from hospitals in China, Denmark, France, and the US, which limits reproducibility due to strict patient privacy regulations.

Key Insights and Ideas

  • Label-Wise Attention is Crucial: Standard attention mechanisms often get overwhelmed by the sheer length of clinical notes. Label-wise Attention Networks (LAN) solve this by calculating a unique attention map for each individual medical code, allowing the model to scan the document specifically for evidence of that code.
  • Transformers Aren't an Automatic Win: While Transformers dominate general NLP, vanilla BERT models struggle with medical coding because of their 512-token limit. Long-context variants (like Longformer and BigBird) or hierarchical architectures are required to handle lengthy discharge summaries effectively.
  • Ontology Structure Tames the Long Tail: Models that inject the hierarchical tree structure of ICD codes into their decoders perform significantly better on rare, few-shot codes because they can share representation knowledge with well-mapped parent codes.

Key Results

The paper compiles a comprehensive performance comparison of representative models on the MIMIC-III full dataset.

Top-performing models (such as MSMN, RAC, and MDBERT) achieve impressive Micro AUC-ROC scores of up to 99.2% and Macro AUC-ROC scores around 95.0%. However, the Macro F1 scores remain low across all models (ranging from 3.8% to 12.7%). This massive discrepancy highlights that while models are excellent at identifying common codes (driving up Micro scores), they still struggle significantly with the rare, long-tail codes that dominate the Macro F1 metric.

Limitations and Future Work

The authors identify several critical gaps that future research must address:

  • Scalability: Capturing long-term dependencies in massive documents without incurring the quadratic computational costs of standard self-attention.
  • Multimodal Fusion: Clinical coders don't just read text; they look at lab charts and medical imaging. Future deep learning models need to better integrate multimodal EHR data.
  • Generative Coding & LLMs: Transitioning from classification to autoregressive generation using Large Language Models (LLMs) like ChatGPT or BioGPT. While promising, researchers must find ways to eliminate "hallucinations" and enforce strict clinical vocabulary constraints.
  • Data Shift & Updates: Medical guidelines change frequently (e.g., transitioning from ICD-9 to ICD-10, or adding new pandemic codes). Models must support continual or zero-shot learning to adapt without needing complete retraining.

Summary updated

BibTeX
@article{ji2022unified,
  author = {Shaoxiong Ji and Wei Sun and Xiaobo Li and Hang Dong and Ara Taalas and Yijia Zhang and Honghan Wu and Esa Pitkänen and Pekka Marttinen},
  title = {{A Unified Review of Deep Learning for Automated Medical Coding}},
  journal = {ACM Computing Surveys},
  year = {2022},
  doi = {10.1145/3664615},
}
Figure