tp-task-cycle

tp-task-cycle is a skill for Claude Code, Codex from CurtisThe/three-pillars-plugin. It costs 36 tokens per session (1,103 once invoked), scanned A, original, Apache-2.0.

A workflow for one red-green-refactor cycle in test-driven development, or TDD. TDD means writing a failing automated test, making the code pass, and then improving the code without changing its behavior.

In plain words
What is it for?
Implement one task from a design plan, write its failing test, make the test pass, and refactor the result.
Why use it?
It gives a coding task a small, repeatable implementation loop with a test as the check. This makes it easier to verify behavior before and after the code changes.

Skill for Claude CodeCodex

Part of the three-pillars plugin — 37 skills, 20 agents shipped together

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 skills/curtisthe/three-pillars-plugin/tp-task-cycle
Any agent
npx skills add CurtisThe/three-pillars-plugin --skill tp-task-cycle
Clone the repo
git clone --depth 1 https://github.com/CurtisThe/three-pillars-plugin

Made for: Claude Code, Codex.

Or install three-pillars, the plugin that ships this one along with the rest of its 37 skills, 20 agents.

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 tp-task-cycle

README.md
[![agentmods](https://agentmods.dev/badge/skills/curtisthe/three-pillars-plugin/tp-task-cycle.svg)](https://agentmods.dev/skills/curtisthe/three-pillars-plugin/tp-task-cycle)
Your own site
<a href="https://agentmods.dev/skills/curtisthe/three-pillars-plugin/tp-task-cycle"><img src="https://agentmods.dev/badge/skills/curtisthe/three-pillars-plugin/tp-task-cycle.svg" alt="Measured on agentmods" height="20"></a>
Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,103 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.00036 $0.01103
Opus 5 $0.00018 $0.00551
Sonnet 5 $0.00007 $0.00221
Haiku 4.5 $0.00004 $0.00110

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

Security

Grade A, and why

tp-task-cycle 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 4d 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.

skills/tp-task-cycle/SKILL.md · 74 lines

How it starts

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

Red-Green-Refactor

Execute one TDD cycle for a single task.

Argument: Either a task description in plain text, OR a {design-name} followed by a task ID (e.g., my-feature 2.3 for Phase 2, Task 3).

Steps

Preflight

  1. Run first-run preflight per skills/_shared/first-run.md.

  2. If a {design-name} was provided, run the collaboration preflight per skills/_shared/collaboration.md with phase: "implement". This verifies the branch and lock before writing code. Honor --force-takeover if passed. If invoked standalone with only a description (no design name), skip this step.

Red — Write a Failing Test

  1. If a task ID was given, read the task from three-pillars-docs/tp-designs/{design-name}/plan.md to get the file, test, and assertion details.
  2. Write the test exactly as specified. Import the module/function being tested even though it may not exist yet.
  3. Run the test and confirm it fails. Acceptable failures are language-dependent but generally:
    • Missing import / module not found (function doesn't exist yet)
    • Assertion failure (function exists but doesn't behave correctly)
    • Missing attribute / method not found (class exists but method doesn't)
  4. If the test passes, something is wrong — the behavior already exists or the test is vacuous. Stop and flag this to the user.

Green — Make It Pass

  1. Write the minimal implementation that makes the test pass. Minimal means:
    • No extra methods, parameters, or branches beyond what the test exercises.
    • No error handling for cases the test doesn't cover.
    • Hard-coded return values are OK if that's all the test needs (the next test will force generalization).
  2. Run the test and confirm it passes.
  3. If it fails, fix the implementation (not the test, unless the test has a bug). Iterate until green.
  4. Run the broader test suite for the file/module to check for regressions via the fast iteration lane: CMD=$(python3 "$TP_ROOT"/skills/_shared/iteration_lane.py --lane iteration --granularity task) then $CMD 2>&1 | tee "$(mktemp /tmp/test_output.XXXXXX.log)". The seam resolves the fast unit subset in the dev repo and the project-discovered command in a consumer repo. If it resolves nothing (non-zero exit), discover the runner from CLAUDE.md / Makefile / package.json / pyproject.toml as before — never tee an empty command as green.

Read the full file on GitHub · 74 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. 4d ago First seen · 74 lines · 36 tokens per session scan A 6ba944347ba6

Subscribe to this mod's changes

tp-task-cycle is a skill published in the GitHub repository CurtisThe/three-pillars-plugin (4 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 36 tokens to every session and 1,103 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-31.

Related

Other skills, from other repositories

tdd

Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.

GreyDGL/PentestGPT · 33 tokens

agentic-testing

MANDATORY before creating, editing, or reviewing tests in agentic.nvim, and before behavior changes that require TDD. Covers mini.test workflow, red/green rules, commands, mark-count checks, and which test references to load.

carlos-algms/agentic.nvim · 51 tokens

test-first-bugs

Enforces a test-driven bug-fixing workflow. Use when a user reports a bug, failing code, an error, or asks to fix something.

jamditis/claude-skills-journalism · 35 tokens

tdd

Test-driven development (TDD) process used when writing code. Use whenever you are adding any new code, unless the user explicitly asks to skip TDD or the code is exploratory/spike.

lexler/skill-factory · 42 tokens

growing-outside-in-systems

Drive feature development using Outside-In TDD with Hexagonal Architecture. Design emerges through inline code, in-memory fakes, interface extraction, and deferred I/O. Use when building features, writing tests, or structuring backend services. Triggers on: TDD, outside-in, hexagonal, ports and adapters, emergent…

lexler/skill-factory · 122 tokens

plan-create

Create structured implementation plans for autonomous TDD development. Use for new features, multi-file changes, or anything requiring multiple steps or tests. Triggers on aspirational openers ("let's build", "let's start building", "I want to make", "I want an app that", "help me build"), capability lists ("users…

markshust/hcf · 171 tokens