Files
timmy-talking-turd/.gitea/workflows/quality.yml
T
timmy 179f8fe6e9
Quality gates / quality (pull_request) Successful in 13m25s
feat(eval): score candidates against the release gates on held-out contributors (#29)
The ROADMAP gates (macro-F1 >= 0.80, precision@coverage >= 0.90, ECE <= 0.05) were prose with no
tool behind them. scripts/calibration_report.py now computes them from prediction records and
refuses input it cannot honestly score:

- a split is re-derived from the pseudonymous subject key with the ingestion rule, so a corpus
  cannot re-label its own splits; a contributor spanning two splits is refused before scoring
- the threshold is selected on validation only, and selecting on test or train is refused
- coverage, precision-at-coverage, macro-F1, per-class precision/recall, confusion, and expected
  calibration error are computed on accepted suggestions, with classes that abstained away named
  in excludedClasses instead of being scored as a silent zero
- exit codes carry the verdict: 0 GO, 3 BLOCKED, 2 refused

The release demo records the real harness against committed synthetic fixtures: a blocked
three-candidate comparison, a fixture engineered to clear every gate, and a leaked corpus refused.
Every number on the card is read back from the report the run wrote, and the captions state that
no model was measured, because a fixture is not evidence about accuracy.

The harness suite is wired into CI, check:syntax, and the release builder's own gates.
2026-10-25 11:05:28 +00:00

74 lines
2.0 KiB
YAML

name: Quality gates
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
quality:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Check out source
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- name: Install reproducibly
run: |
npm ci
python3 -m pip install --break-system-packages -r requirements-test.txt
- name: Install browser
run: npx playwright install --with-deps chromium
- name: Unit and security tests
run: |
npm test
python3 tests/staging-deploy.test.py -v
python3 tests/corpus-manifest.test.py -v
python3 tests/calibration-harness.test.py -v
- name: Mobile browser acceptance
run: |
npm start > /tmp/timmy-server.log 2>&1 &
server_pid=$!
trap 'kill "$server_pid"' EXIT
for attempt in $(seq 1 30); do
if curl --fail --silent http://127.0.0.1:4173/ > /dev/null; then
break
fi
if [ "$attempt" -eq 30 ]; then
cat /tmp/timmy-server.log
exit 1
fi
sleep 1
done
npm run test:ui
npm run test:photo
npm run test:mobile-capture
npm run test:sleek
npm run test:manual-fallback
npm run test:provisional
npm run test:followup
npm run test:vision-refusal
npm run test:worker-readiness
npm run test:pattern-summary
npm run test:photo-lifecycle
npm run test:training-contribution
npm run test:portability
- name: Dependency audit
run: npm audit --audit-level=high
- name: Syntax checks
run: |
npm run check:syntax
node --check tests/staging.acceptance.mjs
- name: Diff hygiene
run: npm run check:diff