Skip to main content

workgraph

workgraph orchestrates development workflows declared as graphs. Nodes run agents or commands; a node's outcome selects the transition to follow. The developer writes the workflow once and starts a run from a harness session with /workgraph. The run prints one progress line per node. One command resumes a stopped run.

The CLI bundles workflow and agent definitions; Workflow files lists them. This repository runs the bundled wg workflow on itself:

flowchart TD
    design([design])
    design -->|done| approve-design
    approve-design -->|accept| plan
    approve-design -->|reject| design
    plan -->|done| approve-plan
    approve-plan -->|accept| implement
    approve-plan -->|reject| plan
    implement -->|done| test
    test -->|pass| review
    test -->|fail| implement
    review --> code-review
    review --> overengineering-review
    review -->|pass| pr
    review -->|fail| review-loop
    review-loop -->|pass| implement
    review-loop -->|fail| implement
    review-loop -->|LIMIT| summary
    summary -->|done| pr
    pr -->|done| END

Install

As a Claude Code plugin:

/plugin marketplace add sylmarien/workgraph
/plugin install workgraph@workgraph

Installing the plugin adds the /workgraph skill. The plugin's install skill installs the CLI with uv, and its update skill upgrades it. Both check that uv is on PATH and install nothing else.

The CLI bundles workflow and agent definitions. A user's own definitions shadow them; see Workflow files for the bundled definitions and the resolution order.

As a Codex plugin:

codex plugin marketplace add sylmarien/workgraph
codex plugin add workgraph@workgraph

Start a new Codex session and invoke $workgraph <workflow> "#<issue>". The plugin shares the install, update, and run skills with the Claude Code plugin. The bundled workflows run nodes on the Claude harness, so they require claude and uv on PATH in Codex too.

Codex reads the repository's existing marketplace at .claude-plugin/marketplace.json and its manifest at .codex-plugin/plugin.json. Both plugins ship in the same Git release. The patch, minor, and major release workflows update both manifests and the CLI to the same version. See the Codex packaging documentation.

Without the plugin:

uv tool install workgraph

pip install workgraph installs the same package from PyPI. uv tool upgrade workgraph upgrades it. Requires Python 3.12+. An agent node additionally requires the CLI of its harness on PATH: claude for harness = "claude", codex for harness = "codex".

Example

workgraph run wg "#12"
design: done
approve-design: parked
parked at approve-design: Plan from this design? · spent 1m20s · $0.15
Review material from design:
https://github.com/sylmarien/workgraph/issues/12#issuecomment-5550441682
workgraph resume --decision accept
approve-design: accept
plan: done
approve-plan: parked
parked at approve-plan: Implement this plan? · spent 4m05s · $0.42
Review material from plan:
<the plan>

workgraph resume --decision accept delivers the decision and resumes the run.

Reference

Development

uv sync
uv run ruff check && uv run ruff format --check && uv run mypy && uv run pytest

The dogfood workflow runs the same gate: workgraph run wg "#<issue>".

Release files for workgraph 0.3.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for workgraph 0.3.4
File Size Uploaded
workgraph-0.3.4.tar.gz 38.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for workgraph 0.3.4
File Interpreter ABI Platform
workgraph-0.3.4-py3-none-any.whl Python 3 none any Details

Total release size: 85.3 kB

Release files / workgraph-0.3.4.tar.gz

Download URL workgraph-0.3.4.tar.gz
Size 38.0 kB
Tags Source
SHA-256 checksum
How to use checksums
8984846e6120927dbfaa1b39291bb1a198b3eb879f40021b2ad8a558a63572ff
BLAKE2b-256 checksum
How to use checksums
f4da0e5e60ca185d586e9ba383e4018b943b414d5aca678d02be7d6c63aa0b78
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / workgraph-0.3.4-py3-none-any.whl

Download URL workgraph-0.3.4-py3-none-any.whl
Size 47.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d169a79e83758219c4d03a9bd56925ad317336b20b7d4ef611262d61d5385f24
BLAKE2b-256 checksum
How to use checksums
81d26ef02c2432cfc10c62495bef1a54d48a57b8544a16c89b84d9e3036e41f9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.18 {"installer":{"name":"uv","version":"0.12.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

0.3.5

2 release files

This release

0.3.4 This release

2 release files

0.3.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page