lazymartha#6 package 4: the crew strip, the room pane and the editor tab (#13 folded in) #14

Closed
opened 2026-12-02 12:15:12 +00:00 by titan · 1 comment
Member

Purpose (feature): the one-stop TUI's remaining panes — every member's dashboard row as a strip, the crew room, and the martha.json editor as a tab — with #13 folded in, so no key the owner types can hold the screen.

Placed by Mars 2026-12-02 (Supervisor ruling): "martha-ai/lazymartha#6 package 4, with lazymartha#13 folded in (same Update loop). Order: (1) the crew strip and the editor tab first; (2) then wire the room pane to martha room --follow from 4a ... Wire it to the JSON-lines shape 4a actually lands, not a guess; read it on martha main once it lands. Package 4 lands after 4a."

Two more Supervisor rulings, 2026-12-02:

  • "(1) The editor-tab save is option (a). The tab writes its proposal to a temp file (as in today's --out handshake) and calls martha declare --from <file>, which checks it and writes the declaration. On refusal, show martha's stderr in the tab and keep the owner's edits, the way --message works today. That command doesn't exist yet: Hygiea builds it in martha now and will tell you the exact command line and exit codes. Package 4 lands after it."
  • "(2) Fold in a --prompt <text> flag on lazymartha crew: send as the first turn to the members today's tmux path would reach, with the same meaning as martha#134. Ceres's martha#367 will forward martha up --prompt to it."

