* feat(spec-phase): spec-completeness edge-probe (#550) — relocated to gsd-core/
Rebased onto current next and relocated the whole feature from get-shit-done/ to
gsd-core/ per #615 (trek-e re-review #4, option 1). The artifact now builds to
gsd-core/bin/lib/edge-probe.cjs; all hard-coded path strings (tests, workflow
@-refs, run-tests.cjs sentinel, eslint ADR-457 ignore, .gitignore) updated.
Content conflicts in .gitignore / eslint.config.mjs / run-tests.cjs resolved.
Feature: Step 5.5 edge-completeness probe walks each SPEC requirement against a
closed 8-category edge taxonomy, proposes applicable candidate edges, and resolves
each (covered/dismissed/backstop/unresolved). covered/backstop criteria are lifted
by plan-phase into must_haves.truths, extending the goal-backward verifier's reach
to boundary edges no requirement was written for. Engine authored as strict TS
(src/edge-probe.cts, ADR-457), compiled to the gitignored gsd-core/bin/lib/edge-probe.cjs.
Folds in every prior review round on PR #584:
- RR-01..03: plan-phase resolves the phase *-SPEC.md and injects {SPEC_PATH} into the
planner; must_haves<->Edge-Coverage quality_gate; held-out planner-contract test.
- RR-04/11: Step 5.5 invokes the compiled engine at runtime (npm --prefix-pinned,
source-checkout-gated build fallback) instead of LLM re-derivation; the engine
capture is exit-checked and the report JSON-validated before use (fail closed).
- RR-05..10: all six fixtures embedded + count-equality; backstop/covered require a
resolution; Array.isArray(shapes); duplicate-resolution rejection; CLI JSON exit(2);
per-artifact build sentinel.
- Authored-shape validation: invalid (non-empty) shapes fail closed (VALID_SHAPES).
- Adversarial-review hardening: orphan/typo resolution rejection, requirement input
validation (id/text/shapes, duplicate id, non-array), zero-applicable guard.
Full suite 0 failures; npm run lint 0 errors; edge-probe suite 72/72.
* test(#550): RED — status×verification re-cut + probe-core engine specs
Re-cut the edge-probe resolution model onto two orthogonal axes per
ADR-550 Decision 7 (trek-e #644 comments 2026-06-03 14:36 + 14:44):
status: resolved | dismissed | unresolved (lifecycle, shared)
verification: explicit | backstop | null (only when resolved)
- tests/probe-core.test.cjs (new): behavioral specs for the generic engine
to be extracted — validateResolution(r, validators), validateRequirement,
analyzeCoverage(items, resolutions?, validators), byVerification rollup,
runProbeCli I/O scaffold (injected-io unit tests).
- tests/edge-probe.test.cjs: covered→{resolved,explicit}, backstop→
{resolved,backstop}; coverage gains byVerification.{explicit,backstop};
proposeEdges items gain verification:null.
- 6 fixtures re-genned + re-embedded in edge-probe.md; coverage.resolved
COUNT preserved on every fixture (closed set = resolved+dismissed; doc
line: 'adjacency=covered + ordering=dismissed' -> 2). edge-probe.md prose
rewritten to the two-axis model.
Fails as expected: probe-core.cjs has no source yet; edge-probe still
emits the old covered/backstop enum (27/61 edge specs red).
* feat(#550): extract probe-core seam + refactor edge-probe onto it (ADR-550 D7)
Extract the generic resolution model into src/probe-core.cts (the shared
seam the prohibition probe #644 is born on) and refactor edge-probe.cts
into its first adapter.
probe-core owns (probe-agnostic):
- the status×verification re-cut: status: resolved|dismissed|unresolved ×
verification: <probe-defined>|null
- validateResolution(r, validators) / validateRequirement (generic id+text)
- analyzeCoverage(items, resolutions?, validators) over ALREADY-PROPOSED
items[] (core never assumes propose is deterministic — edge resolves via
LLM, #644 proposes via LLM), with merge / dup-reject / orphan-reject
- byVerification rollup; coverage.resolved = closed set (resolved+dismissed),
count-preserved from the pre-re-cut engine
- runProbeCli I/O scaffold (injected io; one bin per probe)
- hybrid typing: generic params + injected runtime validators
{categories, verification, requiredFieldsByVerification} (ADR-550 #5)
edge-probe keeps ONLY the edge cluster: Shape/SHAPE_CUES/VALID_SHAPES/
classifyShape/TAXONOMY/applicableCategories/proposeEdges + EDGE_VALIDATORS
{explicit,backstop}; delegates merge/rollup/CLI to probe-core. Every shipped
#584 guarantee preserved (fail-closed shapes, orphan/dup rejection, input
validation, CLI exit 2). 104/104 edge+probe-core+docs+contract specs green.
* chore(#550): register probe-core.cjs artifact in ledgers + inventory
New gitignored build artifact gsd-core/bin/lib/probe-core.cjs (compiled
from src/probe-core.cts) needs registering in every artifact ledger:
- .gitignore + eslint.config.mjs ADR-457 ignore: lint the .cts source,
never the emitted .cjs.
- scripts/run-tests.cjs per-artifact build sentinel: build if probe-core.cjs
is missing on a clean checkout.
- docs/INVENTORY.md: CLI Modules 83 -> 84, new probe-core.cjs row, and the
edge-probe.cjs row updated to reflect it is now the first probe-core adapter.
- docs/INVENTORY-MANIFEST.json: regenerated (gen-inventory-manifest.cjs --write).
probe-core.test.cjs is a single test file (under the 2-file cap), so no
lint-test-file-count allowlist entry is needed.
* docs(adr-550): spec-phase probe pattern + prohibition contract [Accepted]
trek-e's final ADR-550 body, verbatim (open-gsd/gsd-core#644 comment
2026-06-03T15:23Z), Accepted by both maintainer and #550 author. Lands on
PR #584 alongside the probe-core extraction (Decision 7) it governs, so the
contract and its first implementation arrive together.
Decisions: probe packaging (3 layers); recall->precision protocol;
prohibition home = SPEC acceptance criteria + optional must_haves.prohibitions:
(truths untouched, no polarity); tiered verification test|judgment
(judgment = mode-dependent soft-gate-with-flags, never silent pass / never
hard-halt); CI tests the contract not the classifier; secure-phase ownership
seam; and Decision 7 — probe-core seam + status×verification re-cut (7a-7e),
which this PR implements.
* feat(#550): fail-closed probe-core across full status×verification + runProbeCli structural guard
Re-review #5 (trek-e) seam-hardening on the generic probe-core contract #644 inherits:
- validateResolution now enforces the 'verification is null unless resolved'
invariant for EVERY status (not just resolved): a dismissed/unresolved
resolution carrying a verification tier is rejected instead of merging verbatim.
- An unresolved resolution carrying a resolution/reason payload is rejected
(was silently dropped into the unresolved count).
- runProbeCli structurally validates the report an adapter returns before writing
it (was: any malformed object stringified as green output) — fails closed → exit 2.
- coverage.resolved kept count-preserved (closed set) per the blessed migration
contract; a new test locks that an all-dismissed run is NOT affirmatively covered
(byVerification is the honest gate).
Tests: probe-core 37/37; full edge-probe suite 113/113; full suite 1816/1816; lint 0.
* docs(adr-550): annotate Decision 5 #584/#644 scope + correct 7a coverage.resolved semantics
Re-review #5 (trek-e) clarity edits:
- Decision 5: annotate that only contract item (a) ships on #584 (the edge
adapter's parse+validate test); (b)–(d) are #644 scope, matching Consequences.
- Decision 7a: correct the 'coverage.resolved is preserved (status === resolved)'
parenthetical — the blessed/implemented semantics are count-preserved = the
CLOSED set (resolved + dismissed = applicable − unresolved), with byVerification
carrying the per-tier resolved-status breakdown. The old parenthetical
contradicted the shipped count.
* test(#550): cover runProbeCli structural-guard numeric-count branch
Second-pass coverage audit found the 'coverage object present but counts
non-numeric' branch of isValidReport (built probe-core.cjs:60-61) unexercised —
the {nope:true} malformed test fails earlier at the items[] check. Add a report
with well-formed items[] + a coverage object carrying non-numeric counts so the
numeric branch is hit. No source change; closes the line gap.
* fix(#550): reject edge requirement with missing/empty text when no shapes override (M2)
The edge adapter's `text` is the classification signal and a required field, but
core `validateRequirement` left it optional, so a `{ id }` requirement classified to
zero shapes -> zero edges -> was silently DROPPED from coverage with no signal -- the
exact fail-open this feature exists to eliminate. Reject missing/empty text unless an
authored `shapes` override (incl. `[]`) opts out of prose classification.
* fix(#550): validate verbatim items in analyzeCoverage shared seam (m1)
A proposed item with no matching author resolution is rolled up VERBATIM, but its own
status/fields were never validated -- an item carrying an out-of-enum status (the dropped
"covered") or `dismissed` without a reason would be counted closed. The edge adapter only
proposes `unresolved` items, but the prohibition adapter (#644) proposes LLM-generated
items that arrive populated. An Item is structurally a superset of a Resolution, so reuse
validateResolution to fail closed. ADR-550 Decision 5 hardens this shared seam.
* fix(#550): move edge-coverage lift instruction to runtime planner surface (M1)
templates/planner-subagent-prompt.md is loaded by nothing at runtime (no @-import in
agents/gsd-planner.md; plan-phase.md spawns the planner from its own inline
<planning_context>), so the precise covered/backstop -> must_haves.truths lift instruction
this PR added there never reached the planner -- and the RR-02 contract test asserted it in
that dead file, giving false green. Move the instruction into plan-phase.md's runtime
<downstream_consumer> block (where the rest of the wire already lives), revert the dead-template
edit, and retarget RR-02 to the loaded surface with a guard against re-orphaning.
* test(#550): lock machine<->SPEC vocabulary mapping against drift (m2)
The machine contract uses orthogonal status x verification; the SPEC table renders a flat
covered/dismissed/backstop/unresolved. The migration map (ADR-550 Decision 7a) was prose-only
with no test, so the layers could silently drift. The SPEC table is LLM-rendered (no JS
renderer to round-trip), so pin the canonical bijection as code AND ground it in every doc
surface that renders the vocabulary (ADR migration clause, spec.md legend, reference mapping
table) -- a rename or remap now fails the suite.
* docs(#550): add how-to for resolving edge-coverage findings (B1)
Feature shipped reference coverage (FEATURES.md, COMMANDS.md, references/edge-probe.md) but
no how-to -- reference-only does not satisfy the Diataxis docs standard for a user-facing
capability. Add a single-mode how-to (imperative, goal-directed) walking each resolution
state (specify/dismiss/backstop/defer), the soft gate, and --auto, with taxonomy/concepts
linked out to the reference. Register it in the docs/how-to index.
* docs(#550): add Probe Core + Edge Probe glossary entries to CONTEXT.md (N1)
trek-e re-review #7 N1 (Major): adding probe-core/edge-probe as src/*.cts-derived
seam modules (ADR-550 Decision 7) requires CONTEXT.md Domain-terms glossary entries
per the maintainer-enforced new-seam gate. Adds '### Probe Core Module' and
'### Edge Probe Module' with exports, generated source paths, and the ADR-550 seam
contract, placed beside the Research Module feature-seam entries.
* test(#550): add fast-check property suite for probe-core analyzeCoverage (N2)
trek-e re-review #7 N2 (RULESET.TESTS.property-based-testing): analyzeCoverage is a
transformation/rollup module, the class the property-testing predicate covers, and
fast-check is already a dependency with an established *.property.test.cjs pattern.
Adds 5 properties over the algebraic invariants: closed-set identity
(applicable === resolved + unresolved), byVerification sums ≤ resolved, per-tier
recount + resolved-status-only counting, rollup determinism, and stable orphan
rejection. 200 runs/seed 42 via helpers/fast-check-setup.cjs.
* test(#550): align allow-test-rule tokens to canonical runtime-contract-is-the-product (N3)
trek-e re-review #7 N3 (Nit): the // allow-test-rule: tokens (source-text-is-the-product,
docs-parity) differed from CONTEXT.md's canonical exemption category
'runtime-contract-is-the-product' (RULESET.TESTS.no-source-grep.exemption, CONTEXT.md:240).
All three tests assert deployed runtime-contract surfaces (spec-phase.md Step 5.5, the
plan-phase.md planner prompt, the rendered reference/SPEC/ADR vocabulary), so the canonical
category fits; each now carries a one-line justification per the ruleset format. Free-text
reason — lint behavior unchanged.
* test(#550): re-baseline plan-phase + spec-phase byte sizes for edge-probe
Rebased onto next (e4f0910d), which replaced the line-based tier-max
size ratchet (#597) with the byte-based per-file baseline guard (#1074).
The edge-probe feature legitimately grows two workflows:
- spec-phase.md 15131 -> 23094 (+7963): Step 5.5 Edge-Completeness Probe
- plan-phase.md 93135 -> 94253 (+1118): covered/backstop edge lift into
must_haves.truths (the live <downstream_consumer> block)
Both remain under their tier hard caps (plan-phase XL 98304, ~4KB
headroom; spec-phase DEFAULT 40960). Growth is real inline workflow
content the feature requires at that step — not eager @-import proxy
gaming. Drops the obsolete line-based XL_BUDGET 93000->94000 bump
(superseded by the byte baseline) via rebase.
* chore(#550): reconcile INVENTORY headline counts after rebase onto next
Rebase onto current next dropped the prior reconcile commit (stale counts
refs 68 / CLI 107). Current next + the edge-probe additions yield:
- References (68 -> 69 shipped): + gsd-core/references/edge-probe.md
- CLI Modules (107 -> 109 shipped): + edge-probe.cjs + probe-core.cjs
Rows for all three already present; only the headline counts were stale.
Caught by tests/inventory-counts.test.cjs (CI ubuntu-24 leg).
15 KiB
Phase Spec Template
Template for .planning/phases/XX-name/{phase_num}-SPEC.md — locks requirements before discuss-phase.
Purpose: Capture WHAT a phase delivers and WHY, with enough precision that requirements are falsifiable. discuss-phase reads this file and focuses on HOW to implement (skipping "what/why" questions already answered here).
Key principle: Every requirement must be falsifiable — you can write a test or check that proves it was met or not. Vague requirements like "improve performance" are not allowed.
Downstream consumers:
discuss-phase— reads SPEC.md at startup; treats Requirements, Boundaries, and Acceptance Criteria as locked; skips "what/why" questionsgsd-planner— reads locked requirements to constrain plan scopegsd-verifier— uses acceptance criteria as explicit pass/fail checks
File Template
# Phase [X]: [Name] — Specification
**Created:** [date]
**Ambiguity score:** [score] (gate: ≤ 0.20)
**Requirements:** [N] locked
## Goal
[One precise sentence — specific and measurable. NOT "improve X" — instead "X changes from A to B".]
## Background
[Current state from codebase — what exists today, what's broken or missing, what triggers this work. Grounded in code reality, not abstract description.]
## Requirements
1. **[Short label]**: [Specific, testable statement.]
- Current: [what exists or does NOT exist today]
- Target: [what it should become after this phase]
- Acceptance: [concrete pass/fail check — how a verifier confirms this was met]
2. **[Short label]**: [Specific, testable statement.]
- Current: [what exists or does NOT exist today]
- Target: [what it should become after this phase]
- Acceptance: [concrete pass/fail check]
[Continue for all requirements. Each must have Current/Target/Acceptance.]
## Boundaries
**In scope:**
- [Explicit list of what this phase produces]
- [Each item is a concrete deliverable or behavior]
**Out of scope:**
- [Explicit list of what this phase does NOT do] — [brief reason why it's excluded]
- [Adjacent problems excluded from this phase] — [brief reason]
## Constraints
[Performance, compatibility, data volume, dependency, or platform constraints.
If none: "No additional constraints beyond standard project conventions."]
## Acceptance Criteria
- [ ] [Pass/fail criterion — unambiguous, verifiable]
- [ ] [Pass/fail criterion]
- [ ] [Pass/fail criterion]
[Every acceptance criterion must be a checkbox that resolves to PASS or FAIL.
No "should feel good", "looks reasonable", or "generally works" — those are not checkboxes.]
## Edge Coverage
**Coverage:** [resolved]/[applicable] applicable edges resolved · [unresolved] unresolved
| Category | Requirement | Status | Resolution / Reason |
|----------|-------------|--------|---------------------|
| [category] | [Rn] | [✅ covered / ⛔ dismissed / 🧪 backstop / ⚠ UNRESOLVED] | [acceptance criterion ref, dismissal reason, or backstop test note] |
[Generated by the edge-completeness probe (Step 5.5). `covered` rows correspond to
Acceptance Criteria above; `backstop` rows must be carried into plan-phase `must_haves`.
`⚠ UNRESOLVED` rows are flagged: planner must treat as assumption.]
## Ambiguity Report
| Dimension | Score | Min | Status | Notes |
|--------------------|-------|------|--------|------------------------------------|
| Goal Clarity | | 0.75 | | |
| Boundary Clarity | | 0.70 | | |
| Constraint Clarity | | 0.65 | | |
| Acceptance Criteria| | 0.70 | | |
| **Ambiguity** | | ≤0.20| | |
Status: ✓ = met minimum, ⚠ = below minimum (planner treats as assumption)
## Interview Log
[Key decisions made during the Socratic interview. Format: round → question → answer → decision locked.]
| Round | Perspective | Question summary | Decision locked |
|-------|----------------|-------------------------|------------------------------------|
| 1 | Researcher | [what was asked] | [what was decided] |
| 2 | Simplifier | [what was asked] | [what was decided] |
| 3 | Boundary Keeper| [what was asked] | [what was decided] |
[If --auto mode: note "auto-selected" decisions with the reasoning Claude used.]
---
*Phase: [XX-name]*
*Spec created: [date]*
*Next step: /gsd:discuss-phase [X] — implementation decisions (how to build what's specified above)*
<good_examples>
Example 1: Feature addition (Post Feed)
# Phase 3: Post Feed — Specification
**Created:** 2025-01-20
**Ambiguity score:** 0.12
**Requirements:** 4 locked
## Goal
Users can scroll through posts from accounts they follow, with new posts available after pull-to-refresh.
## Background
The database has a `posts` table and `follows` table. No feed query or feed UI exists today. The home screen shows a placeholder "Your feed will appear here." This phase builds the feed query, API endpoint, and the feed list component.
## Requirements
1. **Feed query**: Returns posts from followed accounts ordered by creation time, descending.
- Current: No feed query exists — `posts` table is queried directly only from profile pages
- Target: `GET /api/feed` returns paginated posts from followed accounts, newest first, max 20 per page
- Acceptance: Query returns correct posts for a user who follows 3 accounts with known post counts; cursor-based pagination advances correctly
2. **Feed display**: Posts display in a scrollable card list.
- Current: Home screen shows static placeholder text
- Target: Home screen renders feed cards with author, timestamp, post content, and reaction count
- Acceptance: Feed renders without error for 0 posts (empty state shown), 1 post, and 20+ posts
3. **Pull-to-refresh**: User can refresh the feed manually.
- Current: No refresh mechanism exists
- Target: Pull-down gesture triggers refetch; new posts appear at top of list
- Acceptance: After a new post is created in test, pull-to-refresh shows the new post without full app restart
4. **New posts indicator**: When new posts arrive, a banner appears instead of auto-scrolling.
- Current: No such mechanism
- Target: "3 new posts" banner appears when refetch returns posts newer than the oldest visible post; tapping banner scrolls to top and shows new posts
- Acceptance: Banner appears for ≥1 new post, does not appear when no new posts, tap navigates to top
## Boundaries
**In scope:**
- Feed query (backend) — posts from followed accounts, paginated
- Feed list UI (frontend) — post cards with author, timestamp, content, reaction counts
- Pull-to-refresh gesture
- New posts indicator banner
- Empty state when user follows no one or no posts exist
**Out of scope:**
- Creating posts — that is Phase 4
- Reacting to posts — that is Phase 5
- Following/unfollowing accounts — that is Phase 2 (already done)
- Push notifications for new posts — separate backlog item
## Constraints
- Feed query must use cursor-based pagination (not offset) — the database has 500K+ posts and offset pagination is unacceptably slow beyond page 3
- The feed card component must reuse the existing `<AvatarImage>` component from Phase 2
## Acceptance Criteria
- [ ] `GET /api/feed` returns posts only from followed accounts (not all posts)
- [ ] `GET /api/feed` supports `cursor` parameter for pagination
- [ ] Feed renders correctly at 0, 1, and 20+ posts
- [ ] Pull-to-refresh triggers refetch
- [ ] New posts indicator appears when posts newer than current view exist
- [ ] Empty state renders when user follows no one
## Ambiguity Report
| Dimension | Score | Min | Status | Notes |
|--------------------|-------|------|--------|----------------------------------|
| Goal Clarity | 0.92 | 0.75 | ✓ | |
| Boundary Clarity | 0.95 | 0.70 | ✓ | Explicit out-of-scope list |
| Constraint Clarity | 0.80 | 0.65 | ✓ | Cursor pagination required |
| Acceptance Criteria| 0.85 | 0.70 | ✓ | 6 pass/fail criteria |
| **Ambiguity** | 0.12 | ≤0.20| ✓ | |
## Interview Log
| Round | Perspective | Question summary | Decision locked |
|-------|-----------------|------------------------------|-----------------------------------------|
| 1 | Researcher | What exists in posts today? | posts + follows tables exist, no feed |
| 2 | Simplifier | Minimum viable feed? | Cards + pull-refresh, no auto-scroll |
| 3 | Boundary Keeper | What's NOT this phase? | Creating posts, reactions out of scope |
| 3 | Boundary Keeper | What does done look like? | Scrollable feed with 4 card fields |
---
*Phase: 03-post-feed*
*Spec created: 2025-01-20*
*Next step: /gsd:discuss-phase 3 — implementation decisions (card layout, loading skeleton, etc.)*
Example 2: CLI tool (Database backup)
# Phase 2: Backup Command — Specification
**Created:** 2025-01-20
**Ambiguity score:** 0.15
**Requirements:** 3 locked
## Goal
A `gsd backup` CLI command creates a reproducible database snapshot that can be restored by `gsd restore` (a separate phase).
## Background
No backup tooling exists. The project uses PostgreSQL. Developers currently use `pg_dump` manually — there is no standardized process, no output naming convention, and no CI integration. Three incidents in the last quarter involved restoring from wrong or corrupt dumps.
## Requirements
1. **Backup creation**: CLI command executes a full database backup.
- Current: No `backup` subcommand exists in the CLI
- Target: `gsd backup` connects to the database (via `DATABASE_URL` env or `--db` flag), runs pg_dump, writes output to `./backups/YYYY-MM-DD_HH-MM-SS.dump`
- Acceptance: Running `gsd backup` on a test database creates a `.dump` file; running `pg_restore` on that file recreates the database without error
2. **Network retry**: Transient network failures are retried automatically.
- Current: pg_dump fails immediately on network error
- Target: Backup retries up to 3 times with 5-second delay; 4th failure exits with code 1 and a message to stderr
- Acceptance: Simulating 2 sequential network failures causes 2 retries then success; simulating 4 failures causes exit code 1 and stderr message
3. **Partial cleanup**: Failed backups do not leave corrupt files.
- Current: Manual pg_dump leaves partial files on failure
- Target: If backup fails after starting, the partial `.dump` file is deleted before exit
- Acceptance: After a simulated failure mid-dump, no `.dump` file exists in `./backups/`
## Boundaries
**In scope:**
- `gsd backup` subcommand (full dump only)
- Output to `./backups/` directory (created if missing)
- Network retry (3 attempts)
- Partial file cleanup on failure
**Out of scope:**
- `gsd restore` — that is Phase 3
- Incremental backups — separate backlog item (full dump only for now)
- S3 or remote storage — separate backlog item
- Encryption — separate backlog item
- Scheduled/cron backups — separate backlog item
## Constraints
- Must use `pg_dump` (not a custom query) — ensures compatibility with standard `pg_restore`
- `--no-retry` flag must be available for CI use (fail fast, no retries)
## Acceptance Criteria
- [ ] `gsd backup` creates a `.dump` file in `./backups/YYYY-MM-DD_HH-MM-SS.dump` format
- [ ] `gsd backup` uses `DATABASE_URL` env var or `--db` flag for connection
- [ ] 3 retries on network failure, then exit code 1 with stderr message
- [ ] `--no-retry` flag skips retries and fails immediately on first error
- [ ] No partial `.dump` file left after a failed backup
## Ambiguity Report
| Dimension | Score | Min | Status | Notes |
|--------------------|-------|------|--------|--------------------------------|
| Goal Clarity | 0.90 | 0.75 | ✓ | |
| Boundary Clarity | 0.95 | 0.70 | ✓ | Explicit out-of-scope list |
| Constraint Clarity | 0.75 | 0.65 | ✓ | pg_dump required |
| Acceptance Criteria| 0.80 | 0.70 | ✓ | 5 pass/fail criteria |
| **Ambiguity** | 0.15 | ≤0.20| ✓ | |
## Interview Log
| Round | Perspective | Question summary | Decision locked |
|-------|-----------------|------------------------------|-----------------------------------------|
| 1 | Researcher | What backup tooling exists? | None — pg_dump manual only |
| 2 | Simplifier | Minimum viable backup? | Full dump only, local only |
| 3 | Boundary Keeper | What's NOT this phase? | Restore, S3, encryption excluded |
| 4 | Failure Analyst | What goes wrong on failure? | Partial files, CI fail-fast needed |
---
*Phase: 02-backup-command*
*Spec created: 2025-01-20*
*Next step: /gsd:discuss-phase 2 — implementation decisions (progress reporting, flag design, etc.)*
</good_examples>
**Every requirement needs all three fields:** - Current: grounds the requirement in reality — what exists today? - Target: the concrete change — not "improve X" but "X becomes Y" - Acceptance: the falsifiable check — how does a verifier confirm this?Ambiguity Report must reflect the actual interview. If a dimension is below minimum, mark it ⚠ — the planner knows to treat it as an assumption rather than a locked requirement.
Interview Log is evidence of rigor. Don't skip it. It shows that requirements came from discovery, not assumption.
Boundaries protect the phase from scope creep. The out-of-scope list with reasoning is as important as the in-scope list. Future phases that touch adjacent areas can point to this SPEC.md to understand what was intentionally excluded.
SPEC.md is a one-way door for requirements. discuss-phase will treat these as locked. If requirements change after SPEC.md is written, the user should update SPEC.md first, then re-run discuss-phase.
SPEC.md does NOT replace CONTEXT.md. They serve different purposes:
- SPEC.md: what the phase delivers (requirements, boundaries, acceptance criteria)
- CONTEXT.md: how the phase will be implemented (decisions, patterns, tradeoffs)
discuss-phase generates CONTEXT.md after reading SPEC.md.