Files
msd-core/get-shit-done/workflows/list-phase-assumptions.md
Tom Boucher 85c67b4b21 chore: invalidate bug-2543 outdated namespace invariant + document /gsd-<cmd> migration in CONTEXT.md (#164)
* test(meta): invalidate bug-2543 outdated /gsd:<cmd> namespace invariant

The "no /gsd-<cmd> hyphen form in source files" scan (test 2 of the
describe block) is skipped via test.skip. Motivation:

- Bug-3584 (2026-05-15) introduced runtime-slash.cjs, which intentionally
  emits `/gsd-${token}` for skills-based runtimes. This is the correct
  canonical form for runtime-persisted strings (ROADMAP.md, STATE.md,
  recommended_actions, fix hints).
- Bug-2543 was last updated 2026-05-12, three days BEFORE bug-3584 landed.
  The "no hyphen form" invariant was never updated to reflect the new
  two-tier model.
- PR #154 first-pass: an agent misread bug-2543 and reverted the correct
  `/gsd-plan-phase` to `/gsd:plan-phase` in phase-lifecycle-policy.ts:156,
  breaking tests/bug-3584-runtime-slash-emitters.test.cjs. A 2nd-pass agent
  reverted.

The canonical active invariant for runtime-emitter context is:
  tests/bug-3584-runtime-slash-emitters.test.cjs

The remaining 4 tests in this file (commands/gsd/ existence, command
filename slug format, transformer behavior, non-command identifier safety)
are still valid and remain active — only test 2 is skipped. This avoids
vacuous-truth (a full describe-block skip would let all assertions pass
trivially).

See CONTEXT.md § "Slash-command form: /gsd-<cmd> vs /gsd:<cmd>" (added
in the companion commit) for the full two-tier model documentation.

User directive: 2026-05-23 session authorizing this invalidation.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* docs(context): document /gsd-<cmd> slash-command migration for AI agents

Adds CONTEXT.md § "Slash-command form: /gsd-<cmd> (current) vs /gsd:<cmd>
(legacy)" to give future agents an unambiguous reference for which form
to use in which context.

Covers:
- The two-tier model (source text → colon; runtime-emitted strings → hyphen)
- The runtime-emitter authority: get-shit-done/bin/lib/runtime-slash.cjs
- The canonical invariant test: bug-3584-runtime-slash-emitters.test.cjs
- The PR #154 incident: how an agent misread bug-2543 and applied the wrong form
- An explicit "Context for AI agents" block: stop and re-read if bug-2543 is
  influencing a patch
- A note that DEFECT.AGENT-RETIRED-SLASH-SYNTAX-DRIFT.* predicates (written
  pre-two-tier) are stale for runtime-emitter contexts

Also updates the stale DEFECT predicates at the end of CONTEXT.md with a
clarifying note (the predicates remain for historical reference; the new §
supersedes their fix-forward guidance for runtime-emitter contexts).

Motivation: PR #154 first-pass incident (2026-05-23 session).
Canonical runtime contract: tests/bug-3584-runtime-slash-emitters.test.cjs.
Companion: test(meta) commit invalidating bug-2543's scan.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* test(meta): re-activate bug-2543 scan as scoped invariant, exclude runtime-emitter contexts

Codex adversarial review of PR #164 [high finding]: the single content-scanning
test in bug-2543 was test.skip, leaving a vacuous test surface. The transformer/
filename unit tests remained active but no live source surface was guarded.

Fix: replace test.skip with an active scoped invariant.

Scope change:
- REMOVED get-shit-done/bin/lib/ from SEARCH_DIRS entirely. That directory is
  runtime-emitter territory (runtime-slash.cjs, *.generated.cjs,
  phase-lifecycle-policy.ts) and intentionally uses /gsd-<cmd> (hyphen) per
  bug-3584's contract. Scanning it causes false positives that led to PR #154
  first-pass incident.
- Added RUNTIME_EMITTER_EXCLUDES set documenting exactly why each file is exempt.
- Remaining SEARCH_DIRS (workflows/, references/, templates/, commands/gsd/,
  agents/, hooks/) are Claude-facing source — colon form is correct there.

Verified: 9/9 tests pass, 0 skipped.
Canonical runtime-emitter contract: tests/bug-3584-runtime-slash-emitters.test.cjs
bug-2543's scoped scope: excludes bin/lib/ (runtime-emitter contexts).

* docs(context): rewrite slash-command section as directory-level matrix

Codex adversarial review of PR #164 [high finding]: the previous CONTEXT.md
section was internally contradictory — line 616 claimed /gsd-<cmd> was globally
canonical while lines 634/640 correctly stated Claude-facing source text uses
/gsd:<cmd>. Same document; opposite claims.

Root cause: the first push of this section (2026-05-23) overstated the hyphen
form as universal, when the project has always had a two-tier model.

Fix: replace the section with an unambiguous directory-level matrix.

New structure:
- Single table mapping each directory/surface to its correct form and enforcement.
- "How to choose" decision tree (4 steps, replaces ambiguous prose).
- "What was WRONG previously" retains historical motivation and adds the
  PR #164 contradiction incident to the record.
- "Context for AI agents" updated: ban mass-rewrites based on single test failure,
  cite the two-tier model explicitly.

Two-tier model (unchanged from reality, now clearly documented):
- Claude-facing source (commands/, agents/, workflows/, etc.): /gsd:<cmd> colon.
- Runtime-emitter contexts (runtime-slash.cjs, *.generated.cjs, ROADMAP.md
  persistence): /gsd-<cmd> hyphen per bug-3584 invariant.

Canonical authorities: bug-2543 (colon contract), bug-3584 (hyphen contract).

* fix(workflows): replace dead /gsd-* tokens with live registry forms

Codex adversarial review of PR #164 [medium finding]: stale slash-command
references in user-facing workflow content. Registry-backed sweep confirmed
the following tokens are not in commands/gsd/ registry.

Tokens removed/updated (dead token → live registry form):

1. /gsd-remove-workspace → /gsd:workspace --remove <name>
   File: get-shit-done/workflows/list-workspaces.md:58
   Reason: no commands/gsd/remove-workspace.md; remove-workspace is a subcommand
   of /gsd:workspace (commands/gsd/workspace.md, --remove flag).

2. /gsd-list-workspaces → /gsd:workspace --list
   File: get-shit-done/workflows/remove-workspace.md:35
   Reason: no commands/gsd/list-workspaces.md; list-workspaces is a subcommand
   of /gsd:workspace (commands/gsd/workspace.md, --list flag).

3. /gsd-list-phase-assumptions <phase> → /gsd:discuss-phase <phase> --assumptions
   File: get-shit-done/workflows/list-phase-assumptions.md:17-18 (usage block)
   Reason: no commands/gsd/list-phase-assumptions.md; the workflow is invoked
   via commands/gsd/discuss-phase.md with --assumptions flag.

4. /gsd-list-phase-assumptions 2 → /gsd:discuss-phase 2 --assumptions
   File: get-shit-done/references/continuation-format.md:59
   Reason: same as #3.

Sweep scope: user-facing markdown only (workflows/, references/). Runtime-emitter
hyphen-form references in bin/lib/ are guarded by bug-3584 and were not touched.

* chore(164): add changeset fragment for adversarial-review fixes

The 3 commits addressing Codex review touched user-facing surfaces
(get-shit-done/workflows/, get-shit-done/references/, CONTEXT.md,
bug-2543 test). Add fragment to satisfy changeset-lint.

Refs #164

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-23 18:42:47 -04:00

4.2 KiB

Surface Claude's assumptions about a phase before planning, enabling users to correct misconceptions early.

Key difference from discuss-phase: This is ANALYSIS of what Claude thinks, not INTAKE of what user knows. No file output - purely conversational to prompt discussion.

Phase number: $ARGUMENTS (required)

If argument missing:

Error: Phase number required.

Usage: /gsd:discuss-phase <phase-number> --assumptions
Example: /gsd:discuss-phase 3 --assumptions

Exit workflow.

If argument provided: Validate phase exists in roadmap:

cat .planning/ROADMAP.md | grep -i "Phase ${PHASE}"

If phase not found:

Error: Phase ${PHASE} not found in roadmap.

Available phases:
[list phases from roadmap]

Exit workflow.

If phase found: Parse phase details from roadmap:

  • Phase number
  • Phase name
  • Phase description/goal
  • Any scope details mentioned

Continue to analyze_phase.

Based on roadmap description and project context, identify assumptions across five areas:

1. Technical Approach: What libraries, frameworks, patterns, or tools would Claude use?

  • "I'd use X library because..."
  • "I'd follow Y pattern because..."
  • "I'd structure this as Z because..."

2. Implementation Order: What would Claude build first, second, third?

  • "I'd start with X because it's foundational"
  • "Then Y because it depends on X"
  • "Finally Z because..."

3. Scope Boundaries: What's included vs excluded in Claude's interpretation?

  • "This phase includes: A, B, C"
  • "This phase does NOT include: D, E, F"
  • "Boundary ambiguities: G could go either way"

4. Risk Areas: Where does Claude expect complexity or challenges?

  • "The tricky part is X because..."
  • "Potential issues: Y, Z"
  • "I'd watch out for..."

5. Dependencies: What does Claude assume exists or needs to be in place?

  • "This assumes X from previous phases"
  • "External dependencies: Y, Z"
  • "This will be consumed by..."

Be honest about uncertainty. Mark assumptions with confidence levels:

  • "Fairly confident: ..." (clear from roadmap)
  • "Assuming: ..." (reasonable inference)
  • "Unclear: ..." (could go multiple ways)
Present assumptions in a clear, scannable format:
## My Assumptions for Phase ${PHASE}: ${PHASE_NAME}

### Technical Approach
[List assumptions about how to implement]

### Implementation Order
[List assumptions about sequencing]

### Scope Boundaries
**In scope:** [what's included]
**Out of scope:** [what's excluded]
**Ambiguous:** [what could go either way]

### Risk Areas
[List anticipated challenges]

### Dependencies
**From prior phases:** [what's needed]
**External:** [third-party needs]
**Feeds into:** [what future phases need from this]

---

**What do you think?**

Are these assumptions accurate? Let me know:
- What I got right
- What I got wrong
- What I'm missing

Wait for user response.

**If user provides corrections:**

Acknowledge the corrections:

Key corrections:
- [correction 1]
- [correction 2]

This changes my understanding significantly. [Summarize new understanding]

If user confirms assumptions:

Assumptions validated.

Continue to offer_next.

Present next steps:
What's next?
1. Discuss context (/gsd:discuss-phase ${PHASE}) - Let me ask you questions to build comprehensive context
2. Plan this phase (/gsd:plan-phase ${PHASE}) - Create detailed execution plans
3. Re-examine assumptions - I'll analyze again with your corrections
4. Done for now

Wait for user selection.

If "Discuss context": Note that CONTEXT.md will incorporate any corrections discussed here If "Plan this phase": Proceed knowing assumptions are understood If "Re-examine": Return to analyze_phase with updated understanding

<success_criteria>

  • Phase number validated against roadmap
  • Assumptions surfaced across five areas: technical approach, implementation order, scope, risks, dependencies
  • Confidence levels marked where appropriate
  • "What do you think?" prompt presented
  • User feedback acknowledged
  • Clear next steps offered </success_criteria>