TL;DR
This paper introduces RootCLAM, a novel framework that leverages causal inference to not only identify the root causes of anomalies detected by deep learning models but also to recommend specific actions to mitigate these anomalies. By treating anomalies as the result of external interventions in a structural causal model, RootCLAM offers a more interpretable and actionable approach to anomaly detection.
What Problem Does This Paper Address?
Deep anomaly detection models are widely used in critical applications like security and finance, but they often act as black boxes. When an anomaly is detected, practitioners need to understand why it occurred and how to fix it. Existing methods for explaining anomalies, like feature attribution, highlight abnormal features but fail to capture the underlying causal dependencies between them. For instance, a low savings anomaly might be a consequence of low income, not the primary cause. This lack of causal understanding hinders effective anomaly mitigation. This paper addresses this gap by proposing a method that localizes the true root causes of anomalies and then suggests targeted interventions to revert them to normal.
Methods
The core of RootCLAM is built upon Structural Causal Models (SCMs) and Causal Graph Autoencoders (VACA).
- Root Cause Localization: Anomalies are framed as the result of external interventions on specific features within an SCM. Root causes are identified as features whose exogenous variables deviate significantly from their normal distributions. This is achieved by using VACA to learn a latent representation of these exogenous variables. Features with significantly altered latent representations are flagged as root causes.
- Anomaly Mitigation: Once root causes are identified, RootCLAM formulates anomaly mitigation as a problem of finding optimal "soft interventions" on these root cause features. The goal is to recommend a set of actions (parameter vector $\theta$) that, when applied to the root cause features, flip the detected anomaly to a normal state with minimal perturbation. This is framed as a continuous optimization problem, solved iteratively using an Abduction-Action-Prediction process guided by the VACA and the causal graph's topological order. The framework learns a function $h(x)$ that predicts these mitigation actions for any given anomalous instance.
Datasets
The paper evaluates RootCLAM on three datasets:
- Loan: A semi-synthetic dataset derived from the German Credit dataset, focusing on loan approval scenarios.
- Adult: A semi-synthetic dataset derived from the Adult dataset, focusing on annual income prediction.
- Donors: A real-world dataset for predicting project excitement on DonorsChoose.org.
For the semi-synthetic datasets (Loan and Adult), the paper utilizes the structural equations provided in prior work to simulate anomalies and evaluate counterfactual generation. For the Donors dataset, a causal graph is learned using the PC algorithm.
Key Insights and Ideas
- Causality is Key for Actionability: Simply identifying abnormal features isn't enough. Understanding the causal chain allows for more effective and targeted interventions.
- Root Causes vs. Upstream Anomalies: The framework distinguishes between features directly affected by an external intervention (root causes) and those that become abnormal due to propagation through the causal graph.
- Soft Interventions for Realistic Mitigation: Modeling mitigation actions as soft interventions, which preserve causal dependencies, leads to more realistic counterfactual outcomes compared to hard interventions.
- VACA as a Bridge: The Variational Causal Graph Autoencoder (VACA) is crucial for learning the complex, non-linear causal relationships and for performing counterfactual inference in a differentiable manner.
Key Results
- Root Cause Localization: RootCLAM outperforms the baseline CausalRCA in accuracy and F1 score for root cause localization, particularly showing a much higher recall.
- Anomaly Mitigation: RootCLAM achieves high flipping ratios (transferring anomalies to normal) on both detected anomaly labels and ground truth labels across datasets. It significantly outperforms baselines like C-CHVAE and NaiveAM, especially in flipping the ground truth label.
- Minimal Interventions: RootCLAM achieves these high flipping ratios with significantly smaller action values (norm of interventions) compared to NaiveAM, indicating more efficient and less disruptive mitigation.
- Counterfactual Generation: The generated counterfactual samples are shown to be of high fidelity, with low Mean Squared Error (MSE) and Standard Squared Error (SSE) on datasets with ground truth structural equations.
Limitations and Future Work
- Causal Graph Availability: RootCLAM assumes the availability of a causal graph. While the paper mentions using causal discovery algorithms when graphs are not available, the performance might depend on the accuracy of these discovery methods.
- Computational Cost: The iterative Abduction-Action-Prediction process for anomaly mitigation might be computationally intensive, especially for complex causal graphs or high-dimensional data.
- Future Work: The paper suggests exploring more sophisticated causal discovery algorithms and investigating the framework's scalability to larger and more complex real-world scenarios. Further research could also focus on developing more robust methods for handling feedback loops or cyclic dependencies in causal graphs.
Summary updated