> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.umnai.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.umnai.com/_mcp/server.

# Predictions and attributions

Predictions and attributions are the core signals in a local explanation.

A prediction is the model output for a query. Attributions explain how that prediction was built by showing how much each module, feature, or feature interaction contributed.

## Prediction

A prediction is the output of the model for a query.

For regression problems, the prediction is the sum of all [module attributions](#module-attributions) plus the model [intercept](../../explainable-neural-net-xnn#intercept).

For classification problems, the sum of all module attributions plus the intercept is compared with a threshold to determine the predicted class.

In both cases, the prediction is built from attributions. This is the first step in explaining how the model produced the output.

## Module attributions

Module attributions explain how much each feature or feature interaction contributed to a [prediction](#prediction).

An [XNN](../../explainable-neural-net-xnn) is composed of modules. Each module represents a feature or a feature interaction. When a query is run through the model, it activates one [partition](../../explainable-neural-net-xnn#partition) in every module.

The local neural model in the [rule](../../explainable-neural-net-xnn#rule) of each activated partition calculates the attribution of the feature or interaction represented by that module.

Module attributions can be positive or negative.

| Direction            | Meaning                              |
| -------------------- | ------------------------------------ |
| Positive attribution | The module increased the prediction. |
| Negative attribution | The module decreased the prediction. |

The sum of all module attributions is a direct representation of the prediction.

![Module attribution plot for a prediction](https://files.buildwithfern.com/umnai.docs.buildwithfern.com/77d2be04dcae1db6669205957db3a8cc95027db9a095cf014c61a7cddb879fd0/assets/images/module-attribution-plot-prediction.png)

![Module attribution table (top 15 modules only) showing attributions and activated partitions and rules](https://files.buildwithfern.com/umnai.docs.buildwithfern.com/f6eec8f1b730368726bb14136204834b20bb9c1c5a7c221e5392dbd758a7d174/assets/images/module-attribution-table-top-15.png)

## Feature attributions

Feature attributions explain how much each individual feature contributed to a [prediction](#prediction).

A feature can contribute directly through its own module and indirectly through interaction modules. To produce feature attributions, interaction module attributions are [decomposed](../../explainable-neural-net-xnn#decompositions) and grouped back to the features involved.

Like module attributions, feature attributions can be positive or negative.

| Direction            | Meaning                               |
| -------------------- | ------------------------------------- |
| Positive attribution | The feature increased the prediction. |
| Negative attribution | The feature decreased the prediction. |

Feature attributions provide a feature-level explanation of the prediction across all [modules](../../explainable-neural-net-xnn#module).

![Feature attribution plot for a prediction](https://files.buildwithfern.com/umnai.docs.buildwithfern.com/1b9e5aee2c98d117b4cbe9b1bc3cc3b164e0d356806f757ea44141923ed001dc/assets/images/feature-attribution-plot-prediction.png)

![Feature attribution table for a prediction](https://files.buildwithfern.com/umnai.docs.buildwithfern.com/a4defe633048d168b8cc7664bb484d5fffa85c385f5b0ecffe09cb19649d5924/assets/images/feature-attribution-table-prediction.png)

## Activations

Activations explain the path taken by a query through a model.

For a given query, activation data identifies which [partition](../../explainable-neural-net-xnn#partition) and embedded [rule](../../explainable-neural-net-xnn#rule) were activated in each [module](../../explainable-neural-net-xnn#module).

Activation data connects the prediction and attribution values back to the model structures that produced them.

Activations can also be aggregated across a [segment](../global-explanations/dataset#segments), across the entire dataset, or monitored in real time when a model is deployed for inference.