flow-workflows 0.107.0 → 0.108.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.
@@ -17,7 +17,7 @@ Every `$flow-*` command assumes these rules. They are stated once, here, so a co
17
17
  carries what is specific to its phase. Read this once per session; a command that says "load
18
18
  `flow-core`" means this file.
19
19
 
20
- **This file belongs to flow `0.107.0`.** Compare it once, at the start of the session, against
20
+ **This file belongs to flow `0.108.0`.** Compare it once, at the start of the session, against
21
21
  `version` in `~/.claude/flow/.claude-plugin/plugin.json`. The two differing means the session
22
22
  is running a **mixture** — the commands from one copy of the plugin, these shared rules from another
23
23
  — which is exactly what happens when a branch or a release candidate is loaded over an installed
@@ -236,7 +236,7 @@ Cost line: count every subagent this command launched — reviewers = §2.1 buil
236
236
  - With blockers: `phase` stays where it was (`validate` for size ≥ S, `fix` on XS, where validate never ran). Iterate.
237
237
  - Without blockers: `phase = "review"`, add to `phases_done`. Suggest `$flow-bug-postmortem` (M/L) or `$flow-bug-ship` (XS/S).
238
238
  - **Record *what* you reviewed, and separately what you changed after reading it** — `$flow-feat-review` §9, unchanged: `reviewed_sha` = the **candidate** of §1.5 (the revision the reviewers read, never `git rev-parse HEAD`, which by now holds this round's own fixes), and `fixed_sha` = `git rev-parse HEAD` after those fixes, empty when the round applied none. `phases_done` says a review happened; these two say on which tree and what moved afterwards, and `$flow-bug-ship §0` reads both against what is being pushed. Only when the phase advances: a review that ended in blockers reviewed nothing that stands.
239
- - **Record which pass found what** — `$flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow cost` reads them back per origin, and the retirement rule is the same: a pass with no exclusive surviving finding across twenty reviews comes out of the command.
239
+ - **Record which pass found what** — `$flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow yield` reads them back across works and repos, and the retirement rule is the same: a pass with no unique accepted finding across twenty rounds at a size comes out of the command at that size.
240
240
  - **Record what the agents missed** — `$flow-feat-review §9`, unchanged: surviving findings in a category a panel member or named `agents.<role>` owns and did not report → `meta.json.agent_lessons[]` rows (flow-core §6.7), asking nothing. A fix is where this pays most: the defect already reached production once, and the reviewer that owns its category let it.
241
241
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `$flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `postmortem`/`ship`»). Never `knowledge.save` here.
242
242
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
@@ -388,7 +388,7 @@ Write `.claude/work/<TICKET>/06-review.md`. The `Cost:` line of `## Summary` is
388
388
  - `reviewed_sha` = **the candidate of §1.5**, the revision the reviewers actually read. Not `git rev-parse HEAD`, which by then holds this round's own fixes — code no reviewer saw, recorded as reviewed, and `ship` finding it equal to `HEAD` every time.
389
389
  - `fixed_sha` = `git rev-parse HEAD` after this round's fixes, or **empty** when the round applied none. Two fields because they are two facts.
390
390
  - `phases_done` says a review *happened*; these say which tree, and `$flow-feat-ship §1` reads both before pushing. Written whenever the phase advances, never when it does not: a review that ended in blockers reviewed nothing that stands.
391
- - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow cost` reads them back per origin: how many findings each pass contributed, how many only it raised, and how many of those survived §6. That last number is the only evidence a pass is still earning its words.
391
+ - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow yield` reads them back across every work and repo, per origin and per size: rounds run, findings, how many only that pass raised, how many of those were acted on, and the agents it took (where the round recorded them). That unique-accepted number is the only evidence a pass is still earning its words, and `yield` marks a pass that ran twenty rounds at a size without one.
392
392
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `$flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `ship`»). Never `knowledge.save` here.
393
393
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
394
394
  - **Record what the agents missed** (flow-core §6.7, `agents.learn` not `off`; asking nothing): for each finding that survived, the panel member or named `agents.<role>` whose category it falls in and who did not report it, and the delegated `build` agent whose code it sits in → one `meta.json.agent_lessons[]` row each, only when the lesson passes the §6.7 test. The origins §2.1 carried are what make this possible — a finding with no origin teaches nobody.
@@ -163,7 +163,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
163
163
  ```
164
164
 
165
165
  - **`candidate_sha` / `reviewed_sha` / `fixed_sha` / `validated_sha`**: which code each verdict is about. `candidate_sha` is written by `review` in its **pre-flight** (§1.5) — the revision it froze before reading anything, `git rev-parse HEAD` over a clean tree and `git stash create` over a dirty one, anchored at `refs/flow/candidate/<TICKET>` so nothing collects it. The other three are written at `## Close`, **only when the phase actually advances**, work-level and in the current `mrs[]` entry: `reviewed_sha` is the candidate that was actually read, `fixed_sha` is `HEAD` after that round's own fixes (empty when it applied none), `validated_sha` is where the suite went green.
166
- - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow cost` reports per origin how many findings each contributed, how many **only** it raised, and how many of those survived §6 — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. The rule was written down before the data arrived: no exclusive surviving finding across twenty reviews and the pass comes out of the command.
166
+ - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow yield [<repo-path>…]` reads every work those repos hold — live and `_archive/`, here and in the main checkout — and reports per origin and per size how many rounds each ran, how many findings it contributed, how many **only** it raised, and how many of those were acted on (for rows written before findings carried an outcome: not refuted by a skeptic) — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. Old spellings of an origin (`builtin`, `cli:tests`, `§5.5`) are mapped on read and listed. The rule was written down before the data arrived: no unique accepted finding across twenty rounds at a size (XS and S pooled) and the pass comes out of the command at that size.
167
167
  Two fields for the review because they are two facts. `reviewed_sha` used to be `git rev-parse HEAD` at the end of the phase, which by then held the round's own fixes — so `ship` compared a sha against itself and reported a match over code no reviewer had read. Read by `ship` at pre-flight against `HEAD`: a delta of test files and this work's own folder passes with a note in `06-review.md`; anything else stops and asks in every autonomy mode. Empty is not a mismatch; `fixed_sha` set with `reviewed_sha == HEAD` is one. `review` also reads `reviewed_sha` back as **its own base** on a re-review, so the second round reads the delta instead of the whole branch.
168
168
  - **`respond_rounds`**: rounds of `$flow-work-respond` on an MR/PR. `$flow-work-respond §1` reads it against `quality.respond_max_rounds` (empty = 3) and refuses the round that would exceed it, handing the open threads back to the user.
169
169
  - **`roadmap`**: the roadmap item this work delivers (flow-core §10). Linked at `$flow-feat-start §3.7`, marked in progress / done by `$flow-feat-ship` inside the MR/PR, shown by `next`/`daily`/`resume` — which also flag an item the code delivered but the file still does not mark. `null` with no roadmap, no link, or a bug.
@@ -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.107.0`.** Compare it once, at the start of the session, against
19
+ **This file belongs to flow `0.108.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
@@ -232,7 +232,7 @@ Cost line: count every subagent this command launched — reviewers = §2.1 buil
232
232
  - With blockers: `phase` stays where it was (`validate` for size ≥ S, `fix` on XS, where validate never ran). Iterate.
233
233
  - Without blockers: `phase = "review"`, add to `phases_done`. Suggest `/flow:bug:postmortem` (M/L) or `/flow:bug:ship` (XS/S).
234
234
  - **Record *what* you reviewed, and separately what you changed after reading it** — `/flow:feat:review` §9, unchanged: `reviewed_sha` = the **candidate** of §1.5 (the revision the reviewers read, never `git rev-parse HEAD`, which by now holds this round's own fixes), and `fixed_sha` = `git rev-parse HEAD` after those fixes, empty when the round applied none. `phases_done` says a review happened; these two say on which tree and what moved afterwards, and `/flow:bug:ship §0` reads both against what is being pushed. Only when the phase advances: a review that ended in blockers reviewed nothing that stands.
235
- - **Record which pass found what** — `/flow:feat:review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow cost` reads them back per origin, and the retirement rule is the same: a pass with no exclusive surviving finding across twenty reviews comes out of the command.
235
+ - **Record which pass found what** — `/flow:feat:review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow yield` reads them back across works and repos, and the retirement rule is the same: a pass with no unique accepted finding across twenty rounds at a size comes out of the command at that size.
236
236
  - **Record what the agents missed** — `/flow:feat:review §9`, unchanged: surviving findings in a category a panel member or named `agents.<role>` owns and did not report → `meta.json.agent_lessons[]` rows (flow-core §6.7), asking nothing. A fix is where this pays most: the defect already reached production once, and the reviewer that owns its category let it.
237
237
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow:feat:design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `postmortem`/`ship`»). Never `knowledge.save` here.
238
238
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
@@ -384,7 +384,7 @@ Write `.claude/work/<TICKET>/06-review.md`. The `Cost:` line of `## Summary` is
384
384
  - `reviewed_sha` = **the candidate of §1.5**, the revision the reviewers actually read. Not `git rev-parse HEAD`, which by then holds this round's own fixes — code no reviewer saw, recorded as reviewed, and `ship` finding it equal to `HEAD` every time.
385
385
  - `fixed_sha` = `git rev-parse HEAD` after this round's fixes, or **empty** when the round applied none. Two fields because they are two facts.
386
386
  - `phases_done` says a review *happened*; these say which tree, and `/flow:feat:ship §1` reads both before pushing. Written whenever the phase advances, never when it does not: a review that ended in blockers reviewed nothing that stands.
387
- - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow cost` reads them back per origin: how many findings each pass contributed, how many only it raised, and how many of those survived §6. That last number is the only evidence a pass is still earning its words.
387
+ - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow yield` reads them back across every work and repo, per origin and per size: rounds run, findings, how many only that pass raised, how many of those were acted on, and the agents it took (where the round recorded them). That unique-accepted number is the only evidence a pass is still earning its words, and `yield` marks a pass that ran twenty rounds at a size without one.
388
388
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow:feat:design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `ship`»). Never `knowledge.save` here.
389
389
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
390
390
  - **Record what the agents missed** (flow-core §6.7, `agents.learn` not `off`; asking nothing): for each finding that survived, the panel member or named `agents.<role>` whose category it falls in and who did not report it, and the delegated `build` agent whose code it sits in → one `meta.json.agent_lessons[]` row each, only when the lesson passes the §6.7 test. The origins §2.1 carried are what make this possible — a finding with no origin teaches nobody.
