You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
release: GraphStack v4.3.0 — deterministic process gate
Adds mechanical handoff enforcement so Architect → Builder steps are harder to skip silently, while keeping the full MD-based orchestrator workflow unchanged.
New CLI: graphstack gate (check / hook cursor / hook claude) and graphstack state (handoff/STATE.json). Hook adapters for Cursor (.cursor/hooks.json) and Claude Code (.claude/settings.json). Portable gate-hook.ps1 / gate-hook.sh shims resolve py -3 vs python on Windows.
Gate rules: deny code commits/edits without a board task in doing/; deny commits when BRIEF.md is still the template; advisory STATE.json staleness on turn end. Fail-open on hook errors; bypass via GRAPHSTACK_GATE=off.
Also: framework handoff hygiene (.graphstack-framework + validate warnings), Builder/Orchestrator confirmation fix, token rules condensed to TOKEN_OPTIMIZER.md, README/CHANGELOG updated. 74 tests passing.
Co-authored-by: Cursor <cursoragent@cursor.com>
Copy file name to clipboardExpand all lines: .cursor/skills/architect/ARCHITECT.md
+1-4Lines changed: 1 addition & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -159,7 +159,4 @@ When `handoff/REVIEW.md` has a rejection:
159
159
160
160
## Token Rules (Architect)
161
161
162
-
- Read GRAPH_REPORT.md once per session — never twice
163
-
- Query graph.json for structural questions instead of reading multiple files
164
-
- If you need to read a raw file: read only the relevant function/class, not the whole file
165
-
- Never produce output the user didn't ask for
162
+
Follow `orchestrator/TOKEN_OPTIMIZER.md` (loaded at session start). Architect-specific: graph before raw files; one targeted read if the graph is insufficient; no output the user didn't ask for.
Read GRAPH_REPORT.md once → never again this session
171
-
Read each file maximum once → use context after
172
-
Parallel file reads when possible → one tool call, multiple files
173
-
No speculative reads → only read what the brief requires
174
-
No output longer than needed → code + brief explanation only
175
-
```
167
+
Follow `orchestrator/TOKEN_OPTIMIZER.md` (loaded at session start). Builder-specific: read only brief-listed files; parallel reads in one tool call; no speculative exploration.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+22Lines changed: 22 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,28 @@ All notable changes to GraphStack are documented here.
4
4
5
5
---
6
6
7
+
## [v4.3.0] — 2026-06-11
8
+
9
+
### Added
10
+
-**`graphstack gate`** — deterministic process enforcement: `gate check` (CI/manual), `gate hook cursor`, `gate hook claude`. Rules: deny code commits/edits when no board task is in `doing/`, or when `BRIEF.md` is still the template. Fail-open on hook errors; bypass via `GRAPHSTACK_GATE=off` or `handoff/.gate-off`.
11
+
-**`graphstack state`** — machine-readable `handoff/STATE.json` (`set` / `get` / `clear`) for hook verification and resume.
12
+
-**Hook adapters** — `.cursor/hooks.json` (Cursor 3.x, `version: 1`) and `.claude/settings.json` (Claude Code `PreToolUse` + `Stop`). Installer writes OS-specific commands (`gate-hook.ps1` on Windows, `gate-hook.sh` on Unix).
-**`.graphstack-framework` marker** — `validate` warns when the framework repo ships dirty handoff state (non-template brief, `done/` tasks, active `STATE.md` entries).
-**ORCHESTRATOR** — token tier detail moved to `TOKEN_OPTIMIZER.md` (reference only); state persistence now includes `state set`.
19
+
-**BUILDER** — removed duplicate user confirmation at activation (Orchestrator brief confirmation is the single human gate); activation now runs `state set` and builds immediately.
20
+
-**ARCHITECT / BUILDER** — token rules condensed to pointers to `TOKEN_OPTIMIZER.md`.
21
+
-**CI** — `graphstack gate check` step; required-files manifest includes gate modules and hook shims.
22
+
-**README** — Process Gate section; Limitations updated.
23
+
24
+
### Fixed
25
+
-**Windows hook launcher** — hooks no longer hardcode `python` (often missing on Windows); shims prefer `py -3`.
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+14Lines changed: 14 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -56,6 +56,20 @@ When you introduce a copy change, restart Cursor once locally (and mention that
56
56
57
57
---
58
58
59
+
## Framework repo: reset `handoff/` before release commits
60
+
61
+
This repository **is** GraphStack (marker: `.graphstack-framework`). The `handoff/` folder ships as **empty templates** for projects that run `install.sh` — not as a log of our own development cycles.
62
+
63
+
Before pushing framework changes to GitHub:
64
+
65
+
1. Restore `handoff/BRIEF.md`, `handoff/REVIEW.md`, and `handoff/STATE.md` to their templates (no real task content).
66
+
2. Remove any `handoff/board/done/*.json` and `handoff/STATE.json`.
67
+
3. Run `python -m graphstack validate` — warnings `framework_*` should be zero.
68
+
69
+
Consumer projects keep their handoff history; only this source repo resets.
70
+
71
+
---
72
+
59
73
## Pull Request Guidelines
60
74
61
75
-**One PR per change.** Don't bundle unrelated edits.
[](https://cursor.sh)
13
13
[](https://claude.ai/code)
14
14
15
15
</div>
16
16
17
-
> **v4.2 highlights:**`graphstack run` — token-safe shell output for git/tests (quality-preserving compaction, no external deps). Plus v4.1: `pip install -e .`, `validate` / `doctor`, CI graph checks. See [CHANGELOG.md](CHANGELOG.md).
17
+
> **v4.3 highlights:**`graphstack gate` — deterministic handoff enforcement via Cursor + Claude Code hooks (brief + board task required before code changes). Plus v4.2 `graphstack run` (token-safe shell output), v4.1 `validate` / `doctor`. See [CHANGELOG.md](CHANGELOG.md).
18
18
19
19
---
20
20
@@ -306,7 +306,7 @@ GraphStack is a **workflow protocol** (markdown + handoff files), not a runtime
306
306
307
307
| Topic | Reality |
308
308
|-------|---------|
309
-
| Role automation |The Orchestrator state machine lives in `ORCHESTRATOR.md`. Models can skip Activation or transitions unless you use discipline + `graphstack validate`. |
309
+
| Role automation |Prompts alone cannot guarantee discipline. v4.3 adds **`graphstack gate`** (hook-enforced) + `state set` + `validate`. Hooks block code commits/edits without a claimed board task; turn-end hooks are advisory only. |
310
310
| Token savings | The table above is **estimated**, not guaranteed. Small repos or undisciplined sessions may use **more** tokens than unstructured chat. |
311
311
| Knowledge graph | Value appears on **20+ file** codebases with module boundaries. Meta-repos full of markdown produce noisy graphs — use `.graphifyignore` (included in this repo). |
312
312
| Setup | Graphify + GraphStack install + `/graphify` + Cursor — four steps, not zero-config. |
@@ -347,6 +347,29 @@ Independent Python implementation (MIT) — inspired by common agent-tooling pat
347
347
348
348
---
349
349
350
+
## Process Gate (`graphstack gate`)
351
+
352
+
v4.3 adds **mechanical enforcement** so Architect → Builder → Reviewer steps are harder to skip silently.
353
+
354
+
| Rule | What it blocks | Platform |
355
+
|------|----------------|----------|
356
+
| R1 |`git commit` touching code while `handoff/board/doing/` is empty | Cursor + Claude Code |
357
+
| R2 | Edit/Write on code paths while `doing/` is empty | Claude Code (`PreToolUse`) |
358
+
| R3 | Commit while `BRIEF.md` is still the template and a task is in `doing/`| Both |
359
+
| R4 |*(advisory)*`STATE.json` not updated this cycle | Turn-end hooks |
360
+
361
+
```bash
362
+
python -m graphstack gate check # CI / manual — exit 1 on violation
363
+
python -m graphstack state set --role builder --task my-feature
**Install** writes `.cursor/hooks.json` and `.claude/settings.json` with OS-specific shim commands (`scripts/gate-hook.ps1` on Windows, `scripts/gate-hook.sh` on macOS/Linux). Hooks **fail open** if Python is missing — a crashing gate is worse than no gate.
368
+
369
+
> **Framework repo note:** This GitHub repo ships `handoff/` as **templates** (empty brief, no `done/` tasks). Your installed project fills those files during real work. Before contributing here, reset handoff — see [CONTRIBUTING.md](CONTRIBUTING.md).
0 commit comments