Skip to content

nikeyes/stepwise-dev

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

58 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Claude Code Stepwise Dev Plugin

Plugin Available License Tests

A development workflow for Claude Code inspired by Ashley Ha's workflow, adapted to work 100% locally with thoughts.

πŸ“– Read more: Tu CLAUDE.md no funciona sin Context Engineering (Spanish article about Stepwise-dev)

🎯 What This Is

Solves the context management problem: LLMs lose attention after 60% context usage.

Implements Research -> Plan -> Implement -> Validate with frequent /clear and persistent thoughts/ storage.

  • 6 Slash Commands for structured development
  • 5 Specialized Agents for parallel research
  • 3 Bash Scripts for local thoughts/ management
  • Built-in version tracking for team synchronization

Philosophy

  • Keep context < 60% (attention threshold)
  • Split work into phases.
  • Clear between phases, save to thoughts/
  • Never lose research or decisions

πŸ“¦ What's Included

Enhanced Planning with Vertical Slicing

The create_plan command guides you through creating implementation plans that emphasize:

  • Small safe steps using the Hamburger Method for vertical slicing
  • Progressive delivery patterns (dummy β†’ dynamic, backend-only β†’ full stack, etc.)
  • Learning vs Earning phases to separate research from value delivery
  • Complexity assessment to guide implementation decisions
  • Reversibility and rollback strategies for each phase

Plans are created interactively, with vertical slicing analysis before committing to detailed phases.

Slash Commands

Command Description
/stepwise-dev:research_codebase Research and document codebase comprehensively
/stepwise-dev:create_plan Create detailed implementation plans iteratively
/stepwise-dev:iterate_plan Update existing implementation plans
/stepwise-dev:implement_plan Execute plans phase by phase with validation
/stepwise-dev:validate_plan Validate implementation against plan
/stepwise-dev:commit Create git commits (no Claude attribution)

Specialized Agents

Agent Purpose
codebase-locator Find WHERE code lives in the codebase
codebase-analyzer Understand HOW code works
codebase-pattern-finder Find similar patterns to model after
thoughts-locator Discover documents in thoughts/
thoughts-analyzer Extract insights from thoughts docs

Thoughts Scripts (Included in Plugin)

Script Purpose
thoughts-init Initialize thoughts/ structure in a project
thoughts-sync Sync hardlinks in searchable/ directory
thoughts-metadata Generate git metadata for documents

Note: These scripts are executed automatically by the thoughts-management Skill. You don't need to install them separately or configure PATH.

πŸš€ Installation

# Add marketplace from GitHub
/plugin marketplace add nikeyes/stepwise-dev

# Install plugin
/plugin install stepwise-dev@stepwise-dev

Restart Claude Code after installation.

That's it! The plugin includes:

  • 6 slash commands
  • 5 specialized agents
  • 1 thoughts-management Skill (with 3 bash scripts)

All components are ready to use immediately after installation.

πŸ§ͺ Try It Out

Don't have a project to test with? Use stepwise-todo-api-test β€” a sample repository with small and large tasks designed for testing this plugin in an isolated environment.

πŸ“ Directory Structure

After running thoughts-init in a project:

<your-project>/
β”œβ”€β”€ thoughts/
β”‚   β”œβ”€β”€ nikey_es/          # Your personal notes (you write)
β”‚   β”‚   β”œβ”€β”€ tickets/       # Ticket documentation
β”‚   β”‚   └── notes/         # Personal notes
β”‚   β”œβ”€β”€ shared/            # Team-shared documents (Claude writes)
β”‚   β”‚   β”œβ”€β”€ research/      # Research documents
β”‚   β”‚   β”œβ”€β”€ plans/         # Implementation plans
β”‚   β”‚   └── prs/           # PR descriptions
β”‚   └── searchable/        # Hardlinks for grep (auto-generated)
β”‚       β”œβ”€β”€ nikey_es/      # -> hardlinks to nikey_es/
β”‚       └── shared/        # -> hardlinks to shared/
β”œβ”€β”€ .gitignore            # (add thoughts/searchable/ to this)
└── ...

Key distinction:

  • nikey_es/: Personal tickets/notes you create manually
  • shared/: Formal docs Claude generates from commands
  • Example: /create_plan thoughts/nikey_es/tickets/eng_1234.md reads your ticket β†’ writes shared/plans/2025-11-09-ENG-1234-*.md

Why Hardlinks?

  • Fast searching: Grep one directory instead of many
  • No duplication: Same file, same inode, no extra disk space
  • Auto-sync: Changes in source are immediately visible
  • Efficient: Better than symlinks for grep operations