@@ -159,7 +159,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
159
159
  ```
160
160
 
161
161
  - **`candidate_sha` / `reviewed_sha` / `fixed_sha` / `validated_sha`**: which code each verdict is about. `candidate_sha` is written by `review` in its **pre-flight** (§1.5) — the revision it froze before reading anything, `git rev-parse HEAD` over a clean tree and `git stash create` over a dirty one, anchored at `refs/flow/candidate/<TICKET>` so nothing collects it. The other three are written at `## Close`, **only when the phase actually advances**, work-level and in the current `mrs[]` entry: `reviewed_sha` is the candidate that was actually read, `fixed_sha` is `HEAD` after that round's own fixes (empty when it applied none), `validated_sha` is where the suite went green.
162
- - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow cost` reports per origin how many findings each contributed, how many **only** it raised, and how many of those survived §6 — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. The rule was written down before the data arrived: no exclusive surviving finding across twenty reviews and the pass comes out of the command.
162
+ - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow yield [<repo-path>…]` reads every work those repos hold — live and `_archive/`, here and in the main checkout — and reports per origin and per size how many rounds each ran, how many findings it contributed, how many **only** it raised, and how many of those were acted on (for rows written before findings carried an outcome: not refuted by a skeptic) — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. Old spellings of an origin (`builtin`, `cli:tests`, `§5.5`) are mapped on read and listed. The rule was written down before the data arrived: no unique accepted finding across twenty rounds at a size (XS and S pooled) and the pass comes out of the command at that size.
163
163
  Two fields for the review because they are two facts. `reviewed_sha` used to be `git rev-parse HEAD` at the end of the phase, which by then held the round's own fixes — so `ship` compared a sha against itself and reported a match over code no reviewer had read. Read by `ship` at pre-flight against `HEAD`: a delta of test files and this work's own folder passes with a note in `06-review.md`; anything else stops and asks in every autonomy mode. Empty is not a mismatch; `fixed_sha` set with `reviewed_sha == HEAD` is one. `review` also reads `reviewed_sha` back as **its own base** on a re-review, so the second round reads the delta instead of the whole branch.
