@chrono-meta/fh-gate 3.43.0 → 3.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (105) hide show
  1. package/.claude/rules/fh_4axis_gate.md +50 -608
  2. package/.claude-plugin/marketplace.json +4 -4
  3. package/AGENTS.md +5 -1
  4. package/CATALOG.md +21 -0
  5. package/CHEATSHEET.md +7 -1
  6. package/docs/USER_GUIDE.md +95 -0
  7. package/docs/codex-compat.md +1 -1
  8. package/knowledge/shared/harness-core/fh_4axis_gate_detail.md +679 -0
  9. package/knowledge/shared/harness-core/fh_integration_contract.md +1 -1
  10. package/knowledge/shared/harness-core/fh_module_contract.md +106 -3
  11. package/knowledge/shared/harness-core/governance_engineering_definition.md +16 -0
  12. package/knowledge/shared/harness-core/heavy_skill_to_cartridge.md +185 -0
  13. package/knowledge/shared/learnings/subagent_invocations_log.yaml +221 -0
  14. package/knowledge/shared/plugin-catalog/recommended_plugins.md +53 -9
  15. package/package.json +24 -1
  16. package/plugins/fh-commons/.claude-plugin/plugin.json +1 -1
  17. package/plugins/fh-commons/skills/ko-tech-writer/SKILL.md +50 -14
  18. package/plugins/fh-commons/skills/ko-tech-writer/SKILL_detail.md +80 -0
  19. package/plugins/fh-commons/skills/ko-tech-writer/fixtures/sense_negative.md +30 -0
  20. package/plugins/fh-commons/skills/ko-tech-writer/fixtures/sense_positive.md +56 -0
  21. package/plugins/fh-meta/.claude-plugin/plugin.json +1 -1
  22. package/plugins/fh-meta/CHANGELOG.md +118 -0
  23. package/plugins/fh-meta/skills/auto-decorrelation/SKILL.md +58 -1
  24. package/plugins/fh-meta/skills/install-wizard/SKILL_detail.md +4 -0
  25. package/plugins/fh-meta/skills/sim-conductor/SKILL_detail.md +3 -3
  26. package/plugins/fh-meta/skills/steel-quench/SKILL_detail.md +9 -4
  27. package/plugins/fh-preprep/.claude-plugin/plugin.json +1 -1
  28. package/plugins/fh-qp/.claude-plugin/plugin.json +1 -1
  29. package/scripts/agy_launch_guard.sh +165 -0
  30. package/scripts/agy_remote_run.sh +187 -0
  31. package/scripts/below_floor_scan.sh +30 -0
  32. package/scripts/codex_launch_guard.sh +123 -0
  33. package/scripts/correction_moments.py +23 -2
  34. package/scripts/fh-gate.sh +612 -14
  35. package/scripts/fh-goal.sh +56 -12
  36. package/scripts/fh-run.sh +1 -1
  37. package/scripts/fh_gate_exec.sh +272 -0
  38. package/scripts/fh_session_load.sh +17 -0
  39. package/scripts/finding_fleet.sh +36 -2
  40. package/scripts/finding_verifier.sh +7 -2
  41. package/scripts/fixtures/heavy_skill_smell/clean/tidy-notes/README.md +16 -0
  42. package/scripts/fixtures/heavy_skill_smell/clean/tidy-notes/scripts/check_refs.py +12 -0
  43. package/scripts/fixtures/heavy_skill_smell/clean/tidy-notes/scripts/test_check_refs.py +24 -0
  44. package/scripts/fixtures/heavy_skill_smell/clean/tidy-notes/skills/tidy-notes/SKILL.md +16 -0
  45. package/scripts/fixtures/heavy_skill_smell/clean/tidy-notes/skills/tidy-notes/fh-module.yaml +20 -0
  46. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/SKILL.md +25 -0
  47. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/hooks/hooks.json +7 -0
  48. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/scripts/check_links.py +25 -0
  49. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/scripts/publish.sh +9 -0
  50. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/scripts/publish_guard.py +6 -0
  51. package/scripts/fixtures/heavy_skill_smell/heavy/docs-publisher-pro/scripts/setup.sh +5 -0
  52. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/SKILL.md +25 -0
  53. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/hooks/hooks.json +10 -0
  54. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/scripts/check_refs.py +12 -0
  55. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/scripts/guard_push.py +9 -0
  56. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/scripts/install.sh +6 -0
  57. package/scripts/fixtures/heavy_skill_smell/heavy/release-notes-pro/scripts/ship.sh +9 -0
  58. package/scripts/heavy_skill_smell.py +311 -0
  59. package/scripts/job_heartbeat.py +186 -0
  60. package/scripts/ko_tech_writer_calibrate.py +88 -1
  61. package/scripts/live_eval_matrix.py +128 -0
  62. package/scripts/live_eval_trace.py +199 -5
  63. package/scripts/package_coverage_check.sh +18 -0
  64. package/scripts/prepush_guard_check.sh +41 -20
  65. package/scripts/probe_live_eval.sh +33 -1
  66. package/scripts/probe_live_eval_lib.py +14 -6
  67. package/scripts/selfcheck.sh +162 -2
  68. package/scripts/selfcheck_shard_weights.txt +2 -0
  69. package/scripts/session_checklist.py +109 -5
  70. package/scripts/sidecar_calibrate.sh +15 -5
  71. package/scripts/sidecar_wait.sh +21 -1
  72. package/scripts/sim_isolated_run.sh +20 -0
  73. package/scripts/test_agy_launch_guard_lanes.sh +347 -0
  74. package/scripts/test_agy_remote_run_lanes.sh +228 -0
  75. package/scripts/test_below_floor_scan_lanes.sh +85 -0
  76. package/scripts/test_codex_launch_guard_lanes.sh +183 -0
  77. package/scripts/test_correction_moments_lanes.sh +37 -0
  78. package/scripts/test_fh_gate_absorb_lanes.sh +255 -0
  79. package/scripts/test_fh_gate_defaults_lanes.sh +169 -0
  80. package/scripts/test_fh_gate_exec_lanes.sh +244 -0
  81. package/scripts/test_fh_gate_fusion_lanes.sh +202 -0
  82. package/scripts/test_fh_gate_regressions.sh +92 -1
  83. package/scripts/test_fh_goal_change_detection_lanes.sh +103 -3
  84. package/scripts/test_finding_pipeline_lanes.sh +41 -3
  85. package/scripts/test_guard_anchor_override_env_lanes.sh +84 -0
  86. package/scripts/test_heavy_skill_smell_lanes.sh +160 -0
  87. package/scripts/test_job_heartbeat_lanes.sh +96 -0
  88. package/scripts/test_live_eval_construct_lanes.sh +29 -6
  89. package/scripts/test_live_eval_matrix_lanes.sh +53 -0
  90. package/scripts/test_live_eval_trace_lanes.sh +165 -12
  91. package/scripts/test_name_boundary_locale_lanes.sh +36 -5
  92. package/scripts/test_preprep_speech_coach_lanes.sh +18 -2
  93. package/scripts/test_prepush_guard_failure_visibility_lanes.sh +152 -0
  94. package/scripts/test_prepush_marker_lookup_lanes.sh +143 -0
  95. package/scripts/test_probe_live_eval_lanes.sh +43 -0
  96. package/scripts/test_regression_guard_sibling_lanes.sh +52 -1
  97. package/scripts/test_session_checklist_lanes.sh +205 -0
  98. package/scripts/test_sidecar_calibrate_lanes.sh +5 -1
  99. package/scripts/test_sidecar_wait_stdin.sh +18 -0
  100. package/scripts/test_sim_isolated_run_lanes.sh +43 -0
  101. package/scripts/universal_guard_check.sh +8 -0
  102. package/templates/.claude/rules/mcp_tool_gating.md +27 -0
  103. package/templates/.git-hooks/pre-push +60 -3
  104. package/templates/regression_guard.sh +8 -4
  105. package/templates/settings.LaneGap.snippet.json +27 -0
