Skip to content

Add CLAUDE.md as a short card for agent sessions - #127

Merged
NSchatz merged 1 commit into
mainfrom
harness/67-config-claude-md-short-card
Oct 20, 2026
Merged

NSchatz merged 1 commit into
mainfrom
harness/67-config-claude-md-short-card

Conversation

@NSchatz

@NSchatz NSchatz commented Oct 20, 2026

Copy link
Copy Markdown
Contributor

Adds this repo's first CLAUDE.md: a 59-line card (wc -l < CLAUDE.md prints 59) that an agent session reads first. It has four parts, in this order:

  1. What the repo is, in two sentences.
  2. The gate: the verify job's steps in ci.yml order, plus actionlint, with three notes for running them outside CI.
  3. The hazard: a change to the PHI-scan engine or the parser template can turn PHI detection off wherever they run, and no other repo's CI goes red.
  4. Rules: only rules a past failure proved, each with the PR behind it.

Nothing else changes. No other file linked to a section of a root CLAUDE.md, because there was none. No changeset: CLAUDE.md is in no package's files.

Every command the card names, and how it was checked (checked, not run)

Command or path in the card Kind Check
node scripts/changeset-guard.mjs file git ls-files scripts/changeset-guard.mjs: 1 file
node scripts/release-notes.mjs prepare --repo . --out "$RUNNER_TEMP/release-notes" file git ls-files scripts/release-notes.mjs: 1 file
node scripts/credential-surface.mjs file git ls-files: 1 file
node scripts/install-hardening.mjs file git ls-files: 1 file
node scripts/readme-check.mjs file git ls-files: 1 file
node scripts/drift-check.js file git ls-files: 1 file
node binary command -v node: /usr/local/bin/node. CI installs it with actions/setup-node
pnpm install --frozen-lockfile pnpm built-in command -v pnpm. CI installs pnpm with pnpm/action-setup
pnpm check:no-emdash, pnpm format:check, pnpm typecheck, pnpm lint, pnpm test, pnpm build, pnpm attw package.json scripts each one is in jq -r '.scripts | keys[]' package.json
actionlint binary command -v actionlint finds it on PATH. CI installs it through reviewdog/action-actionlint
git add, git ls-files binary command -v git
drift-manifest.json, packages/script-utils/phi-scan.js, packages/script-utils/CHANGELOG.md, documentation/decisions/0003-the-phi-scan-engine-gap-settlements.md, .github/workflows/no-emdash.yml files git ls-files <path>: 1 file each
scripts/parser-template/ directory git ls-files scripts/parser-template: 36 files
test/*scaffold*.test.ts files git ls-files 'test/*scaffold*.test.ts': 4 files
the release-dry-run job, fetch-depth: 0, persist-credentials: false workflow keys present in .github/workflows/ci.yml and in all three jobs of release.yml

Where each rule comes from

Some rules found in the CHANGELOG were left out: ones a gate already enforces mechanically (install hardening, the em-dash file gate), and the hand-promotion of package [Unreleased] sections, which today's package changelogs do not show being followed.

Gate

The full verify sequence plus actionlint was run locally on this branch with the card staged. Every step exits 0, and the tests pass: 1076 at the root, 50 in script-utils, 225 in process and 195 in test-utils. Two local quirks are written into the card's gate notes:

  • pnpm on PATH: a bare pnpm newer than 10.34.5 fails pnpm typecheck (ERR_PNPM_BAD_PM_VERSION) and one pax case in packages/test-utils/test/attw-gate.test.ts. That happens even on unchanged main. With pnpm 10.34.5 first on PATH, both pass.
  • drift-check.js: from a checkout whose directory is not named config, it exits 2, "nothing was graded". Run from a copy at <dir>/config/, it exits 0.

Follow-up, not in this PR

drift-manifest.json's configSubject.exemptions entry for agentDoc.agentDoc gives as its reason that config "carries no CLAUDE.md or AGENTS.md today". That stops being true once this merges. Deleting the entry would grade this card against the package baseline's five required headings, which a short card does not carry. Whether to drop the exemption or reword its reason is a separate change.

Harness-Task: 67

🤖 Generated with Claude Code

The repo had no agent doc. The card says what the repo is, the exact gate
behind the required checks (verify (22), verify (24), actionlint) in CI order,
the hazard that a change to the PHI-scan engine or the parser template turns
detection off wherever they run, and six rules, each with the PR that proved it.

59 lines. No changeset: CLAUDE.md is in no package's files.

Harness-Task: 67

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@NSchatz
NSchatz merged commit 5e33423 into main Oct 20, 2026
7 checks passed
@NSchatz
NSchatz deleted the harness/67-config-claude-md-short-card branch October 20, 2026 03:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant