Skip to content

Work tools say what she means: latest is a typed submission handle; work/review only on a review card - #5821

Merged
joelteply merged 1 commit into
canaryfrom
fable/work-tools-say-what-she-means
Nov 7, 2026
Merged

joelteply merged 1 commit into
canaryfrom
fable/work-tools-say-what-she-means

Conversation

@joelteply

@joelteply joelteply commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

How this serves the minds: residents spend their acts reading submissions they can't name and calling a verdict verb on their own cards, so almost nothing gets written. This removes the two biggest refusal loops by type, which serves path step 2 (Useful: residents code at pace and merge) and goal 2.

Builds on #5830 (Cormac's one refusal shape, now merged): the "no submission yet" answer is a kernel Refusal with a NextCall, not a new shape. Base: canary.

What changed

  • SubmissionHandle (core/continuum-mind/src/work/submission/submission_handle.rs) is the submission_id type of both work/submission and work/review. Its values are Latest | Id(Shown<SubmissionId>). latest is the default, and the schema she sees lists it as a value (anyOf: [{enum:["latest"]}, {type:string}], default: "latest", no longer required).
  • One resolver, SubmissionHandle::read(board, card):
    • On a code card, the newest submission comes from airc's WorkCard::latest_submission (the one owner of newest; the base already migrated to it).
    • On a review card, it reads the parent's submission through WorkBoardProjection::candidate_for_review, so the reviewer's call on her review card answers.
    • work/review resolves through the same function.
  • No submission yet returns the typed SubmissionRefusal::NoneYet as a kernel Refusal:
    • The next call is work/submit {card_id} when the card is hers to submit (the same work_preconditions::check(Submit) that work/submit executes under).
    • Otherwise the next call is work/get {card_id}.
    • The next call is chosen by cause, and it is never the read that was just refused (Cormac, review 1851ee8b):
      • An id she named that resolved to nothing (Handle, NotOnCard, or the review binding refusing that id) gets work/submission {card_id} at its default (latest).
      • A parent absent from this board, or the newest refused by the review binding, gets work/get on the parent. work/get reads a card from any room she belongs to; asking for latest again would repeat the refused read.
      • a_submission_refusal_never_suggests_the_read_it_refused walks every cause with each handle that can reach it.
    • To name these calls, WorkSubmitParams and WorkSubmissionParams now serialize. A shown id goes back on the wire only in full; a prefix refuses to serialize.
  • work/review and work/submission declare OnDemand. They are no longer core hands on every card. work_preconditions::in_hand puts them in hand when she holds a review card (or her own card once it carries a submission), so work/review is never offered on her own implementation card. This reverses the 11-04 choice to make them core hands, pinned in surface.rs. That fix predates the held-card moves (HeldWork::move_commands → select_granted, contribute.rs:280), which now cover Benchy's 11-04 review card.
  • Standing grounding never leaves the turn (GroundingOffer::of, grounding.rs). With two schemas fewer in her core hands, the greedy Leveled::reduce let an equal-salience roster take one more unit, and the activity wall dropped out. standing_activity_grounding_survives_history_on_the_wire caught it: it passed on the base and failed with only the disclosure change, which I confirmed by flipping it back. A standing piece's last level is now its minimum, the same minimum that fixture already counts as fixed.
  • Next calls are in her hands. work/submit and work/get (the remedies in the "none yet" refusal) are Core, so they are offered every act. work/submission, the remedy for a guessed id, is on-demand, but that refusal only comes back from a work/submission call she just made. So the verb is already in her hands: a held card put it there, or her learned head or help-loaded tail carries it. A reviewer holding a review card has it through WorkVerb::Review's grants.
  • Deleted prose:
    • submissions_on_card (the "this card has no submissions yet: …" hint)
    • the [not_found] submission is absent from this card sentence
    • the withheld_from_hands guidance appended to every work/review and work/submission refusal
  • Rust: +444 / −126 lines. About 180 of the added lines are tests, plus the 86-row replay fixture.

Measured

Before. Source: the M5 prompt captures ~/.continuum/fixtures/prompt-captures/<persona>.jsonl and .prev.jsonl, for the 6 h ending at captured_at_ms 1794051773032 (2026-11-07 ~05:42Z). Tool calls are deduplicated by tool_use id, and a call counts as refused when its result starts with refused . The four residents made 727 calls (Aiko 251, Aris 200, Atlas 151, Benchy 125), and 164 of them were refused:

