-
Notifications
You must be signed in to change notification settings - Fork 4.2k
feat: integrate Kent Beck TDD methodology into spec-kit #1172
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Add two new slash commands to enhance development workflow efficiency: 1. /rec_remove_agents_mcp - Analyzes current project and installed agents/MCP servers - Provides actionable recommendations (KEEP/REMOVE/CONSIDER) - Estimates context window savings - Includes project-type specific heuristics 2. /compact_with_topic - Automatically analyzes recent conversation topics - Generates intelligent compact focus areas - Handles multiple conversation patterns (debugging, development, exploration) - Preserves essential context while reducing conversation overhead Both commands follow spec-kit conventions with: - YAML frontmatter structure - Phase-based execution flows - Comprehensive examples and error handling - Non-destructive default behavior Updated README.md with new "Productivity & Optimization Commands" section. 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
Add comprehensive Test-Driven Development (TDD) workflow inspired by Kent Beck's "Augmented Coding Beyond the Vibes" (https://tidyfirst.substack.com/p/augmented-coding-beyond-the-vibes). ## New Features ### 1. Kent Beck CLAUDE.md Template - Comprehensive TDD methodology (Red → Green → Refactor) - Tidy First principles (structural ≠ behavioral commits) - AI warning signs detection (loops, over-engineering, test cheating) - Auto-populated project-specific configuration - File: templates/kent-beck-claude-template.md ### 2. /speckit.init-tdd Command - Initializes TDD workflow in project - Auto-populates CLAUDE.md from constitution.md and plan.md - Extracts tech stack, architecture, performance requirements - Optional git hooks integration - File: templates/commands/init-tdd.md ### 3. /speckit.go Command - Implements Kent Beck's "go" workflow for one task - Strict TDD cycle: RED (test) → GREEN (code) → REFACTOR → COMMIT - Auto-detects AI warning signs during execution - Follows Tidy First commit discipline - File: templates/commands/go.md ## Integration Benefits - Fast specification (spec-kit) + disciplined implementation (Kent Beck TDD) - Prevents AI anti-patterns: repetition, over-engineering, test manipulation - Enforces test-first development - Clean commit history (structural vs behavioral separation) - Expected 80%+ test coverage ## Documentation - Updated README.md with new command section - Added KENT_BECK_TDD_INTEGRATION.md with comprehensive guide - Includes real-world example and success metrics - User testimonial from real project usage ## Design Decisions - Separate CLAUDE.md (HOW to build) from constitution.md (WHAT to build) - /speckit.go runs ONE task (developer control) vs /speckit.implement (all tasks) - Auto-detection of AI warning signs prevents bad habits - Language-agnostic template adapts to any tech stack ## Related Work Inspired by Kent Beck's blog post on augmented coding beyond vibes. Real-world tested on SAAB MDA Project with positive results. 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
Remove SAAB MDA Project references and replace with generic e-commerce examples: - Changed vessel/AIS examples to user/order examples - Replaced maritime domain examples with e-commerce scenarios - Updated project name references from SAAB to MyProject - Kept all technical concepts and methodology intact This makes the documentation universally applicable without revealing proprietary business information. 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
- Remove all Co-Authored-By references from commit examples - Relax git working directory check to spec files only - Clarify placeholder documentation format with HTML comments - Improve feature detection priority order - Clarify success metrics table header as expected values Addresses review comments from PR github#1171
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR integrates Kent Beck's Test-Driven Development methodology into spec-kit, enabling disciplined AI-assisted development with automated detection of AI warning signs (code repetition, over-engineering, and test manipulation). The integration adds a CLAUDE.md template and two new TDD commands to complement spec-kit's existing specification-driven workflow.
Key Changes:
- Added Kent Beck TDD workflow with Red-Green-Refactor cycle and Tidy First commit discipline
- Introduced
/speckit.init-tddto create project-specific CLAUDE.md with auto-populated tech stack and conventions - Introduced
/speckit.goto implement individual tasks following strict TDD principles with AI warning detection
Additional Changes:
- Added two productivity commands (
/rec_remove_agents_mcpand/compact_with_topic) for context management - Comprehensive documentation with examples and best practices
Reviewed Changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| templates/kent-beck-claude-template.md | Comprehensive TDD template with Kent Beck principles, AI warning signs detection, and project-specific configuration sections |
| templates/commands/init-tdd.md | Command to initialize TDD workflow by creating CLAUDE.md with auto-populated project configuration |
| templates/commands/go.md | Command implementing TDD cycle (Red-Green-Refactor) for single task execution with warning sign detection |
| templates/commands/rec_remove_agents_mcp.md | New command for analyzing and recommending agent/MCP server management |
| templates/commands/compact_with_topic.md | New command for intelligent conversation compaction with topic analysis |
| README.md | Added two new command sections: Productivity & Optimization Commands and Kent Beck TDD Integration Commands |
| KENT_BECK_TDD_INTEGRATION.md | Complete integration guide with examples, benefits, and real-world use cases |
| NEW_COMMANDS_SUMMARY.md | Summary document describing productivity commands (appears to be for a different feature set) |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
README.md
Outdated
| #### Productivity & Optimization Commands | ||
|
|
||
| Commands for managing development environment and conversation efficiency: | ||
|
|
||
| | Command | Description | | ||
| |-----------------------------|-----------------------------------------------------------------------| | ||
| | `/rec_remove_agents_mcp` | Analyze current project and recommend which agents/MCP servers to keep or remove for optimal context management | | ||
| | `/compact_with_topic` | Automatically analyze recent conversation topics and run `/compact` with intelligent focus | | ||
|
|
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The "Productivity & Optimization Commands" section is added but these commands (/rec_remove_agents_mcp and /compact_with_topic) are not mentioned in the PR description which focuses on Kent Beck TDD integration. If these commands are part of this PR, they should be mentioned in the PR description. If they're not, they should be in a separate PR.
| #### Productivity & Optimization Commands | |
| Commands for managing development environment and conversation efficiency: | |
| | Command | Description | | |
| |-----------------------------|-----------------------------------------------------------------------| | |
| | `/rec_remove_agents_mcp` | Analyze current project and recommend which agents/MCP servers to keep or remove for optimal context management | | |
| | `/compact_with_topic` | Automatically analyze recent conversation topics and run `/compact` with intelligent focus | |
| ## 💬 User Testimonial | ||
|
|
||
| > "Kent Beck의 TDD 블로그를 읽고 spec-kit에 적용해봤는데, 정말 효과적이었습니다. AI가 반복 코드를 만들거나 테스트를 약화시키는 것을 자동으로 감지해주니까, 코드 품질이 확 올라갔어요. Spec-Kit의 빠른 문서화와 Kent Beck의 엄격한 TDD를 결합하니까 정말 최고의 조합이더라구요!" | ||
| > |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The testimonial is in Korean. While this may be intentional for a multilingual audience, it's inconsistent with the rest of the English documentation. Consider either providing an English translation alongside the Korean text, or replacing it with an English testimonial for consistency.
| > | |
| > | |
| > "After reading Kent Beck's TDD blog and applying it to spec-kit, I found it incredibly effective. It automatically detects when AI generates repetitive code or weakens tests, so my code quality improved dramatically. Combining Spec-Kit's rapid documentation with Kent Beck's strict TDD is truly the best combination!" | |
| > |
| 🤖 Generated with Claude Code" | ||
| ``` |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The commit message includes "🤖 Generated with Claude Code" but this convention is not explained or documented in the command template itself. If this is a standard convention for spec-kit, it should be documented. If not, it should either be removed or explained as optional.
| [AUTO-POPULATED FROM plan.md] | ||
|
|
||
| **Languages**: [e.g., Python 3.11+, TypeScript 5.0+] | ||
| **Frameworks**: [e.g., FastAPI, React] | ||
| **Databases**: [e.g., PostgreSQL, Redis] | ||
| **Testing**: [e.g., pytest, Jest] |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The placeholder text "[AUTO-POPULATED FROM plan.md]" is left in the template without clear instructions on what should be extracted. Consider adding a more detailed comment showing the expected format or an example of what the auto-population should produce (similar to the detailed examples shown for other placeholders in init-tdd.md lines 97-123).
|
|
||
| ```bash | ||
| # 1. Install spec-kit | ||
| uv tool install specify-cli --from git+https://github.com/github/spec-kit.git |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The installation command references an incorrect repository URL. The command uv tool install specify-cli --from git+https://github.com/github/spec-kit.git attempts to install from github/spec-kit, but based on the PR context, the actual repository path should be verified. This could lead to installation failures for users following the quick start guide.
| uv tool install specify-cli --from git+https://github.com/github/spec-kit.git | |
| uv tool install specify-cli --from git+https://github.com/spec-kit/spec-kit.git |
| - ✅ Need AI warning sign detection | ||
| - ✅ Team wants Kent Beck's methodology | ||
|
|
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code formatting comment specifies "Black (line length 100)" but this appears to be a placeholder value. The standard Black line length is 88 characters, not 100. If 100 is intentional for this template, it should be clearly marked as customizable. Otherwise, it should use the Black default of 88.
|
|
||
| This file follows **Kent Beck's Test-Driven Development (TDD)** methodology. When implementing features: | ||
|
|
||
| 1. **Read the plan**: Check `plan.md` for architecture and design decisions |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The instruction says "Check plan.md" but the file path shown in the document hierarchy (line 371) is specs/[feature]/plan.md. For clarity, consider using the full path here: "Check specs/[feature]/plan.md" to match the complete file structure shown later in the document.
| 1. **Read the plan**: Check `plan.md` for architecture and design decisions | |
| 1. **Read the plan**: Check `specs/[feature]/plan.md` for architecture and design decisions |
NEW_COMMANDS_SUMMARY.md
Outdated
| # New Slash Commands for Spec-Kit | ||
|
|
||
| ## Overview |
Copilot
AI
Nov 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The document title "New Slash Commands for Spec-Kit" describes commands that don't align with the PR description. The PR is about Kent Beck TDD integration but this file appears to be about productivity commands (/rec_remove_agents_mcp and /compact_with_topic). This file seems to be from a different PR or feature set and may have been included by mistake, as the PR description focuses on Kent Beck TDD integration.
- Remove productivity commands (belong in separate PR github#1170) - Translate Korean testimonial to English - Fix Black line length to default (88) - Use full file paths in instructions (specs/[feature]/...) - Remove NEW_COMMANDS_SUMMARY.md (wrong PR) Addresses review comments from PR github#1172
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Per contribution guidelines, this was not yet discussed. Let's hold off on major additions/rewrites until folks got a chance to discuss and approve this approach for Spec Kit. |
Kent Beck TDD Integration for Spec-Kit
Integrates Kent Beck's Test-Driven Development methodology into spec-kit workflow.
What's Added
1. CLAUDE.md Template
templates/kent-beck-claude-template.md2. /speckit.init-tdd Command
templates/commands/init-tdd.md3. /speckit.go Command
templates/commands/go.md4. Documentation
KENT_BECK_TDD_INTEGRATION.mdChanges to README.md
Added new section for Kent Beck TDD integration commands with link to original blog post.
Benefits
Testing