Self-Supervised Adversarial Distribution Regularization for Medication Recommendation

Yanda Wang, Weitong Chen, Dechang Pi, Lin Yue, Sen Wang, Miao Xu

Abstract

Medication recommendation systems are critical for assisting clinicians in prescribing effective drug combinations. However, ensuring patient safety by minimizing Drug-Drug Interactions (DDI) remains a significant challenge, often requiring complex external knowledge bases. We present SARMR (Self-Supervised Adversarial Distribution Regularization Model), a novel framework that improves recommendation safety without external dependencies. By employing a self-supervised adversarial approach, SARMR shapes patient representations toward a safe distribution derived from existing clinical records. Experimental results on the MIMIC-III dataset demonstrate that SARMR not only outperforms state-of-the-art models in accuracy but is also the only model to achieve a net reduction in DDI rates compared to ground truth clinical data.

Introduction

Modern healthcare relies heavily on Electronic Health Records (EHRs) to inform clinical decisions. Medication recommendation systems aim to automate the suggestion of drug combinations based on a patient's diagnosis and procedure history. Despite their potential, two major hurdles persist in the field. First, Safety (DDI): many models prioritize accuracy (matching historical prescriptions) over safety, potentially recommending fatal drug combinations. While some models integrate external DDI knowledge graphs, these are often difficult to maintain and can introduce external biases. Second, Distribution Mismatch: patients exhibit varying DDI risks. Treating high-risk and low-risk patients as a single cohort during training forces models to generalize across conflicting distributions, leading to suboptimal performance and unsafe recommendations.

The SARMR Framework

SARMR addresses these challenges through a multi-component architecture designed to capture clinical reasoning while enforcing safety constraints through distribution matching.

The architecture of SARMR, illustrating the Encoder, Key-Value Memory Network, and the Adversarial Regularization components.

1. Encoder and Memory Network

The model utilizes dual Gated Recurrent Units (GRUs) to process diagnosis and procedure codes. To capture the longitudinal "reasoning" inherent in clinical practice, SARMR employs a Key-Value Memory Neural Network (MemNN). This component performs "multi-hop" reading, allowing the model to look back at historical admissions to find relevant context for the current visit, effectively understanding the patient's treatment trajectory.

2. Graph Convolutional Network (GCN)

To ensure medication embeddings reflect clinical relationships, a GCN processes a drug-drug co-occurrence graph. This ensures that the latent representations of drugs are informed by how they are typically prescribed together in practice.

3. Self-Supervised Adversarial Regularization

The core innovation of SARMR is its approach to safety. Rather than relying on an external database, the model identifies a "safe" subset of records within the raw EHR data (defined by a DDI rate threshold $D_{rec}$). It fits a Gaussian distribution to these safe patient representations. During training, a Generative Adversarial Network (GAN) structure is used: the encoder acts as a generator attempting to make all patient representations indistinguishable from the "safe" distribution, while a discriminator attempts to differentiate them. This "shapes" the latent space, naturally nudging the model toward safer drug combinations.

Experimental Evaluation

The model was evaluated using the MIMIC-III v1.4 dataset, a benchmark containing de-identified data from over 40,000 critical care patients. The study focused on a cohort of 6,350 patients with at least two admissions, involving 1,960 diagnosis codes, 1,432 procedure codes, and 153 medication types. Evaluation metrics included accuracy (F1 score, Jaccard Similarity) and safety (DDI rate change relative to ground truth).

Results and Discussion

SARMR demonstrated superior performance across all primary metrics compared to baselines such as Leap, RETAIN, DMNC, and GAMENet. Notably, SARMR achieved the highest F1 score (0.6608) and Jaccard Similarity (0.5039).

DDI rate density plots comparing SARMR against various baseline models (a-f), showing SARMR's closer alignment with safer (lower) DDI distributions.

In terms of safety, SARMR was the only model to achieve a negative DDI change (-2.72%), indicating it actively reduced the interaction rate compared to the original clinical records. In contrast, existing models like RETAIN and Leap increased the DDI rate by 10.43% and 7.80%, respectively. This suggests that by treating safety as a distribution matching problem rather than a hard constraint or penalty term, the model more effectively navigates the trade-off between accuracy and safety.

Conclusion and Future Work

SARMR represents a significant step forward in safe medication recommendation by leveraging self-supervision to define safety. By avoiding the need for external knowledge bases, it offers a more streamlined and potentially more accurate reflection of clinical safety. Future work will explore adaptive reasoning steps in the memory network to better handle varying patient histories and test the model's robustness across different hospital systems with diverse prescribing cultures.

Summary updated

BibTeX
@inproceedings{wang2021self,
  author = {Yanda Wang and Weitong Chen and Dechang Pi and Lin Yue and Sen Wang and Miao Xu},
  title = {{Self-Supervised Adversarial Distribution Regularization for Medication Recommendation}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {2021},
  doi = {10.24963/ijcai.2021/431},
}
Figure