AWS Certified Machine Learning – SpecialtyModelingHard
A machine learning engineer is deploying a model to production that predicts customer sentiment from text reviews. The model is highly accurate but occasionally produces illogical or contradictory predictions for specific, nuanced reviews, making business users distrust the model. The engineer needs a method to explain individual predictions in an interpretable way, even for complex black-box models, to build trust and debug these edge cases. Which interpretability technique is best suited for providing local, model-agnostic explanations?
- ASHAP (SHapley Additive exPlanations)
- BLIME (Local Interpretable Model-agnostic Explanations)
- CPartial Dependence Plots (PDPs)
- DGlobal Feature Importance (e.g., from tree-based models)
Show answer & explanationAnswer & explanation
Correct answer: B. LIME (Local Interpretable Model-agnostic Explanations)
The problem requires 'local, model-agnostic explanations' for 'individual predictions' to debug 'illogical or contradictory predictions' from a 'complex black-box model'. LIME is specifically designed to explain individual predictions of any black-box model by approximating its behavior locally with an interpretable model. This directly addresses the need for local interpretability and debugging specific cases.
Why the other options are wrong
- A. SHAP provides detailed explanations of individual predictions (local) and is model-agnostic, but LIME is often highlighted for its intuitive local approximation, especially when the focus is on debugging specific 'illogical' cases by understanding local feature contributions.
- C. Partial Dependence Plots show the marginal effect of one or two features on the predicted outcome globally, not for individual predictions.
- D. Global Feature Importance provides an overall understanding of which features are important across the entire dataset, not for individual predictions or debugging specific edge cases.
LIME (Local Interpretable Model-agnostic Explanations)
An interpretability technique that explains the predictions of any black-box machine learning model by fitting a simple, interpretable model (e.g., linear model) locally around the prediction of interest.
- Provides local explanations for individual predictions.
- Model-agnostic, works with any black-box model.
- Helps build trust and debug model behavior in specific cases.
- Generates perturbed samples and weights them by proximity.
Memory trick: LIME Explains Each, Locally and Clear.