From smith
Asks up to 5 targeted clarification questions to identify underspecified areas in a feature spec, then encodes answers back into the spec file.
How this skill is triggered — by the user, by Claude, or both
Slash command
/smith:smith-clarifyThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
> **Workflow requirement (Smith 20+):** This skill must be invoked from inside an active top-level workflow (`/smith-new`, `/smith-bugfix`, `/smith-debug`, `/smith-build`). The workflow-gate hook will block standalone invocation. To use this skill standalone, start a top-level workflow first.
Workflow requirement (Smith 20+): This skill must be invoked from inside an active top-level workflow (
/smith-new,/smith-bugfix,/smith-debug,/smith-build). The workflow-gate hook will block standalone invocation. To use this skill standalone, start a top-level workflow first.
Throughout this action, log significant events to the vault session log. Read the session log path from .smith/vault/.current-session. If the file is missing or the vault is not initialized, skip all logging silently.
Append entries using this format:
### [HH:MM:SS] /smith-clarify <event>
**User Request:**
> <verbatim user message that triggered this action>
**Synthesized Input:** <brief summary>
**Outcome:** <what happened>
**Artifacts:** <files modified>
**Systems affected:** <system IDs>
Log at these points:
$ARGUMENTS
You MUST consider the user input before proceeding (if not empty).
Goal: Detect and reduce ambiguity or missing decision points in the active feature specification and record the clarifications directly in the spec file.
Note: This clarification workflow is expected to run (and be completed) BEFORE invoking /smith-plan. If the user explicitly states they are skipping clarification (e.g., exploratory spike), you may proceed, but must warn that downstream rework risk increases.
Execution steps:
Run .specify/scripts/bash/check-prerequisites.sh --json --paths-only from repo root once (combined --json --paths-only mode / -Json -PathsOnly). Parse minimal JSON payload fields:
FEATURE_DIRFEATURE_SPECIMPL_PLAN, TASKS for future chained flows.)/smith-specify or verify feature branch environment.Questions file location: Store the questions file inside the feature spec folder at FEATURE_DIR/questions.md (NOT in a separate specs/questions/ directory). The questions are part of the feature's decision record and should travel with the feature spec. If FEATURE_DIR points to a .specify/systems/<system>/features/<feature>/ path, use that directly. If clarify is run multiple times, append new questions to the existing file with a ### Session YYYY-MM-DD timestamp header rather than overwriting.
1.5. Check for existing unanswered questions. After resolving FEATURE_DIR, check if FEATURE_DIR/questions.md exists. If it does, scan for unanswered questions — lines matching **Answer**: ___ or **Answer:** followed by only whitespace/underscore.
If unanswered questions exist: Skip the spec ambiguity scan (steps 2-3) and enter the Interactive Answer Collection flow below. This handles the case where /smith-new generated a questions.md during the planning phase and the user wants to answer them conversationally.
If no questions.md exists, or all questions are already answered: Proceed with the normal spec ambiguity scan (steps 2-4).
When a questions.md file exists with unanswered questions, walk through each one interactively:
A. Parse questions.md — extract all question blocks. Each block has: question number, topic, context, question text, options table, recommended answer, and current answer status.
B. For each unanswered question, present it one at a time:
Display in this format:
## Question [N] of [Total]: [Topic]
**Context:** [Quote from plan/spec that raises this question]
**Question:** [The specific implementation decision]
**Options:**
| Option | Description | Implications |
|--------|-------------|--------------|
| A | [description] | [pros: ..., cons: ...] |
| B | [description] | [pros: ..., cons: ...] |
| C | [description] | [pros: ..., cons: ...] |
**Recommended:** [Option letter] — [Clear reasoning for why this is the best choice]
Reply with an option letter (e.g., "A"), say "yes" to accept the recommendation,
type "skip" to defer this question, or provide your own custom answer.
C. Process the user's response:
"yes", "recommended", or "rec" → use the recommended answer"A", "B", "C") → use that option's description as the answer"skip" → mark as **Answer:** SKIPPED — needs follow-upD. After each answer, immediately:
questions.md — replace the **Answer**: ___ line for that question with **Answer:** [chosen answer]Saved: Q[N] → [brief answer summary]. ([remaining] questions remaining)E. If the session is interrupted before all questions are answered, the questions.md file reflects the current state — answered questions have their answers filled in, unanswered questions still show **Answer**: ___. The user can resume later by running /smith-clarify again (it will pick up where they left off).
F. After all questions are answered (or the user says "done"):
questions.md header — change **Status**: AWAITING ANSWERS to **Status**: ANSWERED (or PARTIALLY ANSWERED if any were skipped)## Answers Summary
| # | Topic | Answer |
|---|-------|--------|
| Q1 | [topic] | [answer] |
| Q2 | [topic] | [answer] |
| Q3 | [topic] | SKIPPED |
...
## Implementation Decisions section in the spec if answers affect implementation approach/smith-plan to generate the implementation plan."Log all answers to the vault session log per the Vault Logging section above.
After completing the Interactive Answer Collection, skip to step 8 (Report completion).
Load the current spec file. Perform a structured ambiguity & coverage scan using this taxonomy. For each category, mark status: Clear / Partial / Missing. Produce an internal coverage map used for prioritization (do not output raw map unless no questions will be asked).
Functional Scope & Behavior:
Domain & Data Model:
Interaction & UX Flow:
Non-Functional Quality Attributes:
Integration & External Dependencies:
Edge Cases & Failure Handling:
Constraints & Tradeoffs:
Terminology & Consistency:
Completion Signals:
Misc / Placeholders:
For each category with Partial or Missing status, add a candidate question opportunity unless:
Generate (internally) a prioritized queue of candidate clarification questions (maximum 5). Do NOT output them all at once. Apply these constraints:
Sequential questioning loop (interactive):
Present EXACTLY ONE question at a time.
For multiple‑choice questions:
**Recommended:** Option [X] - <reasoning>| Option | Description |
|---|---|
| A | |
| B | |
| C | (add D/E as needed up to 5) |
| Short | Provide a different short answer (<=5 words) (Include only if free-form alternative is appropriate) |
You can reply with the option letter (e.g., "A"), accept the recommendation by saying "yes" or "recommended", or provide your own short answer.For short‑answer style (no meaningful discrete options):
**Suggested:** <your proposed answer> - <brief reasoning>Format: Short answer (<=5 words). You can accept the suggestion by saying "yes" or "suggested", or provide your own answer.After the user answers:
Stop asking further questions when:
Never reveal future queued questions in advance.
If no valid questions exist at start, immediately report no critical ambiguities.
Integration after EACH accepted answer (incremental update approach):
## Clarifications section exists (create it just after the highest-level contextual/overview section per the spec template if missing).### Session YYYY-MM-DD subheading for today.- Q: <question> → A: <final answer>.(formerly referred to as "X") once.Validation (performed after EACH write plus final pass):
## Clarifications, ### Session YYYY-MM-DD.Write the updated spec back to FEATURE_SPEC.
Report completion (after questioning loop ends or early termination):
/smith-plan or run /smith-clarify again later post-plan.Behavior rules:
/smith-specify first (do not create a new spec here).Context for prioritization: $ARGUMENTS
npx claudepluginhub attckdigital/smithHunts ambiguous, under-specified points in a spec.md and resolves or defers each one so two engineers can't build different things from the same spec.
Clarifies ambiguous or incomplete functional specifications by asking up to 5 targeted questions and encoding answers back into the spec file. Run before design phase.
Adversarially interviews a feature spec to surface unresolved decisions (auth, error handling, persistence, etc.) before PM grooming. Outputs a decision-resolved spec.