harness-plan

harness-plan is a command for Claude Code from kimsanguine/hplan. It costs 49 tokens per session (4,288 once invoked), scanned A, original, MIT.

A command for designing an agent system’s technical architecture and strategy before development. It covers how agents work together, system layers, memory, model selection, and the architecture document.

In plain words
What is it for?
Use it to plan orchestration, a three-layer design, memory handling, model routing, or a strategy review for an agent-based product.
Why use it?
It turns a product idea that has passed initial checks into a structured build plan. Separate modes let you work on one planning area or the full sequence.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: mentions subagents.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python3 hplan/scripts/decision_log.py hitl \.

Part of the hplan plugin — 8 skills, 11 commands, 4 agents shipped together

Good fit Use it to plan orchestration, a three-layer design, memory handling, model routing, or a strategy review for an agent-based product.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/kimsanguine/hplan
agentmods
npx agentmods add commands/kimsanguine/hplan/harness-plan

Made for: Claude Code.

Or install hplan, the plugin that ships this one along with the rest of its 8 skills, 11 commands, 4 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 harness-plan

README.md
[![agentmods](https://agentmods.dev/badge/commands/kimsanguine/hplan/harness-plan.svg)](https://agentmods.dev/commands/kimsanguine/hplan/harness-plan)
Your own site
<a href="https://agentmods.dev/commands/kimsanguine/hplan/harness-plan"><img src="https://agentmods.dev/badge/commands/kimsanguine/hplan/harness-plan.svg" alt="Measured on agentmods" height="20"></a>
Per session 49 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 4,288 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.00049 $0.04288
Opus 5 $0.00024 $0.02144
Sonnet 5 $0.00010 $0.00858
Haiku 4.5 $0.00005 $0.00429

Measured 7d ago against content hash c33b7dbd6172, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

harness-plan 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 7d 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.

hplan/commands/harness-plan.md · 352 lines

How it starts

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

/harness-plan

에이전트 시스템 기술 아키텍처 전체 설계 + 전략 리뷰

Routing

$ARGUMENTS에서 --mode 플래그를 파싱한다.

플래그 실행 범위
--mode orchestration Phase 1만 실행
--mode 3-tier Phase 2만 실행
--mode memory Phase 3만 실행
--mode routing Phase 4만 실행
--mode review Phase 5(Strategy Review)만 실행
플래그 없음 Phase 1 → 2 → Checkpoint → 3 → 4 → Architecture Doc 전체 실행 (Phase 5는 별도 호출)

Instructions

You are designing Technical Architecture and Strategy Plan for: $ARGUMENTS

플래그가 있으면 해당 Phase만 실행한다. 플래그가 없으면 아래 전체 플로우를 순서대로 실행한다.


Planning Disciplines (v0.9.6)

Phase 진입 전 아래 3개 규율을 명시적으로 적용한다.

G2 — Named Artifacts: Phase 시작 직후, 이 Phase의 산출물 파일명·섹션명을 먼저 선언한다.
→ 파일명 없이 "설계를 진행하겠습니다"라고 시작하면 규율 위반.

G3 — Decision Commit: 모든 HITL 결정 지점에서 옵션 3개 이상 제시 → 정확히 1개에 커밋.
→ "A 또는 B 방향으로 갈 수 있습니다" 같은 미결 처리 금지. decision_log.py hitl 기록 필수.

G4 — Phase Context Budget: 각 Phase는 해당 Phase에 필요한 파일만 로드한다 (최대 3개).
→ Phase 시작 전 전체 프로젝트 파일 일괄 Read 금지. 필요한 것만 Just-in-Time 로드.

Phase Named Artifact Context Budget (최대)
1 Orchestration decisions/orchestration-choice.md 또는 decision_log 항목 없음 (신규 설계)
2 3-Tier harness/ARCHITECTURE.md — Tier 섹션 Phase 1 결정 1개
3 Memory harness/ARCHITECTURE.md — Memory 섹션 Tier 설계 1개
4 Routing harness/ARCHITECTURE.md — Routing 섹션 Memory 설계 1개
Architecture Doc harness/ARCHITECTURE.md 완성본 Phase 1–4 결정 요약

Phase 1 — Orchestration Pattern Selection

--mode orchestration 또는 전체 플로우

: 에이전트 여러 개를 어떻게 연결할지는 나중에 바꾸기 어렵습니다. 시작 전에 Sequential·Parallel·Router·Hierarchical 중 어떤 패턴이 맞는지 결정합니다.

4가지 오케스트레이션 패턴을 사용 사례에 대입해 평가한다.

Orchestration (오케스트레이션): 여러 에이전트가 어떤 순서와 방식으로 협력할지 설계하는 것입니다. 사람 조직의 업무 프로세스 설계와 같은 개념입니다.

Pattern Best When Drawback
Sequential 각 스텝이 이전 결과에 의존하고 순서가 고정된 경우 느림; 단일 장애 지점
Parallel 독립적인 서브태스크를 동시에 실행할 수 있는 경우 결과 집계가 복잡해짐
Router 입력 유형에 따라 서로 다른 처리 경로가 필요한 경우 라우터 자체가 병목이 됨
Hierarchical 복잡한 태스크에 계획 레이어와 실행 레이어 분리가 필요한 경우 복잡도·비용 최고

Read the full file on GitHub · 352 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. 7d ago First seen · 352 lines · 49 tokens per session scan A c33b7dbd6172

Subscribe to this mod's changes

harness-plan is a command published in the GitHub repository kimsanguine/hplan (2 stars, last pushed 21d ago), licensed MIT. It adds 49 tokens to every session and 4,288 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.