Evidence-Pinned Extraction for Rare Adverse Events

When a language model is trained to list the rare adverse drug reactions described in a medical paper, it can fail in two opposite ways. It can say nothing, because most documents mention few or no reactions and an empty answer is usually safe. Or, once pushed to find more, it can list reactions that are common in its training data but absent from the document. The second failure is a hallucination produced by the model's prior over labels, and not by misreading the text. We propose to make the extractor pin every reaction it emits to a verbatim evidence passage in the source. The training reward then rewards recall only for positives that are both correctly labelled and supported by that passage. If this works, a rare-event extractor can be pushed hard toward recall without paying for it in invented events.

The opportunity is concrete. On BioDEX, a benchmark that pairs biomedical papers with FDA safety reports, the reaction field is stuck near 34% F1 even for the best fine-tuned model (BioDEX). Work on hallucination span detection has shown that recall-oriented reward shaping is necessary under imbalance, because models otherwise learn to predict nothing (Learning to Reason for Hallucination Span Detection). Our central observation is that the same shaping, applied to extraction of normalized labels, creates a new way to game the reward: guessing high-frequency labels without reading the document. Evidence pinning is the specific ingredient that blocks it. We also ask a secondary question: whether domain-specific pre-training reduces these prior-driven guesses at matched recall.

Core Claim

In generative extraction of rare events, class imbalance and hallucination are the same problem viewed from two sides. The model trades omission against fabrication along a single precision–recall curve. We claim that two things together move that curve outward, rather than sliding along it. The first is an output format in which each emitted event carries a pointer to a source substring. The second is a reward that credits recall only for grounded positives and penalizes ungrounded ones. The move should be largest for rare, low-frequency reaction types, which are exactly where prior-driven guessing fails and where current systems collapse.

The file's closest pieces each do part of this and stop short. Learning to Reason for Hallucination Span Detection introduces class-aware policy optimization, a reward scaling that stops a detector from predicting empty spans. It works on general RAG text, where the target is the error span itself, so there are no normalized labels to guess. We reuse its reward-shaping idea. We argue, however, that transplanting it to label extraction without grounding invites a different form of reward hacking. RIGA at SMM4H-2024 uses GPT-4 inside a classify-then-tag-then-normalize cascade for adverse events in tweets and reports hallucinated, verbose, text-deviating outputs, but it adds no check against them. BioDEX establishes the benchmark and baselines and does not examine whether wrong reactions are grounded in the text. BioBART motivates the generative formulation: casting entity recognition and linking as sequence generation handles discontinuous and normalized entities. BioBART was not studied under severe imbalance or for fabricated entities.

Research Program

The extractor is an encoder–decoder or decoder-only model. For each document it emits a sequence of records, each consisting of a normalized reaction term followed by a quoted evidence substring. Grounding is checked in two stages. The hard check requires the quoted substring to occur verbatim in the document. The soft check scores whether that substring supports the reaction term. The soft scorer is a small entailment classifier. It is trained on reaction–sentence pairs mined automatically from BioDEX training documents whose gold reactions have lexical or synonym matches, and it is frozen before any policy training. Because the soft scorer could itself be gamed, we report every result under the hard check alone as well.

Training proceeds in two phases. The first is supervised fine-tuning on evidence-augmented targets built by the same mining procedure. The second is group-relative policy optimization, which samples several outputs per document and rewards each relative to the group. The reward for a document is

$$ R = \mathrm{F1}_{\alpha}\big(\hat{Y}_{g}, Y\big) - \lambda\,|\hat{Y} \setminus \hat{Y}_{g}|, $$

where $Y$ is the gold reaction set, $\hat{Y}$ is the set of emitted reactions, $\hat{Y}_{g} \subseteq \hat{Y}$ are the emitted reactions whose evidence passes the grounding check, $\mathrm{F1}_{\alpha}$ is an F-score with recall weighted by $\alpha > 1$ in the spirit of class-aware scaling, and $\lambda$ penalizes each ungrounded emission. The design logic is as follows. With $\alpha > 1$ and no grounding term, emitting a frequent label unread has positive expected reward whenever that label's base rate is high enough. Restricting credit to $\hat{Y}_{g}$ removes that incentive, because a guessed label rarely comes with a supporting quote.

We will run the full recipe on BART-Large and BioBART-Large, which share architecture and differ only in PubMed pre-training, and on FLAN-T5-Large to match the BioDEX baseline. We add Qwen2.5-7B for comparability with the span-detection work. For the domain-pre-training question we use the BART and BioBART pair. It is the cleanest comparison the file supports, because the only thing that differs is continued pre-training on biomedical text.

BioDEX full texts have a median of about 20,000 characters. Long inputs are known to increase factual errors (Evaluating large language models on medical evidence summarization, which found that feeding full abstracts rather than main-result sections degraded factuality). We therefore process documents in overlapping chunks and take the union of grounded records. We will also report whether evidence pinning reduces the length penalty.

Baselines

The naive reference point is the empty predictor and a frequency prior. The frequency prior emits the top-$k$ most frequent training reactions for every document, with $k$ tuned on validation. It exists to quantify how much reaction F1 is available to a model that never reads the text. That quantity is the ceiling on reward hacking, and every other system should be compared against it on rare-label buckets.

