Find the Span, Then Forbid the Copy: Debate-Based Error Localization for Correcting LLM Hallucinations

When a language model fixes factual errors in its own draft, two separate things can go wrong. First, it may never notice which few words are false. Second, even after a false phrase has been pointed out, a model asked to rewrite a draft that is 95% correct tends to reproduce it almost word for word, false phrase included. Text-editing research calls this second failure identity mapping bias: when source and target overlap heavily, copying the input is a cheap and nearly optimal behavior. This proposal treats post-hoc hallucination correction as a two-stage problem. The first stage is error-span detection, meaning drawing boundaries around the exact words that are wrong. Multiple model instances argue specifically about where those boundaries should fall. The second stage is a masked fill: the flagged words are removed from the draft and the editor must regenerate them from evidence, so copying them is no longer possible.

The bet is that error-span detection, not rewriting, sets the ceiling on how many hallucinations a correction system can remove. This mirrors a long-known result in coreference and entity linking. There, the hard part is drawing the right spans before any linking happens (the mention detection bottleneck). Gold mention boundaries alone add 8.4 to 12.3 CoNLL points to modern resolvers (Ng). In tweets, simply picking the most popular candidate entity is over 85% accurate once boundaries are right (Guo, Chang, Kiciman). If the same holds for hallucination correction, research effort should move from better rewriters to better localizers. It should also move away from debate systems that issue verdicts on whole claims and toward debate over spans.

Core Claim

We claim that the fraction of hallucinated spans surviving correction decomposes into a detection term and a copy term:

$$ S \;=\; (1 - r) \;+\; r\,c , $$

Here $S$ is the fraction of gold hallucinated spans that remain unchanged in the corrected output. The term $r$ is the recall of the error-span detector. The term $c$ is the copy-through rate, meaning the probability that a flagged span is nevertheless reproduced by the editor. The equation is an accounting identity if we treat a flagged span as either reproduced or replaced, ignoring partial edits.

Free-form rewriting keeps $c$ well above zero, because the editor copies flagged text even when told it is wrong. Masked fill drives $c$ to roughly zero by construction. Once $c$ is gone, $S$ depends almost entirely on $r$, and spending compute on better detection pays off directly.

The cost side is over-editing. A detector tuned for recall flags correct text, and a forced refill can corrupt it. The editor therefore receives retrieved evidence and is allowed to restore the original span when the evidence supports it. We measure how often correct spans come back intact.

Debate enters as the detector, with a specific job. One agent argues for widening or adding error spans (a recall advocate). Another argues for shrinking or dropping them, citing evidence that the words are supported (a precision advocate). A judge fixes the final boundaries. This turns the precision/recall tension that has dogged mention detectors (Stoyanov et al.; Denis et al.) into an explicit adversarial exchange. Whether arguing beats simply voting at equal compute is an open empirical question, and the experiments test it directly.

Relation to Prior Work

Three debate systems motivate the detector, but none of them edits text. The Markov-chain debate of Sun et al. splits a response into claims and has Trust, Skeptic and Leader agents label each claim true or false. It reaches 76.00% on HaluEval dialogue against a 68.00% baseline, and 72.00% response-level accuracy on Factool QA against 64.00% for Factool. Its output is a verdict, and its claim splitting is a single heuristic prompt whose boundary errors are never measured. CFMAD assigns stances to pre-enumerated answer options, which rules out free-form drafts. LegalHalluLens is the closest in spirit. It separates errors of omission from errors of invention through its Risk Direction Index and gates its six-role debate asymmetrically, cutting fabricated clause detections by 45%. However, it works over predefined contract clause types and has no editing model. We borrow its omission/invention asymmetry and reinterpret it as the false-negative/false-positive asymmetry of a span detector.

