Additive feature attribution is a class of post-hoc explanation methods that decompose a model's prediction into a linear sum of individual feature contributions, or attributions, relative to a reference baseline. The core principle is that the final prediction output equals the baseline prediction plus the sum of each feature's attributed effect, providing a complete and fair accounting of how the input features drove the decision. This linear decomposition makes complex, non-linear models locally interpretable.
Glossary
Additive Feature Attribution

What is Additive Feature Attribution?
A class of explanation methods that decompose a model's prediction into a sum of individual feature contributions relative to a baseline.
This framework unifies several popular explanation techniques, most notably LIME and SHAP. The defining property is that the explanation model is a linear function of binary variables representing feature presence. SHAP, grounded in game theory, uses Shapley values to guarantee a unique, fair distribution of credit among features, while LIME approximates this behavior locally. The additive structure ensures that the sum of all feature attributions exactly equals the difference between the model's output for the specific instance and the expected baseline output, a property known as local accuracy or efficiency.
Core Properties of Additive Feature Attribution
Additive feature attribution methods are defined by three core properties that guarantee explanation uniqueness and consistency. These axioms, rooted in game theory, ensure that a model's prediction is fairly decomposed into a sum of individual feature contributions.
Local Accuracy
The explanation model must perfectly match the original model's output for the specific input being explained. If f(x) is the original prediction and g(x') is the additive explanation, then f(x) = g(x') = φ_0 + Σ φ_i.
- Property: The sum of all feature attributions plus a baseline equals the model's exact prediction.
- Mechanism: The baseline
φ_0represents the model's output when all features are 'missing' or set to a reference value. - Constraint: This forces the explanation to be a faithful, zero-error decomposition of the single prediction, not an approximation.
Missingness
If a feature is missing from the original input—meaning its value is set to a baseline or reference point—its attribution must be exactly zero.
- Property:
x'_i = 0impliesφ_i = 0. - Purpose: Ensures that features which do not contribute to the prediction are not arbitrarily assigned importance.
- Implementation: In SHAP, missingness is handled by integrating over the feature's distribution; in LIME, it is enforced by the interpretable representation where a '0' indicates absence.
- Contrast: This is a critical distinction from simple gradient-based methods, which can assign non-zero importance to features with zero value.
Consistency
If a model changes so that a feature's marginal contribution increases or stays the same regardless of other features, that feature's attribution must not decrease.
- Property: If
f'_x(S ∪ i) - f'_x(S) ≥ f_x(S ∪ i) - f_x(S)for all subsetsS, thenφ_i(f', x) ≥ φ_i(f, x). - Significance: This axiom guarantees that a feature's importance score is logically monotonic with its actual impact on the model.
- Uniqueness: Combined with local accuracy and missingness, consistency forces a single, unique solution—the Shapley values.
Shapley Value Uniqueness
The three core properties—local accuracy, missingness, and consistency—collectively prove that Shapley values are the only possible additive feature attribution method that satisfies all axioms.
- Game Theory Origin: Shapley values were originally derived to fairly distribute a coalition's payout among players based on their marginal contributions.
- ML Translation: In machine learning, 'players' become input features, and the 'payout' is the model's prediction relative to a baseline.
- SHAP Framework: SHAP (SHapley Additive exPlanations) is the direct implementation of this proof, unifying LIME, DeepLIFT, and other methods under a single theoretical umbrella.
Additivity vs. Interaction Effects
Additive explanations decompose a prediction into a sum of independent feature contributions, but real models often rely on complex feature interactions.
- Limitation: An additive explanation cannot directly represent interaction effects where the combined impact of two features differs from the sum of their individual impacts.
- Workaround: SHAP extends the framework with Shapley interaction values, which decompose the prediction into a matrix of main effects and pairwise interaction terms.
- Trade-off: While interaction values capture more model complexity, they sacrifice the simplicity and human-interpretability of a purely additive bar chart.
Baseline Definition
The choice of the baseline or reference value is a critical, non-trivial design decision that anchors the entire additive explanation.
- Role: The baseline represents the 'absence' of information and determines the starting point
φ_0from which feature contributions are measured. - Common Choices: An all-black image for vision models, a zero-vector or [MASK] token for text, or the dataset mean for tabular data.
- Impact: A poorly chosen baseline can produce misleading attributions. For example, using a zero pixel value may conflate 'missing' with 'black'.
- Best Practice: The baseline should be an in-distribution, neutral input that represents a true absence of signal for the specific domain.
LIME vs. SHAP: Additive Attribution Approaches
A technical comparison of the two dominant additive feature attribution frameworks for generating instance-level explanations of black-box model predictions.
| Feature | LIME | SHAP | Integrated Gradients |
|---|---|---|---|
Theoretical Foundation | Local surrogate modeling with perturbation sampling | Shapley values from cooperative game theory | Path integral of gradients from baseline to input |
Model-Agnostic | |||
Guarantees Additivity | |||
Local Fidelity Guarantee | |||
Requires Model Internals | |||
Computational Cost | Low to moderate | High (exponential in features) | Moderate (requires multiple forward/backward passes) |
Handles Structured Data | |||
Handles Image Data | |||
Handles Text Data | |||
Explanation Stability | Varies with kernel width and sampling | Deterministic given sufficient samples | Deterministic given sufficient steps |
Baseline/Reference Value Required | |||
Output Format | Sparse linear weights on interpretable features | Additive Shapley value per original feature | Attribution scores summing to prediction difference |
Kernel/Weighting Mechanism | Exponential kernel based on cosine or L2 distance | Shapley kernel for weighted least squares | Riemann sum approximation along straight-line path |
Handles Feature Interactions | |||
Supports Global Explanations |
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Frequently Asked Questions
Clear answers to common questions about additive feature attribution methods, the mathematical framework that decomposes complex model predictions into a sum of individual feature contributions.
Additive feature attribution is a class of model explanation methods that decompose a single prediction into a sum of individual feature contributions, all measured relative to a baseline or expected value. The core equation is g(z') = φ₀ + Σ φᵢz'ᵢ, where φ₀ is the baseline prediction (the model's output when no features are present), φᵢ is the Shapley value or attribution weight for feature i, and z'ᵢ is a binary variable indicating whether that feature is observed (1) or missing (0). This linear explanation model satisfies three critical properties: local accuracy (the explanation matches the original prediction when all features are present), missingness (missing features receive zero attribution), and consistency (if a model changes so a feature's contribution increases, its attribution never decreases). Both LIME and SHAP are unified under this framework, with SHAP providing the unique solution that satisfies all three properties simultaneously.
Related Terms
Explore the core concepts, game-theoretic foundations, and practical implementations that define how additive feature attribution methods decompose complex predictions into interpretable, linear contributions.
Shapley Values
A solution concept from cooperative game theory that determines the marginal contribution of each player (feature) averaged over all possible coalitions. In ML explainability, the 'game' is the prediction task, and the 'payout' is the difference between the model's output and the average prediction.
- Satisfies efficiency: feature contributions sum to the prediction difference from baseline
- Satisfies symmetry: features with identical marginal contributions receive identical values
- Satisfies dummy: a feature that never contributes receives zero attribution
Baseline Value
The reference point against which feature contributions are measured in additive attribution methods. The baseline represents the expected model output when no feature information is present, often computed as the average prediction over the training dataset.
- For tabular data: the mean or median of each feature column
- For images: a black image, blurred version, or zero-valued tensor
- For text: an empty string or [MASK] token
- The choice of baseline critically impacts explanation interpretation and fairness
Additivity Property
The defining mathematical constraint of this explanation class: the sum of all feature attributions plus the baseline value must exactly equal the model's prediction for that instance. This ensures completeness and prevents unexplained variance.
- Enables linear decomposition of complex non-linear predictions
- Allows attributions to be interpreted as additive contributions in the original output units
- Contrasts with gradient-based methods that measure sensitivity rather than contribution
KernelSHAP
A model-agnostic implementation of SHAP that extends the LIME framework by using a Shapley-weighted kernel for local surrogate model training. KernelSHAP solves the additive attribution problem by weighting perturbed samples according to their Shapley kernel weight rather than an arbitrary distance metric.
- Provides theoretically grounded local explanations for any black-box model
- Computationally expensive: requires 2^M model evaluations for M features in exact form
- Practical implementations use sampling approximations to reduce computation
TreeSHAP
A fast, exact algorithm for computing SHAP values specifically for tree-based models like XGBoost, LightGBM, and random forests. TreeSHAP exploits the internal structure of decision trees to compute attributions in polynomial time rather than exponential.
- Reduces complexity from O(2^M) to O(TLD^2) where T=trees, L=leaves, D=depth
- Computes exact SHAP values without sampling or approximation
- Supports feature interactions by decomposing attributions into main effects and interaction terms

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us