Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Workgraph Workflow?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/lukacf-workgraph-workflow)
---
name: workgraph-workflow
description: How to use WorkGraph for durable commitments, dependencies, claims, and evidence
requires_capabilities: [work_graph]
---
# WorkGraph Workflow
Use WorkGraph when work must survive sessions, compaction, restarts, schedules,
or coordination between agents. It is the shared commitment graph, not private
scratch space and not semantic memory.
## Operating Rules
- Use `workgraph_create` for a new durable commitment. Keep related work in the
same host-granted namespace. Omitting `namespace` uses the namespace bound
by the host's grant; it is `default` only when that is the granted namespace.
The grant authorizes one immutable realm/namespace scope. Supplying another
namespace string does not switch scope — it is rejected.
- Use `workgraph_ready` to find eligible work. Do not infer readiness from item
fields, blocker counts, due times, or edges yourself.
- Claim an item before doing durable or shared work with `workgraph_claim`.
Include your typed owner and the current `expected_revision`. Set
`lease_seconds` for a lease, or omit it for no expiry. The tool computes
expiry from the store's claim observation time.
- Claim works only on an `open` item, or on an `in_progress` item whose lease
has expired. A `blocks` edge keeps the dependent item `open`: it is not ready
while that blocker is unresolved. A blocker completing removes only that
gate; the item is claimable only when every other readiness condition also
holds (no other unresolved blocker, its child join satisfied, no future
`not_before`, not snoozed). `workgraph_block`
is different: it sets the item's status to `blocked`, which cannot be claimed,
and there is currently no transition back to `open` (an update keeps it
`blocked`). Use it only for work that should stay parked until it is closed.
- Closing is not a way to unblock. `completed` needs the titled outcome to have
actually happened. Cancelling, or replacing the work with a new item, must be a
real decision: keep the history (attach evidence, link the replacement) and do
not create a duplicate of work that already exists.
- If a write fails with a stale revision (the `expected_revision` you passed
is no longer the item's), reload the item with `workgraph_get`
or `workgraph_snapshot`, reconsider the current state, then retry only if the
work still makes sense.
- Every successful mutation advances the item revision. A write (create,
claim, release, update, policy escalate, block, close, add evidence) answers
a short receipt, not the item: the item's `id`, its `revision`, `status` and
`owner` after the write, what `changed`, and `seq`, the write's place in the
event history. A create or an update that changes the item's `finish_by`
target names it in `changed`.
Use the receipt's `revision`, not an older cached one, as the next write's
`expected_revision`. Read the item with `workgraph_get` when you need its
description, labels or evidence; pass `answer: "full"` on a write only when
you need the whole item in that answer.
- The two rules above are for ordinary tool use. They do not hold in a turn
that runs under an attention binding, that is, a turn of a member a goal is
bound to: such a turn is offered only the WorkGraph tools of the binding's
mode and none of your other tools, and it may also carry a
`WorkGraph attention projection` block. Every WorkGraph call of such a turn,
a read included, is served only while the turn's projection is still
current, and the projection is fixed for the turn. Your own first write to
the bound item changes the item,
so every later WorkGraph call of the same turn is refused with "stale or
inactive WorkGraph attention projection", `workgraph_get` included. That is
not a revision conflict: reloading, or passing another `expected_revision`,
does not help. In such a turn read first if you need to, make the one write
that matters most, stop calling WorkGraph tools after it, and say in your
reply what is left to do. A later turn carries a current projection.
Nothing starts that turn for you: it starts when another input reaches you.
The same refusal on a turn's first call means the item, its binding or its
parent changed after the turn started.
- Use `workgraph_link` for real dependencies and relationships. Edges are
permanent; there is no unlink. Use `blocks` (`from_id` blocker, `to_id`
blocked) only when the target must not be ready until the source is
`completed`; a `failed` or `cancelled` blocker keeps the target blocked.
- Use `parent` when an item is one part of a larger commitment. The edge
points from the child (`from_id`) to the parent (`to_id`); add it right
after creating the child, because `workgraph_create` has no parent field.
A parent is not ready while any child is live, and a `failed` or
`cancelled` child keeps a `require_success` parent waiting. The parent's
`failed_child_join_policy` or `cancelled_child_join_policy` changes that:
`accept` lets the parent proceed without that child, while `propagate`
closes the parent with the child's status.
- Attach evidence with `workgraph_add_evidence` for artifacts, PRs, logs,
summaries, external tickets, or other proof that the work changed state.
- To withdraw evidence (a wrong reading, a superseded result), call
`workgraph_add_evidence` with a new ref that lists the earlier ref's `id`
in `withdraws`. Nothing is removed: a ref whose `id` a later ref lists in
`withdraws` is withdrawn and stays on the item. Withdraw only earlier refs
on the same item, never the new ref's own `id` or another withdrawal;
confirmation and execution evidence cannot be withdrawn.
- Close with `workgraph_close` only when terminal truth exists, and always pass
`status`. `completed` means the titled outcome happened. `failed` means it
was attempted and did not happen: a refuted hypothesis or a fix that did not
work is `failed`, with the refutation attached as evidence. `cancelled`
means the work was dropped without a verdict (superseded, out of scope).
Omitting `status` records `completed`, which misfiles anything that did not
succeed. A non-self-attested completion policy can require typed
confirmation evidence before close.
- Release a claim with `workgraph_release` when you are stopping before terminal
completion and the work should be claimable by someone else.
- To be told when an item closes, open a wait with `workgraph_wait` (`id`,
`until: "closed"`, `deadline_at`). It answers at once with a receipt and
never blocks the turn. You are the waiter; the tool takes none. When the
item closes first you are woken once; when the deadline passes first you are
woken once and, if an owner holds the item then, that owner is woken once
too. The tool is listed only while a schedule host serves the waits of your
WorkGraph store; where it is absent no wait can be opened.
- `workgraph_wait` also waits for evidence: `until: "evidence"` wakes you
once when the first evidence record is added to the item after the wait
was opened. Evidence the item already held does not count; the receipt
shows the count the wait started from (`evidence_count_at_open`). If the
item closes first with no new evidence, the wait ends too: it reads
`item_closed`, not `satisfied`, and the wake says the item closed first
(`item_closed_first`).
- With `on: "checklist"` the wait is judged over the item's direct entries
(the items linked to it with a `parent` edge) instead of the item.
`until: "closed"` is met when the entries are done as the item's own child
policies count them (a failed or cancelled entry keeps a parent that
requires success waiting). An entry linked later is part of the checklist.
If the item itself closes first, the wake says so. The timeout wakes you
and the owner of the item, not the owners of its entries. Refused: an item
without entries, and a wait for the close of a checklist that is already
complete.
- Both together: with `on: "checklist"`, `until: "evidence"` is met by the
first evidence on any direct entry, whether written after the wait opened
or brought by an entry linked after it opened. Evidence on the item itself
does not count. The count never falls: nothing unlinks an entry and
nothing removes an evidence record. Such a wait goes on when its entries
are done, because a done entry still takes evidence, and it can be opened
over entries that are all done.
- When a wait's condition is met and its item is closed at once, the
condition counts: the wait is `satisfied` and the wake says the condition
was met. A wait that ended stays as it ended.
- `workgraph_wait_status` reads how your own waits and their wakes stand: for
each wait its item, what it waits for, its deadline, whether it is waiting,
satisfied, timed out or `item_closed` (a wait for evidence whose item
closed first), for an ended wait for evidence or on a checklist what ended
it (`ended_by`: `condition_met`, `item_closed_first`, `deadline_passed`),
and for each of its two wakes (the waiter's, and
after a timeout the item owner's) whether it is not owed, owed, delivered,
undeliverable or owner-not-found. With no arguments it lists the waits that
still wait and the waits that owe a wake, newest first; a wait that ended
and owes nothing is read by its `wait_id`. Arguments: `wait_id`, `id` (the
item), `owed_only`, `limit`. You are offered it wherever your WorkGraph
store keeps waits a host can serve, with or without a timer. It reads only
the calling session's waits (a mob member's: its own), takes no waiter, and
another caller's wait reads exactly as a wait that does not exist. It opens
nothing and fires nothing.
- `workgraph_list` and `workgraph_snapshot` omit terminal items (`completed`,
`cancelled`, `failed`) unless `include_terminal` is true, even when
`statuses` names a terminal status. `workgraph_ready` returns live eligible
items only. To review closed work, pass `include_terminal: true` or read
`workgraph_events`.
- A `labels` filter on list, ready, or snapshot matches only items that carry
every listed label. Filter on one label to widen the result.
- `workgraph_list`, `workgraph_ready`, and `workgraph_snapshot` return one
page: at most `limit` items (100 by default), list and snapshot most
recently updated first, ready by priority and then age. A result with
`truncated: true` has more matching items (`total_items` counts them all);
pass its `next_cursor` back as `cursor` to read the next page rather than
raising `limit`. `workgraph_events` pages forward with `after_seq` set to
the previous page's `next_after_seq`.
- `workgraph_list` and `workgraph_ready` answer one short row for each item,
as `rows`: its `id`, `title`, `status`, `priority`, `owner`, `revision`,
`due_at`, `finish_by` (when it has that target), labels, `evidence_count`
and its two times. That is enough to
choose an item and to claim it with the row's `revision`. Read the item
with `workgraph_get` for its description and evidence (`include_links:
true` adds what it is part of and what blocks it); pass `answer: "full"`
on a list only when you need every item whole.
- Use `workgraph_events` for audit history and `workgraph_snapshot` for a
graph-wide view. Do not reconstruct either from peer chat or task lists.
- An event's `actor` is the caller that wrote it, as the host knows it: a
member's key, or a session's key. An event that follows from your call
names you too: a parent that a failed child ends when you try to claim it
is closed with you as its actor. An event with no `actor` was written with
no caller known to the host; treat it as nobody's own. To follow what
others changed since a sequence number, call `workgraph_events` with
`after_seq` and `exclude_own: true`: your own events are left out and
events with no actor are kept. `labels` on `workgraph_events` keeps only
the events of items that carried every listed label before the event or
after it: the event that takes a label off an item is still in that
label's feed, so you see the item leave; its later events are not. An
event with no item (a link, an attention change) is in no label's feed.
- `workgraph_policy_escalate` and `workgraph_attention_reassign` are available
only with a runtime-bound attention authority. Their absence on an unscoped
surface is intentional.
## Boundaries
- Use builtin `task_*` tools for private, local, lightweight scratch tracking.
- Use WorkGraph for shared durable commitments, dependencies, readiness, claims,
and evidence.
- Use Schedule for time-based wakeups and recurrence. A schedule can wake an
agent, but WorkGraph remains the live work state.
- Use memory for knowledge retrieval and historical context. Memory does not
own live work state.
## Typical Loop
1. Call `workgraph_ready` within the host-granted realm and namespace.
2. Pick an item that matches the current objective.
3. Claim it with the current item revision as `expected_revision`.
4. Do the work.
5. Add evidence for durable outputs.
6. Update the item if the scope, timing, priority, or labels changed.
7. Close it with an explicit `status` only when the outcome is terminal, or
release it if another agent should continue.
Steps 5 to 7 in one turn are for ordinary tool use. In a turn under an
attention binding only one of them can be done on the bound item; the others
wait for later turns (see Operating Rules).