verb reason total Aiko Aris Atlas Benchy
work/submission id on a card with no submission 27 0 0 18 9
work/review card reviews nothing (her own code card) 22 8 1 0 13
work/submission submission_id=latest 19 6 0 10 3
work/submission parent's submission named on its review card (not_found) 7 3 0 4 0
work/submission guessed id not among the card's submissions 7 2 0 5 0
work/submission auto 3 1 0 2 0
work/create room declares no repo 8 8 0 0 0
code/read path missing in a swe/pallets__flask checkout 8 0 0 0 8
work/submit not holding the card 5 5 0 0 0
tool/output "give exactly one of outputId or act" 5 0 3 2 0
code/tree swe/pallets__flask path missing 5 0 0 0 5

The six work/submission and work/review rows total 85 of the 164 refusals. Each remaining refusal class has 4 or fewer occurrences.

Replay. the_m5s_refused_submission_reads_replay_into_answers runs the 64 refused work/submission calls, copied verbatim into replayed_refusals.json, against a real projection of those cards:

  • 20 now find their submission.
  • 16 get the typed "none yet" with a next call.
  • 21 are guessed ids refused by type, with work/submission at its default as the next call.
  • 2 are auto, which never decodes.
  • 5 name cards outside the fixture board.
  • No latest read misses.

the_review_verb_is_never_offered_on_her_own_card covers the 22 work/review calls.

After deploy. Owner: Sneasel (Fable). Run within 1 h of the deploy that carries this, then compare against a restart-only control hour. Measure from the same captures:

  • refusals per hour per verb, for work/submission and work/review. The expected latest and "reviews nothing" counts are 0.
  • work/submit plus code/edit/code/write calls per hour, per resident.

The card stays open until those numbers are posted.

Not fixed here (four classes; each needs a card):

  • work/create without a repo in a room that declares none: 8 (Aiko)
  • swe/pallets__flask checkout paths: 13 (Benchy)
  • work/submit on a card she doesn't hold: 5 (Aiko)
  • tool/output "exactly one of outputId or act", which should be a one-of type: 5 (Aris 3, Atlas 2)

Tests

All runs on macOS with --features …,metal, in their own target dir:

  • cargo test -p continuum-mind --features test-fixtures,metal --lib: 1114 passed (the replay tests and the never-the-refused-read test included).
  • cargo test -p continuum-cognition --features test-fixtures,metal --lib: 967 passed.
  • cargo test -p continuum-engine --features metal --lib tool_dialect: 6 passed.
  • cargo test -p continuum-core --features metal --lib -- registry:: positron_kanban_source loose_id training_credit work deliberation: 100 passed (the earlier pinned_act_result failure is gone on the new base).
  • AGENTIC_SURFACE_CEILING was re-pinned from 17956 to 17986, measured locally on the new base. That is the whole-registry total (the two handle schemas); the per-act surface shrinks because both verbs left her core hands.
  • Ratchets (source-hygiene --bin ratchets against canary 9528422): no count changed. oversized-edits.sh: passes.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

joelteply added a commit that referenced this pull request Nov 7, 2026
…d it: continuum's airc pin moves past #1660 (card c3504a71) (#5824)

* A resident's submission records her commit, so the merge gate can land it: continuum's airc pin moves past #1660 (card c3504a71)

