Skip to content

Say what holds now in the tree, and leave how it came to be to commits - #6210

Merged
max-sixty merged 3 commits into
mainfrom
archeology-rule
Nov 17, 2026
Merged

max-sixty merged 3 commits into
mainfrom
archeology-rule

Conversation

@max-sixty

@max-sixty max-sixty commented Nov 16, 2026 •

Copy link
Copy Markdown
Owner

Stops agents writing history into the tree. Root AGENTS.md asked a module header to "record" each product decision and the alternatives it rejected, which agents read as a dated log (src/leaf/clerk.py's docstring is mostly that), and evals/README.md asked each case's leading comment to record "where the case came from and what it measured". Now a header states each decision with its reason, whether the user made it, and any alternative a later change might reach for, with why it fails; and text in the tree, comments, tests and eval cases included, says what holds now, with dates, the request or incident, measurements and earlier versions in the commit message. How a rule came to be stays on the list of public surface traps in maintainer guidance, which running-tend's review threshold reads, so review flags history written there.

Scored with a temporary A/B in scratch (about 40 Opus runs, about $60): an eval case written from a session's failure carried its session id, date and pass counts in 4 of 4 runs on the old text and 0 of 4 on the new. Updating a header, neither text wrote dates on a clean header, and deleting the decision sentence outright lost a rejected alternative in 4 of 4, so the sentence stays rewritten rather than cut. On a header already holding dated history, the old text extended it in 1 of 4 runs and the new in 0 of 4. So in headers the history already there is what agents copy; #6212 removes it across the tree.

Asked for by Max on #6160's review. pre-commit passes on both files.

This was written by Claude Code on behalf of max-sixty

Module headers and eval cases had been collecting archeology: dated user
choices, the incidents behind them, replay counts and earlier versions.
`src/leaf/clerk.py`'s docstring is mostly that. Two rules asked for it.
Root `AGENTS.md` had a header "record" each product decision and the
alternatives it rejected, which agents read as a log of when and on what
evidence. `evals/README.md` had each case's leading comment record "where
the case came from and what it measured".

- `AGENTS.md`, "Where instructions live": a header states each product
  decision with its reason, whether the user made it, and any alternative
  a later change might reach for, with why it fails. A new paragraph says
  text in the tree, comments, tests and eval cases included, says what
  holds now rather than how it came to be, and puts dates, the request or
  incident, the measurements and the versions before in the commit
  message. The public-surface-trap sentence drops its copy of that rule.
- `evals/README.md`, "Case format": the leading comment says what
  situation the case reproduces and the failure it invites; where it came
  from and what its runs measured go in the commit.

Of the 560 commits since 2026-11-02 that touched `src`, `browser`,
`packages`, `hooks`, `dev`, `worker` or `build`, 111 added a line
matching a dated-history pattern (dates beside "on/until/since", or "the
user chose/asked/rejected"; the pattern also catches some present-tense
uses of "the user chose").

Scored with a temporary A/B in scratch (Claude Code 2.1.325, Opus 5.5,
the real global config, each arm given its own root `AGENTS.md` and
`evals/README.md`; about 40 runs, about $60):

- Adding an eval case from a session's failure, with the session id,
  date and pass counts in the request: the old text's case comments
  carried all three in 4 of 4 runs; the new text's in 0 of 4, each
  describing the situation and the failure instead. Deleting the
  README's sentence outright left history in 2 of 4 and no comment in the other 2.
- Updating a header after a decision, with dates, replay counts and
  rejected options in the request: on a header with no history, neither
  text wrote dates or counts into it (0 of 4 each), and both recorded
  every rejected option. Deleting the decision sentence dropped the
  rejected "Show all" toggle in 4 of 4, so the sentence still carries the
  alternatives. On a header already holding one dated paragraph, the old
  text extended the dated history in 1 of 4 runs and the new text in 0
  of 4, removing the existing paragraph in all 4.

So the rule mostly moves eval-case comments; in headers, the history
already there is what agents copy, which a separate change removes.

> _This was written by Claude Code on behalf of max-sixty_
leaf-agent
leaf-agent previously approved these changes Nov 16, 2026
Comment thread AGENTS.md Resolved
…which Tend's review threshold reads

> _This was written by Claude Code on behalf of max-sixty_
@max-sixty
max-sixty merged commit 5ed0db4 into main Nov 17, 2026
7 checks passed
@max-sixty
max-sixty deleted the archeology-rule branch November 17, 2026 07:05
max-sixty added a commit that referenced this pull request Nov 17, 2026
…s that made it (#6212)

Removes the history the tree had collected in module headers, comments,
test docstrings and eval-case comments: dates of decisions, who asked
when, the incidents and sessions behind them, replay and pass counts, PR
numbers cited as provenance, and accounts of earlier versions. Each
decision stays with its reason, whether the user made it, and the
alternatives a later change might reach for, now stated as rejected with
why they fail. The removed history stays in the commits that added it
(`git log -L`). #6210 changes the two rules that produced it.

Lines matching a dated-history pattern outside `notes/`, `examples/` and
fixtures go from 264 to 17; the rest are page and prompt data, a page
revision's "first version", and three `browser/AGENTS.md` clauses #6024
already removes. Provenance PR numbers leave code comments; one open
`TODO(#4041)` stays. `src/leaf/clerk.py`'s docstring goes from 250 lines
to 190.

What to weigh: a figure that a constant, bound or budget is sized from
stays (`DEADLINE_S`, `ROLLOUT_MS`, `FEW`), and so does a version that
bounds an observation (a Playwright build, a Claude Code version). An
observation of a browser or of Claude Code that carried a date now says
what the code guards against ("Chromium can leave … hovered"), since
dropping the date alone would have asserted a law. `notes/` keeps its
dated research. Every hunk is a comment, docstring or string; no
assertion changed. `packages/default/styles/sample.css` also loses a
paragraph that described the suggestion as boxless, which `base.css` no
longer makes it.

Conflicts: open PRs that touch these 423 files, such as #6156 in
`forks.py`, will resolve comment hunks when they next merge `main`.

Asked for by Max on #6160's review. Six agents swept by area; an
independent Codex pass per area compared old and new text claim by
claim, and a second pass checked the fixes; their findings are fixed.
`pre-commit` passes on every changed file, as do the tests that read
them.

> _This was written by Claude Code on behalf of max-sixty_
max-sixty added a commit that referenced this pull request Nov 17, 2026
…with its alternative

Root AGENTS.md (#6210, #6212) keeps a decision's date and the incident behind it in
the commit, and has a header state the decision, its reason, whether the user made
it and the alternative a later change might reach for.

- `framed_widgets` states that the author declares a question's region and name, as
  the user chose, and names the two alternatives, the section a heading opens and a
  widget of Leaf's own, with why each fails. Its history moves here: an `lf-ask`
  declared the question until 16 November 2026, when the user chose plain HTML, and
  of the section rule and the named group built that day chose the group.
- `arrivalRegion` says what landing on a change alone would do, and why a heading or
  the block before a change is no region.
- The full-height rule says why every other section keeps its flow, and the
  playground's rule why a minimum of zero fails inside a group that scrolls.
- Two test docstrings and a subtest comment say what would go wrong rather than what
  once did.
max-sixty added a commit that referenced this pull request Nov 17, 2026
…to commits

Main now asks text in the tree to say what holds rather than how it came
to be (#6210, #6212). This branch's own text still carried the date the
user chose the line-turn hold, the hold it replaced as "kept until then",
and the bound it shortened from a minute. The `forks.py` header now
states the decision with the alternative it rejects and why that
alternative fails (a second answer to which turn holds a thread, kept
partly outside the log); the figures that size `STARTING_GRACE` stay in
its comment without the date. No behaviour changes.
max-sixty pushed a commit that referenced this pull request Nov 18, 2026
…uidance (#6357)

Root `AGENTS.md` ("Where instructions live") sends the date of a
decision and the behavior before it to the commit message, and #6210 and
#6212 swept such history out of the tree. Five clauses survived or
arrived since: three "until … November 2026" asides in
`browser/AGENTS.md`, the same aside in
`browser/runtime/keyboard/AGENTS.md`, and the date the user chose
"Claude awaits" in the glossary (added by #6262). This keeps each rule,
its reason and its `check:` pointer, and drops only the dates and the
description of the old behavior; where the old behavior carried the
reason (a long press's release presses nothing so a finger can read
without acting), the reason is now stated directly.

No code or test changes. These paths are agent instructions under
`browser/` and `.claude/`, so landing needs the control-plane owner's
approval.

Co-authored-by: leaf-agent <[email protected]>
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.

2 participants