Done when

  1. The crew strip reads every drawn member's dashboard row (today only a Claude Code member's row is read) and draws martha's own strip words above the panes: the header <online>/<members> online · <waiting> waiting · <needs> need you, and one line per member <name>: <state> · <task> <step>/<of> · <holds> · waits on <who> for <what> · needs you: <needs>, with the spend the row carries. A row quiet past the crew's offline time reads offline. These are the words martha crew draws (martha see_the_crew, draw_the_crew_strip), ported, never invented here.
  2. The room pane (f10) runs one child --room (martha room --follow by default) and draws what it prints, as Saturnus fixed it for martha#364 part 2 (branch saturnus/364-room-command). Each line is told apart by its key: a message (position, from, to, text, sent_at, by_owner) is drawn oldest first with the sender; {"sent":n} is an acknowledgement and draws nothing (the line comes back as a message marked by_owner); {"refused":"..."} is shown where the room is. A line typed there goes to the child's stdin as {"to":"crew","text":...}. A whole-command refusal (stdout silent, one line on stderr, non-zero exit) says why where the room would be drawn, and the child is not restarted. The command's keys may be added to, never renamed or dropped.
  3. The martha.json editor is a tab (f11): its schema is read from martha schema, so the tab hard-codes no field and no path and refuses a schema major it does not know in one line, as the handshake refuses today. Every key goes to the editor while the tab is open, and the crew's keys come back when it closes. A save writes the proposal to a temp file in the crew's own state directory and runs martha declare --from <file>, which checks it and writes the declaration (Supervisor's ruling above). Lazymartha writes no declaration and validates none. A refusal is shown in the tab, with the owner's edits kept, as --message keeps them today.
  4. --prompt <text> is the first turn for every member the screen starts, with martha#134's meaning: an engine member is sent it once its session opens (over ACP, since --acp takes no other word), and a Claude Code member's own start is handed --prompt <text>.
  5. #13: no key can hold the screen's loop on a pty write. Each terminal has one writer of its own draining a bounded queue, and a CLI that has stopped reading its keys is named on the screen instead of stopping the crew.
  6. go vet ./..., gofmt and the whole go test ./... pass; no test reaches an outside service.

Files

  • internal/crew/rows.go — the row as the strip reads it: holds, task, progress, waits and spend beside the state and needs it already reads
  • internal/crew/strip.go (new) — the strip's header and member lines, ported from see_the_crew
  • internal/crew/model.go, internal/crew/view.go, internal/crew/events.go — the strip above the panes; the room and the editor as views over the pane area
  • internal/crew/live.go — every drawn member's row watched; the room child and the handed first prompt
  • internal/room/room.go (new) — martha room --follow as a child: its admitted lines, the owner's line
  • internal/terminal/terminal.go — one writer per terminal over a bounded queue (#13)
  • internal/editor/editor.go — a save that keeps the tab running, and a declaration marked saved
  • cmd/lazymartha/crew.go — the keys, the flags, and the wiring

Refs #6, #13, martha-ai/martha#134, martha-ai/martha#364

Purpose (feature): the one-stop TUI's remaining panes — every member's dashboard row as a strip, the crew room, and the martha.json editor as a tab — with #13 folded in, so no key the owner types can hold the screen. Placed by Mars 2026-12-02 (Supervisor ruling): "martha-ai/lazymartha#6 package 4, with lazymartha#13 folded in (same Update loop). Order: (1) the crew strip and the editor tab first; (2) then wire the room pane to `martha room --follow` from 4a ... Wire it to the JSON-lines shape 4a actually lands, not a guess; read it on martha main once it lands. Package 4 lands after 4a." Two more Supervisor rulings, 2026-12-02: - "(1) The editor-tab save is option (a). The tab writes its proposal to a temp file (as in today's --out handshake) and calls `martha declare --from <file>`, which checks it and writes the declaration. On refusal, show martha's stderr in the tab and keep the owner's edits, the way --message works today. That command doesn't exist yet: Hygiea builds it in martha now and will tell you the exact command line and exit codes. Package 4 lands after it." - "(2) Fold in a `--prompt <text>` flag on `lazymartha crew`: send <text> as the first turn to the members today's tmux path would reach, with the same meaning as martha#134. Ceres's martha#367 will forward `martha up --prompt` to it." ## Done when 1. **The crew strip** reads every drawn member's dashboard row (today only a Claude Code member's row is read) and draws martha's own strip words above the panes: the header `<online>/<members> online · <waiting> waiting · <needs> need you`, and one line per member `<name>: <state> · <task> <step>/<of> · <holds> · waits on <who> for <what> · needs you: <needs>`, with the spend the row carries. A row quiet past the crew's offline time reads `offline`. These are the words `martha crew` draws (martha `see_the_crew`, `draw_the_crew_strip`), ported, never invented here. 2. **The room pane** (`f10`) runs one child `--room` (`martha room --follow` by default) and draws what it prints, as Saturnus fixed it for martha#364 part 2 (branch `saturnus/364-room-command`). Each line is told apart by its key: a message (`position`, `from`, `to`, `text`, `sent_at`, `by_owner`) is drawn oldest first with the sender; `{"sent":n}` is an acknowledgement and draws nothing (the line comes back as a message marked `by_owner`); `{"refused":"..."}` is shown where the room is. A line typed there goes to the child's stdin as `{"to":"crew","text":...}`. A whole-command refusal (stdout silent, one line on stderr, non-zero exit) says why where the room would be drawn, and the child is not restarted. The command's keys may be added to, never renamed or dropped. 3. **The martha.json editor is a tab** (`f11`): its schema is read from `martha schema`, so the tab hard-codes no field and no path and refuses a schema major it does not know in one line, as the handshake refuses today. Every key goes to the editor while the tab is open, and the crew's keys come back when it closes. A save writes the proposal to a temp file in the crew's own state directory and runs `martha declare --from <file>`, which checks it and writes the declaration (Supervisor's ruling above). Lazymartha writes no declaration and validates none. A refusal is shown in the tab, with the owner's edits kept, as `--message` keeps them today. 4. **`--prompt <text>`** is the first turn for every member the screen starts, with martha#134's meaning: an engine member is sent it once its session opens (over ACP, since `--acp` takes no other word), and a Claude Code member's own start is handed `--prompt <text>`. 5. **#13**: no key can hold the screen's loop on a pty write. Each terminal has one writer of its own draining a bounded queue, and a CLI that has stopped reading its keys is named on the screen instead of stopping the crew. 6. `go vet ./...`, gofmt and the whole `go test ./...` pass; no test reaches an outside service. ## Files - `internal/crew/rows.go` — the row as the strip reads it: holds, task, progress, waits and spend beside the state and needs it already reads - `internal/crew/strip.go` (new) — the strip's header and member lines, ported from `see_the_crew` - `internal/crew/model.go`, `internal/crew/view.go`, `internal/crew/events.go` — the strip above the panes; the room and the editor as views over the pane area - `internal/crew/live.go` — every drawn member's row watched; the room child and the handed first prompt - `internal/room/room.go` (new) — `martha room --follow` as a child: its admitted lines, the owner's line - `internal/terminal/terminal.go` — one writer per terminal over a bounded queue (#13) - `internal/editor/editor.go` — a save that keeps the tab running, and a declaration marked saved - `cmd/lazymartha/crew.go` — the keys, the flags, and the wiring Refs #6, #13, martha-ai/martha#134, martha-ai/martha#364
Author
Member

Landed: main is 876f0fb9, the tip Mercurius passed at r=4 (PR 15, fast-forward onto main).

CI: run 6972 green on that exact tip; main push run 7020 green on the same commit.

Reviews along the way: r=1 FAIL, r=2 FAIL, r=3 PASS with Mercurius's inline fix at 33d2bfe, r=4 PASS (diff-only) on the settle fix.

What landed: the crew strip in martha's own words, the room pane (f10) on martha room --follow, the editor tab (f11) saving through martha declare --from, --prompt with a Claude Code member's first turn typed into its own terminal once its composer settles, and #13's key queue folded in.

Package 4 of the design on #6 (comment 8053). The v0.1.2 tag is Raf's through Supervisor; Ceres pins it in martha#367.

Landed: main is 876f0fb9, the tip Mercurius passed at r=4 (PR 15, fast-forward onto main). CI: run 6972 green on that exact tip; main push run 7020 green on the same commit. Reviews along the way: r=1 FAIL, r=2 FAIL, r=3 PASS with Mercurius's inline fix at 33d2bfe, r=4 PASS (diff-only) on the settle fix. What landed: the crew strip in martha's own words, the room pane (f10) on `martha room --follow`, the editor tab (f11) saving through `martha declare --from`, `--prompt` with a Claude Code member's first turn typed into its own terminal once its composer settles, and #13's key queue folded in. Package 4 of the design on #6 (comment 8053). The v0.1.2 tag is Raf's through Supervisor; Ceres pins it in martha#367.
titan closed this issue 2026-12-02 15:42:35 +00:00
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
martha-ai/lazymartha#14
No description provided.