Skip to content
Merged
Show file tree
Hide file tree
Changes from 28 commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
c4d24d4
[jwies/review-dispatch-gate] review: block review submission when the…
jwbron Jul 21, 2026
7cc1fc2
[jwies/review-dispatch-gate] review: harden the gate's fail-open orde…
jwbron Jul 21, 2026
19f87ec
[jwies/review-dispatch-gate] review: protect the sentinel/pre-gate wr…
jwbron Jul 21, 2026
588356b
[jwies/review-dispatch-gate] review: pin keep-list survivors, Step 6 …
jwbron Jul 21, 2026
f95d3f2
[jwies/review-pre-agent-staging] review: move the staging layer into …
jwbron Jul 21, 2026
c0573f0
[jwies/review-pre-agent-staging] review: fix the added-lines hash for…
jwbron Jul 21, 2026
6bdfb95
[jwies/review-pre-agent-staging] review: tighten ghGet retry semantic…
jwbron Jul 21, 2026
63930fd
[jwies/review-stamp-carrier] review: re-review fingerprint falls back…
jwbron Jul 22, 2026
8942b86
[jwies/review-dispatch-gate-local] Merge branch 'jwies/review-stamp-c…
jwbron Jul 22, 2026
c6e43a8
[jwies/review-dispatch-gate-local] review: shared lenient sub-agent J…
jwbron Jul 22, 2026
f737f84
[jwies/review-pre-agent-staging-local] Merge branch 'jwies/review-dis…
jwbron Jul 22, 2026
f5aae5c
[jwies/review-pre-agent-staging-local] review: the staged plan artifa…
jwbron Jul 22, 2026
5735a0e
[jwies/review-pre-agent-staging-local] review: retry the secondary-ra…
jwbron Jul 22, 2026
bdbc612
[jwies/autofix-v1] autofix: opt-in, one-shot fixing of the PR reviewe…
jwbron Jul 28, 2026
11c4a11
[jwies/autofix-v1] autofix: add /autofix as a peer arming surface alo…
jwbron Jul 28, 2026
0182485
[jwies/autofix-v1] autofix: fix the two faults the first live trial r…
jwbron Jul 28, 2026
887fcc8
[jwies/autofix-v1] autofix: work around gh-aw's unbounded PR-branch f…
jwbron Jul 28, 2026
a4e778e
[jwies/autofix-v1] autofix: move to Opus 5; settle the tagOpt questio…
jwbron Jul 28, 2026
73a35fa
[jwies/autofix-v1] autofix: self-contained commit messages, exception…
jwbron Jul 28, 2026
77b7de7
[jwies/autofix-v1] autofix: stage deterministically in a pre-agent step
jwbron Jul 28, 2026
ce00455
[jwies/autofix-v1] autofix: fix the currency guard failing open; one …
jwbron Jul 28, 2026
d7f684b
[jwies/autofix-v1] autofix: reuse the stack's diff builder; close the…
jwbron Jul 28, 2026
33ec833
[jwies/autofix-v1] autofix: price Opus 5 for the proxy; match bot log…
jwbron Jul 29, 2026
dd06f8c
[jwies/autofix-v1] autofix: pin the firewall to the version that hono…
jwbron Jul 29, 2026
1a61004
[jwies/autofix-v1] autofix: hold at Opus 4.8; the Opus 5 pricing fall…
jwbron Jul 29, 2026
5890044
[jwies/autofix-v1] autofix: correct the Opus 5 note; the cause is une…
jwbron Jul 29, 2026
95ca721
[jwies/review-pre-agent-staging] review: don't tell the orchestrator …
jwbron Jul 29, 2026
ca109de
[jwies/autofix-v1] Merge branch 'jwies/review-pre-agent-staging' into…
jwbron Jul 29, 2026
a8f80b4
[jwies/review-dispatch-gate] Merge remote-tracking branch 'origin/mai…
jwbron Jul 29, 2026
e3a22e5
[jwies/review-pre-agent-staging] Merge branch 'jwies/review-dispatch-…
jwbron Jul 29, 2026
68c90bb
[jwies/autofix-v1] Merge branch 'jwies/review-pre-agent-staging' into…
jwbron Jul 29, 2026
9037a9b
[jwies/autofix-v1] autofix: actually implement the guards the command…
jwbron Jul 29, 2026
2369cf6
[jwies/autofix-v1] autofix: lead the description with the command, no…
jwbron Jul 29, 2026
57618a5
Merge branch 'main' into jwies/autofix-v1
jwbron Jul 30, 2026
a0c17ac
[jwies/autofix-v1] autofix: `skip-ai-review` no longer disarms autofix
jwbron Jul 30, 2026
7816541
autofix: fail closed when the thread fetch fails
jwbron Jul 30, 2026
7aed595
[jwies/autofix-v1] autofix: the re-review is best-effort verification…
jwbron Jul 30, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .changeset/autofix.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
"autofix": minor
---

Add the `autofix` workflow: opt-in, one-shot fixing of the PR reviewer's own feedback.

Arm a PR with an `autofix: blocking` / `autofix: nits` label or an `/autofix [scope]` comment; the run fixes the reviewer's open threads in that scope, pushes one commit, replies in each thread, and removes the label. Both arming surfaces are peers resolving through one shared token vocabulary, and the trigger decides which is read, so a stale label cannot widen an explicit command.

Everything except the code edit is deterministic. `lib/stage.ts` runs as a pre-agent step and fetches the inputs before the agent starts; `lib/plan.ts` then resolves scope, checks review currency, builds the work list, and renders the commit trailer. The plan is final: the prompt may execute it or stop, never widen it.

