Fair Recourse for All: Ensuring Individual and Group Fairness in Counterfactual Explanations
Fatima Ezzeddine, Obaida Ammar, Silvia Giordano, Omran Ayoub
TL;DR
This work tackles fair counterfactual explanations (CFs) by defining individual ($EE$), group ($ECR$), and hybrid fairness and solving CF generation as a model-agnostic reinforcement learning problem using SAC. It introduces tailored reward functions that encode $EE$ and $ECR$ objectives while preserving CF validity, plausibility, and proximity, and demonstrates these concepts on three datasets (Adult, SSL, Alzheimer) with clustering to reveal local fairness patterns. Empirical results show high recourse success across groups, low disparities ($PD$), and CFs that remain close to original instances, with hybrid fairness offering a favorable trade-off between equity and CF quality. The study also compares against strong baselines (NiCE, DiCE, Prototype-guided) and discusses broader implications of hybrid fairness for XAI and fairness auditing.
Abstract
Explainable Artificial Intelligence (XAI) is becoming increasingly essential for enhancing the transparency of machine learning (ML) models. Among the various XAI techniques, counterfactual explanations (CFs) hold a pivotal role due to their ability to illustrate how changes in input features can alter an ML model's decision, thereby offering actionable recourse to users. Ensuring that individuals with comparable attributes and those belonging to different protected groups (e.g., demographic) receive similar and actionable recourse options is essential for trustworthy and fair decision-making. In this work, we address this challenge directly by focusing on the generation of fair CFs. Specifically, we start by defining and formulating fairness at: 1) individual fairness, ensuring that similar individuals receive similar CFs, 2) group fairness, ensuring equitable CFs across different protected groups and 3) hybrid fairness, which accounts for both individual and broader group-level fairness. We formulate the problem as an optimization task and propose a novel model-agnostic, reinforcement learning based approach to generate CFs that satisfy fairness constraints at both the individual and group levels, two objectives that are usually treated as orthogonal. As fairness metrics, we extend existing metrics commonly used for auditing ML models, such as equal choice of recourse and equal effectiveness across individuals and groups. We evaluate our approach on three benchmark datasets, showing that it effectively ensures individual and group fairness while preserving the quality of the generated CFs in terms of proximity and plausibility, and quantify the cost of fairness in the different levels separately. Our work opens a broader discussion on hybrid fairness and its role and implications for XAI and beyond CFs.
