| name | discovery-phase |
| description | Execute discovery at the appropriate depth level. Produces DISCOVERY.md that informs PLAN.md creation. Supports quick verify, standard, and deep dive depths. |
Execute discovery at the appropriate depth level.
Produces DISCOVERY.md (for Level 2-3) that informs PLAN.md creation.
Called from plan-phase.md's mandatory_discovery step with a depth parameter.
NOTE: For comprehensive ecosystem research ("how do experts build this"), use /research-phase.md instead, which produces RESEARCH.md.
<depth_levels>
This workflow supports three depth levels:
| Level | Name | Time | Output | When |
|---|
| 1 | Quick Verify | 2-5 min | No file, proceed with verified knowledge | Single library, confirming current syntax |
| 2 | Standard | 15-30 min | DISCOVERY.md | Choosing between options, new integration |
| 3 | Deep Dive | 1+ hour | Detailed DISCOVERY.md with validation gates | Architectural decisions, novel problems |
Depth is determined by plan-phase.md before routing here.
</depth_levels>
<source_hierarchy>
MANDATORY: Context7 BEFORE Web Search
Copilot's training data is 6-18 months stale. Always verify.
Priority Order:
- Context7 MCP FIRST - Use
use_mcp_tool(context7, ...) for current library/framework docs
- Copilot
fetch (built-in) - Use for web search and fetching URLs (no MCP needed)
- Exa / Brave Search MCP - Optional, for deep research when insufficient:
Check the depth parameter passed from plan-phase.md:
- `depth=verify` → Level 1 (Quick Verification)
- `depth=standard` → Level 2 (Standard Discovery)
- `depth=deep` → Level 3 (Deep Dive)
**Level 1: Quick Verification (2-5 minutes)**
**Level 2: Standard Discovery (15-30 minutes)**
**Level 3: Deep Dive (1+ hour)**
**For Level 2-3:** Define what we need to learn.
Use ~/.gsd/templates/discovery.md.
Run the discovery:
- Use web search for current info
- Use Context7 MCP for library docs
- Prefer current year sources
- Structure findings per template
Write `.gsd/phases/XX-name/DISCOVERY.md`:
- Summary with recommendation
- Key findings with sources
- Code examples if applicable
- Metadata (confidence, dependencies, open questions, assumptions)
After creating DISCOVERY.md, check confidence level.
If DISCOVERY.md has open_questions:
```
Discovery complete: .gsd/phases/XX-name/DISCOVERY.md
Recommendation: [one-liner]
Confidence: [level]