Skip to content

feat(session-flow): add save_point.py fill so the handoff fills every slot in one call #4156

Description

@kyle-sexton

Symptom

save_point.py new writes a shape-2 handoff skeleton carrying 19 to 22 <!-- FILL: ... --> slots (the count depends on whether the hop has a predecessor). The write procedure in reference/structure.md step 6 says to fill every slot with the Edit tool, so /session-flow:handoff issues one Edit per slot against the same file. Observed 2026-09-11: the model batched all of them in one message, the operator interrupted mid-batch, eight edits came back rejected or with a missing tool result, and it took two more turns to find and refill the gaps.

Ruled out

  • Not a harness defect: each Edit succeeds when run; the failures were the interrupt cancelling the tail of a batch.
  • Not fixable by asking the model to Write the whole file: that retypes a 300-line file whose deterministic fields the validator then has to re-check, which is the transcription risk the script exists to remove.

Mechanism

The script owns every deterministic field and leaves the model the reasoning slots, which is right. But the fill step has no script surface, so the only tool that fits a slot is Edit, and the slot count is the write count.

Fix shape

save_point.py fill <file> --slots <json>: one JSON object keyed by slot name whose values replace the matching slot spans in one write; an optional slot absent from the JSON is deleted with its line; an unknown key or a missing required slot is a refusal naming it with the file untouched. The procedure becomes new, one Write of the JSON, fill, validate, emit.

Source: handoff-inbox/in-progress/20260911-052500-session-flow-handoff-one-edit-per-fill-slot.md (local queue, not in any repo).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions