Skip to content

[codex] classify profile drift and remove private context #234

[codex] classify profile drift and remove private context

[codex] classify profile drift and remove private context #234

name: Skill Contract Strict Set
on:
pull_request:
paths:
- 'skills/**'
- 'scripts/**'
- 'profiles/**'
- 'hooks/**'
- 'tests/**'
- 'rules/**'
- 'docs/system/**'
- 'docs/project/**'
- 'docs/specs/**'
- 'README.md'
- 'requirements.txt'
- 'requirements.lock'
- '.github/workflows/skill-contract-pilot.yml'
push:
branches:
- main
paths:
- 'skills/**'
- 'scripts/**'
- 'profiles/**'
- 'hooks/**'
- 'tests/**'
- 'rules/**'
- 'docs/system/**'
- 'docs/project/**'
- 'docs/specs/**'
- 'README.md'
- 'requirements.txt'
- 'requirements.lock'
- '.github/workflows/skill-contract-pilot.yml'
permissions:
contents: read
jobs:
validate-pilot:
name: Validate Strict Skill Set
runs-on: ubuntu-24.04
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v6
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: '3.12'
- name: Install dependencies
run: |
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install --require-hashes -r requirements.lock
- name: Run regression tests
run: |
. .venv/bin/activate
python -m pytest tests/ -q
# Ships its own runner beside the skill rather than living in tests/, so
# `pytest tests/` does not collect it. Invoked directly until it is ported.
- name: Run skill-standardizer regression tests
run: |
. .venv/bin/activate
python3 skills/skill-standardizer/scripts/test_skill_standardizer.py
- name: Run strict contract checks on enforced skill set
run: |
. .venv/bin/activate
set +e
python3 skills/skill-evals/scripts/validate_skill_contract.py \
--skills-root skills \
--strict | tee strict-skill-contract-summary.txt
status=${PIPESTATUS[0]}
python3 skills/skill-evals/scripts/validate_skill_contract.py \
--skills-root skills \
--strict \
--json > strict-skill-contract-report.json
json_status=$?
if [ "$status" -ne 0 ] || [ "$json_status" -ne 0 ]; then
exit 1
fi
- name: Check skill version bumps
run: |
. .venv/bin/activate
if [ "$GITHUB_EVENT_NAME" = "pull_request" ]; then
base_ref="${{ github.event.pull_request.base.ref }}"
git fetch --no-tags origin "+refs/heads/${base_ref}:refs/remotes/origin/${base_ref}"
base="origin/${base_ref}"
else
base="${{ github.event.before }}"
fi
python3 skills/skill-evals/scripts/check_skill_versions.py --base "$base" --no-untracked
- name: Verify generated artifacts are in sync
run: |
. .venv/bin/activate
python3 scripts/gen_skill_docs.py --check
python3 scripts/generate_skills_manifest.py --check
python3 scripts/gen_harness_adapters.py --check --skip-symlinks
python3 scripts/gen_catalog.py --check
- name: Verify distribution profiles
run: |
. .venv/bin/activate
python3 scripts/profiles/ci_check.py
- name: Check for dangling links and skill references
run: |
. .venv/bin/activate
python3 scripts/check_links.py
- name: Scan authored prose for AI-slop
run: |
. .venv/bin/activate
python3 scripts/slop_scan.py
- name: Upload strict set report
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: strict-skill-contract-report
path: |
strict-skill-contract-report.json
strict-skill-contract-summary.txt