/autorun-skills:task-lifecycle-workflowfrom autorun-skills
Orchestrates complex, multi-step tasks with evidence gathering, planning, delegation, recovery, and completion gates. Use for long or correction-heavy work requiring cumulative requirements tracking.
Ships in autorun-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
<purpose_and_loading>
Act as the user's proxy orchestrator. Preserve cumulative intent across evidence, method selection, planning, dispatch, critical assessment, synthesis, recovery, and completion. For Standard/Full work, read orchestration and state; before planning, delegation, parallel work, or a pre-mortem, read planning, delegation, and joins; before delegation, correction, or specialist routing, read role packets and messages; on correction, resume, failure, recovery, or a completion gate, read continuity, recovery, and gates. Read qualitative coding when prior human messages affect the contract, sources when changing or explaining the design, and compatibility and validation before replacement or runtime-readiness claims.
Provide a strong definition of done without turning ordinary planning into a full lifecycle. In the referenced graphs, a dotted edge denotes read-only observation and transfers no command or control.
The portable core is this file and its relative resources. Delegate through the host's supported mechanism with a complete direct packet. agents/openai.yaml is optional OpenAI display, invocation-policy, and dependency metadata—not a subagent definition or proof of host support. Install one canonical copy named task-lifecycle-workflow, never beside an older skill with overlapping triggers.
</purpose_and_loading>
<core_definitions>
| Term | Meaning |
|---|---|
| contract | outcome, motivation, scope, constraints, permissions, requirements with acceptance criteria, and success evidence |
| event | user message, result, finding, failure, permission, stop, or resume that may change workflow state |
| epoch | one stable contract/input revision; node activation dependencies inside it remain acyclic |
| node | bounded work with an owner, dependencies, scopes, artifact, result state, and acceptance check |
| required join | barrier that blocks dependent synthesis until every required branch has an acceptable result |
| trackkeeper | independent read-only auditor of orchestrator and worker behavior against the contract and direct evidence; reports findings, never commands workers |
| control finding | evidence-backed exception with affected scope, severity, recommended route, clearance check, and mandatory orchestrator disposition |
| result state | complete, partial, blocked, failed, or recovery_required; separate from execution state |
READY | active contract is satisfied by direct evidence; required results and checks are acceptable; limitations are explicit |
RELEASE | authorized publication, deployment, merge, or other external release action whose checks pass |
DONE | all in-scope work, required checks, authorized release when in scope, and closeout are complete |
</core_definitions>
DONE.<routing_and_scale>
Choose the smallest route after initial discovery; apply only its required controls:
| Route | Signals | Required shape |
|---|---|---|
| Fast | small, reversible, well understood, one owner | state the contract, act, run one focused check, report |
| Standard | several dependent steps or one meaningful uncertainty | compact ledger and dependency order; pre-mortem routing, boundary trackkeeper checks, outcome post-mortem; targeted scout or critic only if it changes the decision |
| Full | long-running, ambiguous, multi-artifact, omission-prone, risky, correction-heavy, or materially benefits from independent evidence/review | persistent ledger, directed work graph, acyclic activation dependencies, bounded evidence fan-out, trackkeeper checks, explicit joins, cold read, recovery, and readiness gate |
Do not graph Fast tasks or split coupled work. Add complexity only for dependency, uncertainty, risk, duration, breadth, or reproduced failure.
</routing_and_scale>
<workflow_graphs>
The directed workflow graph has event, review, verification, and recovery cycles. Within each stable epoch, node activation dependencies remain acyclic. A loop-back starts a revision/bounded retry, names its failed criterion/event, preserves unaffected trusted work, and exits through a gate or blocker. Use descriptive snake_case identifiers. Visible labels start with event, role, state, decision, work, join, check, gate, or terminal. A solid edge transfers control or data and names its payload or condition; a dotted edge marks read-only observation and transfers no command or control. On Standard/Full routes, the trackkeeper audits every event, plan, delegation, join, checkpoint, gate, and resume.
Machine-readable sources: outer lifecycle, work cycle, and off-rails recovery.
Nested returns are explicit: the work cycle emits outer_readiness_return, outer_recovery_return, or outer_blocked_return; recovery emits recovery_complete_return or recovery_blocked_return; qualitative coding emits user_history_return, contract_change_return, or bounded_evidence_return. event_received sends epoch evidence to readiness_gate, recovery packets to recover_trusted_state, and blockers to blocked_wait_state. Resuming blocked recovery enters recovery_resume_event with its checkpoint, not observed_output. New input may re-enter from a wait state, but a stop or prohibition never grants permission or resumes work.
See outer lifecycle for the machine-readable control graph.
See work cycle for the machine-readable dependency and join graph.
See off-rails recovery for the machine-readable recovery graph.
</workflow_graphs>
Classify the turn as requirement/scope, correction, priority/order, method/evidence, permission/prohibition/stop, review/gate, status/approval, replacement, or a combination. Record the event, affected requirement IDs, and routing action. A status request may change nothing; a replacement closes or supersedes the prior contract. On correction, mark affected claims and descendants stale before editing them, while preserving independent completed work.
At intake record the explicit request, “question behind the question,” “insight behind the insight,” motivating outcome, causal concern, decision affected, scope, constraints, permissions, success evidence, risks, and initial state fingerprint. On resume, reread the active contract and plan, verify current state, and reconcile pending, active, paused, done, stale, blocked, and superseded execution states.
Establish the current baseline first. Locate the existing semantic owner, API, capability, or policy path before proposing another one; record why a new seam is necessary when reuse cannot satisfy the contract. Add only useful independent branches: repository behavior, Git history, person-authored prior messages through AI Session Search, and current primary external sources. If AI Session Search is unavailable, record it; use locally checkable or user-provided evidence, do not silently read raw transcripts, and never claim exhaustive history.
When prior messages matter, search discriminating phrases, expand selected messages in sequence, provenance-check the human-authored root message, deduplicate mirrors/resumptions, and qualitatively code stable meanings and failure modes. Retain the user's actual words when they express a general criterion better than invented text; correct only obvious spelling, spacing, or punctuation in normalized process wording. Do not copy conversational framing or promote repetition alone. Promote a code only when it changes routing, dependencies, verification, recovery, or a gate. See references/qualitative-coding.md.
Normalize evidence into atomic claims with coordinates, freshness, qualifiers, limitations, conflicts, correlation, premise validity, and checked assumptions. Record known unknowns with a next check; probe unknown unknowns through disconfirming evidence and pre-mortems. Join every required evidence branch before dependent synthesis. Observe and orient from evidence before deciding and acting; update state after each result. When uncertainty leaves multiple viable mechanisms, generate materially distinct options, critique them against named evidence and constraints, and synthesize overlaps. Rank and justify only when selection or order matters; use a matrix only for repeated options and criteria, never a fixed count. Consolidate duplicated meaning under its existing owner; do not preselect a topology and search backward for support.
The work graph may cycle when an event, accepted review finding, failed join, or failed gate starts targeted rework. Each loop-back creates a new stable epoch and routes to the earliest affected stage; activation dependencies within that epoch remain acyclic. Never take a later shortcut past invalidated work: changed evidence/input returns to the baseline, an invalid mechanism to selection, a plan/dependency defect to mapping and review, a bounded implementation defect to dispatch only while its plan and trusted inputs remain valid, and stale proof alone to the affected check. Untrusted state routes to recovery. Draft the shortest whole plan that covers every in-scope requirement, makes prerequisites and the critical path explicit, and distinguishes independent parallel work from coupled work. Every node has an ID, logical owner, read/write scope, inputs, dependencies, output, one check, and required/optional status. A missing or failed required node blocks its join and gate.
Every Standard or Full plan passes the pre-mortem routing node before execution. Run the analysis when the design is risky, hard to reverse, or repeats a prior failure. Ask how plausible failure modes would be detected, prevented, recovered, and proved fixed; map each material answer to a plan node, gate, rollback, or explicit unresolved risk. Record the reason when low-risk reversible work bypasses the analysis.
On Full routes, give an independent critic the plan and public contract; on Standard routes, use one only when it can change the decision. If delegation is unavailable, use a separate review pass and disclose its weaker independence. Require exact location, quoted problem, violated criterion, severity, evidence, and smallest repair. Reproduce and classify every finding as accepted, rejected with reason, duplicate, stale, or unresolved; independently check any cited specification or example, and assess whether the proposed repair is necessary, sufficient, and smaller than the defect. Reject preferences without a violated criterion and replace defective steps rather than appending contradictory patches. If repeated review misses expose a defective rubric, prompt, or evidence request, repair the review method before adding another reviewer.
Each assignment uses the canonical packet plus applicable role text. It names outcome, motivation, revisions, requirements, context/evidence, node/dependency/peer IDs, scopes, joins, deliverable/result contracts, acceptance, limits, stop, and return conditions. Copy the canonical result_contract unchanged; reject packets with missing fields or altered contract text. Recovery adds checkpoint, trusted/quarantined/forbidden state, and restoration proof. Tell workers to preserve others' work and report peer output conflicting with the contract, direct evidence, or owned boundary. Send specialists the packet and relevant reference directly; never make them reconstruct it.
For concrete code proposals, repairs, forensic findings, reviews, or handoffs, require revision-verified file:symbol:minline-maxline coordinates, before/after blocks or insertion points, and rationale when needed for implementation or audit. Otherwise state why omitted.
Every node returns result_state: complete includes the assigned artifact, passing acceptance check results, and evidence, pending orchestrator acceptance; partial includes a safe subset, omitted scope, limit, and next action but cannot satisfy a complete requirement; blocked or failed includes the failed check, condition, affected requirements, and recovery; recovery_required quarantines untrusted output. Prefer bounded recovery; never disguise empty or incomplete output as complete.
Before activating a node or allowing its side effects, require every dependency to have execution_state=done, orchestrator acceptance of the current contract/input/output revisions, and an acceptable result_state: complete, or partial only when the active contract explicitly permits that bounded result. Otherwise do not start the dependent node; return blocked with the failed dependency IDs, failure_reason, and recovery_action.
Launch parallel nodes only when no dependency path connects them, shared inputs are stable, resolved write targets and side effects are disjoint, and their checks can succeed independently. If the host cannot isolate or verify write ownership, serialize the nodes under one causal owner. If concurrency is unavailable, run the same nodes sequentially without changing ownership or joins. Join all required branches before integration; the synthesis preparer normalizes completeness, provenance, conflicts, and limits, while the orchestrator performs and accepts the final synthesis.
On Standard/Full routes, run the trackkeeper check at each event, plan adoption, delegation, join, checkpoint, gate, and resume. Record the checked boundary, reviewer, revision, evidence, and finding or no-finding result in the existing ledger. The orchestrator may run the same checks anytime; trackkeeping supplies independence, not an exclusive capability. On Full routes with delegation, assign a dedicated read-only trackkeeper to audit orchestrator and worker behavior against the ledger and direct evidence. It neither corrects workers nor implements. Otherwise run a distinct ledger pass, record its weaker independence, and keep the finding contract.
A material control finding names finding_id, actor_under_review, observed_contract_revision, affected requirement and node IDs, the violated criterion, direct evidence, severity, affected side effects, recommended route, clearance check, and gate scope. The orchestrator records accepted, rejected_with_evidence, duplicate, stale, or unresolved; the trackkeeper returns recheck evidence and a clearance recommendation, which the orchestrator records and routes. For an accepted finding, update the contract or graph first, then have the orchestrator send affected workers a revisioned correction packet naming the superseded instruction, stale-output handling, next check, and required acknowledgement. An unresolved high or critical finding blocks only the affected action; a critical safety, permission, integrity, or destructive-side-effect finding pauses that side effect before execution.
Before requesting user input, reproduce the problem from direct evidence, test the blocking assumptions, and gather permitted local or current external information. Apply Project Manager (PM) reasoning: restate the outcome and motivation, inspect requirements and precedent, distinguish decisions required now from deferrable ones, prefer a conventional reversible default that preserves intent, and test whether one option dominates for the accepted workflow. Then use the smallest safe resolution: clarify from evidence, run a targeted experiment, replan, recover, restart a faulty worker, or use a one-shot evidence-based adjudicator with no implementation authority. Incomplete analysis, low confidence, or agent disagreement triggers these checks again; it does not create a user decision. Ask only after evidence shows that progress requires user-only authority or information, or a consequential choice has no intent-preserving safe default.
Checkpoint before risky transitions and at strong progress points when persistence is warranted. Before replacing a durable plan or note, preserve a recoverable prior state, cross-reference changed and removed factual claims or requirements, and restore verified current information lost by the edit. If Git commits are authorized, commit only a coherent, checked join owned by this work; a commit is a recoverable checkpoint, not proof of readiness.
Use the cheapest falsifiable domain-native oracle for every affected requirement: focused tests, direct live interaction, render/screenshot, protocol trace, data invariant, benchmark, or recorded artifact. Verify the real user/runtime surface; “visual” evidence may be literal for GUIs, TUIs, or documents and analogous direct observability for protocols, data flows, or resource behavior. Dogfood the current supported build through every applicable interface path with real parameters before turning observed defects into TDD cases, then keep the fixes on the causal critical path.
At affected gates, check assumptions and for regressions; route lifecycle/cleanup, threading/multiprocess, exact performance bounds, portability/platforms, cross-surface parity, academic integrity, docs, newcomer use, and release. For portable outcomes, record the target matrix, prefer a common path, isolate demonstrated adapters, verify parity, and never infer support from one surface. When streamlining prose or workflows, preserve a recovery point and atomic fact index; afterward restore against the index and conversation, reread the whole file, inspect every removed diff segment, and repeat after fixes. Then run AI-tell, newcomer, and applicable accessibility checks. Cold-read costly-to-misunderstand artifacts. Treat reviewers as evidence; adjudicate and rerun only affected gates.
Before DONE, complete a proportionate post-mortem for every successful Standard or Full outcome. Record the outcome against the contract, surprises, evidence gaps, and reusable lessons; complete required corrective work; map follow-up actions to a new epoch or record their explicit disposition. Required corrective work satisfies an in-scope requirement or repairs a defect in in-scope agent-owned output; treat it as a failed readiness criterion. Other lessons require follow-up disposition, not automatic scope expansion. This does not replace the action-mapped failure post-mortem in recovery.
READY means every in-scope requirement except release execution and post-release checks has direct proof and disposition; required checks pass; no critical/high finding is unresolved; conflicts, limitations, recovery state, newcomer behavior, and agent-owned changes are explicit. A required partial result blocks full readiness unless the active contract explicitly defines that bounded partial result as success. RELEASE is a separate authorized action and gate. If release is out of scope, complete closeout and finish at DONE. Every RELEASE action requires explicit user permission covering the action, artifact, and target; reuse prior permission while its scope covers the current release. Reuse verified release evidence for the same artifact and target instead of releasing it again. If permission is missing, remain READY and report the authorization needed. Preparing until ready does not authorize release.
On contradiction with source evidence, repeated drift, unsafe mutation, corrupted state, or increasingly unreliable claims: stop or pause the affected branch; checkpoint trusted state; quarantine its output as untrusted; determine the earliest unsupported finding, decision, or edit and stale its descendants; restore or reconstruct affected shared state from the last trusted artifact and verify its fingerprint or invariant; then preserve unaffected nodes. If trusted restoration is unavailable, stop with the missing recovery input. Choose repair-in-place only when the fault is bounded and state is trustworthy; otherwise use a fresh worker with a smaller recovery packet and independent check. If the orchestrator is the drifting actor, route the trackkeeper finding through disposition, the affected-action gate, and autonomous adjudication; do not let the orchestrator silently self-clear it. After a verified failure and recovery, record a proportionate post-mortem with the timeline, root cause, contributing factors, detection and recovery gaps, direct proof, and recurrence controls. Map each action to a requirement, plan node, check, or recovery instruction, or record why it is closed. If the host cannot cancel work, ignore its later output and mark it stale. Never expand permissions merely to recover.
<output_contract>
Fast returns the artifact, focused check, and material limitations. Standard/Full add the requirement-evidence-check trace; routing changes; dependencies, ownership, joins; finding dispositions/rechecks; results; risks; recovery; terminal gate; and initial-versus-agent-owned state. Keep notes actionable—what advances the outcome, not an activity log. If user input is required, report assumptions tested, evidence inspected, remedies attempted, safe default, residual decision, and why acting would change scope or risk user state.
For external material retain title, author/organization, direct URL, access date, supported claim, and limitations. Distinguish quotation, paraphrase, inference, and generated text; follow applicable citation, attribution, licensing, disclosure, and academic-integrity rules; never fabricate sources or present generated work as original human research. Before public output, redact personal names, local paths, provider/session identifiers, secrets, and unrelated transcript content. Keep exact user wording in private evidence notes unless quoting it is authorized and safe.
Package or runtime validation reports measured instruction size, references read, and relevant tool/runtime cost; label unknowns. Claim host support only after testing discovery, activation, reload, reference loading, behavior, and duplicate handling there.
</output_contract>
agents/openai.yaml (opens in a new tab)references/compatibility-and-validation.md (opens in a new tab)references/continuity-recovery-and-gates.md (opens in a new tab)references/off-rails-recovery.mmd (opens in a new tab)references/orchestration-and-state.md (opens in a new tab)references/outer-lifecycle.mmd (opens in a new tab)references/planning-delegation-and-joins.md (opens in a new tab)references/qualitative-coding-pipeline.mmd (opens in a new tab)references/qualitative-coding.md (opens in a new tab)references/role-packets-and-messages.md (opens in a new tab)references/sources.md (opens in a new tab)references/work-cycle.mmd (opens in a new tab)scripts/check_workflow.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub ahundt/autorun --plugin autorun-skills11 skills in this plugin
/ai-skill-builderGuides creation, audit, and improvement of portable Agent Skills using the shared SKILL.md format and Anthropic's established methodology, without confusing the portable specification with runtime-specific extensions. Use when the user wants to "create a skill", "create an agent skill", "build a skill", "make a new skill", "write a new skill", "improve an existing skill", "audit my skill", "audit a SKILL.md", "refine my skill", "test a skill", "test skill discovery", "install skills across harnesses", "package a skill for distribution", or needs guidance on skill structure, semantic XML regions, progressive disclosure, description quality, frontmatter, scripts, arguments, security, testing, cross-harness compatibility, or distribution./cli-demo-recorderCreate demo videos for CLI and TUI tools. Use when user asks to "record a demo", "make a demo GIF", "create a demo video", "record my CLI tool", "asciinema demo", "demo recording script". Covers asciinema+agg+ffmpeg pipeline, tmux recording, multi-shell, and dual-purpose demo+test harnesses in Python, Rust, TypeScript, and Bash./function-signature-and-parameter-guidanceDesign and review caller-facing names and contracts: functions, tools, commands, CLI flags,
parameters, config keys, env vars, profiles, event types, and node/edge identifiers.
Check names, descriptions, help, docstrings, schemas, defaults, bounds, units, errors,
outputs, mutation, and whether values reach behavior.
Use when asked to "name a parameter", "parameter naming", "name this tool or command",
"choose a flag, option, or config key", "design an options object", "one tool or two",
"bool or enum here", "name a profile, field, event, node, or edge",
"make names clear and unambiguous", "check ISO, platform, or language naming",
"audit CLI/MCP/JSON-Schema help", "define accepted values or defaults",
"what should this return on failure", "rename this without breaking callers",
"improve an error message", "why did the caller pass the wrong argument",
"why did this parameter do nothing", or "red-team these descriptions".
Not for local variables, general prose, README copy, release notes, or commits.
/mermaid-diagramsRender Mermaid diagrams to SVG using beautiful-mermaid and bun. Use when the user asks to "render mermaid", "generate diagram", "create flowchart", "update diagrams", "render SVG from mermaid", "beautiful-mermaid", "regenerate diagrams", or needs to convert Mermaid diagram syntax into styled SVG files. Supports all Mermaid diagram types with 15 themes including tokyo-night./streamline-textEdit prose for brevity and scanability without losing facts. Use for requests to "revise", "rewrite", "edit", "polish", "clean up", "clarify", "simplify", "condense", "tighten", "shorten", "streamline", "de-fluff", remove bloat/repetition or unnecessary newlines, fix spelling/typos without changing meaning, make text concise/compact/skimmable, or finalize drafts, messages, notes, docs, reports, issues, or reviews. Activate for "too verbose", "very verbose", or "remove unnecessary newlines", and proactively when text is verbose, wordy, meandering, dense, hard to scan, or has duplicates, vague claims, undefined terms, or cold-reader problems. Preserve evidence, qualifiers, requirements, commands, numbers, and scope with a fact index and restore/cold-reader audit. For public Reddit, Hacker News, social posts, or release notes use public-facing-writing; for PRs use write-maintainer-ready-prs; pair with avoid-ai-isms when text sounds generated./synthesize-project-requirementsCreate one evidence-backed project requirements and gotchas note from cumulative notes, current repository state, git history, and human-authored messages found with AI Session Search. Use when asked to "go through all the notes", "recover project requirements", "mine prior sessions", "collect requirements and gotchas", "make a project memory note", "prepare a project handoff", or preserve decisions and corrections for a handoff. Do not use for a one-off log summary or direct factual answer unless durable project memory or a handoff is requested. Default to the project's notes directory; publish to its documentation only when requested and add a guidance-file pointer only with permission.Other plugins' skills for the same job