Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions .github/workflows/community-smoke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ jobs:

test -f .specify/extensions/arch/extension.yml
test -f .specify/extensions/preview/extension.yml
test -f .specify/extensions/discovery/extension.yml
test -f .specify/extensions/repository-governance/extension.yml
test -f .specify/presets/workflow-preset/preset.yml
/tmp/specify-community-smoke-venv/bin/python - <<'PY'
Expand Down Expand Up @@ -101,6 +102,7 @@ jobs:
speckit-preview-high-html; do
test -f ".claude/skills/$preview_skill/SKILL.md"
done
test -f .claude/skills/speckit-discovery-feasibility/SKILL.md
test -f .claude/skills/speckit-repository-governance-refresh/SKILL.md
test -f .claude/skills/speckit-specify/SKILL.md
test -f .claude/skills/speckit-clarify/SKILL.md
Expand All @@ -118,7 +120,7 @@ jobs:
grep -q "Vertical Planner Agent" .claude/skills/speckit-implement/SKILL.md
grep -q "Worker Agent" .claude/skills/speckit-implement/SKILL.md

for extension_id in arch preview repository-governance; do
for extension_id in arch discovery preview repository-governance; do
/tmp/specify-community-smoke-venv/bin/specify extension remove "$extension_id" --force
test ! -d ".specify/extensions/$extension_id"
case "$extension_id" in
Expand All @@ -137,13 +139,16 @@ jobs:
test ! -d ".claude/skills/$preview_skill"
done
;;
discovery)
test "$(find .claude/skills -maxdepth 1 -type d -name 'speckit-discovery-*' | wc -l)" -eq 0
;;
repository-governance)
test ! -d .claude/skills/speckit-repository-governance-refresh
;;
esac
done

for extension_id in arch preview repository-governance; do
for extension_id in arch discovery preview repository-governance; do
/tmp/specify-community-smoke-venv/bin/specify extension add "$GITHUB_WORKSPACE/extensions/$extension_id" --dev
case "$extension_id" in
arch)
Expand All @@ -163,13 +168,22 @@ jobs:
grep -q "evidence-backed" ".claude/skills/$preview_skill/SKILL.md"
done
;;
discovery)
test -f .claude/skills/speckit-discovery-feasibility/SKILL.md
grep -q "evidence-backed feasibility study" .claude/skills/speckit-discovery-feasibility/SKILL.md
;;
repository-governance)
test -f .claude/skills/speckit-repository-governance-refresh/SKILL.md
grep -q "Repository Governance Generate/Update" .claude/skills/speckit-repository-governance-refresh/SKILL.md
;;
esac
done

/tmp/specify-community-smoke-venv/bin/specify extension remove discovery --force
/tmp/specify-community-smoke-venv/bin/specify extension add discovery
test -f .claude/skills/speckit-discovery-feasibility/SKILL.md
test -f .claude/skills/speckit-discovery-decision/SKILL.md

