Workflow primitive for the cjhowe-us/artifact Claude Code plugin ecosystem.
Project description
workflow
Workflow primitive for the artifact ecosystem. Ships the worker agent, orchestration hooks, the execution scheme +
execution-gh-pr backend, the /workflow entry skill, the workflow-execution artifact template (the bootstrap that
turns a workflow definition into a live execution), and four base workflows:
default— orchestrator + dashboard. Entry point for every/workflowinvocation.conductor— the single meta-workflow: a workflow that creates/edits/reviews/deletes other workflows and artifact templates. Four modes (create/update/review/delete) dispatched via conditional steps on themodeinput.plan-do— reusable 2-step (plan → do) building block composed by other workflows.write-review— reusable 2-step (write → review) building block composed by other workflows.
Depends on the artifact plugin.
Install
claude plugin marketplace add cjhowe-us/marketplace
claude plugin install artifact@cjhowe-us-marketplace # required
claude plugin install workflow@cjhowe-us-marketplace
Prerequisites
ghCLI, authenticated (gh auth login). Identity comes fromgh auth status— no login dialog.git≥ 2.30 (worktrees).CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1in the environment. Theenv-setupplugin can persist this.
First run
/workflow opens the dashboard and routes user intent. The default orchestrator is a four-step DAG (seed → tutor
→ interpret → act). On first invocation for a (user, workspace) pair it runs:
seed— detects whether the repo is on GitHub, then asks oneAskUserQuestionper backend slot: execution state storage (defaultexecution-gh-pr), lock / presence storage (defaultgh-gist), and dependency overlay (defaultgh-issue). All three are pluggable and optional — the defaults are proposals the user confirms, swaps, or declines per slot. Accepted choices are written topreferences:workspace/<repo-hash>.extra.*(team-shared settings) andpreferences:user.extra.*(per-developer settings).tutor— walks the user through the two primitives (workflow, artifact), enumerates installed extensions, and offers a guided try-it. Re-open later with/workflow teach me again.interpret/act— normal intent routing + dispatch.
Subsequent invocations skip seed (once workflow_initialized=true is set) and tutor (once tutor_completed=true is
set), running interpret → act directly.
GitHub auth is consulted through workflowlib.auth, which caches gh auth status on-disk under
$ARTIFACT_CONFIG_DIR/workflow/gh_auth.json (default TTL 1 h, override via WORKFLOW_GH_AUTH_TTL_S). The same helper
wraps artifactlib_gh.gh.auth_status so every plugin in the ecosystem reads the same identity without re-shelling per
call.
Extending with your own workflows
User extensibility is the whole point. You don't fork the plugin to add a workflow — you drop files into one of four scope directories. Discovery walks all four at session start and the registry picks them up automatically.
| Scope | Path | Purpose |
|---|---|---|
override |
$CWD/.artifact-override/workflows/<name>/ |
One-off; for this working tree only |
workspace |
$REPO/.claude/workflows/<name>/ |
Project-specific; commit to the repo |
user |
~/.claude/workflows/<name>/ |
Personal; shared across all your projects |
plugin |
<installed-plugin>/workflows/<name>/ |
Shipped by a plugin; immutable |
Precedence: override > workspace > user > plugin. A workspace-scope workflow named default will shadow this plugin's
default.
Author the easy way:
/workflow create <name> --scope workspace # commit to $REPO/.claude/workflows/
/workflow create <name> --scope user # live under ~/.claude/workflows/
/workflow create <name> --scope override # transient in $CWD/.artifact-override/
This dispatches the conductor workflow in mode: create; it prompts for inputs/outputs/step graph, validates with
scripts/workflow-conformance.py, and writes. Same command structure covers updates (/workflow update <uri>), reviews
(/workflow review <uri>), and deletions (/workflow delete <uri>) — all drive through conductor's mode switch.
Each workflow directory holds a workflow.md (YAML frontmatter: name, description + prose body) and a
manifest.json (structured DSL: inputs, outputs, graph, transitions, dynamic_branches). See
skills/workflow/references/workflow-contract.md for the full
schema.
Artifact templates follow the same rules — put project-specific templates under
$REPO/.claude/artifact-templates/<name>.md, personal templates under ~/.claude/artifact-templates/<name>.md.
Discovery picks them up.
Gitignore reminder: ~/.claude/ is per-user; don't commit it to a project repo. But committing $REPO/.claude/ is
exactly what workspace scope is for — check it in.
Files
agents/worker.md— the single agent role.hooks/*.py— env check, orchestrator lock, PreToolUse rules, PostToolUse progress, SubagentStop release, TeammateIdle rescan, UserPromptSubmit status. Session-start discovery lives in the artifact plugin.scripts/orchestrator-lock.py— per-machine flock.scripts/dispatch-execution.py— shared helper used by workflow-shape templates to instantiate an execution artifact.scripts/workflowlib/— shared python runtime library (lock, env, status, dispatch, rules, conformance, …).scripts/workflow-conformance.py— validates a workflow directory against the contract.skills/workflow/—/workflowentry skill. References underreferences/load on demand.workflows/— four base workflows:default,conductor,plan-do,write-review(each isworkflow.md+manifest.json).artifact-templates/workflow-execution.md— the bootstrap template (/workflow rungoes through this).artifact-schemes/execution/+artifact-storage/execution-gh-pr/— theexecutionvertex scheme and its GitHub-PR-backed storage.tests/test_*.py— pytest suite.DESIGN.md— workflow-side design doc + dated changelog.
Dogfooding
The workflow plugin is a reference plugin for the artifact plugin:
- Every artifact call goes through
artifactlib.provider.dispatch(orartifact/scripts/run-provider.py). - Workflow state lives as artifacts (the
executionscheme) managed by the artifact plugin. - The
conductorworkflow drives CRUD on workflows + templates entirely through the artifact plugin's subcommand surface (create/get/update/delete).
If any cross-plugin link needs a special case, fix the artifact contract — not the consumer.
Not supported
- Writing under any installed plugin's root (blocked by
hooks/pretooluse-no-self-edit.py). To change a built-in workflow, copy it to workspace/user/override scope or open a PR to the plugin repo. - Automatic transfer of artifact locks. Ownership changes are manual (e.g. reassigning a PR on GitHub).
License
Apache-2.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file workflow_plugin-2.2.0.tar.gz.
File metadata
- Download URL: workflow_plugin-2.2.0.tar.gz
- Upload date:
- Size: 17.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
07b9356c45643574a700d3814e7c42a6ddb14a96215782c02deedf69c1172104
|
|
| MD5 |
73ba4c8145cddc4290368e44a8b7b1d1
|
|
| BLAKE2b-256 |
13c449087ae8340f38736c79a6b6db53d6d45d3bd65e884f2999f0b2918f4ca7
|
File details
Details for the file workflow_plugin-2.2.0-py3-none-any.whl.
File metadata
- Download URL: workflow_plugin-2.2.0-py3-none-any.whl
- Upload date:
- Size: 17.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f43e9292d78f0656b25697063508d2be860f594abf39ff072b14095591b55fc5
|
|
| MD5 |
e20141c14fa83f392db86a417d7b4aac
|
|
| BLAKE2b-256 |
07452e3d907341c90098bea477522782b2714a30a36d33e4e10b63907194bab6
|