Give the prose pass its own reviewer agent, prose-reviewer #150

Merged
lilleman merged 2 commits from prose-agent into rebuild 2026-09-30 15:02:53 +02:00
3 changed files with 31 additions and 16 deletions
+28
View File
@@ -0,0 +1,28 @@
---
name: prose-reviewer
description: "Use this agent for larv-review's prose pass."
tools: Read, Grep, Glob
---
You judge prose as a reader who did not write the change: you do not know what it means to say, so you can see whether it says it.
Verdict, severities, rounds and declines: ~/.claude/skills/larv-review/review-findings.md. The bar: `~/.claude/CLAUDE.md` → "Comments and documentation" and "Prose"; per paragraph the default verdict is delete. Read both each time — they change.
## Scopes
The prompt hands you these; past them, read only what a finding needs checking against.
1. **What the diff touched** — every markdown line and every comment it adds or changes.
2. **What the review cited** — each section the prompt names, with the code it governs. A cited section is load-bearing.
3. **Every prose file the repo owns**, when the prompt says the architecture pass ran: the sweep that catches accretion, since no diff shows a file that grew a paragraph per chunk.
## Findings
Name the fix with each:
- **Delete** — a type, a test name, a spec or the code already says it.
- **Move** — a decision to `docs/decisions.md` with its one-line index in `AGENTS.md`; a goal to the README.
- **Move back** — a pointer standing where a definition belongs ("A pointer is not a definition"): inline the definition, leave the reasoning where it is.
- **Split or index** — load-bearing but unfindable: a section long enough that a reader who knows the answer is inside it still has to search. Sub-headings, or an index at its head.
Also a sentence contradicting another, a claim the code shows false, and a word used against `CLAUDE.md` → "Vocabulary".
+3 -15
View File
@@ -31,13 +31,13 @@ Follow `~/.claude/CLAUDE.md` → "Git, commits, and PRs". Never commit to the de
| Full security scan | the `claude-security` plugin (`/claude-security` → "Scan changes") | touches authn/authz, secrets or crypto, opens an untrusted-input boundary, or adds an external surface |
| Stability | stability-reviewer | changes code, config or tests; a fix, only where it changes behaviour: what the code or its tests do |
| Product-owner | product-owner-reviewer | changes an external surface: API, CLI, UI, error or deprecation text a consumer reads, README and docs an outside reader lands on |
| Prose | you, and a fresh-context agent | every chunk; a fix, where it touches prose |
| Prose | prose-reviewer | every chunk; a fix, where it touches prose |
A comment is prose, not code. Passes run in this order: line-level polish on code the architect wants restructured, or on a call the security pass will rewrite, is wasted work. A 🔀 escalation runs the named pass once the current pass is done; its fixes re-enter like any other.
**Record, then ask**, for the architecture pass and the full scan: where the repo holds the decision this change executes — a decision-log entry, or a planning item crediting the pass — the pass is done: skip it and cite the record. A change that *departs* from the record is unreviewed however thorough the record is. Fired with no record behind it → ask the user with the evidence and your recommendation; no user reachable → run it.
**Round cap.** A round is one launch of a pass's reviewer, whatever launched it, a rerun after the architect's Stage 0 questions — the goals, audience, scale or domain language it found unrecorded — included. The architecture pass's round is the architect and then the scoring run, so a floor fix reruns both as one round; the prose pass's round is its fresh-context agent; the external auto-reviewer (§4) is a pass of its own, each review it posts a round. From round 2, prompt an agent under `~/.claude/agents/` with the previous round's findings verbatim and what changed since. A pass is done on no 🔴 and no 🟡, until a re-entry reruns it; the 🟢 and ❓ left are addressed in the round that finished it — fixed, answered, declined or filed in `todo.md`. A pass takes at most three rounds per chunk; instead of a fourth, list what is open and ask the human — for the auto-reviewer, before any push that would summon a fourth.
**Round cap.** A round is one launch of a pass's reviewer, whatever launched it, a rerun after the architect's Stage 0 questions — the goals, audience, scale or domain language it found unrecorded — included. The architecture pass's round is the architect and then the scoring run, so a floor fix reruns both as one round; the external auto-reviewer (§4) is a pass of its own, each review it posts a round. From round 2, prompt an agent under `~/.claude/agents/` with the previous round's findings verbatim and what changed since. A pass is done on no 🔴 and no 🟡, until a re-entry reruns it; the 🟢 and ❓ left are addressed in the round that finished it — fixed, answered, declined or filed in `todo.md`. A pass takes at most three rounds per chunk; instead of a fourth, list what is open and ask the human — for the auto-reviewer, before any push that would summon a fourth.
**Re-entry.** A fix is a change no pass has seen, a 🟢's or ❓'s included. A round's fixes re-enter together: run, in table order, each pass whose trigger they fire and the pass whose 🔴 or 🟡 they answer, a pass at its cap getting the cap's ask; then §4.
@@ -66,19 +66,7 @@ Launch the reviewer with the change — product-owner-reviewer also with the ext
### Prose
Two scopes:
1. **What the diff touched** — every markdown line and every comment it adds or changes. Judge these yourself.
2. **What this review cited** — any section of the repo's prose a reviewer quoted to justify a finding, you quoted to justify a decline, or the implementer quoted to explain a decision. A cited section is load-bearing, and if anyone had to hunt for it, that is the finding. Judge these with a **fresh-context agent**, never yourself: whoever just wrote the code already knows the answer and cannot see what the prose adds. Hand it the section and the code that section governs, and nothing else.
In a chunk whose architecture pass ran, the fresh-context agent reads every prose file the repo owns: the only sweep that catches accretion, since no diff shows a file that grew a paragraph per chunk.
The bar is `~/.claude/CLAUDE.md` → "Comments and documentation"; per paragraph the default verdict is delete.
- **Delete** — a type, a test name, a spec or the code already says it. In this chunk.
- **Move** — a decision goes to `docs/decisions.md` with its one-line index; a goal goes to the README. In this chunk.
- **Move back** — the opposite fault, and the one a deletion-only pass never catches: a pointer standing where a definition belongs ("A pointer is not a definition", same section). Inline the definition and leave the reasoning where it is.
- **Split or index** — load-bearing but unfindable: a section long enough that a reader who knows the answer is inside it still has to search for it. Sub-headings, or an index at its head. Bigger than the chunk → a `todo.md` item naming the section and what the hunt costs.
Launch prose-reviewer with what the diff touched and every section this review cited — a reviewer's finding, your decline or the implementer's decision quoted it — each with the code it governs, and say whether the architecture pass ran. Its fixes land in this chunk; a split or index bigger than the chunk is a `todo.md` item naming the section and what the hunt costs.
## 4. Gate
-1
View File
@@ -8,7 +8,6 @@ The rebuild lifts every dimension, one chunk per item, until the last item opens
The places the bench of 2026-09-30 found in rebuild's larv-review, each hit by two or more of its four runs (`~/code/claude-handoffs/claude-config_2026-09-30.md`):
- **Define the prose pass's fresh-context agent: its prompt, the bar it reads, whether round 2 gets the earlier findings, and whether a rerun judging only diff lines launches it and counts as a round.** No agent file exists, "nothing else" contradicts the round-2 rule, and each run wrote its own prompt.
- **Say whether a decision record the chunk itself writes lets the architecture pass skip.** Three runs read it differently.
- **Give every ask a no-human branch: the round cap's fourth round, a reviewer's ❓, and a prose fix that needs a goal or a decision changed.** Today only Stage 0 and "Record, then ask" have one. Say too whether the other passes run while the cap's ask waits, and what the human's yes grants.
- **Say whether the comprehension floor runs when the architecture pass is skipped by record.** The floor sits inside that pass's round.