Maintain AI-Q CI and Governance
Use this skill when a developer changes AI-Q's CI, pre-commit hooks, or
contributor governance — the GitHub Actions workflows, the pre-commit config,
CODEOWNERS, the CodeRabbit review config, the copy-pr-bot mirror, or the
product-level skill-eval harness. These surfaces gate every PR, so a change must
keep the gate working and must not weaken security or review rules.
Start Here
- Identify the surface: a workflow (
.github/workflows/), a pre-commit hook
(.pre-commit-config.yaml), governance (.github/CODEOWNERS,
.coderabbit.yaml, .github/copy-pr-bot.yaml), or the skill-eval harness
(.github/skill-eval/).
- Read the authoritative files below and
CONTRIBUTING.md "CI and Bot Workflow"
before editing — the bot/mirror flow is easy to break.
- Make the smallest change; do not weaken secret detection, auth gating, or
code-owner review without a prior design discussion (see
AGENTS.md).
- Remember CI runs on the copy-pr-bot mirror after
/ok to test, not on push.
Authoritative References
- CONTRIBUTING.md: "CI and Bot Workflow" — copy-pr-bot
mirroring to
pull-request/<N>, /ok to test, /nvskills-ci, /merge.
- AGENTS.md: "Git and PR hygiene" and the validation
commands CI mirrors.
.github/workflows/ci.yml: jobs pre-commit, test (pytest + coverage),
helm-lint, test-scripts. The pre-commit job runs Ruff separately and
skips the push-stage pytest and Helm hooks when it runs
pre-commit run --all-files — those checks run as their own jobs instead.
.github/workflows/ui.yml: jobs install, lint, type-check, unit-test,
build.
.github/workflows/skills-eval.yml: the Skills Eval gate (push +
workflow_dispatch; detect-changes path gate → generate-datasets spec
validation → harbor-eval on the self-hosted aiq-eval runner).
.github/workflows/request-nvskills-ci.yml: comment-triggered NVSkills CI.
.pre-commit-config.yaml: the hook set. Note pytest-root, pytest-mcp, and
helm-lint are stages: [push] (see the reference for what that means
locally). Root and MCP pytest checks use their own uv projects; MCP is not a
root dependency group.
.github/CODEOWNERS, .coderabbit.yaml, .github/copy-pr-bot.yaml: review
routing, path-scoped automated review, and the PR mirror.
Longer procedures live in this bundle:
- references/workflows-and-hooks.md: the
workflows, their jobs/triggers, the copy-pr-bot mirror flow, and the pre-commit
hook inventory (incl. the push-stage hooks).
- references/skill-eval-harness.md: how the
.github/skill-eval/ regression gate finds specs, runs adapters, and verifies.
Workflow
- Locate the exact workflow, hook, or governance file and read it plus the
relevant
CONTRIBUTING.md section.
- Make the smallest scoped change; keep job names, triggers, and the
detect-changes path gate intact unless that is the change.
- Lint the change: validate YAML and, for workflows, run
actionlint if it is
installed.
- Reproduce the affected gate locally where possible — run the pre-commit hooks
or the job's underlying command (see the references).
- Note that the real CI run happens on the copy-pr-bot mirror after a maintainer
comments
/ok to test.
- Summarize changed files and the local validation evidence.
Validation
uv run pre-commit run --all-files # default-stage hooks (NOT pytest/helm-lint)
uv run pre-commit run --all-files --hook-stage push # adds the push-stage pytest + helm-lint hooks
uv run pre-commit run --files <changed> # faster, during iteration
actionlint .github/workflows/<file>.yml # if actionlint is installed
Expected: hooks pass (or only auto-fix) and any edited workflow is valid YAML.
pytest and helm-lint are push-stage, so the default --all-files run skips
them — CI runs them as the dedicated test and helm-lint jobs. For skill-eval
changes, see the harness reference: full Harbor runs need the self-hosted runner,
so validate spec/adapter shape locally and rely on the mirrored CI run.
Common Mistakes
- Adding a trigger
paths: filter to skills-eval.yml instead of using the
detect-changes job — the comment in that workflow explains why path-filtering
the trigger is wrong here.
- Weakening
detect-secrets, auth gating, or code-owner review to make CI pass.
- Expecting CI to run on push; it runs on the copy-pr-bot mirror after
/ok to test.
- Assuming
pre-commit run --all-files reproduces the whole gate — pytest and
helm-lint are stages: [push], so they do not run at the default stage. Use
--hook-stage push (or run them directly), and remember CI runs them as
separate jobs.
- Editing
.github/CODEOWNERS without updating the paths it routes, so reviews
go to the wrong owners.
Related Skills
aiq-release-qa
aiq-prepare-pr
1---2name: aiq-maintain-ci3description: Use when changing AI-Q continuous integration, pre-commit, or contributor governance — editing .github/workflows/ (ci, ui, skills-eval, request-nvskills-ci), .pre-commit-config.yaml hooks, .github/CODEOWNERS, .coderabbit.yaml, copy-pr-bot, or the .github/skill-eval harness — and validating those changes without breaking the gate.4license: Apache-2.05---67# Maintain AI-Q CI and Governance89Use this skill when a developer changes AI-Q's CI, pre-commit hooks, or10contributor governance — the GitHub Actions workflows, the pre-commit config,11CODEOWNERS, the CodeRabbit review config, the copy-pr-bot mirror, or the12product-level skill-eval harness. These surfaces gate every PR, so a change must13keep the gate working and must not weaken security or review rules.1415## Start Here1617- Identify the surface: a workflow (`.github/workflows/`), a pre-commit hook18 (`.pre-commit-config.yaml`), governance (`.github/CODEOWNERS`,19 `.coderabbit.yaml`, `.github/copy-pr-bot.yaml`), or the skill-eval harness20 (`.github/skill-eval/`).21- Read the authoritative files below and `CONTRIBUTING.md` "CI and Bot Workflow"22 before editing — the bot/mirror flow is easy to break.23- Make the smallest change; do not weaken secret detection, auth gating, or24 code-owner review without a prior design discussion (see `AGENTS.md`).25- Remember CI runs on the copy-pr-bot mirror after `/ok to test`, not on push.2627## Authoritative References2829- [CONTRIBUTING.md](../../../CONTRIBUTING.md): "CI and Bot Workflow" — copy-pr-bot30 mirroring to `pull-request/<N>`, `/ok to test`, `/nvskills-ci`, `/merge`.31- [AGENTS.md](../../../AGENTS.md): "Git and PR hygiene" and the validation32 commands CI mirrors.33- `.github/workflows/ci.yml`: jobs `pre-commit`, `test` (pytest + coverage),34 `helm-lint`, `test-scripts`. The `pre-commit` job runs Ruff separately and35 skips the push-stage pytest and Helm hooks when it runs36 `pre-commit run --all-files` — those checks run as their own jobs instead.37- `.github/workflows/ui.yml`: jobs `install`, `lint`, `type-check`, `unit-test`,38 `build`.39- `.github/workflows/skills-eval.yml`: the Skills Eval gate (push +40 `workflow_dispatch`; `detect-changes` path gate → `generate-datasets` spec41 validation → `harbor-eval` on the self-hosted `aiq-eval` runner).42- `.github/workflows/request-nvskills-ci.yml`: comment-triggered NVSkills CI.43- `.pre-commit-config.yaml`: the hook set. Note `pytest-root`, `pytest-mcp`, and44 `helm-lint` are `stages: [push]` (see the reference for what that means45 locally). Root and MCP pytest checks use their own uv projects; MCP is not a46 root dependency group.47- `.github/CODEOWNERS`, `.coderabbit.yaml`, `.github/copy-pr-bot.yaml`: review48 routing, path-scoped automated review, and the PR mirror.4950Longer procedures live in this bundle:5152- [references/workflows-and-hooks.md](references/workflows-and-hooks.md): the53 workflows, their jobs/triggers, the copy-pr-bot mirror flow, and the pre-commit54 hook inventory (incl. the push-stage hooks).55- [references/skill-eval-harness.md](references/skill-eval-harness.md): how the56 `.github/skill-eval/` regression gate finds specs, runs adapters, and verifies.5758## Workflow59601. Locate the exact workflow, hook, or governance file and read it plus the61 relevant `CONTRIBUTING.md` section.622. Make the smallest scoped change; keep job names, triggers, and the63 `detect-changes` path gate intact unless that is the change.643. Lint the change: validate YAML and, for workflows, run `actionlint` if it is65 installed.664. Reproduce the affected gate locally where possible — run the pre-commit hooks67 or the job's underlying command (see the references).685. Note that the real CI run happens on the copy-pr-bot mirror after a maintainer69 comments `/ok to test`.706. Summarize changed files and the local validation evidence.7172## Validation7374```bash75uv run pre-commit run --all-files # default-stage hooks (NOT pytest/helm-lint)76uv run pre-commit run --all-files --hook-stage push # adds the push-stage pytest + helm-lint hooks77uv run pre-commit run --files <changed> # faster, during iteration78actionlint .github/workflows/<file>.yml # if actionlint is installed79```8081Expected: hooks pass (or only auto-fix) and any edited workflow is valid YAML.82`pytest` and `helm-lint` are push-stage, so the default `--all-files` run skips83them — CI runs them as the dedicated `test` and `helm-lint` jobs. For skill-eval84changes, see the harness reference: full Harbor runs need the self-hosted runner,85so validate spec/adapter shape locally and rely on the mirrored CI run.8687## Common Mistakes8889- Adding a trigger `paths:` filter to `skills-eval.yml` instead of using the90 `detect-changes` job — the comment in that workflow explains why path-filtering91 the trigger is wrong here.92- Weakening `detect-secrets`, auth gating, or code-owner review to make CI pass.93- Expecting CI to run on push; it runs on the copy-pr-bot mirror after94 `/ok to test`.95- Assuming `pre-commit run --all-files` reproduces the whole gate — `pytest` and96 `helm-lint` are `stages: [push]`, so they do not run at the default stage. Use97 `--hook-stage push` (or run them directly), and remember CI runs them as98 separate jobs.99- Editing `.github/CODEOWNERS` without updating the paths it routes, so reviews100 go to the wrong owners.101102## Related Skills103104- `aiq-release-qa`105- `aiq-prepare-pr`