diff --git a/.agents/skills/verification-loop/SKILL.md b/.agents/skills/verification-loop/SKILL.md deleted file mode 100644 index 1933545d57..0000000000 --- a/.agents/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,126 +0,0 @@ ---- -name: verification-loop -description: "A comprehensive verification system for Claude Code sessions." -origin: ECC ---- - -# Verification Loop Skill - -A comprehensive verification system for Claude Code sessions. - -## When to Use - -Invoke this skill: -- After completing a feature or significant code change -- Before creating a PR -- When you want to ensure quality gates pass -- After refactoring - -## Verification Phases - -### Phase 1: Build Verification -```bash -# Check if project builds -npm run build 2>&1 | tail -20 -# OR -pnpm build 2>&1 | tail -20 -``` - -If build fails, STOP and fix before continuing. - -### Phase 2: Type Check -```bash -# TypeScript projects -npx tsc --noEmit 2>&1 | head -30 - -# Python projects -pyright . 2>&1 | head -30 -``` - -Report all type errors. Fix critical ones before continuing. - -### Phase 3: Lint Check -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### Phase 4: Test Suite -```bash -# Run tests with coverage -npm run test -- --coverage 2>&1 | tail -50 - -# Check coverage threshold -# Target: 80% minimum -``` - -Report: -- Total tests: X -- Passed: X -- Failed: X -- Coverage: X% - -### Phase 5: Security Scan -```bash -# Check for secrets -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# Check for console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### Phase 6: Diff Review -```bash -# Show what changed -git diff --stat -git diff HEAD~1 --name-only -``` - -Review each changed file for: -- Unintended changes -- Missing error handling -- Potential edge cases - -## Output Format - -After running all phases, produce a verification report: - -``` -VERIFICATION REPORT -================== - -Build: [PASS/FAIL] -Types: [PASS/FAIL] (X errors) -Lint: [PASS/FAIL] (X warnings) -Tests: [PASS/FAIL] (X/Y passed, Z% coverage) -Security: [PASS/FAIL] (X issues) -Diff: [X files changed] - -Overall: [READY/NOT READY] for PR - -Issues to Fix: -1. ... -2. ... -``` - -## Continuous Mode - -For long sessions, run verification every 15 minutes or after major changes: - -```markdown -Set a mental checkpoint: -- After completing each function -- After finishing a component -- Before moving to next task - -Run: /verify -``` - -## Integration with Hooks - -This skill complements PostToolUse hooks but provides deeper verification. -Hooks catch issues immediately; this skill provides comprehensive review. diff --git a/.agents/skills/verification-loop/agents/openai.yaml b/.agents/skills/verification-loop/agents/openai.yaml deleted file mode 100644 index 644a9ad535..0000000000 --- a/.agents/skills/verification-loop/agents/openai.yaml +++ /dev/null @@ -1,7 +0,0 @@ -interface: - display_name: "Verification Loop" - short_description: "Build, test, lint, typecheck verification" - brand_color: "#10B981" - default_prompt: "Run verification: build, test, lint, typecheck, security" -policy: - allow_implicit_invocation: true diff --git a/.codex/AGENTS.md b/.codex/AGENTS.md index 5230166214..e62fa24042 100644 --- a/.codex/AGENTS.md +++ b/.codex/AGENTS.md @@ -33,7 +33,7 @@ Available skills: - eval-harness — Eval-driven development - strategic-compact — Context management - api-design — REST API design patterns -- verification-loop — Build, test, lint, typecheck, security +- tdd-workflow — TDD + build, test, lint, typecheck, security verification - deep-research — Multi-source research with firecrawl and exa MCPs - exa-search — Neural search via Exa MCP for web, code, and companies - claude-api — Anthropic Claude API patterns and SDKs diff --git a/.kiro/README.md b/.kiro/README.md index 6b105d5b29..0c549243c8 100644 --- a/.kiro/README.md +++ b/.kiro/README.md @@ -83,10 +83,9 @@ Skills are on-demand workflows invocable via the `/` menu in chat. | Skill | Description | |-------|-------------| -| `tdd-workflow` | Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests. Use when writing new features or fixing bugs. | +| `tdd-workflow` | Enforces TDD with 80%+ coverage (unit, integration, E2E) and includes a pre-PR verification gate (build, type check, lint, tests, security scan, diff review). Use when writing features, fixing bugs, or before creating PRs. | | `coding-standards` | Universal coding standards and best practices for TypeScript, JavaScript, React, and Node.js. Use when starting projects, reviewing code, or refactoring. | | `security-review` | Comprehensive security checklist and patterns. Use when adding authentication, handling user input, creating API endpoints, or working with secrets. | -| `verification-loop` | Comprehensive verification system that runs build, type check, lint, tests, security scan, and diff review. Use after completing features or before creating PRs. | | `api-design` | RESTful API design patterns and best practices. Use when designing new APIs or refactoring existing endpoints. | | `frontend-patterns` | React, Next.js, and frontend architecture patterns. Use when building UI components or optimizing frontend performance. | | `backend-patterns` | Node.js, Express, and backend architecture patterns. Use when building APIs, services, or backend infrastructure. | @@ -272,8 +271,6 @@ Shell scripts used by hooks to perform quality checks and formatting. │ │ └── SKILL.md # Coding standards skill │ ├── security-review/ │ │ └── SKILL.md # Security review skill -│ ├── verification-loop/ -│ │ └── SKILL.md # Verification loop skill │ ├── api-design/ │ │ └── SKILL.md # API design skill │ ├── frontend-patterns/ @@ -361,7 +358,7 @@ All files are yours to modify after installation. The installer never overwrites 3. **Review your code**: Switch to `code-reviewer` agent after writing code 4. **Check security**: Use `security-reviewer` agent for auth, API endpoints, or sensitive data handling 5. **Run quality gate**: Trigger the `quality-gate` hook before committing -6. **Verify comprehensively**: Use the `verification-loop` skill before creating PRs +6. **Verify comprehensively**: Use the `tdd-workflow` skill's verification gate before creating PRs The auto-loaded steering files (coding-style, security, testing) ensure consistent standards throughout your session. @@ -404,10 +401,10 @@ kiro-cli --agent code-reviewer # 2. Review specific files or directories > "Review the changes in src/api/users.ts" -# 3. Use the verification-loop skill for comprehensive checks -> /verification-loop +# 3. Use the tdd-workflow verification gate for comprehensive checks +> /verify -# 4. The verification loop will: +# 4. The verification gate will: # - Run build and type checks # - Run linter # - Run all tests @@ -561,8 +558,8 @@ kiro-cli --agent refactor-cleaner # - Suggest consolidation opportunities # - Refactor safely without breaking changes -# 3. Use verification-loop after refactoring -> /verification-loop +# 3. Use verification gate after refactoring +> /verify # Ensures all tests still pass after refactoring ``` diff --git a/.kiro/docs/longform-guide.md b/.kiro/docs/longform-guide.md index 2216a2cf51..1d80fb40ff 100644 --- a/.kiro/docs/longform-guide.md +++ b/.kiro/docs/longform-guide.md @@ -107,7 +107,7 @@ Hooks create a safety net and capture knowledge automatically. → Agent identifies coupling, cohesion issues → Agent suggests refactoring strategy -2. Invoke refactor-cleaner agent with verification-loop skill +2. Invoke refactor-cleaner agent with tdd-workflow skill → Agent refactors incrementally → Agent runs tests after each change → Agent validates behavior preservation diff --git a/.kiro/docs/security-guide.md b/.kiro/docs/security-guide.md index c034bdfb18..e0361def8d 100644 --- a/.kiro/docs/security-guide.md +++ b/.kiro/docs/security-guide.md @@ -117,7 +117,7 @@ Plan a user authentication feature with these security requirements: **Risk**: May accidentally remove security checks during refactoring. **Mitigation**: -- Use verification-loop skill to validate behavior preservation +- Use tdd-workflow verification gate to validate behavior preservation - Include security tests in test suite - Review diffs carefully for removed security code - Run security-reviewer after refactoring diff --git a/.kiro/docs/shortform-guide.md b/.kiro/docs/shortform-guide.md index ace257f314..4b9dc00d10 100644 --- a/.kiro/docs/shortform-guide.md +++ b/.kiro/docs/shortform-guide.md @@ -57,9 +57,8 @@ Type `/` in chat and select from the menu, or use: | Skill | Use For | |-------|---------| -| `tdd-workflow` | Red-green-refactor TDD cycle | +| `tdd-workflow` | Red-green-refactor TDD cycle + pre-PR verification gate | | `security-review` | Comprehensive security audit | -| `verification-loop` | Continuous validation and improvement | | `coding-standards` | Code style and standards enforcement | | `api-design` | RESTful API design patterns | | `frontend-patterns` | React/Vue/Angular best practices | @@ -207,7 +206,7 @@ Toggle hooks in the Agent Hooks panel or edit `.kiro/hooks/*.kiro.hook` files. "Analyze the user module architecture" 2. /agent swap refactor-cleaner - #verification-loop + #tdd-workflow "Refactor based on the analysis" 3. /agent swap code-reviewer diff --git a/.kiro/skills/agentic-engineering/SKILL.md b/.kiro/skills/agentic-engineering/SKILL.md index 72831ba12c..46686d6ff3 100644 --- a/.kiro/skills/agentic-engineering/SKILL.md +++ b/.kiro/skills/agentic-engineering/SKILL.md @@ -130,6 +130,6 @@ Outcome: Success ## Integration with Other Skills - **tdd-workflow**: Combine with eval-first loop for test-driven development -- **verification-loop**: Use for continuous validation during implementation +- **tdd-workflow**: Also provides a pre-PR verification gate for continuous validation during implementation - **search-first**: Apply before implementation to find existing solutions - **coding-standards**: Reference during code review phase diff --git a/.kiro/skills/verification-loop/SKILL.md b/.kiro/skills/verification-loop/SKILL.md deleted file mode 100644 index f4327b91e1..0000000000 --- a/.kiro/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,128 +0,0 @@ ---- -name: verification-loop -description: > - A comprehensive verification system for Kiro sessions. -metadata: - origin: ECC ---- - -# Verification Loop Skill - -A comprehensive verification system for Kiro sessions. - -## When to Use - -Invoke this skill: -- After completing a feature or significant code change -- Before creating a PR -- When you want to ensure quality gates pass -- After refactoring - -## Verification Phases - -### Phase 1: Build Verification -```bash -# Check if project builds -npm run build 2>&1 | tail -20 -# OR -pnpm build 2>&1 | tail -20 -``` - -If build fails, STOP and fix before continuing. - -### Phase 2: Type Check -```bash -# TypeScript projects -npx tsc --noEmit 2>&1 | head -30 - -# Python projects -pyright . 2>&1 | head -30 -``` - -Report all type errors. Fix critical ones before continuing. - -### Phase 3: Lint Check -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### Phase 4: Test Suite -```bash -# Run tests with coverage -npm run test -- --coverage 2>&1 | tail -50 - -# Check coverage threshold -# Target: 80% minimum -``` - -Report: -- Total tests: X -- Passed: X -- Failed: X -- Coverage: X% - -### Phase 5: Security Scan -```bash -# Check for secrets -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# Check for console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### Phase 6: Diff Review -```bash -# Show what changed -git diff --stat -git diff HEAD~1 --name-only -``` - -Review each changed file for: -- Unintended changes -- Missing error handling -- Potential edge cases - -## Output Format - -After running all phases, produce a verification report: - -``` -VERIFICATION REPORT -================== - -Build: [PASS/FAIL] -Types: [PASS/FAIL] (X errors) -Lint: [PASS/FAIL] (X warnings) -Tests: [PASS/FAIL] (X/Y passed, Z% coverage) -Security: [PASS/FAIL] (X issues) -Diff: [X files changed] - -Overall: [READY/NOT READY] for PR - -Issues to Fix: -1. ... -2. ... -``` - -## Continuous Mode - -For long sessions, run verification every 15 minutes or after major changes: - -```markdown -Set a mental checkpoint: -- After completing each function -- After finishing a component -- Before moving to next task - -Run: /verify -``` - -## Integration with Hooks - -This skill complements postToolUse hooks but provides deeper verification. -Hooks catch issues immediately; this skill provides comprehensive review. diff --git a/.opencode/README.md b/.opencode/README.md index 170a8459f7..37f1390f99 100644 --- a/.opencode/README.md +++ b/.opencode/README.md @@ -168,7 +168,6 @@ The default OpenCode config loads 11 curated ECC skills via the `instructions` a - tdd-workflow - strategic-compact - eval-harness -- verification-loop - api-design - e2e-testing diff --git a/.opencode/opencode.json b/.opencode/opencode.json index 1038140fdf..44c2526c89 100644 --- a/.opencode/opencode.json +++ b/.opencode/opencode.json @@ -14,7 +14,6 @@ "skills/frontend-slides/SKILL.md", "skills/backend-patterns/SKILL.md", "skills/e2e-testing/SKILL.md", - "skills/verification-loop/SKILL.md", "skills/api-design/SKILL.md", "skills/strategic-compact/SKILL.md", "skills/eval-harness/SKILL.md" diff --git a/AGENTS.md b/AGENTS.md index 3abed0a8c2..7b386ce490 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,6 +1,6 @@ # Everything Claude Code (ECC) — Agent Instructions -This is a **production-ready AI coding plugin** providing 30 specialized agents, 136 skills, 60 commands, and automated hook workflows for software development. +This is a **production-ready AI coding plugin** providing 30 specialized agents, 135 skills, 60 commands, and automated hook workflows for software development. **Version:** 1.9.0 @@ -142,7 +142,7 @@ Troubleshoot failures: check test isolation → verify mocks → fix implementat ``` agents/ — 30 specialized subagents -skills/ — 136 workflow skills and domain knowledge +skills/ — 135 workflow skills and domain knowledge commands/ — 60 slash commands hooks/ — Trigger-based automations rules/ — Always-follow guidelines (common + per-language) diff --git a/COMMANDS-QUICK-REF.md b/COMMANDS-QUICK-REF.md index b1bcab691a..f8746ebb6e 100644 --- a/COMMANDS-QUICK-REF.md +++ b/COMMANDS-QUICK-REF.md @@ -12,7 +12,7 @@ | `/tdd` | Enforce test-driven development: scaffold interface → write failing test → implement → verify 80%+ coverage | | `/code-review` | Full code quality, security, and maintainability review of changed files | | `/build-fix` | Detect and fix build errors — delegates to the right build-resolver agent automatically | -| `/verify` | Run the full verification loop: build → lint → test → type-check | +| `/verify` | Run the full verification gate: build → lint → test → type-check (via tdd-workflow) | | `/quality-gate` | Quality gate check against project standards | --- diff --git a/README.md b/README.md index 2417f82314..e4d238624f 100644 --- a/README.md +++ b/README.md @@ -220,7 +220,7 @@ For manual install instructions see the README in the `rules/` folder. When copy /plugin list everything-claude-code@everything-claude-code ``` -**That's it!** You now have access to 30 agents, 136 skills, and 60 commands. +**That's it!** You now have access to 30 agents, 135 skills, and 60 commands. ### Multi-model commands require additional setup @@ -339,10 +339,9 @@ everything-claude-code/ | |-- continuous-learning-v2/ # Instinct-based learning with confidence scoring | |-- iterative-retrieval/ # Progressive context refinement for subagents | |-- strategic-compact/ # Manual compaction suggestions (Longform Guide) -| |-- tdd-workflow/ # TDD methodology +| |-- tdd-workflow/ # TDD methodology + pre-PR verification gate | |-- security-review/ # Security checklist | |-- eval-harness/ # Verification loop evaluation (Longform Guide) -| |-- verification-loop/ # Continuous verification (Longform Guide) | |-- videodb/ # Video and audio: ingest, search, edit, generate, stream (NEW) | |-- golang-patterns/ # Go idioms and best practices | |-- golang-testing/ # Go testing patterns, TDD, benchmarks @@ -1064,7 +1063,7 @@ Skills at `.agents/skills/` are auto-loaded by Codex: | eval-harness | Eval-driven development | | strategic-compact | Context management | | api-design | REST API design patterns | -| verification-loop | Build, test, lint, typecheck, security | +| tdd-workflow | TDD + build, test, lint, typecheck, security verification | ### Key Limitation @@ -1111,7 +1110,7 @@ The configuration is automatically detected from `.opencode/opencode.json`. |---------|-------------|----------|--------| | Agents | PASS: 30 agents | PASS: 12 agents | **Claude Code leads** | | Commands | PASS: 60 commands | PASS: 31 commands | **Claude Code leads** | -| Skills | PASS: 136 skills | PASS: 37 skills | **Claude Code leads** | +| Skills | PASS: 135 skills | PASS: 37 skills | **Claude Code leads** | | Hooks | PASS: 8 event types | PASS: 11 events | **OpenCode has more!** | | Rules | PASS: 29 rules | PASS: 13 instructions | **Claude Code leads** | | MCP Servers | PASS: 14 servers | PASS: Full | **Full parity** | diff --git a/README.zh-CN.md b/README.zh-CN.md index 4ccf1cda62..113e8649f1 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -190,10 +190,9 @@ everything-claude-code/ | |-- continuous-learning-v2/ # 基于直觉的学习与置信度评分 | |-- iterative-retrieval/ # 子代理的渐进式上下文细化 | |-- strategic-compact/ # 手动压缩建议(详细指南) -| |-- tdd-workflow/ # TDD 方法论 +| |-- tdd-workflow/ # TDD 方法论 + PR 前验证门控 | |-- security-review/ # 安全检查清单 | |-- eval-harness/ # 验证循环评估(详细指南) -| |-- verification-loop/ # 持续验证(详细指南) | |-- golang-patterns/ # Go 惯用语和最佳实践(新增) | |-- golang-testing/ # Go 测试模式、TDD、基准测试(新增) | |-- cpp-testing/ # C++ 测试模式、GoogleTest、CMake/CTest(新增) diff --git a/agent.yaml b/agent.yaml index 881c00cef8..de0f8c5d7b 100644 --- a/agent.yaml +++ b/agent.yaml @@ -139,7 +139,6 @@ skills: - tdd-workflow - team-builder - token-budget-advisor - - verification-loop - video-editing - videodb - visa-doc-translate diff --git a/docs/COMMAND-AGENT-MAP.md b/docs/COMMAND-AGENT-MAP.md index 70bcacfc14..a3e56ec864 100644 --- a/docs/COMMAND-AGENT-MAP.md +++ b/docs/COMMAND-AGENT-MAP.md @@ -36,8 +36,8 @@ This document lists each slash command and the primary agent(s) or skills it inv | `/promote` | — | continuous-learning-v2 | | `/projects` | — | continuous-learning-v2 | | `/skill-create` | — | skill-create-output script, git history | -| `/checkpoint` | — | verification-loop skill | -| `/verify` | — | verification-loop skill | +| `/checkpoint` | — | tdd-workflow skill (verification gate) | +| `/verify` | — | tdd-workflow skill (verification gate) | | `/eval` | — | eval-harness skill | | `/test-coverage` | — | Coverage analysis | | `/sessions` | — | Session history | @@ -55,7 +55,7 @@ This document lists each slash command and the primary agent(s) or skills it inv ## Skills referenced by commands - **continuous-learning**, **continuous-learning-v2**: `/learn`, `/learn-eval`, `/instinct-*`, `/evolve`, `/promote`, `/projects` -- **verification-loop**: `/checkpoint`, `/verify` +- **tdd-workflow** (verification gate): `/checkpoint`, `/verify` - **eval-harness**: `/eval` - **security-scan**: `/security-scan` (runs AgentShield) - **strategic-compact**: suggested at compaction points (hooks) diff --git a/docs/ja-JP/README.md b/docs/ja-JP/README.md index 86a802f0ea..c84b672398 100644 --- a/docs/ja-JP/README.md +++ b/docs/ja-JP/README.md @@ -215,10 +215,9 @@ everything-claude-code/ | |-- continuous-learning-v2/ # 信頼度スコア付き直感ベース学習 | |-- iterative-retrieval/ # サブエージェント用の段階的コンテキスト精製 | |-- strategic-compact/ # 手動圧縮提案(長文ガイド) -| |-- tdd-workflow/ # TDD 方法論 +| |-- tdd-workflow/ # TDD 方法論 + PR 前検証ゲート | |-- security-review/ # セキュリティチェックリスト | |-- eval-harness/ # 検証ループ評価(長文ガイド) -| |-- verification-loop/ # 継続的検証(長文ガイド) | |-- golang-patterns/ # Go イディオムとベストプラクティス | |-- golang-testing/ # Go テストパターン、TDD、ベンチマーク | |-- cpp-testing/ # C++ テスト GoogleTest、CMake/CTest(新規) diff --git a/docs/ja-JP/skills/configure-ecc/SKILL.md b/docs/ja-JP/skills/configure-ecc/SKILL.md index 0a9ba790bd..16ef8a222c 100644 --- a/docs/ja-JP/skills/configure-ecc/SKILL.md +++ b/docs/ja-JP/skills/configure-ecc/SKILL.md @@ -120,7 +120,7 @@ Options: | `security-review` | セキュリティチェックリスト: 認証、入力、シークレット、API、決済機能 | | `strategic-compact` | 論理的な間隔で手動コンテキスト圧縮を提案 | | `tdd-workflow` | 80%以上のカバレッジで TDD を強制: ユニット、統合、E2E | -| `verification-loop` | 検証と品質ループのパターン | +| `tdd-workflow` | TDD 方法論 + PR 前検証ゲート | **スタンドアロン** diff --git a/docs/ja-JP/skills/verification-loop/SKILL.md b/docs/ja-JP/skills/verification-loop/SKILL.md deleted file mode 100644 index ee51db997b..0000000000 --- a/docs/ja-JP/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,120 +0,0 @@ -# 検証ループスキル - -Claude Codeセッション向けの包括的な検証システム。 - -## 使用タイミング - -このスキルを呼び出す: -- 機能または重要なコード変更を完了した後 -- PRを作成する前 -- 品質ゲートが通過することを確認したい場合 -- リファクタリング後 - -## 検証フェーズ - -### フェーズ1: ビルド検証 -```bash -# プロジェクトがビルドできるか確認 -npm run build 2>&1 | tail -20 -# または -pnpm build 2>&1 | tail -20 -``` - -ビルドが失敗した場合、停止して続行前に修正。 - -### フェーズ2: 型チェック -```bash -# TypeScriptプロジェクト -npx tsc --noEmit 2>&1 | head -30 - -# Pythonプロジェクト -pyright . 2>&1 | head -30 -``` - -すべての型エラーを報告。続行前に重要なものを修正。 - -### フェーズ3: Lintチェック -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### フェーズ4: テストスイート -```bash -# カバレッジ付きでテストを実行 -npm run test -- --coverage 2>&1 | tail -50 - -# カバレッジ閾値を確認 -# 目標: 最低80% -``` - -報告: -- 合計テスト数: X -- 成功: X -- 失敗: X -- カバレッジ: X% - -### フェーズ5: セキュリティスキャン -```bash -# シークレットを確認 -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# console.logを確認 -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### フェーズ6: 差分レビュー -```bash -# 変更内容を表示 -git diff --stat -git diff HEAD~1 --name-only -``` - -各変更ファイルをレビュー: -- 意図しない変更 -- 不足しているエラー処理 -- 潜在的なエッジケース - -## 出力フォーマット - -すべてのフェーズを実行後、検証レポートを作成: - -``` -検証レポート -================== - -ビルド: [成功/失敗] -型: [成功/失敗] (Xエラー) -Lint: [成功/失敗] (X警告) -テスト: [成功/失敗] (X/Y成功、Z%カバレッジ) -セキュリティ: [成功/失敗] (X問題) -差分: [Xファイル変更] - -総合: PRの準備[完了/未完了] - -修正すべき問題: -1. ... -2. ... -``` - -## 継続モード - -長いセッションの場合、15分ごとまたは主要な変更後に検証を実行: - -```markdown -メンタルチェックポイントを設定: -- 各関数を完了した後 -- コンポーネントを完了した後 -- 次のタスクに移る前 - -実行: /verify -``` - -## フックとの統合 - -このスキルはPostToolUseフックを補完しますが、より深い検証を提供します。 -フックは問題を即座に捕捉; このスキルは包括的なレビューを提供。 diff --git a/docs/ko-KR/skills/verification-loop/SKILL.md b/docs/ko-KR/skills/verification-loop/SKILL.md deleted file mode 100644 index ca9a5a0a71..0000000000 --- a/docs/ko-KR/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,127 +0,0 @@ ---- -name: verification-loop -description: "Claude Code 세션을 위한 포괄적인 검증 시스템." -origin: ECC ---- - -# 검증 루프 스킬 - -Claude Code 세션을 위한 포괄적인 검증 시스템. - -## 사용 시점 - -다음 상황에서 이 스킬을 호출하세요: -- 기능 또는 주요 코드 변경을 완료한 후 -- PR을 생성하기 전 -- 품질 게이트가 통과하는지 확인하고 싶을 때 -- 리팩터링 후 - -## 검증 단계 - -### 단계 1: 빌드 검증 -```bash -# Check if project builds -npm run build 2>&1 | tail -20 -# OR -pnpm build 2>&1 | tail -20 -``` - -빌드가 실패하면 계속하기 전에 중단하고 수정합니다. - -### 단계 2: 타입 검사 -```bash -# TypeScript projects -npx tsc --noEmit 2>&1 | head -30 - -# Python projects -pyright . 2>&1 | head -30 -``` - -모든 타입 에러를 보고합니다. 중요한 것은 계속하기 전에 수정합니다. - -### 단계 3: 린트 검사 -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### 단계 4: 테스트 스위트 -```bash -# Run tests with coverage -npm run test -- --coverage 2>&1 | tail -50 - -# Check coverage threshold -# Target: 80% minimum -``` - -보고 항목: -- 전체 테스트: X -- 통과: X -- 실패: X -- 커버리지: X% - -### 단계 5: 보안 스캔 -```bash -# Check for secrets -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# Check for console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### 단계 6: Diff 리뷰 -```bash -# Show what changed -git diff --stat -git diff --name-only -git diff --cached --name-only -``` - -각 변경된 파일에서 다음을 검토합니다: -- 의도하지 않은 변경 -- 누락된 에러 처리 -- 잠재적 엣지 케이스 - -## 출력 형식 - -모든 단계를 실행한 후 검증 보고서를 생성합니다: - -``` -VERIFICATION REPORT -================== - -Build: [PASS/FAIL] -Types: [PASS/FAIL] (X errors) -Lint: [PASS/FAIL] (X warnings) -Tests: [PASS/FAIL] (X/Y passed, Z% coverage) -Security: [PASS/FAIL] (X issues) -Diff: [X files changed] - -Overall: [READY/NOT READY] for PR - -Issues to Fix: -1. ... -2. ... -``` - -## 연속 모드 - -긴 세션에서는 15분마다 또는 주요 변경 후에 검증을 실행합니다: - -```markdown -Set a mental checkpoint: -- After completing each function -- After finishing a component -- Before moving to next task - -Run: /verify -``` - -## Hook과의 통합 - -이 스킬은 PostToolUse Hook을 보완하지만 더 깊은 검증을 제공합니다. -Hook은 즉시 문제를 포착하고, 이 스킬은 포괄적인 검토를 제공합니다. diff --git a/docs/tr/skills/verification-loop/SKILL.md b/docs/tr/skills/verification-loop/SKILL.md deleted file mode 100644 index d6936e8012..0000000000 --- a/docs/tr/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,126 +0,0 @@ ---- -name: verification-loop -description: "Claude Code oturumları için kapsamlı doğrulama sistemi." -origin: ECC ---- - -# Verification Loop Skill - -Claude Code oturumları için kapsamlı doğrulama sistemi. - -## Ne Zaman Kullanılır - -Bu skill'i şu durumlarda çağır: -- Bir özellik veya önemli kod değişikliği tamamladıktan sonra -- PR oluşturmadan önce -- Kalite kapılarının geçtiğinden emin olmak istediğinde -- Refactoring sonrasında - -## Doğrulama Fazları - -### Faz 1: Build Doğrulaması -```bash -# Projenin build olup olmadığını kontrol et -npm run build 2>&1 | tail -20 -# VEYA -pnpm build 2>&1 | tail -20 -``` - -Build başarısız olursa, devam etmeden önce DUR ve düzelt. - -### Faz 2: Tip Kontrolü -```bash -# TypeScript projeleri -npx tsc --noEmit 2>&1 | head -30 - -# Python projeleri -pyright . 2>&1 | head -30 -``` - -Tüm tip hatalarını raporla. Devam etmeden önce kritik olanları düzelt. - -### Faz 3: Lint Kontrolü -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### Faz 4: Test Paketi -```bash -# Testleri coverage ile çalıştır -npm run test -- --coverage 2>&1 | tail -50 - -# Coverage eşiğini kontrol et -# Hedef: minimum %80 -``` - -Rapor: -- Toplam testler: X -- Geçti: X -- Başarısız: X -- Coverage: %X - -### Faz 5: Güvenlik Taraması -```bash -# Secret'ları kontrol et -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# console.log kontrol et -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### Faz 6: Diff İncelemesi -```bash -# Neyin değiştiğini göster -git diff --stat -git diff HEAD~1 --name-only -``` - -Her değişen dosyayı şunlar için incele: -- İstenmeyen değişiklikler -- Eksik hata işleme -- Potansiyel edge case'ler - -## Çıktı Formatı - -Tüm fazları çalıştırdıktan sonra, bir doğrulama raporu üret: - -``` -DOĞRULAMA RAPORU -================== - -Build: [PASS/FAIL] -Tipler: [PASS/FAIL] (X hata) -Lint: [PASS/FAIL] (X uyarı) -Testler: [PASS/FAIL] (X/Y geçti, %Z coverage) -Güvenlik: [PASS/FAIL] (X sorun) -Diff: [X dosya değişti] - -Genel: PR için [HAZIR/HAZIR DEĞİL] - -Düzeltilmesi Gereken Sorunlar: -1. ... -2. ... -``` - -## Sürekli Mod - -Uzun oturumlar için, her 15 dakikada bir veya major değişikliklerden sonra doğrulama çalıştır: - -```markdown -Mental kontrol noktası belirle: -- Her fonksiyonu tamamladıktan sonra -- Bir component'i bitirdikten sonra -- Sonraki göreve geçmeden önce - -Çalıştır: /verify -``` - -## Hook'larla Entegrasyon - -Bu skill PostToolUse hook'larını tamamlar ancak daha derin doğrulama sağlar. -Hook'lar sorunları anında yakalar; bu skill kapsamlı inceleme sağlar. diff --git a/docs/zh-CN/README.md b/docs/zh-CN/README.md index e363001e0b..e7c6f0a58c 100644 --- a/docs/zh-CN/README.md +++ b/docs/zh-CN/README.md @@ -314,10 +314,9 @@ everything-claude-code/ | |-- continuous-learning-v2/ # 基于直觉的学习与置信度评分 | |-- iterative-retrieval/ # 子代理渐进式上下文优化 | |-- strategic-compact/ # 手动压缩建议(长文指南) -| |-- tdd-workflow/ # TDD 方法论 +| |-- tdd-workflow/ # TDD 方法论 + PR 前验证门控 | |-- security-review/ # 安全检查清单 | |-- eval-harness/ # 验证循环评估(长文指南) -| |-- verification-loop/ # 持续验证(长文指南) | |-- videodb/ # 视频与音频:导入、搜索、编辑、生成与流式处理(新增) | |-- golang-patterns/ # Go 习惯用法与最佳实践 | |-- golang-testing/ # Go 测试模式、TDD 与基准测试 @@ -1049,7 +1048,7 @@ Codex macOS 应用: | eval-harness | 评估驱动的开发 | | strategic-compact | 上下文管理 | | api-design | REST API 设计模式 | -| verification-loop | 构建、测试、代码检查、类型检查、安全 | +| tdd-workflow | TDD + 构建、测试、代码检查、类型检查、安全验证 | ### 关键限制 diff --git a/docs/zh-CN/skills/autonomous-loops/SKILL.md b/docs/zh-CN/skills/autonomous-loops/SKILL.md index 15807f6524..81acf2541f 100644 --- a/docs/zh-CN/skills/autonomous-loops/SKILL.md +++ b/docs/zh-CN/skills/autonomous-loops/SKILL.md @@ -579,7 +579,7 @@ evictionContext ───────────────────── 2. **连续 Claude + 去草率化** — 为每次迭代添加带有去草率化指令的 `--review-prompt`。 -3. **任何循环 + 验证** — 在提交前,使用 ECC 的 `/verify` 命令或 `verification-loop` 技能作为关卡。 +3. **任何循环 + 验证** — 在提交前,使用 ECC 的 `/verify` 命令或 `tdd-workflow` 技能中的验证门控作为关卡。 4. **Ralphinho 在简单循环中的分层方法** — 即使在顺序流水线中,你也可以将简单任务路由到 Haiku,复杂任务路由到 Opus: ```bash @@ -618,4 +618,4 @@ evictionContext ───────────────────── | Infinite Agentic Loop | disler | credit: @disler | | Continuous Claude | AnandChowdhary | credit: @AnandChowdhary | | NanoClaw | ECC | 此仓库中的 `/claw` 命令 | -| Verification Loop | ECC | 此仓库中的 `skills/verification-loop/` | +| Verification Gate | ECC | `skills/tdd-workflow/` 中的 PR 前验证 | diff --git a/docs/zh-CN/skills/configure-ecc/SKILL.md b/docs/zh-CN/skills/configure-ecc/SKILL.md index fad024c313..2197b1c65c 100644 --- a/docs/zh-CN/skills/configure-ecc/SKILL.md +++ b/docs/zh-CN/skills/configure-ecc/SKILL.md @@ -150,7 +150,7 @@ mkdir -p $TARGET/skills $TARGET/rules | `security-review` | 安全检查清单:身份验证、输入、密钥、API、支付功能 | | `strategic-compact` | 在逻辑间隔处建议手动上下文压缩 | | `tdd-workflow` | 强制要求 TDD,覆盖率 80% 以上:单元测试、集成测试、端到端测试 | -| `verification-loop` | 验证和质量循环模式 | +| `tdd-workflow` | TDD 方法论 + PR 前验证门控 | **类别:业务与内容(5 项技能)** diff --git a/docs/zh-CN/skills/plankton-code-quality/SKILL.md b/docs/zh-CN/skills/plankton-code-quality/SKILL.md index f5c888c411..05264674df 100644 --- a/docs/zh-CN/skills/plankton-code-quality/SKILL.md +++ b/docs/zh-CN/skills/plankton-code-quality/SKILL.md @@ -131,7 +131,7 @@ claude 1. 将 ECC 安装为你的插件(代理、技能、命令、规则) 2. 添加 Plankton 钩子以实现编写时质量强制执行 3. 使用 AgentShield 进行安全审计 -4. 在 PR 之前使用 ECC 的 verification-loop 作为最后一道关卡 +4. 在 PR 之前使用 ECC 的 tdd-workflow 验证门控作为最后一道关卡 ### 避免钩子冲突 diff --git a/docs/zh-CN/skills/prompt-optimizer/SKILL.md b/docs/zh-CN/skills/prompt-optimizer/SKILL.md index 73a3fbf0b2..453e5f9ad4 100644 --- a/docs/zh-CN/skills/prompt-optimizer/SKILL.md +++ b/docs/zh-CN/skills/prompt-optimizer/SKILL.md @@ -99,9 +99,9 @@ metadata: | 意图 | 命令 | 技能 | 代理 | |--------|----------|--------|--------| -| 新功能 | /plan, /tdd, /code-review, /verify | tdd-workflow, verification-loop | planner, tdd-guide, code-reviewer | +| 新功能 | /plan, /tdd, /code-review, /verify | tdd-workflow | planner, tdd-guide, code-reviewer | | 错误修复 | /tdd, /build-fix, /verify | tdd-workflow | tdd-guide, build-error-resolver | -| 重构 | /refactor-clean, /code-review, /verify | verification-loop | refactor-cleaner, code-reviewer | +| 重构 | /refactor-clean, /code-review, /verify | tdd-workflow | refactor-cleaner, code-reviewer | | 研究 | /plan | search-first, iterative-retrieval | — | | 测试 | /tdd, /e2e, /test-coverage | tdd-workflow, e2e-testing | tdd-guide, e2e-runner | | 审查 | /code-review | security-review | code-reviewer, security-reviewer | diff --git a/docs/zh-CN/skills/verification-loop/SKILL.md b/docs/zh-CN/skills/verification-loop/SKILL.md deleted file mode 100644 index 6607fe8bf0..0000000000 --- a/docs/zh-CN/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,136 +0,0 @@ ---- -name: verification-loop -description: "Claude Code 会话的全面验证系统。" -origin: ECC ---- - -# 验证循环技能 - -一个全面的 Claude Code 会话验证系统。 - -## 何时使用 - -在以下情况下调用此技能: - -* 完成功能或重大代码变更后 -* 创建 PR 之前 -* 当您希望确保质量门通过时 -* 重构之后 - -## 验证阶段 - -### 阶段 1:构建验证 - -```bash -# Check if project builds -npm run build 2>&1 | tail -20 -# OR -pnpm build 2>&1 | tail -20 -``` - -如果构建失败,请停止并在继续之前修复。 - -### 阶段 2:类型检查 - -```bash -# TypeScript projects -npx tsc --noEmit 2>&1 | head -30 - -# Python projects -pyright . 2>&1 | head -30 -``` - -报告所有类型错误。在继续之前修复关键错误。 - -### 阶段 3:代码规范检查 - -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### 阶段 4:测试套件 - -```bash -# Run tests with coverage -npm run test -- --coverage 2>&1 | tail -50 - -# Check coverage threshold -# Target: 80% minimum -``` - -报告: - -* 总测试数:X -* 通过:X -* 失败:X -* 覆盖率:X% - -### 阶段 5:安全扫描 - -```bash -# Check for secrets -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# Check for console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### 阶段 6:差异审查 - -```bash -# Show what changed -git diff --stat -git diff HEAD~1 --name-only -``` - -审查每个更改的文件,检查: - -* 意外更改 -* 缺失的错误处理 -* 潜在的边界情况 - -## 输出格式 - -运行所有阶段后,生成验证报告: - -``` -验证报告 -================== - -构建: [通过/失败] -类型: [通过/失败] (X 处错误) -代码检查: [通过/失败] (X 条警告) -测试: [通过/失败] (X/Y 通过,覆盖率 Z%) -安全: [通过/失败] (X 个问题) -差异: [X 个文件被修改] - -总体: [就绪/未就绪] 提交 PR - -待修复问题: -1. ... -2. ... -``` - -## 持续模式 - -对于长时间会话,每 15 分钟或在重大更改后运行验证: - -```markdown -设置一个心理检查点: -- 完成每个函数后 -- 完成一个组件后 -- 在移动到下一个任务之前 - -运行: /verify - -``` - -## 与钩子的集成 - -此技能补充 PostToolUse 钩子,但提供更深入的验证。 -钩子会立即捕获问题;此技能提供全面的审查。 diff --git a/docs/zh-TW/README.md b/docs/zh-TW/README.md index 5185e9c636..14469fefa8 100644 --- a/docs/zh-TW/README.md +++ b/docs/zh-TW/README.md @@ -168,10 +168,9 @@ everything-claude-code/ | |-- continuous-learning-v2/ # 基於本能的學習與信心評分 | |-- iterative-retrieval/ # 子代理程式的漸進式上下文精煉 | |-- strategic-compact/ # 手動壓縮建議(完整指南) -| |-- tdd-workflow/ # TDD 方法論 +| |-- tdd-workflow/ # TDD 方法論 + PR 前驗證門控 | |-- security-review/ # 安全性檢查清單 | |-- eval-harness/ # 驗證迴圈評估(完整指南) -| |-- verification-loop/ # 持續驗證(完整指南) | |-- golang-patterns/ # Go 慣用語法和最佳實務(新增) | |-- golang-testing/ # Go 測試模式、TDD、基準測試(新增) | diff --git a/docs/zh-TW/skills/verification-loop/SKILL.md b/docs/zh-TW/skills/verification-loop/SKILL.md deleted file mode 100644 index 07efbf8c25..0000000000 --- a/docs/zh-TW/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,120 +0,0 @@ -# 驗證循環技能 - -Claude Code 工作階段的完整驗證系統。 - -## 何時使用 - -在以下情況呼叫此技能: -- 完成功能或重大程式碼變更後 -- 建立 PR 前 -- 想確保品質門檻通過時 -- 重構後 - -## 驗證階段 - -### 階段 1:建置驗證 -```bash -# 檢查專案是否建置 -npm run build 2>&1 | tail -20 -# 或 -pnpm build 2>&1 | tail -20 -``` - -如果建置失敗,停止並在繼續前修復。 - -### 階段 2:型別檢查 -```bash -# TypeScript 專案 -npx tsc --noEmit 2>&1 | head -30 - -# Python 專案 -pyright . 2>&1 | head -30 -``` - -報告所有型別錯誤。繼續前修復關鍵錯誤。 - -### 階段 3:Lint 檢查 -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### 階段 4:測試套件 -```bash -# 執行帶覆蓋率的測試 -npm run test -- --coverage 2>&1 | tail -50 - -# 檢查覆蓋率門檻 -# 目標:最低 80% -``` - -報告: -- 總測試數:X -- 通過:X -- 失敗:X -- 覆蓋率:X% - -### 階段 5:安全掃描 -```bash -# 檢查密鑰 -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# 檢查 console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### 階段 6:差異審查 -```bash -# 顯示變更內容 -git diff --stat -git diff HEAD~1 --name-only -``` - -審查每個變更的檔案: -- 非預期變更 -- 缺少錯誤處理 -- 潛在邊界案例 - -## 輸出格式 - -執行所有階段後,產生驗證報告: - -``` -驗證報告 -================== - -建置: [PASS/FAIL] -型別: [PASS/FAIL](X 個錯誤) -Lint: [PASS/FAIL](X 個警告) -測試: [PASS/FAIL](X/Y 通過,Z% 覆蓋率) -安全性: [PASS/FAIL](X 個問題) -差異: [X 個檔案變更] - -整體: [READY/NOT READY] for PR - -待修復問題: -1. ... -2. ... -``` - -## 持續模式 - -對於長時間工作階段,每 15 分鐘或重大變更後執行驗證: - -```markdown -設定心理檢查點: -- 完成每個函式後 -- 完成元件後 -- 移至下一個任務前 - -執行:/verify -``` - -## 與 Hooks 整合 - -此技能補充 PostToolUse hooks 但提供更深入的驗證。 -Hooks 立即捕捉問題;此技能提供全面審查。 diff --git a/manifests/install-components.json b/manifests/install-components.json index 8f3d73064c..16098fb0b6 100644 --- a/manifests/install-components.json +++ b/manifests/install-components.json @@ -355,14 +355,6 @@ "workflow-quality" ] }, - { - "id": "skill:verification-loop", - "family": "skill", - "description": "Verification loop for code quality assurance.", - "modules": [ - "workflow-quality" - ] - }, { "id": "skill:strategic-compact", "family": "skill", diff --git a/manifests/install-modules.json b/manifests/install-modules.json index 619d39483b..3e3f40f65a 100644 --- a/manifests/install-modules.json +++ b/manifests/install-modules.json @@ -197,8 +197,7 @@ "skills/project-guidelines-example", "skills/skill-stocktake", "skills/strategic-compact", - "skills/tdd-workflow", - "skills/verification-loop" + "skills/tdd-workflow" ], "targets": [ "claude", diff --git a/skills/autonomous-loops/SKILL.md b/skills/autonomous-loops/SKILL.md index d6f455723a..0bbb4919f6 100644 --- a/skills/autonomous-loops/SKILL.md +++ b/skills/autonomous-loops/SKILL.md @@ -568,7 +568,7 @@ These patterns compose well: 2. **Continuous Claude + De-Sloppify** — Add `--review-prompt` with a de-sloppify directive to each iteration. -3. **Any loop + Verification** — Use ECC's `/verify` command or `verification-loop` skill as a gate before commits. +3. **Any loop + Verification** — Use ECC's `/verify` command or the verification gate in the `tdd-workflow` skill as a gate before commits. 4. **Ralphinho's tiered approach in simpler loops** — Even in a sequential pipeline, you can route simple tasks to Haiku and complex tasks to Opus: ```bash @@ -607,4 +607,4 @@ These patterns compose well: | Infinite Agentic Loop | disler | credit: @disler | | Continuous Claude | AnandChowdhary | credit: @AnandChowdhary | | NanoClaw | ECC | `/claw` command in this repo | -| Verification Loop | ECC | `skills/verification-loop/` in this repo | +| Verification Gate | ECC | Pre-PR verification in `skills/tdd-workflow/` | diff --git a/skills/configure-ecc/SKILL.md b/skills/configure-ecc/SKILL.md index 07109a30e0..8e1779c9b5 100644 --- a/skills/configure-ecc/SKILL.md +++ b/skills/configure-ecc/SKILL.md @@ -146,7 +146,7 @@ For each selected category, print the full list of skills below and ask the user | `security-review` | Security checklist: auth, input, secrets, API, payment features | | `strategic-compact` | Suggests manual context compaction at logical intervals | | `tdd-workflow` | Enforces TDD with 80%+ coverage: unit, integration, E2E | -| `verification-loop` | Verification and quality loop patterns | +| `tdd-workflow` | TDD methodology with pre-PR verification gate | **Category: Business & Content (5 skills)** diff --git a/skills/plankton-code-quality/SKILL.md b/skills/plankton-code-quality/SKILL.md index 16513c2573..f1ba3bed66 100644 --- a/skills/plankton-code-quality/SKILL.md +++ b/skills/plankton-code-quality/SKILL.md @@ -127,7 +127,7 @@ To use Plankton hooks in your own project: 1. Install ECC as your plugin (agents, skills, commands, rules) 2. Add Plankton hooks for write-time quality enforcement 3. Use AgentShield for security audits -4. Use ECC's verification-loop as a final gate before PRs +4. Use ECC's tdd-workflow verification gate as a final gate before PRs ### Avoiding Hook Conflicts diff --git a/skills/prompt-optimizer/SKILL.md b/skills/prompt-optimizer/SKILL.md index 3241968c0b..93aba2f0ca 100644 --- a/skills/prompt-optimizer/SKILL.md +++ b/skills/prompt-optimizer/SKILL.md @@ -117,9 +117,9 @@ Map intent + scope + tech stack (from Phase 0) to specific ECC components. | Intent | Commands | Skills | Agents | |--------|----------|--------|--------| -| New Feature | /plan, /tdd, /code-review, /verify | tdd-workflow, verification-loop | planner, tdd-guide, code-reviewer | +| New Feature | /plan, /tdd, /code-review, /verify | tdd-workflow | planner, tdd-guide, code-reviewer | | Bug Fix | /tdd, /build-fix, /verify | tdd-workflow | tdd-guide, build-error-resolver | -| Refactor | /refactor-clean, /code-review, /verify | verification-loop | refactor-cleaner, code-reviewer | +| Refactor | /refactor-clean, /code-review, /verify | tdd-workflow | refactor-cleaner, code-reviewer | | Research | /plan | search-first, iterative-retrieval | — | | Testing | /tdd, /e2e, /test-coverage | tdd-workflow, e2e-testing | tdd-guide, e2e-runner | | Review | /code-review | security-review | code-reviewer, security-reviewer | diff --git a/skills/santa-method/SKILL.md b/skills/santa-method/SKILL.md index 77a9ac8711..27f72bbb1e 100644 --- a/skills/santa-method/SKILL.md +++ b/skills/santa-method/SKILL.md @@ -279,7 +279,7 @@ def santa_batch(items, rubric, sample_rate=0.15): | Skill | Relationship | |-------|-------------| -| Verification Loop | Use for deterministic checks (build, lint, test). Santa for semantic checks (accuracy, hallucinations). Run verification-loop first, Santa second. | +| TDD Workflow (Verification Gate) | Use for deterministic checks (build, lint, test). Santa for semantic checks (accuracy, hallucinations). Run the tdd-workflow verification gate first, Santa second. | | Eval Harness | Santa Method results feed eval metrics. Track pass@k across Santa runs to measure generator quality over time. | | Continuous Learning v2 | Santa findings become instincts. Repeated failures on the same criterion → learned behavior to avoid the pattern. | | Strategic Compact | Run Santa BEFORE compacting. Don't lose review context mid-verification. | diff --git a/skills/tdd-workflow/SKILL.md b/skills/tdd-workflow/SKILL.md index 76aaaa1ac7..e9f55728d7 100644 --- a/skills/tdd-workflow/SKILL.md +++ b/skills/tdd-workflow/SKILL.md @@ -1,6 +1,6 @@ --- name: tdd-workflow -description: Use this skill when writing new features, fixing bugs, or refactoring code. Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests. +description: Use this skill when writing new features, fixing bugs, or refactoring code. Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests. Includes pre-PR verification gates (build, type-check, lint, security, diff review). origin: ECC --- @@ -15,6 +15,9 @@ This skill ensures all code development follows TDD principles with comprehensiv - Refactoring existing code - Adding API endpoints - Creating new components +- After completing a feature or significant code change (verification gate) +- Before creating a PR (pre-PR verification) +- When you want to ensure quality gates pass ## Core Principles @@ -230,57 +233,10 @@ describe('GET /api/markets', () => { ``` ### E2E Test Pattern (Playwright) -```typescript -import { test, expect } from '@playwright/test' - -test('user can search and filter markets', async ({ page }) => { - // Navigate to markets page - await page.goto('/') - await page.click('a[href="/markets"]') - - // Verify page loaded - await expect(page.locator('h1')).toContainText('Markets') - - // Search for markets - await page.fill('input[placeholder="Search markets"]', 'election') - // Wait for debounce and results - await page.waitForTimeout(600) - - // Verify search results displayed - const results = page.locator('[data-testid="market-card"]') - await expect(results).toHaveCount(5, { timeout: 5000 }) - - // Verify results contain search term - const firstResult = results.first() - await expect(firstResult).toContainText('election', { ignoreCase: true }) - - // Filter by status - await page.click('button:has-text("Active")') - - // Verify filtered results - await expect(results).toHaveCount(3) -}) - -test('user can create a new market', async ({ page }) => { - // Login first - await page.goto('/creator-dashboard') - - // Fill market creation form - await page.fill('input[name="name"]', 'Test Market') - await page.fill('textarea[name="description"]', 'Test description') - await page.fill('input[name="endDate"]', '2025-12-31') - - // Submit form - await page.click('button[type="submit"]') - - // Verify success message - await expect(page.locator('text=Market created successfully')).toBeVisible() - - // Verify redirect to market page - await expect(page).toHaveURL(/\/markets\/test-market/) -}) -``` +For comprehensive Playwright patterns including Page Object Model, configuration, +flaky test strategies, artifact management, and CI/CD integration, see the +[e2e-testing skill](../e2e-testing/SKILL.md). ## Test File Organization @@ -458,6 +414,116 @@ npm test && npm run lint - E2E tests cover critical user flows - Tests catch bugs before production +## Pre-PR Verification Gate + +After completing the TDD cycle, run a full verification gate before creating a PR. +This replaces the former `verification-loop` skill. + +### Phase 1: Build Verification +```bash +# Check if project builds +npm run build 2>&1 | tail -20 +# OR +pnpm build 2>&1 | tail -20 +``` + +If build fails, STOP and fix before continuing. + +### Phase 2: Type Check +```bash +# TypeScript projects +npx tsc --noEmit 2>&1 | head -30 + +# Python projects +pyright . 2>&1 | head -30 +``` + +Report all type errors. Fix critical ones before continuing. + +### Phase 3: Lint Check +```bash +# JavaScript/TypeScript +npm run lint 2>&1 | head -30 + +# Python +ruff check . 2>&1 | head -30 +``` + +### Phase 4: Test Suite +```bash +# Run tests with coverage +npm run test -- --coverage 2>&1 | tail -50 + +# Check coverage threshold +# Target: 80% minimum +``` + +Report: +- Total tests: X +- Passed: X +- Failed: X +- Coverage: X% + +### Phase 5: Security Scan +```bash +# Check for secrets +grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 +grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 + +# Check for console.log +grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 +``` + +### Phase 6: Diff Review +```bash +# Show what changed +git diff --stat +git diff HEAD~1 --name-only +``` + +Review each changed file for: +- Unintended changes +- Missing error handling +- Potential edge cases + +### Verification Report Format + +After running all phases, produce a verification report: + +``` +VERIFICATION REPORT +================== + +Build: [PASS/FAIL] +Types: [PASS/FAIL] (X errors) +Lint: [PASS/FAIL] (X warnings) +Tests: [PASS/FAIL] (X/Y passed, Z% coverage) +Security: [PASS/FAIL] (X issues) +Diff: [X files changed] + +Overall: [READY/NOT READY] for PR + +Issues to Fix: +1. ... +2. ... +``` + +### Continuous Verification + +For long sessions, run verification every 15 minutes or after major changes: + +```markdown +Set a mental checkpoint: +- After completing each function +- After finishing a component +- Before moving to next task + +Run: /verify +``` + +This verification gate complements PostToolUse hooks but provides deeper, +comprehensive review. + --- **Remember**: Tests are not optional. They are the safety net that enables confident refactoring, rapid development, and production reliability. diff --git a/skills/verification-loop/SKILL.md b/skills/verification-loop/SKILL.md deleted file mode 100644 index 1933545d57..0000000000 --- a/skills/verification-loop/SKILL.md +++ /dev/null @@ -1,126 +0,0 @@ ---- -name: verification-loop -description: "A comprehensive verification system for Claude Code sessions." -origin: ECC ---- - -# Verification Loop Skill - -A comprehensive verification system for Claude Code sessions. - -## When to Use - -Invoke this skill: -- After completing a feature or significant code change -- Before creating a PR -- When you want to ensure quality gates pass -- After refactoring - -## Verification Phases - -### Phase 1: Build Verification -```bash -# Check if project builds -npm run build 2>&1 | tail -20 -# OR -pnpm build 2>&1 | tail -20 -``` - -If build fails, STOP and fix before continuing. - -### Phase 2: Type Check -```bash -# TypeScript projects -npx tsc --noEmit 2>&1 | head -30 - -# Python projects -pyright . 2>&1 | head -30 -``` - -Report all type errors. Fix critical ones before continuing. - -### Phase 3: Lint Check -```bash -# JavaScript/TypeScript -npm run lint 2>&1 | head -30 - -# Python -ruff check . 2>&1 | head -30 -``` - -### Phase 4: Test Suite -```bash -# Run tests with coverage -npm run test -- --coverage 2>&1 | tail -50 - -# Check coverage threshold -# Target: 80% minimum -``` - -Report: -- Total tests: X -- Passed: X -- Failed: X -- Coverage: X% - -### Phase 5: Security Scan -```bash -# Check for secrets -grep -rn "sk-" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 -grep -rn "api_key" --include="*.ts" --include="*.js" . 2>/dev/null | head -10 - -# Check for console.log -grep -rn "console.log" --include="*.ts" --include="*.tsx" src/ 2>/dev/null | head -10 -``` - -### Phase 6: Diff Review -```bash -# Show what changed -git diff --stat -git diff HEAD~1 --name-only -``` - -Review each changed file for: -- Unintended changes -- Missing error handling -- Potential edge cases - -## Output Format - -After running all phases, produce a verification report: - -``` -VERIFICATION REPORT -================== - -Build: [PASS/FAIL] -Types: [PASS/FAIL] (X errors) -Lint: [PASS/FAIL] (X warnings) -Tests: [PASS/FAIL] (X/Y passed, Z% coverage) -Security: [PASS/FAIL] (X issues) -Diff: [X files changed] - -Overall: [READY/NOT READY] for PR - -Issues to Fix: -1. ... -2. ... -``` - -## Continuous Mode - -For long sessions, run verification every 15 minutes or after major changes: - -```markdown -Set a mental checkpoint: -- After completing each function -- After finishing a component -- Before moving to next task - -Run: /verify -``` - -## Integration with Hooks - -This skill complements PostToolUse hooks but provides deeper verification. -Hooks catch issues immediately; this skill provides comprehensive review.