agent-tui: Command for Claude Code

.claude/commands/plan-tdd.md

plan-tdd is a command for Claude Code from pproenca/agent-tui. It costs 13 tokens per session (2,788 once invoked), scanned A, original, MIT.

A command that turns a feature description into a detailed task list using test-driven development (TDD), where tests are written before the code. It splits work into small, independently demonstrable steps and records task dependencies.

In plain words
What is it for?
Use it to plan features from a specification, brainstorming document, or codebase exploration. It helps organize tests, implementation, and integration work into a dependency-aware checklist.
Why use it?
It removes the need to work out the full implementation sequence by hand. The small steps and test-first order make long coding sessions easier to track.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool.

This is pproenca/agent-tui's own configuration. It tells Claude Code how to work on agent-tui itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything agent-tui configures →

Reuse

Borrowing it

Nothing to install: this file belongs to pproenca/agent-tui. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/pproenca/agent-tui/master/.claude/commands/plan-tdd.md
Clone the repo
git clone --depth 1 https://github.com/pproenca/agent-tui

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for plan-tdd

README.md
[![agentmods](https://agentmods.dev/badge/commands/pproenca/agent-tui/plan-tdd/github.svg)](https://agentmods.dev/commands/pproenca/agent-tui/plan-tdd)
Your own site
<a href="https://agentmods.dev/commands/pproenca/agent-tui/plan-tdd"><img src="https://agentmods.dev/badge/commands/pproenca/agent-tui/plan-tdd/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for plan-tdd

Your own site · 80×15
<a href="https://agentmods.dev/commands/pproenca/agent-tui/plan-tdd"><img src="https://agentmods.dev/badge/commands/pproenca/agent-tui/plan-tdd.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 13 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,788 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What 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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00013 $0.02788
Opus 5.5 $0.00005 $0.01115
Sonnet 5.5 $0.00003 $0.00558
Haiku 4.5 $0.00001 $0.00279

Measured 2mo ago against content hash 8ef72512a7f7, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

plan-tdd 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 2mo 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.

.claude/commands/plan-tdd.md · 363 lines

How it starts

The opening of the file, as written. The whole thing — 363 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TDD Task Planning Command

Create an extensive, detailed task list using TDD methodology with carpaccio-style slicing. This command is designed for long coding sessions where comprehensive tracking is essential.

Artifact Chain

This command is part of the brainstorm → spec → plan pipeline:

.claude/specs/<feature-name>/
├── brainstorm.md    ← From /brainstorm (optional)
├── spec.md          ← From /spec (recommended input)
└── plan-summary.md  ← Output: task plan summary

Input Priority:

  1. If .claude/specs/<feature-name>/spec.md exists → use it as primary input
  2. If .claude/specs/<feature-name>/brainstorm.md exists → use it (less structured)
  3. If neither exists → gather requirements interactively or explore codebase

Core Principles

1. Carpaccio Slicing

Every task must be:

  • Atomic: Completable in a single focused action (< 30 min of work)
  • Demonstrable: Has visible, verifiable output
  • Valuable: Delivers a small increment of functionality
  • Vertical: Touches all necessary layers (test → impl → integration)

2. TDD Workflow (Red-Green-Refactor)

For every feature, create this task chain:

  1. RED - Write failing test(s) first
  2. GREEN - Implement minimal code to pass
  3. REFACTOR - Clean up while keeping tests green

3. Dependency Chains

Use addBlockedBy to enforce:

  • Test tasks block their implementation tasks
  • Implementation tasks block refactor tasks
  • Earlier phases block later phases

Execution Flow

Step 1: Load Context from Artifact Chain

Extract feature name from argument: $ARGUMENTS

Check for existing artifacts in order:

1. .claude/specs/<feature-name>/spec.md      → Full specification (best)
2. .claude/specs/<feature-name>/brainstorm.md → Raw ideas (usable)
3. Neither exists                             → Interactive mode

If spec.md exists:

  • Read the entire specification
  • Extract: success criteria, scope, architecture decisions, interfaces, testing strategy
  • Use these directly to inform task creation
  • Skip most interactive questions (spec has answers)

Read the full file on GitHub · 363 lines

Changes

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.

  1. 2mo ago First seen · 363 lines · 13 tokens per session scan A 8ef72512a7f7

Subscribe to this mod's changes

plan-tdd is a command published in the GitHub repository pproenca/agent-tui (122 stars, last pushed 8d ago), licensed MIT. It adds 13 tokens to every session and 2,788 once invoked, about $0.0001 per session on Opus 5.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.