164
164
  - **`respond_rounds`**: rounds of `/flow:work:respond` on an MR/PR. `/flow:work:respond §1` reads it against `quality.respond_max_rounds` (empty = 3) and refuses the round that would exceed it, handing the open threads back to the user.
165
165
  - **`roadmap`**: the roadmap item this work delivers (flow-core §10). Linked at `/flow:feat:start §3.7`, marked in progress / done by `/flow:feat:ship` inside the MR/PR, shown by `next`/`daily`/`resume` — which also flag an item the code delivered but the file still does not mark. `null` with no roadmap, no link, or a bug.
@@ -17,7 +17,7 @@ Every `/flow-*` command assumes these rules. They are stated once, here, so a co
17
17
  carries what is specific to its phase. Read this once per session; a command that says "load
18
18
  `flow-core`" means this file.
19
19
 
20
- **This file belongs to flow `0.107.0`.** Compare it once, at the start of the session, against
20
+ **This file belongs to flow `0.108.0`.** Compare it once, at the start of the session, against
21
21
  `version` in `~/.claude/flow/.claude-plugin/plugin.json`. The two differing means the session
22
22
  is running a **mixture** — the commands from one copy of the plugin, these shared rules from another
23
23
  — which is exactly what happens when a branch or a release candidate is loaded over an installed
@@ -236,7 +236,7 @@ Cost line: count every subagent this command launched — reviewers = §2.1 buil
236
236
  - With blockers: `phase` stays where it was (`validate` for size ≥ S, `fix` on XS, where validate never ran). Iterate.
237
237
  - Without blockers: `phase = "review"`, add to `phases_done`. Suggest `/flow-bug-postmortem` (M/L) or `/flow-bug-ship` (XS/S).
238
238
  - **Record *what* you reviewed, and separately what you changed after reading it** — `/flow-feat-review` §9, unchanged: `reviewed_sha` = the **candidate** of §1.5 (the revision the reviewers read, never `git rev-parse HEAD`, which by now holds this round's own fixes), and `fixed_sha` = `git rev-parse HEAD` after those fixes, empty when the round applied none. `phases_done` says a review happened; these two say on which tree and what moved afterwards, and `/flow-bug-ship §0` reads both against what is being pushed. Only when the phase advances: a review that ended in blockers reviewed nothing that stands.
239
- - **Record which pass found what** — `/flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow cost` reads them back per origin, and the retirement rule is the same: a pass with no exclusive surviving finding across twenty reviews comes out of the command.
239
+ - **Record which pass found what** — `/flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow yield` reads them back across works and repos, and the retirement rule is the same: a pass with no unique accepted finding across twenty rounds at a size comes out of the command at that size.
240
240
  - **Record what the agents missed** — `/flow-feat-review §9`, unchanged: surviving findings in a category a panel member or named `agents.<role>` owns and did not report → `meta.json.agent_lessons[]` rows (flow-core §6.7), asking nothing. A fix is where this pays most: the defect already reached production once, and the reviewer that owns its category let it.
241
241
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `postmortem`/`ship`»). Never `knowledge.save` here.
242
242
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
@@ -388,7 +388,7 @@ Write `.claude/work/<TICKET>/06-review.md`. The `Cost:` line of `## Summary` is
388
388
  - `reviewed_sha` = **the candidate of §1.5**, the revision the reviewers actually read. Not `git rev-parse HEAD`, which by then holds this round's own fixes — code no reviewer saw, recorded as reviewed, and `ship` finding it equal to `HEAD` every time.
389
389
  - `fixed_sha` = `git rev-parse HEAD` after this round's fixes, or **empty** when the round applied none. Two fields because they are two facts.
390
390
  - `phases_done` says a review *happened*; these say which tree, and `/flow-feat-ship §1` reads both before pushing. Written whenever the phase advances, never when it does not: a review that ended in blockers reviewed nothing that stands.
391
- - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow cost` reads them back per origin: how many findings each pass contributed, how many only it raised, and how many of those survived §6. That last number is the only evidence a pass is still earning its words.
391
+ - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow yield` reads them back across every work and repo, per origin and per size: rounds run, findings, how many only that pass raised, how many of those were acted on, and the agents it took (where the round recorded them). That unique-accepted number is the only evidence a pass is still earning its words, and `yield` marks a pass that ran twenty rounds at a size without one.
392
392
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `ship`»). Never `knowledge.save` here.
393
393
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
394
394
  - **Record what the agents missed** (flow-core §6.7, `agents.learn` not `off`; asking nothing): for each finding that survived, the panel member or named `agents.<role>` whose category it falls in and who did not report it, and the delegated `build` agent whose code it sits in → one `meta.json.agent_lessons[]` row each, only when the lesson passes the §6.7 test. The origins §2.1 carried are what make this possible — a finding with no origin teaches nobody.
@@ -163,7 +163,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
163
163
  ```
164
164
 
165
165
  - **`candidate_sha` / `reviewed_sha` / `fixed_sha` / `validated_sha`**: which code each verdict is about. `candidate_sha` is written by `review` in its **pre-flight** (§1.5) — the revision it froze before reading anything, `git rev-parse HEAD` over a clean tree and `git stash create` over a dirty one, anchored at `refs/flow/candidate/<TICKET>` so nothing collects it. The other three are written at `## Close`, **only when the phase actually advances**, work-level and in the current `mrs[]` entry: `reviewed_sha` is the candidate that was actually read, `fixed_sha` is `HEAD` after that round's own fixes (empty when it applied none), `validated_sha` is where the suite went green.