Thoughts Directory

This directory contains research documents, implementation plans, and notes for this project.

Structure

  • nikey_es/ - Personal notes and tickets
    • tickets/ - Ticket documentation and tracking
    • notes/ - Personal notes and observations
  • shared/ - Team-shared documents
    • research/ - Research documents from /stepwise-dev:research_codebase
    • plans/ - Implementation plans from /stepwise-dev:create_plan
    • prs/ - PR descriptions and documentation
  • searchable/ - Hardlinks for efficient grep searching (auto-generated)

Usage

Use Claude Code slash commands:

  • /stepwise-dev:research_codebase [topic] - Research and document codebase
  • /stepwise-dev:create_plan [description] - Create implementation plan
  • /stepwise-dev:implement_plan [plan-file] - Execute a plan
  • /stepwise-dev:validate_plan [plan-file] - Validate implementation

Run thoughts-sync after adding/modifying files to update searchable/ hardlinks.

πŸ”„ The Four-Phase Workflow

Phase 1: Research

Goal: Understand what exists before changing anything.

# In Claude Code
/stepwise-dev:research_codebase How does authentication work in this app?

This will:

  1. Spawn parallel agents to search the codebase
  2. Search thoughts/ for historical context
  3. Generate a comprehensive research document
  4. Save to thoughts/shared/research/YYYY-MM-DD-topic.md
  5. Run thoughts-sync to update searchable/

Output: Research document with code references, architecture insights, and file:line numbers.

Phase 2: Plan

Goal: Create a detailed, iterative implementation plan.

# In Claude Code
/stepwise-dev:create_plan Add rate limiting to the API
# Or reference a research doc:
/stepwise-dev:create_plan @thoughts/shared/research/2025-11-09-auth-system.md

This will:

  1. Ask clarifying questions
  2. Research existing patterns in the codebase
  3. Iterate with you 5+ times on the plan
  4. Create phases with specific changes
  5. Define automated AND manual success criteria
  6. Save to thoughts/shared/plans/YYYY-MM-DD-topic.md

Output: Detailed plan with phases, file paths, code snippets, and verification steps.

Phase 3: Implement

Goal: Execute one phase at a time with confidence.

# In Claude Code
/stepwise-dev:implement_plan @thoughts/shared/plans/2025-11-09-rate-limiting.md

This will:

  1. Read the complete plan
  2. Implement Phase 1
  3. Run automated verification (tests, linting)
  4. Pause for manual verification
  5. Wait for your confirmation
  6. Proceed to Phase 2 (or stop)

Key Rule: One phase at a time. Validate before proceeding.

Phase 4: Validate

Goal: Systematically verify the entire implementation.

# In Claude Code
/stepwise-dev:validate_plan @thoughts/shared/plans/2025-11-09-rate-limiting.md

This will:

  1. Check all phases are complete
  2. Run all automated verification
  3. Review code against plan
  4. Identify deviations or issues
  5. Generate validation report

Output: Report showing what passed, what needs fixing, and manual test checklist.

πŸ’‘ Usage Examples

Example 1: Feature Development

# 1. Research
/stepwise-dev:research_codebase Where is user registration handled?
# β†’ Saves to thoughts/shared/research/2025-11-09-user-registration.md
# β†’ /context shows 45%
# β†’ /clear

# 2. Plan
/stepwise-dev:create_plan Add OAuth login support
# β†’ Iterates 5 times
# β†’ Saves to thoughts/shared/plans/2025-11-09-oauth-login.md
# β†’ /context shows 58%
# β†’ /clear

# 3. Implement (Phase 1 only)
/stepwise-dev:implement_plan @thoughts/shared/plans/2025-11-09-oauth-login.md
# β†’ Completes Phase 1
# β†’ Runs tests
# β†’ Pauses for manual testing
# β†’ You verify it works
# β†’ "Continue to Phase 2"
# β†’ /context shows 62%
# β†’ /clear

# 4. Validate
/stepwise-dev:validate_plan @thoughts/shared/plans/2025-11-09-oauth-login.md
# β†’ Comprehensive verification
# β†’ /context shows 41%

# 5. Commit
/stepwise-dev:commit
# β†’ Creates atomic commits

Example 2: Bug Investigation

# Research the bug
/stepwise-dev:research_codebase Why are webhooks timing out after 30 seconds?

# Create a fix plan
/stepwise-dev:create_plan Fix webhook timeout issue based on @thoughts/shared/research/...md

