Abstract
Transparency is an essential requirement of machine learning based decision making systems that are deployed in real world. Often, transparency of a given system is achieved by providing explanations of the behavior and predictions of the given system. Counterfactual explanations are a prominent instance of particular intuitive explanations of decision making systems. While a lot of different methods for computing counterfactual explanations exist, only very few work (apart from work from the causality domain) considers feature dependencies as well as plausibility which might limit the set of possible counterfactual explanations. In this work we enhance our previous work on convex modeling for computing counterfactual explanations by a mechanism for ensuring actionability and plausibility of the resulting counterfactual explanations.
Introduction
As machine learning models increasingly influence critical decisions, such as loan approvals, the need for interpretable explanations becomes paramount. Counterfactual explanations—statements of the form "If feature X were different, the outcome would be Y"—are highly intuitive for users. However, standard methods for generating these explanations often fail in two key areas: actionability and plausibility.
Actionability is compromised when suggested changes ignore physical or logical dependencies between features (e.g., increasing education without increasing age). Plausibility is lost when algorithms produce "adversarial" points that satisfy the model's decision boundary but do not resemble real-world data. This paper proposes a convex optimization framework to address these issues efficiently.
Methodology
The proposed framework shifts the focus from searching for a counterfactual data point $\vec{x}_{cf}$ to optimizing an action vector $\vec{\delta}$. This vector, when applied through a mapping function $f(\cdot)$, generates the counterfactual.
Actionability through Correlation
To ensure actionability, the method incorporates a sparse inverse covariance matrix estimated from training data. This ensures that the generated counterfactual respects the natural correlations between features, reflecting how they would realistically move together.
Plausibility via Prototypes
Plausibility is enforced by requiring the counterfactual to reside within the convex hull of "prototypes"—representative data points learned via dictionary learning. This prevents the generation of mathematical anomalies and ensures the explanation looks like a valid instance of the target class.
Convex Optimization
By formulating the search as a convex optimization problem with affine mapping and convex decision boundaries (applicable to models like Logistic Regression, SVMs, and GLVQ), the authors enable the use of high-performance solvers. This allows for the generation of realistic explanations in milliseconds, a significant improvement over slow, non-convex alternatives.
Experimental Evaluation
The framework was evaluated on four datasets: Iris, Wine, Breast Cancer Wisconsin, and Digits. The researchers compared their "actionable" counterfactuals against standard "closest" counterfactuals across two model types: Softmax regression and Generalized Learning Vector Quantization (GLVQ).
Results and Discussion
The experiments revealed that ignoring feature dependencies leads to fundamentally different advice. As shown in Figure 1, the number of overlapping features between standard and actionable counterfactuals varies significantly across datasets. In the Breast Cancer dataset, for instance, the actionable method typically changed two more features than the standard method to account for correlations.
Furthermore, the Euclidean distance between the standard and actionable counterfactuals was substantial, particularly in higher-dimensional datasets like Breast Cancer. This proves that ignoring feature dependencies leads to fundamentally different (and likely misleading) advice.
In the Digits dataset, standard counterfactuals often appeared as noisy, adversarial versions of the original image. In contrast, the plausible counterfactuals generated by the proposed method clearly resembled the target digit class, providing a more convincing and human-interpretable explanation.
Conclusion and Future Work
This work demonstrates that incorporating feature dependencies and data-driven plausibility constraints into a convex optimization framework produces more realistic counterfactual explanations without sacrificing computational efficiency. While currently limited to linear correlations and convex model boundaries, future research will explore non-linear dependencies and applications to complex "black-box" neural networks, alongside user studies to validate human perception of plausibility.
Summary updated