166
- - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow cost` reports per origin how many findings each contributed, how many **only** it raised, and how many of those survived §6 — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. The rule was written down before the data arrived: no exclusive surviving finding across twenty reviews and the pass comes out of the command.
166
+ - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow yield [<repo-path>…]` reads every work those repos hold — live and `_archive/`, here and in the main checkout — and reports per origin and per size how many rounds each ran, how many findings it contributed, how many **only** it raised, and how many of those were acted on (for rows written before findings carried an outcome: not refuted by a skeptic) — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. Old spellings of an origin (`builtin`, `cli:tests`, `§5.5`) are mapped on read and listed. The rule was written down before the data arrived: no unique accepted finding across twenty rounds at a size (XS and S pooled) and the pass comes out of the command at that size.
167
167
  Two fields for the review because they are two facts. `reviewed_sha` used to be `git rev-parse HEAD` at the end of the phase, which by then held the round's own fixes — so `ship` compared a sha against itself and reported a match over code no reviewer had read. Read by `ship` at pre-flight against `HEAD`: a delta of test files and this work's own folder passes with a note in `06-review.md`; anything else stops and asks in every autonomy mode. Empty is not a mismatch; `fixed_sha` set with `reviewed_sha == HEAD` is one. `review` also reads `reviewed_sha` back as **its own base** on a re-review, so the second round reads the delta instead of the whole branch.
168
168
  - **`respond_rounds`**: rounds of `/flow-work-respond` on an MR/PR. `/flow-work-respond §1` reads it against `quality.respond_max_rounds` (empty = 3) and refuses the round that would exceed it, handing the open threads back to the user.
169
169
  - **`roadmap`**: the roadmap item this work delivers (flow-core §10). Linked at `/flow-feat-start §3.7`, marked in progress / done by `/flow-feat-ship` inside the MR/PR, shown by `next`/`daily`/`resume` — which also flag an item the code delivered but the file still does not mark. `null` with no roadmap, no link, or a bug.
@@ -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.107.0`.** Compare it once, at the start of the session, against
19
+ **This file belongs to flow `0.108.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
@@ -234,7 +234,7 @@ Cost line: count every subagent this command launched — reviewers = §2.1 buil
234
234
  - With blockers: `phase` stays where it was (`validate` for size ≥ S, `fix` on XS, where validate never ran). Iterate.
235
235
  - Without blockers: `phase = "review"`, add to `phases_done`. Suggest `/flow-bug-postmortem` (M/L) or `/flow-bug-ship` (XS/S).
236
236
  - **Record *what* you reviewed, and separately what you changed after reading it** — `/flow-feat-review` §9, unchanged: `reviewed_sha` = the **candidate** of §1.5 (the revision the reviewers read, never `git rev-parse HEAD`, which by now holds this round's own fixes), and `fixed_sha` = `git rev-parse HEAD` after those fixes, empty when the round applied none. `phases_done` says a review happened; these two say on which tree and what moved afterwards, and `/flow-bug-ship §0` reads both against what is being pushed. Only when the phase advances: a review that ended in blockers reviewed nothing that stands.
237
- - **Record which pass found what** — `/flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow cost` reads them back per origin, and the retirement rule is the same: a pass with no exclusive surviving finding across twenty reviews comes out of the command.
237
+ - **Record which pass found what** — `/flow-feat-review §9`, unchanged: one `meta.json.review_findings[]` entry per finding **per source** (`{ round, origin, severity, file, discarded_by_skeptic }`, no finding text), written by `flow review --record` when the CLI ran the panel and by this Close when the agentic panel did. `flow yield` reads them back across works and repos, and the retirement rule is the same: a pass with no unique accepted finding across twenty rounds at a size comes out of the command at that size.
238
238
  - **Record what the agents missed** — `/flow-feat-review §9`, unchanged: surviving findings in a category a panel member or named `agents.<role>` owns and did not report → `meta.json.agent_lessons[]` rows (flow-core §6.7), asking nothing. A fix is where this pays most: the defect already reached production once, and the reviewer that owns its category let it.
239
239
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `postmortem`/`ship`»). Never `knowledge.save` here.
240
240
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
@@ -386,7 +386,7 @@ Write `.claude/work/<TICKET>/06-review.md`. The `Cost:` line of `## Summary` is
386
386
  - `reviewed_sha` = **the candidate of §1.5**, the revision the reviewers actually read. Not `git rev-parse HEAD`, which by then holds this round's own fixes — code no reviewer saw, recorded as reviewed, and `ship` finding it equal to `HEAD` every time.
387
387
  - `fixed_sha` = `git rev-parse HEAD` after this round's fixes, or **empty** when the round applied none. Two fields because they are two facts.
388
388
  - `phases_done` says a review *happened*; these say which tree, and `/flow-feat-ship §1` reads both before pushing. Written whenever the phase advances, never when it does not: a review that ended in blockers reviewed nothing that stands.
389
- - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow cost` reads them back per origin: how many findings each pass contributed, how many only it raised, and how many of those survived §6. That last number is the only evidence a pass is still earning its words.
389
+ - **Record which pass found what**, in the same write: `meta.json.review_findings[]`, one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, and no finding text, which stays in the artifact. `flow review --record` writes these itself when the CLI ran the panel; when the agentic panel ran, write them here from the origins §2.1 carried. `flow yield` reads them back across every work and repo, per origin and per size: rounds run, findings, how many only that pass raised, how many of those were acted on, and the agents it took (where the round recorded them). That unique-accepted number is the only evidence a pass is still earning its words, and `yield` marks a pass that ran twenty rounds at a size without one.
390
390
  - **Stage what the review taught** (`knowledge.stage` set; silence by default). Review is where a project teaches the most, and this is the only moment its findings are in context. Candidates are findings about the **domain or the codebase's real behaviour**, not about this diff: a library that does other than its name says, a test disguise that kept the suite green over a live defect, a module rule the reviewers had to cite from its own prose, a measurement. A blocker fixed here is not knowledge; *why it was written wrong* may be. Same evidence rule as `/flow-feat-design` §8 — one line of evidence per finding or it is not staged. One call per finding, one line to the user («Staged N finding(s) for `ship`»). Never `knowledge.save` here.
391
391
  - Overwrite `00-summary.md` whole (≤15 lines, flow-core §5).
392
392
  - **Record what the agents missed** (flow-core §6.7, `agents.learn` not `off`; asking nothing): for each finding that survived, the panel member or named `agents.<role>` whose category it falls in and who did not report it, and the delegated `build` agent whose code it sits in → one `meta.json.agent_lessons[]` row each, only when the lesson passes the §6.7 test. The origins §2.1 carried are what make this possible — a finding with no origin teaches nobody.
@@ -161,7 +161,7 @@ This system **orchestrates** the project's existing sub-agents and skills (it do
161
161
  ```
