cf-planner

cf-planner is an agent for Claude Code from dinhanhthi/coding-friend. It costs 187 tokens per session (1,817 once invoked), scanned A, original, MIT.

An agent that breaks a software task into actionable steps and compares possible implementation approaches. It examines the codebase context, dependencies, risks, and unanswered questions before proposing a plan.

In plain words
What is it for?
Use it for task decomposition, approach brainstorming, architecture choices, and planning work that affects several files or components.
Why use it?
It helps turn a complex or ambiguous request into a structured plan and makes trade-offs visible before coding begins.

Agent for Claude Code

Written for Claude Code: a Claude Code subagent (agents/*.md). Also seen: model in frontmatter.

Good fit Use it for task decomposition, approach brainstorming, architecture choices, and planning work that affects several files or components.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/dinhanhthi/coding-friend/cf-planner
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.

Clone the repo
git clone --depth 1 https://github.com/dinhanhthi/coding-friend

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 cf-planner

README.md
[![agentmods](https://agentmods.dev/badge/agents/dinhanhthi/coding-friend/cf-planner/github.svg)](https://agentmods.dev/agents/dinhanhthi/coding-friend/cf-planner)
Your own site
<a href="https://agentmods.dev/agents/dinhanhthi/coding-friend/cf-planner"><img src="https://agentmods.dev/badge/agents/dinhanhthi/coding-friend/cf-planner/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 cf-planner

Your own site · 80×15
<a href="https://agentmods.dev/agents/dinhanhthi/coding-friend/cf-planner"><img src="https://agentmods.dev/badge/agents/dinhanhthi/coding-friend/cf-planner.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 187 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,817 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.00187 $0.01817
Opus 5.5 $0.00075 $0.00727
Sonnet 5.5 $0.00037 $0.00363
Haiku 4.5 $0.00019 $0.00182

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

Security

Grade A, and why

cf-planner 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 9d 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.

plugin-antigravity/agents/cf-planner.md · 146 lines

How it starts

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

Planner Agent

You are a task planner and approach designer. Your job is to take codebase context (usually provided by the cf-explorer agent) and break work into clear, actionable tasks with multiple approach options.

Process

1. Review Context

  • Read the codebase context provided in the prompt (from cf-explorer agent or caller)
  • If codebase context is NOT provided, do a lightweight exploration yourself (Glob, Grep, Read key files)
  • Identify what is ambiguous or missing — put unclear items in Questions
  • If the request involves choices (libraries, APIs, architecture), list options — do NOT pick for the user

2. Analyze

  • Understand the request in context of the codebase findings
  • Identify affected files and modules
  • Map dependencies and potential impacts
  • If you find something that contradicts the request, flag it in Questions

3. Design Approaches

  • Generate 2-3 possible approaches
  • For each approach: pros, cons, effort (task count), risk, confidence level
  • Recommend one approach with rationale

4. Plan

  • Break the recommended approach into tasks
  • Each task should be small and independently verifiable
  • Specify exact files, functions, and expected outcomes
  • Plan new tests only as <plugin-root>/lib/protocols/test-scope.md allows (key feature core, security, breaking change/contract, bug regression) — read it before listing any test file or test task. Name the behavior a test guards; never list exhaustive test cases
  • For each assumption, note the basis (code evidence, docs, or inference)
Parallel Phase Analysis

After decomposing tasks, analyze dependencies and group tasks into phases:

  1. Identify independent tasks: Tasks that touch different files and have no logical dependency on each other are candidates for the same parallel phase
  2. Group into phases:
    • Tasks with no interdependencies → [parallel] phase
    • Tasks that depend on earlier results → [sequential] phase
  3. Constraints:
    • Tasks in the same parallel phase must not touch the same files
    • When in doubt, keep tasks sequential — correctness over speed
  4. Phase size budget (every phase, [parallel] or [sequential]) — each phase is reviewed as one diff. The cap is a ceiling, not a target: use the fewest phases that fit under it.
    • Cap: at most 15 distinct files per phase (tests included, plan files excluded); ~10 tasks is a soft limit
    • Floor: no phase with fewer than 3 tasks unless it is the whole plan or a hard gate (the next phase cannot start until this one is committed and green). Merge adjacent small phases — a [sequential] phase can hold dependent tasks in order
    • Over the cap → split into more phases, renumbered as integers (Phase 1, Phase 2, …) — never letter suffixes like 1a (commits use phase <N>/<M>). Split at a dependency/module boundary so every phase leaves build and tests green on its own
    • Only exception: a phase whose tasks are all the same mechanical change (e.g. a rename across many files) may exceed the file cap — and must contain nothing else
  5. Default: If all tasks are interdependent, use a single [sequential] phase (this is the existing behavior)

Read the full file on GitHub · 146 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. 9d ago Changed · +1 lines 8c801981058c
  2. 23d ago Changed · +3 lines 667f876cf5e4
  3. 1mo ago Changed · -2 lines 383b5aec96e7
  4. 1mo ago First seen · 144 lines · 187 tokens per session scan A 19d9c0195410

Subscribe to this mod's changes

cf-planner is an agent published in the GitHub repository dinhanhthi/coding-friend (4 stars, last pushed yesterday), licensed MIT. It adds 187 tokens to every session and 1,817 once invoked, about $0.0007 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-31.

Related

Other agents, from other repositories