Three lines of text-editing work supply the anti-copying mechanism, though all of them target surface errors rather than facts.

  • MaskCorrect masks 15–20% of correct source tokens at random so that a correction model cannot rely on copying. This lifts BEA-2019 $F_{0.5}$ from 50.4 to 53.9. It also finds that clean training data strengthens the copy shortcut.
  • Cao et al. show that grammatical error correction models are overconfident at copied positions and uncertain at edit positions. They mask low-confidence positions for a second, bidirectional decoder.
  • EditNTS and Prog-Refine make edits explicit through a "programmer" model that emits keep/delete/insert commands and an "interpreter" that carries them out.

Our masked fill differs from MaskCorrect and Cao et al. in two ways. It masks at inference time rather than during training, and it chooses positions by evidence-based argument rather than at random or by decoder confidence. Prog-Refine is the most important constraint on the design. Its authors report that an oracle programmer adds nearly 30 BLEU over the system, which is direct evidence that localization dominates in post-editing. We take that finding as our starting hypothesis and test whether it carries over to factual correction.

On the hallucination side, FActScore provides the evaluation. It splits long-form biographies into atomic facts, checks each against Wikipedia, and documents lower precision on rare entities and decay later in a generation. It does not correct anything, and its decomposition is itself an unaudited span-drawing step. CoBa intervenes during decoding using token probability and distance from the source. It cannot revise a finished draft or catch relational errors such as swapped roles. HaluEval constrains the design. It shows that models detect their own fabrications poorly (58.53% for ChatGPT on summarization). It also shows that presenting correct and hallucinated versions side by side can hurt detection. For that reason our agents argue over one draft against retrieved evidence, never over contrasting drafts.

Research Program

The system has three parts.

  1. Draft generation. A generator writes the draft, for example a biography of a named entity.
  2. Span debate. A retriever fetches evidence for the draft. A proposer then marks candidate error spans as character offsets. Over a fixed number of rounds, the recall advocate and the precision advocate contest additions, deletions and boundary shifts, and each must quote evidence. A judge outputs the final span set.
  3. Masked fill. The editor receives the draft with the flagged spans replaced by numbered blanks, plus the evidence. It fills each blank or, when the evidence is insufficient, marks it "unsupported, remove." Text outside the blanks is frozen, so unflagged content cannot drift.

The first analysis is the oracle decomposition. It holds detection fixed while varying the editor, and holds the editor fixed while varying detection. This estimates $r$ and $c$ separately and tests whether the identity in the Core Claim predicts residual hallucination. The second analysis breaks results down by entity rarity, following FActScore. Our hypothesis is that detection recall, not editing, is what fails on rare entities, which would make rarity a localization problem.

Span-level gold labels are needed for both analyses. We build them for a subset of FActScore biographies by aligning unsupported atomic facts back to the draft words that express them, with two annotators and adjudication. We also map CUAD's typed clause errors to spans. Where HaluEval provides paired correct and hallucinated responses, we derive candidate spans by aligning the two and then check them by hand.

Baselines

The naive reference point is the uncorrected draft, scored with FActScore. On the FActScore biography benchmark, the reported overall scores are 58.3% for ChatGPT and 71.5% for PerplexityAI (Min et al.). We regenerate drafts with our own generator, so the baseline is re-measured rather than copied. A second naive baseline is single-agent self-correction: the generator, given the same retrieved evidence, is asked to review and rewrite its draft. This is the most common practice, and it isolates the joint effect of detection and copying with no structure at all.

The strongest existing method for detection is the Markov-chain debate of Sun et al.. We turn its claim verdicts into an editor by rewriting every claim it judges false. Its reported numbers are 76.00% accuracy on HaluEval dialogue and 72.00% on Factool QA. For correction on FActScore biographies, we found no reported result on Lacuna for this or any debate-based correction method, so all correction numbers will be measured fresh.

The strongest explicit-edit competitor is a Prog-Refine-style pipeline. A small model, fine-tuned on our span labels, emits delete/insert commands, and the LLM interpreter applies them. Its reported numbers are from machine translation, not factuality: Kashmiri–English BLEU rose from 9.21 to 16.32.

