pi-agent-dashboard / scripts
AGENTS.md312 starsChanged 4 months agoMITView on GitHub
Files in this directory. One row per file. Non-source area (migrated from docs/file-index-skills-misc.md; source of truth now here). See change: migrate-file-index-to-agents-tree.
- Deletes or force-pushes
- Installs packages
In this repository12 other files it gives its agents.
- AGENTS.mdAGENTS.md
- docker/AGENTS.mdAGENTS.md
- docs/AGENTS.mdAGENTS.md
- .github/verdaccio/AGENTS.mdAGENTS.md
- .github/workflows/AGENTS.mdAGENTS.md
- mockups/AGENTS.mdAGENTS.md
- presentations/AGENTS.mdAGENTS.md
- public/AGENTS.mdAGENTS.md
- qa/AGENTS.mdAGENTS.md
- spike/AGENTS.mdAGENTS.md
- tests/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
The file
Files
DOX — scripts
Files in this directory. One row per file. Non-source area (migrated from docs/file-index-skills-misc.md; source of truth now here). See change: migrate-file-index-to-agents-tree.
| File | Purpose | ||
__tests__/assert-bundled-plugins-complete.test.mjs | Vitest unit tests for packages/electron/scripts/assert-bundled-plugins-complete.mjs (subprocess-driven with… → see __tests__/assert-bundled-plugins-complete.test.mjs.AGENTS.md | ||
__tests__/assert-bundled-server-plugin-load.test.mjs | Tests for packages/electron/scripts/assert-bundled-server-plugin-load.mjs (X13): the bundle layout contract (SERVER_BUNDLE_DIR override, win32 node.exe, missing-file reporting) and the log verdict (loaded / present-but-dead / vacuous-green), and logTail (last-N lines, empty-log marker). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/check-kb-dist-fresh.test.mjs | C1 (fix-kb-eval-measurement-integrity): fault-injection via --pkg sandbox — clean fingerprint → exit 0; src/tsconfig edited after committed build or fingerprint missing → non-zero + mandated message. | ||
__tests__/check-pi-settings-paths.test.mjs | Drives absoluteSourceViolations directly (12 cases) so detection is pinned independently of what .pi/settings.json currently holds. Negative cases carry the weight: npm:/git:/https:///ssh:// sources and the bare-string package form must NOT be flagged, else the guard is unusable. See issue #371. | ||
__tests__/biome-undeclared-dependencies.test.mjs | Guardrails for the noUndeclaredDependencies config in biome.json. → see __tests__/biome-undeclared-dependencies.test.mjs.AGENTS.md | ||
__tests__/dependency-declarations.test.mjs | Set-based manifest guarantees over ALL 32 non-private workspaces (not a sample). → see __tests__/dependency-declarations.test.mjs.AGENTS.md | ||
__tests__/fixtures/mutation-journal-child.mjs | Child-process fixture for the mutation-journal crash-safety tests. → see __tests__/fixtures/mutation-journal-child.mjs.AGENTS.md | ||
__tests__/merge-latest-mac.test.mjs | Covers test-plan U6 for merge-latest-mac.py: the minimumSystemVersion update gate survives the arm64 + x64 merge, every arch DMG stays in files[], extra legs are consumed, and a LEG-ASYMMETRIC injection (or a value disagreement) is REJECTED in both glob orders rather than silently inheriting from whichever file the glob yielded first. Skips when python3/pyyaml is absent. See change: upgrade-electron-runtime. | ||
__tests__/seed-settings-compaction.test.mjs | Unit tests for the e2e-only compaction.keepRecentTokens seed (change: replay-compaction-boundary): merge decision-table (fresh write, sibling-key preservation, no-clobber, unrelated top-level keys kept) + the file wrapper's corrupt-file / absent-path / idempotent cases. | ||
__tests__/nightly-report.test.mjs | Nightly report (X9–X11). → see __tests__/nightly-report.test.mjs.AGENTS.md | ||
__tests__/select-affected-tests.test.mjs | Selector layers (E1–E27). → see __tests__/select-affected-tests.test.mjs.AGENTS.md | ||
__tests__/select-affected-tests-cli.test.mjs | Selector CLI (X2–X8). → see __tests__/select-affected-tests-cli.test.mjs.AGENTS.md | ||
__tests__/select-affected-tests-graph.test.mjs | Real-tree graph build (X1, P1). → see __tests__/select-affected-tests-graph.test.mjs.AGENTS.md | ||
__tests__/test-selection-data.test.mjs | Selection data contract (E29). → see __tests__/test-selection-data.test.mjs.AGENTS.md | ||
__tests__/fixed-tick-waits.test.mjs | Guard tests + vitest wrapper for check-fixed-tick-waits.mjs (test-plan E10-E14, P3, X5): barrier detection incl. resolve/reject param names and helper scope, test-file-only scope, per-occurrence opt-out (E11) that never waives a later barrier (E12), real client census = 0 violations (E13), spawn exit-code contract with the file named on stderr (E14), < 2 s census wall-clock (P3), standalone-step/wrapper agreement (X5). Fixtures in mkdtemp outside the repo, cleaned in afterAll. See change: make-test-suite-deterministic. | ||
__tests__/jiti-cjs-transpile-safety.test.mjs | Repo gate: jiti CJS transpile safety. → see __tests__/jiti-cjs-transpile-safety.test.mjs.AGENTS.md | ||
__tests__/kb-packaging.test.mjs | C2 (fix-kb-eval-measurement-integrity, ci-level behind RUN_CI_SCENARIOS=1): npm pack --dry-run of packages/kb after a real build must carry bin/kb.mjs, bin/lib/engine-fingerprint.mjs, engine-fingerprint.json, dist/cli.js, src/ — and no __tests__. | ||
__tests__/knip-config.test.mjs | Entry-point rooting for the dead-code oracle (test-plan #G1, #G2, #G4, #D1, #P2). → see __tests__/knip-config.test.mjs.AGENTS.md | ||
__tests__/knip-harness.test.mjs | Docker-harness reproducibility for the dead-code oracle (test-plan #H1). → see __tests__/knip-harness.test.mjs.AGENTS.md | ||
__tests__/lint-harness-scoping.test.mjs | Guards that repo-wide lint harnesses judge git-tracked SOURCE, not local-only working-tree state. Covers parseBiomeReport/runBiomeRule tolerating Biome's non-zero exit (one untracked unparseable file used to kill 4 tests in lint-ledger + async-semantics-guards), knip workspace derivation seeing only tracked manifests (leaked .worktrees/, gitignored bundled-extensions/, .pi/npm/), and skill-frontmatter judging only tracked SKILL.md. All 4 failure modes are invisible in CI's clean checkout and fire only on a developer's disk. Biome fixture lives under node_modules/.cache/ so npx resolves the binary and parallel scans skip it. | ||
__tests__/knip-ratchet.test.mjs | Per-class dead-code ratchet (test-plan #R1-#R6). Load-bearing case is #R2: a scalar total lets one deleted… → see __tests__/knip-ratchet.test.mjs.AGENTS.md | ||
__tests__/z-layer-lint.test.mjs | Overlay z-index ratchet tests (test-plan #E4/#E5): extractRawZ matches raw numeric z but not word z-<layer> utilities; ratchetDecision rejects a NEW raw-z / increased count, allows shrinking. See change: add-overlay-layering-system. | ||
__tests__/knip-scan.test.mjs | Live whole-workspace Knip scan assertions (test-plan #G3, #G5, #G6, #D2, #D3, #P1). → see __tests__/knip-scan.test.mjs.AGENTS.md | ||
__tests__/mutation-journal.test.mjs | Vitest crash-safety tests for the mutation-harness journal (test-plan #E1-#E8, #X1-#X13). → see __tests__/mutation-journal.test.mjs.AGENTS.md | ||
__tests__/nightly-verdaccio-publish.test.mjs | Vitest unit tests for scripts/nightly-verdaccio-publish.mjs pure helpers: nextPatch (0.6.1→0.6.2, ignores… → see __tests__/nightly-verdaccio-publish.test.mjs.AGENTS.md | ||
__tests__/qa-smoke-guards.test.mjs | Fault-injects the clean-prefix QA smoke (qa/tests/35-plugin-install-load.sh) by stubbing npm/pi-dashboard/curl on PATH, so every anti-vacuity guard is driven deterministically on any machine. Pins X8 (empty prefix FAILS), X9 (throwing server entry FAILS while the smoke wrote enabled:true), X10 (loaded:false with NO status.error does NOT fail; status.error DOES), X11 (a /plugins/ path outside the prefix FAILS), plus failed-install and never-200-health guards. Supplies minimal REAL fixture tarballs for both the dashboard and the plugin, because the smoke's local-tarball mode unpacks the plugin and identifies specs by reading their package.json (a registry spec would make tar -xzOf fail inside the smoke). Repo root derives from import.meta.url, not process.cwd(). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/rebuild-scripts-gate.test.mjs | X5 fault injection: both rebuild-restart.sh and rebuild-and-restart.sh run the served-client gate between build and restart and abort NON-ZERO on refusal, with npm/pi-dashboard recording stubs on PATH plus a node stub that refuses the sync step — neither restart/reload stub is invoked. See change: add-served-build-coherence-and-hash-parity. | ||
__tests__/repair-meta-source.test.mjs | Vitest unit tests for repair-meta-source.mjs. Asserts source:"dashboard" → cleaned (other fields preserved),… → see __tests__/repair-meta-source.test.mjs.AGENTS.md | ||
__tests__/review-changes-parser.test.mjs | Vitest unit tests for parseFindings + splitFindings (.pi/skills/implement/scripts/parse-findings.ts). → see __tests__/review-changes-parser.test.mjs.AGENTS.md | ||
__tests__/severity-literal-guard.test.mjs | Static guard: no raw red-<NN(N)> Tailwind literal (2- or 3-digit shade, so red-50 is caught too) in the… → see __tests__/severity-literal-guard.test.mjs.AGENTS.md | ||
__tests__/ship-it-manifest.test.mjs | Vitest unit tests for ship-it manifest.ts (.pi/skills/ship-it/scripts/). → see __tests__/ship-it-manifest.test.mjs.AGENTS.md | ||
__tests__/ship-it-no-weakening.test.mjs | Vitest unit tests for ship-it no-weakening.ts assertNoWeakening. → see __tests__/ship-it-no-weakening.test.mjs.AGENTS.md | ||
__tests__/skill-frontmatter.test.mjs | Vitest guard over every repo **/SKILL.md (skips node_modules/dist/worktrees). → see __tests__/skill-frontmatter.test.mjs.AGENTS.md | ||
__tests__/spec-collateral.test.mjs | L1 for spec-collateral.mjs (E1–E26, P1–P2, X1–X5). → see __tests__/spec-collateral.test.mjs.AGENTS.md | ||
__tests__/sync-served-client.test.mjs | E15/E16/X3/X4: the sync-served-client.mjs outcome table over temp dirs — no-op (dest == source, source must be described), mirror+verify incl. superseded-asset removal, legacy adopt, API-only success, undescribed/malformed source refusal, non-client-build refusal, EACCES refusal with no partial write, and a post-copy mismatch reported as refusal (injected copyTree skips the declaration). See change: add-served-build-coherence-and-hash-parity. | ||
__tests__/verify-release-deps-client-build-deps.test.mjs | Vitest tests for the E7 client build-dep rules in verify-release-deps.mjs. → see __tests__/verify-release-deps-client-build-deps.test.mjs.AGENTS.md | ||
__tests__/theme-token-guard.test.mjs | Scan/ratchet/bootstrap tests for all three guard arms. → see __tests__/theme-token-guard.test.mjs.AGENTS.md | ||
__tests__/test-up-oversubscribe-guard.test.mjs | Vitest tests for the co-resident harness oversubscription guard (change: stabilize-browser-e2e, #451 part 2) + list_running_harness_projects/parse_memory_bytes/human_bytes in docker/lib-ports.sh. docker stubbed on PATH (records every argv; no daemon touched): (a) peer up + MemTotal 8 GiB + default MEM_LIMIT → exit non-zero, names the peer + 2 × 4 GiB/8 GiB, no compose up call, no state file written; (b) PI_HARNESS_ALLOW_OVERSUBSCRIBE=1 → proceeds, one warning; (c) MemTotal 16 GiB → proceeds, one warning; (d) no peer / non-harness peer → silent; (e) docker info fails or MEM_LIMIT unparseable → warns + proceeds. Uses spawnSync (NOT execFileSync) so stderr warnings on the exit-0 paths are captured. | ||
__tests__/test-up-port-derivation.test.mjs | Vitest tests for parallel-worktree test-harness port/project derivation. → see __tests__/test-up-port-derivation.test.mjs.AGENTS.md | ||
_windows-introspection-probe.ts | Probe child for Windows introspection smoke. Imports real isVirtualMachine + defaultGetCmdline (relative… → see _windows-introspection-probe.ts.AGENTS.md | ||
build.sh | Type-check + build dashboard. Flags: --check-only (tsc --noEmit only), --client-only (Vite build only). Auto-runs npm install if node_modules absent. | ||
__tests__/verify-published-imports.test.mjs | Tests for verify-published-imports.mjs. Fixtures built in mkdtemp OUTSIDE the repo and the checker driven… → see __tests__/verify-published-imports.test.mjs.AGENTS.md | ||
__tests__/patch-vendor-specifiers.test.mjs | Tests for patch-vendor-specifiers.mjs (E6: 4-specifier rewrite, byte-identical tree across run counts 1/2/3, §4(b) header exactly once, unmapped + stale-notice failures). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/root-packaging.test.mjs | ci-level root tarball exclusion check (E14/E15). → see __tests__/root-packaging.test.mjs.AGENTS.md | ||
__tests__/refresh-vendor.test.mjs | Tests for refresh-vendor.mjs (X3: an unfaithful stubbed fetch aborts before patching with tree + manifest untouched; a faithful one verifies → patches → rehashes preserving upstream). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/vendor-specifiers.test.mjs | Tests for check-vendor-specifiers.mjs (E1/E2/X4: the patched tree passes non-vacuously; @protocol//@injected/ fixtures rejected; a re-copy that skipped the patch fails on both files). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/verify-plugin-install-load.test.mjs | Tests for verify-plugin-install-load.mjs (E8 scope filter always; X1/X2/X6 pack→install→import opt-in via RUN_INSTALL_LOAD=1). See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/verify-docker-plugin-load.test.mjs | Tests for verify-docker-plugin-load.mjs (X12): harness-state parsing, the load verdict (missing success line, unexpected failure lines, the seeded e2e-broken fixture allowlist, verdict polling), the JITI_* crutch check, and teardown on the failing path. See change: fix-browser-plugin-vendor-specifier-resolution. | ||
__tests__/vitest-workers.test.mjs | Guard over the vitest worker consolidation (test-plan E15-E17, P1): no config restates the parallel target as a literal (allowed values: 1, PARALLEL_MAX_WORKERS), ≥27 configs import the shared module, serial projects declare maxWorkers: 1 and do NOT import it, all importers use relative specifiers and no package.json references the module, and every config still resolves to its pre-consolidation worker count via a live config-import census. See change: make-test-suite-deterministic. | ||
check-conventions.mjs | Deterministic half of the ship gate, run by ship-it step 4.4. → see check-conventions.mjs.AGENTS.md | ||
check-e2e-fixture-import.mjs | Guard: every tests/e2e/*.spec.ts MUST import test from ./fixtures.js, never @playwright/test directly… → see check-e2e-fixture-import.mjs.AGENTS.md | ||
check-fixed-tick-waits.mjs | Fixed-tick wait guard, run by ci.yml (standalone step) + ship gate. Bans await new Promise((r) => setTimeout(r, …)) barriers in client test files; per-occurrence opt-out marker // fixed-tick-waits: opt-out — <reason> on the line directly above. Exports analyzeFixedTickWaits(root), CLIENT_SRC, REPO_ROOT. Exit non-zero iff ≥1 violation; violations named on stderr. See change: make-test-suite-deterministic. | ||
check-kb-dist-fresh.mjs | CI gate (ci.yml, ship-it 4.4-adjacent): recomputes kb srcHash+tsconfigHash vs the committed packages/kb/engine-fingerprint.json; mismatch → non-zero + "the kb bin and the extension would run different engines — rebuild and commit the fingerprint". --pkg <dir> sandbox override for the fault-injection tests. dist/ is gitignored so a CI build can never observe lag — the committed fingerprint can. See change: fix-kb-eval-measurement-integrity. | ||
check-pi-settings-paths.mjs | Guard, run by ci.yml: no machine-specific absolute path in a committed .pi/settings.json packages[].source. Exports absoluteSourceViolations(file, raw), CHECKED_FILES, CORRECTION, REPO_ROOT. Flags POSIX /x, Windows C:\x/UNC, and ~/x; leaves npm:/git:/https:///ssh:// specifiers alone; unparseable JSON fails closed. Needed because pi install <path> and pi config WRITE the absolute form, so a one-time correction regresses. See issue #371. | ||
check-skill-frontmatter.mjs | Skill frontmatter guard, run by ci.yml. Exit non-zero iff >=1 error; warnings never fail. → see check-skill-frontmatter.mjs.AGENTS.md | ||
check-vendor-specifiers.mjs | Static specifier guard for the vendored relay: every import under relay/vendor/ must be a builtin, a declared dep, or relative. → see check-vendor-specifiers.mjs.AGENTS.md | ||
commit-windows-parity.sh | Stages and commits fix-windows-server-parity + consolidate-platform-handlers work in 5 logical chunks (fix:,… → see commit-windows-parity.sh.AGENTS.md | ||
dox-byte-gate.mjs | AGENTS.md byte-cap gate for ship-it step 4.4. Filters kb dox lint --json to kind:"over-threshold" +… → see dox-byte-gate.mjs.AGENTS.md | ||
fix-pty-permissions.cjs | Postinstall: fix node-pty spawn-helper execute permissions | ||
generate-plugin-registry.mjs | Standalone generator for packages/client/src/generated/plugin-registry.tsx (gitignored). → see generate-plugin-registry.mjs.AGENTS.md | ||
i18n-lint.mjs | Hardcoded-UI-string lint. → see i18n-lint.mjs.AGENTS.md | ||
rebuild-and-restart.sh | Build → verify served client → pi-dashboard restart → npm run reload. Twin of rebuild-restart.sh; BOTH run the gate so it cannot be bypassed by picking the other script. See change: add-served-build-coherence-and-hash-parity. | ||
rebuild-restart.sh | Build (+ optional --check tsc) → verify served client (node scripts/sync-served-client.mjs) → pi-dashboard restart → ./scripts/reload-all.sh. set -euo pipefail aborts before any restart/reload when built ≠ served. See change: add-served-build-coherence-and-hash-parity. | ||
refresh-vendor.mjs | Owns the vendored-relay refresh: copy → verify upstream (in memory, before any write) → patch → rehash. → see refresh-vendor.mjs.AGENTS.md | ||
sync-served-client.mjs | Resolves the served destination via the SERVER's resolveStaticClientDir (jiti) and mirrors the fresh packages/client/dist into it when they differ (superseded assets pruned AFTER the copy), then verifies both declarations equal. Refuses non-zero on an undescribed source, a non-client-build destination, EACCES, or a post-copy mismatch; adopts a legacy declaration-less destination; API-only is an explicit success. See change: add-served-build-coherence-and-hash-parity (design D5). | ||
heap-probe.mjs | CDP heap probe for a RUNNING dashboard: SIGUSR1s the pid (from --pid or /api/health), attaches to… → see heap-probe.mjs.AGENTS.md | ||
lib-jiti-scope.mjs | Discovery rule + AST detector behind the jiti-cjs-transpile-safety gate. Scope is a DERIVED RULE… → see lib-jiti-scope.mjs.AGENTS.md | ||
lib/kb-engine-fingerprint.mjs | Repo-facing re-export of packages/kb/bin/lib/engine-fingerprint.mjs (the ONE implementation — shipped via the tarball's bin, so the bin shim and this gate share bytes). See change: fix-kb-eval-measurement-integrity. | ||
lib/smoke-spawn-session.mjs | Test helper: connects dashboard browser WS (/ws), sends spawn_session for cwd, waits for… → see lib/smoke-spawn-session.mjs.AGENTS.md | ||
knip-config.mjs | Derives Knip entry points from the project's own manifest conventions and fails when knip.json does not… → see knip-config.mjs.AGENTS.md | ||
knip-ratchet.mjs | Per-class dead-code ratchet for ship-it step 4.4 and the nightly job. → see knip-ratchet.mjs.AGENTS.md | ||
windows-forbidden-subjects-smoke.ts | Windows-only smoke (_smoke.yml Windows leg): forbiddenGrantSubjects() lists host %SystemRoot%, no /-rooted or `\etc | usr | var` junk; skips off Windows. See change: surface-denial-remedy-in-previews (test-plan #E24). |
z-layer-lint.mjs | Overlay z-index ratchet (spec overlay-layering). Freezes raw numeric z-[NNNN]/z-<n> in packages/client/src (excl. tests) as z-layer-baseline.json; FAILS on a NEW occurrence outside the z-<layer> token utilities. Baseline = migration backlog, may only shrink. --write-baseline regenerates. Exports extractRawZ/scanRawZ/ratchetDecision. Wired into quality:changed + z-layer:lint. See change: add-overlay-layering-system. | ||
z-layer-baseline.json | Frozen baseline for z-layer-lint.mjs — the current raw-z occurrences (Tier-B inline popovers + FilePreviewOverlay + in-flow decorations) permitted until migrated. See change: add-overlay-layering-system. | ||
maybe-patch-package.cjs | postinstall guard: runs patch-package only when module resolvable + patches/ dir exists. → see maybe-patch-package.cjs.AGENTS.md | ||
merge-latest-mac.py | Merges the arm64 + x64 latest-mac.yml update-metadata legs into one file (softprops dedups release assets by basename, so without a merge one arch overwrites the other). Extracted from an inline heredoc in publish.yml so its semantics are testable. Unions files[] by url; mirrors path/sha512 from the first entry for legacy readers. minimumSystemVersion (the macOS update gate) is NOT inherited from the glob-first leg: every leg must agree or the merge FAILS, so the shipped gate cannot depend on glob order. Rewrites argv[1], deletes the rest; single-path call is a no-op. Locked by __tests__/merge-latest-mac.test.mjs. See change: upgrade-electron-runtime. | ||
measure-replay-compaction.mjs | Measures the compact-warm-replay-stream (#399) win: events / bytes / batches / wall time, before vs after… → see measure-replay-compaction.mjs.AGENTS.md | ||
migrate-child-process-imports.sh | One-shot sed migration: rewrites from "node:child_process" to platform/exec wrapper. → see migrate-child-process-imports.sh.AGENTS.md | ||
mutation-harness.mjs | Manifest-driven mutation runner for the promise-rule ladder: breaks a covered behaviour in a real source file… → see mutation-harness.mjs.AGENTS.md | ||
mutation-journal-global-setup.mjs | Root-level vitest globalSetup (registered in the ROOT vitest.config.ts) that reconciles mutation-harness… → see mutation-journal-global-setup.mjs.AGENTS.md | ||
nightly-verdaccio-publish.mjs | Nightly Verdaccio publish: bump every non-private workspace + root to <base>-nightly.<YYYYMMDD>.<sha7> (or… → see nightly-verdaccio-publish.mjs.AGENTS.md | ||
nightly-verdaccio-serve.mjs | Start an ephemeral Verdaccio as a detached background service (spawn detached+unref+stdio:ignore — cross-OS,… → see nightly-verdaccio-serve.mjs.AGENTS.md | ||
probe-harness-memory.mjs | Out-of-band harness memory probe (host side): docker exec reads cgroup v2 memory.* + pids.current and… → see probe-harness-memory.mjs.AGENTS.md | ||
prune-orphan-worktrees.ts | One-shot: rm -rf orphan .worktrees/* husk dirs (on disk, absent from git worktree list) left by kb DB… → see prune-orphan-worktrees.ts.AGENTS.md | ||
patch-vendor-specifiers.mjs | Rewrites the vendored relay's playwright-internal specifiers to package-relative shims/*.js paths + §4(b) notice; idempotent, fail-closed. → see patch-vendor-specifiers.mjs.AGENTS.md | ||
reload-all.sh | Build bridge + reload all pi sessions | ||
repair-main-specs.mjs | Structural repair of corrupted openspec/specs/**/spec.md. Exports classifySpec, repairSpecText, PLACEHOLDER; CLI takes --dry-run, --specs-dir. Promotes the FIRST delta header to ## Requirements and DELETES every subsequent one (parser reads only the first section, so renaming yields a silently-ignored duplicate); wraps orphaned ### Requirement: blocks in a created section; inserts TODO(repair):-marked Purpose + h1; REFUSES ## REMOVED Requirements (exit non-zero, file untouched); re-validates after write to surface phase-two errors the no-purpose throw masked. Idempotent. Blank-run collapse is fence-aware. See change: repair-corrupted-main-specs. | ||
repair-meta-source.mjs | Removes source: "dashboard" from every ~/.pi/agent/sessions/**/*.meta.json. Atomic tmp+rename. → see repair-meta-source.mjs.AGENTS.md | ||
seed-sessions-window.mjs | E2E-only seed: writes >120 ended session .meta.json/.jsonl records across dummy dirs plus one out-of-window stub dir, so the windowed snapshot + sessions_page stub group are exercised. Exports seedSessionsWindow(root) (idempotent) + SEED_SESSIONS_COUNT/STUB_SESSION_ID/STUB_DIR_CWD. Called by docker/test-entrypoint.sh under PI_E2E_SEED. See change: fix-connect-snapshot-frame-loss. | ||
seed-settings-compaction.mjs | E2E-only seed: writes compaction.keepRecentTokens (default 1) into pi settings.json so a manual /compact finds a cut point after a few small turns — the shipped 20000 would force the replay-boundary specs to build ~80 KB transcripts. Exports pure mergeE2ECompaction(cfg)→{cfg,changed} (no-clobber, preserves sibling compaction keys) + seedFile(path) (missing→{}, unparseable→untouched, writes+logs only on change). Called by docker/test-entrypoint.sh under PI_E2E_SEED. See change: replay-compaction-boundary. | ||
seed-settings-default-model.mjs | Seeds pi settings.json with SPLIT defaultProvider+defaultModel so faux is the startup default (pi 0.84 no longer resolves a combined defaultModel). Exports pure mergeDefaultModel(cfg)→{cfg,changed} (gated on absent defaultProvider; splits a combined defaultModel on FIRST /; else pins faux/faux-1) + seedFile(path) (missing→{}, unparseable→untouched exit 0, writes+logs only on change). Called by docker/test-entrypoint.sh. See change: split-faux-seed-default-provider. | ||
select-affected-tests.mjs | Affected-test selector CLI. → see select-affected-tests.mjs.AGENTS.md | ||
test-selection/ | Selector modules + data. → see test-selection/AGENTS.md | ||
spec-collateral.mjs | Advisory OpenSpec post-archive contradiction scan; exit 0/2, never 1. → see spec-collateral.mjs.AGENTS.md | ||
split-large-agents.mjs | One-off Node script. Splits over-large directory AGENTS.md file-based. → see split-large-agents.mjs.AGENTS.md | ||
stop-dashboard.sh | Stops pi-dashboard server. Reads port from ~/.pi/dashboard/config.json (default 8000); lsof -ti :PORT; SIGTERM, SIGKILL fallback after 5s. | ||
sync-versions-spec.js | Pure helper extracted from sync-versions.js for unit tests. → see sync-versions-spec.js.AGENTS.md | ||
sync-versions.js | Post-bump release helper. Reads every workspace package.json, enforces lockstep versions, rewrites every… → see sync-versions.js.AGENTS.md | ||
test-standalone-npm-install-docker.sh | Docker smoke: packs workspaces + root, launches clean Linux container (default node:24-bookworm-slim),… → see test-standalone-npm-install-docker.sh.AGENTS.md | ||
test-standalone-npm-install.ps1 | Windows port of standalone-npm-install smoke. Packs workspaces, installs into isolated temp HOME, spawns… → see test-standalone-npm-install.ps1.AGENTS.md | ||
test-standalone-npm-install.sh | Bash standalone-install smoke: packs workspaces, installs tarballs into isolated temp HOME, spawns… → see test-standalone-npm-install.sh.AGENTS.md | ||
theme-token-baseline.json | Shrink-only baseline for theme-token-guard.mjs: {fallback,undeclared,accentText} maps. → see theme-token-baseline.json.AGENTS.md | ||
theme-token-guard.mjs | Three-arm theme-token ratchet: fallback-form, undeclared colour token, accent-as-text. → see theme-token-guard.mjs.AGENTS.md | ||
verify-published-imports.mjs | Publish-correctness checker, run by ci.yml. For every non-private packages/*, asserts every module… → see verify-published-imports.mjs.AGENTS.md | ||
verify-plugin-install-load.mjs | Dynamic install-load check: pack → install OUTSIDE the repo → import the server entry under plain node+jiti, asserting the loader's default-export contract. → see verify-plugin-install-load.mjs.AGENTS.md | ||
verify-docker-plugin-load.mjs | Required Docker gate (X12): boot the image and assert the browser plugin loaded, with no alias crutch. → see verify-docker-plugin-load.mjs.AGENTS.md | ||
verify-lockfile-versions.mjs | Sanity gate after pnpm install --lockfile-only in publish.yml (tag-and-push) + _electron-build.yml. → see verify-lockfile-versions.mjs.AGENTS.md | ||
verify-release-deps.mjs | Pre-release dependency-shape gate. RULES assert server declares jiti, node-pty (>=1.2.0-beta.13),… → see verify-release-deps.mjs.AGENTS.md | ||
vitest.config.ts | Vitest config for repo-root /scripts project. Includes scripts/tests/**/*.test.mjs, node env, forks pool, maxWorkers PARALLEL_MAX_WORKERS, testTimeout 30_000 — harness-scoping/spec-repair tests shell out and blew the 5s default under fork contention. See change: contention-harden-real-process-tests. | ||
windows-job-object-smoke.ts | Windows Job Object kill-on-close smoke (task 7.4a; CI: ci-e2e-electron.yml job job-object-windows). → see windows-job-object-smoke.ts.AGENTS.md | ||
windows-liveness-smoke.ts | Windows boot-parent-liveness smoke (CI: _smoke.yml standalone-install-smoke-windows). → see windows-liveness-smoke.ts.AGENTS.md | ||
windows-introspection-smoke.ts | Windows introspection smoke driver (CI: _smoke.yml standalone-install-smoke-windows). → see windows-introspection-smoke.ts.AGENTS.md |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

