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.
git clone --depth 1 https://github.com/studioKjm/ai-harness-templatenpx agentmods add commands/studiokjm/ai-harness-template/migrate-trafficWrote 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.
[](https://agentmods.dev/commands/studiokjm/ai-harness-template/migrate-traffic)<a href="https://agentmods.dev/commands/studiokjm/ai-harness-template/migrate-traffic"><img src="https://agentmods.dev/badge/commands/studiokjm/ai-harness-template/migrate-traffic.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00028 | $0.00550 |
| Opus 5 | $0.00014 | $0.00275 |
| Sonnet 5 | $0.00006 | $0.00110 |
| Haiku 4.5 | $0.00003 | $0.00055 |
Grade A, and why
migrate-traffic 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 8d 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.
How it starts
The opening of the file, as written. The whole thing — 70 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/migrate-traffic — Advance to Migrate Phase
Expand → Migrate 전환
When to use
- After verifying with
/expand <id>that both old and new coexist - When ready to start switching callers from old to new (one PR at a time)
Prerequisites
- Plan in
phase=expand - Both
old.caller_patternandnew.caller_patternregistered - Both patterns currently match in the codebase
Usage
/migrate-traffic <plan-id>
Instructions
Step 1 — Run advance
python3 .harness/methodologies/parallel-change/scripts/pc.py advance <plan-id> migrate
The script:
- Validates both
caller_patterns are set - Counts callers of old (must be > 0) and new (must be > 0)
- If valid: updates
phases.current = "migrate"and appends to history - If invalid: refuses transition with reason
Step 2 — Report
On success:
"Plan {id}: expand → migrate. Now switch callers one at a time. The state gate enforces both old and new continue to exist until /contract."
On failure (script's stderr will explain):
- "old signature has 0 callers" → either migration done out-of-band (advance to contract instead) or pattern wrong
- "new signature not found" → implement new alongside old before transitioning
Step 3 — Migration guidance
After advancing to migrate, instruct the user on the workflow during this phase:
"Migrate phase rules:
- Switch callers from old → new in small commits (per consumer or per PR)
- Each commit must keep both old and new working (state gate enforces this)
- When all callers migrated and
pc.py callers <id>shows 0 for old, run/contract"
Constraints
- Cannot skip from expand to contract — must pass through migrate
- Cannot return to expand once advanced (state machine is forward-only; revert requires manual yaml edit)
- The migrate phase is where most of the work happens — it can take days/weeks. Plans stay open until /contract.
Side effects
- Plan file
phases.currentchanges tomigrate - Plan file
phases.historygains an entry - Plan file
last_check.timestampupdated - No code changes — this is purely a state transition
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.
- 8d ago First seen · 70 lines · 28 tokens per session scan A 2b6f641bdf3c
migrate-traffic is a command published in the GitHub repository studioKjm/ai-harness-template (43 stars, last pushed 3mo ago), licensed MIT. It adds 28 tokens to every session and 550 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.
Other commands, from other repositories
capture-feedback
Quick feedback capture with structured signals.
show-lessons
Display promoted lessons and their corrective actions.
harness-review
Review the current change set from an opposing harness-engineering perspective.
step0-specify-feature
Pipeline Step 0 — Specify what you want to build and why, before any technical planning. Surfaces ambiguities early with [NEEDS CLARIFICATION] markers.
harness-update
Update a target repository's harness from the latest harness-starter-kit reference material.
harness-doctor
Run Harness Doctor to evaluate how ready the current repository is for reliable AI coding agent collaboration.