بنقرة واحدة
phase-execution
Execute a single phase with sequential task execution in an isolated worktree.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Execute a single phase with sequential task execution in an isolated worktree.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
Execute implementation plan with autonomous subagent pipeline. Two-stage review (spec + quality). Flags only for critical blockers.
Use after /imagine completes to create an executable implementation plan (War Room phase).
Use when a user wants to develop a rough idea into a product design. Activates a virtual startup team that guides the user through Discovery, Definition, Validation, and Architecture phases. Creates session.yaml and four design documents.
Start the Office Dashboard to visualize /build progress in real-time
Use when code review feedback requires fixes - emphasizes technical verification over performative agreement
استنادا إلى تصنيف SOC المهني
| name | phase-execution |
| description | Execute a single phase with sequential task execution in an isolated worktree. |
Runs all tasks in a phase sequentially within an isolated worktree. Each task goes through the 4-stage pipeline inline: Implement → Self-Review (Spec) → Self-Review (Quality) → Commit.
Context strategy:
Why sequential?
The orchestrator provides context before invoking this skill:
phase_id - Which phase to executeworktree_path - Absolute path to this phase's worktreeproject_path - Absolute path to main project rootmodels - Model config (for reference, but tasks run inline)retry_limit - Max retry attempts per stage (default: 3)mkdir -p {project_path}/docs/office/build/phase-{id}/
# Extract only THIS phase's tasks from tasks.yaml
# This is unavoidable - we need the dependency graph
Read {project_path}/docs/office/tasks.yaml and extract:
Store in memory for sequential processing. Do NOT re-read this file.
phase: {phase-id}
status: in_progress
started_at: "{ISO timestamp}"
tasks:
task-001: ready # no dependencies
task-002: ready # no dependencies (parallel with 001)
task-003: blocked # depends on task-001
task-004: blocked # depends on task-001, task-002
Use the Write tool to create the initial log entry:
Write tool:
file_path: {project_path}/docs/office/build/phase-{id}/progress.log
content: "{ISO timestamp} PHASE_START\n"
Do NOT use bash echo - it requires permission prompts that block execution.
Tasks are executed in dependency order, one at a time:
for task in sorted_by_dependencies(phase_tasks):
# 1. Start task
log_event(f"TASK_START:{task.id}")
update_status(task.id, "in_progress")
# 2. Execute 4-stage pipeline (inline - see Task Execution section)
result = execute_task_inline(task)
# 3. Handle result
if result.success:
update_status(task.id, "completed")
log_event(f"TASK_DONE:{task.id}")
elif result.is_blocking_flag:
# Return flag to orchestrator immediately
output: FLAG: {type} | {task.id} | {description}
return # Stop phase execution
else:
# Non-blocking failure - log and continue
update_status(task.id, "failed")
log_event(f"TASK_FAIL:{task.id}")
# All tasks processed
log_event("PHASE_COMPLETE")
update_status_file(status="completed")
output: PHASE_COMPLETE: {phase_id}
Execute each task directly - do NOT spawn background subagents.
For each task, follow this 4-stage pipeline:
spec/phase_{N}_{name}/spec.mdFLAG: clarifier_blocked | {task-id} | {question}After implementing:
If issues found:
FLAG: spec_review_exhausted | {task-id} | {issues}Review your code for:
If issues found:
FLAG: code_review_exhausted | {task-id} | {issues} (WARNING only)git add -A
git commit -m "{task-id}: {description}"
On success:
TASK_DONE: {task-id}
Files: {list of files changed}
Tests: {pass count} passed
Commit: {sha}
On blocking issue:
FLAG: {type} | {task-id} | {description}
Use the Edit tool (NOT sed/bash) to update status.yaml:
Edit tool:
file_path: {project_path}/docs/office/build/phase-{id}/status.yaml
old_string: " {task_id}: {old_status}"
new_string: " {task_id}: {new_status}"
This avoids shell command issues (sed waiting on stdin if malformed).
For progress.log, use Read + Write tools to append:
# 1. Read current content
Read tool:
file_path: {project_path}/docs/office/build/phase-{id}/progress.log
# 2. Write with appended line
Write tool:
file_path: {project_path}/docs/office/build/phase-{id}/progress.log
content: "{existing_content}{ISO timestamp} {EVENT}\n"
Do NOT use bash echo for logging - it requires permission prompts that block background agent execution.
After each task completes:
TASK_STATUS: {task-id} {DONE|FLAG|SKIPPED}
On phase completion:
PHASE_COMPLETE: {phase-id}
On blocking flag:
FLAG: {flag_type} | {task-id} | {brief description}
| Item | Cost | Notes |
|---|---|---|
| Skill content | ~3k | One-time load |
| tasks.yaml (phase portion) | ~500-1k | One-time read |
| Spec file (phase) | ~2-5k | Read once per phase |
| Task implementation | ~1-2k each | Inline execution |
| Status updates | ~50 each | Edit tool |
| Total per phase | ~10-20k | Depends on task count |
All execution happens inline - no subagent overhead.