flow-workflows 0.114.0 → 0.115.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -4
- package/adapters/codex/CORE.md +142 -134
- package/adapters/codex/skills/flow-bug-fix/SKILL.md +1 -1
- package/adapters/codex/skills/flow-bug-ship/SKILL.md +1 -1
- package/adapters/codex/skills/flow-doctor/SKILL.md +1 -1
- package/adapters/codex/skills/flow-feat-build/SKILL.md +2 -2
- package/adapters/codex/skills/flow-feat-ship/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-README/SKILL.md +5 -5
- package/adapters/codex/skills/flow-work-abandon/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-daily/SKILL.md +1 -1
- package/adapters/codex/skills/flow-work-handoff/SKILL.md +4 -3
- package/adapters/codex/skills/flow-work-resume/SKILL.md +8 -24
- package/adapters/gemini/CORE.md +142 -134
- package/adapters/gemini/commands/flow/bug/fix.toml +1 -1
- package/adapters/gemini/commands/flow/bug/ship.toml +1 -1
- package/adapters/gemini/commands/flow/doctor.toml +1 -1
- package/adapters/gemini/commands/flow/feat/build.toml +2 -2
- package/adapters/gemini/commands/flow/feat/ship.toml +1 -1
- package/adapters/gemini/commands/flow/work/README.toml +5 -5
- package/adapters/gemini/commands/flow/work/abandon.toml +1 -1
- package/adapters/gemini/commands/flow/work/daily.toml +1 -1
- package/adapters/gemini/commands/flow/work/handoff.toml +4 -3
- package/adapters/gemini/commands/flow/work/resume.toml +8 -24
- package/adapters/hermes/CORE.md +142 -134
- package/adapters/hermes/skills/flow-bug-fix/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-bug-ship/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-doctor/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-feat-build/SKILL.md +2 -2
- package/adapters/hermes/skills/flow-feat-ship/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-README/SKILL.md +5 -5
- package/adapters/hermes/skills/flow-work-abandon/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-daily/SKILL.md +1 -1
- package/adapters/hermes/skills/flow-work-handoff/SKILL.md +4 -3
- package/adapters/hermes/skills/flow-work-resume/SKILL.md +8 -24
- package/adapters/opencode/CORE.md +142 -134
- package/adapters/opencode/commands/flow-bug-fix.md +1 -1
- package/adapters/opencode/commands/flow-bug-ship.md +1 -1
- package/adapters/opencode/commands/flow-doctor.md +1 -1
- package/adapters/opencode/commands/flow-feat-build.md +2 -2
- package/adapters/opencode/commands/flow-feat-ship.md +1 -1
- package/adapters/opencode/commands/flow-work-README.md +5 -5
- package/adapters/opencode/commands/flow-work-abandon.md +1 -1
- package/adapters/opencode/commands/flow-work-daily.md +1 -1
- package/adapters/opencode/commands/flow-work-handoff.md +4 -3
- package/adapters/opencode/commands/flow-work-resume.md +8 -24
- package/bin/cli.mjs +546 -12
- package/package.json +1 -1
- package/plugins/flow/.claude-plugin/plugin.json +1 -1
- package/plugins/flow/CHANGELOG.md +21 -0
- package/plugins/flow/examples/FLOW.template.md +1 -0
|
@@ -100,32 +100,16 @@ With what is new (there is already work on disk):
|
|
|
100
100
|
|
|
101
101
|
## 5. Rebuild the live panel
|
|
102
102
|
|
|
103
|
-
After a break the panel is most likely stale, and a resumed session is exactly where flow-core §4 asks for `panel_get` **before** publishing: read what is on screen, then
|
|
103
|
+
After a break the panel is most likely stale, and a resumed session is exactly where flow-core §4 asks for `panel_get` **before** publishing: read what is on screen, then render it from the state just rebuilt — `panel-input.json` written whole, then the panel CLI with `--forge` (flow-core §4), whose document goes to `panel_set` where the terminal offers the panel tools:
|
|
104
104
|
|
|
105
105
|
```json
|
|
106
|
-
{
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
"header": true,
|
|
110
|
-
"lines": [
|
|
111
|
-
{"text": "<work title>", "style": "title"},
|
|
112
|
-
"",
|
|
113
|
-
{"ref": "#1", "text": "batch read sources", "mark": "wait", "link": "https://gitlab.com/…/merge_requests/9977"},
|
|
114
|
-
{"ref": "#2", "text": "per-event counters", "mark": "current"},
|
|
115
|
-
{"ref": "#3–#6", "text": "channel map · use case · detail · route", "mark": "pending"},
|
|
116
|
-
"",
|
|
117
|
-
{"ref": "Now", "text": "nothing running — just resumed", "mark": "info"},
|
|
118
|
-
{"ref": "Next", "text": "build", "mark": "info"},
|
|
119
|
-
{"ref": "Decision", "text": "run the next step, or leave it for another work", "mark": "wait"},
|
|
120
|
-
"",
|
|
121
|
-
{"text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
122
|
-
]
|
|
123
|
-
}
|
|
106
|
+
{"phase": "build", "now": "nothing running — just resumed", "next": "build",
|
|
107
|
+
"decision": "run the next step, or leave it for another work",
|
|
108
|
+
"blocks": [{"text": "sibling-repo still needs the endpoint contract"}]}
|
|
124
109
|
```
|
|
125
110
|
|
|
126
111
|
- `phase` = the phase you are resuming into (`meta.json.phase` does not yet say it).
|
|
127
|
-
- `
|
|
128
|
-
- `
|
|
129
|
-
- `
|
|
130
|
-
-
|
|
131
|
-
- `updated_at` from `date -Iseconds` when the panel goes to the file; every fact from `meta.json` and the artifacts; language of the work's artifacts.
|
|
112
|
+
- `now` in prose; `next` names the phase §4 suggested.
|
|
113
|
+
- `decision` is always set after a resume — nothing is running, the next move is the user's. It goes the moment they make it (flow-core §4.4e), not at the next stop.
|
|
114
|
+
- `blocks` for the blockers §4 surfaced (`contract_handoff` `pending` in a sibling repo, a red pipeline, an unmerged dependency); `labels` in the language of the work's artifacts.
|
|
115
|
+
- The train, the steps and each MR/PR's real state come from the CLI: never typed here.
|
package/adapters/gemini/CORE.md
CHANGED
|
@@ -16,7 +16,7 @@ Every `/flow:*` command assumes these rules. They are stated once, here, so a co
|
|
|
16
16
|
carries what is specific to its phase. Read this once per session; a command that says "load
|
|
17
17
|
`flow-core`" means this file.
|
|
18
18
|
|
|
19
|
-
**This file belongs to flow `0.
|
|
19
|
+
**This file belongs to flow `0.115.0`.** Compare it once, at the start of the session, against
|
|
20
20
|
`version` in `~/.claude/flow/.claude-plugin/plugin.json`. The two differing means the session
|
|
21
21
|
is running a **mixture** — the commands from one copy of the plugin, these shared rules from another
|
|
22
22
|
— which is exactly what happens when a branch or a release candidate is loaded over an installed
|
|
@@ -663,30 +663,76 @@ I need: <one line — the decision or action you are waiting on>
|
|
|
663
663
|
- **If it is a question, it is `AskUserQuestion`** — in `unattended`, the orchestrator's `ask` (§2.1). Never end a message with a question in prose. If it does not deserve the menu, it is a decision you take and record.
|
|
664
664
|
- **What the question is about travels with the question.** A brief, an MR/PR body, a plan, a finding: put it where the user answers it — in the question text and its options — and not only in the prose above. **Nothing runs between the two**: a tool call after that prose is what makes a terminal fold it away, and the last thing a chat UI collapses is exactly the thing they were asked to read. A gate answered without seeing what it was about is not a gate; "it is in `05-implementation.md`" is not showing it, because the answer then costs opening an editor and finding the file. Too long for the harness's question → print it as the **last** thing before asking, tool calls already done.
|
|
665
665
|
|
|
666
|
-
## 4. Live panel —
|
|
666
|
+
## 4. Live panel — rendered by `flow-workflows panel`, carried by the terminal's MCP or a file
|
|
667
667
|
|
|
668
|
-
Whenever the state a panel would show changes,
|
|
669
|
-
|
|
670
|
-
(§3).
|
|
668
|
+
Whenever the state a panel would show changes, the panel is rendered again. **Any progress line you
|
|
669
|
+
were about to type into the chat is a panel update instead** (§3).
|
|
671
670
|
|
|
672
|
-
**
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
`
|
|
677
|
-
|
|
678
|
-
transport, never instead of it.
|
|
671
|
+
**You do not write the panel; you write what only you know, and the CLI renders the rest.** The
|
|
672
|
+
title, the MR/PR train and each one's state, the plan's steps, sibling repos' MRs/PRs, what is still
|
|
673
|
+
open — all of it is already in `meta.json`, the plan's ticks and the forge, and a panel rebuilt from
|
|
674
|
+
prose loses it: the step block was published in 8 of 64 build sessions that had a plan, merged
|
|
675
|
+
MRs/PRs stayed `wait`, and panels from other harnesses lost their clock, their links and their
|
|
676
|
+
language. So a publication is two moves:
|
|
679
677
|
|
|
680
|
-
**
|
|
681
|
-
namespaces an MCP server's tools, so what you are looking for is a tool whose name *ends* in
|
|
682
|
-
`panel_set` — `mcp__panel__panel_set` on Claude Code, another prefix elsewhere — and the name is
|
|
683
|
-
whatever it is called there, not `panel_set`. It may also be **deferred**: listed by name with no
|
|
684
|
-
schema, uncallable until you load it, and indistinguishable from absent unless you read that list.
|
|
685
|
-
A deferred tool is a tool that is there; load the three schemas and publish. The file is the answer
|
|
686
|
-
only after that search comes back empty — and this is the one paragraph that decides it, because
|
|
687
|
-
prose describing a file is otherwise obeyed to the letter.
|
|
678
|
+
1. **Write `.claude/work/<work>/panel-input.json`** — whole, every time, only what this moment knows:
|
|
688
679
|
|
|
689
|
-
|
|
680
|
+
```json
|
|
681
|
+
{"phase": "build", "now": "unit suite over #2", "next": "review #2",
|
|
682
|
+
"decision": "confirm the MR/PR body before I create it", "attention": "wait",
|
|
683
|
+
"blocks": [{"text": "sibling-repo still needs the endpoint contract", "link": "https://…"}],
|
|
684
|
+
"stale_after_minutes": 45,
|
|
685
|
+
"labels": {"now": "Ahora", "next": "Siguiente", "decision": "Decisión", "open": "Abierto",
|
|
686
|
+
"closed": "nada más aquí", "review": "ronda de review", "findings": "abiertos",
|
|
687
|
+
"followups": "seguimientos"}}
|
|
688
|
+
```
|
|
689
|
+
|
|
690
|
+
Every field is optional. `phase` is the phase **running now**. `now` is what is running — never
|
|
691
|
+
the train restated (*"MR/PR open, waiting for review"* is what the train line already says).
|
|
692
|
+
`next` is the next phase or MR/PR — never housekeeping (*archive the work*, *remove the
|
|
693
|
+
worktree*). `decision` only while parked on the user; it sets `attention: wait` by itself.
|
|
694
|
+
`blocks` are what stops the work on somebody else — a sibling repo with `contract_handoff:
|
|
695
|
+
pending`, a red pipeline, an unmerged dependency — each with its `link` when it names an MR/PR.
|
|
696
|
+
`labels` carry the fixed words in **the language of the work's artifacts**; omitted, they are
|
|
697
|
+
English. Free text lives in this file, never on a command line.
|
|
698
|
+
2. **Run `npx flow-workflows@<version> panel --harness <harness> --forge`** from the work's
|
|
699
|
+
checkout (`<version>` this plugin's own, from `~/.claude/flow/.claude-plugin/plugin.json`
|
|
700
|
+
— the rule `/flow:feat:review` §1 gives for every `flow-workflows` call). It writes
|
|
701
|
+
`.claude/work/<work>/panel.json`, writes `card.json` beside it when `panel.artifact` is set, pipes
|
|
702
|
+
the document to `panel.publish_cmd` when that is set, and prints the document. `--forge` asks
|
|
703
|
+
`gh`/`glab` for each open MR/PR and keeps the answers in `forge-state.json`, which the renders
|
|
704
|
+
without it reuse — leave it out at a plan step (§4.4 f), where nothing in the forge moved.
|
|
705
|
+
`meta.json` is never written by it.
|
|
706
|
+
|
|
707
|
+
**Where the plugin's hooks run — Claude Code and Codex — the render also happens on its own**: a
|
|
708
|
+
`PostToolUse` hook renders the panel again whenever `meta.json`, the plan, or `panel-input.json` is
|
|
709
|
+
newer than `panel.json` and than that branch's last attempt — a render that wrote nothing is not
|
|
710
|
+
retried until one of them changes again. Ticking a step in the plan *is* publishing it there. The hook cannot reach
|
|
711
|
+
the terminal's MCP tools, which is what `panel.publish_cmd` is for (§4.2).
|
|
712
|
+
|
|
713
|
+
**The CLI unavailable** — no network for npx, a sandbox that blocks it, a non-zero exit with no
|
|
714
|
+
document — → write the §4.1 document yourself, once, by its rules, and say so at the next stop:
|
|
715
|
+
`panel: written by hand — <why>`. Never retry variants of the call.
|
|
716
|
+
|
|
717
|
+
**One panel is drawn by hand on purpose**: `/flow:work:watch` paints a monitoring cycle — verdict, latency, what it is waiting for — that no work file holds, so it writes its §5 document itself, by §4.1's rules, and the CLI is not run while it watches.
|
|
718
|
+
|
|
719
|
+
**Two transports for the one document.** When the tools `panel_set` / `panel_get` are available,
|
|
720
|
+
this console is a pane of a terminal that paints what reaches it over its MCP (§4.2). Whatever the
|
|
721
|
+
transport, `panel.json` is written — by the CLI — because the session-start hook reads its `Now` and
|
|
722
|
+
`phase` to say what the last session was doing. No work folder (lightweight `respond`/`green`) →
|
|
723
|
+
nothing to publish, either way. With `panel.artifact` set, each publication is also mirrored to a
|
|
724
|
+
claude.ai page that gathers every work of every repo (§4.6) — in addition to the transport, never
|
|
725
|
+
instead of it.
|
|
726
|
+
|
|
727
|
+
**Look for the tools before you conclude they are missing**, once per session, in pre-flight. A
|
|
728
|
+
harness namespaces an MCP server's tools, so what you are looking for is a tool whose name *ends* in
|
|
729
|
+
`panel_set` — `mcp__panel__panel_set` on Claude Code, another prefix elsewhere. It may also be
|
|
730
|
+
**deferred**: listed by name with no schema, uncallable until you load it, and indistinguishable from
|
|
731
|
+
absent unless you read that list. A deferred tool is a tool that is there; load the schemas and
|
|
732
|
+
publish. A tool that answers that this console is not one of its panes → the file is the transport
|
|
733
|
+
for the rest of the session.
|
|
734
|
+
|
|
735
|
+
### 4.1 The document — what the CLI prints, and what you write when it cannot
|
|
690
736
|
|
|
691
737
|
```json
|
|
692
738
|
{
|
|
@@ -694,105 +740,76 @@ prose describing a file is otherwise obeyed to the letter.
|
|
|
694
740
|
"phase": "validate",
|
|
695
741
|
"header": true,
|
|
696
742
|
"lines": [
|
|
697
|
-
{"text": "Expose a thread's tracking state and events", "style": "title"},
|
|
743
|
+
{"key": "title", "text": "Expose a thread's tracking state and events", "style": "title"},
|
|
744
|
+
"",
|
|
745
|
+
{"key": "mr-1", "ref": "#1", "text": "batch read sources", "mark": "wait", "link": "https://gitlab.com/…/merge_requests/9977"},
|
|
746
|
+
{"key": "mr-1-state", "text": "pipeline passed · 0/1 approvals · 2 open threads", "mark": "info", "indent": 4},
|
|
747
|
+
{"key": "mr-2", "ref": "#2", "text": "per-event and per-recipient counters", "mark": "current"},
|
|
748
|
+
{"key": "step-1", "ref": "1", "text": "counter columns + migration", "mark": "done", "indent": 4},
|
|
749
|
+
{"key": "step-2", "ref": "2", "text": "per-recipient aggregation in the use case", "mark": "current", "indent": 4},
|
|
750
|
+
{"key": "step-3", "ref": "3", "text": "expose both counters on the endpoint", "mark": "pending", "indent": 4},
|
|
751
|
+
{"key": "mr-3-6", "ref": "#3–#6", "text": "channel map · use case · document detail · route", "mark": "pending"},
|
|
752
|
+
"",
|
|
753
|
+
{"key": "sib-1", "ref": "mcp !71", "text": "pipeline running", "mark": "wait", "link": "https://gitlab.com/…/mcp/-/merge_requests/71"},
|
|
698
754
|
"",
|
|
699
|
-
{"
|
|
700
|
-
{"ref": "#2", "text": "per-event and per-recipient counters", "mark": "current"},
|
|
701
|
-
{"ref": "1–2", "text": "counter columns + migration · repository query", "mark": "done", "indent": 4},
|
|
702
|
-
{"ref": "3", "text": "per-recipient aggregation in the use case", "mark": "current", "indent": 4},
|
|
703
|
-
{"ref": "4", "text": "expose both counters on the endpoint", "mark": "pending", "indent": 4},
|
|
704
|
-
{"ref": "#3–#6", "text": "channel map · use case · document detail · route", "mark": "pending"},
|
|
755
|
+
{"key": "open", "ref": "Open", "text": "review round 2 · 1 open · 2 follow-ups", "mark": "info"},
|
|
705
756
|
"",
|
|
706
|
-
{"ref": "Now", "text": "unit suite and the test agent over #2", "mark": "info"},
|
|
707
|
-
{"ref": "Next", "text": "ship #2", "mark": "info"},
|
|
708
|
-
{"ref": "Decision", "text": "confirm the MR/PR body before I create it", "mark": "wait"},
|
|
757
|
+
{"key": "now", "ref": "Now", "text": "unit suite and the test agent over #2", "mark": "info"},
|
|
758
|
+
{"key": "next", "ref": "Next", "text": "ship #2", "mark": "info"},
|
|
759
|
+
{"key": "decision", "ref": "Decision", "text": "confirm the MR/PR body before I create it", "mark": "wait"},
|
|
709
760
|
"",
|
|
710
|
-
{"text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
761
|
+
{"key": "block-1", "text": "sibling-repo still needs the endpoint contract", "mark": "block"}
|
|
711
762
|
]
|
|
712
763
|
}
|
|
713
764
|
```
|
|
714
765
|
|
|
715
|
-
- **`mark` says what a line is**; the reader draws it. `done` · `current` (at most one per block) · `pending` · `wait` (waiting on someone else: an open MR/PR, a user decision) · `block` · `info`.
|
|
716
|
-
- **`
|
|
717
|
-
-
|
|
718
|
-
- **
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
- **
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
**
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
first: the worst case is that nothing happened and you were told why.
|
|
751
|
-
- **A patch whose answer never arrived may have been applied — send it again.** The resend is
|
|
752
|
-
refused rather than doubling the line.
|
|
753
|
-
- At most 64 ops per call. `actions` are not patchable: change buttons with a whole `panel_set`.
|
|
754
|
-
- Republish with `panel_set` only when the *shape* changes (a new MR/PR train, a different body).
|
|
755
|
-
|
|
756
|
-
**Refusals are information, not noise.** `no line of this panel carries the key "…"` → your keys and
|
|
757
|
-
the panel disagree: `panel_get` and republish. `publish with panel_set before patching` → this pane
|
|
758
|
-
is still on its file. `this panel is held by "…"` → another producer owns it; do not fight it, say
|
|
759
|
-
so at the next stop.
|
|
760
|
-
|
|
761
|
-
**After a compaction, a restart or a resumed work**, call `panel_get` **before publishing**. It
|
|
762
|
-
returns the document on screen — yours or one that arrived by file — and publishing it back leaves
|
|
763
|
-
the panel exactly as it is. What comes back is the document as the app understood it: unknown fields
|
|
764
|
-
are gone and defaults come back absent.
|
|
765
|
-
|
|
766
|
-
**Optional — buttons at a stop.** At a stop parked on the user, `actions` (up to 8) paint a button
|
|
767
|
-
whose command is shown literally and is written into this pane's program on one click — which here
|
|
768
|
-
is this very session's prompt. So `{"label": "Approve the design", "send": "approve"}` answers you
|
|
769
|
-
without the user typing. Plain text, no line breaks, never a credential: it is painted on screen and
|
|
770
|
-
lands in the shell history.
|
|
771
|
-
|
|
772
|
-
### 4.3 Without those tools — `.claude/work/<work>/panel.json`
|
|
773
|
-
|
|
774
|
-
Overwrite the file **whole** (never patch) with the §4.1 document. `updated_at` from the real clock
|
|
775
|
-
(`date -Iseconds`), never carried over — it is how the reader flags a stale snapshot. `attention`
|
|
776
|
-
and `key` buy nothing here: the file panel is drawn from `mark` and `ref` alone.
|
|
766
|
+
- **`mark` says what a line is**; the reader draws it. `done` · `current` (at most one per block) · `pending` · `wait` (waiting on someone else: an open MR/PR, a user decision) · `block` · `info`. Do not set `style` on a marked line — except `mark: "info"` + `style: ok|warn|error` when the colour *is* the information (a monitoring verdict, the closing line).
|
|
767
|
+
- **`link` is a field, never a URL inside `text`**, and every line that names an MR/PR carries it.
|
|
768
|
+
- **Order:** the title (`meta.json.title` without the ticket id: `header: true` draws ticket, type, phase and age); the MR/PR train, one entry per `meta.json.mrs[]` (a single MR/PR from `mr_url`), not-started ones folded into one `#a–#z` line, each open one followed by its state from the forge; under the MR/PR being built — or the bug in `fix` — its plan's steps from the ticks, never ahead of them, at most five lines (past three done they fold, a long pending tail folds); sibling repos' MRs/PRs; one `Open` line for the latest review round's open findings and the open follow-ups; `Now`, `Next`, `Decision`; blockers. A finished work (`meta.json.phase` `done`) shows its train, one `info`/`ok` closing line and `attention: done`, and nothing else.
|
|
769
|
+
- **Rules:** every fact from `meta.json`, the artifacts and the forge — an invented MR/PR state is worse than a blank panel. Keep it under ~14 lines.
|
|
770
|
+
|
|
771
|
+
### 4.2 Over the terminal's MCP — `panel_set` with what the CLI printed
|
|
772
|
+
|
|
773
|
+
**Every publication is one `panel_set`** — `source: "flow"`, `document` the JSON the CLI just
|
|
774
|
+
printed, which already carries a `key` on every line and the top-level `attention`: `wait` when
|
|
775
|
+
parked on the user, `block` when stuck on somebody else, `done` when the work closed, absent while
|
|
776
|
+
simply working. The terminal never deduces it from the body, and a `wait` left behind flags that tab
|
|
777
|
+
for ever — so the next render, which drops the `decision`, is what clears it. The first `panel_set`
|
|
778
|
+
claims the pane for as long as this session lives; a second producer is refused by name.
|
|
779
|
+
|
|
780
|
+
- `panel_patch` is for the CLI-unavailable case only (§4): there, patch by `key` rather than
|
|
781
|
+
rebuild — ops `replace`, `before`, `after`, `delete`, `first`, `last`, `set` (`phase`,
|
|
782
|
+
`attention`, `header`, `stale_after_minutes`); the whole list applies or none of it does, and a
|
|
783
|
+
resend of a patch whose answer never arrived is refused rather than doubling a line.
|
|
784
|
+
- **Refusals are information.** `this panel is held by "…"` → another producer owns it; do not fight
|
|
785
|
+
it, say so at the next stop.
|
|
786
|
+
- **After a compaction, a restart or a resumed work**, call `panel_get` before publishing: it returns
|
|
787
|
+
what is on screen, which may have arrived from elsewhere.
|
|
788
|
+
- **A hook cannot call these tools.** Where the reader is a terminal like this one, the person sets
|
|
789
|
+
`panel.publish_cmd`, in a git-ignored FLOW file, to whatever command that terminal offers for
|
|
790
|
+
publishing a document from a shell; the CLI pipes every render into it, the hook's included.
|
|
791
|
+
- **Optional — buttons at a stop.** At a stop parked on the user, `actions` (up to 8) paint a button
|
|
792
|
+
whose command is written into this pane's program on one click — this very session's prompt. Add
|
|
793
|
+
them to the printed document before `panel_set`: `{"label": "Approve the design", "send":
|
|
794
|
+
"approve"}`. Plain text, no line breaks, never a credential.
|
|
795
|
+
|
|
796
|
+
### 4.3 Without those tools — the file is the transport
|
|
797
|
+
|
|
798
|
+
`panel.json` is what the CLI already wrote: nothing else to do. Written by hand (the CLI
|
|
799
|
+
unavailable), overwrite the file **whole** with the §4.1 document and `updated_at` from the real
|
|
800
|
+
clock (`date -Iseconds`), never carried over — it is how a reader flags a stale snapshot.
|
|
777
801
|
|
|
778
802
|
### 4.4 When to publish — whichever transport is in play
|
|
779
803
|
|
|
780
804
|
(a) In pre-flight, as soon as `meta.json` is loaded; (b) immediately **before** every stop header;
|
|
781
805
|
(c) **before** any long stretch (fan-out, full suite, CI poll) — never after, so a step that dies
|
|
782
806
|
halfway is not shown as finished. When the stretch will outlast the ~30 min staleness warning, set
|
|
783
|
-
`stale_after_minutes` to what it will really take; (d) wherever `## Close` updates
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
the
|
|
788
|
-
|
|
789
|
-
that never asked, because they answered it and the screen says it did not land; and an `attention`
|
|
790
|
-
nobody clears keeps that tab claiming them for ever. The same applies to a blocker that lifted and
|
|
791
|
-
to a `wait` line whose MR/PR merged.
|
|
792
|
-
|
|
793
|
-
**(f) Each plan step that lands** (the (2b) block): one patch, the moment its tick goes into the
|
|
794
|
-
phase artifact — that step to `done`, the next to `current`, `Now` moved on. Not batched at the end
|
|
795
|
-
of the MR/PR: a list that jumps from nothing to finished told the user nothing while it mattered.
|
|
807
|
+
`stale_after_minutes` in the input to what it will really take; (d) wherever `## Close` updates
|
|
808
|
+
`meta.json`; (e) **the moment a question is answered or a gate is cleared** — before you resume the
|
|
809
|
+
work: drop `decision` from the input, move `now` on, render. A panel still asking what the user
|
|
810
|
+
already answered is worse than one that never asked; (f) **each plan step that lands** — tick it in
|
|
811
|
+
the phase artifact, move `now` on, render without `--forge`. Where the plugin's hook runs, the tick
|
|
812
|
+
and the input change already rendered it; publish over the tools anyway when they are there.
|
|
796
813
|
|
|
797
814
|
### 4.5 `meta.json.cost[]` — what a phase measured, when it could
|
|
798
815
|
|
|
@@ -833,26 +850,17 @@ section does not exist: no artifact tool is loaded or called.
|
|
|
833
850
|
(f), a plan step, only when the card's last write is 10 minutes old or more: every write is a
|
|
834
851
|
tool call, and outside auto mode a prompt, while a card left alone for 30 minutes reads as a dead
|
|
835
852
|
session on the page.
|
|
836
|
-
- **What**:
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
panel clears `attention` and carries a `block` line; the card says `done`). An open MR/PR
|
|
846
|
-
waiting to merge is not over. The page reads the state from this field alone.
|
|
847
|
-
- `repo` (the repo id below), `work` (the work folder's name), `ticket`, `type`, `branch`, and
|
|
848
|
-
`harness` (`Claude Code`), from `meta.json` and git.
|
|
853
|
+
- **What**: `card.json`, which the CLI writes beside `panel.json` whenever `panel.artifact` is set
|
|
854
|
+
— the rendered document plus `repo`, `work`, `ticket`, `type`, `branch` and `harness` — passed as
|
|
855
|
+
`file_path` to the `set`. Never a document rebuilt in your head. Its `attention` is the
|
|
856
|
+
document's: `done` once `meta.json.phase` is `done`, or once every MR/PR of the work and every MR/PR
|
|
857
|
+
recorded for its sibling repos has merged (the forge's word counts) with no Decision or blocker left in the
|
|
858
|
+
session's own input; an abandoned work claims nobody (its input carries only the `block` line
|
|
859
|
+
saying why); an open MR/PR waiting to merge is not over. The page reads
|
|
860
|
+
the state from that field alone. The CLI unavailable → the hand-written §4.1 document with those
|
|
861
|
+
six fields added.
|
|
849
862
|
- **Where**: action `set` — the whole document, so a line dropped from the panel leaves the card —
|
|
850
|
-
`url` the key's value, collection `works`, doc id `<repo
|
|
851
|
-
path of `git remote get-url origin` — everything after the host, which ends at the first `/` after
|
|
852
|
-
`//` (`https://host/owner/repo.git`, `ssh://git@host:22/owner/repo.git`) or at the first `:`
|
|
853
|
-
(`git@host:owner/repo.git`) — with `.git` dropped and every `/` turned into `.`: `owner.repo`,
|
|
854
|
-
`group.subgroup.repo`. No remote → the main checkout's directory name (§0). Any character outside
|
|
855
|
-
`[A-Za-z0-9_.~:@+-]` becomes `-`.
|
|
863
|
+
`url` the key's value, collection `works`, doc id `<repo>--<work>`, both read from `card.json`.
|
|
856
864
|
- **Version**: a write to a card that exists needs `if_version`, the version the last write
|
|
857
865
|
returned. Keep it in the session — one writer per card, so it is right until the session loses
|
|
858
866
|
it. None held → one `get` first: the card exists → pin to its version; it does not → write
|
|
@@ -865,14 +873,14 @@ section does not exist: no artifact tool is loaded or called.
|
|
|
865
873
|
mirror off or the key empty → nothing to do. A folder moved back out of `_archive/` gets its card
|
|
866
874
|
again at its next publication.
|
|
867
875
|
- **A card whose MR/PR moved without its session.** A merge or a close done in the forge has no
|
|
868
|
-
session to write it, and the card keeps asking. `/flow:work:daily` and `/flow:work:clean`
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
`
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
next phase, or `clean`, closes it.
|
|
876
|
+
session to write it, and the card keeps asking. `/flow:work:daily` and `/flow:work:clean` read
|
|
877
|
+
`works` once (`list`) when the mirror is on, and for each card of this repo whose train still
|
|
878
|
+
shows an MR/PR open, run `panel --harness <harness> --work <work> --forge` and `set` the
|
|
879
|
+
`card.json` it wrote — the forge's answer turns that line `done` or `block`, and the card closes
|
|
880
|
+
(`attention: done`, no Decision) once every MR/PR of the work, siblings included, has merged:
|
|
881
|
+
rendered for another branch, the input is that session's last word, not a live question. Such a
|
|
882
|
+
render writes only the card: that work's `panel.json` is its own session's pane. Same version pinning as above; `meta.json` is not
|
|
883
|
+
touched — the work's own next phase, or `clean`, closes it.
|
|
876
884
|
- **Failure never stops a phase.** A second version refusal → no more retries for that
|
|
877
885
|
publication. Any other failure — a wrong URL, auth, a permission prompt the user declined — turns
|
|
878
886
|
the mirror off for the rest of the session. Either way the next stop carries one line,
|
|
@@ -121,7 +121,7 @@ Save it in `04-fix.md` under `## Plan`, right after the brief. **A fix that was
|
|
|
121
121
|
|
|
122
122
|
- Apply the minimal fix targeting the finding of `03-investigation.md` (or the diagnosis if investigate was skipped).
|
|
123
123
|
- Sensitive area (authentication, payments, sensitive data) → consult the `agents.architecture` agent from FLOW.md to confirm the correct layer; empty → check against `conventions` in FLOW.md.
|
|
124
|
-
- More than 2 fix steps → the §2.0bis plan is already written: tick its numbered steps off in `04-fix.md` where they stand, and
|
|
124
|
+
- More than 2 fix steps → the §2.0bis plan is already written: tick its numbered steps off in `04-fix.md` where they stand, and render the panel as each lands — the panel CLI draws the steps from those ticks (flow-core §4.1, §4.4 (f)); a harness task list, if there is one, goes on top as `/flow:feat:build §2.1` says. One task per step, same order, marked `in_progress` and `completed` as they go — not batched.
|
|
125
125
|
- **Comment discipline**: comment only a *why* the code cannot say (a non-obvious constraint, the reason for a workaround, a subtle invariant); match the surrounding file's comment density. **Never write the ticket ID or "fix for #N" into a code comment** — that lives in the commit/branch/MR-PR.
|
|
126
126
|
- Keep the log updated while editing.
|
|
127
127
|
|
|
@@ -197,7 +197,7 @@ posted as comments anchored on the changed lines of the MR/PR, confirmed in ever
|
|
|
197
197
|
- **A worktree does not own the tree its tools wrote into — `/flow:feat:ship` §5.5, in full and unchanged.** First, before anything below: `meta.json.worktree` not null → read the main checkout's `git status --porcelain`, name any paths it holds in one line as what they are (in the main checkout, not in the branch just pushed, and not necessarily put there by this run), and offer once to carry them over. The knowledge files are no longer the expected case — flow-core §0 step 4 moved them into the worktree before the commit, whether `postmortem` or §3.1 saved them — so what is left here is another tool's output, or a move that went wrong.
|
|
198
198
|
- **Knowledge still owed — `/flow:feat:ship` §5, in full and unchanged**: `meta.json.knowledge.status` `later` or `failed` → offered once on this re-run; onto the open branch, or a knowledge-only MR/PR once the fix merged.
|
|
199
199
|
- Update `meta.json`: add `ship` to `phases_done`, update `updated_at`. **`phase` becomes `done` only once the MR/PR is confirmed merged** — creating it is not finishing it. Right after §3.1 it is open, so ask once with `AskUserQuestion` whether it has already been merged: **no** (the normal answer) → leave `phase = "ship"`; **yes** → `phase = "done"`. `/flow:work:green` and `/flow:work:respond` work on the open MR/PR; `/flow:work:clean` only sweeps what merged.
|
|
200
|
-
-
|
|
200
|
+
- Render the panel (flow-core §4, with `--forge`): while the MR/PR is open its line is `wait` with its real state; once merged it is `done`, and at `phase = "done"` the CLI closes the panel itself. Drop `decision` from the input either way.
|
|
201
201
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
202
202
|
- **Tracker: move to done.** **Only when this ship set `phase = "done"`** (merge confirmed just above) and `tracker.tool` is not `none`/empty, `tracker.done_cmd` is set, and `meta.json.ticket` is a **real tracker id**: run `tracker.done_cmd` with `{TICKET}` = `meta.json.ticket`. Never on an open MR/PR. If the answer was "not merged", skip silently — the transition belongs to whoever confirms the merge (`/flow:work:clean` reports the branch as merged, and re-running this close is legitimate). Same contract as `/flow:bug:start §4.5`: **best-effort, idempotent, gated** (ask once in `autonomy.mode: manual`; automatic in `guided`/`auto`); failure or already-done ticket → warn and continue, never block. **Leave `tracker.done_cmd` empty on GitHub/GitLab** — `Closes #N` already auto-closes on merge; this is for Jira/Linear-style trackers.
|
|
203
203
|
- Summarize: ticket, MR/PR URL, regression test added.
|
|
@@ -221,7 +221,7 @@ refuse) · **degraded** (it runs, quietly worse than the config promises), plus
|
|
|
221
221
|
`.agents/agents`, or a plugin. Report each missing name and that it falls back per flow-core §6.6 — the installed agent
|
|
222
222
|
that fits, else `general-purpose` (a skill: skipped) — a panel missing agents reviews less and still reports a clean pass.
|
|
223
223
|
- Harness cannot set a model per subagent → note that every `models.*` value degrades to inheritance.
|
|
224
|
-
- **Where the live panel will go this session** (flow-core §4): a tool whose name ends in `panel_set` / `panel_patch` — namespaced by the harness (`mcp__panel__panel_set` on Claude Code) and possibly **deferred**, which reads as absent until the list of deferred tools is checked → the terminal draws the panel
|
|
224
|
+
- **Where the live panel will go this session** (flow-core §4): a tool whose name ends in `panel_set` / `panel_patch` — namespaced by the harness (`mcp__panel__panel_set` on Claude Code) and possibly **deferred**, which reads as absent until the list of deferred tools is checked → the terminal draws the panel; genuinely absent → `panel.json` is the transport. Either way the panel CLI writes `panel.json`; with `panel.publish_cmd` set, one line with its value and the file it came from — a fault when that file is tracked by git, where the CLI refuses to run it. Neither is a fault — one line naming the tools as they are actually called here, or saying the file is the transport.
|
|
225
225
|
- **The artifact mirror** (flow-core §4.6) — `panel.artifact` empty and the artifact tools here → one information line, not a fault: *control room off — `/flow:init room` turns it on*. Set: one line with its value and the file it came from; whether a tool whose name ends in `ArtifactData` is here (deferred counts); and, when it is, whether a `list` of collection `works` (limit 1) on that URL answers — a read, never a write. Tool present → also name the rule that keeps every card update from asking — `ArtifactData` (as the harness calls it) under `permissions.allow` — and its cost in the same line: it lets any session write to the data of any of your artifacts without asking, not only this page's; without it, each card update is approved by hand. The value coming from any file but `FLOW.claude.md` → a fault: the URL is one person's page, and a committed `FLOW.md` hands it to every teammate, whose writes it refuses. Key set and no tool → *off in this harness*, not a fault. The read failing → the error, as a fault. The read answering → also the page's version (`flow-room-page`, through an Artifact `read`) against the plugin's example: older or absent → one information line, *control room page out of date — the next card write republishes it*, not a fault.
|
|
226
226
|
|
|
227
227
|
### 2.3 Knowledge sources
|
|
@@ -184,7 +184,7 @@ Execution mode:
|
|
|
184
184
|
|
|
185
185
|
Use `TaskCreate` to track the steps of the **§2.0ter plan for this MR/PR** — one task per numbered step, same order. Step skipped there (small MR/PR) → seed from `03-design.md` §"Implementation plan (order)", taking only the steps this MR/PR covers per `04-mr-plan.md`; the feature's plan predates the split and carries steps that belong to siblings. Mark each step `in_progress` when starting and `completed` when done — do not batch.
|
|
186
186
|
|
|
187
|
-
**The steps go to the live panel** (flow-core §4.1
|
|
187
|
+
**The steps go to the live panel** (flow-core §4.1, §4.4 (f)) — that is the list the user watches, whatever the harness. The panel CLI draws them from the ticks in `05-implementation.md`: render the panel when the first step starts and again as each one lands — where the plugin's hook runs, the tick itself renders it.
|
|
188
188
|
|
|
189
189
|
**A harness task list is optional on top.** `TaskCreate` is the Claude Code name; a harness may call it otherwise (`TodoWrite` on older builds), list it **deferred** — by name only, uncallable until its schema is loaded — or not offer it at all (Claude Code withholds it from newer models unless `CLAUDE_CODE_ENABLE_TODO_TOOLS=true`). There → seed it too; not there → nothing is missing and nothing is said. Either way the plan in `05-implementation.md` is the record: tick each step there (`- [x]`) as it lands — the panel and any task list follow the ticks, never the other way round.
|
|
190
190
|
|
|
@@ -237,7 +237,7 @@ The step's changes are **always reported before anything is recorded**. Who deci
|
|
|
237
237
|
|
|
238
238
|
**After completing each plan step**:
|
|
239
239
|
|
|
240
|
-
1. **Tick the step** in `05-implementation.md`,
|
|
240
|
+
1. **Tick the step** in `05-implementation.md`, move `now` on in `panel-input.json` and render the panel (flow-core §4.4 (f)), and mark it `completed` in the harness task list if there is one (§2.1).
|
|
241
241
|
2. **Report to the user** a step summary (≤ 5 lines):
|
|
242
242
|
```
|
|
243
243
|
Step N done: <description>
|
|
@@ -432,7 +432,7 @@ In every scenario:
|
|
|
432
432
|
```
|
|
433
433
|
|
|
434
434
|
Nothing back → the content is **not** on the base whatever the forge says (see §6.2.1). Do not mark the entry `merged`: leave it `in_progress` with a `note`, tell the user in one line, and recover it with a fresh MR/PR against `git.default_base` before the train moves on.
|
|
435
|
-
-
|
|
435
|
+
- Render the panel from the updated `meta.json` (flow-core §4, with `--forge`): a shipped-but-open MR/PR draws as `wait` with its real state, `done` once merged; when this ship sets `phase = "done"` the CLI closes the panel itself (nothing left here, `attention: done`) — drop `decision` from the input.
|
|
436
436
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
437
437
|
|
|
438
438
|
### 6.1.1 Tracker: move to done
|
|
@@ -38,7 +38,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
38
38
|
- **Shared rules live in the `flow-core` skill** (`skills/flow-core/SKILL.md`): configuration merge,
|
|
39
39
|
`models`, autonomy and hard gates, never-a-question list, stop header, the live panel,
|
|
40
40
|
`00-summary.md`. Every command loads it once per session.
|
|
41
|
-
- **One folder per ticket**: `.claude/work/{TICKET}/` holds `meta.json`, `00-summary.md`, the numbered markdown artifacts
|
|
41
|
+
- **One folder per ticket**: `.claude/work/{TICKET}/` holds `meta.json`, `00-summary.md`, the numbered markdown artifacts, `panel-input.json` (what the agent knows right now) and `panel.json` (the panel the CLI rendered from all of them).
|
|
42
42
|
- **Numbered artifacts**: each phase writes a `NN-phase.md` that the next step reads.
|
|
43
43
|
- **`evidence/`**: what `/flow:*:validate` actually observed when it drove the running app — a screenshot, a response body, a log excerpt, one file per criterion, with a **before** where the change alters something already visible. `/flow:*:ship` attaches it to the MR/PR description. `quality.evidence: off` disables both halves.
|
|
44
44
|
- **`meta.json` is the source of truth** for state (current phase, size, branch). Without it, commands refuse to continue.
|
|
@@ -63,7 +63,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
63
63
|
- **Commits follow the autonomy mode** (`/flow:feat:build` §2.2, `/flow:bug:fix` §2.1): changes **always reported before anything is recorded**. `manual`: **no `git commit` on its own**. `guided`: asks **once**. `auto`: WIP commit per step, cut by step (§2.3) — **`autonomy.mode: auto` plus typing the command is the explicit authorization**. WIP commits on the work branch **only**; push and MR/PR creation stay hard gates in every mode.
|
|
64
64
|
- **A named next command is not a handoff**: each `## Close` carries the **autonomy handoff** — `manual` proposes the next command with one `AskUserQuestion`; `guided`/`auto` **chain in the same turn**. Never chained: `ship` (hard gate in every mode) and anything downstream of a red gate.
|
|
65
65
|
- **Every stop opens with where you are** (flow-core §3): stop header, then ≤ ~10 product-altitude lines. Own process → the artifact; subagent notifications never earn a turn.
|
|
66
|
-
- **The stop is also published to the live panel** ([document below](#the-panel-document), flow-core §4):
|
|
66
|
+
- **The stop is also published to the live panel** ([document below](#the-panel-document), flow-core §4): rendered by `flow-workflows panel` from `meta.json`, the plan's ticks, the forge and `panel-input.json`, then carried by the terminal's `panel_set` where it exists — `panel.json` is written either way, and the plugin's hook re-renders it when those files change (Claude Code, Codex). Published **before** a long stretch, never after.
|
|
67
67
|
- **What is never a question is as binding as what always is**: hard gates stop in **every** mode; in `guided`/`auto` flow mechanics, WIP commits, the train's next MR/PR, size confirmation and anything already decided are never asked (flow-core §2). Only new evidence reopens a decision.
|
|
68
68
|
- **A correction is a convention, and a convention is written down**: when the user overrides something a phase proposed and the same correction would apply to an unrelated ticket in this repo, it becomes a `meta.json.conventions_candidates[]` row and a `## Conventions learned` line in the phase artifact, asking nothing (flow-core §8). `review`'s idiom audit reads them in the same work; `ship` offers them to `FLOW.md` once, at Close, in every mode. What is about *this* ticket stays in the artifact and goes no further.
|
|
69
69
|
- **Work you decide not to do is recorded, not narrated**: every "idea for a separate ticket", out-of-scope piece, unmitigated risk, unchecked edge case and prevention action becomes a `meta.json.followups[]` entry (flow-core §7) alongside its artifact section. Written without asking, and only when it clears the bar of §7 (a named subject, a path someone has actually seen, waiting costing more than doing it). Triaged **once** at `ship`'s Close, behind a skeptic: 3 or more candidates go to an agent whose job is to refute that each deserves a ticket, and only the strongest `tracker.followup_ask_max` (empty → **2**) become questions (**Do it** / **Not worth it** / **Later**). The rest are logged. Published in the MR/PR description while still open, and surfaced by `status`/`daily`/`next` — from `_archive/` too — until decided. Creating the tracker issue for an accepted one is outward-facing: **asks in every mode**. Two kinds are not deferred work: a **`decision`** the diff depends on is asked when it surfaces (in every mode) and only a deferred one is recorded; a **`tooling`** gap is recorded with no question at all and never goes to the tracker.
|
|
@@ -179,7 +179,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
179
179
|
|
|
180
180
|
## The panel document
|
|
181
181
|
|
|
182
|
-
`meta.json` is the *state machine*; the panel is the *view* a reader outside the chat watches. Optional: a work that never publishes it still resolves from `meta.json` alone.
|
|
182
|
+
`meta.json` is the *state machine*; the panel is the *view* a reader outside the chat watches. Optional: a work that never publishes it still resolves from `meta.json` alone. `flow-workflows panel` renders it (flow-core §4): order, ceiling and the derived lines are the CLI's; what the agent supplies is `panel-input.json`. The document below is what it prints, and what a phase writes by hand only when the CLI is unavailable.
|
|
183
183
|
|
|
184
184
|
```json
|
|
185
185
|
{
|
|
@@ -212,11 +212,11 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
|
|
|
212
212
|
- **`phase`** — the phase running **right now** (`meta.json.phase` advances only at close); the reader prefers it.
|
|
213
213
|
- **`updated_at`** — local ISO-8601 with offset from the real clock, never carried over; lets the reader flag a stale snapshot. Over the tools the app stamps each delivery itself.
|
|
214
214
|
- **`attention`** *(tools only)* — `wait` · `block` · `done`, beside `phase`, absent while simply working: the pane's claim on the user's attention, which the app never deduces from a line's `mark`. A tab's card shows the strongest claim among its panes, so an uncleared `wait` flags that tab for ever — it goes, with the `Decision` line, the moment the question is answered (flow-core §4.4e).
|
|
215
|
-
- **`key`**
|
|
215
|
+
- **`key`** — a unique, never-painted name on every line the CLI renders (`title`, `mr-1`, `mr-1-state`, `step-3`, `sib-1`, `open`, `now`, `next`, `decision`, `block-1`, `closed`).
|
|
216
216
|
|
|
217
217
|
**No headings over the train.** A shipped MR/PR is *open, waiting to merge*; `mark` says it per entry — `wait` shipped, `current` being worked, `done` only merged.
|
|
218
218
|
|
|
219
|
-
**The artifact mirror** (opt-in, flow-core §4.6). With `panel.artifact` set — in `FLOW.claude.md`, Claude Code only — each publication is also written (a per-step
|
|
219
|
+
**The artifact mirror** (opt-in, flow-core §4.6). With `panel.artifact` set — in `FLOW.claude.md`, Claude Code only — each publication is also written (a per-step render only when the card is 10 minutes old), whole, as one card of a claude.ai page that gathers every work of every repo: the `card.json` the CLI writes beside `panel.json` — the document plus `repo`, `work`, `ticket`, `type`, `branch`, `harness` — set as doc `<repo>--<work>` in collection `works`. The page is `examples/panel-artifact.html`, which `/flow:init room` publishes. The transport above is unchanged.
|
|
220
220
|
|
|
221
221
|
**Who publishes it.** The 18 phase commands (flow-core §4); `/flow:feat:ship` and `/flow:bug:ship` the instant an MR/PR URL exists; `/flow:feat:plan` when the train is populated — a new train is a new shape, so a full republish; `/flow:work:resume` (§5), after reading what is on screen; `/flow:work:watch` every cycle; `/flow:work:abandon` with a terminal state. Read-only `status`, `daily`, `config`, `doctor`, `news` never publish; `/flow:work:clean` archives the folder with any panel file inside.
|
|
222
222
|
|
|
@@ -89,7 +89,7 @@ Ask the user what to do with the branch — do not decide alone:
|
|
|
89
89
|
- Update `meta.json`: `phase = "abandoned"`; `phases_done` not touched (it reflects what was actually done); `notes` += abandonment reason; `updated_at` updated.
|
|
90
90
|
- Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
|
|
91
91
|
- **Tracker: move to won't-do** (never "done" — this work did not ship). Only if `tracker.tool` is not `none`/empty, `tracker.abandon_cmd` is set, and `meta.json.ticket` is a **real tracker id** (skip for local-only slugs). Run `tracker.abandon_cmd` substituting `{TICKET}` = `meta.json.ticket`. Same contract as `/flow:feat:start §6.5`: **best-effort, idempotent, gated** (ask once in `autonomy.mode: manual`; automatic in `guided`/`auto`); failure or already-in-state ticket → warn and continue, never block. `tracker.abandon_cmd` empty → do nothing (the user closes the ticket by hand if they want).
|
|
92
|
-
- Panel published for this work (flow-core §4) →
|
|
92
|
+
- Panel published for this work (flow-core §4) → render a terminal state before archiving: `panel-input.json` holding only one `blocks` entry saying the work was abandoned and why, after `meta.json.phase` is `abandoned` — the CLI then draws no Now, Next or Decision and claims nobody's attention.
|
|
93
93
|
- Delete the work's card from the artifact control room when `panel.artifact` is set (flow-core §4.6, *a card ends with its work folder*), then move the folder to `.claude/work/_archive/` **keeping its directory name** (`_archive/<work-dir>/`, the folder located in §1 — e.g. `<TICKET>-<slug>`) so `/flow:work:daily` no longer lists it.
|
|
94
94
|
- Report to the user: ticket abandoned, reason, what was done with the branch.
|
|
95
95
|
|
|
@@ -22,7 +22,7 @@ External sources (tracker, forge, `knowledge`) are all **best-effort**: a CLI mi
|
|
|
22
22
|
|
|
23
23
|
Your **work assistant**: a Scrum-style daily standup — *"what was I working on?"*, *"what's left?"*, *"what should I pick up today?"* — from three sources: **local** work state, the **forge** (open MRs/PRs, reviews, CI), the **tracker** (assigned/re-prioritized tickets). The one overview of every open work; `/flow:work:resume` is the one-branch view. With forge and tracker both unavailable it is still the full local picture.
|
|
24
24
|
|
|
25
|
-
**Read-only.** Never touches `meta.json`, git, the forge, or the tracker; its only writes are the "last seen" marker (§7) and, with `panel.artifact` set, the control-room cards §2 finds stale. What it finds stale it reports and points at the command that writes.
|
|
25
|
+
**Read-only.** Never touches `meta.json`, git, the forge, or the tracker; its only writes are the "last seen" marker (§7) and, with `panel.artifact` set, the control-room cards §2 finds stale — with the `card.json` the panel CLI renders for those works (never their `panel.json`: that is each work's own session's pane). What it finds stale it reports and points at the command that writes.
|
|
26
26
|
|
|
27
27
|
## Modes
|
|
28
28
|
|
|
@@ -84,7 +84,7 @@ cd "$(git rev-parse --show-toplevel)" || exit 1
|
|
|
84
84
|
[ -d "$WORK" ] || { echo "no such folder: $WORK"; exit 1; }
|
|
85
85
|
tmp=$(mktemp -d) || exit 1
|
|
86
86
|
idx="$tmp/index" # does not exist yet: git starts an empty index there
|
|
87
|
-
GIT_INDEX_FILE="$idx" git add -f -- "$WORK" ":(exclude)$WORK/panel.json" &&
|
|
87
|
+
GIT_INDEX_FILE="$idx" git add -f -- "$WORK" ":(exclude)$WORK/panel.json" ":(exclude)$WORK/panel-input.json" ":(exclude)$WORK/card.json" ":(exclude)$WORK/forge-state.json" ":(exclude)$WORK/.panel-refresh*" ":(exclude)$WORK/*.tmp" &&
|
|
88
88
|
files=$(GIT_INDEX_FILE="$idx" git ls-files) &&
|
|
89
89
|
tree=$(GIT_INDEX_FILE="$idx" git write-tree) &&
|
|
90
90
|
commit=$(git commit-tree "$tree" -m "study $TICKET")
|
|
@@ -94,8 +94,9 @@ printf '%s\\n' "$files"; echo "commit=$commit"
|
|
|
94
94
|
```
|
|
95
95
|
|
|
96
96
|
`GIT_INDEX_FILE` is set per command, never exported, so a failure leaves no session pointing git
|
|
97
|
-
at a deleted index. `panel.json`
|
|
98
|
-
|
|
97
|
+
at a deleted index. `panel.json`, `panel-input.json`, `card.json`, `forge-state.json`, the `.panel-refresh*` stamps and
|
|
98
|
+
any `*.tmp` stay out: they are this machine's panel, and on
|
|
99
|
+
another one they would show this session's last state as if it were theirs. The block failing → its message, and
|
|
99
100
|
stop: `commit-tree` with no git identity configured is the usual cause.
|
|
100
101
|
|
|
101
102
|
## 4. Confirm, then push
|