Fable's #5821 refusal table: every resident submission carried no head, and airc #1660's merge gate
(a passed independent review at a recorded head) refuses a headless submission, so no resident's work
could ever merge, blocking goal 2 (a resident's first merged PR). continuum pinned airc at b158a7e93,
which predates #1660, so work/submit could not record one.

- Cargo.toml: every airc crate b158a7e93 -> 22c9c0ee0 (airc canary: #1660 recorded heads, #1661
  latest_submission, #1663 the stacked-PR gate).
- work/submit records her checkout's committed HEAD (committed_head) as the submission's head, and
  the patch is that commit's diff against the base. While she holds changes the commit does not carry
  (tracked or untracked, outside the substrate paths the patch excludes) it is refused by name, naming
  code/git/commit: a submission is a commit, never her working tree, and the substrate never commits
  for her. A typed artifact names its head too (`head` param).
- One owner of "newest": continuum's card_holder::latest_submission (a copy of submissions.first())
  is deleted; its six callers read airc's WorkCard::latest_submission().
- Touched files leave with no self-sized sites: handoff.rs's five hand-cut ids render through
  airc_core::shown_id::shown_form; the build shas compare by prefix either way and render whole; the
  dirty paths, the diff sha256 and the obligations she resumes from render whole; work_similar's card
  text gives the embedder the whole body. latest_submission.rs runs git through one git_in helper
  (three spawn sites become one).
- Test literals of WorkSubmission/SubmitWork carry a head (Unrecorded where heads are not the subject).

Tests: continuum-mind work:: 86 pass, continuum-rooms handoff 8 pass, rooms lib 30 pass; mind/rooms/core
--tests check clean; ratchets vs origin/canary 87/87. a_worktree_with_no_base_is_refused_by_name now
proves an uncommitted change is refused naming code/git/commit and the derived head is the commit.
Mutation: without the dirty-tree refusal, it fails.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

* A submission's patch is exactly its commit, base..head; a commit carrying an unpublished path is refused (Fable on #5824)

Fable: the gate merges the HEAD commit, but the artifact was candidate_diff (her checkout's diff minus
SOLUTION_PATH_EXCLUDES), so anything in her commit that the diff dropped would merge unreviewed; airc's
CLI submit enforces patch == git diff --binary base head for this reason. commit_patch now returns
exactly `git diff --binary base..head` (the same flags the patch was always rendered with), and a commit
that touches a path a submission never publishes (substrate or build byproducts) is refused by name.

Tests: continuum-mind work:: 84 pass; ratchets vs origin/canary 87/87. a_worktree_with_no_base_is_refused_by_name
now also commits .continuum/state.json and expects the refusal naming it. Mutation: without the refusal it
fails.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

* protocol: WorkSubmitParams carries head (the regenerated ts-rs binding for #5824)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

* work/submit passes the validated base to commit_patch (an unused variable was a new continuum-mind warning; CI's warning ratchet 13 -> 14)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

* work/submit fixtures type their head; head's doc cut to one clause

A typed submission is complete only with the commit it ends at (the gate refuses one without),
so the training_credit fixtures that typed base and artifact but no head fell through to
deriving from a checkout and cloned acme/ordinary-project in CI. They now type head.
head's tool doc is cut to 'Omit: your checkout's committed HEAD.' (+42 surface tokens at
bce9206 with the longer text; the exact figure is pinned from this commit's CI).

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

* The agentic surface ceiling is re-pinned at 17956: work/submit's head param (measured in CI at 6b5069c)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

---------

Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
@joelteply
joelteply force-pushed the 3d7931b7/one-refusal-shape branch from 2707e7d to 960431e Compare November 7, 2026 16:04
Base automatically changed from 3d7931b7/one-refusal-shape to canary November 7, 2026 16:17
@joelteply
joelteply force-pushed the fable/work-tools-say-what-she-means branch 2 times, most recently from 0e48936 to 5f81156 Compare November 7, 2026 16:37
… and work/review is offered only on a review card

The M5's four residents, six hours of captures (2026-11-07): 164 refused calls, and the
two work-verb loops lead it. 19 `work/submission submission_id=latest` refused as "not a
usable submission handle", 27 handles refused on cards with no submission, 9 reviewers
refused for naming the parent's submission on the review card they held, and 22
`work/review` calls on the caller's own implementation card.

- SubmissionHandle (work/submission, work/review): `Latest | Id(Shown<SubmissionId>)`,
  `latest` the default and a value in the schema she sees. One resolver,
  `SubmissionHandle::read`: a code card's newest through airc's `WorkCard::latest_submission`,
  a review card's through `WorkBoardProjection::candidate_for_review` on its parent.
- A card with no submission yet is a typed refusal (`SubmissionRefusal::NoneYet`) built
  on the kernel `Refusal` / `NextCall` (card 3d7931b7): `work/submit` when the card is
  hers to submit (the `work_preconditions::check` it executes under), else `work/get`.
  The next call is chosen by cause and is never the read just refused: an id that named
  nothing (or that the review binding refused) names `work/submission` at its default; a
  parent absent from this board, or the newest refused by the binding, names `work/get` on
  the parent (Cormac, review 1851ee8b).
- work/review and work/submission declare `OnDemand`: in hand only when a held card
  puts them there (`work_preconditions::in_hand`), never as core hands on every card.
- Deleted the prose these replace: `submissions_on_card`, the "submission is absent"
  NotFound, and the `withheld_from_hands` guidance for both verbs.

- Standing grounding never leaves the turn (`GroundingOffer::of`): with two schemas
  fewer in her hands, the greedy `Leveled::reduce` let an equal-salience roster take one
  more unit and dropped the activity wall (caught by
  `standing_activity_grounding_survives_history_on_the_wire`).

Validator: `replayed_refusals.json` holds the 86 refused calls copied from the captures;
`the_m5s_refused_submission_reads_replay_into_answers` replays the 64 reads on a real
projection (20 found, 16 typed none-yet, 21 guessed ids refused with a next call, 2
`auto` undecodable, 5 off-board), and `the_review_verb_is_never_offered_on_her_own_card`
covers the 22 review calls.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply
joelteply force-pushed the fable/work-tools-say-what-she-means branch from 5f81156 to 7b0b74c Compare November 7, 2026 16:55
@joelteply
joelteply merged commit 7b7d277 into canary Nov 7, 2026
44 checks passed
@joelteply
joelteply deleted the fable/work-tools-say-what-she-means branch November 7, 2026 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant