Optimal Counterfactual Search in Tree Ensembles: A Study Across Modeling and Solution Paradigms
Awa Khouna, Youssouf Emine, Julien Ferry, Thibaut Vidal

TL;DR
This paper develops and compares different optimization methods for computing minimal, plausible, and actionable counterfactual explanations in tree ensemble models, highlighting the strengths of each approach.
Contribution
It introduces CPCF, a constraint programming formulation for optimal counterfactual search, and compares it with MaxSAT and MILP across multiple datasets and ensemble types.
Findings
CP achieves the best overall performance in scalability and anytime solutions.
MaxSAT performs well with hard-voting ensembles.
MILP is competitive in amortized inference with moderate split levels.
Abstract
Trust in counterfactual explanations depends critically on whether their recommended changes are truly minimal: suboptimal explanations may vastly overshoot the actual changes needed to alter a decision, and heuristic errors can affect individuals unevenly, giving some users relevant recourse while assigning others unnecessarily costly recommendations. Consequently, we study the problem of computing optimal counterfactual explanations for tree ensembles under plausibility and actionability constraints. This is a combinatorial problem: for a fixed model, counterfactual search boils down to selecting consistent branching decisions and threshold-defined regions under a distance objective. We exploit this structure through CPCF, a constraint programming (CP) formulation in which numerical features are encoded as interval domains induced by split thresholds, while discrete features retain…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