/tmp/specify-community-smoke-venv/bin/specify preset resolve plan-template | tee resolve-plan-template.txt
grep -q "workflow-preset" resolve-plan-template.txt
grep -q "Composition chain" resolve-plan-template.txt
24 changes: 24 additions & 0 deletions extensions/catalog.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,30 @@
"ux"
]
},
"discovery": {
"name": "Spec Kit Discovery Extension",
"id": "discovery",
"version": "0.2.0",
"description": "Run technical discovery commands for feasibility, technology selection, scenario-specific technical decisions, legacy codebase assessment, implementation understanding, and proof-of-concept validation",
"author": "bigsmartben",
"repository": "https://github.com/bigsmartben/spec-kit-discovery",
"license": "MIT",
"bundled": true,
"requires": {
"speckit_version": ">=0.1.0"
},
"provides": {
"commands": 6
},
"tags": [
"discovery",
"feasibility",
"selection",
"codebase",
"poc",
"decision"
]
},
"repository-governance": {
"name": "Repository Governance",
"id": "repository-governance",
Expand Down
12 changes: 12 additions & 0 deletions extensions/discovery/.extensionignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.git/
.gitignore
.extensionignore

# Local editor state
.idea/
.vscode/

# Temporary files
*.log
tmp/
temp/
16 changes: 16 additions & 0 deletions extensions/discovery/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
.DS_Store
Thumbs.db

# Local editor state
.idea/
.vscode/
*.swp
*.swo

# Spec Kit local-only config generated by installed extensions
.specify/extensions/**/*-config.local.yml

# Logs and temporary files
*.log
tmp/
temp/
32 changes: 32 additions & 0 deletions extensions/discovery/CATALOG-SUBMISSION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Spec Kit Extension Submission

Extension ID: discovery
Name: Spec Kit Discovery Extension
Version: 0.2.0
Description: Run technical discovery commands for feasibility, technology selection, scenario-specific technical decisions, legacy codebase assessment, implementation understanding, and proof-of-concept validation.
Author: bigsmartben
Repository URL: https://github.com/bigsmartben/spec-kit-discovery
Download URL: https://github.com/bigsmartben/spec-kit-discovery/archive/refs/tags/v0.2.0.zip
Documentation URL: https://github.com/bigsmartben/spec-kit-discovery#readme
License: MIT
Required Spec Kit version: >=0.1.0
Commands count: 6
Hooks count: 0
Tags: discovery, feasibility, selection, codebase, poc, decision

## Key Features

- Adds `speckit.discovery.feasibility`, `speckit.discovery.techselect`, and `speckit.discovery.codebase`.
- Adds `speckit.discovery.codebase-api-imp` for source-backed implementation overviews.
- Adds `speckit.discovery.poc` for bounded proof-of-concept planning and validation.
- Adds `speckit.discovery.decision` with `type: api|performance|migration|ux|compatibility` routing.
- Keeps outputs focused on evidence, assumptions, unknowns, planning decisions, and validation scope before formal implementation planning.

## Testing Performed

- Validated the bundled manifest with `ExtensionManifest`.
- Ran `uv run pytest tests/integrations/test_cli.py -k "community_extensions_and_workflow_preset_auto_installed or no_git_keeps_community_defaults"`.
- Ran `uv run pytest tests/test_arch_templates.py tests/test_presets.py -k "community_smoke_checks_wheel_assets_and_extension_dev_reinstall or init_next_steps_do_not_list_arch_as_core_workflow"`.
- Built the CLI wheel with `uv build --wheel` and verified `specify_cli/core_pack/extensions/discovery/extension.yml` and representative command/template files were included.
- Smoke-tested `specify init`, `specify extension remove discovery --force`, and `specify extension add discovery` in a temporary project.
- Verified release `v0.2.0` installs with `Commands: 6`.
16 changes: 16 additions & 0 deletions extensions/discovery/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Changelog

## [0.2.0] - 2026-06-23

### Changed

- Consolidated API integration, performance, data migration, UX workflow, and compatibility discovery into `speckit.discovery.decision` with type-specific routing.
- Updated documentation to describe the six-command public interface.
- Replaced references to the old API integration command with `/speckit.discovery.decision type: api`.

## [0.1.0] - 2026-06-23

### Added

- Initial `discovery` extension manifest and usage documentation.
- Added discovery commands for feasibility, technology selection, legacy codebase assessment, implementation overview, proof-of-concept validation, and scenario-specific technical decisions.
21 changes: 21 additions & 0 deletions extensions/discovery/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 bigsmartben

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
175 changes: 175 additions & 0 deletions extensions/discovery/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,175 @@
# Spec Kit Discovery Extension

`spec-kit-discovery` provides a `discovery` extension for Spec Kit. It adds scope-bounded commands for the technical discovery phase:

```text
/speckit.discovery.feasibility [goal or idea] [constraints] [success criteria]
/speckit.discovery.techselect [decision to make] [candidate options] [criteria or constraints]
/speckit.discovery.decision type: api|performance|migration|ux|compatibility [scenario] [constraints or risks]
/speckit.discovery.codebase [target area or fuzzy scope] [planned change or integration] [known concerns]
/speckit.discovery.codebase-api-imp [API route, SDK method, topic, command, or capability] [known concern] [source scope]
/speckit.discovery.poc [user stories] [use cases] [core design idea]
```

The extension helps teams complete technical discovery before formal planning. `feasibility`, `techselect`, and `codebase` produce decision documents; `decision` evaluates scenario-specific API, performance, migration, UX, and compatibility risks; `codebase-api-imp` explains existing interface implementations from source facts; `poc` creates a bounded-scope experiment that supports feasibility, selection, scenario decision, or legacy-codebase risk decisions.

Internally, the commands are organized into four capability types:

- `feasibility`: support a go/no-go continuation decision.
- `techselect`: compare general technology choices.
- `decision`: evaluate scenario-specific API, performance, migration, UX, and compatibility decisions with type-specific risks.
- `codebase`, `codebase-api-imp` (API implementation overview), and `poc`: locate relevant source scope, gather source-backed evidence, record evidence levels and unknowns, explain implemented interface behavior, or run executable validation.

## Installation

From a Spec Kit project:

```bash
specify extension add --dev /path/to/spec-kit-discovery
```

From this repository during local development:

```bash
specify extension add --dev . --force
```

After installation, restart or refresh your AI coding agent if the new command does not appear immediately.

## Commands

### `speckit.discovery.feasibility`

Produces an evidence-backed feasibility study.

Typical output:

- `feasibility.md`
- decision: `feasible`, `feasible-with-risks`, `not-feasible`, or `inconclusive`

### `speckit.discovery.techselect`

Builds a technology selection matrix for candidate tools, libraries, platforms, or architectures.

Typical output:

- `tech-selection-matrix.md`
- recommendation, shortlist, or evidence gap

### `speckit.discovery.decision`

Evaluates a scenario-specific technical decision before formal planning. Use `type: api`, `type: performance`, `type: migration`, `type: ux`, or `type: compatibility` to select the decision frame and output template.

Typical output:

- `api-integration-discovery.md`
- `performance-discovery.md`
- `data-migration-discovery.md`
- `ux-discovery.md`
- `compatibility-discovery.md`
- type-specific `Planning Decision`

### `speckit.discovery.codebase`

Assesses legacy codebase risks, reusable assets, constraints, and integration hazards. When the target area is fuzzy, it first narrows likely source areas before using files, symbols, tests, configuration, and observed behavior as evidence for planning.

Typical output:

- `legacy-codebase-risk-assessment.md`
- scoped source areas or inspected paths
- source facts with file references
- evidence level per finding
- unknowns and unresolved questions
- risks rated as `low`, `medium`, `high`, or `unknown`

### `speckit.discovery.codebase-api-imp`

Explains how an already implemented API or interface works from repository facts. Use it for an HTTP/RPC route, SDK method, message topic, scheduled job, CLI command, or internal capability when engineers need implementation understanding or defect-localization guidance.

Typical output:

- `codebase-api-imp.md`
- interface match and source-backed entrance evidence
- service/system-level and module/component-level Mermaid sequence diagrams when evidence supports them
- repository-fact-backed business implementation flowcharts for key branches, dependencies, exceptions, and return paths
- evidence levels: `Proven`, `Framework inferred`, `Runtime dependent`, or `Unknown`

### `speckit.discovery.poc`

Creates a bounded-scope PoC plan and, when static evidence is insufficient and execution preconditions are met, a minimum runnable validation plus evidence report and conclusion.

Minimum input:

- User stories
- Use cases
- Core design idea

Example:

```text
/speckit.discovery.poc US: Readers can search notes by title and body. UC: Search while typing and open a result. Core design idea: Use SQLite FTS5 with a small local index.
```

The command produces:

- `poc-plan.md`
- `poc-result.md`
- `discovery/<short-name>/poc/` minimum validation code or scripts when executable evidence is required
- evidence logs or outputs
- result: `passed`, `failed`, or `inconclusive`

## Scenario-Specific Technical Decisions

Use `/speckit.discovery.decision` when the unknown is already tied to a common technical decision situation. The command creates a single-decision discovery document with a type-specific `Planning Decision`, and sets `Evaluation Mode` to either `comparison` or `single-approach-readiness`.

| Decision type | Use for | Typical output |
|---|---|---|
| `api` | Third-party API, SDK, webhook, service, SaaS platform, or partner integration decisions. | `api-integration-discovery.md` |
| `performance` | Latency, throughput, scalability, resource, capacity, or cost decisions. | `performance-discovery.md` |
| `migration` | Data model, storage, schema, backfill, import/export, or migration decisions. | `data-migration-discovery.md` |
| `ux` | Complex interaction, stateful workflow, accessibility, responsive behavior, or frontend/backend handoff decisions. | `ux-discovery.md` |
| `compatibility` | Browser, OS, device, runtime, framework, API version, or deployment compatibility decisions. | `compatibility-discovery.md` |

## Repository Structure

```text
.
├── extension.yml
├── commands/
│ ├── codebase-api-imp.md
│ ├── codebase.md
│ ├── decision.md
│ ├── feasibility.md
│ ├── poc.md
│ └── techselect.md
├── templates/
│ ├── api-integration-discovery.md
│ ├── codebase-api-imp.md
│ ├── compatibility-discovery.md
│ ├── data-migration-discovery.md
│ ├── feasibility.md
│ ├── legacy-codebase-risk-assessment.md
│ ├── performance-discovery.md
│ ├── poc-plan.md
│ ├── poc-result.md
│ ├── tech-selection-matrix.md
│ └── ux-discovery.md
├── docs/
│ └── usage.md
├── CHANGELOG.md
├── LICENSE
└── README.md
```

## Development

Validate the extension from a Spec Kit project with:

```bash
specify extension add --dev /path/to/spec-kit-discovery --force
specify extension info discovery
```

## License

MIT
Loading