fd-execute

A command that carries out a confirmed implementation plan using test-driven development, or TDD: writing and checking tests as part of the coding process.

In plain words
What is it for?
Use it to execute planned implementation steps with worktree safety checks, dependency-impact reviews, delegated agents, tests, and checkpoints.
Why use it?
It organizes multi-step changes into waves, checks the affected code and dependencies, and saves progress after each wave.

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/dvnghiem/flowdeck/fd-execute
Clone the repo
git clone --depth 1 https://github.com/DVNghiem/FlowDeck
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 2,069 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.02069
Opus 5 $0.00013 $0.01035
Sonnet 5 $0.00005 $0.00414
Haiku 4.5 $0.00003 $0.00207

Measured yesterday against content hash 02aac65fb62a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

fd-execute 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 yesterday.

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.

docs/commands/fd-execute.md · 243 lines

How it starts

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

Execute

Implement the confirmed plan using the FlowDeck TDD agent pipeline.

Input: $ARGUMENTS — optional --topic=<slug> to target a topic other than the active one, --override to bypass guards, --keep-worktree to skip worktree cleanup after merge.

Pre-flight: Research Gate

Before reading plan.md or touching any code, re-verify the execution context.

Research scope: execute

Graph freshness check (MUST run before any worktree is created):

  • Run fdx-graph action:status. Stale → run fdx-graph action:build.
  • Use fdx-graph action:impact target:<file> to confirm the affected file scope before each implementation step.
  • Before delegating to a subagent, run fdx-graph action:impact on the target file and include the result in the subagent's context packet under "Blast radius".

You are the single writer for action:build. Subagents use read actions only — fdx graph build does not wait on lock contention, so a parallel wave that all tried to build would have every agent but one told "another build is in progress".

Artifact validation (MUST run both before any worktree is created):

  1. fdx-validate action:artifacts topic:<topic> — artifact format check
  2. fdx-validate action:pre-execute topic:<topic> — file existence + freshness check

If either returns valid: false → STOP and show errors. Both MUST pass before execution proceeds.

Standard pre-flight (always):

  1. Read ~/.fd-plan/<slug>/STATE.md — verify plan_confirmed, active topic, freshness
  2. Read ~/.fd-plan/<slug>/.codebase/CODEBASE_INDEX.md if available — file changes since the plan was written
  3. Check for research_execute evidence in STATE.md from a prior pass

If existing research is fresh (summaryVersion matches, state fresh within 5 min), reuse it and log "Research skipped — fresh evidence reused from prior pass". Otherwise run a fresh pass and persist the result.

Guard Check

Resolve <topic> from --topic, else from topic in STATE.md.

Read the full file on GitHub · 243 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. yesterday First seen · 243 lines · 0 tokens per session scan A 02aac65fb62a

Subscribe to this mod's changes

fd-execute is a command published in the GitHub repository DVNghiem/FlowDeck (24 stars, last pushed 13d ago), licensed MIT. It adds 25 tokens to every session and 2,069 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.