For the complete documentation index, see llms.txt. This page is also available as Markdown.

Tutorial 3: Wire CI/CD quality gates

Tutorial 3 — Wire Stratix evaluations into GitHub Actions to gate AI changes.

Time: ~30 minutes Level: Intermediate You'll build: A GitHub Actions workflow that runs a Stratix evaluation on every PR and blocks merge on regression.

What you'll learn

  • How to call Stratix from a CI runner

  • How to compare a run against a baseline

  • How to fail a build on regression

Prerequisites

Step 1: Get an API key

In Stratix Premium → Settings → API keysNew key. Scope it to evaluation read/write. Copy the key.

In GitHub: Settings → Secrets and variables → Actions → New repository secret. Name: LAYERLENS_STRATIX_API_KEY.

Step 2: Create the CI script

scripts/ci-eval.py:

Step 3: Add the workflow

.github/workflows/eval.yml:

Step 4: Open a test PR

Make a small change to a prompt under src/prompts/. Push. Watch the GitHub Action run. Verify the eval kicks off.

Step 5: Tune the tolerance

Start strict (0.01). Loosen as you learn the natural variance of the evaluation. If you get false-positives on noise, you have two choices:

  • Increase tolerance

  • Make the eval less noisy (more rows, or a determined seed)

What's next

Last updated

Was this helpful?