- repo-stats reads the gotcha list from context/gotchas.md (the digest in
repo-map.md no longer measures the doc-growth signal) and reports it as
`docs.gotchas`; the test fixture and its derived expectations follow.
- AGENTS.md and the wave agent-rules protect gotchas.md and
file-inventory.md like the repo map they were split from.
- doc-site.md's publication table lists the two new pages.
- file-inventory.md's Context docs rows describe the three files correctly.
- the code-review skill points at gotchas.md for the long form.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
repo-map.md was 173 KB (~43k tokens), too long to be part of every new
agent's context. The full gotcha text moves verbatim to context/gotchas.md
and the per-file inventory (with the old Wasm/CLI/Testing sections) to
context/file-inventory.md; the map keeps a one-or-two-line digest per
gotcha under the same numbers, so every `gotcha N` citation still resolves.
The doc-site manifest publishes the two new pages, and `gotchas` gets the
same gotcha-N anchors as `repo-map`.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The Opus review of 46c8a967: a new-version file had nowhere to declare
its stored measures. The ## Category: _Measure section stays and lists
them with displays and ids; its header declares nothing. Clause 6 says
input text means files and command-language text, distinct from
interactive typing. The sort note says plain string order, not numeric.
The user approved the amendment on PR #326 (2026-10-09), so its Status,
the accepted ADR's pointer, core.md section 20 and the doc-site title
no longer say proposed.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
On the user's instruction an ADR states only what its decision changes,
and mentions an existing convention only where it conflicts. The accepted
ADR 007 is restored to main's text plus a one-line pointer, so merging
this PR keeps it; the amendment is context/adr/007-stable-identities-
amendment-1.md (280 lines, from 784), with a table of the accepted rules
it replaces. The doc site lists the new file, and core.md section 20
points at it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
The run_case_capture helper was being called in command substitution
(out=$(run_case_capture ...)), which runs it in a subshell. This caused
the ok/bad updates to the pass/fail counters to be discarded.
Fix by having the helper write output to a caller-provided file parameter,
then reading from that file in the caller. This keeps the helper in the
parent shell where counter updates are preserved.
Addresses Codex P2 review on commit ec30c8a7.
Co-authored-by: Ed Langley <fiddlerwoaroof@users.noreply.github.com>
1. Shebang (Codex P2): scripts/agent-bootstrap.sh and .claude/hooks/session-start.sh
now use #!/usr/bin/env bash instead of #!/bin/bash, matching repo convention
enforced by checkers.sh.
2. Fail-closed bd pin (Codex P2): .claude/hooks/session-start.sh local path now
exits 2 with a warning when pinned or running version cannot be parsed,
instead of silently succeeding. An unparseable version is not a pass.
3. pr-reviews failure (Codex P2): scripts/pr-watch no longer uses '|| true' to
swallow pr-reviews failures. If pr-reviews fails (fetch error, malformed
response), pr-watch now exits 6 with a warning. Empty successful fetch
(no reviews) is still exit 0.
- Added exit 6 to usage text and skill documentation
- Added test case 'pr-reviews failure exits 6' using malformed JSON fixture
- All 57 pr-watch tests pass
Co-authored-by: Ed Langley <fiddlerwoaroof@users.noreply.github.com>
The pr-watch skill and script now cover reviews/comments, not just CI checks.
An agent reading only the pr-watch skill now knows to track both.
.agents/skills/pr-watch/SKILL.md:
- Reframed: 'watching a PR' means checks AND reviews
- Added 'Reviews and Comments' section with the three surfaces table
- Added 'Review Obligations' subsection (answer feedback, identity line, etc.)
- Documented --reviews (default) and --no-reviews flags
- Cross-references AGENTS.md for full workflow details
scripts/pr-watch:
- Added --reviews (default) and --no-reviews flags
- After exit 0 (green/mergeable), calls scripts/pr-reviews to show all
reviews and comments. Does not change exit code — answering is agent's job.
- Updated usage text to document the new behavior
- Composes with existing pr-reviews (fixture mode passes through)
scripts/pr-watch-test.sh:
- Added mk_reviews_empty() and mk_reviews_with_review() helpers
- Added review fixtures to all cases that exit 0 (pr-reviews needs them)
- Added tests: 'green with reviews shows review output' and
'--no-reviews skips review output'
- All 56 tests pass
AGENTS.md / context/cloud-agents.md:
- Updated cross-references to point to pr-watch skill as agent-facing recipe
- Simplified text now that pr-watch handles reviews automatically
Co-authored-by: Ed Langley <fiddlerwoaroof@users.noreply.github.com>
User ruling: agents must work inside nix develop (or direnv) for this repo.
Bare system cargo that fails edition2024 is a misconfigured session.
Changes:
1. scripts/agent-bootstrap.sh:
- Added section 0: seed nix flake inputs automatically
- Cargo warm now runs inside 'nix develop --command'
- Added --skip-nix-seed flag for environments that don't need it
- Updated environment notes to emphasize nix-first
2. .cursor/environment.json:
- Removed --skip-cargo-warm (full nix-backed warm now default)
3. AGENTS.md:
- Added 'Toolchain' row to multi-stack table (nix develop required)
- Added 'Toolchain Requirement' subsection with usage examples
- Updated local agents guidance to use 'direnv allow'
4. context/cloud-agents.md:
- Bootstrap now lists nix-seed as step 1
- 'What does not work' table updated: bare system cargo now listed as
failing; nix develop works after bootstrap
- Updated nix section to reflect automatic seeding
Previous soft gap: nix-seed was a manual footnote; now it runs in bootstrap.
Co-authored-by: Ed Langley <fiddlerwoaroof@users.noreply.github.com>
Unifies coding-agent setup across Claude Code and Cursor so both stacks get:
- Pin-matched bd from flake.nix
- Fresh Dolt beads tracker sync (not stale JSONL export)
- Same skills via symlinks to .agents/skills/
Key changes:
1. scripts/agent-bootstrap.sh: stack-agnostic bootstrap that handles bd
installation, tracker sync, and optional cargo warming. Works for any
agent stack (Claude, Cursor, or manual).
2. .claude/hooks/session-start.sh: now a thin wrapper that calls the
shared bootstrap for cloud sessions, keeping only the local pin-check
inline.
3. .cursor/environment.json: configures Cursor cloud agents to run the
bootstrap via 'install'.
4. .cursor/skills/: symlinks to .agents/skills/* so Cursor agents
discover the same skills Claude has.
5. AGENTS.md: adds Multi-Stack Agent Support section; clarifies that
scripts/kb is the KB interface (Prolog MCP is not required and not
available in all stacks).
6. context/cloud-agents.md: updated for multi-stack support; added KB
section emphasizing scripts/kb over Prolog MCP.
The canonical skill source remains .agents/skills/. Both .claude/skills/
and .cursor/skills/ are symlinks to it, so there is one truth that both
stacks read.
Co-authored-by: Ed Langley <fiddlerwoaroof@users.noreply.github.com>
A two-level numeric tower: exact decimals (rust_decimal) by default, inexact f64 by Scheme's contagion rule. Measured against f64, bigdecimal and num-rational, and against ADR 009's exact f64 accumulator. Registered on the doc site.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
churn.csv now has a fixed header. When no file changed in the window,
no model is built and the report says so. docs/*.md, README.md and
RELEASING.md count as prose, and .codex/ as agent docs. The suite no
longer builds improvise itself, because checkers.sh scrubs the linker's
environment.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
code-maat's CSVs and a per-file churn CSV go into one directory, one
sparse model is imported from it, and a checked-in improvise script
builds and exports the views the report prints.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
The wrapper's contract drops cherry-pick, because git ignores
GIT_AUTHOR_NAME there, and rule 8's cherry-pick -x should keep who wrote
the commit. A new case asserts it. The pre-push check now asks that every
commit you made names your actor, since a stacked or cherry-picked commit
keeps its own author. Answers the Codex P2 and the review on PR #310.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
An in-house DBSP core as a problem-agnostic crate, plugged in behind a
trait in improvise-core, with the eager evaluator kept as the oracle.
Adds examples/retraction_drift.rs, which measures f64 retraction drift
against the eager fold and the exact decimal sum.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
On #210 the review and comment JSON outgrew ARG_MAX, and
`jq -n --argjson ...` failed to exec with exit 126 before printing
anything. A `combine` helper now pipes the three documents to `jq -s`
through the printf builtin, on both the fixture path and the live path.
The new suite cases put about 2 MB on each surface, so a fix that moves
only one document off argv still fails. Both rivals fail 5 of 30: the
pre-fix script, and a partial fix that keeps the issue comments on argv.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
#297's rulings kept: no bash floor, no find_modern_bash probe in
checkers.sh (it runs suites under the dev shell's $BASH), and no
toolchain-policing step in the build job. This branch's CI table kept:
ci_suites, --ci, --would-run, and the --ci steps in ci.yml (build, js, kb),
which replace gh/main's hand-listed kb, --self-test and remaining-checkers
steps. The kb row already runs every suite those steps named.
check-ci-graph passes on the merged ci.yml.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
Copilot on #297: `pr-reviews` only calls `date +%s`, so the REAL_DATE
pass-through never ran. It is deleted rather than tested. The fake now refuses
any other arguments with exit 2, so a new `date` call shows up as a failure.
Rival: with pr-reviews calling `date -u +%s`, "a review arriving on the third
poll is seen" and "--wait keeps polling until its deadline" fail (23/25).
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
This follows the user's rulings: CI should not care which bash or which
standard utilities it runs, and jobs take what the ci dev shell provides.
- checkers.sh: remove find_modern_bash, the 5.1 floor (improvise-fd0j) and
exit 3. Suites run under $BASH with PATH unchanged.
- checkers-test.sh: remove sections 2, 5 and 5b (the fake bashes and utilbin).
They existed only to pin the floor.
- scripts/kb: drop the BSD `stat -f` fallback. kb needs the dev shell for tpl,
and that shell's stat is GNU.
- ci.yml: remove every `shell: bash` override, so every step runs in the dev
shell. Remove the web-toolchain version probe and the Playwright
version/browser probe. The shell's PLAYWRIGHT_BROWSERS_PATH pins the
browsers. npm ci stays because @playwright/test is not nix-provided.
- flake.nix: update the comments that promised those CI checks.
Reasoning: context/code/tooling.md section 5. Evidence:
context/test-evidence/tooling.md.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
On the NixOS runners /bin holds only sh. With no /bin/sleep, the watchdog in
bounded_reviews exits at once and wins the `wait -n`, so every --wait case
reports 124. Both tools are now resolved with `type -P` before any case stubs
PATH.
Red: with both paths pointed at /nonexistent/, the suite fails 25 of 25.
Rival: REAL_SLEEP=/nonexistent/sleep fails 25 of 25 again. The date
pass-through has no discriminating rival, because pr-reviews only calls
`date +%s`. Evidence: context/test-evidence/tooling.md.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
ci.yml: this branch's check-harness-lock --allow-network step is kept, ahead
of main's nix-build clippy and test steps that #228's merge brought in.
test-evidence/tooling.md: both EOF appends kept, no heading lost (42 = union).
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
ci.yml: main's NixOS-runner rewrite, with this branch's --ci build and --ci kb
steps. Main's separate `checkers.sh kb` step is dropped (the kb row runs it),
and so is the `nix shell nixpkgs#trealla` wrapper (the dev shell supplies tpl).
test-evidence/tooling.md: both EOF appends kept, no heading lost (41 = union).
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
Section 5b (the bash 5.1 floor, #237) was written on a branch cut before the
NixOS-runner change (af44653f). That change moved section 5 off /usr/bin:/bin,
because on NixOS that path holds only env and sh. The two merged with no
conflict. On NixOS the runner then dies on `dirname` with exit 1, which turned
the KB job red on every PR at 666de199.
5b now uses utilbin too, and utilbin gains head and env for the 5.1 control.
Evidence and rivals: context/test-evidence/tooling.md.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze
Main's PR #287 added a workflow-level defaults shell, and the refusal made every
suite read as unrun. The two cases that pinned it are deleted; one shows a step
under workflow and job defaults is counted.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VdfEGXA7aJ6ftMsCc9PJze