Gates can now hand back a verdict, not just pass or fail. Point gate at a script that prints JSON and its output becomes the child's structured output, so workflow scripts and lane logic can branch on a post-run classifier without the parent ever reading the child's report. This release also fixes two startup annoyances: terminals that embed Ghostty (like cmux) no longer trigger the Ghostty inspector and its AppleScript errors, and machines without npm start up without a stray command not found line.
Highlights
- Typed gates:
gate: { command, output: "json" }turns a script's JSON stdout into the child'sstructuredOutput, optionally validated against a schema. Bad or empty output fails the gate instead of silently losing the verdict. - Ghostty detection only activates for the standalone Ghostty app, so cmux and other embedding terminals stop getting
-1728/-2741AppleScript errors or the wrong window. - Hosts without
npmstart quietly. - The tool reference no longer claims a default
maxOutputcap that never existed.
Changelog
Highlights
- Gates can now return a JSON verdict. Point
gateat a script that prints JSON, and its output becomes the child's structured output, so workflows can branch on a post-run check without the parent reading the child's report. - Ghostty detection no longer misfires inside terminals like cmux that embed Ghostty, so you stop seeing AppleScript
-1728/-2741errors or the wrong window being targeted. - Hosts without
npmstart up quietly instead of printingnpm: command not found.
Added
- Typed gates:
gateaccepts{ command, output: "json", schema?, timeoutMs? }alongside the plain string form. When the command passes, its JSON stdout becomes the child'sstructuredOutput(validated againstschemawhen given). Empty, truncated, or invalid output fails the gate rather than silently dropping the verdict. Typed gates always run (they are never cached), and a run cannot combine one with anoutputSchema. Seedocs/for using command-runner agents as typed workflow steps andexamples/typed-gatefor a runnable example.
Fixed
- The Ghostty inspector only activates when the macOS host bundle id identifies the standalone Ghostty app. Terminals that embed Ghostty (such as cmux) set
TERM_PROGRAM=ghosttytoo, which previously targeted an unrelated Ghostty window or emitted-1728/-2741AppleScript errors; those hosts now fall back to theinspector.commandhint. Thanks to @wangpi26 for #2281. - Hosts without
npmno longer print/bin/sh: npm: command not foundduring startup; global package-root discovery is optional and now stays silent when the package manager is missing. Thanks to @PhrZer for #2287. - Fixed
docs/tool-reference.md, which claimed a defaultmaxOutputcap of 200 KB / 5,000 lines. The cap applies only whenmaxOutputis set.