Explanations or Attacks? Beyond Adversarial Edits in Visual Counterfactual Explanations

Counterfactual explanations and adversarial examples address a similar question: what is the smallest change to an input that flips a classifier's decision? However, a key difference is that a useful explanation must convey a meaningful change recognizable beyond the explained classifier; otherwise, even a visually plausible counterfactual may be little more than an adversarial perturbation. To check if a counterfactual behaves like an adversarial edit, we introduce an evaluation protocol based on simple diagnostics, independent oracles, and robustness to image transformations, including diffusion purification. Our analysis shows that several state-of-the-art counterfactual methods behave more like adversarial attacks than useful explanations. We address this problem by proposing SeeShift, a method that learns to shift the semantic latent code of a diffusion autoencoder without directly optimizing pixels based on classifier gradients. The resulting edit is transferred to the original image as a localized residual, preserving content outside the edited region. Experiments on human (CelebA-HQ) and animal (AFHQ) faces, and on chest radiographs (NIH ChestX-ray14) show that SeeShift achieves higher oracle validity and robustness to image transformations than competing methods, while maintaining visual similarity to the input images. A blinded study with physicians further shows that SeeShift depicts the intended clinical changes more frequently and is preferred over competing explanations. Our findings demonstrate that classifier flips and pixel proximity alone are insufficient to establish the explanatory value of a counterfactual.

Authors

Publication Details

Journal
arXiv
Published
2026-12-02
Primary Topic
Explainable Artificial Intelligence (XAI)
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
preprint

Explanations or Attacks? Beyond Adversarial Edits in Visual Counterfactual Explanations

Marek Śmieja, Mário A. T. Figueiredo, Jan Masłowski
arXiv
Explainable Artificial Intelligence (XAI)
preprint

Explanations or Attacks? Beyond Adversarial Edits in Visual Counterfactual Explanations

Marek Śmieja, Mário A. T. Figueiredo, Jan Masłowski
preprint en

Abstract

Counterfactual explanations and adversarial examples address a similar question: what is the smallest change to an input that flips a classifier's decision? However, a key difference is that a useful explanation must convey a meaningful change recognizable beyond the explained classifier; otherwise, even a visually plausible counterfactual may be little more than an adversarial perturbation. To check if a counterfactual behaves like an adversarial edit, we introduce an evaluation protocol based on simple diagnostics, independent oracles, and robustness to image transformations, including diffusion purification. Our analysis shows that several state-of-the-art counterfactual methods behave more like adversarial attacks than useful explanations. We address this problem by proposing SeeShift, a method that learns to shift the semantic latent code of a diffusion autoencoder without directly optimizing pixels based on classifier gradients. The resulting edit is transferred to the original image as a localized residual, preserving content outside the edited region. Experiments on human (CelebA-HQ) and animal (AFHQ) faces, and on chest radiographs (NIH ChestX-ray14) show that SeeShift achieves higher oracle validity and robustness to image transformations than competing methods, while maintaining visual similarity to the input images. A blinded study with physicians further shows that SeeShift depicts the intended clinical changes more frequently and is preferred over competing explanations. Our findings demonstrate that classifier flips and pixel proximity alone are insufficient to establish the explanatory value of a counterfactual.

arXiv
Explainable Artificial Intelligence (XAI)
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon