Prerequisites
- A dataset with CI/CD enabled in AgentX settings.
- Your
AGENTX_API_KEYstored as a GitHub Actions secret. - Your
AGENTX_DATASET_ID— visible in the dataset settings page URL.
Workflow template
Save as.github/workflows/eval.yml in your repository:
Using a dedicated eval script
For larger test setups, use a separate script:Adding required status checks
To block merges when the gate fails:- Go to your GitHub repo → Settings → Branches
- Add a branch protection rule for
main - Enable Require status checks to pass before merging
- Add
eval / Evaluate agentas a required check
Viewing results
Every CI run is recorded in the CI Runs tab in your AgentX workspace, showing:- Gate result (PASS / FAIL) badge
- Per-question scores and justifications
- Branch, commit SHA, and PR number
- Threshold violations
Environment variables
| Variable | Description |
|---|---|
AGENTX_API_KEY | Your workspace API key |
AGENTX_DATASET_ID | Evaluation dataset ID with CI enabled |
GITHUB_HEAD_REF | PR branch name (set by GitHub Actions) |
GITHUB_SHA | Commit SHA (set by GitHub Actions) |
GITHUB_REF | Full ref string (set by GitHub Actions) |
GITHUB_REPOSITORY | org/repo (set by GitHub Actions) |

