graph-engineering
Builds a graph-of-plans for end-to-end one-shots: research then questions (must ask; do not guess), then a master graph covering docs-in, architecture, design/UI UX, build, integrate, evaluate, actually run, multiple trials, and docs-out. Each node has a linked sub-plan; approving the graph runs it. Use for entire products or major features when the user invokes /graph-engineering or says "graph this plan", "one-shot this project", or "run this as a graph". Do not load unless the user named it. Not graphify. Not for 1–3 step real chains.
- License 许可
- MIT
- 最近更新
- 2026-09-15
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- graph-engineering
- license
- MIT
- trigger
- /graph-engineering
- description
- Builds a graph-of-plans for end-to-end one-shots: research then questions (must ask; do not guess), then a master graph covering docs-in, architecture, design/UI UX, build, integrate, evaluate, actually run, multiple trials, and docs-out. Each node has a linked sub-plan; approving the graph runs it. Use for entire products or major features when the user invokes /graph-engineering or says "graph this plan", "one-shot this project", or "run this as a graph". Do not load unless the user named it. Not graphify. Not for 1–3 step real chains.
- argument-hint
- [plan path or leave blank to use the current nawab plan]
- disable-model-invocation
- true
02 资源文件 4
- 参考文档GRAPH.template.md4.0 KB
- 参考文档LIFECYCLE.md3.9 KB
- 参考文档NODE.template.md1.5 KB
- 参考文档TOPOLOGIES.md5.3 KB
03 SKILL.md 正文
Graph Engineering
The graph is the plan you look at. Nawab §0–§18 still captures scope (north star, blockers, commit discipline). This skill owns shape and scale: what can run at once, which slice owns which files, and the per-node plans that execute those slices.
Each node is a bounded workstream with its own plan file. The master graph must list a markdown link to every node plan so you can open any slice without hunting.
XOR with graph-of-loops. That skill uses the same lifecycle but each
node is maker + checker until a stop command holds. If the user named both,
stop and ask which wins. Do not compile both into §19.
Not graphify. graphify maps a codebase. This skill shapes execution.
Template: GRAPH.template.md
Node plan: NODE.template.md
Lifecycle: LIFECYCLE.md
Topologies: TOPOLOGIES.md
Persistence
Once loaded, stay on the graph for the whole run — every wave, including resume after a dead session. Do not drift back to one sequential agent holding the entire project. Ponytail on every code write.
Off only: "stop graph" / "run it linearly" / user reverts to §18.
When to load
Load only when the user named this skill. Signals:
/graph-engineeringor@graph-engineering- "graph this plan" / "graph engineering" / "run this as a graph"
- "one-shot this project" / "one-shot this feature"
Do not load because Plan mode is on or nawab-plans loaded. Do not load
if the user named graph-of-loops instead (XOR).
Skip the fleet (one-node or short chain in §19) when the work is a real 1–3 step dependency. Do not invent nodes or nested plans for a hotfix.
This skill is for entire products and major features — research through shipped software, proven by running it, then docs. Long, quality-rich, parallel work.
Hierarchy (depth 2, no more)
EXECUTION_GRAPH.md ← what you approve and read
plans/nodes/<id>.md ← one collapsed plan per node (linked from the graph)
- Graph — topology, contracts, waves, links to every node plan.
- Node plan — feature-mode nawab, collapsed: objective, paths, commits, gate, return contract. Not a second 18-section master.
- Stop. A node plan does not spawn another graph unless the user names this skill again for that slice.
Cursor primitives (not Claude Code)
Do not emit JS orchestration scripts or .claude/workflows/.
| Idea | Cursor |
|---|---|
| Node | One Task (or lead job) that executes that node's plan against a JSON return contract |
| Node plan | plans/nodes/<id>.md — the only authority that node agent loads |
| Edge | Named artifact that actually crosses (schema field, file, list) |
| Fake "and then" | No Task, no wait — two node plans, same wave |
| Fan-out | Multiple Tasks in one message, each prompted with its node-plan path |
| Plumbing | Lead code (flatMap, dedupe) — no extra node, no extra plan |
| Barrier / merge | Lead waits; one merge node whose plan sees the whole set |
| Verifier | Readonly Tasks that try to kill findings before they flow on |
| Isolation | Disjoint write paths. Cloud worktrees only if the user asked |
| Cycle | seen set; dry stop after 2 empty rounds; dedupe vs seen |
| Model | composer-2.5-fast on extract/classify; inherit on merge/judge |
| Concurrency | Readonly: fan out freely. Writers: 2–4, disjoint paths |
If a model slug is not in the session list, use inherit. Never guess.
Gate 0 — Research, then questions (blocking)
Before nawab §19, node plans, or approval. Asking is expected. Do not smooth over uncertainty.
- Research the repo or state greenfield. 5–10 lines of what you found.
- Ask numbered questions. Split must-answer (blocks compile), trade-off (neither option is obviously better — show both, ask PRIORITY), and optional (state the default).
- Stop. Wait. Do not compile the graph on guessed architecture, UX, tenancy, or "we will figure it out in the node."
Full rules and the trade-off block: LIFECYCLE.md.
End-to-end coverage
A full one-shot graph includes every lifecycle stage or marks
N/A — [reason]. Catalog: LIFECYCLE.md.
| Stage | Must mean |
|---|---|
| Docs-in | Existing docs good enough to plan, or listed gaps |
| Architecture | Boundaries + remaining trade-offs decided with the user |
| Design / UI UX | Required if there is a user-facing surface |
| Build | Fan-out slices with real edges only |
| Integrate | Barrier over the slices |
| Evaluate | Tests / evals that can fail |
| Run | Boot it — not only unit tests |
| Trials | More than one run (happy, empty, error, one regression) |
| Docs-out | README (and companions) after it works — readme skill |
A graph that ends at "code written" is incomplete.
A. Drafting (skill named, not yet approved)
- Gate 0 — research, then questions. Wait for answers.
- Draft nawab §0–§18 for scope.
- Compile the graph of plans (checklist). Cover the lifecycle. Write every node plan before approval so the links work.
- Put the graph in §19 and on disk as
EXECUTION_GRAPH.md. - Approval footer: Approving this graph starts execution immediately. Node plans are linked. Lifecycle stages are listed (or N/A).
- Stop. Wait only for that approval.
B. On approval, or skill named on an already-approved plan
- If the graph or any node plan is missing, compile first.
- Run immediately. Each node Task gets: repo path, node-plan path, input artifact, output schema, write paths, Do NOT commit.
- Follow Execute protocol.
Compile checklist
Gate 0 must already be done. Read LIFECYCLE.md. Read TOPOLOGIES.md if the shape is not a simple diamond.
- Start from the lifecycle catalog. Add/split nodes from nawab §5–§9.
Mark unused stages
N/A — [reason]on the graph. - Cut fake edges: if B does not read A's output, they are the same wave.
- Contract every node (in schema, out schema). Pass inputs explicitly.
- Mark remaining edges
plumbing|agent|verify. - Pick topology; emit waves. Barrier only when a stage needs the whole set.
- Write
plans/nodes/<id>.mdper node from NODE.template.md. Map commits onto the parent §9 matrix; writers must not overlap. - Fill GRAPH.template.md. Node plans table is required — every row is a working markdown link. Include Lifecycle.
- Tiny real chains stay a chain. Do not pad.
Save agents for judgment. Not for plumbing.
Output contract
Show in chat, not only in files:
- The mermaid graph
- The Node plans table with clickable links
- Lifecycle table (every stage present or N/A)
- Wave table (counts, where the barrier is)
- Edges cut, and why
- Model tiers: which nodes run cheap
During a wave: name wave, node ids, model; after: survivors vs dropped.
Execute protocol
If §19 is filled, §18 defers to these waves.
- Refresh
EXECUTION_GRAPH.mdfrom §19 (must still contain the node-plan links). - Ponytail on every code write.
- Per wave: spawn independent
Tasks in one message. Each prompt includes only that node's plan path plus its input artifact — not the whole master nawab. Null/empty → drop; fan-in tolerates missing inputs. - Lead runs
plumbing. Spawn merge/verify only when judgment is required. - Barrier only when the next node needs every prior result together.
- Conditionals: schema-bounded classify, then
if/switchin the lead. - Cycles: persist
seen(sidecar JSON or in the graph). Stop after 2 dry rounds. - Checkpoints: after each wave, update
EXECUTION_GRAPH.md(wave status) andPROGRESS.md. A later session resumes at the next pending wave — do not restart the project in one context. - Lead owns git, gates, PROGRESS, PR. Subagents do not commit. One §9 row per commit. Human checkpoint only if the node plan marks it (prod / freeze).
Pairing with nawab-plans
| Default nawab | This skill named | |
|---|---|---|
| What you read | Linear §0–§18 | The graph + linked node plans |
| §19 | N/A |
Required: graph + links to every node plan |
| Approval | Then implement per §18 | Approve graph → run |
| Extra wait | — | None per node |
Never auto-chain from nawab-plans. Nawab §0–§18 stay the scope contract. The graph is the execution program. Node plans are additive files.
Anti-patterns
- Loading this skill because Plan mode is on
- Compiling the graph before Gate 0 answers (guessing architecture or UX)
- Skipping trade-off questions when two options are both valid
- Graph that ends at "code written" with no run / trials / docs-out
- Graph with no working links to node plans
- 18-section nawab per node (collapse; depth 2 only)
- Node plan that spawns another graph unasked
- Treating "and then" as an edge when no data crosses
- Spawning an agent to flatten or dedupe
- One Task prompt that pastes every node plan (kills the point of the graph)
- Restarting from wave 0 after a dead session instead of the checkpoint
- Parallel writers on the same files
- Loading this skill and
graph-of-loopsin one plan - Confusing this skill with
graphify - Inventing a fleet for a 1–3 step real chain
- Guessing a
modelslug not in the session list
04 同仓库更多 Skills
greet
A greeting skill for testing
valid-skill
A valid skill for testing purposes.
unknown-field
A skill with an unknown frontmatter field.
no-frontmatter
暂无简介
child-skill
A nested skill in a subdirectory.
different-name
A skill with a name that doesn't match the directory.