Two-phase codebase analysis. Phase 1: discover features from code. Phase 2: trace workflows.
View on GitHubNothflare/feature-tree
feature-tree
January 20, 2026
Select agents to install to:
npx add-skill https://github.com/Nothflare/feature-tree/blob/main/feature-tree/skills/bootstrap/SKILL.md -a claude-code --skill bootstrapInstallation paths:
.claude/skills/bootstrap/# Bootstrap Feature Tree
Two-phase process to populate Feature Tree from an existing codebase:
- **Phase 1**: Feature Discovery (bottom-up, code → features)
- **Phase 2**: Workflow Identification (top-down, features → workflows)
Both phases are optional. Run Phase 1 alone, skip to Phase 2 with manual guidance, or run both.
---
## Phase 1: Feature Discovery
### Step 1.1: Module Detection
Scan the codebase structure and propose modules:
1. Read top-level directories (especially `src/`, `lib/`, `app/`)
2. Check config files (package.json, pyproject.toml) for hints
3. Present proposed modules to user:
```
I found these potential modules:
| Module | Path | Notes |
|--------|------|-------|
| auth | src/auth | login, session, oauth files |
| payments | src/payments | stripe, checkout |
| users | src/users | profile, settings |
| utils | src/utils | shared helpers → likely INFRA |
Add, remove, or rename any? [Enter to confirm]
```
Log module detection: `bootstrap_log("Proposed modules: auth, payments, users, utils", "MODULE_DETECT")`
### Step 1.2: Parallel Subagent Dispatch
For each confirmed module, spawn an Explore subagent with Feature Tree context:
```python
Task(
subagent_type="Explore",
prompt=f"""
## Context: Feature Tree Bootstrap
Feature Tree tracks atomic features and infrastructure for AI-assisted development.
**FEATURE** = Atomic, user-facing capability
- Something you'd say "implement the X feature"
- Examples: AUTH.login, PAYMENT.checkout, USER.profile_update
- Must be completable in one Claude session
**INFRASTRUCTURE** = Shared utilities, not user-facing alone
- Use INFRA.* prefix: INFRA.rate_limiter, INFRA.logger, INFRA.validation
- Gets linked to features via `uses` field
**CONFIDENCE:**
- HIGH: Obvious from names/structure (file literally named login.ts with handleLogin export)
- MEDIUM: Reasonable inference from patterns
- LOW: Ambiguous, might be wrong
## Your Task
Analyze module: {module_name}
Path: {module_path}
1. Identi