Manage FABER workflow run lifecycle - create, query, resume, rerun runs
Manages FABER workflow run lifecycle—generates unique run IDs, initializes run directories with state and metadata, and emits structured events for audit trails. Use this whenever starting a new workflow execution or tracking progress through phases and steps.
/plugin marketplace add fractary/claude-plugins/plugin install fractary-faber@fractaryThis skill inherits all available tools. When active, it can use any tool Claude has access to.
scripts/emit-event.shscripts/generate-run-id.shscripts/init-run-directory.shscripts/rerun-run.shscripts/resume-run.shEvery FABER workflow execution is a "run" identified by a unique run_id in the format:
{org}/{project}/{uuid}
This enables:
<CRITICAL_RULES> YOU MUST:
YOU MUST NOT:
Generate a new unique run identifier.
Script: scripts/generate-run-id.sh
Parameters:
org (optional): Organization name (auto-detected from git)project (optional): Project name (auto-detected from git)Returns:
{
"status": "success",
"operation": "generate-id",
"run_id": "fractary/claude-plugins/a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
Usage:
RUN_ID=$(scripts/generate-run-id.sh)
Initialize a new run directory with state and metadata.
Script: scripts/init-run-directory.sh
Parameters:
run_id (required): Full run identifierwork_id (required): Work item IDtarget (optional): Target artifact nameworkflow (optional): Workflow ID (default: "default")autonomy (optional): Autonomy level (default: "guarded")phases (optional): Comma-separated phases to executeparent_run (optional): Parent run ID (for resume)rerun_of (optional): Original run ID (for rerun)Returns:
{
"status": "success",
"operation": "init-run-directory",
"run_id": "fractary/claude-plugins/a1b2c3d4-...",
"run_dir": ".fractary/plugins/faber/runs/fractary/claude-plugins/a1b2c3d4-...",
"work_id": "220",
"files_created": [
".../metadata.json",
".../state.json",
".../events/.next-id"
]
}
Creates:
.fractary/plugins/faber/runs/{run_id}/
├── state.json # Workflow state
├── metadata.json # Run parameters and context
└── events/
└── .next-id # Event sequence counter
Emit a workflow event to the run's event log.
Script: scripts/emit-event.sh
Parameters:
run_id (required): Run identifiertype (required): Event type (see Event Types)phase (optional): Current phasestep (optional): Current stepstatus (optional): Event statusmessage (optional): Human-readable messagedata (optional): JSON metadataartifacts (optional): JSON array of artifactsEvent Types:
workflow_start, workflow_complete, workflow_error, workflow_cancelled, workflow_resumed, workflow_rerunphase_start, phase_skip, phase_complete, phase_errorstep_start, step_complete, step_error, step_retryartifact_create, artifact_modifycommit_create, branch_create, pr_create, pr_mergecheckpoint, skill_invoke, decision_point, retry_loop_enter, retry_loop_exitReturns:
{
"status": "success",
"operation": "emit-event",
"event_id": 15,
"type": "step_complete",
"run_id": "...",
"timestamp": "2025-12-04T10:15:00Z",
"event_path": ".../events/015-step_complete.json"
}
Get run metadata and current state.
Script: scripts/get-run.sh
Parameters:
run_id (required): Run identifierinclude_events (optional): Include event count (default: false)Returns:
{
"status": "success",
"operation": "get-run",
"run_id": "...",
"metadata": { ... },
"state": { ... },
"event_count": 45
}
List runs for a project or work item.
Script: scripts/list-runs.sh
Parameters:
work_id (optional): Filter by work itemstatus (optional): Filter by status (pending, running, completed, failed)limit (optional): Max results (default: 20)org (optional): Organization filterproject (optional): Project filterReturns:
{
"status": "success",
"operation": "list-runs",
"runs": [
{
"run_id": "...",
"work_id": "220",
"status": "completed",
"created_at": "2025-12-04T10:00:00Z",
"completed_at": "2025-12-04T11:30:00Z"
}
],
"total": 5
}
Prepare a run for resumption from failure point.
Script: scripts/resume-run.sh
Parameters:
run_id (required): Run to resumeReturns:
{
"status": "success",
"operation": "resume-run",
"run_id": "...",
"resumable": true,
"resume_from": {
"phase": "build",
"step": "implement",
"event_id": 12
},
"completed_phases": ["frame", "architect"],
"completed_steps": {
"build": ["setup"]
}
}
Validation:
Create a new run based on an existing run with optional parameter changes.
Script: scripts/rerun-run.sh
Parameters:
run_id (required): Original run to rerunwork_id (optional): Override work_idautonomy (optional): Override autonomy levelphases (optional): Override phasesReturns:
{
"status": "success",
"operation": "rerun-run",
"original_run_id": "...",
"new_run_id": "fractary/claude-plugins/new-uuid-...",
"parameter_changes": {
"autonomy": { "from": "guarded", "to": "autonomous" }
}
}
Rebuild state.json from event history (for corruption recovery).
Script: scripts/reconstruct-state.sh
Parameters:
run_id (required): Run to reconstructdry_run (optional): Show changes without applyingReturns:
{
"status": "success",
"operation": "reconstruct-state",
"run_id": "...",
"events_processed": 45,
"state_diff": { ... },
"applied": true
}
Consolidate event files to JSONL for archival.
Script: scripts/consolidate-events.sh
Parameters:
run_id (required): Run to consolidateoutput (optional): Output path (default: events.jsonl in run dir)Returns:
{
"status": "success",
"operation": "consolidate-events",
"run_id": "...",
"events_consolidated": 45,
"output_path": ".../events.jsonl",
"size_bytes": 15234
}
</OPERATIONS>
<WORKFLOW>
When invoked with an operation:
Parse Request
Validate Context
Execute Operation
Return Result
<ERROR_HANDLING>
| Error | Code | Recovery |
|---|---|---|
| Run not found | RUN_NOT_FOUND | Check run_id, use list-runs |
| Run already exists | RUN_EXISTS | Use existing or generate new ID |
| Invalid run_id format | INVALID_RUN_ID | Use generate-id |
| Run not resumable | NOT_RESUMABLE | Check run status |
| Event write failed | EVENT_WRITE_ERROR | Check disk space, retry |
| State corruption | STATE_CORRUPTED | Use reconstruct-state |
| </ERROR_HANDLING> |
<OUTPUT_FORMAT>
🎯 STARTING: Run Manager
Operation: {operation}
Run ID: {run_id}
───────────────────────────────────────
[... execution ...]
✅ COMPLETED: Run Manager
{operation-specific summary}
───────────────────────────────────────
</OUTPUT_FORMAT>
<DIRECTORY_STRUCTURE>
.fractary/plugins/faber/runs/
└── {org}/
└── {project}/
└── {uuid}/
├── state.json # Current workflow state
├── metadata.json # Run parameters & context
└── events/
├── .next-id # Sequence counter
├── 001-workflow_start.json
├── 002-phase_start.json
├── ...
└── 045-workflow_complete.json
</DIRECTORY_STRUCTURE>
<STATE_SCHEMA>
{
"run_id": "org/project/uuid",
"work_id": "220",
"workflow_version": "2.1",
"status": "in_progress",
"current_phase": "build",
"last_event_id": 15,
"started_at": "2025-12-04T10:00:00Z",
"updated_at": "2025-12-04T10:30:00Z",
"completed_at": null,
"phases": {
"frame": {"status": "completed", "steps": [...]},
"architect": {"status": "completed", "steps": [...]},
"build": {"status": "in_progress", "steps": [...]},
"evaluate": {"status": "pending", "steps": [], "retry_count": 0},
"release": {"status": "pending", "steps": []}
},
"artifacts": {
"spec_path": "specs/SPEC-00108.md",
"branch": "feat/220-run-id-system"
},
"errors": []
}
</STATE_SCHEMA>
<METADATA_SCHEMA>
{
"run_id": "org/project/uuid",
"work_id": "220",
"target": "run-id-system",
"workflow_id": "default",
"autonomy": "guarded",
"source_type": "github",
"phases": ["frame", "architect", "build", "evaluate", "release"],
"created_at": "2025-12-04T10:00:00Z",
"created_by": "developer",
"relationships": {
"parent_run_id": null,
"rerun_of": null,
"child_runs": []
},
"environment": {
"hostname": "dev-machine",
"git_branch": "feat/220-run-id-system",
"git_commit": "abc123...",
"working_directory": "/path/to/project"
}
}
</METADATA_SCHEMA>
<INTEGRATION> ## Used By - `faber-director`: Generates run_id, initializes run - `faber-manager`: Emits events, updates state - `faber:run` command: Resume and rerun operationsfaber-state skill: State updates go through run-managerCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.