A Query-Optimal Algorithm for Finding Counterfactuals

Abstract

We design an algorithm for finding counterfactuals with strong theoretical guarantees on its performance. For any monotone model f : Xd \0,1\ and instance x, our algorithm makes \[ S(f)O(f(x))· d\] queries to f and returns an optimal counterfactual for x: a nearest instance x' to x for which f(x') f(x). Here S(f) is the sensitivity of f, a discrete analogue of the Lipschitz constant, and f(x) is the distance from x to its nearest counterfactuals. The previous best known query complexity was d\,O(f(x)), achievable by brute-force local search. We further prove a lower bound of S(f)(f(x)) + ( d) on the query complexity of any algorithm, thereby showing that the guarantees of our algorithm are essentially optimal.

0

Turn this paper into a full lesson

ArcXiv compiles a staged curriculum from this paper: 8-12 lessons across beginner → advanced, synthesised section guides, visuals, flashcards, a quiz, exercises, and on-demand deep dives per section. Grounded in the abstract, never invented.

Discussion (0)

Sign in to join the discussion.

Loading comments…