Guards fail closed. Currency is checked per file so one unrelated push doesn't refuse the whole run; unparseable labels, outdated anchors, threads a human opened, an unreadable diff, and a head that moves mid-run are all excluded. Refusal is reserved for a PR with no review at all.

The push uses `KHAN_ACTIONS_BOT_TOKEN`, because GitHub creates no workflow runs for `GITHUB_TOKEN`-triggered events and the re-review of the autofix commit is the only verification a fix gets. Ships with a documented workaround for gh-aw's unbounded PR-branch fetch, which is otherwise fatal on large monorepos.
5 changes: 5 additions & 0 deletions .changeset/review-dispatch-gate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"review": minor
---

The dispatch-conformance gate: a review verdict can no longer be submitted unless the sub-agent outputs it is supposed to summarize actually exist. On the v1.7.0 acceptance trial (Khan/webapp#40992, run 29865480728) the orchestrator skipped its own protocol in production: it ran no router, dispatched zero sub-agents, did no claim validation, reviewed the diff itself, labeled its audit record "streamlined direct review", and submitted a REQUEST_CHANGES that disclosed none of it; the previous day's review of Khan/actions#272 dispatched correctly and disclosed its sheds, so this is stochastic non-conformance the eval suite cannot see by construction (the harness dispatches sub-agents from a script). The gate is code at the submit chokepoint, same family as v1.6.1's non-empty-body rule: a new `post-steps:` step in the agent job (`lib/dispatch-gate.ts`) runs after gh-aw finalizes the safe-output queue and before the queue ships to the `safe_outputs` job that calls the GitHub API. It checks the queued verdict and findings against the staged `out/` files per re-review depth (the correctness pass wherever the depth dispatches one, with the pattern-triage empty-`reviewFiles` waiver; a parseable `claim-validator.json` or its disclosed skipped-dimension note whenever inline comments post; a disclosure note for every reviewer routing planned that never dispatched) and, on violation, strips every posting item from the queue and fails the job: the submission is blocked rather than detected, the run goes red, and the original queue plus the gate report ride the agent artifact for diagnosis. Fail-open only for the gate's own bugs (loud warning, review unblocked); a detected violation never passes silently.
5 changes: 5 additions & 0 deletions .changeset/review-pre-agent-staging.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"review": minor
---

Staging becomes a pre-agent step (deterministic-orchestrator slice 1, scoped 07-13 out of the #246 review). A new `lib/stage-pr.ts` runs in `pre-agent-steps:` before the agent starts: it fetches the PR metadata, changed files, and prior bot reviews from the GitHub API, rebuilds the unified diff in the exact header format the provenance parser requires, computes the diff facts (per-file fingerprint plus added-lines hunk signature, staged as `diff-facts.json` so Step 2 compares and Step 9 saves code-computed values) and the newly-changed-code scope against cache memory's `reviewedHunks`, and then runs the deterministic CLI chain the orchestrator previously invoked mid-conversation (router first pass, provenance staging, re-review plan including the `out/` copy, and the scoped swap; at flip-gated depth `pr.diff` / `pr-annotated.diff` / `review-files.json` are staged from `scoped.diff` since no triage runs there). Steps 1 and 3 of the prompt now read the staged files instead of fetching and invoking; #246's interim prompt wiring is deleted. The one model touch stays mid-run by design: when the staged `routing.json` carries `pendingRiskQuestions`, the orchestrator still answers them and runs the router's second pass, which changes only tiers and budget. Every staging failure degrades toward more review, never less (missing cache puts the whole diff in scope, a failed reviews fetch forces a full review), and a hard fetch failure fails the step before any AI spend. Behavior-neutral by construction: the eval producer stages cases through the same lib functions, so A/Bs keep measuring production.
7 changes: 7 additions & 0 deletions .changeset/stamp-carrier-cache-memory.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"review": patch
---

review: the re-review fingerprint anchors on cache memory; the body stamp never survives gh-aw ingest

gh-aw's safe-output sanitizer strips all XML/HTML comments (`removeXmlComments`), so the hidden fingerprint stamp a review body carries never reaches the PR: every production re-review planned `no-prior-fingerprint` and silently escalated to full depth, making the `re-review` ROUTING dial (scoped/flip-gated/fast) inert. The plan CLI now falls back to the Step 9 cache-memory record (`verdict`, `stampHunks`/`reviewedHunks`, `wasDraft`) when no prior-review body carries a stamp, and records which carrier anchored the plan as `stampSource` in `rereview-plan.json`. Step 9 gains a `stampHunks` field copied verbatim from the plan CLI's own hash computation so hash regimes are never mixed. Cache eviction still degrades to a full review, never a cheaper one.
11 changes: 3 additions & 8 deletions .github/aw/actions-lock.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
{
"entries": {
"github/gh-aw-actions/setup-cli@v0.81.6": {
"repo": "github/gh-aw-actions/setup-cli",
"version": "v0.81.6",
"sha": "ba6380cc6e5be5d21677bebe04d52fb48e3abec7"
},
"github/gh-aw-actions/setup@v0.81.6": {
"github/gh-aw-actions/setup@v0.83.4": {
"repo": "github/gh-aw-actions/setup",
"version": "v0.81.6",
"sha": "ba6380cc6e5be5d21677bebe04d52fb48e3abec7"
"version": "v0.83.4",
"sha": "e89c65e17eb281bbd5ff2ff9e9199a03e96654c7"
}
}
}
Loading
Loading