8000 review: one run per head, configured by three keys by dominikwozniak · Pull Request #76 · dominikwozniak/dw-mc · GitHub
[go: up one dir, main page]

Skip to content

review: one run per head, configured by three keys - #76

Merged
dominikwozniak merged 4 commits into
mainfrom
refactor/74-one-review-run
Sep 17, 2026
Merged

dominikwozniak merged 4 commits into
mainfrom
refactor/74-one-review-run

Conversation

@dominikwozniak
Copy link
Copy Markdown
Owner

A pull request carries one review run, on Claude Code, and what that run opens on is configuration
rather than a string literal. Three keys say it — review.command, review.effort, review.prompt —
and each is overridable for a single run by a flag, because the review I want today is not always the
one the repository is set up for. Codex goes, and with it the second opinion that paid for an ordered
runners array, a runner suffix in every key, a runner field on every record, the
supporting-versus-deciding split, and two questions in init.

What changes

  • src/adapters/claude.ts — was runner.ts; owns the boundary the way gh.ts and git.ts do.
    reviewTurns takes the turn and spawns it: two turns for a slash command, one for the tool's own
    prompt with the schema inline. My own brief rides on --append-system-prompt beside a command.
  • src/domain/persona.ts — turnFor decides which of the two a run is; review.skill is
    review.prompt and reaches every shape rather than only the ones nothing configured.
  • dw-mc review — gains --command, --prompt, --model, --prompt-only and --command-only;
    --effort widens to low through max. dw-mc init asks nothing; dw-mc findings loses --runner.
  • CONTEXT.md, ADR 0009, ADR 0010 — the glossary drops the three runner entries for one review turn,
    and the two decisions get their own records: one run per head, and what happens to a configuration
    file this version cannot read.

Test plan

  • pnpm check — pass (lint, format, typecheck, 656 tests, build)
  • src/adapters/claude.test.ts — four new cases over reviewTurns: one turn on the prompt, two on a
    slash command, --append-system-prompt beside the command, and a guard that the command turn is
    never handed --json-schema
  • src/domain/persona.test.ts — five new cases over turnFor, one per shape
  • node dist/bin.js findings … against the real config.yaml — the migration error named all three
    removed keys and said review.skill is review.prompt now
  • by hand, still to do: one real dw-mc review to confirm --append-system-prompt steers a
    /code-review run, that xhigh is accepted, and that the resumed findings turn still finds its
    session. Fallbacks for all three are recorded in ADR 0009.

Risk

The configuration file changes shape, so every command stops until three keys are edited — the error
names them, and git revert plus the old file is the way back. Review runs recorded by an earlier
version are not read by this one, which costs one re-review per pull request.

Closes #74

dominikwozniak and others added 4 commits September 17, 2026 22:58
A head carried a run per configured runner so that Codex could stand beside a
review of my own as a second opinion. Nothing here runs Codex, so that one idea
was paying for an ordered runners array, a runner suffix in every storage key, a
runner field on every record, the supporting-versus-deciding split and its stamp
switch, a runner flag on two commands, and two questions in init.

What a run opens on becomes configuration instead: a slash command, the effort
word after it, and my own review brief, each overridable for a single run by a
flag. The brief rides on --append-system-prompt beside a command, because what a
slash command does with its arguments is its business and not this tool's.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The glossary loses the three runner entries and gains the review turn, an ADR
records why the second opinion went and why a slash command costs two turns, and
the README, the design snapshot and the skill say what the tool does today.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The glossary stopped having a runner, so the code stops naming one. An adapter
is named for the boundary it owns - `gh.ts`, `git.ts` - and this one owns Claude
Code, so `runner.ts` becomes `claude.ts` and `RunnerFailed` becomes
`AgentFailed`, whose field already held a program name.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The strict decode is why a removed key stops every command, and the rejected
alternatives - tolerating a dead key, rewriting the file behind me - are the
kind a reader would otherwise suggest again. That is a decision of its own, not
a consequence of the one that removed the keys.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@dominikwozniak
dominikwozniak force-pushed the refactor/74-one-review-run branch from fd34809 to 298285b Compare September 17, 2026 21:02
@dominikwozniak
dominikwozniak merged commit 37875ea into main Sep 17, 2026
1 check passed
@dominikwozniak
dominikwozniak deleted the refactor/74-one-review-run branch September 17, 2026 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

review: one run per head, configured by three keys

1 participant

0