feat(autonomous): add --interactive flag for lean context with user input

The autonomous workflow previously had two extremes: full auto-answer
mode (--auto discuss, lean context but no user input) or manager mode
(interactive but bloated context from accumulating everything inline).

The --interactive flag bridges this gap:
- Discuss runs inline via gsd:discuss-phase (asks questions, waits for
  user answers — preserving all design decisions)
- Plan and execute dispatch as background agents (fresh context per
  phase — no accumulation in the main session)
- Pipeline parallelism: discuss Phase N+1 while Phase N builds in the
  background

This keeps the main context lean (only discuss conversations accumulate)
while preserving user input on all decisions. Particularly helpful for
users hitting context limits with /gsd:manager on multi-phase milestones.

Usage:
  /gsd:autonomous --interactive
  /gsd:autonomous --interactive --from 3
  /gsd:autonomous --interactive --only 5

Also adds --only N flag parsing to the upstream workflow (previously only
in PR #1444's branch).

Closes #1413

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Tibsfox
2026-03-30 00:00:31 -07:00
parent 78e5c6d973
commit 2aca125308
4 changed files with 154 additions and 8 deletions

View File

@@ -651,7 +651,7 @@ describe('copyCommandsAsCopilotSkills', () => {
assert.ok(skillContent.includes('description: Run all remaining phases autonomously'),
'description preserved');
// argument-hint present and double-quoted
assert.ok(skillContent.includes('argument-hint: "[--from N]"'), 'argument-hint present and quoted');
assert.ok(skillContent.includes('argument-hint: "[--from N] [--only N] [--interactive]"'), 'argument-hint present and quoted');
// allowed-tools comma-separated
assert.ok(skillContent.includes('allowed-tools: Read, Write, Bash, Glob, Grep, AskUserQuestion, Task'),
'allowed-tools is comma-separated');