The strongest existing method on our primary benchmark is fine-tuned FLAN-T5-Large from BioDEX. It reports 59.1% F1 overall and roughly 34% F1 on reactions. For reference, few-shot GPT-4 reaches 53.1% and human experts about 72.0%. We will retrain it on the same training split, with the same chunking and the same number of validation-tuned hyperparameter trials as our method. Because a single operating point hides the omission–fabrication trade, we sweep its decoding bias on the end-of-list token to trace a full precision–recall curve. Beating it means a reaction-F1 improvement of at least three points at the best operating point, plus a curve that dominates it in the recall range above its default. The improvement should be concentrated in reactions below the training-frequency median.

The strongest competitor on the imbalance side is class-aware group-relative optimization as in Learning to Reason for Hallucination Span Detection. There it reports 55.9 span-F1 on RAGTruth, against 50.1 for supervised fine-tuning and 51.2 for o3. We run it as our own recipe with $\lambda = 0$ and credit given to all of $\hat{Y}$ rather than $\hat{Y}_{g}$. It uses the same models, reward weighting $\alpha$, sampling budget, and training steps. This is the ablation that isolates evidence pinning. It is expected to raise recall over supervised fine-tuning while inflating ungrounded emissions of frequent labels. If it instead matches the full method on precision and rare-label F1, our core claim fails.

The cascade baseline follows RIGA at SMM4H-2024. A document-level gate is followed by the generative extractor run only on gated-positive chunks. On SMM4H-2024 we found no reported numeric result on Lacuna for RIGA's submissions beyond "above mean and median," so we will reproduce it rather than quote it. A GPT-4 few-shot prompt with the same evidence-pinned format serves as the frontier-prompting reference. It is given the same demonstrations and chunking.

Why not just…?

Why not just tune the decoding threshold of a supervised extractor? This is the most serious threat. Lowering the end-of-list penalty on a fine-tuned FLAN-T5 raises recall for free. If the resulting curve matches ours, the policy optimization is unnecessary. Our argument is that threshold tuning slides along a fixed curve: extra recall comes disproportionately from frequent labels, because those carry the most prior probability mass. The swept baseline above is exactly this experiment. We will judge it on rare-label F1 and on the evidence-deletion probe described below, not on overall F1 alone.

Why not just filter a supervised model's outputs with the grounding check at test time? This is also a real threat. Oversampling from the supervised model and discarding ungrounded records uses our key ingredient without any training. It cannot recover reactions the model never proposes, and omission is the dominant failure on rare labels in BioDEX. It does, however, directly remove fabrications. We run it as a baseline at matched inference compute. If it closes most of the gap, we will say that the contribution is the evidence-pinned format and verifier rather than the training procedure.

Why not just prompt a frontier model? The evidence in the file is consistently against it for this regime. Few-shot GPT-4 trails fine-tuned FLAN-T5-Large on BioDEX (53.1% vs 59.1%). o3 trails a trained 7B detector on RAGTruth (51.2 vs 55.9). RIGA reports hallucinated and verbose GPT-4 extractions on rare tweets. We still include an evidence-pinned GPT-4 prompt, because pinning might help it more than it helps small models.

Why not just rebalance the training data? MIDAS@SMM4H-2019 found that undersampling negatives hurt BERT and ULMFiT on adverse-reaction tweets. For document-level extraction, the imbalance is also over which reactions appear within a document, and removing negative documents cannot address that. We include one oversampled-positive supervised run for completeness.

Proposed Experiments

The primary benchmark is BioDEX report extraction (9.6k train, 2.4k validation, 3.6k test papers), with reaction F1 as the headline metric. Results are broken down by training-frequency tertile of the gold reaction, and we report the temporal split BioDEX provides.

The decisive diagnostic is an evidence-deletion probe. For each test document we remove the sentences that the mining procedure links to a gold reaction, rerun the extractor, and count how often it still emits that reaction. A high persistence rate means the model is emitting from its prior. Our method should cut persistence well below both the supervised baseline and the no-grounding ablation at matched recall. This probe does not depend on the soft verifier, so it guards against the verifier being gamed.

The domain question is settled by comparing BART-Large and BioBART-Large under identical recipes. We measure persistence and rare-tertile F1 at matched recall. If domain pre-training lowers prior-driven emissions, BioBART should show lower persistence even with $\lambda = 0$.

Transfer beyond formal literature uses two further datasets. On the DataLoch discharge summaries, the reported fine-grained extraction ceiling is about 0.67 F1 against 0.943 at document level (Adverse Event Extraction from Discharge Summaries), which makes it a direct test of whether pinning narrows that gap. Its negation and low-confidence attributes let us check whether grounded-but-negated mentions ("no delirium") are handled, since a verbatim quote alone does not establish the event occurred. On SMM4H-2024 Task 1 (6.8% positive tweets), we test the informal-text "clinical gap" that BioBART's PubMed pre-training may not cover.

The note would be falsified by any of three outcomes. First, the no-grounding class-aware ablation matches the full method on rare-tertile F1 and persistence. Second, test-time filtering of a supervised model matches it at equal compute. Third, the gains appear only on frequent reactions.