Customizing the monitoring model settings
# Fetch the correct RuntimeConfiguration
config = sdk.monitoring.RuntimeConfiguration.get(model_id=model["id"])
# Now we can use this object to manipulate the monitoring model settings.
# Let's enable the Jensen-Shannon Univariate Covariate Shift method for our target values.
config.univariate_drift_method("JENSEN_SHANNON").enable_targets()
# Let's disable the Domain Classifier Multivariate Covariate Shift method
config.multivariate_drift_method("DOMAIN_CLASSIFIER_AUROC").disable()
# Let's set a constant threshold for the Missing Values data quality metric
config.data_quality_metric("MISSING_VALUES").set_threshold(threshold_type="CONSTANT", upper=5)
# Now apply the altered configuration
sdk.monitoring.RuntimeConfiguration.set(model_id=model["id"], config=config)Last updated