tezvyn:

Why was this customer denied: global or local explanation?

AI-drafted, machine-checkedSource: christophm.github.iobeginner
Why was this customer denied: global or local explanation?

This tests matching questions to explanation scope. Global methods show overall behavior; local methods explain one prediction. Specific denials need local methods like SHAP. A red flag is using global summaries like permutation importance or PDPs for a case.

WHAT THIS TESTS: Whether you can match the scope of an explanation to a business question and name practical tooling. A product manager asking about one customer is asking a local question, but many engineers default to global model summaries because those are the metrics they monitor in training pipelines. The interviewer wants to see that you understand the difference between how a model behaves in general and why it made one specific decision.

A GOOD ANSWER COVERS: First, define global explanations as methods that describe overall model behavior across the dataset, such as permutation feature importance, partial dependence plots, or accumulated local effects. Second, define local explanations as methods that unpack exactly one prediction, such as SHAP values, LIME, or counterfactual explanations. Third, state clearly that a question about a specific loan denial requires a local explanation because global trends can average away the unique feature combination that triggered this denial. Fourth, name a concrete library like the Python shap package, lime, or alibi and briefly note what it produces, for example SHAP force plots or waterfall charts that show directional feature contributions for a single row.

COMMON WRONG ANSWERS: Confusing global and local scope is the biggest red flag. Do not suggest permutation feature importance or PDPs to explain one person. Another red flag is giving a vague answer like we look at the weights without specifying whether you mean global coefficients or local attribution values. Also avoid saying you would just show the feature values; the PM already knows the customer has a low credit score, they want to know how much that mattered relative to other features for this exact prediction.

LIKELY FOLLOW-UPS: The interviewer might ask how you would explain SHAP values to a non-technical PM without jargon. They might ask what you would do if the local explanation contradicts the global story, for example if a feature usually helps approval but hurt this customer. They might also ask how you handle correlated features in local explanations, or when global explanations are actually the right tool, such as during model validation or regulatory reporting.

ONE CONCRETE EXAMPLE: Suppose a customer with a 720 credit score and a debt-to-income ratio of 48 percent is denied. A global PDP might show that higher DTI generally increases denial probability across the portfolio. But the local SHAP explanation reveals that for this exact customer, the DTI contributed plus 0.15 toward denial while the credit score contributed minus 0.08 toward approval, and the model threshold was 0.10. That precise breakdown lets the PM understand why the denial happened and what the customer could change.

Source: christophm.github.io

Read the original → christophm.github.io

Get five bites like this every day.

Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.