# Implement the fix
/stepwise-dev:implement_plan @thoughts/shared/plans/...md

# Commit
/stepwise-dev:commit

Example 3: Iterating on a Plan

# You've created a plan but need to adjust it
/stepwise-dev:iterate_plan @thoughts/shared/plans/2025-11-09-feature.md

# Claude asks: What changes would you like to make?
# You: "Add error handling phase before deployment"

# Claude updates the plan in place

πŸ› οΈ Thoughts Scripts

thoughts-init

Initialize thoughts/ in current project:

cd ~/projects/my-app
thoughts-init

Creates structure, README, .gitignore, and runs initial sync.

thoughts-sync

Sync hardlinks in searchable/:

thoughts-sync

Run this:

  • After adding new .md files
  • After modifying file structure
  • If searchable/ seems out of sync

The scripts automatically run this after /research_codebase and /create_plan.

thoughts-metadata

Generate metadata for the current repo:

thoughts-metadata

Returns:

Current Date/Time (TZ): 2025-11-09 15:30:00 PST
ISO DateTime: 2025-11-09T23:30:00+0000
Date Short: 2025-11-09
Current Git Commit Hash: abc123...
Current Branch Name: main
Repository Name: my-app
Git User: nikey_es

Used internally by commands to populate frontmatter.

🏷️ Version Management

Checking Plugin Version

/plugin
# Check on Installed tab

Updating

/plugin -> Marketplaces tab -> stepwise-dev -> Update marketplace
/plugin -> Installed -> stepwise-dev -> Update now

Note: Plugin updates include commands, agents, and scripts automatically. No separate script installation needed.

πŸ“ Context Management

Golden Rule: Never exceed 60% context capacity.

Check context frequently:

/context

Clear between phases:

/clear

πŸ”§ Customization

Change Username: Set export THOUGHTS_USER=your_name or edit skills/thoughts-management/scripts/thoughts-init:8

Add Commands: Create .md files in ~/.claude/commands/ with frontmatter. Claude auto-detects on restart.

πŸ§ͺ Testing

make test          # Run all automated tests (functional + structure)
make test-verbose  # Run tests with debug output
make check         # Run shellcheck on all bash scripts
make ci            # Run full CI validation (test + check + plugin)

Tests validate bash scripts (thoughts-init, thoughts-sync, thoughts-metadata) and plugin structure. No dependencies needed, runs in isolated temp directories.

Test structure:

  • test/thoughts-structure-test.sh - Functional tests for thoughts/ operations
  • test/plugin-structure-test.sh - Plugin structure validation
  • test/test-helpers.sh - Test utilities and assertions
  • test/commands/ - Test command definitions

πŸ› Troubleshooting

Plugin Issues

Commands not showing after installation:

  • Restart Claude Code completely
  • Check plugin is enabled: /plugin list
  • Try reinstalling: /plugin uninstall stepwise-dev@stepwise-dev then /plugin install stepwise-dev@stepwise-dev

Plugin installation fails:

  • Verify marketplace added: /plugin marketplace list
  • Check network connection (for GitHub marketplaces)
  • Try local marketplace for testing: /plugin marketplace add ./test-marketplace

Workflow Issues

Hardlinks failing: Script auto-falls back to symlinks (slower but works)

No files synced: Run THOUGHTS_DEBUG=1 thoughts-sync to debug

Plugin version mismatch: Update plugin with /plugin update stepwise-dev@stepwise-dev. All components (commands, agents, scripts) update together.

πŸ“š Learn More

🀝 Contributing

This is extracted from HumanLayer and adapted for local use. If you have improvements:

  1. Test them in your workflow
  2. Document what changed and why
  3. Share with the community

πŸ“„ License

Apache License 2.0 - See LICENSE file for details.

πŸ”– Attribution

This project is derived from HumanLayer's Claude Code workflow under Apache License 2.0.

See NOTICE for detailed attribution.

Major enhancements and modifications:

  • Specialized agent system for efficient codebase exploration (5 custom agents)
  • Local-only thoughts/ management with Agent Skill (no cloud dependencies)
  • Automated testing infrastructure for bash scripts
  • Standalone plugin distribution system
  • Enhanced TDD-focused success criteria guidelines

πŸ™ Credits

  • Ashley Ha - For documenting and popularizing this workflow
  • HumanLayer Team (Dex Horthy et al.) - For creating the original commands and agents
  • Anthropic - For Claude Code

Happy Coding! πŸš€

Questions? Issues? Open an issue on GitHub.

About

Dev workflow for Claude Code

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published