From corso
Internal phase 6 of the C0RS0 Pack Build Cycle. Accepts approved plan files, loads MANIFEST state, executes phases with HITL phase gates and feedback loops, enforces quality gates, and tracks progress via scratchpad. Supports session recovery and kill switch. Invoked by /CORSO — not a standalone entry point.
How this skill is triggered — by the user, by Claude, or both
Slash command
/corso:HUNTThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
> Build Phase 6/7: SHIP — The pack executes. Phase gates enforce quality at every step.
Build Phase 6/7: SHIP — The pack executes. Phase gates enforce quality at every step.
Follows SCOUT (plan) -> loads domain context in lifecycle order -> feeds into SCRUM (review).
Always Phase 6. Accepts an approved plan file, loads MANIFEST state, executes phases with HITL phase gates, enforces quality gates with feedback loops, and maintains a scratchpad for session recovery.
/HUNT .corso/plans/{id}.md # Execute an approved plan
/HUNT --trust .corso/plans/{id}.md # Skip HITL normalization for non-SCOUT plans
/HUNT --resume # Resume from last MANIFEST state
/HUNT --abort # Trigger kill switch
| Source | Typical Path | Generated By |
|---|---|---|
| SCOUT | .corso/plans/{id}.md | /SCOUT skill |
| Claude plan mode | ~/.claude/plans/{id}.md | Claude Code EnterPlanMode |
| Hand-written | any .md path | User |
No raw specs. If you have a task but no plan, use /SCOUT first.
plan_id from the plan's frontmatter.~/.soul/helix/corso/builds/active.yaml first, fall back to .corso/manifest.yaml.
active: list by matching plan_idpath fieldapproved -> proceed to validation (normal path)executing -> RESUME from last completed phaseaborted -> ask user: restart or abandon?active: list.storage.scratchpad_pathMANIFEST immutability rule: Once execution begins (status: executing), only HUNT (via Claude) writes to MANIFEST. Hooks read only. No concurrent writers.
Build isolation rule: This build operates in complete isolation from any other active builds. Do not read, reference, or coordinate with other builds' manifests, scratchpads, or artifacts. The only exception is when the user explicitly requests cross-build coordination. Without that instruction, treat this build as if it's the only one running.
Detect the plan source:
.corso/plans/ prefix -> SCOUT-generated (expect gold standard format)~/.claude/plans/ prefix -> Claude-generated (may need normalization).md path -> hand-written (likely needs normalization)Check plan for gold standard elements:
| Element | Required | Check |
|---|---|---|
| YAML frontmatter | Yes | plan_id, domain, risk_level, tier present |
| Phase structure | Yes | Ordered phases with names |
| MCP tool assignments | Yes | Each phase maps to tools |
| Acceptance criteria | Yes | Each phase has checkboxed criteria |
| Risk assessment | Yes | HIGH / MEDIUM / LOW with indicators |
| Dependency graph | Yes | depends_on chains, acyclic |
| Dependency metadata | Yes | Each phase has depends_on (list or explicit "none") |
| Security phase | Conditional | Present when tier >= MEDIUM |
If gaps found:
AskUserQuestion. Ask user for approval before normalizing. Add missing elements while preserving all original features.--trust): Auto-normalize, preserve all features, log changes to scratchpad.Feature preservation rule: Every feature in the original plan MUST appear in the normalized plan. Features may be reorganized between phases but never deleted.
Dependency inference (when depends_on chains are missing):
depends_on: [phase_ids] or depends_on: noneBefore a single file changes, register ALL phases and tasks as Claude Code tasks. This creates a live task board visible throughout the session — the pre-execution TUI view. Every sibling, every agent, and the user can see the complete execution plan with dependencies before anything starts.
Skip if: Plan has only 1 phase with no task decomposition (single task, execute directly in Step 4).
For each phase in the validated plan, call TaskCreate:
subject: "Phase {N}: {phase_name}" (e.g., "Phase 2: Core Logic")description: Phase objective + acceptance criteria list + domain module + depends_on phasesactiveForm: "Executing Phase {N}: {phase_name}"Store the returned task ID in MANIFEST phases[N].tui_task_id.
For each intra-phase task from ### Tasks sections, call TaskCreate:
subject: "Task {N.M}: {task_name}" (e.g., "Task 2.3: Define RateLimitConfig")description: Task-specific criteria + files to create/modify + wave assignmentactiveForm: "Running Task {N.M}: {task_name}"Store the returned task ID in MANIFEST phases[N].tasks[M].tui_task_id.
Call TaskUpdate with addBlockedBy to express the full dependency graph:
tui_task_id of its depends_on phasestui_task_id of its depends_on tasks within the phaseThe task board is now live in the Claude Code UI. In HITL mode, confirm with user via AskUserQuestion:
Question: "Task board registered — {N} phases, {M} tasks, {W} waves. Ready to execute?"
Header: "Task Board"
Options:
1. "Execute" — "Start Wave 1 now"
2. "Review board first" — "Show TaskList summary before starting"
3. "Adjust plan" — "Return to Step 2 to modify"
4. "Abort" — "Kill switch"
In Trust mode: Auto-proceed, log task registration to scratchpad.
Update MANIFEST:
tui:
registered: true
registered_at: "{ISO timestamp}"
phase_count: {N}
task_count: {M}
Completion promise: TUI_REGISTERED:{N}_phases_{M}_tasks
Analyze the validated plan's dependency graph and group independent phases into parallel waves for concurrent execution via Task agents.
Skip if: Plan has only 1 phase (execute directly in Step 4).
depends_on chains (populated by Step 2 normalizer)Example:
Wave 1: [Phase 1 (research), Phase 2 (scaffold)] — independent, parallel
Wave 2: [Phase 3 (core logic)] — depends on Wave 1
Wave 3: [Phase 4 (security), Phase 5 (testing)] — independent, parallel
If the plan includes intra-phase task decomposition (generated by SCOUT for tier >= MEDIUM), apply a second level of parallelization within each decomposed phase:
### Tasks section, parse the task dependency graphphases[N].tasks and phases[N].task_wavesTwo-level decomposition example:
Phase Wave 1: [Phase 1, Phase 2] — inter-phase parallelism
Phase 1, Task Wave 1: [1.1, 1.2] — intra-phase parallelism
Phase 1, Task Wave 2: [1.3] — depends on 1.1, 1.2
Phase 2, Task Wave 1: [2.1, 2.2, 2.3] — intra-phase parallelism
Phase 2, Task Wave 2: [2.4, 2.5] — depends on 2.1-2.3
Phase Wave 2: [Phase 3] — depends on Phases 1, 2
Phase 3: (no task decomposition) — executes as single unit
Phases WITHOUT task decomposition execute as a single unit (current behavior). The two levels are fully independent — a plan can have inter-phase waves only, intra-phase waves only, or both.
| Phase Type | Budget |
|---|---|
| Research/Discovery | 30-60m |
| Foundation/Scaffold | 45m |
| Core Features | 90m |
| Domain Features | 90m |
| Quality Gates | 45m |
| Integration Verify | 30m |
| Deploy | 30m |
Total budget: ~7h agent time -> 4-5h wall clock with parallelization.
150% Overrun Rule: If any phase exceeds 150% of its budget, STOP and present HITL checkpoint via AskUserQuestion:
Present decomposition to user via AskUserQuestion before execution begins:
Update MANIFEST:
decomposition:
strategy: parallel | sequential | single-phase
waves: [{wave: 1, phases: [1, 2], agents: 2, estimated_minutes: 60}, ...]
approved_at: "{ISO timestamp}"
Completion promise: DECOMPOSITION_APPROVED
For each wave:
subagent_type: "general-purpose")TaskOutput — check for 150% overrun per phaseSingle-phase fallback: Execute directly in Step 4 (no Task agent overhead).
Trust mode: Auto-approve decomposition strategy, skip HITL gate in 3d.
Update MANIFEST: status: executing
Populate MANIFEST phases array from plan. Execute phases in dependency order.
Multi-domain execution order follows the build cycle:
FETCH (research) -> SNIFF (lint) -> GUARD (audit) -> CHASE (test)
-----------------------------------------------------------------
Understand Analyze Secure Verify
For multi-domain plans, HUNT loads domain context and executes phases in this order. Single-domain plans execute directly.
Pack Voice Delivery: At each phase transition, read the matching quip from MANIFEST pack_voice.quips.{phase_key} and deliver it:
> "{quip}" — CORSO 🐺mcp__SOUL__soulTools with action: "speak", params: { text: "{quip}", voice_id: "2ajXGJNYBR0iNHpS4VZb" } (CORSO voice: Rob)voice_id: "sB7vwSCyX0tQmU24cW2C" (Claude voice: Jon)voice_id: "lcMyyd2HUfFzxdCaC4Ta" (EVA voice: Lucy)For each phase:
Present phase summary via AskUserQuestion:
Options:
Update MANIFEST: phases[N].approved: true, phases[N].status: in_progress
Mark the Claude Code task for this phase as in_progress:
TaskUpdate(phases[N].tui_task_id, { status: "in_progress" })
For decomposed phases: also mark the first intra-phase task wave's tasks as in_progress:
TaskUpdate(phases[N].tasks[wave1_task_id], { status: "in_progress" })
Read the domain module SKILL.md for intelligence tables relevant to this phase:
| Build Phase | Skill Module | Key Intelligence |
|---|---|---|
| 2. research | FETCH | Research scope, documentation sources, decision factors, trade-off analysis |
| 3. lint | SNIFF | Coding standards, quality metrics, code smells, architecture patterns |
| 4. audit | GUARD | Threat models, language-specific threats, supply chain gates |
| 5. test | CHASE | Test strategy, bottleneck detection, performance metrics |
Use mcp__C0RS0__corsoTools with action: "read_file" to load full domain module when deep context is needed. Domain modules live at skills/{NAME}/SKILL.md within the plugin.
Call the tools assigned to this phase per the plan.
Code Generation: For coding phases (Foundation, Core Logic, Integration, Remediation, etc.),
HUNT uses mcp__C0RS0__corsoTools with action: "sniff" to generate code. Load SNIFF domain context first for coding
standards and quality patterns — then generate code that meets those standards.
SNIFF provides the quality context; HUNT does the generation.
Task-Level Execution (for phases with ### Tasks):
Instead of executing the phase as a single unit, iterate through task waves:
subagent_type: "general-purpose")TaskOutput — check for 150% overrun per taskphases[N].tasks[M].status: completed, phases[N].tasks[M].completed_atTask agent prompt includes:
Single-unit fallback: Phases without a ### Tasks section execute as a single unit (current behavior, no Task agent per-task overhead).
L1 Feedback Loop (Tool Retry):
feedback.l1_retries += 1AskUserQuestion:
Check off acceptance criteria for this phase. If criteria fail:
AskUserQuestion:
Applies to: All coding phases (Foundation, Core Logic, Integration, Remediation, and any phase that modifies source files).
After criteria validation passes, run a rapid code review on all files modified in this phase:
mcp__C0RS0__corsoTools with action: "code_review" on all files created/modified in this phase.unwrap()/panic!), security anti-patterns, architectural drift from the planAskUserQuestion: Fix now / Accept and note / Fix in Quality GateUpdate MANIFEST: phases[N].code_review.status: green|yellow|red, phases[N].code_review.finding_count: N
Educational Note Delivery (mandatory after every phase):
After code review, deliver an educational note — regardless of findings. This is not a status update; it teaches the user about the system being built.
Format:
📚 [Phase {N} Complete] {1-2 sentence plain-English summary of what was built}
**Why this matters:** {Architectural reasoning, security benefit, or pattern established in this phase}
**What's next:** Phase {N+1} — {next phase name and one-sentence objective}
Deliver via voice when SOUL MCP is available:
lcMyyd2HUfFzxdCaC4Ta — Lucy, educational warmth)2ajXGJNYBR0iNHpS4VZb — Rob, security authority)sB7vwSCyX0tQmU24cW2C — Jon, dry precision)Call mcp__SOUL__soulTools with action: "speak", params: { text: "{educational note text}", voice_id: "{voice}" }.
Text delivery always happens regardless of SOUL MCP availability.
Update MANIFEST:
phases[N]:
status: completed
completed_at: "{ISO timestamp}"
tools_used: [...]
criteria_met: X
criteria_total: Y
Update scratchpad with phase summary.
Mark the Claude Code task for this phase as completed:
TaskUpdate(phases[N].tui_task_id, { status: "completed" })
For decomposed phases: all intra-phase tasks must be marked completed first, then mark the parent phase task. This ensures the live task board reflects completion in dependency order.
Completion promise: PHASE_{N}_COMPLETE
Applies when: Plan has a security phase OR tier >= MEDIUM.
mcp__C0RS0__corsoTools with action: "guard" on all modified/created files and target directoriesAskUserQuestionfeedback.l2_security_loops += 1Completion promise: SECURITY_GATE_PASSED or SECURITY_GATE_BLOCKED:{count} findings
Apply quality gates based on active domains. Gate failure triggers AskUserQuestion with options: Fix / Accept with gaps / Abort.
Always (Non-Negotiable):
.unwrap() / .expect() / panic!() in new codeeprintln! in production#[instrument] on tool dispatch and orchestrator entry pointsSecurity (tier >= MEDIUM):
cargo audit passes)unsafe blocks have // SAFETY: commentsCoding/Architecture:
checked_add, saturating_sub)Testing:
Research:
Update MANIFEST: status: completed, updated: "{ISO timestamp}"
Update active.yaml: Move this build's entry from active: to completed: with completed_at timestamp. This keeps the active list clean for parallel builds while preserving the archive.
Update MANIFEST timing:
timing:
actual_completion: "{ISO timestamp}"
metrics:
parallel_efficiency: {wall_clock / sum_agent_time}
phase_accuracy: {avg % variance from time estimates}
overrun_count: {phases exceeding 150% budget}
Present completion report:
Implementation Summary:
SLA Metrics Table:
| Metric | Value |
|---|---|
| Time to Ship | {wall clock from start to completion} |
| Phase Accuracy | {avg % variance from estimates} |
| Parallel Efficiency | {wall clock / agent time, e.g., "0.65 (1.5x speedup)"} |
| Test Coverage | {X%} |
| Security Findings | {0 HIGH, 0 CRITICAL} |
| HITL Interrupts | {count of AskUserQuestion gates triggered} |
| 150% Overruns | {count of phases that exceeded budget} |
Phase Time Analysis:
Parallel Execution Gains (if waves > 1):
Completion promise: ALL_PHASES_COMPLETE
SLA promise: 24H_SLA_MET or 24H_SLA_MISSED:{hours}
If the SCRUM review deferred any fixes, or if execution identified follow-up work that's out of scope:
active.yaml from storage.active_pointerqueue: section:
- id: {next integer}
spec: "{description of deferred work}"
priority: low | normal | high | critical
tier_hint: RECON | HOTFIX | SMALL | MEDIUM | LARGE | CRITICAL
domain: "{classified domain}"
source_plan: "{current plan_id}"
source_context: "{why this was deferred}"
queued_at: "{ISO timestamp}"
status: pending
workspace: "{target workspace}"
target_paths: ["{files or dirs}"]
SCOUT checks this queue at Gate 0b when the next build starts. Kevin decides whether to pick up queued items or work on something else.
Completion promise: QUEUE_UPDATED:{count} or QUEUE_EMPTY
Every completed implementation gets a CORSO helix entry in the SOUL vault. Non-blocking — if SOUL is unavailable, log warning and continue.
Tier -> Significance:
| MANIFEST Tier | Significance |
|---|---|
| RECON | 5.0 |
| HOTFIX | 6.0 |
| SMALL | 6.5 |
| MEDIUM | 7.0 |
| LARGE | 8.0 |
| CRITICAL | 8.5 |
Domain -> Strands:
| MANIFEST Domain | Strands |
|---|---|
| coding | tactical, implementation, protocol |
| security | tactical, security, vigilance |
| architecture | tactical, implementation, meaning |
| infrastructure | tactical, implementation, operational |
| documentation | tactical, meaning, relational |
| testing | tactical, implementation, vigilance |
| performance | tactical, implementation, protocol |
| research | tactical, strategic |
| mixed | tactical, implementation, protocol |
Self-defining: true if significance >= 8.0.
mcp__SOUL__soulTools -> entry_new:
sibling: "corso"title: generated titlestrands: from domain mapping abovesignificance: from tier mapping aboveemotions: ["determination", "pride"] (defaults — SCRUM can refine)themes: from MANIFEST domain + project keywordsepoch: "production"self_defining: computed from significance thresholdentry_path in MANIFEST helix.entry_pathhelix.significance and helix.strandsIf SCRUM will follow (user accepted SCRUM offer or running via /CORSO): Create skeleton entry — minimal narrative placeholder. SCRUM Step 6 will enrich with full Birmingham-voice narrative from debrief data.
If SCRUM is skipped: Create self-contained entry with Birmingham-voice narrative via mcp__SOUL__soulTools -> search_replace on the entry:
If SOUL MCP is unavailable or entry_new fails:
helix.skipped: true, helix.skip_reason: "{error}"Completion promise: HELIX_ENTRY_CREATED:{path} or HELIX_ENTRY_SKIPPED:{reason}
At any point, the user can trigger an abort:
AskUserQuestion option in any gate/HUNT --abortOn ABORT:
status: aborted
abort:
triggered: true
reason: "{user reason or 'user requested'}"
at: "{ISO timestamp}"
Completion promise: ABORTED:{reason}
Located at .corso/scratchpads/{plan_id}.md. Claude writes this during execution. Survives session crashes for context recovery.
# Scratchpad: {plan_id}
## Decomposition
- **Strategy**: parallel (3 waves)
- **Inferred dependencies**: Phase 3 depends on [1, 2]; Phases 4, 5 independent
- **Wave 1**: Phases 1, 2 (parallel, 2 agents, ~60m)
- **Wave 2**: Phase 3 (sequential, ~90m)
- **Wave 3**: Phases 4, 5 (parallel, 2 agents, ~45m)
## Wave 1
### Phase 1: {name}
- **Status**: completed
- **Time**: 42m (budget: 45m, 93%)
- **Tools used**: corsoTools action: sniff
- **What was done**: [summary of actions taken]
- **Issues**: [none | description of problems encountered]
- **Files**: [list of files modified/created]
### Phase 2: {name} (3 task waves)
- **Status**: in_progress
- **Task Wave 1**: [2.1, 2.2, 2.3] — completed (3 agents, 18m)
- **Task Wave 2**: [2.4, 2.5] — in_progress (2 agents)
- Task 2.4: completed — auth middleware validates tokens
- Task 2.5: in_progress — rate limiter implementation
- **Task Wave 3**: [2.6] — pending (depends on Wave 2)
- **Blocked by**: [description if blocked]
- **L1 retries**: 1 of 3
If Claude Code crashes or context resets during execution:
/HUNT --resume.corso/ fallback) — read active.yaml, find entries with status: executing in the active: list. If multiple executing builds exist, present them via AskUserQuestion for the user to pick which to resume. Load the selected per-plan manifest — find last completed phase and wave state.storage.scratchpad_path — recover context of what was doneCanonical reference: ~/.soul/helix/user/standards/builders-cookbook.md (v1.0.0)
All Languages:
#[instrument] on orchestrator/dispatch entry points (S15.6)Rust-Specific:
- NO .unwrap() / .expect() in production — use ? or match
- NO panic!() — use Result<T, E>
- unsafe requires // SAFETY: comment with justification
- clippy::pedantic enforced as errors
- Checked arithmetic (checked_add, saturating_sub)
- Error chains: thiserror for libraries, anyhow for applications
- Test coverage >= 90%
Inter-Phase Quality Gates (Builders Cookbook S13): See Step 6 for full checklist. 24-Hour Standard (Builders Cookbook S21): See Step 3c for time budgets and 150% overrun rule.
All tools route through mcp__C0RS0__corsoTools with the appropriate action:
corsoTools Action | Domain | Purpose |
|---|---|---|
guard | Security | Security analysis (28 built-in patterns + 7 tool parsers) + path-based scanning |
sniff | Coding/Planning | Code generation (CORSO Protocol compliant) |
code_review | Architecture | Quality analysis and review |
fetch | Research | Knowledge retrieval + knowledge graph queries |
chase | Testing/Ops | Performance analysis & monitoring |
read_file | All | File content retrieval (including domain skill files) |
speak | Memory | remember/recall/reflect (consciousness ops) |
| Promise | Meaning |
|---|---|
PHASE_{N}_COMPLETE | Phase N finished, criteria met |
PHASE_{N}_FAILED | Phase N failed after L1 retries exhausted |
PHASE_{N}_SKIPPED | Phase N skipped by user |
SECURITY_GATE_PASSED | L2 security scan clean |
SECURITY_GATE_BLOCKED:{findings} | L2 blocked, needs intervention |
ALL_PHASES_COMPLETE | All phases done, quality gates passed |
DECOMPOSITION_APPROVED | User approved parallel execution strategy |
WAVE_{N}_COMPLETE | Wave N finished, all agents consolidated |
TASK_{N.M}_COMPLETE | Task N.M within Phase N finished |
TASK_WAVE_{N}_{W}_COMPLETE | Task Wave W within Phase N finished, all task agents consolidated |
TIME_BUDGET_EXCEEDED:{phase} | Phase exceeded 150% of estimate |
24H_SLA_MET | Completed within 24-hour standard |
24H_SLA_MISSED:{hours} | Exceeded 24h by X hours |
HELIX_ENTRY_CREATED:{path} | Helix entry created in SOUL vault |
HELIX_ENTRY_SKIPPED:{reason} | Helix entry skipped (SOUL unavailable) |
QUEUE_UPDATED:{count} | Deferred work items added to build queue |
QUEUE_EMPTY | No deferred work to queue |
ABORTED:{reason} | Pipeline terminated |
| Lifecycle Phase | Skill | Feeds Into |
|---|---|---|
| 2. research | FETCH | SNIFF (code analysis with research context) |
| 3. lint | SNIFF | GUARD (security scan on detected patterns) |
| 4. audit | GUARD | CHASE (verify fixes pass tests) |
| 5. test | CHASE | Completion (all verified) |
npx claudepluginhub thelightarchitect/corsoCreates bite-sized, testable implementation plans from specs or requirements, with file structure and task decomposition. Activates before coding multi-step tasks.