SafeDrug: A Benchmark Dataset for Safety-Critical Pharmacological Reasoning in LLMs

Tengfei Ma, Yushan Yang, Hou Jiahao, Yujie Chen, Guanghui Ye, Xuanbai Ren, Yiping Liu, Bosheng Song, Xiangxiang ZengNeurIPS 2026 Evaluations and Datasets Track Poster 2026

TL;DR

Large language models (LLMs) can ace medical multiple-choice exams, but can they actually reason about drug safety in the real world? SafeDrug is a massive new benchmark (1.9 million instances) designed to test whether LLMs truly understand pharmacological mechanisms, multi-drug interactions, and patient-specific risks—or if they are just memorizing statistical correlations. Spoiler: they are great at guessing what might happen, but surprisingly bad at explaining why.

What Problem Does This Paper Address?

In clinical practice, drug safety isn't a simple trivia question. Assessing whether a medication is safe requires multi-step reasoning: you have to consider drug properties, biological pathways, clinical evidence, and who is actually taking the pill (a child, an adult, or an older adult). Add polypharmacy—patients taking 3, 5, or even 10 drugs at once—and the complexity explodes.

Existing biomedical benchmarks (like MedQA, PubMedQA, or DDI-Ben) mostly test single-step question answering or basic classification. They don't check if a model understands the underlying pharmacological mechanism, whether it can ground its answer in real literature, or if its predictions hold up across different age groups. Without testing those capabilities, we can't tell if an LLM is genuinely reasoning or just relying on superficial patterns in its training data.

Methods

The authors built a hierarchical evaluation framework that moves from surface-level pattern matching to deep, multi-step reasoning:

Figure 1: SafeDrug is a benchmark for evaluating safety-critical pharmacological reasoning in large language models. It covers a hierarchy of tasks from prediction to multi-step reasoning (a), integrates heterogeneous ADE/DDI data with population awareness into a unified QA format (d), and evaluates diverse LLMs using multiple metrics for both accuracy and reasoning quality (b–c). The pipeline standardizes data, performs model inference, and conducts multi-dimensional evaluation (e).
  1. Classification Tasks: Basic outcome prediction (identifying potential adverse drug events or interactions) and risk assessment (estimating severity or likelihood).
  2. Reasoning Tasks:
  3. Evidence Grounding: Selecting and generating supporting literature for a prediction.
  4. Mechanistic Reasoning: Explaining drug effects via biological or metabolic pathways.
  5. Compositional Reasoning: Predicting outcomes and risks when 3 to 10 drugs are combined.
  6. Drug Replacement: Suggesting safer alternatives.

To keep things fair, the authors evaluated nine representative LLMs—four open-weight (Qwen2.5-3B/7B, LLaMA-3.1-8B, LLaMA-3.2-3B) and five proprietary/frontier models (DeepSeek-V3, GPT-4o-mini, Gemini-2.5-Flash, Qwen3-235B-A22B, GPT-5-mini)—in a zero-shot setting with deterministic decoding ($T=0$). They also tested newer frontier models (including GPT-5.6-Sol, Kimi-K3, and DeepSeek-V4-Pro) on population-specific tasks. Because drug safety tasks range from binary choices to free-form explanations, they used a mix of Exact Match, Macro-F1, Set-F1, ROUGE, BLEU, and LLM-as-a-judge metrics.

Datasets

SafeDrug unifies seven heterogeneous pharmacological datasets into a single reasoning-oriented QA format:

  • Single-drug Adverse Drug Events (ADEs): SIDER, OFFSIDES, CT-ADE, and pediatric-specific resources.
  • Multi-drug Interactions (DDIs): DrugBank, HODDI, and DDInter2.0.
  • Literature Evidence: Roughly 33,000 curated biomedical papers from DDInter2.0, processed using DeepSeek-V3.2 to extract mechanisms and supporting evidence.

The benchmark is split into two complementary subsets:

  • SafeDrug-large: ~1.9 million instances across 5 task dimensions (8:1:1 train/val/test split) for broad-scale evaluation.
  • SafeDrug-small: 2,554 high-confidence, human-verified instances (sampled from 3,000 candidates) for precise evaluation of intermediate reasoning steps.
Figure 2: Data statistics of SafeDrug. (a) Task distribution across predic- tion, risk assessment, and reasoning dimensions. (b) Population-aware data distribution over child, adult, and older adult groups. (c) Distribution of multi-drug interactions with varying numbers of drugs, reflecting polyphar- macy complexity.

Key Insights and Ideas

  • Correlation vs. Understanding: LLMs are quite good at outcome-level prediction (e.g., spotting that two drugs interact), but they struggle badly with mechanistic reasoning and severity assessment. They know what happens, not why.
  • The "Convincing Hallucination" Gap: On evidence-generation tasks, LLMs scored over 0.90 on LLM-as-a-judge pass rates—meaning their explanations sound plausible and coherent. Yet on evidence selection, their Set-F1 scores were only 0.22 to 0.55. They can talk the talk, but they frequently omit or misalign the actual supporting facts.
  • Adult-Centric Bias: Across the board, models performed best on adult (18–64) cases and significantly worse on children (<18) and older adults ($\ge$65). Even the strongest frontier models couldn't escape this population gap.
  • Polypharmacy Heuristics: As the number of drugs increases (from 3 to 10), prediction accuracy stays stable or even rises, but risk assessment falters—models often resort to over-predicting high-risk labels rather than reasoning through the specific drug combinations.

Key Results

  • Single-Drug & Pairwise DDI (Exact Match): On DDI prediction, Gemini-2.5-Flash (63.55%) and GPT-5-mini (57.60%) performed well. However, on mechanism prediction, most models scored below 30% (e.g., GPT-5-mini hit 24.60%; LLaMA-3.1-8B dropped to 4.22%).
  • Polypharmacy (10 Drugs): Gemini-2.5-Flash and GPT-5-mini both exceeded 65% Exact Match on 10-drug prediction, though risk assessment remained variable.
  • Intermediate Reasoning (SafeDrug-small): When directly tested on recovering the underlying pharmacological rationale, mean rationale-selection accuracy ranged from just 0.094 to 0.234, while evidence-grounding F1 sat between 0.453 and 0.566.

Limitations and Future Work

The authors note that SafeDrug still has underrepresented subpopulations and incomplete evidence annotations. Moving forward, they suggest expanding mechanistic data coverage and developing modeling strategies that explicitly improve compositional reasoning, evidence alignment, and fairness across pediatric and older adult populations.

Summary updated

BibTeX
@inproceedings{ma2026safedrug,
  author = {Tengfei Ma and Yushan Yang and HOU Jiahao and Yujie Chen and Guanghui Ye and Xuanbai Ren and Yiping Liu and Bosheng Song and Xiangxiang Zeng},
  title = {{SafeDrug: A Benchmark Dataset for Safety-Critical Pharmacological Reasoning in LLMs}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=8ZSkbx5A6D},
}

Loading related content...

Figure