Skip to content

v1.92.15.0 feat: plan reviews check facts and keep one task list; /office-hours hands its wireframe to design review (#340, #513, #973, #1048, #1791) - #3775

Merged
capy-ai[bot] merged 20 commits into
mainfrom
garrytan/gsta228-planning-wave
Nov 1, 2026
Merged

capy-ai[bot] merged 20 commits into
mainfrom
garrytan/gsta228-planning-wave

Conversation

@garrytan

@garrytan garrytan commented Nov 1, 2026 •

Copy link
Copy Markdown
Owner
{
  "schema_version": 1,
  "pr": 3775,
  "head": "981cc5301b81288b80e820eb5c155b637eaaf548",
  "version": "1.92.7.0",
  "base": "main",
  "gate": {
    "free": {
      "tests_ran": 24683,
      "fail": 0
    }
  },
  "session_kind": "unattended",
  "head_tree": "e8536b2dc12342e750ace7fd7d09b07f719a4a45",
  "product_patch_id": "f7eaa17bd925ab392834f2961a196f50bf5c5747",
  "gstack_version": "1.91.379.0",
  "review_depth": {
    "depth": "standard",
    "class": "code",
    "runtime_lines": 638,
    "rules": "150435b0a543019a",
    "base": "5b7b0950b80180ff9eee1fc424efffe27ebacf59",
    "registry": "5b7b0950b80180ff9eee1fc424efffe27ebacf59",
    "gate_scan": {
      "tagged": 0,
      "head": "981cc5301b81288b80e820eb5c155b637eaaf548"
    },
    "reasons": [
      "runtime=638>50"
    ]
  },
  "pregate": "requires-remote cleared @e8536b2dc123 (7 checks, current for 981cc5301b81)",
  "requires_remote": [
    "free-tests.yml/cso-macos-launcher: https://github.com/garrytan/gstack/actions/runs/41263307721",
    "free-tests.yml/macos-named-regressions: https://github.com/garrytan/gstack/actions/runs/41263307721",
    "windows-free-tests.yml/windows-free-shard: https://github.com/garrytan/gstack/actions/runs/41263307894",
    "pregate.json/remote_gate: remote-gate tree=e8536b2dc123 tests=24683 receipt=/home/user/.capy/work/gsta228/ship/remote-gate.txt sha256=54c5e2172534"
  ],
  "issues": {
    "fixes": [
      340,
      513,
      973,
      1048,
      1791
    ],
    "refs": [],
    "flakes": []
  },
  "docs": {
    "status": "updated",
    "scope": "docs/, README.md, AGENTS.md, CONTRIBUTING.md (troubleshooting entries read in full; others by grep)"
  },
  "review_loop": {
    "passes": 1,
    "blocking_found": 3,
    "deferred": 0,
    "noted": 2,
    "fixed": 9,
    "scope": "frozen",
    "fix_checks": 2,
    "dispatches": {
      "specialist": 3,
      "red-team": 1
    }
  }
}

What changed

gstack-plan-reality check on a plan that cites a missing file and a line past the end: main passes it, this branch opens each receipt and holds the phase open

Plan reviews no longer accept a file:line citation they never opened: a missing file or a line past the end now fails the phase with REALITY_RECEIPT_UNRESOLVED (#973).

Before/after as text: gstack-plan-reality check on a plan citing a missing file and a line past the end: main passes it, this branch opens each receipt and holds the phase open
--- Before · before.txt · captured output
+++ After · after.txt · captured output
+PLAN_REALITY: phase=eng rows=7/7 missing=none unresolved=premise-table,already-done verdict=incomplete
+RECEIPT_UNRESOLVED: premise-table lib/does-not-exist.ts:12 no such file
+RECEIPT_UNRESOLVED: already-done lib/a.ts:99 line 99 is past the end (3 lines)
+gstack-plan-reality check: a `REALITY:` receipt names a file the checkout does not have, or a line past its end (phase eng: premise-table lib/does-not-exist.ts:12 (no such file); already-done lib/a.ts:99 (line 99 is past the end (3 lines))); fix: open the cited file and cite the line that holds the evidence; when the evidence lives in another checkout, pass `--root <dir>` for it (REALITY_RECEIPT_UNRESOLVED)
+exit=1
-PLAN_REALITY: phase=eng rows=7/7 missing=none verdict=complete
-exit=0

Plan reviews now read the last task list, carry or close each task through a rows file, and write one list that replaces the old one

The per-review task section drops 30 lines of hand-built jq and becomes one gstack-tasks add call that reads a rows file, so a rerun carries open tasks forward and closes finished ones instead of leaving two lists for /autoplan to merge (#1791).

Before/after as text: the JSONL artifact section of plan-eng-review/sections/review-sections.md at 5b7b095 and on this branch
--- Before · plan-eng-review/sections/review-sections.md § JSONL artifact at 5b7b095 · source text
+++ After · plan-eng-review/sections/review-sections.md § JSONL artifact on this branch · source text
 ### JSONL artifact (write when permitted, including zero tasks)
+`/autoplan` aggregates this list. With your file-write tool, write one JSON object per line to `.gstack/tmp/tasks-eng-review-rows.jsonl` at the repo root (no free text in a command; no rows, no file) [...]. Then write the list (empty means "ran, no findings", distinct from "didn't run"):
-`/autoplan` reads this file to aggregate across phases. Build each line with
-`jq -nc` so titles and source findings containing quotes, newlines, or
-backslashes serialize cleanly — never use hand-rolled `echo` / `printf`.
 
 ```bash
+~/.claude/skills/gstack/bin/gstack-tasks add --phase eng-review
-GSTACK_STATE_ROOT=$(~/.claude/skills/gstack/bin/gstack-paths --get GSTACK_STATE_ROOT) [...]
-TASKS_FILE="$TASKS_DIR/tasks-eng-review-$(date +%Y%m%d-%H%M%S).jsonl"
-[... 25 more lines of per-task jq invocation ...]
 ```
-If `jq` is not installed, fall back to skipping the JSONL write [...]
-When writes are permitted and zero tasks were identified, touch the JSONL file [...]

Why

#973 put it plainly: "Spec-review subagents see only document text. They can't grep source, compute math, or shell out <tool> --help." The other four are the same kind of gap: on a rerun "the second run has no awareness of the first" (#1791), "wireframes never make it to plan-design-review" (#340), a "minimal diff" preference "biases reviewers against schema normalization" (#1048), and the YC tier's reasoning "is hidden from the user" (#513). Now a citation to a missing file or line fails the review, a rerun leaves one live task list, design review rates the plan against the approved wireframe, storage advice follows the data's queries, and the closing names the signals it counted.

Blast radius

The change touches the four plan-review skills, /office-hours, and three bins (gstack-plan-reality, gstack-office-hours-review, the new gstack-tasks); /autoplan's aggregator in autoplan/ is not edited. That is safe because gstack-tasks supersede only renames the reconciled earlier list to superseded-…, outside the aggregator's existing tasks-<phase>-*.jsonl glob, and prior still reads the older tasks-<phase>-<ts>.jsonl names, which I read in lib/tasks-prior.ts and proved in test/tasks-prior.test.ts and the paid rerun case (script ran).

Approvals

Date Asked Exact words Outcome Covers Still pending
2026-10-31 Approve the planning wave (F2, G1-G4) plan gate, taking every recommendation “Do it” (Garry) approved GSTA-228 plan gate rev 3: uc1b, d1b, d2a, d3b, d4b, d5b, p1b at full scope none
2026-10-31 Build or close the approved feature list “Do it” (Garry) approved build verdict on plans/feature-build-or-close.md (batch 2 F-J, K) none
2026-10-31 Paid eval and build budget for GSTA-228 “$100 paid-eval budget, $60 build cap, up to +$30 if re-review is triggered” (GStack Minder) approved GSTA-228 spend none

Source: gstack-approvals record for garrytan/gsta228-planning-wave (display only; not an approval citation).

Summary

Planning reviews used to trust the plan's own words, so a design doc with a made-up path or flag could pass at 8/10. They now check facts the way a reviewer would:

Security read

The probe is the one piece that runs commands, so it is fenced in code (lib/office-hours-probe.ts), not prose: it runs only --help (retrying -h when a non-gstack CLI prints no usage) for gstack bins that handle --help and a fixed list of common CLIs (git, gh, bun, node, npm, pnpm, yarn, jq, rg, python3, uv, go, cargo, make, docker, claude, codex, gemini). Subcommands are limited to each CLI's built-in ones: one word for git, cargo and npm, up to two for gh, docker, go and uv, none for the rest. It never runs a repository-local path or a relative PATH entry, runs with an environment that keeps only HOME, user, locale and toolchain locations (API keys and tokens are dropped), and refuses everything else with OFFICE_HOURS_PROBE_REFUSED. It makes no network calls of its own, adds no dependency and does not touch .github/workflows, setup, install or upgrade scripts. No outside contributor code was used; the #1048 reporter's patch was read as text only and not carried over.

Test Coverage

New tests: test/tasks-prior.test.ts (15), test/office-hours-probe.test.ts (11), test/plan-reality-receipts.test.ts (8), test/planning-wave-prose.test.ts (5, two from test.each), and the paid test/skill-e2e-planning-wave.test.ts (4 cases). Existing tests extended: test/plan-reality.test.ts and the module and selection lists the new files belong in.

Regression proof for G2 (failing first): the paid planning-wave-tasks-rerun case fails at main (one_live_list, prior_superseded, carried_open_task and done_task_disposed all false) and passes on this branch with all six scores true. Regression proof for G1: the shot above, main passes a missing-file and past-the-end receipt with exit 0, this branch exits 1.

Tests ran: free 24683 (remote pregate on tree e8536b2dc123, 0 failed, $0.09, VM destroyed)

Pre-Landing Review

Pass 1 (specialist batch plus red-team) and two fix-checks, then the adversarial pass and a cross-family outside voice (gpt-6.1-sol), since this PR adds a command runner and publishes eval numbers. Fixed: the probe ran uv run/docker run targets and gstack bins that ignore argv with the full environment (now per-CLI subcommand lists, --help-handling gstack bins only, and an environment without keys); add could drop an undecided earlier task (now refused); detached HEAD stamped rows unknown; same-second lists could overwrite each other; line 0, reversed ranges, dangling links and paths through files crashed or passed the receipt check; relative PATH entries were probed.

REVIEW_LOOP: passes=1 blocking_found=3 deferred=0 noted=2 fixed=9 scope=frozen fix_checks=2 dispatches=4

Gate edits (listed by hand at this head): test/fixtures/skill-md-size-allowlist.json lowers 27 size pins and raises none; test/fixtures/module-size-ratchet.json adds the lib/result-codes-plan.ts split from lib/result-codes.ts; test/eng-finding-retry-budget.test.ts counts the new e2e file; test/gstack-doctor.test.ts, test/plan-tune-cathedral.test.ts and test/timeline-stop-hook-slug.test.ts add the new result-codes file to their module lists. No threshold, trial count or skip changed.

Outside review: ran (gpt-6.1-sol); its range finding (src/a.ts:999-1 and line 0 passing) is fixed in 37006b4.

Review notes

Noted, not fixed (none meets the blocking floor):

  • Two reviews of the same phase running at the same moment in one checkout share .gstack/tmp/tasks-<phase>-rows.jsonl.
  • On native Windows the probe fails closed (refuses) rather than running.
  • add outside a git repo reads rows from the state directory.
  • prior writes its pending marker in modes where the storage policy forbids writes, and the marker write is not atomic.
  • A gstack bin qualifies for the probe when its file contains the string --help.
  • A dangling link outside the root reads as unresolved rather than missing.
  • A redundant man line in one probe test.

Eval Results

Preregistered in the plan (same model for every arm; B = this branch, M = main at the merge base, N = no gstack, a plain prompt with the same input).

Case (kind, trials) Bar B M N
planning-wave-planted-facts (behavior, 3) ≥2 of 4 planted errors in ≥2 trials, no false flag, not worse than M first run 4/4, 4/4, 3/4 found (bad_flag 2/3 vs M 3/3, red on the not-worse letter); after the probe repair in 18d2498, PASS 3/3 with 4/4 ×3 PASS 3/3 (4/4 ×3) PASS 3/3 (4/4 ×3)
planning-wave-schema (behavior, 3) explicit structure for queried tiers, control JSON left alone PASS 3/3 PASS 3/3 PASS 3/3
planning-wave-tasks-rerun (rule, 1) carry the open task, dispose the done one, supersede the prior list PASS (at 0099229 and e91ae22, all 6 scores true) FAIL FAIL (carried_open_task, done_task_disposed false)
planning-wave-closing-signals (behavior, 3) names a counted signal tied to a quote, invents none PASS 3/3 not run (known absent, per the prereg) PASS 3/3

Honest read: G2 is the only case where the branch beats both arms. On planted facts, schema and closing signals today's model already does as well without the new prose, so the gain there is the bin-enforced receipt check (deterministic, shown above), not a measured eval lift.

No-loss replay of the cases the diff selects, on the branch: plan-eng-review, plan-ceo-review, plan-design-review-plan-mode, plan-design-with-ui-scope, plan-review-report and office-hours-design-draft PASS. plan-eng-review-artifact FAILs on this branch, on its one allowed rerun, and on main at the merge base with the same assertion, so it is a pre-existing red, not a regression from this PR.

Plan Completion

All approved items shipped (uc1b, d1b, d2a, d3b, d4b, d5b, p1b). Deviations from the plan, each recorded in the decision trail:

  • F2 lives in the shared plan-review section rather than its own step.
  • Plan result codes moved to a new lib/result-codes-plan.ts to keep lib/result-codes.ts under the module-size ratchet.
  • The probe's CLI list adds claude, codex and gemini, and each CLI has its own list of built-in subcommands.
  • gstack-tasks uses a rows file the agent writes and has no separate start command; add does the validation and the supersede.

Deferred from the issues, by the approved plan: #340 point 3 (headless "present and iterate") and #973's three-model severity merge and npm registry lookups.

Issues

Fixes #340
Fixes #513
Fixes #973
Fixes #1048
Fixes #1791

Verification Results

CI green at 981cc53 (Free Tests run 41263307721, Windows Free Tests run 41263307894). Remote pregate on tree e8536b2dc123: PASS with 0 failed; macOS and Windows obligations cleared with those CI runs. Typecheck and the test-code type ratchet green (no new diagnostics).

TODOS

No TODO items completed in this PR.

Documentation

Status: updated. One factual correction to docs/troubleshooting.md; no blockers.

Scope: base 5b7b095, head 2b60e98 on garrytan/gsta228-planning-wave. The candidate had no staged, unstaged or untracked content. The audit covered the 43 committed files, mainly the plan-reality receipt check, gstack-office-hours-review probe, gstack-tasks and the new result codes. I read the new troubleshooting entries and part of docs/capy-install.md in full. The other candidate docs were checked by grep for the new bins and codes only.

Documentation health

File Status
docs/troubleshooting.md Updated: probe entry now says one subcommand word for git, cargo and npm, up to two for gh, docker, go and uv (verified against lib/office-hours-probe.ts)
docs/capy-install.md Current: the review-voice helper list does not name the new bins
README.md, AGENTS.md, CONTRIBUTING.md, other docs Not read in full; no references to the new bins or codes found by grep
CHANGELOG Not touched (protected metadata); the fragment is in changelog.d

Coverage debt: gstack-tasks (prior, add, supersede) has reference coverage only in docs/troubleshooting.md, plus its --help text, with no how-to or tutorial. The probe --help command and the Wireframe: line handoff between /office-hours and /plan-design-review have no docs outside skill prose and the changelog fragment. Consider running /document-generate for these.

Diagram drift: none found; the candidate adds no architecture diagrams and I found none affected.

Regeneration: none required by this edit; docs/troubleshooting.md is authored, not generated.

Test plan

  • UBI_OWNER=gsta228 gstack-pregate --stage tests --remote --spend-cap 2 --timeout 2700 --allow-repo-commands: 24683 tests, 0 failed on tree e8536b2dc123
  • bun run typecheck and bun run typecheck:test: zero product errors, no new test diagnostics
  • Guard and selection suite on the merged tree: 2412 pass, 0 fail
  • Paid planning-wave cases (branch, main, no-gstack arms) and the no-loss replay: results above

🤖 Generated with Claude Code

garrytan and others added 11 commits October 31, 2026 23:08
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…nforced probe (#973)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…or/supersede) (#1791)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The emit block shrinks to three calls: prior (now defaulting --dir and
--branch, and printing how to reconcile), start (creates the empty
branch-named list) and add (one validated row per task). close records a
done or dropped prior task. The plan-review result codes move to
lib/result-codes-plan.ts so lib/result-codes.ts stays under the module-size
ratchet; generated plan-review sections shrink, so their size pins go down.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…-review reads it

Step 5 copies sketch.png/html to <PROJECT_DIR>/{user}-{branch}-sketch-{datetime}.*
and writes a Wireframe: line (state-root relative) or Wireframe: none (<reason>).
The design review section finds the design doc before Pass 1 and opens the
wireframe, text-only when the file is missing. G4's signals line rides along
in the same generated office-hours files; tests in planning-wave-prose.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
One bullet in each of plan-eng-review and plan-ceo-review: fields queried,
constrained or updated on their own get explicit columns or tables; JSON suits
a document read and written whole. Written fresh; the reporter's patch is not
ported.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
planted facts (G1, behavior), data model (G3, behavior), task-list rerun (G2,
rule) and closing signals (G4, behavior). GSTACK_WAVE_ARM picks the arm; only
the branch arm asserts the preregistered bar, every arm writes a score row.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The planted-facts eval's one branch miss: the reviewer asked to probe
"git log", the probe refused it, and git's top-level help cannot show a log
flag, so the fabricated --since-commit stayed "unverified".
probe --help <command> [<subcommand> [<subcommand>]] now runs
<cli> <sub> --help for git, gh, docker, cargo, go, npm and uv (never node,
bun, python3, make, yarn, pnpm or a gstack bin, where the word could name a
script), in an empty temporary directory with pagers set to cat, falling back
to -h when --help has no usage line (a minimized system's missing man page).

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The free suite's generated-bash lint (INV-3) refused the add command's
<title>/<finding> placeholders: free text reaches a command only as a file the
agent writes with its file-write tool. start now also creates an empty rows
file in the repository's git-excluded .gstack/tmp and records the run; the
agent writes task and disposition rows there; add validates every row,
stamps phase, run, branch and commit, appends tasks to the list and
dispositions to task-dispositions-<phase>-<branch>.jsonl, then supersedes the
branch's earlier lists. close is gone (dispositions are rows).

The new planning-wave cases get measured periodic walls in
scripts/paid-test-durations.json so the periodic census still packs into 40
slices, the schema case declares the preamble sources its eng-template owners
need, and the paid file count is 114.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The rows file lives at .gstack/tmp/tasks-<phase>-rows.jsonl; add writes this
run's list (empty when there are no rows), appends dispositions, deletes the
rows file and supersedes the branch's earlier lists. Lowers 27 size pins.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@trunk-io

trunk-io Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

😎 This pull request was merged.

garrytan and others added 9 commits November 1, 2026 01:04
CI shard 13 home containment caught gstack-slug writing ~/.gstack/slug-cache
entries from the tasks-prior fixtures.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
The probe now accepts only each CLI's listed built-in subcommands (no uv run,
docker run, go test, npm exec or gh extensions), refuses gstack bins that do not
handle --help and never retries them with -h, and runs with a throwaway HOME and
an environment without keys. gstack-tasks resolves the slug through
runScriptSync (Windows) and prior deletes a rows file an unfinished run left.
Adds tests for the dropped disposition and the stale rows file.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Ship review (state matrix): a rerun that skipped RECONCILE silently retired
open tasks. add now names each undecided <run_id>/<id> and writes nothing.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Probe: find the repository root without running git, drop relative and
in-repository PATH entries for lookup and for the child, keep HOME and
toolchain locations (rustup, mise, asdf) but no keys, drop cargo fmt/clippy
(external cargo-* programs), restore planted env in the test.
gstack-tasks: resolve the exclude path against the cwd (subdirectories),
resolve --dir, stamp an empty branch on a detached HEAD like the aggregator,
name the file from --branch, and refuse a same-second second list instead of
appending. Receipts: line 0, reversed ranges, dangling links and paths
through files are unresolved instead of crashing.

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…wered where the wave shrinks)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@capy-ai capy-ai Bot changed the title Planning reviews check facts; office-hours handoff and verdict (F2, G1–G4) feat: plan reviews check facts and keep one task list; /office-hours hands its wireframe to design review (#340, #513, #973, #1048, #1791) Nov 1, 2026
@capy-ai
capy-ai Bot marked this pull request as ready for review November 1, 2026 02:22
@github-actions github-actions Bot changed the title feat: plan reviews check facts and keep one task list; /office-hours hands its wireframe to design review (#340, #513, #973, #1048, #1791) v1.92.15.0 feat: plan reviews check facts and keep one task list; /office-hours hands its wireframe to design review (#340, #513, #973, #1048, #1791) Nov 1, 2026
@capy-ai
capy-ai Bot merged commit 8695938 into main Nov 1, 2026
63 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment