tdd-task

A command for implementing a GitHub Task through a Test-Driven Development (TDD) loop, then updating the issue and opening a pull request.

In plain words
What is it for?
Use it to select a Task, create a branch, make and test the changes, record meaningful progress on the issue, and create a pull request that closes the Task.
Why use it?
It keeps task work traceable and enforces project rules such as using a feature branch and providing a runnable test command.

Command

Install

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.

agentmods
npx agentmods add commands/el-feo/ai-context/tdd-task
Clone the repo
git clone --depth 1 https://github.com/el-feo/ai-context
Per session 25 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,060 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00025 $0.03060
Opus 5 $0.00013 $0.01530
Sonnet 5 $0.00005 $0.00612
Haiku 4.5 $0.00003 $0.00306

Measured 2d ago against content hash 03e3e8aa62bf, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

tdd-task 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.

plugins/ghpm/commands/tdd-task.md · 419 lines

How it starts

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

Resolution order if omitted:

  1. If branch name matches ghpm/task-<N>-* or task-<N>-*, use N
  2. Most recent open issue labeled Task assigned to @me: gh issue list -l Task -a @me -s open --limit 1 --json number -q '.[0].number'
  3. Most recent open Task: gh issue list -l Task -s open --limit 1 --json number -q '.[0].number'

<usage_examples> With task number:

/ghpm:tdd-task task=#42

With focus hint:

/ghpm:tdd-task task=#42 focus=unit

Auto-resolve from branch:

# On branch: ghpm/task-42-add-auth
/ghpm:tdd-task

Auto-resolve from GitHub:

# No arguments - uses most recent assigned Task
/ghpm:tdd-task

</usage_examples>

<operating_rules>

  • Always create a feature branch before making changes. Never commit directly to main/master.
  • No local markdown artifacts. Do not write local status files; only code changes + GitHub issue/PR updates.
  • Do NOT use the TodoWrite tool to track tasks during this session.
  • Do not silently expand scope. If you must, create a new follow-up Task issue and link it.
  • Always provide a runnable test command in the final notes.
  • Minimize noise: comment at meaningful milestones.
  • All commits and PR titles MUST follow Conventional Commits format for changelog generation. </operating_rules>

<conventional_commits>

Conventional Commits Format

All commits and PR titles must follow the Conventional Commits specification to enable automated changelog generation.

Format

Read the full file on GitHub · 419 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. 2d ago First seen · 419 lines · 25 tokens per session scan A 03e3e8aa62bf

Subscribe to this mod's changes

tdd-task is a command published in the GitHub repository el-feo/ai-context (12 stars, last pushed 1mo ago), licensed MIT. It adds 25 tokens to every session and 3,060 once invoked, about $0.0001 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.