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
{"number": 91, "title": "[Rule] C to D", "item_id": "PVTI_yyy", "has_good": false, "labels": ["rule"]}
84
87
]
85
88
}
86
89
```
87
90
88
91
### 1b: Pick the top issue
89
92
90
-
Pick the first item from the list. If the list is empty, STOP with message: "No `[Model]`/`[Rule]` issues in Backlog."
93
+
Pick the first item from the list and retain both `<NUMBER>` and `<ITEM_ID>`. If the list is empty, STOP with message: "No `[Model]`/`[Rule]` issues in Backlog."
91
94
92
95
If the top issue already has the `Good` label and its check report has **0 failures and 0 warnings**, skip to Step 8 (just move it to Ready — no edits needed). If it has warnings, proceed normally.
93
96
94
-
### 1c: Fetch the chosen issue
97
+
### 1c: For a specific issue number, locate the board item and validate status
98
+
99
+
When `/fix-issue <NUMBER>` is used, do **not** start editing immediately. First look up the card:
100
+
101
+
```bash
102
+
uv run --project scripts scripts/pipeline_board.py find <NUMBER>
103
+
```
104
+
105
+
Returns JSON: `{"item_id": "PVTI_xxx", "status": "Backlog", "number": 207, "title": "..."}` or an error if not found.
106
+
107
+
- If the status is `Backlog`, continue and claim it in Step 1d.
108
+
- If the status is `OnHold`, continue only as a **resume** of in-progress `fix-issue` work.
109
+
- If the status is anything else (`Ready`, `In progress`, `Review pool`, etc.), STOP with message: "Issue #<NUMBER> is not available for `/fix-issue` because its board status is <STATUS>."
110
+
- If an error is returned, STOP with message: "Issue #<NUMBER> is not on the project board."
111
+
112
+
### 1d: Move the card to OnHold immediately
113
+
114
+
Claim the work item **before any further action** (before `gh issue view`, before parsing comments, before drafting edits):
115
+
116
+
```bash
117
+
uv run --project scripts scripts/pipeline_board.py move <ITEM_ID> OnHold
118
+
```
119
+
120
+
This is a temporary lock to avoid two agents or humans editing the same issue concurrently. Do not leave the card in Backlog while you inspect or modify it.
121
+
122
+
Use `OnHold` as the in-progress state for `/fix-issue`. Once claimed, do not move the issue back to `Backlog` automatically; keep it in `OnHold` until Step 8 or explicit human re-triage.
123
+
124
+
If the issue is already in `OnHold` because you are resuming previously started `fix-issue` work, do not move it again; just continue.
@@ -169,54 +201,14 @@ Use `cargo run -p problemreductions-cli --bin pred -- show <problem>` (or `./tar
169
201
170
202
## Step 4: Present Full Context and Auto-Fixes to Human
171
203
172
-
**IMPORTANT: Show all context BEFORE asking for any decisions.** The human needs full visibility into the check report findings, research results, and classification before being asked to choose.
173
-
174
-
### 4a: Show the check report summary
204
+
**IMPORTANT: Show all context BEFORE asking for any decisions.**
175
205
176
-
Print the parsed check report summary table (from Step 2) so the human can see the starting state:
206
+
Present everything in one block so the human has full visibility:
177
207
178
-
```
179
-
## Check Report Summary (Issue #<NUMBER>)
180
-
181
-
| Check | Result | Details |
182
-
|-------|--------|---------|
183
-
| Usefulness | ✅ Pass | ... |
184
-
| Non-trivial | ✅ Pass | ... |
185
-
| Correctness | ⚠️ Warn | ... |
186
-
| Well-written | ⚠️ Warn | ... |
187
-
```
188
-
189
-
For each `Fail` or `Warn` result, include the key details from the check report's detailed section (not just the one-liner — include the specific sub-issues identified).
190
-
191
-
### 4b: Show research results
192
-
193
-
If web searches, `pred show` lookups, or other research was performed during classification (Step 2–3), present those findings now. For example:
194
-
- Web search results that confirm or contradict references
195
-
-`pred show` output for source/target problems
196
-
- Companion issue status (exists / missing)
197
-
198
-
This ensures the human has all the evidence before any decisions.
Then list the substantive issues that need discussion:
213
-
214
-
```
215
-
## Issues requiring your input
216
-
217
-
1. **Decision vs optimization:** ...
218
-
2. **Reference accuracy:** ...
219
-
```
208
+
1.**Check report summary** — the parsed table from Step 2 (Check / Result / Details). For `Fail` or `Warn` results, include the specific sub-issues from the detailed section, not just the one-liner.
209
+
2.**Research results** — any web searches, `pred show` lookups, or companion issue status gathered during Steps 2–3.
Print results to the human as a summary table (Check / Result / Details).
247
239
240
+
If the issue cannot be completed in this session because the check report is missing, the issue body is malformed, required context is unavailable, or the proposed fix turns out to be wrong, STOP and tell the human exactly what blocked completion. Leave the card in `OnHold`.
241
+
248
242
---
249
243
250
244
## Step 7: Ask Human for Decision
@@ -255,7 +249,7 @@ Use `AskUserQuestion` to present the options:
255
249
256
250
> The issue has been re-checked locally. What would you like to do?
257
251
>
258
-
> 1.**Looks good** — I'll push the edits to GitHub, update labels, and move it to Ready
252
+
> 1.**Looks good** — I'll push the edits to GitHub, update labels, and move it from OnHold to Ready
259
253
> 2.**Modify again** — tell me what else you'd like to change
260
254
261
255
### If human picks 2: Modify Again
@@ -266,6 +260,8 @@ Ask the human (free-form) what they want to change:
266
260
267
261
Apply the requested changes to the draft issue body, re-check locally (Step 6), then ask again (Step 7). Repeat until the human picks "Looks good".
268
262
263
+
If the session pauses without approval, leave the card in `OnHold`. Do **not** move it back to Backlog automatically; `OnHold` is the conflict-avoidance state for partially completed `fix-issue` work.
264
+
269
265
---
270
266
271
267
## Step 8: Finalize (If human picks 1 "Looks good")
| Forgetting to update the issue title | If the problem name changed, update the title with `gh issue edit <N> --title "..."` and find all related issues referencing the old name |
0 commit comments