@@ -0,0 +1,56 @@
1
+ <!-- S35 낱말 뜻 흔들림 — 늘어놓기(a) known-positive. 줄마다 활용형 하나 · 기대 낱말은 줄 끝 주석에. -->
2
+ <!-- 문장은 만든 일반 예문이다(어느 원고의 문장도 아니다). 뜻은 일부러 섞었다 — 이 레인은 뜻을 가르지 않고 «빠짐없이 늘어놓는가»만 잰다. -->
3
+
4
+ 설계 문서를 쓰다 보면 용어가 흔들린다. <!-- 쓰다 -->
5
+ 이 스크립트는 캐시를 쓴다. <!-- 쓰다 -->
6
+ 보고서를 쓰는 사람이 따로 있다. <!-- 쓰다 -->
7
+ 예전에 쓰던 도구를 그대로 둔다. <!-- 쓰다 -->
8
+ 이 옵션을 쓰면 속도가 빨라진다. <!-- 쓰다 -->
9
+ 초안을 쓰고 나서 검토를 받는다. <!-- 쓰다 -->
10
+ 기본값을 쓰되 경로만 바꾼다. <!-- 쓰다 -->
11
+ 같은 설정을 써서 다시 돌린다. <!-- 쓰다 -->
12
+ 지난주에 결과 요약을 썼다. <!-- 쓰다 -->
13
+ 저희는 이 방식을 씁니다. <!-- 쓰다 -->
14
+ 그 함수는 쓸 수 없다. <!-- 쓰다 -->
15
+ 이 값은 쓰지 않는다. <!-- 쓰다 -->
16
+ 문서 쓰기가 늦어졌다. <!-- 쓰다 -->
17
+ 건수를 세다 보니 하나가 빠졌다. <!-- 세다 -->
18
+ 실패한 줄을 센다. <!-- 세다 -->
19
+ 경고를 세는 스크립트가 있다. <!-- 세다 -->
20
+ 통과로 세지 않았다. <!-- 세다 -->
21
+ 줄을 세어 보니 열둘이었다. <!-- 세다 -->
22
+ 건수를 세고 나서 표에 적었다. <!-- 세다 -->
23
+ 중복을 세면 숫자가 부푼다. <!-- 세다 -->
24
+ 어제 다시 셌다. <!-- 세다 -->
25
+ 항목을 셉니다. <!-- 세다 -->
26
+ 몇 번인지 셀 수 없다. <!-- 세다 -->
27
+ 응답 시간을 재다 보면 편차가 크다. <!-- 재다 -->
28
+ 지연을 잰다. <!-- 재다 -->
29
+ 메모리를 재는 도구를 붙였다. <!-- 재다 -->
30
+ 속도를 재어 기록했다. <!-- 재다 -->
31
+ 크기를 재고 나서 비교했다. <!-- 재다 -->
32
+ 같은 조건에서 재면 값이 같다. <!-- 재다 -->
33
+ 어제 다시 쟀다. <!-- 재다 -->
34
+ 처리량을 잽니다. <!-- 재다 -->
35
+ 아직 재지 않았다. <!-- 재다 -->
36
+ 그 길이는 잴 수 없다. <!-- 재다 -->
37
+ 기계가 판정을 내린다. <!-- 기계 -->
38
+ 이 단계는 기계적으로 처리한다. <!-- 기계 -->
39
+ 이 함수는 여러 곳에서 쓰인다. <!-- 쓰다 -->
40
+ 그 값은 기본값으로 쓰입니다. <!-- 쓰다 -->
41
+ 캐시를 쓰거나 끄거나 둘 중 하나다. <!-- 쓰다 -->
42
+ 고객이 직접 쓰신 후기다. <!-- 쓰다 -->
43
+ 이 변수는 나중에 쓰일 예정이다. <!-- 쓰다 -->
44
+ 다시 세야 한다. <!-- 세다 -->
45
+ 몇 개인지 셀까 고민했다. <!-- 세다 -->
46
+ 줄을 세거나 건너뛴다. <!-- 세다 -->
47
+ 한 번 세봤다. <!-- 세다 -->
48
+ 같은 조건에서 다시 재야 한다. <!-- 재다 -->
49
+ 시간을 재거나 기록만 남긴다. <!-- 재다 -->
50
+ 그 값은 예전에 기본값으로 쓰였다. <!-- 쓰다 -->
51
+ 이 옵션은 끄고 쓰도 된다. <!-- 쓰다 -->
52
+ 초안 작성 후 검토 요청 씀. <!-- 쓰다 -->
53
+ 나중에 다시 셀 것이다. <!-- 세다 -->
54
+ 대충 세도 된다. <!-- 세다 -->
55
+ 같은 방식으로 재도 된다. <!-- 재다 -->
56
+ 지연은 이렇게 재죠. <!-- 재다 -->
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fh-meta",
3
- "version": "3.43.0",
3
+ "version": "3.45.0",
4
4
  "engines": {
5
5
  "claudeCode": ">=1.0.0"
6
6
  },
@@ -2,6 +2,124 @@
2
2
 
3
3
  ### [Unreleased]
4
4
 
