Contribute to Giskard

Push your tests in Giskard repo

  • Clone the Giskard repository
  • Create a GitHub branch with the base as main, starting with test-contribution/name-of-your-branch
  • Write your test inside one of the classes (MetamorphicTests, HeuristicTests, PerformanceTests or DriftTests) inside this repo. If your test does not fit these classes, you can also create a custom class in a new file.
  • We recommend writing unit tests for your test functions: this is the way you can execute and debug your test! Unit tests should be placed in this directory.
Fixtures
A unit test is executed with a test model and test data provided as fixtures.
For example, in test_precision function, we use german_credit_data and german_credit_model as fixtures. If necessary, you can create your own fixtures; check this directory to know how.
  • To use this test on Giskard UI, we recommend you write the same code in the Giskard UI following these steps in our doc.
Even if your test works, it won’t appear in Giskard's frontend, unless you re-create it as a custom test in Giskard UI.
  • Create a Pull Request
Example
Let us guide you with an example where you want to create a heuristic test function:
Export as PDF
Copy link
Edit on GitHub