162
162
 
163
163
  - **`candidate_sha` / `reviewed_sha` / `fixed_sha` / `validated_sha`**: which code each verdict is about. `candidate_sha` is written by `review` in its **pre-flight** (§1.5) — the revision it froze before reading anything, `git rev-parse HEAD` over a clean tree and `git stash create` over a dirty one, anchored at `refs/flow/candidate/<TICKET>` so nothing collects it. The other three are written at `## Close`, **only when the phase actually advances**, work-level and in the current `mrs[]` entry: `reviewed_sha` is the candidate that was actually read, `fixed_sha` is `HEAD` after that round's own fixes (empty when it applied none), `validated_sha` is where the suite went green.
164
- - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow cost` reports per origin how many findings each contributed, how many **only** it raised, and how many of those survived §6 — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. The rule was written down before the data arrived: no exclusive surviving finding across twenty reviews and the pass comes out of the command.
164
+ - **`review_findings[]`**: one entry per finding **per source** — `{ round, origin, severity, file, discarded_by_skeptic }`, no finding text (that stays in `06-review.md`). Written at `review`'s Close, and by `flow review --record` when the CLI ran the panel. `origin` is `built-in`, a panel role, or the pass that raised it. It exists so a pass can be retired on evidence: `flow yield [<repo-path>…]` reads every work those repos hold — live and `_archive/`, here and in the main checkout — and reports per origin and per size how many rounds each ran, how many findings it contributed, how many **only** it raised, and how many of those were acted on (for rows written before findings carried an outcome: not refuted by a skeptic) — and a finding three sources raised says nothing about any of them, which is why dedup keeps every source rather than the first. Old spellings of an origin (`builtin`, `cli:tests`, `§5.5`) are mapped on read and listed. The rule was written down before the data arrived: no unique accepted finding across twenty rounds at a size (XS and S pooled) and the pass comes out of the command at that size.
165
165
  Two fields for the review because they are two facts. `reviewed_sha` used to be `git rev-parse HEAD` at the end of the phase, which by then held the round's own fixes — so `ship` compared a sha against itself and reported a match over code no reviewer had read. Read by `ship` at pre-flight against `HEAD`: a delta of test files and this work's own folder passes with a note in `06-review.md`; anything else stops and asks in every autonomy mode. Empty is not a mismatch; `fixed_sha` set with `reviewed_sha == HEAD` is one. `review` also reads `reviewed_sha` back as **its own base** on a re-review, so the second round reads the delta instead of the whole branch.
166
166
  - **`respond_rounds`**: rounds of `/flow-work-respond` on an MR/PR. `/flow-work-respond §1` reads it against `quality.respond_max_rounds` (empty = 3) and refuses the round that would exceed it, handing the open threads back to the user.
167
167
  - **`roadmap`**: the roadmap item this work delivers (flow-core §10). Linked at `/flow-feat-start §3.7`, marked in progress / done by `/flow-feat-ship` inside the MR/PR, shown by `next`/`daily`/`resume` — which also flag an item the code delivered but the file still does not mark. `null` with no roadmap, no link, or a bug.
package/bin/cli.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
- import { cpSync, existsSync, mkdirSync, readFileSync, readdirSync, renameSync, rmSync, statSync, writeFileSync } from 'node:fs'
2
+ import { cpSync, existsSync, mkdirSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, statSync, writeFileSync } from 'node:fs'
3
3
  import { homedir } from 'node:os'
4
- import { dirname, join } from 'node:path'
4
+ import { dirname, join, resolve } from 'node:path'
5
5
  import { fileURLToPath } from 'node:url'
6
6
  import { execFileSync, spawn } from 'node:child_process'
7
7
 
@@ -1160,52 +1160,228 @@ function cost(argv) {
1160
1160
  console.log()
1161
1161
  console.log('These are the harness\'s own client-side estimates and can differ from a bill.')
1162
1162
  console.log('Phases with no row did not measure anything — absence here is not zero.')
1163
+ console.log('Which reviewer found what, across every work: `flow yield`.')
1164
+ }
1163
1165
 
1164
- findingsByOrigin(meta)
1166
+ // --- yield -----------------------------------------------------------------------------
1167
+ // Whether each review pass still earns what it costs, across every work a repo has kept —
1168
+ // live and archived, in this checkout and in the main one, over as many repos as are named.
1169
+ // `meta.json.review_findings[]` has carried an origin per source since the rows were added;
1170
+ // what it never had is a reader that counts across works, so the twenty-review rule had
1171
+ // nothing to count. The origins were written by hand and drifted (`builtin`, `code-review`,
1172
+ // `cli:tests`, `§5.5`…): they are mapped here, on read, and every spelling that was not
1173
+ // already canonical is printed with what it was read as, so a wrong mapping is visible.
1174
+
1175
+ const RETIRE_AFTER = 20
1176
+ const ACCEPTED = new Set(['fixed', 'open', 'deferred'])
1177
+ const SECTION_ORIGINS = {
1178
+ '§3.5': 'sweep', sweep: 'sweep',
1179
+ '§3.6': 'query-duel', 'query-duel': 'query-duel',
1180
+ '§4': 'yagni', yagni: 'yagni',
1181
+ '§5': 'contract', contract: 'contract', 'contract-verifier': 'contract',
1182
+ '§5.5': 'idiom', idiom: 'idiom', 'idiom-audit': 'idiom',
1183
+ }
1184
+ const BUILT_IN = new Set(['built-in', 'builtin', 'builtin-code-review', 'code-review'])
1185
+ const LEGACY_SEVERITY = {
1186
+ blocker: 'blocker', high: 'blocker',
1187
+ major: 'major', medium: 'major',
1188
+ minor: 'minor', low: 'minor', suggestion: 'minor',
1189
+ nit: 'nit',
1165
1190
  }
1166
1191
 
1167
- // What the money was spent ON. A review runs the built-in, a panel, and four specialised
1168
- // passes — roughly 1 800 words of a 5 683-word command — every one of them added after a real
1169
- // defect got through, and not one able to show it still earns its cost. The only argument
1170
- // available was an opinion, and opinions about this converge on whoever spoke last.
1171
- function findingsByOrigin(meta) {
1172
- const rows = Array.isArray(meta.review_findings) ? meta.review_findings : []
1173
- console.log()
1174
- if (!rows.length) {
1175
- console.log('No findings recorded by origin yet. `flow review --record` writes one row per')
1176
- console.log('finding per source, and the agentic panel records the same at §9 of review.')
1177
- return
1192
+ // A panel role is whatever the repo named it; only the spelling noise is folded: a prefix
1193
+ // saying which path ran it, case and spaces, and the suffixes an agent's file name adds.
1194
+ function panelRole(raw) {
1195
+ let r = raw.toLowerCase().trim().replace(/\s+/g, '-')
1196
+ r = r.replace(/-(reviewer|hunter|verifier|audit)$/, '').replace(/-round\d+$/, '')
1197
+ if (r === 'testing') r = 'tests'
1198
+ if (r === 'redteam') r = 'red-team'
1199
+ if (/^silent(-failures?)?$/.test(r)) r = 'silent-failure'
1200
+ if (r === 'code-simplifier') r = 'simplify'
1201
+ return `panel:${r}`
1202
+ }
1203
+
1204
+ function canonicalOrigin(raw) {
1205
+ const o = String(raw ?? '').trim()
1206
+ if (!o) return 'unknown'
1207
+ if (o.startsWith('reinforcement:')) return o.toLowerCase()
1208
+ const bare = o.replace(/^(§panel:|cli-panel:|cli:|panel:)/, '')
1209
+ if (BUILT_IN.has(bare)) return 'built-in'
1210
+ if (SECTION_ORIGINS[bare]) return SECTION_ORIGINS[bare]
1211
+ return panelRole(bare)
1212
+ }
1213
+
1214
+ // Every work folder a repo holds: its `.claude/work` here and in the main checkout, live and
1215
+ // `_archive/`, each meta.json read once however many of those paths lead to it.
1216
+ // `seen` is shared across every repo of one call: a worktree and its main checkout, or the
1217
+ // same path named twice, lead to the same folders and must count them once.
1218
+ function worksOf(repo, seen) {
1219
+ const roots = new Set([join(repo, '.claude', 'work'), join(mainCheckout(repo), '.claude', 'work')])
1220
+ const works = []
1221
+ for (const root of roots) {
1222
+ for (const dir of [root, join(root, '_archive')]) {
1223
+ let entries = []
1224
+ try { entries = readdirSync(dir, { withFileTypes: true }) } catch { continue }
1225
+ for (const e of entries) {
1226
+ if (!e.isDirectory() || (dir === root && e.name === '_archive')) continue
1227
+ const p = join(dir, e.name, 'meta.json')
1228
+ let real
1229
+ try { real = realpathSync(p) } catch { continue }
1230
+ if (seen.has(real)) continue
1231
+ seen.add(real)
1232
+ try { works.push({ path: join(dir, e.name), meta: JSON.parse(readFileSync(p, 'utf8')) }) } catch {}
1233
+ }
1234
+ }
1235
+ }
1236
+ return works
1237
+ }
1238
+
1239
+ // The rule is judged per size because the review itself is: the panel rarely runs below M,
1240
+ // so XS and S are pooled or neither would ever reach twenty rounds.
1241
+ function sizeBucket(size) {
1242
+ const s = String(size ?? '').toUpperCase()
1243
+ return s === 'XS' || s === 'S' ? 'XS+S' : s === 'M' || s === 'L' ? s : 'unknown size'
1244
+ }
1245
+
1246
+ function yieldOf(argv) {
1247
+ const repos = (argv.length ? argv : ['.']).map((a) => {
1248
+ const top = git(['rev-parse', '--show-toplevel'], resolve(a)).trim()
1249
+ if (!top) { console.error(`flow yield: \`${a}\` is not a git checkout`); process.exit(1) }
1250
+ return top
1251
+ })
1252
+
1253
+ // bucket → origin → counters; rounds are (work, round) keys so a round counts once.
1254
+ const table = new Map()
1255
+ const spellings = new Map()
1256
+ let rounds = 0, rows = 0, works = 0
1257
+ const seen = new Set()
1258
+ const cell = (bucket, origin) => {
1259
+ if (!table.has(bucket)) table.set(bucket, new Map())
1260
+ const t = table.get(bucket)
1261
+ if (!t.has(origin)) t.set(origin, { rounds: new Set(), findings: 0, unique: 0, accepted: 0, agents: null })
1262
+ return t.get(origin)
1178
1263
  }
