You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: apps/claude-code/pr-review/CHANGELOG.md
+107Lines changed: 107 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,17 +3,124 @@
3
3
## [Unreleased]
4
4
5
5
### Breaking
6
+
- (none)
7
+
8
+
### Added
9
+
- (none)
10
+
11
+
### Fixed
12
+
- (none)
13
+
14
+
## [0.8.0] — 2026-05-06
15
+
16
+
### Breaking
17
+
- (none)
18
+
19
+
### Added
20
+
- Re-review: detect prior Claude Code threads in Step 3.5; set `IS_REREVIEW`, `PRIOR_THREADS_FILE`, `SUMMARY_THREAD_ID`, and `PRIOR_ITERATION_ID`; normalize signature format to `🤖 *Reviewed by Claude Code* — Iteration N` for detection and iteration targeting (specs 01–02)
21
+
- Re-review: resolve `LATEST_ITERATION_ID` and `LATEST_COMMIT_ID` from PR iterations API; compute `PRIOR_COMMIT_ID` from prior review signature; replace hardcoded `iterationId=1` (spec 03)
22
+
- Re-review: incremental diff between `PRIOR_COMMIT_ID` and `LATEST_COMMIT_ID` in Step 5; early exit with pending thread list when no new commits detected (spec 04)
23
+
- Re-review: classify each prior bot thread as `addressed`, `disputed`, `pending`, or `obsolete` in Step 5.5; detect deleted-file threads as `obsolete` (spec 05)
24
+
- Re-review: reply to existing bot threads instead of posting new duplicates in Step 10; apply per-classification actions and post run-completion marker on every successful run (spec 06)
25
+
- Re-review: skip full summary when no new or addressed findings; post delta reply (counts + new finding bullets) to existing summary thread; fall back to full summary if prior summary thread was deleted (spec 07)
26
+
27
+
### Fixed
28
+
- (none)
29
+
30
+
## [0.7.0] — 2026-05-06
31
+
32
+
### Breaking
33
+
- (none)
34
+
35
+
### Added
36
+
- On re-review, skip full summary when nothing changed; post delta reply (counts + new finding bullet list) to existing summary thread when findings exist; fall back to full summary if prior summary thread was deleted (spec 07)
37
+
38
+
### Fixed
39
+
- (none)
40
+
41
+
## [0.6.0] — 2026-05-06
42
+
43
+
### Breaking
44
+
- (none)
45
+
46
+
### Added
47
+
- Reply to existing bot threads instead of duplicating them on re-review: match prior threads by file path and line-range overlap (±3 line drift), branch Step 10 on `IS_REREVIEW`, apply per-classification actions (skip `pending`, reply `disputed`/`addressed`, ignore `obsolete`), post run-completion marker on every successful run (spec 06)
48
+
49
+
### Fixed
50
+
- (none)
51
+
52
+
## [0.5.0] — 2026-05-06
53
+
54
+
### Breaking
55
+
- (none)
56
+
57
+
### Added
58
+
- Classify each prior bot thread as `addressed`, `disputed`, `pending`, or `obsolete` in Step 5.5; print summary count before Step 6; detect deleted-file threads as `obsolete` (spec 05)
59
+
60
+
### Fixed
61
+
- (none)
62
+
63
+
## [0.4.0] — 2026-05-06
64
+
65
+
### Breaking
66
+
- (none)
67
+
68
+
### Added
69
+
- Branch Step 5 on `IS_REREVIEW`: incremental diff between `PRIOR_COMMIT_ID` and `LATEST_COMMIT_ID` for re-reviews; early exit with pending thread list when no new commits; fallback warnings with both commit IDs on fetch failure or missing commit IDs; hunk boundaries exported to `DIFF_HUNKS_FILE` for spec 05 (spec 04)
70
+
71
+
### Fixed
72
+
- (none)
73
+
74
+
## [0.3.0] — 2026-05-06
6
75
76
+
### Breaking
77
+
- (none)
78
+
79
+
### Added
80
+
- Fetch PR iterations to resolve `LATEST_ITERATION_ID` and `LATEST_COMMIT_ID`; replace hardcoded `iterationId=1` in Step 4; add `PRIOR_COMMIT_ID` resolution for re-review mode (spec 03)
81
+
82
+
### Fixed
83
+
- (none)
84
+
85
+
## [0.2.1] — 2026-05-06
86
+
87
+
### Breaking
7
88
- (none)
8
89
9
90
### Added
91
+
- (none)
92
+
93
+
### Fixed
94
+
- Set `isSummaryThread` flag only on the most-recent prior summary thread (not all matching threads) to avoid ambiguity in re-review targeting
95
+
96
+
## [0.2.0] — 2026-05-06
97
+
98
+
### Breaking
10
99
11
100
- (none)
12
101
102
+
### Added
103
+
104
+
- Added Step 3.5 (Detect prior review): paginated fetch of all PR threads, bot-comment detection via signature prefix, and export of `IS_REREVIEW`, `PRIOR_THREADS_FILE`, `SUMMARY_THREAD_ID`, and `PRIOR_ITERATION_ID` for use by later re-review steps
105
+
13
106
### Fixed
14
107
15
108
- (none)
16
109
110
+
## [0.1.3] — 2026-05-06
111
+
112
+
### Breaking
113
+
114
+
- (none)
115
+
116
+
### Added
117
+
118
+
- (none)
119
+
120
+
### Fixed
121
+
122
+
- Normalized all emitted comment signatures to asterisk italics and added `— Iteration {LATEST_ITERATION_ID}` suffix; documented detection prefix in Notes and Comment signature sections
Copy file name to clipboardExpand all lines: apps/claude-code/pr-review/CLAUDE.md
+2-3Lines changed: 2 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,9 +34,9 @@ When bumping the version, update it in **both** files:
34
34
35
35
- YAML frontmatter declares `allowed-tools` — add any new tools the command needs there
36
36
- Auto-generated files are explicitly skipped in Step 6 (serialization YAMLs, `*.g.cs`, generated types output, `swagger.md`)
37
-
- All comments posted to ADO **must** end with the exact signature: `---\n🤖 *Reviewed by Claude Code*`
37
+
- All comments posted to ADO **must** end with the exact signature: `---\n🤖 *Reviewed by Claude Code* — Iteration N` (where N = LATEST_ITERATION_ID)
38
38
- Inline threads use ADO REST `pullRequestThreads` via `az devops invoke`; file paths must match ADO format (leading `/`, forward slashes)
39
-
-`iterationId=1` is always used unless there's a specific reason to target a later iteration
39
+
-Always use the latest iteration of the PR. `iterationId=1` is never used. Re-reviews additionally compute `PRIOR_ITERATION_ID` from the prior review's signature — see spec 02.
40
40
- If `az devops invoke` returns a `threadContext` error, fall back to posting without `threadContext` (general comment)
41
41
42
42
## External dependencies
@@ -64,5 +64,4 @@ Then add `"pr-review@unic": true` to `enabledPlugins` and restart Claude Code.
64
64
65
65
- GitHub PR support
66
66
- Vote on PR (approve/reject) after review
67
-
- Re-review: detect existing Claude Code threads and update instead of duplicating
A fixed text marker appended to every Plugin-authored comment, used to identify Review Threads and Replies created by this Plugin.
60
60
_Avoid_: watermark, marker, signature
61
61
62
+
### Doc context enrichment
63
+
64
+
**Doc Context**:
65
+
The aggregated summaries of linked work items and Confluence pages passed to Review Aspect agents as background on the business intent of the PR. Produced before the review phase and injected as a preamble into each agent's prompt.
66
+
_Avoid_: ticket context, background info, extra context
67
+
68
+
**Doc Context Sub-agent**:
69
+
A short-lived agent spawned to fetch and summarise a single source — either a work item description or a Confluence page — in a diff-aware way. Multiple Doc Context Sub-agents run in parallel; their outputs are merged into the Doc Context.
70
+
_Avoid_: context agent, doc agent, fetcher agent
71
+
62
72
### Re-review classification
63
73
64
74
**Thread Classification**:
@@ -85,6 +95,8 @@ A Thread Classification state. The relevant code was deleted or moved; the comme
85
95
- A **Reply** is added to an existing **Review Thread** — it does not open a new one
86
96
- The **Bot Signature** is present on every comment authored by the Plugin, enabling prior-review detection
87
97
- A **Revision** is the code snapshot a **Review** or **Re-review** analyses
98
+
- A **Doc Context** is assembled by one or more **Doc Context Sub-agents** before the Review phase and injected into every Review Aspect agent
99
+
- A **Doc Context Sub-agent** operates on a single source (work item or Confluence page) and receives the changed files list and the local diff when available
Copy file name to clipboardExpand all lines: apps/claude-code/pr-review/README.md
+25-4Lines changed: 25 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@ Run `/pr-review:review-pr <ADO-PR-URL>` to:
11
11
3. Post each finding as an inline comment at the exact file and line in the ADO web UI
12
12
4. Post a summary comment with severity-grouped findings and positive observations
13
13
14
-
All comments are signed `🤖 *Reviewed by Claude Code*` so reviewers know they are AI-generated.
14
+
All comments are signed `🤖 *Reviewed by Claude Code* — Iteration N` so reviewers know they are AI-generated and can track which review iteration produced each finding.
15
15
16
16
---
17
17
@@ -127,18 +127,39 @@ Every comment posted to the PR ends with:
127
127
128
128
```
129
129
---
130
-
🤖 *Reviewed by Claude Code*
130
+
🤖 *Reviewed by Claude Code* — Iteration N
131
131
```
132
132
133
-
This consistent signature lets team members immediately identify AI-generated review comments.
133
+
This consistent signature lets team members immediately identify AI-generated review comments and track which review iteration produced each finding.
134
+
135
+
---
136
+
137
+
## Re-review
138
+
139
+
Running `/pr-review:review-pr <url>` on a PR that already has Claude Code review threads triggers re-review mode automatically.
140
+
141
+
**What changes in re-review mode:**
142
+
143
+
-**Detection** — Step 3.5 scans all existing PR threads for the bot signature and extracts their file paths, line ranges, and classification metadata.
144
+
-**Thread reuse** — New findings are posted as replies to the matching prior thread (matched by file path and line-range overlap ±3 lines) rather than creating duplicate threads.
145
+
-**Classification** — Each prior thread is classified as `addressed` (resolved), `disputed` (active disagreement), `pending` (still open), or `obsolete` (file deleted or lines moved far).
146
+
-**Incremental diff** — The diff is computed between the prior review's commit and the latest commit, so only new changes are analysed.
147
+
-**Delta summary** — Instead of a full summary, a short reply is posted to the existing summary thread listing new findings and counts. If nothing changed, no summary is posted.
148
+
-**Completion marker** — Every successful run appends a completion marker to the summary thread so subsequent runs can detect partial-run failures.
149
+
150
+
**Signature format:**`🤖 *Reviewed by Claude Code* — Iteration N` (N = ADO PR iteration number).
151
+
152
+
**Known limitations:**
153
+
154
+
- Force-push that rewrites history falls back to a full diff (prior commit no longer exists in the remote).
155
+
- If a run was interrupted before posting the completion marker, the next run treats it as a partial run and skips to a recovery path.
134
156
135
157
---
136
158
137
159
## Roadmap
138
160
139
161
-**GitHub PR support** — detect `https://github.com/...` URLs and route to `gh pr review`
140
162
-**Vote on PR** — optionally set approval/rejection after review
141
-
-**Re-review** — detect existing Claude Code threads and update rather than duplicate
142
163
-**PR description generation** — generate a PR description from the diff
0 commit comments