Skip to content

Commit dffc577

Browse files
feat(skills): /feature non-interactive invocation — structured SKIP/STOP instead of prompts (#3962)
When an orchestrating agent invokes /feature #N headlessly, collision, gh-failure, closed-issue, aged-scope and plan-validation waits emit structured SKIP:/STOP: lines instead of prompting, with claim rollback on post-claim stops. Interactive sessions unchanged. Closes #3959
1 parent 1a2a2cd commit dffc577

1 file changed

Lines changed: 22 additions & 1 deletion

File tree

.claude/skills/feature/SKILL.md

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,26 @@ The issue `body` is the **primary scope source** — read it, not just the title
6161
- Fresh issue with matching references → continue silently.
6262
- If the user aborts at this gate, roll back the FULL claim from step 3 — `gh issue edit <N> --remove-assignee @me` AND delete the `WIP —` comment just posted (`gh api -X DELETE repos/<owner>/<repo>/issues/comments/<comment-id>` — capture the id when posting, or take the last own `WIP —` comment). Leaving the comment behind would make step 2 treat the aborted claim as resumable on the next run.
6363

64+
### 4b. Non-interactive invocation (orchestrated runs)
65+
66+
When the invoker's brief declares a **non-interactive run** (an orchestrating
67+
agent executes the issue headlessly — no human present to answer), every
68+
STOP-and-ask in this skill becomes a structured final line instead of a
69+
question:
70+
71+
| Interactive behavior | Non-interactive replacement |
72+
|---|---|
73+
| Collision prompt (any `y/N` row of the table above) | Emit `SKIP: collision — <detail>` and stop |
74+
| `gh` command failure (step 1) or `state == closed` | Emit `STOP: claim — <error>` and stop |
75+
| Aged-scope drift confirmation (step 4) | Emit `STOP: freshness — <drift summary>` and stop |
76+
| Phase 0 "Present plan & wait for validation" | Satisfied by the issue body when the brief states the scope was validated upstream; insufficient scope → emit `STOP: scope — <gap>` and stop |
77+
78+
Never wait on a prompt in a non-interactive run. If the stop happens after
79+
the claim (step 3) already landed, roll the claim back first (step 4's
80+
rollback: `--remove-assignee` + delete the `WIP —` comment) so the aborted
81+
attempt doesn't read as live work on the next run. Interactive sessions keep
82+
the exact behavior above.
83+
6484
### 5. Proceed to Phase 0
6585

6686
Continue to scope analysis below.
@@ -104,7 +124,8 @@ For each user-facing flow this feature creates or modifies, identify:
104124
- Users impacted + notification plan
105125
- Open questions or scope decisions
106126

107-
**Wait for user validation before coding.**
127+
**Wait for user validation before coding.** (Non-interactive runs: Phase 0.0
128+
§4b — a validated issue body satisfies this step; never wait.)
108129

109130
## Phase 1 — Implementation
110131

0 commit comments

Comments
 (0)