Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/classmethod/tsumiki/tdd-refactorgit clone --depth 1 https://github.com/classmethod/tsumikiWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00039 | $0.04990 |
| Opus 5 | $0.00019 | $0.02495 |
| Sonnet 5 | $0.00008 | $0.00998 |
| Haiku 4.5 | $0.00004 | $0.00499 |
Grade A, and why
tdd-refactor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
Copies of this mod
1 near-identical copy found in the catalogue:
- tdd-verify-complete — 86% identical, 582 lines differ
How it starts
The opening of the file, as written. The whole thing — 409 lines — stays where its author put it; the contents beside it link to each section on GitHub.
TDDのRefactorフェーズを実行し、Greenフェーズで作成した実装コードの品質を改善します。
context
出力ディレクトリ="./docs/implements" 機能名={{feature_name}} タスクID={{task_id}} 要件名={{requirement_name}} 信頼性評価=[] メモファイル=./docs/implements/{要件名}/{{task_id}}/{feature_name}-memo.md 要件定義ファイル=./docs/implements/{要件名}/{{task_id}}/{feature_name}-requirements.md テストケースファイル=./docs/implements/{要件名}/{{task_id}}/{feature_name}-testcases.md Greenフェーズファイル=./docs/implements/{要件名}/{{task_id}}/{feature_name}-green-phase.md Refactorフェーズファイル=./docs/implements/{要件名}/{{task_id}}/{feature_name}-refactor-phase.md
step
- $ARGUMENTS がない場合、「引数に要件名とTASK-IDを指定してください(例: ユーザー認証機能 TASK-0001)」と言って終了する
- $ARGUMENTS の内容と context の内容をまとめてユーザに宣言する
- step2 を実行する
step2: コンテキスト準備
開発コンテキストの準備を実行する:
-
タスクノートの読み込み(唯一のコンテキストソース)
./docs/implements/{要件名}/{{task_id}}/note.mdを読み込み- 存在しない場合: @task で
/tsumiki-legacy:tdd-tasknote {要件名} {{task_id}}を実行して生成 - note.mdには技術スタック、開発ルール、関連実装、設計文書、テスト関連情報、注意事項が集約済み
-
直前フェーズの出力を読み込み
./docs/implements/{要件名}/{{task_id}}/{feature_name}-requirements.md- 要件定義./docs/implements/{要件名}/{{task_id}}/{feature_name}-testcases.md- テストケース定義./docs/implements/{要件名}/{{task_id}}/{feature_name}-green-phase.md- Greenフェーズの実装記録./docs/implements/{要件名}/{{task_id}}/{feature_name}-refactor-phase.md- 既存のRefactorフェーズ記録(存在する場合)./docs/implements/{要件名}/{{task_id}}/{feature_name}-memo.md- 開発履歴メモ(存在する場合)
読み込み完了後、step3 を実行する
step3: テスト実行とコード品質確認
-
現在のテストが全て通ることを確認
- 【品質保証】: リファクタ前の動作確認
- 【安全性確保】: 変更による機能破綻の防止
- 【実行方法】: Taskツールを使用してテストを実行し、結果を詳細に分析
-
テスト実行時間のチェック
- 【長時間テストの検出】: 2秒以上かかるテストがないか確認
- 【警告表示】: 遅いテストが見つかった場合は以下を表示
⚠️ 遅いテストが検出されました(2秒以上) 詳細な分析とリファクタリング提案が必要な場合: `/tsumiki:dcs:test-performance-analysis` を実行してください テスト実行速度の改善パターン: `/tsumiki:test-optimization-patterns` を実行してください
-
コード・テスト除外チェック
- 【.gitignore確認】: 本来確認対象のコードファイルが除外されていないかチェック
- 【テスト除外確認】:
describe.skip,it.skip,test.skip等でテストが無効化されていないかチェック - 【jest設定確認】:
jest.config.jsやpackage.jsonのtestPathIgnorePatterns等でテストファイルが除外されていないかチェック - 【実行対象確認】: 実際に実行されるべきテストとコードが適切に対象に含まれているかチェック
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 409 lines · 39 tokens per session scan A 2d2423f3c009
tdd-refactor is a command published in the GitHub repository classmethod/tsumiki (974 stars, last pushed 25d ago), licensed MIT. It adds 39 tokens to every session and 4,990 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
checklist
Generate a custom checklist for the current feature based on user requirements.
clarify
Identify underspecified areas in the current feature spec by asking up to 5 highly targeted clarification questions and encoding answers back into the spec.
specify
Create or update the feature specification from a natural language feature description.
analyze
Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation.
converge
Assess the current codebase against the feature's spec, plan, and tasks, then append any remaining unbuilt work as new tasks to tasks.md so implement can complete it.
implement
Execute the implementation plan by processing and executing all tasks defined in tasks.md.