Configure anomaly detection
This section outlines the steps to enable anomaly detection for your assets. The setup involves configuring it once for your space and then enabling anomaly detection for individual assets.
Space setup
This section outlines the steps to configure the anomaly detection package for your space. This is a one-time operation. The package is a Y42-customized version of the Elementary Data package (opens in a new tab).
Add the dbt-data-reliability package
To incorporate anomaly detection into your project space, add the following code into your packages.yml file:
To find the latest commit hash, navigate to the "Commits" section of the repository and use the "Copy" option.
You can find out more about installing and maintaining dbt packages here.
Configure dbt_project.yml
Add the following to the models section of your dbt_project.yml:
Commit changes
After updating packages.yml and dbt_project.yml, commit the changes.
Asset-level configuration
This section details how to enable anomaly detection for specific assets
Enabling anomaly detection for an asset
To update the .yml configuration of your source or model asset, modify the config and tests blocks as follows:
Commit changes
After updating the .yml, commit the changes.
Building an asset
When running an asset, anomaly detection behaves like standard tests. Findings are available in "Build details -> Test" section for review. To view them, navigate to "Build history" and select a specific run.
Anomaly detection test success.
Anomaly detection test failure.