5
+ ### [3.45.0] — 2026-11-20
6
+
7
+ Minor by the version policy: fh-gate gains an execution layer, a review pass that follows `/code-review`'s method, a history-aware «elephant» pass and `/code-review` itself as an opt-in reviewer (#1147, #1156). There are also new shipped tools and lanes (`live_eval_matrix.py`, `heavy_skill_smell.py`, `job_heartbeat.py`), a new `FH_AGY_ISOLATION=no-tools-agent` route, and judged procedure changes in shipped skills and canon.
8
+
9
+ **fh-gate defaults, stated plainly.** A caller who sets nothing gets the 3.44.0 review, with three exceptions: the default Claude model is now `claude-sonnet-5-5` (#1142), and file names with non-ASCII characters (#1142) or with quotes, backslashes or tabs (#1146) are now reviewed. Otherwise:
10
+ - the reviewer is `fh-legacy` on every backend;
11
+ - the elephant pass is off;
12
+ - the execution layer is off.
13
+
14
+ Terms: the *goldfish* pass is a reviewer that sees only the diff and the files, never the author's explanation. The *elephant* pass also sees the task description and the files' git history. *fh-legacy* is the original angle pass. Grades: A blocks, B means proceed with care (PENDING), C is a note.
15
+
16
+ Each new layer is opt-in: `FH_REVIEWER=code-review` (claude backend only) or `FH_REVIEWER=fh`, `FH_GATE_ELEPHANT=auto|on`, `FH_GATE_EXEC=on`. Why: whether a headless `/code-review` call, or the `fh` pass, returns the structured object the gate needs on every runner is UNMEASURED, and `FH_GATE_EXEC=on` runs the repository's own lane scripts.
17
+
18
+ Three changes make a shipped gate refuse more by default; see their `BREAKING (gate):` entries:
19
+ - the pre-push Load-Bearing gate reads each pushed branch's own marker (#1119; FH-checkout pushes of gate files only);
20
+ - `fh-goal` and `fh-gate` fail closed when any changed file name holds a newline (#1146);
21
+ - `codex_launch_guard.sh` refuses a stdin that does not end in time, or is closed, instead of waiting forever or starting codex with an empty prompt (#1158).
22
+
23
+ Items marked «not in the npm package» are in the repository checkout only.
24
+
25
+ ### Added
26
+ - fh-gate review layers, all opt-in (#1147, #1156):
27
+ - `FH_GATE_EXEC=on` runs `scripts/fh_gate_exec.sh` (shipped) in a copy of the tree. It makes no model call, but the lanes it runs may use the network or secrets the way your CI does:
28
+ - E0 runs FH's pipefail early-exit class scanner against the change; a new site it flags is B. The scanner is not in the npm package, so from npm E0 prints `NOT RUN (scanner not shipped here)` and only E1 runs.
29
+ - E1 runs the change's target lanes. A lane this change turns red is graded A (BLOCKED); a lane already red before the change is C; a lane that did not finish or could not run is B.
30
+ - It runs the repository's own lane scripts: use it only where the change is trusted. The copy is not a sandbox.
31
+ - `FH_REVIEWER=code-review` (claude backend only) calls the built-in `/code-review` (medium at `quick`, high at `full`) with a JSON schema. Its tools are not read-only: `/code-review` needs git's read commands, and `git diff/log/show --output=<file>` writes a file, so a reviewed change that talks the model into it could write a file of its choosing. Use it on trusted changes only. The call runs without the runner's command-file variables (`GITHUB_ENV`, `GITHUB_PATH`, `GITHUB_OUTPUT`, `GITHUB_STATE`, `GITHUB_STEP_SUMMARY`); that removes the direct reference only — the files can still be found and written, so it does not make this path safe. Its findings are carried as reported: Important → B, Nit and Pre-existing → C.
32
+ - `FH_REVIEWER=fh` runs a «goldfish» pass modelled on the phase structure of `/code-review` as shipped in Claude Code 2.1.328, written in FH's words:
33
+ - eight finder angles;
34
+ - one CONFIRMED / PLAUSIBLE / REFUTED vote per candidate;
35
+ - at most 10 findings at `full`, 8 at `quick`;
36
+ - it never receives `FH_TASK_DESCRIPTION`, in its prompt or in its process environment.
37
+ - on the claude backend it gets only Read · Glob · Grep: no shell, no MCP server, no skill (`--tools`, `--strict-mcp-config`, `--disable-slash-commands`; the change and the target content are in its prompt). A Claude Code too old for these flags fails the call (exit 10). On codex it runs in `codex exec -s read-only`, codex's sandbox. The elephant pass below is the same.
38
+ - `FH_GATE_ELEPHANT=auto` (on at `full`) or `on` adds an «elephant» pass:
39
+ - it gets the task description and the touched files' git history;
40
+ - it looks only for a past fix re-opened, a recorded decision undone or the task contradicted;
41
+ - it can only make the verdict stricter.
42
+ - Shared rules:
43
+ - Any failure of the opt-in passes exits 10.
44
+ - When a pass that reads the change diff runs (an opt-in reviewer, or the elephant), a diff that cannot be computed is a B. With `fh-legacy` and the elephant off, it is only named on the reviewer line.
45
+ - The elephant under `fh-legacy` keeps the 120 s default timeout; the 900 s default applies only to `code-review` and `fh`.
46
+ - Output gains `FH_GATE_REVIEWER` · `FH_GATE_ELEPHANT` · `FH_GATE_E0` · `FH_GATE_E1` · `FH_GATE_LAYERS_NOT_BUILT`, and a `source:` per finding. Verdicts, exit codes 0/1/2/3/10/11/12 and the record keep their meaning.
47
+ - In `cross` mode with `FH_REVIEWER=code-review`, the codex leg runs the goldfish pass, labelled `fallback`.
48
+ - Lanes (shipped): `test_fh_gate_defaults_lanes.sh` · `test_fh_gate_exec_lanes.sh` · `test_fh_gate_fusion_lanes.sh` · `test_fh_gate_absorb_lanes.sh`.
49
+ - `FH_AGY_ISOLATION=no-tools-agent` in `agy_launch_guard.sh` (shipped), for a machine where company repositories are readable. Its callers (`finding_fleet.sh`, `finding_verifier.sh`, `sidecar_calibrate.sh`) and the `auto-decorrelation` and `steel-quench` docs name the new route. In order:
50
+ 1. It refuses before agy starts when the prompt, an argument, the agy binary path or the working folder names a company-repo root. An unconfigured list is refused.
51
+ 2. It writes a `tools: []` agent definition under a unique name and runs agy with it and `--output-format stream-json`.
52
+ 3. It voids any run whose stream shows a tool step other than `manage_task`, or that does not end in one SUCCESS result: exit 4, nothing on stdout.
53
+ 4. It removes the definition.
54
+
55
+ The `container` / `os-user` / `remote-os-user` routes are unchanged. (#1140)
56
+ - `scripts/live_eval_matrix.py` (shipped): a probe × date matrix across nightly live-eval reports, with always-pass / never-pass / mixed / too-few lists. Record only; UNCALIBRATED and FAILED-TO-RUN rows count as not scored. (#1082)
57
+ - Live-eval behaviour profile (record only). The nightly report gains, per probe, arm and rep, the arm's top-level tool calls in four bins (explore · edit · test-run · other), counted by `live_eval_trace.py profile`. The bins are a heuristic calibrated on 17 real calls (edit and test-run on fixtures only). A rep with no stream says `trace=MISSING`, never 0. (#1133)
58
+ - `knowledge/shared/harness-core/heavy_skill_to_cartridge.md` and `scripts/heavy_skill_smell.py` (shipped). A guide for splitting a skill that carries its own gates and hooks into craft / checks / floor. The checker flags seven smell families and is advisory: exit 0 when it read everything, 2 when it could not, never 1. (#1135)
59
+ - `scripts/job_heartbeat.py` (shipped), wired into the session-start load. Per installed FH nightly job (`com.forge-harness.*` launchd jobs; silent where there are none), it lists the last 3 days with no output; days inside a row of `tracks/_meta/job_pauses.tsv` print as «paused (recorded)». It never judges a gap; always exit 0. (#1154)
60
+ - Cartridge loader (not in the npm package; the shipped `heavy_skill_to_cartridge.md` and install-wizard detail name it): `scripts/cartridge_loader.py` / `.sh`, a SessionStart hook. It injects the entry text of the cartridges the operator lists in `.claude/cartridges.enabled`, each pinned by a tree hash. No list means nothing is injected. (#1137)
61
+ - `scripts/fh_techwriter_sync_check.sh` (not in the npm package): names the files where the published fh-techwriter copy differs from FH's own export of ko-tech-writer (DRIFT · MISSING · EXTRA). Record only. (#1139)
62
+ - `scripts/scoreboard_render.py` (not in the npm package): renders a measurement scoreboard only from sealed, quoted records, and lists everything else as excluded with its reason. (#1143, #1144)
63
+
64
+ ### Changed
65
+ - fh-gate, fh-goal and fh-run: the default Claude model moves from `claude-sonnet-4-6` to `claude-sonnet-5-5`. Verdict rules and exit codes are unchanged. (#1142)
66
+ - `action.yml`: the `timeout` input defaults to empty and becomes `FH_TIMEOUT` only when given; it is read through an env var, not a `${{ }}` in the shell. With no `timeout`, the gate uses its own default for the review it runs: 120 s for `fh-legacy`, 900 s for an opted-in `code-review` or `fh` reviewer. Callers who set `timeout` are unchanged. (#1156)
67
+ - BREAKING (gate): `templates/.git-hooks/pre-push` (shipped), the Load-Bearing Change Gate.
68
+ - Scope: it binds only when the push carries load-bearing gate files and the repository has a `tracks/_meta` folder (an FH checkout).
69
+ - What changed: every branch the push updates needs its own marker, named exactly `.axes_23_passed_<slug>_YYYY-MM-DD.marker` and carrying a `crossfamily:` line, read from where pre-commit writes it (the main checkout's `tracks/_meta` when you push from a worktree).
70
+ - Why: before, it took the newest marker of any branch, so a main-checkout push could pass on another branch's marker.
71
+ - What now blocks: a push whose branch has no marker of its own, or whose marker name another local branch shares.
72
+ - Remedy: record the marker for the branch you push, or use the logged `PUBLIC_SURFACE_OK=1` exception.
73
+ - Repositories without `tracks/_meta` are not newly blocked. (#1119)
74
+ - `fh_module_contract.md` (shipped):
75
+ - §2d: the declared purpose picks the measurement axis. Role and interaction modules get a persona simulation with three arms (bare / skill-only / module). (#1136)
76
+ - §2e: a module that verifies names its near-miss request kinds and refuses them with exit 2 and «NOT checked», never 0 or 1, with one lane per kind. (#1141)
77
+ - `ko-tech-writer` (shipped): scope words (지원하는 · 어디서나 · 모든 · 항상) need evidence for that scope. S20 drops a bracketed exit code only when the sentence already states the result. Operator examples are added to S18 · S19 · S23 · S30. (#1134)
78
+ - `.claude/rules/fh_4axis_gate.md` (shipped) is a thin resident layer: 59 KB → 20 KB. It is written to keep every hook-enforced requirement; the pre-registered probe of that was INSTRUMENT-UNCONFIRMED (its control also scored full). The previous body moved to `knowledge/shared/harness-core/fh_4axis_gate_detail.md`, byte-identical below a new header. `templates/regression_guard.sh` (shipped) credits that move as a sibling pair. (#1145)
79
+ - `templates/.claude/rules/mcp_tool_gating.md` (shipped) gains step 6 for npx/uvx servers, which is advisory: a pinned version is not a dependency freeze. (#1132)
80
+ - Live-eval `INVALID-COMPARISON` now starts with the elements not present in every arm («not in every arm: tools=…; mcp=…; plugins=…»). Verdict and rc are unchanged. (#1152)
81
+ - `sim_isolated_run.sh` (shipped) prints a run-level tally, and `RUN: FAILED-TO-RUN` when no rep was captured or ended empty; exit code unchanged. (#1138)
82
+ - The self-dev nightly report ends with a tier tally (not in the npm package; measuring only). (#1153)
83
+
84
+ ### Fixed
85
+ - BREAKING (gate): `scripts/codex_launch_guard.sh` (shipped since 3.44.0), which FH scripts start codex through.
86
+ - What changed: it reads the prompt from stdin with an idle limit (`FH_GUARD_STDIN_IDLE_S`, default 60 s) and a total limit (`FH_GUARD_STDIN_MAX_S`, default 600 s).
87
+ - Why: it used to read stdin with `cat`. A stdin that stays open and never ends — an agent's background shell hands its commands one — made it wait forever, and everything that started codex through it with it (measured: a selfcheck stuck 2 h 30 min in the `sidecar_calibrate.sh` lane).
88
+ - What now blocks: a stdin silent past the idle limit or not ended by the total limit, a limit outside 1–86400, a read error, or a closed stdin (`<&-`, which used to start codex with an empty prompt). Each is a refusal by name: exit 3, codex not started, nothing partial passed on.
89
+ - Remedy: pipe in a prompt that ends, or run the caller with `< /dev/null` when the prompt is an argument. `sidecar_calibrate.sh` now does this for its probes. (#1158)
90
+ - BREAKING (gate): `fh-goal` and `fh-gate` (shipped bins) read changed files NUL-delimited. Before, a name with a quote made `fh-goal`'s `xargs` abort, and it reported «no changed files» with exit 0, so fh-gate never ran. `fh-gate` used to only warn about names with a quote, backslash or tab; now it reviews them. In both, a change in which any name holds a newline exits 10: when every name does («every changed file name holds a newline … Failing closed»), and also when such a name sits beside others, since a verdict on the rest would cover only part of the change and read as the whole (a security review before the 3.45.0 tag reproduced PASS / exit 0 with the newline-named file unreviewed). Remedy: rename the file, or pass the files to review explicitly. (#1146)
91
+ - `fh-gate` and `fh-goal` review files with non-ASCII names. They used to be quoted with octal escapes and could not be opened; a Korean-only change exited 10 with «nothing was reviewed». (#1142)
92
+ - The guard anchors `universal_guard_check.sh` and `prepush_guard_check.sh` (shipped) unset every override the hooks read before building their sandbox. A commit made with `PUBLIC_SURFACE_OK=1` no longer turns them red for an unrelated reason. (#1118)
93
+ - `fh-gate --help` and the Action's `backend` description name the 3.45.0 defaults (fh-legacy; `FH_GATE_EXEC=on` runs the repository's own scripts; the opt-in layers are set in the step env), and lane D9 pins the help line (this release).
94
+ - `test_finding_pipeline_lanes.sh` (shipped) runs its stub pipelines from its own temp folder. A checkout that lists its own root in `.claude/rules/.company-roots` no longer turns 7 lanes red, and the codex guard still refuses a launch from the checkout (L128, L129). (#1155)
95
+ - `below_floor_scan.sh` (shipped): from a git worktree it reads the main checkout's markers, or says NOT READ, instead of printing «0 total» from the worktree's empty folder. (#1151)
96
+ - `correction_moments.py` (shipped): a long prompt that repeats 3+ times, such as a scheduled trigger, is no longer counted as an operator correction. (#1150)
97
+ - Clean-room audit rounds 8–9: two lanes that reported an absence about sound subjects now find the row by elimination or name the premise. A LaneGap snippet template now ships with the lane that reads it. (#1062)
98
+ - `state_claim_recheck_hook.sh` (not in the npm package) also reads the lease archive and tags its lines as expired. (#1148)
99
+
100
+ ### [3.44.0] — 2026-11-17
101
+
102
+ Minor by the version policy: new shipped guards and a remote runner for the cross-family sidecars (#1123, #1125, #1127), a new `--senses` listing and lane in `ko-tech-writer` (#1128), and judged procedure changes in shipped skills and canon. One change makes an existing path refuse more by default — FH scripts now start `agy` only through `agy_launch_guard.sh`, so a gemini fleet member you ran on purpose fails as refused until it runs isolated; see the `BREAKING (gate):` entry for the remedy (#1123). The same change makes `finding_fleet.sh` stop with exit 1 before any member runs when it cannot create or prove its agy shim (for example a read-only or noexec `/tmp`), so a codex-only fleet on such a machine stops too (#1123). Two other refusals are new and narrower: a codex arm is refused when its prompt, arguments or working folder name a configured company-repo root (#1127), and `sidecar_wait.sh` now reports a sidecar that rejected its model as `HARNESS-ERROR` instead of `COMPLETE` (#1127). The live-eval report can now exit 2 (`INVALID-COMPARISON`) when its arms loaded different plugin sets — a report verdict, not a commit or publish gate (#1121). This repository's own required `validate` check now proves every selfcheck shard passed without the GitHub API (#1130) — repository CI only, nothing shipped changes.
103
+ ### Added
104
+ - `scripts/codex_launch_guard.sh` (shipped): FH's codex verifier arms (`finding_fleet.sh` codex rows — including rows that call `codex` by name, through a shim first on `PATH` — `finding_verifier.sh --family codex`, the `sidecar_calibrate.sh` probe) start codex only through it. It refuses (exit 3, `HARNESS-ERROR: CODEX-REFUSED`, codex not started) when the prompt on stdin, an argument or the working folder names a root in the operator's company-repo list (`FH_COMPANY_ROOTS`, or the gitignored `.claude/rules/.company-roots`); otherwise codex runs with the prompt byte-for-byte and its own exit code. With no list configured it runs and prints «CODEX-GUARD: no company roots configured — not checked». A list that exists but cannot be read, an unreadable prompt or a failed matcher also refuses (exit 3). `.gitignore` now lists `.claude/rules/.company-roots`. It is a string check on paths (as given, real path, without `/private`, with `~`), not isolation. Not covered: a custom fleet row that calls codex by absolute path or resets `PATH` (it skips the shim), and the runtime adapters `fh-run.sh` · `fh-goal.sh` · `fh-gate.sh`, where codex is the user's own agent. `sidecar_wait.sh` reports a guard refusal as `HARNESS-ERROR reason=guard-refused`. Lanes `scripts/test_codex_launch_guard_lanes.sh` (shipped). (#1127)
105
+ - `scripts/agy_remote_run.sh` (shipped): the route FH ships for agy (the `container` / `os-user` markers remain for an isolated environment you built, unchecked by the guard) — it runs agy only as a separate OS user on another machine over ssh (frozen inputs copied in, output and requested files copied back, only its own `fh_agy_<stamp>_<hex>` work folder removed) and never starts a local agy. `--canary` (no agy) measures that the remote user cannot read the `FH_AGY_REMOTE_DENY` paths and writes a local receipt; runs are refused (exit 3) without a PASS receipt under 7 days old for the same settings, and a route that is down exits 4. `agy_launch_guard.sh` honours the new `FH_AGY_ISOLATION=remote-os-user` only when the target is this runner. Host, account and paths come from the environment only. Lanes `scripts/test_agy_remote_run_lanes.sh` (shipped) use a fake ssh/scp; the PowerShell side is not exercised by the lanes. (#1125)
106
+ - BREAKING (gate): `scripts/agy_launch_guard.sh` (shipped). FH scripts now start `agy` only through it, and it refuses (exit 3, `AGY-REFUSED` on stderr) unless `FH_AGY_ISOLATION` is exactly `container` or `os-user`. Covered callers: `finding_fleet.sh` (the default gemini row, custom rows that write `AGY_BIN`, and custom rows that call `agy` by name — through a shim put first on `PATH`; both rounds), `finding_verifier.sh --family gemini`, and `sidecar_calibrate.sh` (which now prints a `REFUSED` row instead of reading the refusal as an answer). Why: agy runs its own shell and file tools even in `--mode plan` and sends what they print to the cloud model; on 2026-11-16 a review run searched the whole machine, read its own answer key and sent file names from another repository on that machine. If you ran a gemini member on purpose, it now fails as a refused member until you run it inside a container or a separate OS user (or as a remote OS user through `scripts/agy_remote_run.sh`, `FH_AGY_ISOLATION=remote-os-user`, #1125) and set the marker there. `--sandbox` does not count: a canary test the same day showed `agy --mode plan --sandbox` reading files outside its cwd and in the home directory. The marker is self-declared: the guard checks that you said it, not that it is true — set it only where a canary check confirmed the isolation. Not covered: a fleet row that calls agy by absolute path or resets `PATH`. `auto-decorrelation` §Step 2 states the rule; lanes `scripts/test_agy_launch_guard_lanes.sh` (shipped). (#1123)
107
+ - `ko-tech-writer` S35, word-sense drift, as a procedure rather than a word list (shipped: `SKILL.md`, `SKILL_detail.md`, `fixtures/sense_positive.md`, `fixtures/sense_negative.md`, `scripts/ko_tech_writer_calibrate.py`). `ko_tech_writer_calibrate.py --senses FILE` lists occurrences of 쓰다/세다/재다/기계 (enumerated endings; compounds are not matched) with their context; a person or model then groups them by sense and flags the minority sense, and a coverage line says that 0 hits is not «none». New lane C22 checks the listing on a constructed inflection fixture and 0 hits on 27 lines of collision words; the sense grouping itself has no lane and stays a judgment. The same change adds a draft-time term table (Step 1), reading cited papers from the abstract (Step 4) and a provisional seeded whole-document pass after a correction round (Step 5) (#1128)
108
+ ### Changed
109
+ - `sidecar_wait.sh`: a sidecar CLI that refuses the requested model now gets `SIDECAR_VERDICT=HARNESS-ERROR exit=<n> reason=model-not-available` and exit 3, instead of `COMPLETE` — which read as «the reviewer answered and found nothing». Measured 2026-11-16: codex `-m gpt-5.5` and `-m gpt-5` return HTTP 400 «not supported when using Codex with a ChatGPT account» (rc 1). Documented examples (`sidecar_wait.sh` usage, `auto-decorrelation`, `sim-conductor`) no longer pin those models; they use the CLI default. `auto-decorrelation` records that codex's `--sandbox read-only` limits writes, not reads (canary files in cwd, another temp folder and the home directory were all read), so codex arms get public diffs only. Lane `test_sidecar_wait_stdin.sh` P10/P10b. (#1127)
110
+ - live-eval: the init plugin list (each plugin's source and version, never its path) is now part of the surface that `INVALID-COMPARISON` compares, next to the tool and MCP lists. Arms that loaded different plugins, or the same plugin at different versions, or one arm whose init has no plugin list, make the probe `INVALID-COMPARISON` with no pass rate and the run exits 2. Arms with the same plugins score as before. Why: the 2026-11-15 nightly had two probes where one rep loaded one more built-in plugin than the rest, with tools and MCP equal, and the report counted one surface. The plugins are still loaded from the operator's HOME; pinning them is not in this change. Lanes TR14–TR18 in `scripts/test_live_eval_trace_lanes.sh` (shipped). (#1121)
111
+ - `ko-tech-writer` S11/S16/S19/S23 carry the 2026-11-15 operator full-read pairs (shipped). S11 gives bare section numbers a unit and splits shared-unit number pairs; S16 adds a cross-asset term check that splits by meaning and never bulk-replaces; S19/S23 gain four pairs; Step 5 adds context-only neighbour blocks and a provisional beginner cold-read stop rule. No lane or script changed (#1120)
112
+ - `governance_engineering_definition.md` (shipped): the supervising placement is one root window over work sessions that each do one task in sequence. Provisional and proposal-only: when a multi-day task piles up in a session with other tasks, the governor proposes in one line moving it to a re-enterable work session; coupled work is not split (#1117)
113
+ ### Fixed
114
+ - `scripts/prepush_guard_check.sh` (shipped): when a known pair breaks, the closing `❌ BLOCKED` line now names every broken pair with its exit code and elapsed seconds (`… 5 known pair(s) broke after 10s: <pair> (rc=0, 1s); …`), and every pair line carries an `[Ns]` stamp. `selfcheck.sh` shows a failing check through its ❌-line extractor instead of the last 12 lines, with the check's total elapsed time. Why: a downstream consumer got `BLOCKED — a known pair broke` from a long selfcheck under heavy load with the pair cut off above the 12-line tail, so nobody could tell which pair broke or whether it timed out. The cause of that failure is still unmeasured; pass/fail verdicts do not change. Lane `scripts/test_prepush_guard_failure_visibility_lanes.sh` (shipped) plants a broken pair and checks the names survive the tail. (#1129)
115
+ - `session_checklist.py extract --out` (shipped) no longer drops the parts of an existing sheet that the table parser does not consume — a result section below the table, a preface, prose in between, fenced code and hand-written notes are kept in order under «이전 결과서의 표 밖 내용», so a re-run over its own output is byte-identical. An orphan row whose first cell is `-` was read as a separator and lost on the second re-extract; it now survives. Lanes L55–L58 and KR1 in `scripts/test_session_checklist_lanes.sh` (shipped) (#1108)
116
+ - `scripts/test_preprep_speech_coach_lanes.sh` (shipped): the `ffmpeg`-absent probe first resolves the real interpreter (`sys.executable` under the normal PATH), then runs it under the empty PATH. A downstream consumer saw it die with rc 127 where `python3` is a bash shim (pyenv), so the code under test was never reached. An unresolved interpreter now exits 10 (a setup error, not a pass), and a new control shows the shim case both ways (#1126)
117
+ - `.github/workflows/validate.yml` (not in the npm package): the required `validate` check no longer calls the GitHub API to prove every selfcheck shard passed. Each shard's last step writes its own job output `leg_<i>=passed:<i>/<N>`, and the check reads only `needs.selfcheck.result` and `needs.selfcheck.outputs`; a missing, extra, empty or mislabelled key, unreadable outputs, or a result other than `success` is red. The `validate` job no longer needs `actions: read` or a token. Why: a downstream consumer on GitHub Enterprise got HTTP 401 from the jobs listing with the job token although every shard had passed, so the required check could never go green; no «API failed → pass» fallback was added. `scripts/test_ci_validate_shard_count_lanes.sh` (not in the npm package) runs the step against fixtures built for the workflow's own shard count and reads the workflow as YAML to check the wiring (22 lanes; it needs PyYAML, which CI installs) (#1130)
118
+
119
+ ### Docs
120
+ - `knowledge/shared/plugin-catalog/recommended_plugins.md` (shipped) category 0.5 is re-enumerated from the live `claude-plugins-official` directory: 43 plugins (7 new, none removed), replacing a 36-plugin snapshot. Each row gains the plugin's own description and an «already covered / FH overlap» column, plus two notes: every enabled plugin also loads into headless `claude -p` runs (live-eval reports differing sets as `INVALID-COMPARISON`, #1121), so enable plugins only where clearly used; and the LSP plugins need their language server installed separately (#1122)
121
+ - `docs/USER_GUIDE.md` §4 (shipped) opens with a table comparing one Claude Code session working in sequence, one session plus subagents or worktrees, and FH, quoting two Anthropic lines with their source. It adds how work sessions stack under a supervising governor, how to ask for a close-time sweep, and an opt-in lease block for reversible maintenance on your own machine (no FH rule reads it). `AGENTS.md` points to it (#1116)
122
+
5
123
  ### [3.43.0] — 2026-11-15
6
124
 
7
125
  Minor by the version policy: a new shipped tool and lane for live-eval (#1099), a new shipped lane for `meta-prompt-builder` (#1103), and new judged procedures in shipped skills and rules. Nothing here makes an existing commit or publish gate refuse more by default, so no `BREAKING (gate)` line applies. Two checks are stricter, and neither is a consumer gate: the live-eval report can now exit 2 with `INVALID-COMPARISON` (#1099), and the checkout-only fixture-guard ratchet counts more git calls (#1097). The one new refusal path in a shipped gate script is opt-in: `remote_marker_gate.sh` reads PR bodies over the API only when `RMG_PR_LOOKUP=1` is set, and a failed lookup then exits 10 (#1105). If you run the 3.42.0 package's `test_fixture_guard_coverage_lanes.sh` directly, it no longer fails on the checkout floor (#1097). Items marked «not in the npm package» are in the repository checkout only.
@@ -50,6 +50,51 @@ single-session even when sidecars are available.
50
50
 
51
51
  ## Step 2 — Sidecar discovery (mechanical, the anti-power-waste core)
52
52
 
53
+ 🟥 **A cloud agent CLI with tools enabled must not run on a machine where company repositories are
54
+ readable.** That covers `agy` in every mode (`--mode plan` included) and any similar CLI that runs its
55
+ own shell or file tools: what those tools print goes to the cloud model. Measured 2026-11-16: given an
56
+ empty temp directory as cwd, `agy -p --mode plan` searched the whole filesystem and the home directory,
57
+ read the run's answer key in 45 of 83 conversations, and sent file names from a company repository on
58
+ the same machine to the model. **Allowed instead**: a tool-less API call (prompt and excerpt only, no
59
+ tools offered), or the CLI inside a container or a separate OS user that can see only the frozen inputs.
60
+ **`--sandbox` is not isolation**: measured 2026-11-16 with canary files, `agy -p --mode plan --sandbox`
61
+ read files it was pointed at in its cwd, in another temp folder and in the home directory. FH's scripts
62
+ start agy only through `scripts/agy_launch_guard.sh`, which refuses (exit 3, `AGY-REFUSED`) unless
63
+ `FH_AGY_ISOLATION=container` or `FH_AGY_ISOLATION=os-user`. The marker is self-declared — the guard checks
64
+ that you said it, not that it is true — so set it only inside a container or OS user where a canary check
65
+ has confirmed it (canary files outside the frozen inputs, agy asked to read those exact paths, every read
66
+ fails). Being
67
+ discovered below makes agy a *candidate*, not a recruit: on the host, without the marker, it is not
68
+ recruitable. Lanes: `scripts/test_agy_launch_guard_lanes.sh`.
69
+
70
+ **On this machine, for public material only: `FH_AGY_ISOLATION=no-tools-agent`** (2026-11-19). This is the one
71
+ marker the guard partly checks instead of taking on trust. Measured with canaries: a custom agent whose
72
+ definition says `tools: []` made 0 file reads in 4 of 4 runs, while a control with the same body read
73
+ both canaries; settings keys and `permissions.deny` did not stop reads. On this route the guard:
74
+ - refuses when the prompt, an argument or the working folder names a company-repo root (codex guard's
75
+ list; an unconfigured list is refused);
76
+ - writes a `tools: []` agent definition under a unique name into `~/.gemini/agents`, runs agy with it,
77
+ and removes the definition;
78
+ - reads every run's stream-json and **voids** the run (exit 4, nothing printed) on any tool step other
79
+ than `manage_task`, another agent, or a stream it cannot parse.
80
+
81
+ A void cannot un-send what a tool already read, which is why company paths are refused before the start.
82
+
83
+ **The route FH ships for agy: a separate OS user on another machine** — `scripts/agy_remote_run.sh` (the `container` / `os-user` markers remain for an isolated environment you built yourself, and the guard cannot check those).
84
+ Set `FH_AGY_BIN=<repo>/scripts/agy_remote_run.sh` and `FH_AGY_ISOLATION=remote-os-user` (the guard honours
85
+ that value only for this runner). Configuration is environment-only (`FH_AGY_REMOTE` = ssh target,
86
+ `FH_AGY_REMOTE_DENY` = `;`-separated paths that user must not read). First run
87
+ `agy_remote_run.sh --canary` — no agy, a plain remote shell tries every deny path (all must be refused)
88
+ and a positive file (must be readable) and writes a local receipt. Runs are refused without a PASS
89
+ receipt under 7 days old for the same settings, and a route that is down is a refusal (exit 4), never a
90
+ local agy. The receipt is the record of that measurement, not proof of isolation. **Name what the remote
91
+ user can still read**: on the operator's machine measured 2026-11-16, the remote user cannot read the
92
+ admin profile, the shared Public folder, the admin WSL home or the two data-drive roots, but still lists
93
+ or opens 8 sub-items the operator accepted — game folders, the two recycle bins, an antivirus decoy
94
+ folder and three device-information files — because those carry their own explicit allow entries that an
95
+ inherited deny does not override. Lanes: `scripts/test_agy_remote_run_lanes.sh` (fake ssh/scp; the
96
+ PowerShell side was run for real once).
97
+
53
98
  Build the available panel at run time; absent tools **and unreachable endpoints** drop off silently:
54
99
  ```bash
55
100
  # Sidecar-callable CLIs only. **Scope discipline**: the probe list is NOT "every agent CLI that exists".
@@ -154,11 +199,23 @@ diversity vs the orchestrator** (orchestrator = Claude/opus → recruit GPT or G
154
199
  > does not exist until the process has exited.
155
200
 
156
201
  ```bash
157
- printf '%s' "$prompt" | bash scripts/sidecar_wait.sh out.txt 900 -- codex exec -m gpt-5.5 -
202
+ printf '%s' "$prompt" | bash scripts/sidecar_wait.sh out.txt 900 -- bash scripts/codex_launch_guard.sh codex exec -
158
203
  # → SIDECAR_VERDICT=COMPLETE exit=0 bytes=48489 (read out.txt)
159
204
  # → SIDECAR_VERDICT=TIMEOUT waited=900s bytes=0 (still alive — NOT a result)
160
205
  # → SIDECAR_VERDICT=EMPTY exit=0 (the only state that means "it said nothing")
206
+ # → SIDECAR_VERDICT=HARNESS-ERROR exit=1 reason=model-not-available (exit 3 — nothing was reviewed)
161
207
  ```
208
+ No `-m` pin by default: the CLI default answers, while a pinned model can be retired under you —
209
+ on 2026-11-16 `-m gpt-5.5` and `-m gpt-5` returned HTTP 400 «not supported when using Codex with a
210
+ ChatGPT account» (rc 1). Pin only a model `sidecar_calibrate.sh` has just shown answering.
211
+ 🟥 **Send codex only public diffs.** Its `--sandbox read-only` limits writes, not reads: measured
212
+ 2026-11-16 with canary files, it read paths in its cwd, in another temp folder and in the home
213
+ directory. A codex arm on a machine that holds company checkouts must never be given company
214
+ material, and the sandbox flag is not a reason to relax that. FH starts codex verifier arms through
215
+ `scripts/codex_launch_guard.sh`, which refuses (exit 3, `HARNESS-ERROR: CODEX-REFUSED`) when the prompt, an
216
+ argument or the working folder names a root in the operator's company-repo list (`FH_COMPANY_ROOTS` or the
217
+ gitignored `.claude/rules/.company-roots`); with no list it runs and says «not checked». It is a string check
218
+ on paths, not isolation: a relative path or pasted file content without its path is not seen.
162
219
 
163
220
  The runner **refuses to emit a verdict while the process is alive**, so "the sidecar returned
164
221
  nothing" becomes unsayable until it has actually exited. Grep the typed `SIDECAR_VERDICT=` line;
@@ -591,6 +591,10 @@ fi
591
591
  # skill's own Per-item-approval principle). Ask BEFORE running the python:
592
592
  # "Register the SessionStart hooks (floor check · env-delta · companion load) into
593
593
  # .claude/settings.json? (Y/N)
594
+ # [only when templates/settings.CartridgeLoader.snippet.json exists — a hub checkout, not the npm
595
+ # package:] This also registers the cartridge loader. It injects nothing until you write
596
+ # .claude/cartridges.enabled yourself (example: templates/cartridges.enabled.example) — it
597
+ # loads only admitted snapshots you list.
594
598
  # On N: you get no turn-0 mechanical signal — floor gaps, env changes and companion freshness
595
599
  # fall back to session prose, and some of FH's intended features will not run as designed.
596
600
  # The decline is recorded and a one-line per-session reminder will note the state
@@ -173,14 +173,14 @@ Run multi-team? (a) Full panel (b) Claude sub-agents only (c) Skip to Area B
173
173
  | T1 Gemini | `gemini` pipe | beginner · main-player · challenger | `echo PROMPT \| gemini` |
174
174
  | T2 Copilot | `gh copilot suggest` | challenger · expert | `gh copilot suggest -t shell` |
175
175
  | T3 Ollama | `ollama run` | challenger | `ollama run llama3 PROMPT` |
176
- | T4 Codex | `npx @openai/codex exec` | challenger · edge-case-hunter | `echo PROMPT \| npx @openai/codex exec -m gpt-5 -` |
176
+ | T4 Codex | `npx @openai/codex exec` | challenger · edge-case-hunter | `echo PROMPT \| npx @openai/codex exec -` (no `-m`: `gpt-5` returns HTTP 400 as of 2026-11-16) |
177
177
 
178
178
  > **사이드카 대기는 기계로 한다** — `scripts/sidecar_wait.sh` 경유가 필수 형식이고, 타입 verdict
179
- > (`COMPLETE`/`TIMEOUT`/`EMPTY`)만 읽는다. **`EMPTY` 만이 "사이드카가 아무 말 안 했다"** 이다.
179
+ > (`COMPLETE`/`TIMEOUT`/`EMPTY`/`HARNESS-ERROR`)만 읽는다. `HARNESS-ERROR` = CLI 가 모델을 거절했다(아무것도 검토 안 됨). **`EMPTY` 만이 "사이드카가 아무 말 안 했다"** 이다.
180
180
  > 출력 파일을 눈으로 보고 판정하지 마라 — 살아있는 프로세스와 죽은 프로세스가 같은 0바이트를
181
181
  > 낸다(2026-07-29 실측: 1초/30초 만에 읽고 정상 동작 중인 사이드카 2종을 '실패'로 기록,
182
182
  > 실제로는 4건의 진짜 finding 이 나왔다). 정본 = `auto-decorrelation` SKILL.md §S-1b.
183
- | T5 agy | `agy -p` (gemini successor) | challenger · beginner | `agy -p "PROMPT"` — argument form only (stdin pipe prints help); timebox+retry hard rule (intermittent hang class); -p auto-approves tools → trusted artifacts only |
183
+ | T5 agy | `agy -p` (gemini successor) | challenger · beginner | `agy -p "PROMPT"` — argument form only (stdin pipe prints help); timebox+retry hard rule (intermittent hang class); -p auto-approves tools → trusted artifacts only; start it only through `scripts/agy_launch_guard.sh` (refuses unless `FH_AGY_ISOLATION=container\|os-user` — never on a host where company repos are readable, auto-decorrelation §Step 2) |
184
184
 
185
185
  ### CLI detection bash
186
186
 
@@ -300,7 +300,7 @@ Default team-persona assignments:
300
300
  | **T4 Codex** | `npx @openai/codex exec` | devil · edge-case-hunter |
301
301
 
302
302
  > **사이드카 대기는 기계로 한다** — `scripts/sidecar_wait.sh` 경유가 필수 형식이고, 타입 verdict
303
- > (`COMPLETE`/`TIMEOUT`/`EMPTY`)만 읽는다. **`EMPTY` 만이 "사이드카가 아무 말 안 했다"** 이다.
303
+ > (`COMPLETE`/`TIMEOUT`/`EMPTY`/`HARNESS-ERROR`)만 읽는다. `HARNESS-ERROR` = CLI 가 모델을 거절했다(아무것도 검토 안 됨). **`EMPTY` 만이 "사이드카가 아무 말 안 했다"** 이다.
304
304
  > 출력 파일을 눈으로 보고 판정하지 마라 — 살아있는 프로세스와 죽은 프로세스가 같은 0바이트를
305
305
  > 낸다(2026-07-29 실측: 1초/30초 만에 읽고 정상 동작 중인 사이드카 2종을 '실패'로 기록,
306
306
  > 실제로는 4건의 진짜 finding 이 나왔다). 정본 = `auto-decorrelation` SKILL.md §S-1b.
@@ -363,7 +363,11 @@ fi
363
363
  # ── T5: agy (Antigravity) — gemini successor ──────────────
364
364
  # Constraints: argument form only (`agy -p "PROMPT"`); timebox+retry is a hard rule
365
365
  # (intermittent hang class, ~50% observed 2026-06-11); -p auto-approves tool execution,
366
- # so feed only trusted artifacts — never untrusted external content. Serial by design
366
+ # so feed only trusted artifacts — never untrusted external content. 🟥 Its tools also READ the
367
+ # machine and send what they print to the cloud model: start it only through
368
+ # scripts/agy_launch_guard.sh, which refuses unless FH_AGY_ISOLATION=container|os-user (or no-tools-agent,
369
+ # a tools: [] agent with every run checked — public material only) — never on a
370
+ # host where company repositories are readable (auto-decorrelation §Step 2). Serial by design
367
371
  # (worst case ~6 min if the hang class fires on every call) — do NOT copy the T1-T4
368
372
  # `VAR=$(...) &` pattern: it assigns inside a background subshell.
369
373
  if [[ " ${TEAMS[*]} " =~ " agy " ]]; then
@@ -372,8 +376,9 @@ if [[ " ${TEAMS[*]} " =~ " agy " ]]; then
372
376
  # pipe can outlive it (same gap as `timeout` without process-group kill).
373
377
  tb() { perl -e 'alarm shift; exec @ARGV' "$@"; }
374
378
  agy_call() { # $1=prompt — 60s timebox, 1 retry on empty
375
- local out; out=$(tb 60 agy -p "$1" 2>/dev/null)
376
- [ -z "$out" ] && out=$(tb 60 agy -p "$1" 2>/dev/null)
379
+ local g="${FH_DIR:-.}/scripts/agy_launch_guard.sh" out
380
+ out=$(tb 60 bash "$g" agy -p "$1" 2>/dev/null)
381
+ [ -z "$out" ] && out=$(tb 60 bash "$g" agy -p "$1" 2>/dev/null)
377
382
  printf '%s' "$out"
378
383
  }
379
384
  A_DEVIL=$(agy_call "[Devil] Adversarial reviewer, no prior context.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fh-preprep",
3
- "version": "3.43.0",
3
+ "version": "3.45.0",
4
4
  "engines": {
5
5
  "claudeCode": ">=1.0.0"
6
6
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fh-qp",
3
- "version": "3.43.0",
3
+ "version": "3.45.0",
4
4
  "engines": {
5
5
  "claudeCode": ">=1.0.0"
6
6
  },
@@ -0,0 +1,165 @@
1
+ #!/usr/bin/env bash
2
+ # agy_launch_guard.sh — every FH launch of agy (the Antigravity CLI) goes through here.
3
+ #
4
+ # WHY. agy runs its own tools (shell commands, file reads) even in `--mode plan`, and what those tools
5
+ # print goes into the conversation the cloud model reads. Measured 2026-11-16 on a review run with an
6
+ # empty temp directory as cwd: agy ran a filesystem-wide `find` and a recursive `grep` over the home
7
+ # directory, read the run's answer key in 45 of 83 conversations, and the search output carried file
8
+ # names from a company repository checked out on the same machine. Claude-side deny rules do not bind
9
+ # agy. 🟥 `--sandbox` is NOT isolation: measured 2026-11-16 (canary test), `agy -p --mode plan --sandbox`
10
+ # from a fresh temp cwd read three canary files it was pointed at — one in cwd, one in another temp
11
+ # folder, one in the home directory. It restricts the terminal at most; file reads go through.
12
+ #
13
+ # RULE. A cloud agent CLI with tools enabled must not run on a machine where company repositories are
14
+ # readable. Allowed instead: a tool-less API call (that does not use agy, so it does not come here), or
15
+ # agy inside a container or a separate OS user that can see only the frozen inputs of the task.
16
+ #
17
+ # MARKER. FH_AGY_ISOLATION=container or FH_AGY_ISOLATION=os-user, or FH_AGY_ISOLATION=remote-os-user
18
+ # (honoured only when the target is scripts/agy_remote_run.sh beside this guard). Unset, empty, or any other value
19
+ # (including 1 / yes / true) is refused. 🟥 The marker is self-declared: this script checks that you
20
+ # said it, not that it is true — it cannot see a container or an OS user. Set it only inside a container
21
+ # or OS user where a canary check has confirmed it: place a canary file outside the frozen inputs (in
22
+ # the host home directory and in another temp folder), ask agy to read those exact paths, and set the
23
+ # marker only if every read fails. Never on the host that holds company repositories, and never because
24
+ # of `--sandbox`.
25
+ #
26
+ # NO-TOOLS AGENT (2026-11-19, on this machine). FH_AGY_ISOLATION=no-tools-agent is the one marker the guard
27
+ # can partly CHECK rather than take on trust. Measured 2026-11-19 with canaries: a custom agent whose
28
+ # definition says `tools: []` made 0 file reads in 4 of 4 runs, while a control with the same body and no
29
+ # `tools` line read both canaries; settings keys and `permissions.deny` did not stop reads, and `init.tools`
30
+ # lists 60 tools either way (not a signal). `manage_task` (agy's own task list) still ran. So on this route:
31
+ # 1. refuse unless the prompt (stdin), the arguments and the working folder carry no company-repo root —
32
+ # the matcher is codex_launch_guard.sh's, and an UNCONFIGURED list is refused here, not warned;
33
+ # 2. refuse a caller's own --agent or any output format but text (a caller's `--output-format text` is
34
+ # dropped — this route prints the result text; FH's fleet and verifier pass it);
35
+ # 3. write an FH-owned definition with `tools: []` under a unique name into the folder agy discovers
36
+ # (FH_AGY_AGENTS_DIR, default ~/.gemini/agents — measured: `agy agents` lists definitions from
37
+ # ~/.gemini/agents and ~/.gemini/config/agents only, not from the working folder), run agy with
38
+ # --agent <it> --output-format stream-json, and remove the definition when the run ends;
39
+ # 4. read the whole stream and VOID the run (exit 4, nothing on stdout) when a line does not parse, the
40
+ # init event names another agent, a step is neither user_input nor agent_response nor a tool step whose
41
+ # tool_name AND tool_info.name are both exactly manage_task (any state — ACTIVE, DONE or ERROR), an event
42
+ # is not init / step_update / result, or no successful result arrives — naming the step or tool. Only a
43
+ # run that passes prints the result text on stdout. Deny by default: 13 probe runs saw manage_task,
44
+ # read_file, search_web and write_file, which is not every tool agy has.
45
+ # 🟥 A void cannot un-send: what a forbidden tool read has already gone to the cloud model. That is why step 1
46
+ # refuses company paths before the start, and why this route is for public material only.
47
+ #
48
+ # Usage: bash scripts/agy_launch_guard.sh <agy-binary> [agy arguments...]
49
+ # Exit: 3 = refused, agy was not started · 2 = usage · 4 = no-tools-agent run voided (stdout empty)
50
+ # · otherwise agy's own exit code
51
+ set -uo pipefail
52
+ [ $# -ge 1 ] || { echo "usage: agy_launch_guard.sh <agy-binary> [agy arguments...]" >&2; exit 2; }
53
+ case "${FH_AGY_ISOLATION-}" in
54
+ container|os-user) exec "$@" ;;
55
+ no-tools-agent)
56
+ _here="$(cd "$(dirname "$0")" && pwd -P)"
57
+ _refuse() { echo "AGY-REFUSED: $1 — agy was not started (FH_AGY_ISOLATION=no-tools-agent)." >&2; exit 3; }
58
+ # The caller's own `--output-format text` is dropped (this route prints the result text anyway — FH's
59
+ # fleet and verifier pass it); any other output format or an --agent is refused.
60
+ _args=(); _skip=0
61
+ for _a in "${@:2}"; do
62
+ if [ "$_skip" = 1 ]; then
63
+ _skip=0; [ "$_a" = text ] && continue
64
+ _refuse "the caller asked for --output-format $_a; this route prints text only"
65
+ fi
66
+ case "$_a" in
67
+ --output-format) _skip=1 ;;
68
+ --output-format=text) ;;
69
+ --output-format=*) _refuse "the caller asked for $_a; this route prints text only" ;;
70
+ --agent|--agent=*) _refuse "the caller passed $_a; this route sets the agent itself" ;;
71
+ *) _args+=("$_a") ;;
72
+ esac
73
+ done
74
+ [ "$_skip" = 0 ] || _refuse "--output-format has no value"
75
+ set -- "$1" ${_args[@]+"${_args[@]}"}
76
+ [ -f "$_here/codex_launch_guard.sh" ] || _refuse "codex_launch_guard.sh (the company-path matcher) is missing beside this guard"
77
+ _w="$(mktemp -d "${TMPDIR:-/tmp}/fh_agy_nt.XXXXXX")" || _refuse "no temp dir"
78
+ _def=""
79
+ trap 'rm -rf "$_w"; [ -n "$_def" ] && rm -f "$_def"' EXIT
80
+ if [ -t 0 ]; then : > "$_w/prompt"; else cat > "$_w/prompt"; fi
81
+ _chk="$(bash "$_here/codex_launch_guard.sh" /usr/bin/true "$@" < "$_w/prompt" 2>&1)"; _crc=$? # the agy path itself too
82
+ [ "$_crc" -eq 0 ] || _refuse "the company-path check refused or failed: $(printf '%s' "$_chk" | tr '\n' ' ' | cut -c1-200)"
83
+ case "$_chk" in *"no company roots configured"*) _refuse "no company-repo roots are configured, so the prompt could not be checked" ;; esac
84
+ _dir="${FH_AGY_AGENTS_DIR:-$HOME/.gemini/agents}"
85
+ mkdir -p "$_dir" || _refuse "cannot create the agents folder $_dir"
86
+ _name="fh-notools-$(od -An -N6 -tx1 /dev/urandom | tr -d ' \n')"
87
+ [ "${#_name}" -eq 23 ] || _refuse "could not make a unique agent name"
88
+ _def="$_dir/$_name.md"
89
+ [ ! -e "$_def" ] || _refuse "an agent definition named $_name already exists"
90
+ printf -- '---\nname: %s\ndescription: FH tool-less agent (written by agy_launch_guard.sh, removed after the run)\ntools: []\n---\nYou have no tools. Answer from the prompt text only.\n' "$_name" > "$_def" \
91
+ || _refuse "cannot write the agent definition"
92
+ "$1" "${@:2}" --agent "$_name" --output-format stream-json < "$_w/prompt" > "$_w/stream" 2> "$_w/err"; _arc=$?
93
+ rm -f "$_def"; _def=""
94
+ _v="$(python3 - "$_w/stream" "$_name" "$_w/response" <<'PY'
95
+ import json, sys
96
+ path, name, out = sys.argv[1], sys.argv[2], sys.argv[3]
97
+ def void(why): print("VOID " + why); sys.exit(0)
98
+ init = result = None
99
+ try: lines = open(path, encoding="utf-8").read().splitlines()
100
+ except (OSError, UnicodeDecodeError) as e: void("stream unreadable (%s)" % type(e).__name__)
101
+ for n, raw in enumerate(lines, 1):
102
+ if not raw.strip(): void("line %d is blank" % n) # deny by default: agy does not print blank lines
103
+ try: d = json.loads(raw)
104
+ except ValueError: void("line %d is not JSON" % n)
105
+ if not isinstance(d, dict): void("line %d is not an object" % n)
106
+ ev = d.get("event")
107
+ body = d.get(ev) if isinstance(ev, str) else None
108
+ if not isinstance(body, dict): void("line %d has no event body" % n)
109
+ if ev == "init":
110
+ if init is not None: void("a second init event on line %d" % n)
111
+ init = body
112
+ if body.get("agent") != name: void("init names agent %r, not %s" % (body.get("agent"), name))
113
+ elif ev == "step_update":
114
+ if init is None: void("a step before the init event (line %d)" % n)
115
+ st = body.get("step_type")
116
+ if st in ("user_input", "agent_response"): continue
117
+ if st == "tool":
118
+ # agy 1.5.11 names a tool step twice: step_update.tool_name and step_update.tool_info.name (13 probe
119
+ # runs, 2026-11-19). Both must say manage_task; a missing or different one voids — whatever the
120
+ # state (ACTIVE, DONE or ERROR: a tool that started has run).
121
+ info = body.get("tool_info")
122
+ n1, n2 = body.get("tool_name"), (info.get("name") if isinstance(info, dict) else None)
123
+ if n1 == "manage_task" and n2 == "manage_task": continue
124
+ void("tool step %s (index %s, state %s)" % ("/".join(sorted({str(n1), str(n2)})), body.get("step_index"), body.get("state")))
125
+ void("step of type %r (index %s; keys %s)" % (st, body.get("step_index"), ",".join(sorted(body))))
126
+ elif ev == "result":
127
+ if result is not None: void("a second result event on line %d" % n)
128
+ result = body
129
+ else:
130
+ void("unknown event %r on line %d" % (ev, n))
131
+ if init is None: void("no init event")
132
+ if result is None: void("no result event")
133
+ if result.get("status") != "SUCCESS": void("result status %r" % result.get("status"))
134
+ resp = result.get("response")
135
+ if not isinstance(resp, str): void("result has no response text")
136
+ open(out, "w", encoding="utf-8").write(resp)
137
+ print("OK")
138
+ PY
139
+ )"
140
+ case "$_v" in
141
+ OK) cat "$_w/response"; exit "$_arc" ;;
142
+ VOID*) echo "AGY-VOID: ${_v#VOID } — the run was discarded (agy rc=$_arc). Anything a tool read has already been sent; this route takes public material only." >&2
143
+ [ -s "$_w/err" ] && tail -3 "$_w/err" >&2
144
+ exit 4 ;;
145
+ *) echo "AGY-VOID: the stream check did not run (${_v:-no output}) — the run was discarded (agy rc=$_arc)." >&2; exit 4 ;;
146
+ esac ;;
147
+ remote-os-user)
148
+ # Honoured for ONE route only: the target must be FH's remote runner beside this guard, which runs
149
+ # agy as a separate OS user on another machine and itself refuses without a fresh canary receipt.
150
+ _here="$(cd "$(dirname "$0")" && pwd -P)"
151
+ _tgt_dir="$(cd "$(dirname "$1")" 2>/dev/null && pwd -P)"
152
+ if [ "$_tgt_dir/$(basename "$1")" = "$_here/agy_remote_run.sh" ] && [ -f "$_here/agy_remote_run.sh" ]; then
153
+ exec bash "$_here/agy_remote_run.sh" "${@:2}"
154
+ fi
155
+ echo "AGY-REFUSED: FH_AGY_ISOLATION=remote-os-user is honoured only when the target is $_here/agy_remote_run.sh (got: $1)." >&2
156
+ exit 3 ;;
157
+ esac
158
+ {
159
+ echo "AGY-REFUSED: agy was not started (FH_AGY_ISOLATION=${FH_AGY_ISOLATION-<unset>})."
160
+ echo " agy runs shell and file tools and sends their output to a cloud model, so it must not run where"
161
+ echo " company repositories are readable. Run it in a container or a separate OS user that sees only the"
162
+ echo " frozen inputs, then set FH_AGY_ISOLATION=container|os-user there — or use a tool-less API call."
163
+ echo " On this machine, for public material only: FH_AGY_ISOLATION=no-tools-agent (a tools: [] agent, every run checked)."
164
+ } >&2
165
+ exit 3