1179
- const rounds = new Set(rows.map((r) => r.round)).size
1180
- // A finding is identified by where it is, not by its text — the text lives in the artifact.
1181
- const key = (r) => `${r.round}::${r.severity}::${r.file}`
1182
- const sources = new Map()
1183
- for (const r of rows) {
1184
- if (!sources.has(key(r))) sources.set(key(r), new Set())
1185
- sources.get(key(r)).add(r.origin)
1264
+ const read = (raw) => {
1265
+ const c = canonicalOrigin(raw)
1266
+ if (raw !== c) {
1267
+ if (!spellings.has(c)) spellings.set(c, new Set())
1268
+ spellings.get(c).add(String(raw))
1269
+ }
1270
+ return c
1186
1271
  }
1187
- const per = new Map()
1188
- for (const r of rows) {
1189
- const e = per.get(r.origin) ?? { total: 0, exclusive: 0, survived: 0 }
1190
- e.total += 1
1191
- if (sources.get(key(r)).size === 1) {
1192
- e.exclusive += 1
1193
- if (!r.discarded_by_skeptic) e.survived += 1
1272
+
1273
+ for (const repo of repos) {
1274
+ for (const { path, meta } of worksOf(repo, seen)) {
1275
+ const found = Array.isArray(meta.review_findings) ? meta.review_findings : []
1276
+ const costs = (Array.isArray(meta.cost) ? meta.cost : []).filter((e) => e?.phase === 'review' && e.round != null)
1277
+ if (!found.length && !costs.length) continue
1278
+ works += 1
1279
+ const sizeFor = (mr, round) => {
1280
+ const entry = costs.find((e) => e.round === round && e.effective_size && (e.mr ?? null) === (mr ?? null))
1281
+ if (entry) return entry.effective_size
1282
+ const part = Array.isArray(meta.mrs) && mr != null ? meta.mrs.find((m) => m?.n === mr) : null
1283
+ return part?.size ?? meta.size
1284
+ }
1285
+ const roundsHere = new Set()
1286
+
1287
+ // A round that recorded what it launched says which passes ran, findings or not.
1288
+ for (const e of costs) {
1289
+ roundsHere.add(e.round)
1290
+ for (const [raw, n] of Object.entries(e.agents ?? {})) {
1291
+ if (!(Number(n) > 0)) continue
1292
+ const c = cell(sizeBucket(e.effective_size ?? sizeFor(e.mr, e.round)), read(raw))
1293
+ c.rounds.add(`${path}#${e.round}`)
1294
+ c.agents = (c.agents ?? 0) + Number(n)
1295
+ }
1296
+ }
1297
+
1298
+ // Legacy rows are one per source; the same finding is the same (round, severity, file).
1299
+ const legacy = found.filter((r) => !Array.isArray(r.sources))
1300
+ const keyOf = (r) => `${r.round}::${LEGACY_SEVERITY[r.severity] ?? 'unrated'}::${r.file ?? ''}`
1301
+ const sourcesOf = new Map()
1302
+ for (const r of legacy) {
1303
+ if (r.count != null) continue
1304
+ const k = keyOf(r)
1305
+ if (!sourcesOf.has(k)) sourcesOf.set(k, new Set())
1306
+ String(r.origin ?? '').split('+').forEach((o) => sourcesOf.get(k).add(canonicalOrigin(o)))
1307
+ }
1308
+ for (const r of legacy) {
1309
+ rows += 1
1310
+ roundsHere.add(r.round)
1311
+ const bucket = sizeBucket(sizeFor(r.mr, r.round))
1312
+ const accepted = !r.discarded_by_skeptic && !['declined', 'discarded'].includes(r.severity)
1313
+ for (const origin of new Set(String(r.origin ?? '').split('+').map(read))) {
1314
+ const c = cell(bucket, origin)
1315
+ // A row that only carries a count says how many, never which: they are findings,
1316
+ // and nothing can say whether another source had them too — so the round they sit in
1317
+ // is not one this origin can be judged on either.
1318
+ if (r.count != null) { c.findings += Number(r.count) || 0; continue }
1319
+ c.rounds.add(`${path}#${r.round}`)
1320
+ c.findings += 1
1321
+ if (sourcesOf.get(keyOf(r)).size === 1) {
1322
+ c.unique += 1
1323
+ if (accepted) c.accepted += 1
1324
+ }
1325
+ }
1326
+ }
1327
+
1328
+ for (const r of found.filter((x) => Array.isArray(x.sources))) {
1329
+ rows += 1
1330
+ roundsHere.add(r.round)
1331
+ const bucket = sizeBucket(sizeFor(r.mr, r.round))
1332
+ const sources = new Set(r.sources.map(read))
1333
+ for (const o of sources) {
1334
+ const c = cell(bucket, o)
1335
+ c.rounds.add(`${path}#${r.round}`)
1336
+ c.findings += 1
1337
+ if (sources.size === 1) {
1338
+ c.unique += 1
1339
+ if (ACCEPTED.has(r.outcome)) c.accepted += 1
1340
+ }
1341
+ }
1342
+ }
1343
+ rounds += roundsHere.size
1194
1344
  }
1195
- per.set(r.origin, e)
1196
1345
  }
1197
- console.log(`## Findings by origin — ${rows.length} row(s) over ${rounds} round(s)`)
1346
+
1347
+ console.log(`# Review yield — ${repos.join(' · ')}`)
1198
1348
  console.log()
1199
- console.log('| origin | findings | only this one | and survived §6 |')
1200
- console.log('|---|---|---|---|')
1201
- for (const [origin, e] of [...per.entries()].sort((a, b) => b[1].survived - a[1].survived)) {
1202
- console.log(`| ${origin} | ${e.total} | ${e.exclusive} | ${e.survived} |`)
1349
+ if (!table.size) {
1350
+ console.log('No review rounds recorded in the works these checkouts hold')
1351
+ console.log(`(${repos.map((r) => join(r, '.claude', 'work')).join(', ')}, archive included).`)
1352
+ return
1353
+ }
1354
+ console.log(`${works} work(s), ${rounds} review round(s), ${rows} finding row(s).`)
1355
+ for (const bucket of ['XS+S', 'M', 'L', 'unknown size']) {
1356
+ const t = table.get(bucket)
1357
+ if (!t) continue
1358
+ console.log()
1359
+ console.log(`## ${bucket}`)
1360
+ console.log()
1361
+ console.log('| origin | rounds | findings | unique | unique accepted | agents | verdict |')
1362
+ console.log('|---|---|---|---|---|---|---|')
1363
+ const sorted = [...t.entries()].sort((a, b) => b[1].accepted - a[1].accepted || b[1].findings - a[1].findings)
1364
+ for (const [origin, c] of sorted) {
1365
+ const n = c.rounds.size
1366
+ const verdict = n < RETIRE_AFTER ? `too few rounds (${n}/${RETIRE_AFTER})`
1367
+ : c.accepted === 0 ? `retire at ${bucket}` : 'keep'
1368
+ console.log(`| ${origin} | ${n} | ${c.findings} | ${c.unique} | ${c.accepted} | ${c.agents ?? '—'} | ${verdict} |`)
1369
+ }
1203
1370
  }
1204
1371
  console.log()
1205
- console.log('"only this one" is the column that decides anything: a finding three sources')
1206
- console.log('raised says nothing about any of them. A pass contributing no exclusive surviving')
1207
- console.log('finding across twenty reviews is removed from the command — the rule is written')
1208
- console.log('down before the data arrives so it cannot be argued backwards later.')
1372
+ console.log('"unique accepted" decides: a finding only this origin raised and that was acted on.')
1373
+ console.log(`An origin that ran ${RETIRE_AFTER}+ rounds at a size with none is retired at that size.`)
1374
+ console.log('Re-run it when the model changes — a pass that stopped paying may pay again, and back.')
1375
+ console.log('Rows written before findings carried an outcome count "accepted" as "not refuted by a')
1376
+ console.log('skeptic", and a round they record counts only for the origins with a row in it, so')
1377
+ console.log('"rounds" is a lower bound there and "agents" is unknown (—). Those rows carry no MR/PR')
1378
+ console.log('number either, so a split work\'s legacy rows count at the size of the whole work.')
1379
+ if (spellings.size) {
1380
+ console.log()
1381
+ console.log('## Spellings read as')
1382
+ console.log()
1383
+ for (const [c, raws] of [...spellings.entries()].sort()) console.log(`- ${c} ← ${[...raws].sort().join(', ')}`)
1384
+ }
1209
1385
  }
1210
1386
 
1211
1387
  function usage() {
@@ -1218,6 +1394,7 @@ function usage() {
1218
1394
  npx flow-workflows tier [--base <ref>] [--rev <ref>] [--harness <name>]
1219
1395
  npx flow-workflows review [--out <file>] [--record] [same options as bundle]
1220
1396
  npx flow-workflows cost
1397
+ npx flow-workflows yield [<repo-path>…]
1221
1398
 
1222
1399
  Harnesses: ${Object.keys(HARNESSES).join(' · ')}
1223
1400
  "project" installs into the current repo instead of your user folder.
@@ -1267,9 +1444,13 @@ Claude Code, Codex CLI and zcode have their own marketplaces:
1267
1444
  "cost" prints what each phase of this branch's work actually reported spending, from
1268
1445
  what --record wrote into meta.json. A harness that reports no figure is recorded as
1269
1446
  "not reported": a headcount of subagents is not a cost, and neither is a guess.
1270
- It also breaks the round's findings down by origin — which reviewer or pass raised
1271
- each one, how many only it raised, and how many of those survived verification. That
1272
- last column is the only evidence a pass is still earning the words it costs.
1447
+
1448
+ "yield" reads every work of the repos named (default: this one) — live and archived,
1449
+ here and in the main checkout — and prints, per reviewer or pass and per size, the
1450
+ rounds it ran, the findings it raised, how many only it raised, how many of those were
1451
+ acted on, and the agents it took. One that ran 20+ rounds at a size with no unique
1452
+ accepted finding is marked "retire" there; XS and S are pooled, since the panel rarely
1453
+ runs below M. Old spellings of an origin are mapped and listed with what they became.
1273
1454
 
1274
1455
  Updating: re-run the install command — it sweeps the previous version first.
1275
1456
  Docs: https://github.com/mashware/flow-workflows`)
@@ -1280,6 +1461,7 @@ const [cmd, tool, scope] = process.argv.slice(2)
1280
1461
  if (cmd === 'bundle') bundle(process.argv.slice(3))
1281
1462
  else if (cmd === 'tier') tier(process.argv.slice(3))
1282
1463
  else if (cmd === 'cost') cost(process.argv.slice(3))
1464
+ else if (cmd === 'yield') yieldOf(process.argv.slice(3))
1283
1465
  else if (cmd === 'review') review(process.argv.slice(3)).catch((e) => { console.error(`flow review: ${e.message}`); process.exit(1) })
1284
1466
  else if (cmd === 'check') check()
1285
1467
  else if (cmd === 'install' && tool === 'claude') claude()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flow-workflows",
3
- "version": "0.107.0",
3
+ "version": "0.108.0",
4
4
  "description": "Guided feat/bug workflows (start→ship), post-deploy monitoring and multi-agent code review, stack-agnostic. Each repo uses a shared FLOW.md plus optional harness overlay.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -3,7 +3,7 @@
3
3
  "name": "flow",
4
4
  "displayName": "Flow — guided dev workflows",
5
5
  "description": "Guided feat/bug workflows (start→ship), post-deploy monitoring and multi-agent code review, stack-agnostic. Each repo uses a shared FLOW.md plus optional harness overlay.",
6
- "version": "0.107.0",
6
+ "version": "0.108.0",
7
7
  "author": {
8
8
  "name": "Alberto Vioque",
9
9
  "email": "mashware@gmail.com"
@@ -5,6 +5,26 @@ plugin and is what `/flow:news` reads to show you what changed since your previo
5
5
 
6
6
  The canonical, richest notes live in the [GitHub Releases](https://github.com/mashware/flow-workflows/releases).
7
7
 
8
+ ## v0.108.0 — You can see which review passes still find what nothing else finds · 2026-11-04
9
+
10
+ **In short**
11
+ - **`npx flow-workflows yield [<repo>…]` counts every review your repos kept.** It reads live and archived works,
12
+ in the checkout you run it from and in the main one, across as many repos as you name.
13
+ - **Per reviewer or pass, and per change size**, it shows the rounds it ran, the findings it raised, how many only
14
+ it raised, how many of those were acted on, and the agents it took.
15
+ Rows recorded so far carry no outcome and no agent count: for them "acted on" means "not refuted by a skeptic",
16
+ the agents column shows `—`, and `yield` says so under its tables.
17
+ - **A verdict per row.** A pass that ran 20 rounds at a size without one finding of its own that was acted on is
18
+ marked `retire at <size>`. Under 20 rounds, it says how many it has. XS and S count together, because the panel
19
+ rarely runs below M.
20
+ - **Old spellings count as the pass they are.** `builtin`, `code-review`, `cli:tests` and `§5.5` were all written by
21
+ hand. They are folded on read, and the output lists each spelling with what it was read as.
22
+ - **`flow cost` is back to spend only.** Its per-origin table moved to `yield`, where it spans works.
23
+
24
+ Every review has recorded which pass raised each finding since v0.66.0, but only one work at a time could be read.
25
+ So the rule "no finding of its own across twenty reviews, and the pass comes out" had nothing to count. On the
26
+ three repos using flow today that is 131 rounds and about 1 100 rows (#234).
27
+
8
28
  ## v0.107.0 — A red test outside the change gets fixed when flow can see why · 2026-11-03
9
29
 
10
30
  **In short**