Repository navigation
Read pickup receipts through the delivery contract - #2080
Merged
Merged
Conversation
Require opened context receipts in shared task settlement and Claude Code timing/turn checks. Queued transport acceptance and failed delivery no longer satisfy pickup checks. Keep separate journey milestones and complete receipt batches for timing, provenance and mixed-delivery evaluation. Regressions exercise real admission, claim and closed-session boundaries for queued/opened/failed receipts, plus the adjacent queue-before-context timing case. git log -L traces the divergent classifiers to their original verifier implementations.
leaf-agent
previously approved these changes
Oct 8, 2026
leaf-agent
approved these changes
Oct 8, 2026
max-sixty
added a commit
that referenced
this pull request
Oct 9, 2026
…wser user end (#2144) `leaf-dev journey TARGET` is now the one command that runs a real session of a harness or the website and checks and times what the user's comments get. `verify-claude-code-task`, `verify-codex-task` and `verify-pi-task` are folded into it and deleted. There were three launchers for "a real session of harness X": the journey's headless `claude -p`, the Claude Code tmux driver, and `codex_task.Task`. The journey timed one comment through a browser but ran Claude Code headless, unlike a user's session. The verifiers ran the realistic sessions and checked several moments, but timed nothing per comment. Now each target runs its most realistic session, and every step is both checked and timed. ### Targets - `claude-code`: interactive Claude Code in tmux; `--hooks-module` turns on the plugin's hooks module. - `codex-app-server` and `codex-queue`: a Codex task on each transport. The queue transport is the desktop app's route and had no journey before. `--preview` keeps `verify-codex-task`'s preview checks. - `pi`: a real Pi session. - `website-adapter` (was `local`): leaf.page's adapter on this host. - `website-worker` (was `wrangler`): the built site through the local Worker and a page container. The rename covers `verify-site`, `ci.yaml`, `publish-site.yaml`, `AGENTS.md` and the docs. - Or a website origin. ### The user's end: HTTP or `--browser` One axis applies to every step: - **HTTP**, the default for harness targets, starts no browser. Each comment is posted as the page's tab posts one, and checked and timed from the event log on the page server's clock: picked up (`opened`, separate from `queued` per #2080), work started, progress, published, titled, replied. Across the runs below, a browser adds only 0.1–0.6 s to a harness reply. - **`--browser`**, the only end for website targets, is the whole unmocked journey. Every comment is typed as a user types it: a page comment in the banner's comment card, an anchored one on its selected passage. The page records when each reply showed: its message in view, its thread's row, or its news notice once the page has applied the reply. The release ask's reload is checked and profiled. Both ends share one `User` and one release check (`run_journey`): an end only sends the ask, and the shared code waits on the turn, the title and the answer. ### What each harness checks Every check the verifiers made still runs: - each comment is answered once; - a comment sent during a turn is picked up in it (Codex: on the queue transport); - Escape closes the turn, and a comment after it is answered; - restart and resume recover (Codex: #2046's Stop-first resume); - quitting ends the claim. Claude Code's permission prompts are answered and recorded on the step's sample. Detection of the user's command is scoped to the run's own tmux pane, so journeys can run side by side. ### Where to look - `dev/leaf_dev/journey.py`: targets, the two ends, the shared release check, step samples, `journey-chart`. - `dev/leaf_dev/journey_claude_code.py`, `journey_codex.py`, `journey_pi.py`: each harness's session and steps (from the verifiers). - `dev/leaf_dev/verify_site_browser.js`: the page's record of when each reply showed. - `tests/test_journey.py`: step readings at both ends, prompt matching, transcript and Pi trace parsing, a no-Chrome check over HTTP. ### Runs Every target passed a real run, one at a time: - over HTTP: claude-code, codex-app-server, codex-queue and pi; - with `--browser`: claude-code, codex-queue and website-adapter. `website-worker` was not run locally (no Docker); CI's `verify-site website-worker` covers it. > _This was written by Claude Code on behalf of max-sixty_ --------- Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Shared task verification accepted any pickup receipt, so queue acceptance or a failed delivery could pass as context entry. Claude Code timing could also report the queue timestamp as “picked up.”
Move receipt selection into
leaf.deliveryand require each consumer to name its transport reading. Reply failure writers explicitly select all recorded phases to preserve custody; developer consumers name their phase. Context checks useopened; journey measurements keep separate queued and opened milestones. Receipts retain their complete input batch, session, turn and timestamp for timing, exact-turn checks and mixed-delivery scoring.Validation: real admission/claim/session-closure probes reject queued and failed receipts while accepting opened receipts, even when all cases have a successful reply. A baseline/candidate timing probe reports queue acceptance at 1 s versus context entry at 4 s. Focused scenario, evaluator, arm, journey timing and production failure-receipt checks pass; mutation checks prove queued custody cannot be narrowed to opened; changed-file pre-commit checks pass. History review used
git log -Lon settlement, opened-input selection and Claude timing.