Skip to content

Clarify when additive changes keep the page protocol - #3681

Merged
max-sixty merged 2 commits into
mainfrom
codex/clarify-protocol-bumps
Oct 23, 2026
Merged

max-sixty merged 2 commits into
mainfrom
codex/clarify-protocol-bumps

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

Clarify that additive public APIs and new record kinds keep the current page protocol, while incompatible changes to existing return values require a bump. Explain that schema checks leave JavaScript compatibility to maintainer judgment and do not justify an already-selected bump.

Validation: independent contract review, all eight protocol comparison tests passed, and direct comparisons confirmed that a new record is accepted while an incompatible existing field type is rejected. Documentation only; runtime behavior is unchanged.

This was written by Codex on behalf of max-sixty

@max-sixty
max-sixty merged commit 519dd27 into main Oct 23, 2026
3 checks passed
@max-sixty
max-sixty deleted the codex/clarify-protocol-bumps branch October 23, 2026 03:50
max-sixty added a commit that referenced this pull request Oct 24, 2026
…sk obligations

The review of the merge resolution found the layer registry had kept only half of #3681's rule, and packages/AGENTS.md had a broken reflow. The glossary's Obligation entry predated message obligations and user to-dos in the inventory.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
max-sixty added a commit that referenced this pull request Oct 24, 2026
Cuts Leaf's maintainer guidance by 31%, from 53,277 to 36,520 words over
the 19 files below, as five commits, one per group (A–E). Each group was
reviewed separately, side by side against main, before this branch
assembled them onto main at `01a765701`. The cuts drop claims the code
or another file already owns and point to that owner. Most of the
remainder is catalogs the code keeps, restated module headers, history
and hedges. The root `AGENTS.md` above "Repository map" is
byte-identical to main.

## Groups

Word counts are `wc -w` on main and on this branch.

**A, session lifetime and page storage** (10,507 → 4,225, −60%):
`src/leaf/session-lifetime.md` 7,638 → 2,971, `src/leaf/page-storage.md`
2,869 → 1,254. Stop policy, receipt, the Claude Code watch, nudges,
reconnects, the start handshake and the `observations.jsonl` field list
now live only in the module headers the text points at. Every `## Files`
bullet the storage-contract test parses stays. Also corrected: the hook
registration list now points at the registration files, since the old
list omitted PreToolUse; SessionEnd's route through `bin/leaf` to
`state.py` is stated; both writers of `messaged_ending` are named.

**B, events, layer registry and validation** (10,834 → 6,879, −37%):
`events.md` 6,074 → 4,123, `layer-registry.md` 2,103 → 1,417,
`validation.md` 2,657 → 1,339. Obligation-record detail, thread
attention, read state, the static rule catalogue, render invariants and
the kernel fact list now live only in their modules. The kinds table
keeps its columns, `kind-*` anchors and required fields. Also corrected:
the kernel facts include `$passages`. The `$marks` registry description
and `registry/kernel.py` now say that a layer declaring a different
table is refused, where they used to say it is stamped over.

**C, browser and build** (7,938 → 6,612, −17%): `browser/AGENTS.md`
6,211 → 5,413, the keyboard guide 1,241 → 1,002, `build/AGENTS.md` 486 →
197. Restated module headers and the "Authoritative projection" section
are cut. The concern and question indexes are unchanged. The `lit-html`
pin's reason moved into `litModule`'s comment.

**D, area AGENTS.md files and the root from "Repository map" down**
(10,953 → 7,645, −30%): root tail 2,523 → 2,214, `dev/` 1,579 → 481,
`src/` 1,310 → 301, `tests/` 4,726 → 3,937, `examples/` 747 → 654,
`packages/` 68 → 58. `leaf-dev --help` now prints each command's
summary, read from its module docstring without importing it, and
replaces `dev/AGENTS.md`'s command list. `src/AGENTS.md`'s module
catalogue is deleted, and so is the test that only held it to the code.
`tests/AGENTS.md` renames two headings to "Failing tests" and "Races",
and running-tend's citations follow.

**E, repository skills** (13,045 → 11,159, −14%): developing-leaf 4,382
→ 3,543, its glossary 3,995 → 3,596, running-tend 2,467 → 2,300,
ui-sweep 1,339 → 1,224, grinding-ui 862 → 496. Text that command help
and module headers hold is cut. Every behavior the injecting eval cases
grade is kept. Also corrected: closing a page ends the agent's side of
it; it doesn't close the page in the browser.

## Scars kept

Review restored or protected these: the #2481 clauses in the root ("even
for a change most of the suite runs through", "on a busy host keep to
focused checks"); the root sentence that `wt merge` skips the website
delivery checks; developing-leaf's "Choose what the user reviews",
"Prove and hand off a visible change" and "Explore an open design";
ui-sweep's "First reading" and "External review" and the pointer to it
beside the `/ui-sweep` rule, which guideline-review measured; #3532's
scoring rules; in events.md, the `part` exactness rule, `publication` on
any reply that publishes the saved source, and a promised to-do keeping
an obligation the agent's after its thread resolves; both revision
manifest digests; a refused revival leaving the service enabled until
`server stop`.

## Main since the cuts

The groups were cut at `28b729d12`, and main had moved 166 commits
since. Every group conflicted. Each resolution kept the group's text and
carried in what main added to the same passages: the runtime no longer
being vendored (`runtime_selection.py`, the runtime identity handshake,
the protocol scope it narrows); `leaf page open`/`close`, `thread reply`
and `page claim`; message obligations; the undo key's show-then-take
press; the http-connections grant record; the render gate's desktop
window; the "What takes turns in a place doesn't size it" rule and the
"Editing in place" section; the corpus as ignored snapshots; landing
through a GitHub pull request; the glossary's renames and its "Related
terms" section; main's renames in the browser and keyboard guides.
Main's new module entries in `src/AGENTS.md` and field names in the
page-state reading were left out, because those groups had moved the
lists into the code. One cut was reversed: the root keeps main's
sentence that pages run the committed kernel while it matches and the
source modules otherwise, because the file D pointed to for it
(`build/AGENTS.md`) no longer says so after C. Pointers to sections that
D removed from `dev/AGENTS.md` now target their current home.

## Checks

- `pytest -n 4` on `tests/model/test_interact_layer.py`,
`interact_contract/test_layer_contract.py`, `test_owner_index.py`,
`test_unused_exports.py`, `test_session_lifecycle.py` and
`dev/tests/model/test_response_times.py`: 252 passed, including the
storage-contract, events-reference, root-directory-map and skill-file
tests.
- `uv run leaf-dev --help` prints every command with its summary.
- `pre-commit run --from-ref 01a7657 --to-ref HEAD` passes.
- A script resolved every `file`, `file, "Heading"`, `/skill, "Heading"`
and `file.md#anchor` pointer in the changed prose, and grepped the tree
for citations of every heading the branch removed. Its only real
findings, the pointers into `dev/AGENTS.md`'s removed sections, are
fixed.
- `node --check build/browser/build.mjs`. `pnpm run check` was not run;
the only change under `build/` is a comment.
- An independent review rebuilt each file's three-way merge and checked
main's change in each of the 60 conflicts against this branch. It found
one lost clause (#3681's, on a bump chosen by hand) and a broken reflow,
both fixed in the last commit, which also adds message and user-task
obligations to the glossary's Obligation entry.
- No evals were rerun on the assembled text. Group E's eval passes were
run on its own branch.

> _This was written by Claude Code on behalf of max-sixty_

---------

Co-authored-by: Claude Opus 5.5 (1M context) <[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