# Wyjaśnianie pojedynczej decyzji (SHAP, LIME)

EN: **Local feature attribution (SHAP, LIME)** · id `featureattribution` · aliases: SHAP, LIME, Shapley values, wartości Shapleya, local explanations, atrybucja cech

Path: [AI Atlas](https://aiatlasgraph.com/llms.txt) › [Ewaluacja i interpretowalność](https://aiatlasgraph.com/t/evaluation.md) › [Interpretowalność](https://aiatlasgraph.com/t/explainability.md) › Wyjaśnianie pojedynczej decyzji (SHAP, LIME)

## Description

- PL: Metody wyjaśniające pojedynczą predykcję przez przypisanie cechom wkładu w wynik. Mogą traktować model jak czarną skrzynkę albo wykorzystywać jego strukturę.
- EN: Methods that explain an individual prediction by assigning contributions to input features. They may treat the model as a black box or exploit its structure.

## In one sentence

- PL: To szacowanie, jaki wkład poszczególne cechy danych miały w konkretną odpowiedź modelu.
- EN: This estimates how individual data features contributed to a particular model answer.

## Problem it solves

- PL: Widzisz przewidywanie, ale nie wiesz, które części opisu podniosły je lub obniżyły względem wybranego porównania.
- EN: You see a prediction but do not know which parts of the input raised or lowered it against a chosen reference.

## What it does

- PL: Porównuje wpływ cech przez zmianę ich zestawów lub prosty model pomocniczy; wynik zależy od metody i przyjętego punktu odniesienia.
- EN: It compares feature effects through changed feature combinations or a simple supporting model; results depend on the method and reference choice.

## Everyday example

- PL: Przy prognozie opóźnienia paczki oglądasz oszacowane wkłady długości trasy, wagi i dnia wysyłki dla tego jednego przypadku.
- EN: For one parcel delay forecast, you inspect estimated contributions from route length, weight and dispatch day.

## This concerns you if you…

- PL: chcesz badać pojedyncze przewidywanie modelu
- PL: potrzebujesz porównać wkład różnych cech przykładu
- EN: want to examine an individual model prediction
- EN: need to compare contributions from an example's features

## Keywords

Shapley values · KernelSHAP · TreeSHAP · feature coalitions · local surrogate models

## How it works

- PL: Metody koalicyjne porównują predykcje dla różnych kombinacji cech względem wybranego tła. Lokalne modele zastępcze dopasowują prostą funkcję do perturbacji wejścia i przypisują cechom wkłady w odpowiedź.
- EN: Coalition-based methods compare predictions across feature combinations against a selected background. Local surrogate models fit a simple function to input perturbations and assign feature contributions to an answer.

## Limits

- PL: Wkłady zależą od definicji brakującej cechy i rozkładu tła. Skorelowane wejścia tworzą niejednoznaczności; atrybucja predykcji nie dowodzi przyczynowego wpływu w świecie.
- EN: Contributions depend on how missing features and background distributions are defined. Correlated inputs create ambiguity; prediction attribution does not prove real-world causal influence.

## Key terms

- PL: **koalicja cech**: Podzbiór wejść uwzględniony podczas porównania predykcji.
- PL: **model zastępczy**: Prosty model przybliżający zachowanie bardziej złożonego modelu.
- EN: **feature coalition**: A subset of inputs included when comparing predictions.
- EN: **surrogate model**: A simple model approximating a more complex model's behaviour.

## Know first

- [Uczenie nadzorowane (Supervised learning)](https://aiatlasgraph.com/t/supervised.md)
- [Rozkłady prawdopodobieństwa (Probability distributions)](https://aiatlasgraph.com/t/distributions.md)

## Examples

- PL: wartości Shapleya · SHAP · LIME · lokalny model zastępczy
- EN: Shapley values · SHAP · LIME · local surrogate model

## Related topics

Untyped, symmetric "see also" links.

- [Gry kooperacyjne i wartość Shapleya (Cooperative games and the Shapley value)](https://aiatlasgraph.com/t/shapleyvalue.md)
- [Kalibracja zaufania: cytaty, pewność i wyjaśnienia (Trust calibration)](https://aiatlasgraph.com/t/trustcalibration.md)
- [Wyjaśnianie decyzji kredytowych i równe traktowanie (Explaining credit decisions and fair lending)](https://aiatlasgraph.com/t/creditexplain.md)

## Sources

- [Interpretable Machine Learning: A Guide for Making Black Box Models Explainable (3rd edition)](<https://christophm.github.io/interpretable-ml-book/>) `molnar-iml-book-3ed` · by Christoph Molnar
- [A Unified Approach to Interpreting Model Predictions](<https://arxiv.org/abs/1705.07874>) `lundberg-lee-shap-2017` · by Scott M. Lundberg, Su-In Lee
- [“Why Should I Trust You?”: Explaining the Predictions of Any Classifier](<https://arxiv.org/abs/1602.04938>) `ribeiro-lime-2016` · by Marco Tulio Ribeiro, Sameer Singh, Carlos Guestrin

---

AI Atlas revision 122 (2026-10-30) · HTML: https://aiatlasgraph.com/t/featureattribution · index: https://aiatlasgraph.com/llms.txt · everything: https://aiatlasgraph.com/llms-full.txt · updated 2026-10-30
