graff — a fast agentic coding harness in Zig: multi-provider, MCP, workflows, DGM evolution loop, TS/Python SDKs
Python
Release v0.0.302.18
justrache62ca653ee05
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 8c9568d5..4123a563 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -12,10 +12,22 @@ current is part of cutting a release.## v0.0.302.18+### Terminal UI++- The fullscreen UI is now a separate client. `graff tui` launches an installed `graff-tui` (the sibling binary first, then `PATH`) with its arguments unchanged, and never downloads one. In a terminal, `graff` and `graff repl` start the line REPL. The embedded renderer, its adapters and fixtures are removed (ADR 0245).++### Speed and cost++- Heads-ups are one short line in the same response as their tool calls, and a script that computes an answer is its own proof, so the model no longer recomputes it a second way. `read_file` is required only before editing an existing file. A call's time follows the tokens it writes (ADR 0239, #1478).+- rlm: a slim view names the fields the whole value holds, the slim rule says to compute over results inside the same script, and an unbound call or `each()` prints its result (ADR 0240, #1479).+- On the Responses wire, prose tightens the stall budget only while its output item is open. A model that writes a heads-up and then composes its tool calls in silence gets the full budget instead of a false stall and a repeated generation (ADR 0241, #1480).+- The `shell` tool names the python3 the shell runs, read from where `python3` on `PATH` resolves and never by running it, so scripts stop using features that version lacks (ADR 0242, #1481).+- On the ChatGPT plan and the OpenAI platform, the project instructions and layout ride as their own input item. The instructions are then identical in every repo and are read from the cache on a new repo's first call (ADR 0243, #1483).+### Sessions- Live sessions show meaningful activity age, deterministic recent-first ordering, and separated rows without repeated identifiers. Resume errors distinguish live identifiers from saved keys. (#1459–#1464)-- Saved workspaces remain discoverable after their processes exit. Workspace-qualified targets distinguish same-named conversations, and cross-project resume enters the selected workspace before restoring history. (#1457, #1458)+- Saved workspaces remain discoverable after their processes exit. Workspace-qualified targets distinguish same-named conversations, and cross-project resume enters the selected workspace before restoring history (ADR 0244). (#1457, #1458)### Recoverydiff --git a/docs/releases/v0.0.302.18.md b/docs/releases/v0.0.302.18.mdnew file mode 100644index 00000000..aa526ebb--- /dev/null+++ b/docs/releases/v0.0.302.18.md@@ -0,0 +1,87 @@+# Codegraff v0.0.302.18++This release makes turns on the Responses wire shorter and cheaper, moves the+fullscreen UI to its own client, and fixes session discovery and tool+recovery. Measured with this release's code against the previous release and+against Pi 1.0 with its codemode:++## Evals++On a ChatGPT plan, interleaved over 11 tasks (five MCP tasks, a git digest and+five solo coding tasks), 3 runs each, 8 at a time. Cost is the list price of+each run's tokens. Every arm passed every run.++### gpt-6.1-sol: ahead of Pi with codemode on time, cost and cache hits++| | Pass | Wall per task | Median | List cost per task | Cache hit | Output tokens per task |+| --- | ---: | ---: | ---: | ---: | ---: | ---: |+| v0.0.302.17 | 33/33 | 38.8s | 35.0s | $0.0272 | 84.0% | 855 |+| **v0.0.302.18** | 33/33 | **31.7s** | **25.3s** | **$0.0212** | **86.5%** | 687 |+| Pi 1.0 + codemode | 33/33 | 33.7s | 27.9s | $0.0277 | 47.8% | 613 |++### gpt-6-astra: 21% less time than the previous release, the lowest cost of the three++| | Pass | Wall per task | Median | List cost per task | Cache hit | Output tokens per task |+| --- | ---: | ---: | ---: | ---: | ---: | ---: |+| v0.0.302.17 | 33/33 | 50.7s | 41.8s | $0.120 | 90.3% | 800 |+| **v0.0.302.18** | 33/33 | **40.0s** | 31.8s | **$0.113** | 89.5% | 725 |+| Pi 1.0 + codemode | 33/33 | 40.8s | 31.5s | $0.138 | 54.8% | 670 |++On gpt-6-astra the two are level on time; graff's cost stays lower because most+of its input is read from the cache.++## Shorter turns++A model call's time follows the tokens it writes, not the size of the context+it reads. graff's calls wrote more than they needed to:++- **Narration.** Heads-ups are now one short line in the same response as+ their tool calls, instead of a short paragraph before most calls+ ([ADR 0239](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0239-heads-ups-are-one-line-and-a-computed-answer-is-its-own-proof.md)).+- **Second derivations.** A script that computes an answer is its own proof;+ the model no longer recomputes it a different way in the same script.+- **Reads of files about to be created.** `read_file` is required only before+ editing an existing file.+- **rlm round trips.** A slim view names the fields the whole value holds, the+ slim rule says to compute over results inside the same script, and an+ unbound call or `each()` prints its result+ ([ADR 0240](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0240-a-slim-view-names-its-fields-and-one-script-fetches-and-computes.md)).+- **Version errors.** The `shell` tool names the python3 the shell runs, read+ from where `python3` on `PATH` resolves, never by running it+ ([ADR 0242](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0242-the-shell-tool-names-python3s-version.md)).+- **False stalls.** Prose tightens the stall budget only while its output+ item is open. A model that writes a heads-up and then composes several tool+ calls in silence gets the full budget, instead of a reconnect that repeats+ the whole generation+ ([ADR 0241](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0241-prose-tightens-the-stall-budget-only-until-its-item-closes.md)).++## The instructions cache across repos++The ChatGPT-plan backend renders the tools and then the instructions, and+caches the instructions as one unit. They used to carry the project's+instruction file and its layout, so a new repo's first call reused nothing of+them. On the ChatGPT plan and the OpenAI platform those two blocks now ride as+their own input item, and the instructions are identical in every repo+([ADR 0243](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0243-repo-context-rides-as-an-input-item-on-responses.md)).+Other providers send what they sent before.++## The fullscreen UI is a separate client++The fullscreen UI is maintained in its own repository. `graff tui` now+launches an installed `graff-tui` (the sibling binary first, then `PATH`) with+its arguments unchanged, and never downloads one. In a terminal, `graff` and+`graff repl` start the line REPL+([ADR 0245](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0245-fullscreen-tui-is-an-external-client.md)).++## Sessions and recovery++- Live sessions show their activity age, list most recent first, and resume+ errors tell a live identifier from a saved key (#1459–#1464).+- Saved workspaces stay discoverable after their processes exit, and+ cross-project resume enters the selected workspace first+ ([ADR 0244](https://github.com/justrach/codegraff/blob/v0.0.302.18/docs/adr/0244-saved-workspaces-have-durable-discovery.md),+ #1457, #1458).+- Empty or format-only pastes recover a clipboard image or warn (#1468).+ Stale MCP registrations return recovery guidance, and disconnected tools+ leave the next catalog without any call being replayed (#1465, #1467).+ Account-backed model selections tolerate gaps in dynamic catalogs (#1466).diff --git a/scripts/eval/tier1-manifest.json b/scripts/eval/tier1-manifest.jsonindex d77da252..5db56cac 100644--- a/scripts/eval/tier1-manifest.json+++ b/scripts/eval/tier1-manifest.json@@ -14,7 +14,7 @@"src/main.zig","src/repl.zig"],- "test_count_baseline": 3126,+ "test_count_baseline": 3140,"test_count_slack": 25,"required_invariants": [{diff --git a/src/cli.zig b/src/cli.zigindex 7b25c364..87696976 100644--- a/src/cli.zig+++ b/src/cli.zig@@ -24,6 +24,9 @@ pub const changelog_text =\\What's new\\──────────\\0.0.302.18+ \\ • graff tui launches the separate fullscreen client; terminals get the line REPL+ \\ • shorter turns: one-line heads-ups, no recomputed answers, fewer false stalls+ \\ • instructions cache across repos; the shell names python3's version\\ • clearer session lists and cross-project resume\\ • paste warnings, MCP recovery, and catalog-tolerant model selection\\