Use npm run validate as the repo readiness gate before starting or resuming a Turnfile experiment.
npm run validateRuns the full local gate:
npm run lint:turnfilenpm run lint:mailboxnpm run lint:prdsnpm run validate:skills:cinpm run evals
npm run evalsRuns fixture-based regression evals for the validators and exporters. The evals create temporary files and assert CLI exit codes plus stable output snippets.
npm run validate:skillsRuns strict skills preflight, including global Codex skill install checks. Use this on a configured local workstation. CI uses validate:skills:ci because global installs are environment-specific.
Turnfile evals fall into three categories. They serve different purposes and run through different commands.
- Repo readiness validators: the fixture-based regression evals run by
npm run validate(step 5,npm run evals). These assert validator and exporter behavior and gate whether the repo is ready to start or resume an experiment. - PRD implementation evals: the per-PRD acceptance suites under
evals/*.evals.mjs, run as an aggregate withnpm run evals:prd. These enforce the eight-step implementation loop (PRD-006) by proving each promoted PRD against the evals its proposer authored. - Focused PRD evals: a single PRD suite run directly with Node, for example
node --test evals/prd-032.evals.mjs. Use these when iterating on one PRD without running the full aggregate.
The aggregate runner is tools/run-prd-evals.mjs (the npm run evals:prd script). It resolves every file matching evals/*.evals.mjs, supports --dry-run introspection, and fails clearly when no PRD eval files are found. PRD suites whose registry implementation.state is not done, eval-verified, or grandfathered still run and are logged as expected-pending, but their result is excluded from the gate exit code. Implemented PRDs and non-PRD suites remain hard-gated.
- Run
npm ciafter dependency changes. - Run
npm run validate. - Confirm
working-session/MAILBOX.mdhas expected active messages and Open Queue state. - Regenerate
working-session/MAILBOX.jsonafter mailbox edits withnpm run export:mailbox. - Decide whether
working-session/is the active experiment workspace or whether the previous run should be archived underexamples/.
GitHub Actions runs npm ci on pushes to main and on pull requests, then runs npm run validate and npm run evals:prd as separate steps. The repo readiness gate and the PRD implementation evals are kept as distinct CI steps so a PRD eval regression and a readiness-gate failure are attributed independently. Both steps are release gates; expected-pending PRD suites are visible in the log but do not fail the release gate until their registry state advances.