Skip to content

Value Range

Why monitor value range?

Monitoring changes in the value range of numeric features / raw inputs helps to locate and examine anomalies in the model's input. For example, setting the monitor for a feature named hour_sin with the range -1 <= x <= 1 will help us discover issues in model input.

Detection Methods

For this monitor type, you can select the following detection methods:

Value Range Detection Methods

  • Absolute Values - The selected features / raw inputs are lower or higher than a specific value.
  • Change In Percentage - Detects change in a configured percentage between the values of the inspected data and the values reported in a time period before the data was collected.
  • Compared To Segment - Detects change in a configured percentage between the values of the inspected data and the values in a different data segment.
  • Compared To Training - Detects change in a configured percentage between the values of the inspected data and the values reported in the training set.

Configuration

Start from choosing the features / raw inputs you'd like to monitor. You can select as many as you want :-)

Value Range Configuration

Note that the monitor configuration may vary between the detection method you choose.

Creating this monitor using the REST API

POST https://app.aporia.com/v1beta/monitors
{
    "name": "Ensure valid age values",
    "type": "values_range",
    "scheduling": "*/5 * * * *",
    "configuration": {
        "configuration": {
            "focal": {
                "source": "SERVING",
                "timePeriod": "1h"
            },
            "metric": {
                "type": "histogram"
            },
            "actions": [
                {
                    "type": "ALERT",
                    "schema": "v1",
                    "severity": "MEDIUM",
                    "alertType": "values_range",
                    "description": "Unexpected values were detected in feature <b>'{field}'</b>. <br /> The values were observed in the <b>{model}</b> model, in version <b>{model_version}</b> for the <b>last {focal_time_period} ({focal_times})</b> <b>{focal_segment}</b>. <br /><br /> Based on defined limits, the values were expected to be <b>{value_thresholds}</b>, but values <b>{unexpected_values}</b> were received.",
                    "notification": [
                        {
                            "type": "EMAIL",
                            "emails": [
                                "dev@aporia.com"
                            ]
                        }
                    ],
                    "visualization": "values_candlestick_chart"
                }
            ],
            "logicEvaluations": [
                {
                    "max": 80,
                    "min": 16,
                    "name": "VALUES_RANGE"
                }
            ]
        },
        "identification": {
            "models": {
                "id": "seed-0000-fhpy"
            },
            "segment": {
                "group": null
            },
            "features": [
                "numeric_Age"
            ],
            "environment": null
        }
    }
}