The ablations isolate each ingredient.

  • Debate without masking (debate spans plus free rewrite) measures $c$.
  • Masking without debate (single-prompt spans plus masked fill) measures how much debate adds to $r$.
  • Random-span masking (spans of the same total length placed at random) is an analog of MaskCorrect at inference time and controls for the bare effect of forcing edits.
  • Oracle spans plus masked fill gives the ceiling.
  • Compute-matched voting. Independent single-agent detectors are run with as many total generated tokens as the debate uses, and their spans are combined by majority vote at the token level. This is the critical control on whether arguing matters.

All systems use the same generator, retriever, evidence passages, editor model and decoding settings. Each gets an equal prompt-tuning budget on a shared development split. Cost is reported as total generated tokens per draft.

The proposal beats the field if it meets three conditions:

  • It raises FActScore precision over Sun-et-al.-plus-rewrite at equal or lower token cost.
  • It does not reduce the number of supported atomic facts retained by more than a small, pre-registered margin, so that precision is not bought by deletion.
  • Its span-detection recall exceeds compute-matched voting on the rare-entity bins.

Why not just…?

Why not just ask a strong model to rewrite its draft using the retrieved evidence? This is the self-correction baseline, and the oracle experiment tests it in its strongest form. The rewriter is told exactly which spans are wrong, yet it rewrites freely. If its copy-through rate $c$ on gold-flagged spans is near zero, identity mapping bias does not apply to factual post-editing and the masking component is unnecessary. We would then report that as a negative result. The evidence suggesting otherwise comes from neighboring settings. Overconfident copying appears even at known edit positions (Cao et al.), and LLMs copy source sentences when asked to simplify them (Kew et al.). Neither result tested factual correction, which is why the oracle run comes first.

Why not just sample several independent detectors and vote, which is cheaper than debate? This is the real threat. The proposal does not assume debate wins. Compute-matched voting is run as a full baseline, scored on span-level recall and boundary accuracy, not only on claim labels. Our hypothesis is that argument helps mainly on boundaries and on rare entities, where a single detector misses an error and only an advocate searching the evidence surfaces it. If voting matches debate at equal tokens, the contribution narrows to the span-first decomposition plus masked fill, with voting as the recommended detector. We would report it that way.

Why not just fine-tune a span tagger, as the Prog-Refine programmer does? A fine-tuned tagger is cheap at inference and is included as a baseline. Two findings argue against expecting it to win. Prog-Refine's own 30-BLEU oracle gap shows that a small fine-tuned programmer localizes errors poorly. Ng's "unseen name trap" shows that span models memorize familiar names, which is exactly the regime of rare-entity hallucination. The rarity breakdown will show whether the tagger collapses on rare entities as predicted.

Why not just delete flagged spans instead of refilling them? Deletion drives $S$ down trivially and inflates FActScore precision, since FActScore measures only the share of supported facts. For this reason we report the count of supported facts retained, and the "remove" option in our editor is counted as an omission. A method that wins only through deletion is reported as trading recall for precision, in the omission direction that LegalHalluLens warns about.

Decisive Checks

The first check is the oracle decomposition on FActScore biographies. It runs gold spans with free rewrite, gold spans with masked fill, predicted spans with masked fill, and no spans. The idea is supported if the gap between gold and predicted spans is larger than the gap between free rewrite and masked fill once gold spans are given, and if $c$ under free rewrite is clearly nonzero. If the editor gap dominates instead, localization is not the bottleneck and the program should refocus on editing.

The second check compares debate with compute-matched voting on span recall, split into FActScore's frequency bins.

The third check measures over-editing: the share of correct spans that the masked fill changes, and the share it restores intact. A recall-heavy detector is only acceptable if the editor reliably restores correct spans.

Transfer to CUAD tests whether the omission/invention asymmetry measured by LegalHalluLens's Risk Direction Index predicts which debate advocate should be given more weight. HaluEval summarization tests a setting where self-detection is known to be weakest.