Strengths and weaknesses

Estimate prediction strength, uncertainty, and adjusted error.
View as Markdown

The Strengths and weaknesses view returns strength, uncertainty, and adjusted error metrics for a deployed model prediction.

Use it when you have both query inputs and target observations, and you want to understand whether the prediction appears strong, uncertain, or potentially unreliable.

When to use

Use caseDescription
Review prediction qualityEstimate how strong or weak a prediction is for a query row.
Inspect uncertaintyUse estimator disagreement to understand whether the prediction is uncertain.
Compare rows or segmentsRun the view for multiple query rows and compare strength, uncertainty, and adjusted error across them.
Enrich explanation workflowsUse strength and weakness metrics alongside attribution or decision-action views.

Generate the view

Generate the Strengths and weaknesses view from a deployed model.

POST
/deployed-models/:deployedModelId/views
curl -X POST https://api.hi.umnai.com/deployed-models/deployedModelId/views \
-H "X-Views-Cache-Control: no-cache, no-store" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"data": [
{
"view_type": "SAW"
}
],
"query": {
"age": [
58
],
"capital_45_gain": [
0
],
"capital_45_loss": [
0
],
"education": [
"HS-grad"
],
"educational_45_num": [
9
],
"fnlwgt": [
299831
],
"gender": [
"Male"
],
"hours_45_per_45_week": [
35
],
"marital_45_status": [
"Married-civ-spouse"
],
"native_45_country": [
"United-States"
],
"occupation": [
"?"
],
"race": [
"White"
],
"relationship": [
"Husband"
],
"workclass": [
"?"
]
},
"targets": {
"income": [
0
]
}
}'
Response
{
"data": [
{
"view_type": "SAW",
"justification_data": {
"columns": [
"0",
"1",
"query_id"
],
"index": [
0
],
"data": [
[
0.2735845447,
0.2705326141,
0
]
],
"foreign_keys": [],
"labels": [
"query_id"
],
"types": [
{
"data_type": "NUMBER",
"format": "FLOAT64"
},
{
"data_type": "NUMBER",
"format": "FLOAT64"
},
{
"data_type": "NUMBER",
"format": "INT64"
}
]
},
"output_version": {
"major_version": 1,
"minor_version": 2,
"patch_version": 1
},
"view_data": {
"columns": [
"strength",
"uncertainty",
"adjusted_error"
],
"index": [
0
],
"data": [
[
0.7279414206,
1,
0
]
],
"foreign_keys": [],
"labels": [],
"types": [
{
"data_type": "NUMBER",
"format": "FLOAT64"
},
{
"data_type": "NUMBER",
"format": "INT64"
},
{
"data_type": "NUMBER",
"format": "INT64"
}
]
},
"views_version": {
"major_version": 0,
"minor_version": 5,
"patch_version": 0,
"build_version": "dev76"
}
}
]
}

The request needs view_type set to SAW, query data aligned with the deployed model input schema, and target observations for the query rows.

Strengths and weaknesses require targets. Without target observations, the view cannot compute the prediction error metrics.

Output

The response follows the shared Response structure format.

The Strengths and weaknesses view returns two dataframes.

DataframeDescription
view_dataStrength, uncertainty, and adjusted error values for each query row.
justification_dataSupporting estimator prediction data used to calculate the metrics.

Interpret the result

The Strengths and weaknesses view is easiest to read by starting with strength, then using uncertainty and adjusted error to understand reliability.

Start with strength

Use strength to understand how strong the prediction is.

Higher values indicate a stronger prediction. Lower values indicate a weaker prediction and may deserve more careful review, especially if the row is important or high-impact.

Check uncertainty

Use uncertainty to understand estimator disagreement.

Higher uncertainty means the model’s estimators disagree more. This can indicate that the query row is in a region where the model is less stable or less confident.

Uncertainty is most informative for models with multiple estimators.

Review adjusted error

Use adjusted_error to understand the prediction error after adjustment.

This metric uses the target observation supplied in the request. It is useful when reviewing how well the prediction matched the observed outcome for a specific row or batch.

Compare rows

For batch queries, compare strength, uncertainty, and adjusted_error across rows.

Rows with low strength, high uncertainty, or high adjusted error are good candidates for review. Rows with high strength and low uncertainty are usually easier to trust, although they should still be interpreted in context.

Use with attribution views

Use Strengths and weaknesses together with Feature attribution, Module attribution, or Decision actions.

Attribution views explain what contributed to the prediction. Strengths and weaknesses help you understand whether that prediction appears strong, uncertain, or error-prone.

Options

The Strengths and weaknesses view supports options for error calculation and scaling.

OptionUse
winsorize_limitConfigure the winsorization limit used for adjusted error calculations.
scaledScale predictions and targets between 0 and 1 when supported by the view configuration.

Winsorization

Use winsorize_limit to control how extreme values are handled when calculating adjusted error.

This can reduce the influence of outliers in error-related calculations.

Scaling

Use scaled when you want predictions and targets scaled between 0 and 1 for the calculation.

This can make metrics easier to compare across targets or model outputs when scaling is appropriate.

Field reference

The Strengths and weaknesses view returns dataframes, so individual columns are not documented as standalone API schema properties.

view_data

The view_data dataframe contains the primary strength and weakness metrics.

FieldDescription
strengthStrength of the prediction. Higher values indicate a stronger prediction.
uncertaintyUncertainty of the prediction, based on estimator disagreement. Higher values indicate more uncertainty.
adjusted_errorAdjusted prediction error calculated using the supplied target observation.

justification_data

The justification_data dataframe contains supporting estimator prediction data.

Field patternDescription
<estimator_index>Prediction output from the estimator at that index.
query_idQuery row identifier used to connect estimator predictions to the corresponding result row.