Skip to content

P5: DX4 StepEnd gains optional t, model and effort (sminos 1.27.12) - #339

Merged
SSFSKIM merged 1 commit into
masterfrom
p5-step-end-fields
Oct 29, 2026
Merged

SSFSKIM merged 1 commit into
masterfrom
p5-step-end-fields

Conversation

@SSFSKIM

@SSFSKIM SSFSKIM commented Oct 29, 2026

Copy link
Copy Markdown
Owner

DX4 step-end: the end's time and the step's model and effort, optional (sminos 1.27.12)

Remote lane A needs two things DX4's step-end didn't carry. It places a cut reply's partial text by the step's own clock (DL 132's rule, today fed by local lane A's reshaper), and it shows the session's model chip. sminos 1.27.12's plane now sends both (doperpowers branch sminos-step-end-fields). This PR types the fields, makes the fake machine produce them the way the plane does, and documents them.

The contract

step-end {turnId, agentId, step, t?, model?, effort?}. Each field is present only when the producer knows it, and is never null for unknown. Producers older than sminos 1.27.12 send none of the three.

  • t, a number: the bridge's DX5 stamp of the event that ended the step, in ms since the epoch on the machine's clock, the same as a chunk's t.

    • For a normal end, it is the step end's stamp.
    • For a step its turn cut off, it is the turn complete's stamp.
    • The bridge holds back the end of a step whose streamed blocks don't have rows yet, for at most 1 s. A held end is stamped when it is posted, so t can trail the request's finish by up to 1 s. It is never later than the loop's next step start or its turn complete. This is the same t that local lane A's reshape.ts already puts on its step-ends.
  • model and effort: what the step's DX5 step start carried.

    • For the main loop, that includes a model or effort chosen through the bridge.
    • effort is null when the request named none.
  • What a subscription knows depends on what it saw of the step:

    How the subscription learned of the step model effort
    It saw the step's start yes yes
    It began mid-step yes, from the snapshot entry's model no (the entry keeps none)
    Only from the step's chunks no no

The hub reads nothing in a subscription message's body beyond checking that it is an object (relay), so it relays both shapes as they came.

What changed

  • apps/desk-hub/src/protocol/session.ts: StepEnd gains t?: number, model?: string and effort?: string | null, with their semantics.
  • apps/desk-hub/fake-machine/recording.ts: a bridge recording's step end and turn end keep their t, and its step start keeps its effort. A synthesized recording has neither.
  • apps/desk-hub/fake-machine/session.ts: each subscription keeps what it knew of each open step's start, as sminos's plane does: the start it saw live, otherwise the snapshot entry's model alone. Its step-end carries that, plus the end's t, or the turn end's t for a step that was cut off. A mid-step watch on the fake therefore gets what a real one would.
  • apps/desk-hub/test/support/dx4-reader.ts: the reader records each step-end's body (stepEnds).
  • src/renderer/src/lane-a/stream/overlay.ts: the cast it used to reach t is gone, since the type now carries it.
  • docs/doperpowers/specs/2026-10-15-desk-design.md: the DX4 step-end row and the fake machine's rules describe the fields.
  • Tests:
    • test/protocol/session.test.ts admits the widened shapes and refuses a null model or a null t.
    • test/session-plane.test.ts checks the hub relays a widened step-end verbatim beside the old shape.
    • test/fake-machine/depth.test.ts checks the committed recording's step-ends: each one's t is the recorded end's, or the cutting turn end's, and its model and effort are its start's. It also checks that a mid-step subscriber gets model without effort, a chunk-only step gets neither, and an unstamped end gets no t.

Validation Evidence

Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)

…l (sminos 1.27.12)

sminos's plane now sends three optional fields on `step-end`, each only
when it knows it and never null for unknown, for remote lane A's cut
reply placement and model chip:

- `t`: the bridge's DX5 stamp of the event that ended the step (its step
  end, or the turn complete that cut it off), as a chunk's `t`.
- `model` and `effort`: what the step's DX5 start carried, the main
  loop's override applied; `effort` null when the request named none. A
  subscription that began mid-step has the snapshot entry's model and no
  effort; a step known only by its chunks has neither.

`StepEnd` types them. The fake machine passes a recording's stamps and
start effort through (recording.ts) and, like the plane, keeps per
subscription what it knew of each step's start (session.ts), so a
mid-step watch gets what a real one would. Dx4Reader records each
step-end's body. The hub relays a sub body verbatim, so both shapes
pass; session-plane.test.ts pins the widened one. The DX4 spec's
step-end row and the fake machine's rules say it. The overlay's cast to
reach `t` goes, the type carrying it now.

Sminos-Session: p5-desk-track-owner#b4948247 (doperpowers on macbook)
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-29T08:03:32.326102Z aafc86c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@SSFSKIM
SSFSKIM merged commit 2505e72 into master Oct 29, 2026
SSFSKIM added a commit that referenced this pull request Oct 29, 2026
…ffort (with sminos 1.27.12) for remote lane A

Sminos-Session: GUI AI agent workspace charter#37052769 (MAWS on macbook)
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.

1 participant