@ask-llm/plugin 0.14.0 → 0.16.2

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 (49) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/.cursor-plugin/plugin.json +25 -0
  3. package/CHANGELOG.md +966 -0
  4. package/README.md +49 -9
  5. package/agents/brainstorm-coordinator.md +70 -25
  6. package/agents/gemini-reviewer.md +1 -1
  7. package/dist/antigravity-run.js +0 -0
  8. package/dist/brainstorm-panel.d.ts +46 -0
  9. package/dist/brainstorm-panel.d.ts.map +1 -0
  10. package/dist/brainstorm-panel.js +247 -0
  11. package/dist/brainstorm-panel.js.map +1 -0
  12. package/dist/brainstorm-run.d.ts +3 -0
  13. package/dist/brainstorm-run.d.ts.map +1 -0
  14. package/dist/brainstorm-run.js +51 -0
  15. package/dist/brainstorm-run.js.map +1 -0
  16. package/dist/codex-run.js +0 -0
  17. package/dist/grok-run.js +0 -0
  18. package/dist/ollama-run.js +0 -0
  19. package/dist/run.js +0 -0
  20. package/mcp.json +11 -0
  21. package/package.json +18 -15
  22. package/pi/extensions/provider-tools.ts +8 -1
  23. package/scripts/benchmark/README.md +114 -0
  24. package/scripts/benchmark/fixtures/README.md +29 -0
  25. package/scripts/codex-pair-debounce-worker.mjs +0 -0
  26. package/scripts/codex-pair-log.mjs +4 -13
  27. package/scripts/codex-pair-prompt-drain.mjs +1 -1
  28. package/scripts/codex-pair-session.mjs +2 -2
  29. package/scripts/codex-pair-stop-gate.mjs +8 -8
  30. package/scripts/codex-pair-watch.mjs +20 -39
  31. package/skills/brainstorm/SKILL.md +62 -39
  32. package/skills/codex-pair/SKILL.md +44 -2
  33. package/skills/gemini-review/SKILL.md +1 -1
  34. package/skills/grok-pair/SKILL.md +115 -0
  35. package/skills/pairing-contract.md +40 -0
  36. package/scripts/lib/broker-lifecycle.mjs +0 -575
  37. package/scripts/lib/broker-rpc.mjs +0 -203
  38. package/scripts/lib/broker-transport.mjs +0 -407
  39. package/scripts/lib/broker.mjs +0 -537
  40. package/scripts/lib/debounce-state.mjs +0 -208
  41. package/scripts/lib/parser.d.mts +0 -12
  42. package/scripts/lib/parser.mjs +0 -229
  43. package/scripts/lib/process.mjs +0 -56
  44. package/scripts/lib/prompt.d.mts +0 -8
  45. package/scripts/lib/prompt.mjs +0 -41
  46. package/scripts/lib/session-registry.mjs +0 -162
  47. package/scripts/lib/state.d.mts +0 -58
  48. package/scripts/lib/state.mjs +0 -733
  49. package/scripts/lib/stop-gate.mjs +0 -134
package/CHANGELOG.md ADDED
@@ -0,0 +1,966 @@
1
+ # @ask-llm/plugin
2
+
3
+ ## 0.16.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#314](https://github.com/Lykhoyda/ask-llm/pull/314) [`bb13eb0`](https://github.com/Lykhoyda/ask-llm/commit/bb13eb0698317545fef776f716df461bb21b8936) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Adopt Google's GA `gemini-3.8-flash` as the Gemini quota-fallback default and mirror it through the plugin's Gemini runner, agent, skill, and Pi surfaces. The `gemini-3.1-pro-preview` primary default, `ASK_GEMINI_FALLBACK_MODEL` override, and Antigravity's independent `gemini-3.5-flash` fallback remain unchanged ([#312](https://github.com/Lykhoyda/ask-llm/issues/312)).
8
+ - Updated dependencies [[`bb13eb0`](https://github.com/Lykhoyda/ask-llm/commit/bb13eb0698317545fef776f716df461bb21b8936)]:
9
+ - @ask-llm/gemini-mcp@1.9.0
10
+ - @ask-llm/mcp@0.9.2
11
+
12
+ ## 0.16.1
13
+
14
+ ### Patch Changes
15
+
16
+ - Updated dependencies [[`bfb24b2`](https://github.com/Lykhoyda/ask-llm/commit/bfb24b2327d910fc9e940de58b399ec7c54fda20)]:
17
+ - @ask-llm/gemini-mcp@1.8.1
18
+ - @ask-llm/grok-mcp@0.1.4
19
+ - @ask-llm/codex-mcp@0.7.7
20
+ - @ask-llm/ollama-mcp@0.6.1
21
+ - @ask-llm/antigravity-mcp@0.7.4
22
+ - @ask-llm/mcp@0.9.1
23
+
24
+ ## 0.16.0
25
+
26
+ ### Minor Changes
27
+
28
+ - [#304](https://github.com/Lykhoyda/ask-llm/pull/304) [`f9f3e9d`](https://github.com/Lykhoyda/ask-llm/commit/f9f3e9d14be950cb142b7d0e9944b755106b28ea) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Bump the factory-default Ollama model from `qwen3.6:27b` to same-size-class `qwen3.8:27b` (official library `latest` / 27b tag, ~18 GB Q4_K_M). `ASK_OLLAMA_MODEL` overrides are unchanged; a missing local model still fails with an actionable `ollama pull` error and no silent substitution.
29
+
30
+ ### Patch Changes
31
+
32
+ - [#300](https://github.com/Lykhoyda/ask-llm/pull/300) [`a24889e`](https://github.com/Lykhoyda/ask-llm/commit/a24889e958af2962a0fc0e31cdd7d5ab042a5973) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Refresh the MCP SDK, validation libraries, Pi host SDK, and transitive runtime dependencies, including security-fixed Hono, URI, archive, HTTP, and parser releases.
33
+
34
+ - [#306](https://github.com/Lykhoyda/ask-llm/pull/306) [`c132496`](https://github.com/Lykhoyda/ask-llm/commit/c13249605ae54557ff52b137b3c872edcedd2f07) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Adopt Google's GA `gemini-3.7-flash` as the Gemini quota-fallback default and mirror it through the plugin's Gemini runner, agent, skill, and Pi surfaces. The `gemini-3.1-pro-preview` primary default, `ASK_GEMINI_FALLBACK_MODEL` override, and Antigravity's independent `gemini-3.5-flash` fallback remain unchanged ([#298](https://github.com/Lykhoyda/ask-llm/issues/298)).
35
+ - Updated dependencies [[`a24889e`](https://github.com/Lykhoyda/ask-llm/commit/a24889e958af2962a0fc0e31cdd7d5ab042a5973), [`c132496`](https://github.com/Lykhoyda/ask-llm/commit/c13249605ae54557ff52b137b3c872edcedd2f07), [`f9f3e9d`](https://github.com/Lykhoyda/ask-llm/commit/f9f3e9d14be950cb142b7d0e9944b755106b28ea)]:
36
+ - @ask-llm/antigravity-mcp@0.7.3
37
+ - @ask-llm/codex-mcp@0.7.6
38
+ - @ask-llm/gemini-mcp@1.8.0
39
+ - @ask-llm/grok-mcp@0.1.3
40
+ - @ask-llm/ollama-mcp@0.6.0
41
+ - @ask-llm/mcp@0.9.0
42
+
43
+ ## 0.15.0
44
+
45
+ ### Minor Changes
46
+
47
+ - [#290](https://github.com/Lykhoyda/ask-llm/pull/290) [`af77cd8`](https://github.com/Lykhoyda/ask-llm/commit/af77cd8b90cb836f87a39893d52e983a36fbea53) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Add an exact Grok + GPT-5.6 Sol brainstorming panel with Cursor Agent as the preferred model-neutral harness, explicit direct-Grok alternatives, deterministic partial-failure synthesis rules, truthful route/model attribution, and no Gemini or silent fallback in the two-model workflow.
48
+
49
+ - [#291](https://github.com/Lykhoyda/ask-llm/pull/291) [`d989ec9`](https://github.com/Lykhoyda/ask-llm/commit/d989ec916f71eefe5fe0814d5c1eb75d29dfe89f) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Add a first-class Claude Code `/grok-pair` workflow with explicit Cursor Agent, xAI API, or Grok CLI routes and no silent fallback. Add Cursor Plugin/Agent Skills support for `/codex-pair` with consent, bounded context, exact Codex model/effort/include options, persisted session reuse, cancellation, and actionable diagnostics. Unified Ask LLM now forwards supported reasoning/include options, rejects `includeDirs` on resumed Codex threads instead of dropping them (enforced once in the shared Codex executor so the split `ask-codex` and Pi tools fail closed too), and Cursor Agent consultations support validated include directories plus structured session resume. The Claude plugin keeps bundling only Codex; `@ask-llm/mcp` and `@ask-llm/grok-mcp` are user-scoped installs for the Grok routes. Unified startup now detects authenticated Grok CLI-only installations without requiring an API key or server-wide harness override (an explicit `ASK_GROK_HARNESS` keeps readiness on that harness), while execution remains pinned to the request's explicit harness with no fallback and a CLI-only default-route call reports the `harness: "grok-cli"` pin instead of a bare missing-key error. The Cursor plugin manifest exposes exactly `/codex-pair` and `/grok-pair` with explicit empty `agents`/`commands`/`hooks`, and its `mcp.json` bundles only the unified `ask-llm` server (split Codex/Grok servers are optional user installs).
50
+
51
+ ### Patch Changes
52
+
53
+ - [#293](https://github.com/Lykhoyda/ask-llm/pull/293) [`fc4be66`](https://github.com/Lykhoyda/ask-llm/commit/fc4be66cef40a0d3691540fad404b5a11b93a0e4) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Document Pi's pre-dispatch refusal of brainstorm participant lists that mix routed model specs with bare provider names.
54
+
55
+ - Updated dependencies [[`d989ec9`](https://github.com/Lykhoyda/ask-llm/commit/d989ec916f71eefe5fe0814d5c1eb75d29dfe89f), [`fa272ee`](https://github.com/Lykhoyda/ask-llm/commit/fa272ee9c5ea1bd8ea85673fc0a757a0cd81a509), [`af77cd8`](https://github.com/Lykhoyda/ask-llm/commit/af77cd8b90cb836f87a39893d52e983a36fbea53)]:
56
+ - @ask-llm/mcp@0.8.0
57
+ - @ask-llm/grok-mcp@0.1.2
58
+
59
+ ## 0.14.0
60
+
61
+ ### Minor Changes
62
+
63
+ - [#279](https://github.com/Lykhoyda/ask-llm/pull/279) [`9d27169`](https://github.com/Lykhoyda/ask-llm/commit/9d27169fbe22c2ffbfae0be9d6cba841b98e42f1) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Add first-class Grok consultations through explicit xAI API or official Grok CLI harnesses, with exact model selection, strict no-fallback diagnostics, redacted credentials, cancellation, telemetry, and opt-in live tests. Add a separate model-neutral Cursor Agent harness that requires provider and exact Cursor model attribution, runs read-only, and never changes trust or spend settings. The Cursor provider enum is `claude`, `codex`, `gemini`, `grok` in the unified server and Pi, and the requested model must belong to that family (Auto and noncanonical IDs are refused); `AskResponse` gains an optional `reportedModel` carrying Cursor's display label while `model` echoes the exact requested catalog ID. Prompts above 16 KB reach Grok CLI through a private `--prompt-file` (only when `grok --help` advertises it; otherwise they fail before spawn) and Cursor Agent over stdin. xAI effort coercion (`xhigh` applied as `high` on older models) and served-model alias resolution are disclosed, and an effort-rejecting 4xx is classified with the supported list.
64
+
65
+ ### Patch Changes
66
+
67
+ - [#277](https://github.com/Lykhoyda/ask-llm/pull/277) [`7a20e22`](https://github.com/Lykhoyda/ask-llm/commit/7a20e22c69578f0972da8914964dc089f1da8f8d) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Register the Ask LLM Codex MCP transport with the Claude Code plugin and make `/sol-review` distinguish missing registration from service unavailability before using its explicit CLI fallback.
68
+
69
+ - [#273](https://github.com/Lykhoyda/ask-llm/pull/273) [`e685565`](https://github.com/Lykhoyda/ask-llm/commit/e68556513c59c8a2c56a64c0443c9b36eff0ec64) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Claim Pi codex-pair pending findings with an exclusive lock file instead of a rename, so two sessions on Windows can no longer claim the same finding.
70
+
71
+ - Updated dependencies [[`e685565`](https://github.com/Lykhoyda/ask-llm/commit/e68556513c59c8a2c56a64c0443c9b36eff0ec64), [`9d27169`](https://github.com/Lykhoyda/ask-llm/commit/9d27169fbe22c2ffbfae0be9d6cba841b98e42f1), [`c3f3da4`](https://github.com/Lykhoyda/ask-llm/commit/c3f3da4682d7dd91118b06bd2272b0b3e5ebc1e2)]:
72
+ - @ask-llm/codex-mcp@0.7.5
73
+ - @ask-llm/gemini-mcp@1.7.2
74
+ - @ask-llm/grok-mcp@0.1.1
75
+ - @ask-llm/ollama-mcp@0.5.7
76
+ - @ask-llm/antigravity-mcp@0.7.2
77
+ - @ask-llm/mcp@0.7.0
78
+
79
+ ## 0.13.0
80
+
81
+ ### Minor Changes
82
+
83
+ - [#264](https://github.com/Lykhoyda/ask-llm/pull/264) [`2433d79`](https://github.com/Lykhoyda/ask-llm/commit/2433d79453363ece39fb08da6d585039da224274) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Add first-class Pi host support to the canonical dual-host plugin package, including portable skills, native provider tools, deterministic multi-provider dispatch, consent-gated lifecycle pairing, package/install CI, and abortable provider execution.
84
+
85
+ ### Patch Changes
86
+
87
+ - Updated dependencies [[`2433d79`](https://github.com/Lykhoyda/ask-llm/commit/2433d79453363ece39fb08da6d585039da224274)]:
88
+ - @ask-llm/gemini-mcp@1.7.1
89
+ - @ask-llm/codex-mcp@0.7.4
90
+ - @ask-llm/ollama-mcp@0.5.6
91
+ - @ask-llm/antigravity-mcp@0.7.1
92
+
93
+ ## 0.12.8
94
+
95
+ ### Patch Changes
96
+
97
+ - Updated dependencies [[`634dcf6`](https://github.com/Lykhoyda/ask-llm/commit/634dcf643a60c1c878672d5407936b192558aaa0)]:
98
+ - @ask-llm/antigravity-mcp@0.7.0
99
+
100
+ ## 0.12.7
101
+
102
+ ### Patch Changes
103
+
104
+ - Updated dependencies [[`1d0984b`](https://github.com/Lykhoyda/ask-llm/commit/1d0984bd6996ac1864db9cdb5a46d84e17b750fc)]:
105
+ - @ask-llm/codex-mcp@0.7.3
106
+
107
+ ## 0.12.6
108
+
109
+ ### Patch Changes
110
+
111
+ - Updated dependencies [[`0c35001`](https://github.com/Lykhoyda/ask-llm/commit/0c350017f43e971b9274eb865d5c5c9e33fbcbd7)]:
112
+ - @ask-llm/gemini-mcp@1.7.0
113
+
114
+ ## 0.12.5
115
+
116
+ ### Patch Changes
117
+
118
+ - [#246](https://github.com/Lykhoyda/ask-llm/pull/246) [`a1f62ad`](https://github.com/Lykhoyda/ask-llm/commit/a1f62ad1625c4248876c40842801fe0c4403c561) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Pin the brainstorm-coordinator's raw agy call to the agy 1.1.5 model contract (`--model gemini-3.1-pro --effort high`) ([#243](https://github.com/Lykhoyda/ask-llm/issues/243)).
119
+
120
+ - Updated dependencies [[`a1f62ad`](https://github.com/Lykhoyda/ask-llm/commit/a1f62ad1625c4248876c40842801fe0c4403c561), [`a1f62ad`](https://github.com/Lykhoyda/ask-llm/commit/a1f62ad1625c4248876c40842801fe0c4403c561)]:
121
+ - @ask-llm/antigravity-mcp@0.6.0
122
+ - @ask-llm/gemini-mcp@1.6.17
123
+ - @ask-llm/codex-mcp@0.7.2
124
+ - @ask-llm/ollama-mcp@0.5.5
125
+
126
+ ## 0.12.4
127
+
128
+ ### Patch Changes
129
+
130
+ - [#240](https://github.com/Lykhoyda/ask-llm/pull/240) [`b648785`](https://github.com/Lykhoyda/ask-llm/commit/b648785c9c3243cbe9c1ad33efd590653709d452) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - `/sol-review` no longer depends on agent improvisation when the `ask-codex` MCP tool is unavailable in the subagent context ([#232](https://github.com/Lykhoyda/ask-llm/issues/232)). The skill preflights the transport, the `sol-reviewer` agent sanctions an exact CLI fallback (`codex exec -m gpt-5.6-sol -c model_reasoning_effort="high" -s read-only --ignore-user-config --ignore-rules --skip-git-repo-check`) with plugin-namespaced tool variants recognized as primary transport, transport fallbacks must be disclosed like model fallbacks, and a missing CLI stops the review instead of degrading to another transport, model, or sandbox mode.
131
+
132
+ ## 0.12.3
133
+
134
+ ### Patch Changes
135
+
136
+ - [#237](https://github.com/Lykhoyda/ask-llm/pull/237) [`ba569cc`](https://github.com/Lykhoyda/ask-llm/commit/ba569cc1f8346ef2db76e6733fa9d9f222f61242) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Expose an explicit `sandbox` opt-in on the `ask-codex` tool. Every Codex run now
137
+ defaults to `--sandbox read-only` (ADR-136), which silently broke `/codex-image`
138
+ because Codex could no longer write the generated PNG to disk. `ask-codex` now
139
+ accepts an optional `sandbox` enum (`read-only` | `workspace-write`, default
140
+ `read-only`) that passes through to the executor as a deliberate opt-out of the
141
+ read-only review contract for flows that must have Codex write files. The
142
+ `/codex-image` skill now sets `sandbox: "workspace-write"`; review, second-opinion,
143
+ and analysis flows continue to run read-only.
144
+
145
+ - [#237](https://github.com/Lykhoyda/ask-llm/pull/237) [`ba569cc`](https://github.com/Lykhoyda/ask-llm/commit/ba569cc1f8346ef2db76e6733fa9d9f222f61242) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Keep managed review paths read-only, isolate concurrent compare runs, fix
146
+ special-character Stop-gate paths, and include the MIT license in every
147
+ published package tarball.
148
+ - Updated dependencies [[`ba569cc`](https://github.com/Lykhoyda/ask-llm/commit/ba569cc1f8346ef2db76e6733fa9d9f222f61242), [`ba569cc`](https://github.com/Lykhoyda/ask-llm/commit/ba569cc1f8346ef2db76e6733fa9d9f222f61242)]:
149
+ - @ask-llm/codex-mcp@0.7.1
150
+ - @ask-llm/antigravity-mcp@0.5.1
151
+ - @ask-llm/ollama-mcp@0.5.4
152
+
153
+ ## 0.12.2
154
+
155
+ ### Patch Changes
156
+
157
+ - Updated dependencies [[`a3c3ba3`](https://github.com/Lykhoyda/ask-llm/commit/a3c3ba38fc1643059f4d5a75208b99e580ae9d4b)]:
158
+ - @ask-llm/shared@0.6.0
159
+ - @ask-llm/codex-mcp@0.7.0
160
+ - @ask-llm/antigravity-mcp@0.5.0
161
+ - @ask-llm/gemini-mcp@1.6.16
162
+ - @ask-llm/ollama-mcp@0.5.3
163
+
164
+ ## 0.12.1
165
+
166
+ ### Patch Changes
167
+
168
+ - [#230](https://github.com/Lykhoyda/ask-llm/pull/230) [`394c305`](https://github.com/Lykhoyda/ask-llm/commit/394c305806607ca5db4803c666a0ebdc3304c2db) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Move every public MCP package into the canonical `@ask-llm` npm organization,
169
+ while preserving the existing executable names for compatibility.
170
+ - Updated dependencies [[`394c305`](https://github.com/Lykhoyda/ask-llm/commit/394c305806607ca5db4803c666a0ebdc3304c2db)]:
171
+ - @ask-llm/gemini-mcp@1.6.15
172
+ - @ask-llm/codex-mcp@0.6.2
173
+ - @ask-llm/ollama-mcp@0.5.2
174
+ - @ask-llm/antigravity-mcp@0.4.2
175
+
176
+ ## 0.12.0
177
+
178
+ ### Minor Changes
179
+
180
+ - [#228](https://github.com/Lykhoyda/ask-llm/pull/228) [`b27b69e`](https://github.com/Lykhoyda/ask-llm/commit/b27b69ef6a83d1fe03c51da2b90cc98f0994fbb8) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Add `/fable-review` and `/sol-review`, two read-only review skills that launch
181
+ isolated reviewer agents that request native Fable and explicitly pin OpenAI GPT-5.6 Sol,
182
+ respectively. Both workflows validate findings against the source and report
183
+ only high-confidence issues.
184
+
185
+ ## 0.11.1
186
+
187
+ ### Patch Changes
188
+
189
+ - [#222](https://github.com/Lykhoyda/ask-llm/pull/222) [`ae7780c`](https://github.com/Lykhoyda/ask-llm/commit/ae7780c67327224eea760ade42b61df3d9a32b54) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Update Codex defaults to the GPT-5.6 family: GPT-5.6 Sol is now the
190
+ quality-first model for MCP calls, reviews, brainstorming, image orchestration,
191
+ and codex-pair, with GPT-5.6 Terra as the balanced quota fallback. The legacy
192
+ preferred-model escape hatch remains available, but no longer adds a redundant
193
+ attempt when it resolves to the Sol default. `ask-codex` now accepts an optional
194
+ `reasoningEffort`; general calls preserve `medium`, while `/codex-review` and
195
+ `/brainstorm` use `high`.
196
+ - Updated dependencies [[`ae7780c`](https://github.com/Lykhoyda/ask-llm/commit/ae7780c67327224eea760ade42b61df3d9a32b54), [`ae7780c`](https://github.com/Lykhoyda/ask-llm/commit/ae7780c67327224eea760ade42b61df3d9a32b54)]:
197
+ - ask-gemini-mcp@1.6.14
198
+ - ask-codex-mcp@0.6.1
199
+ - ask-ollama-mcp@0.5.1
200
+ - ask-antigravity-mcp@0.4.1
201
+
202
+ ## 0.11.0
203
+
204
+ ### Minor Changes
205
+
206
+ - [#220](https://github.com/Lykhoyda/ask-llm/pull/220) [`1089a21`](https://github.com/Lykhoyda/ask-llm/commit/1089a215657594a1c569dcd6c180d94750b1dab6) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Codex `/codex-review` and `/brainstorm` now prefer `gpt-5.5-pro` when the Codex
207
+ account is entitled, falling back transparently to `gpt-5.5` (then `gpt-5.4-mini`
208
+ on quota). Those two commands opt in automatically; the raw `ask-codex` tool can
209
+ opt in with the new `preferred` arg. `ASK_CODEX_PREFERRED_MODEL` customizes which
210
+ model the preferred tier uses (default `gpt-5.5-pro`) — it does not by itself
211
+ enable preferred mode. `/multi-review`'s Codex leg inherits the preferred tier
212
+ via the shared `codex-reviewer` agent (its binary-fallback path stays on
213
+ `gpt-5.5`); `codex-pair` and `/codex-verify` are unchanged. (ADR-132)
214
+
215
+ ### Patch Changes
216
+
217
+ - Updated dependencies [[`1089a21`](https://github.com/Lykhoyda/ask-llm/commit/1089a215657594a1c569dcd6c180d94750b1dab6)]:
218
+ - ask-codex-mcp@0.6.0
219
+
220
+ ## 0.10.2
221
+
222
+ ### Patch Changes
223
+
224
+ - [#218](https://github.com/Lykhoyda/ask-llm/pull/218) [`f69ac41`](https://github.com/Lykhoyda/ask-llm/commit/f69ac415db370ced8bc427e6ec0d85d1eed846b5) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - `/compare` now includes **Antigravity** in its default provider set, matching `/brainstorm-all` and `/multi-review`. The skill dispatches to gemini, codex, ollama, and antigravity in parallel (ADR-050 backgrounding + per-PID wait) and renders a fourth `### Antigravity` section side-by-side. Previously `/compare` silently excluded Antigravity even though it is a first-class provider (ADR-125/128). A user can still request a subset (e.g. "compare gemini and codex"). A load-bearing contract test now pins the `antigravity-run.js` dispatch leg so it cannot regress.
225
+
226
+ ## 0.10.1
227
+
228
+ ### Patch Changes
229
+
230
+ - [#213](https://github.com/Lykhoyda/ask-llm/pull/213) [`4002985`](https://github.com/Lykhoyda/ask-llm/commit/400298591b07635624c3ceafa07288692ec0f524) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-pair: the Stop drain, `blockOn: HIGH` gate, and UserPromptSubmit drain now cover every repository edited during the session — not just Claude Code's current working directory. In multi-repo sessions where an edit lands in a different repo than the cwd, that repo's queued verdicts now drain at turn-end and its unaddressed HIGH findings correctly block "done" (issue [#209](https://github.com/Lykhoyda/ask-llm/issues/209), ADR-131). A new session-scoped marker registry under the OS temp dir bridges the watch hook (which knows the edited repo) to the cwd-anchored Stop/prompt hooks. Behavior is unchanged for single-repo sessions and when the hook payload carries no `session_id`.
231
+
232
+ ## 0.10.0
233
+
234
+ ### Minor Changes
235
+
236
+ - [#208](https://github.com/Lykhoyda/ask-llm/pull/208) [`5b0e6a4`](https://github.com/Lykhoyda/ask-llm/commit/5b0e6a4f72070f13e0b6fa16e843cc5f2c1c155d) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-pair seamless pairing (ADR-130): auto-pauses now self-heal — TTL expiry (quota 6h / failures 24h, `CODEX_PAIR_QUOTA_PAUSE_TTL_MS` / `CODEX_PAIR_FAILURES_PAUSE_TTL_MS`), immediate expiry when the plugin version changed since the pause, a SessionStart paused-reminder/auto-resume notice, and `/codex-pair-resume` clearing the failure counter. Every verdict is now emitted on the documented model-visible channel (PostToolUse `hookSpecificOutput.additionalContext`) alongside `systemMessage`. The Stop-gate drains queued debounce verdicts at turn-end for all projects and, with `blockOn: HIGH`, blocks once per turn while reviews are still in flight (settling debounce windows, running codex calls, and the new worker `reviewing` handoff marker).
237
+
238
+ ## 0.9.6
239
+
240
+ ### Patch Changes
241
+
242
+ - [#206](https://github.com/Lykhoyda/ask-llm/pull/206) [`93b024c`](https://github.com/Lykhoyda/ask-llm/commit/93b024c640492d99ef1cc020752d560f957733bb) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-image skill: document gpt-image-2 capabilities (legible in-image text ~99%, up to 4K + custom dimensions, embedded C2PA provenance manifest + invisible AI-origin watermark) so prompt-building accounts for them. Follow-up to the gpt-image-2 model correction; docs/prose only.
243
+
244
+ ## 0.9.5
245
+
246
+ ### Patch Changes
247
+
248
+ - [#204](https://github.com/Lykhoyda/ask-llm/pull/204) [`b284c08`](https://github.com/Lykhoyda/ask-llm/commit/b284c08442265d4e931bd86761b0826210a0df74) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-image skill: correct the image model to `gpt-image-2`. OpenAI shipped gpt-image-2 on 2026-04-21 (replacing gpt-image-1 and the interim 1.5), and Codex's server-side `image_generation` tool now uses it — verified via the C2PA provenance manifest embedded in a live render (`gpt-image` version `2.0`). Updated the SKILL.md description + example footer, and refreshed the stale "2–6 minutes" wall-time to sub-minute for simple images (measured 44–52s; a few minutes for complex/4K thinking-mode renders).
249
+
250
+ ## 0.9.4
251
+
252
+ ### Patch Changes
253
+
254
+ - [#199](https://github.com/Lykhoyda/ask-llm/pull/199) [`553b93b`](https://github.com/Lykhoyda/ask-llm/commit/553b93b9587df53b3b0b583b323955663b27ed64) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - 2026-07-02 audit hardening batch (ADR-128):
255
+
256
+ - **shared**: new canonical `PROVIDERS` tuple + `ProviderName` type (single source of truth for the provider list); new `relativeDirSchema` for includeDirs-style params; `ASK_OLLAMA_TIMEOUT_MS` / `DEFAULT_OLLAMA_TIMEOUT_MS` in `EXECUTION`; chunkCache now creates its dir 0700 and chunk files 0600 (and tightens dirs from older releases); `registerTools()` fails fast on duplicate tool names; stderr accumulation switched to `Buffer[]` (parity with stdout).
257
+ - **ollama**: the `/api/chat` call finally has a timeout — `AbortController` bounded by `ASK_OLLAMA_TIMEOUT_MS` > `GMCPT_TIMEOUT_MS` > 600s default, with an actionable timeout error; previously a wedged Ollama server hung `ask-ollama` forever.
258
+ - **codex**: JSONL output that parses into events but contains no agent message now throws an actionable error (naming the thread id, with truncated raw output) instead of returning the raw JSONL dump as the "response"; plain-text output still passes through. `includeDirs` on `ask-codex`/`ask-codex-edit` now validates paths (relative only, no `..`/`~`) — parity with `ask-gemini-edit`.
259
+ - **gemini**: empty-string `sessionId` now bypasses the response cache (parity with codex/ollama, ADR-063 semantics) — previously a cached body with `sessionId: undefined` was returned instead of performing the session turn; includeDirs cache-key construction no longer mutates the caller's array.
260
+ - **llm-mcp**: `multi-llm` outputSchema and the no-providers-detected fallback enum now include `antigravity` (previously the declared contract rejected antigravity usage stats); REPL `/provider` help derives from the provider registry.
261
+ - **plugin**: plugin.json + marketplace.json description/keywords now name Antigravity; manifest tests assert all four runner binaries.
262
+
263
+ - Updated dependencies [[`5d53a1e`](https://github.com/Lykhoyda/ask-llm/commit/5d53a1e637adcb2e72667e8bc32f5f2c6aa2150c), [`553b93b`](https://github.com/Lykhoyda/ask-llm/commit/553b93b9587df53b3b0b583b323955663b27ed64)]:
264
+ - ask-antigravity-mcp@0.4.0
265
+ - @ask-llm/shared@0.5.0
266
+ - ask-ollama-mcp@0.5.0
267
+ - ask-codex-mcp@0.5.0
268
+ - ask-gemini-mcp@1.6.13
269
+
270
+ ## 0.9.3
271
+
272
+ ### Patch Changes
273
+
274
+ - [#195](https://github.com/Lykhoyda/ask-llm/pull/195) [`f65e72f`](https://github.com/Lykhoyda/ask-llm/commit/f65e72f03b975a93d480091687729350b78788d6) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Fix the Codex quota-fallback model: default to `gpt-5.4-mini` instead of `gpt-5.5-mini`.
275
+
276
+ `gpt-5.5-mini` is rejected with a `400 "not supported when using Codex with a ChatGPT account"` on ChatGPT-plan accounts — the common case for the `codex` CLI, where plan quota is account-wide — so when `gpt-5.5` hit a usage limit the fallback retry failed (`…fallback also failed`) instead of producing a cheaper answer. `gpt-5.4-mini` is confirmed to work on both ChatGPT-plan and API-key accounts and is now the default `ASK_CODEX_FALLBACK_MODEL`. The `gpt-5.5` primary default is unchanged, and API-key users who prefer `gpt-5.5-mini` can still pin it via `ASK_CODEX_FALLBACK_MODEL`. The codex-pair plugin default is updated to match. See ADR-126 (closes [#194](https://github.com/Lykhoyda/ask-llm/issues/194)).
277
+
278
+ - Updated dependencies [[`f65e72f`](https://github.com/Lykhoyda/ask-llm/commit/f65e72f03b975a93d480091687729350b78788d6), [`4938dba`](https://github.com/Lykhoyda/ask-llm/commit/4938dbaeb422e3c5dcfd5ed2780ad030b819a832)]:
279
+ - ask-codex-mcp@0.4.1
280
+
281
+ ## 0.9.2
282
+
283
+ ### Patch Changes
284
+
285
+ - [#192](https://github.com/Lykhoyda/ask-llm/pull/192) [`8ff1d02`](https://github.com/Lykhoyda/ask-llm/commit/8ff1d02b08a8f9f47752d27f1feb64dff9b35d05) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - Default `ask-antigravity` to **Gemini 3.1 Pro (High)** — the strongest reasoning tier — and add a **Gemini 3.5 Flash (High)** rate-limit fallback.
286
+
287
+ Previously `ask-antigravity` defaulted to Gemini 3.5 Flash (High) with no fallback. It now leads with the Pro reasoning tier for the code-review / second-opinion workload and retries once on Flash when Pro hits a subscription rate limit (`RESOURCE_EXHAUSTED` / `429` / quota), mirroring the cross-tier quota fallback that `ask-gemini` and `ask-codex` already use. If the resolved model is already the fallback (or the caller pinned it via `ASK_ANTIGRAVITY_MODEL`), there is nothing to fall back to and the actionable rate-limit message is returned. Non-rate-limit failures (auth, not-installed, timeout) are surfaced as-is and never trigger a fallback. Override the default with the `ASK_ANTIGRAVITY_MODEL` env var (run `agy models` for options).
288
+
289
+ - Updated dependencies [[`8ff1d02`](https://github.com/Lykhoyda/ask-llm/commit/8ff1d02b08a8f9f47752d27f1feb64dff9b35d05)]:
290
+ - ask-antigravity-mcp@0.3.0
291
+
292
+ ## 0.9.1
293
+
294
+ ### Patch Changes
295
+
296
+ - Updated dependencies [[`1feaaa2`](https://github.com/Lykhoyda/ask-llm/commit/1feaaa2ca51e79fb334af780aaf0ecaa83b5bd8f)]:
297
+ - ask-ollama-mcp@0.4.0
298
+
299
+ ## 0.9.0
300
+
301
+ ### Minor Changes
302
+
303
+ - [#187](https://github.com/Lykhoyda/ask-llm/pull/187) [`5757bee`](https://github.com/Lykhoyda/ask-llm/commit/5757bee9029303118cb9e58040617c3390e959b2) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-pair: a primary-model quota error followed by a **structurally-unavailable fallback model** now auto-pauses cleanly (kind `quota`, with the reset hint) instead of cascading to the 3-failure backstop. On ChatGPT-plan Codex accounts the `gpt-5.5-mini` fallback is rejected with a 400 ("not supported when using Codex with a ChatGPT account") — because plan quota is account-wide, a cheaper fallback never applied. The hook now recognizes the broken fallback ladder as the same "no usable model" exhaustion as the no-ladder case and re-throws the primary quota error so its reason + reset hint reach the pause notice. ADR-123.
304
+
305
+ ### Patch Changes
306
+
307
+ - Updated dependencies [[`206943d`](https://github.com/Lykhoyda/ask-llm/commit/206943deb83975e7b06f461771087210617d7287)]:
308
+ - @ask-llm/shared@0.4.0
309
+ - ask-codex-mcp@0.4.0
310
+ - ask-gemini-mcp@1.6.12
311
+ - ask-ollama-mcp@0.3.7
312
+ - ask-antigravity-mcp@0.2.3
313
+
314
+ ## 0.8.0
315
+
316
+ ### Minor Changes
317
+
318
+ - [#181](https://github.com/Lykhoyda/ask-llm/pull/181) [`85d8801`](https://github.com/Lykhoyda/ask-llm/commit/85d88018723fffe530c2e21c601acad62c312ec4) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - codex-pair now pauses itself when the provider is dead instead of erroring on every edit ([#176](https://github.com/Lykhoyda/ask-llm/issues/176)). Quota exhaustion (both models) auto-pauses with a one-time notice including the parsed reset hint; 3 consecutive failures of any kind trigger the same backstop. Failure reasons now surface the real codex error (stdout JSONL error event) instead of the "Reading prompt from stdin..." stderr banner, and ChatGPT-plan quota phrasings ("You've hit your usage limit") are now classified for the existing model fallback. Resume stays manual: /codex-pair-resume.
319
+
320
+ ## 0.7.8
321
+
322
+ ### Patch Changes
323
+
324
+ - Updated dependencies [[`fc40dcb`](https://github.com/Lykhoyda/ask-llm/commit/fc40dcbca3256d1558c2910bb30df64f373876ab)]:
325
+ - ask-gemini-mcp@1.6.11
326
+ - ask-codex-mcp@0.3.11
327
+ - ask-ollama-mcp@0.3.6
328
+ - ask-antigravity-mcp@0.2.2
329
+
330
+ ## 0.7.7
331
+
332
+ ### Patch Changes
333
+
334
+ - Updated dependencies [[`2f12b43`](https://github.com/Lykhoyda/ask-llm/commit/2f12b43c5b8111e3f726ee52fc237ca31df0b4b0)]:
335
+ - @ask-llm/shared@0.3.4
336
+ - ask-codex-mcp@0.3.10
337
+ - ask-antigravity-mcp@0.2.1
338
+ - ask-gemini-mcp@1.6.10
339
+ - ask-ollama-mcp@0.3.5
340
+
341
+ ## 0.7.6
342
+
343
+ ### Patch Changes
344
+
345
+ - Updated dependencies [[`0e14e19`](https://github.com/Lykhoyda/ask-llm/commit/0e14e19fd55dad04c4cc31b55336a970de01ef0b)]:
346
+ - ask-antigravity-mcp@0.2.0
347
+
348
+ ## 0.7.5
349
+
350
+ ### Patch Changes
351
+
352
+ - Updated dependencies [[`fe3ee41`](https://github.com/Lykhoyda/ask-llm/commit/fe3ee41b65908125a88f711b0a2fd560cb286e30)]:
353
+ - ask-gemini-mcp@1.6.9
354
+
355
+ ## 0.7.4
356
+
357
+ ### Patch Changes
358
+
359
+ - Updated dependencies [[`d88606f`](https://github.com/Lykhoyda/ask-llm/commit/d88606f9ec7c1dcc48308d4cadfd8731c9ade8d8)]:
360
+ - ask-gemini-mcp@1.6.8
361
+
362
+ ## 0.7.3
363
+
364
+ ### Patch Changes
365
+
366
+ - [#123](https://github.com/Lykhoyda/ask-llm/pull/123) [`f12e43c`](https://github.com/Lykhoyda/ask-llm/commit/f12e43cd1926c399f6ee1778ea711f9093ed8620) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # Release workflow hardening — failure-tracking issue + Release status badge
367
+
368
+ Two complementary fixes that make release-workflow failures visible
369
+ after the fact, born from the lived-experience finding that PR [#112](https://github.com/Lykhoyda/ask-llm/issues/112)'s
370
+ release run sat with a red X for 5 days without anyone noticing.
371
+
372
+ ## What changes
373
+
374
+ ### `release.yml` — open a tracking issue on failure
375
+
376
+ Adds a final step gated on `if: failure() && steps.changesets.outcome ==
377
+ 'failure'` that uses `actions/github-script@v7` to:
378
+
379
+ - Check for an existing open issue with the `release-broken` label
380
+ - If one exists: post a comment with the new run URL + commit SHA
381
+ (avoids issue-spam on consecutive failures)
382
+ - If none exists: open a new issue titled "Release workflow failed on
383
+ <sha7> — publish blocked" with labels `release-broken` + `urgent`,
384
+ body containing the run URL, commit SHA, likely-cause checklist
385
+ (NODE_AUTH_TOKEN expired/wrong-type, package permission change, npm
386
+ outage), and the fix path
387
+
388
+ Safety note: uses the octokit API exclusively, no shell evaluation of
389
+ untrusted input. All `context.*` values are GitHub-runtime trusted
390
+ (sha, runId, serverUrl, repo).
391
+
392
+ ### `README.md` — Release status badge
393
+
394
+ Adds a Release badge next to the existing CI badge so the workflow
395
+ failure state is visible to anyone visiting the repo:
396
+
397
+ ```markdown
398
+ [![Release](https://img.shields.io/github/actions/workflow/status/Lykhoyda/ask-llm/release.yml?branch=main&label=release&logo=npm)](https://github.com/Lykhoyda/ask-llm/actions/workflows/release.yml)
399
+ ```
400
+
401
+ ## What this does NOT change
402
+
403
+ The publish step itself is unchanged. These fixes don't prevent
404
+ failures — they make failures surface loudly so they get fixed
405
+ promptly. Publish behavior, version-bump logic, MCP Registry sync,
406
+ unified GitHub Release creation — all byte-identical.
407
+
408
+ - Updated dependencies [[`53c0708`](https://github.com/Lykhoyda/ask-llm/commit/53c07080f7e62355d18a4d423bf76a65ab473dc7)]:
409
+ - @ask-llm/shared@0.3.2
410
+ - ask-gemini-mcp@1.6.6
411
+ - ask-codex-mcp@0.3.8
412
+ - ask-ollama-mcp@0.3.3
413
+
414
+ ## 0.7.2
415
+
416
+ ### Patch Changes
417
+
418
+ - [#113](https://github.com/Lykhoyda/ask-llm/pull/113) [`c28c90c`](https://github.com/Lykhoyda/ask-llm/commit/c28c90c0cbfce994c99618244dcab3215e78e297) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # ADR-098 — codex-pair task-agnostic re-positioning + `/codex-pair` user-invocable dashboard
419
+
420
+ Two coupled documentation + UX changes for the codex-pair surface:
421
+
422
+ ## 1. Task-agnostic re-framing across 5 documentation surfaces
423
+
424
+ Every place that described codex-pair's value via the ADR-077 four-task
425
+ benchmark's specific probe domains ("float-money precision, validation
426
+ bypass, edge-case clamping") in sentences like "Use codex-pair when handling
427
+ money / security-sensitive code" caused LLMs reading the ask-llm codebase
428
+ as project context to hallucinate that ask-llm itself has money handling
429
+ and auth paths. ask-llm is a CLI bridge between MCP clients and LLM CLIs
430
+ with none of that code.
431
+
432
+ The rewrite replaces domain-specific framing with code-characteristic
433
+ language ("code with hidden invariants the model can't infer from one
434
+ file", "code where latent bugs cost more than per-edit review", the
435
+ "looks fine, runs wrong" failure-mode class). The recall improvement is
436
+ explicitly attributed as task-agnostic — measured across four
437
+ structurally different fixtures (todo CRUD, URL shortener, RFC-spec
438
+ implementation, stateful business logic), not just one. Each surface
439
+ that lives in the LLM-readable corpus now includes an explicit "ask-llm
440
+ itself is a CLI/MCP bridge with none of these properties; codex-pair
441
+ runs here for dogfooding" disclaimer. Empirical numbers (2/10 → 7/10
442
+ → 10/10) are preserved verbatim — only surrounding framing changes.
443
+
444
+ Surfaces touched: `packages/claude-plugin/skills/codex-pair/SKILL.md`,
445
+ `packages/claude-plugin/README.md`, `apps/docs/plugin/hooks.md`,
446
+ `apps/docs/plugin/skills.md`, `apps/docs/plugin/overview.md`.
447
+
448
+ ## 2. `/codex-pair` user-invocable dashboard
449
+
450
+ `codex-pair/SKILL.md` flips from `user_invocable: false` to `true` with
451
+ a Phase 1–5 orchestration block at the top:
452
+
453
+ - **Phase 1**: Detect state (marker walk, pause sentinel check, recent
454
+ log tail)
455
+ - **Phase 2**: Branch on detected state
456
+ - **Phase 3** (no marker → setup): Auto-detect project context by
457
+ reading `README.md` + `package.json` + alternative manifests; draft a
458
+ `.codex-pair/context.md` with project-purpose summary + 3-5 inferred
459
+ domain invariants; use `AskUserQuestion` with the draft as the
460
+ recommended option's `preview` field so the user sees content before
461
+ deciding; ASK before modifying `.gitignore`
462
+ - **Phase 4** (paused): Structured status table with paused-since
463
+ timestamp + resume instruction
464
+ - **Phase 5** (active): Structured status table with marker
465
+ model + surface threshold + cost-per-review estimate + last 5 reviews
466
+ summary + active ignore/include patterns + pause instruction
467
+
468
+ The existing hook reference documentation (when-to-use, cost
469
+ characteristics, output format, configuration knobs, empirical
470
+ justification) moves below the orchestration block but is unchanged
471
+ in substance — it serves as Claude's reference for explaining hook
472
+ behavior to users mid-orchestration.
473
+
474
+ Zero new code under `scripts/` — the entire orchestration uses Claude's
475
+ existing tool surface (Bash, Read, AskUserQuestion). Plugin test count
476
+ unchanged at 313 (no new code to test; the orchestration is natural-
477
+ language phase instructions, structural pinning would over-couple).
478
+ Lint clean across 6 workspaces.
479
+
480
+ - [#120](https://github.com/Lykhoyda/ask-llm/pull/120) [`daeec3d`](https://github.com/Lykhoyda/ask-llm/commit/daeec3dd989e6bc70616cc37bdb612dd05812823) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # ADR-099 — codex-pair Karpathy baseline principles in review prompt
481
+
482
+ Adds a new `## Baseline review principles` section to the codex-pair
483
+ review prompt template at `packages/claude-plugin/prompts/review.txt`,
484
+ adapting three diff-evaluable rules from the Karpathy CLAUDE.md
485
+ (https://github.com/multica-ai/andrej-karpathy-skills/blob/main/CLAUDE.md):
486
+
487
+ 1. **Simplicity** — flag features beyond what was asked, single-use
488
+ abstractions, unrequested configurability, impossible-scenario error
489
+ handling, 200-line code that could be 50.
490
+
491
+ 2. **Surgical scope** — flag drive-by refactors of unrelated adjacent
492
+ code, style refactors mixed with substantive logic edits, orphan
493
+ imports/variables/functions, style drift from the file's existing
494
+ conventions.
495
+
496
+ 3. **Hidden assumptions** — flag behavior depending on unstated
497
+ invariants the next reader can't see, simpler alternatives the diff
498
+ didn't consider when obvious, multiple valid interpretations of the
499
+ task with one silently picked.
500
+
501
+ The fourth Karpathy rule (Goal-Driven Execution) was intentionally
502
+ excluded — it's a metaprocess rule about how to approach a task with
503
+ no concrete evaluation target on a code diff. Tracked as a candidate
504
+ for separate CLAUDE.md inclusion in a follow-on.
505
+
506
+ ## Why universal (Option A) over project-scoped opt-in
507
+
508
+ The baseline is intentionally on for every opted-in project: same
509
+ review criteria everywhere, regardless of whether the project supplied
510
+ a marker. Project-specific invariants in `.codex-pair/context.md`
511
+ take precedence per the section's framing ("Treat violations as MED or
512
+ HIGH findings unless a project-context rule below explicitly overrides
513
+ them"), so projects retain the ability to override baseline behavior
514
+ without removing it.
515
+
516
+ ## Cost + cache impact
517
+
518
+ - ~360 tokens per review of prompt overhead (~$0.0015 at current
519
+ codex pricing — negligible vs the $0.04–0.07 per-review codex spend)
520
+ - Cache invalidation is one-time per project on the first edit after
521
+ upgrade because the prompt content change → cache key change. Each
522
+ opted-in project pays one extra codex spawn per file on the first
523
+ post-upgrade edit, then back to normal cache-hit rates.
524
+
525
+ ## What's unchanged
526
+
527
+ The hook source (`codex-pair-watch.mjs`) is byte-identical. This is a
528
+ prompt-only change. ADR-077 silent-on-error, ADR-082 cache key shape,
529
+ ADR-087 inflight lock, ADR-089 golden-fixture contract — all unchanged
530
+ in mechanism (the golden fixture content is updated to match the new
531
+ template, preserving the byte-identical pin).
532
+
533
+ Plugin test count unchanged at 313; lint clean across 6 workspaces.
534
+
535
+ ## Reversibility
536
+
537
+ Two file edits + one test-assertion update if empirical follow-on
538
+ shows the baseline doesn't earn its keep. ADR-099 documents the
539
+ reversal cost up front.
540
+
541
+ - [#121](https://github.com/Lykhoyda/ask-llm/pull/121) [`5bb4dff`](https://github.com/Lykhoyda/ask-llm/commit/5bb4dff1793939c26303239c93b8f0b271cdeef3) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # ADR-100 — codex-pair prompt A/B benchmark harness
542
+
543
+ Scaffolds an empirical validation harness for prompt-template changes
544
+ at `packages/claude-plugin/scripts/benchmark/`. Built initially to
545
+ validate ADR-099 (Karpathy baseline principles), but reusable for any
546
+ future prompt change.
547
+
548
+ ## What's in the harness
549
+
550
+ ```
551
+ packages/claude-plugin/scripts/benchmark/
552
+ ├── README.md # usage + decision rule
553
+ ├── prompt-ab.mjs # driver
554
+ ├── lib/
555
+ │ ├── render-prompt.mjs # mirrors lib/prompt.mjs substitution
556
+ │ ├── invoke-codex.mjs # spawns codex exec --json, parses JSONL
557
+ │ ├── score.mjs # keyword-based probe matching
558
+ │ └── report.mjs # markdown report generator
559
+ ├── fixtures/
560
+ │ ├── README.md
561
+ │ ├── 01-overcomplication/ # Simplicity rule
562
+ │ ├── 02-drive-by-refactor/ # Surgical scope rule
563
+ │ ├── 03-orphan-imports/ # Surgical scope rule
564
+ │ └── 04-hidden-assumption/ # Hidden assumptions rule
565
+ └── templates/
566
+ ├── pre-baseline.txt # main's prompt as of ADR-098
567
+ └── baseline.txt # ADR-099's prompt with Karpathy block
568
+ ```
569
+
570
+ ## Methodology
571
+
572
+ 1. Each fixture has three files: `code.ts` (sent to codex), `context.md`
573
+ (marker context), `probes.json` (ground-truth `should_flag` entries).
574
+ 2. The driver renders each fixture against both templates, invokes real
575
+ `codex exec --json`, scores findings against probes via keyword
576
+ match (≥2 keyword hits per probe), emits a markdown comparison.
577
+ 3. Decision rule for ADR-099 validation: ship if recall delta ≥ +10 pp
578
+ AND extra-finding delta ≤ +1/fixture; otherwise execute ADR-099's
579
+ documented two-file rollback.
580
+
581
+ ## Cost
582
+
583
+ ~$0.40 per full benchmark run (4 fixtures × 2 arms × ~$0.05/review).
584
+
585
+ ## What this is NOT
586
+
587
+ - NOT a runtime change — the harness is standalone tooling under
588
+ `scripts/benchmark/` with no imports from the runtime layer
589
+ - NOT auto-run on PRs — manual invocation only until variance data
590
+ justifies a CI gate
591
+ - NOT tested by vitest — one-off maintainer scripts, exercised
592
+ manually when run; lint covers syntax via Biome
593
+
594
+ Plugin test count unchanged at 313; lint clean across 6 workspaces.
595
+
596
+ ## Forward use
597
+
598
+ Future prompt changes (severity-vs-urgency, structured-output tweaks,
599
+ baseline rule extensions) can vendor a new template snapshot into
600
+ `templates/` and re-run against the same fixtures + decision rule.
601
+ The harness itself is the durable artifact; ADR-099 is the first
602
+ use-case.
603
+
604
+ Run with:
605
+
606
+ ```bash
607
+ node packages/claude-plugin/scripts/benchmark/prompt-ab.mjs \
608
+ --out benchmark-report.md
609
+ ```
610
+
611
+ - [#122](https://github.com/Lykhoyda/ask-llm/pull/122) [`971ddf7`](https://github.com/Lykhoyda/ask-llm/commit/971ddf7d1e96bbab7d98eebae7d9ef065598e6e0) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # Benchmark harness fixes — SIGKILL timeout respect + graceful error-state report rendering
612
+
613
+ Two defects in the ADR-100 prompt A/B benchmark harness (`packages/claude-plugin/scripts/benchmark/`) discovered during the first real run validating ADR-099. Both fixes are isolated to maintainer tooling — no runtime impact, no test-suite changes needed.
614
+
615
+ ## Fix 1: `lib/invoke-codex.mjs` — SIGKILL respect + settled guard
616
+
617
+ **Defect**: codex ignored `SIGTERM` when mid-turn. The first benchmark run recorded fixture durations of **712s / 985s / 908s** past a 240-second `SIGTERM` — codex held the script open until its own internal lifecycle decided to exit. The promise-rejection from the timer fired, but the child process kept the Node script alive via its still-open stdio pipes.
618
+
619
+ **Fix**:
620
+
621
+ - Switch from `SIGTERM` to `SIGKILL` — codex respects the latter immediately
622
+ - Explicit `child.stdout.destroy()` + `child.stderr.destroy()` + `child.stdin.destroy()` to release stdio backpressure when killing
623
+ - `settled` guard variable prevents the `close` handler from double-settling the promise if it fires after the timer
624
+ - `child.on("error", ...)` handler added so spawn-failure (ENOENT, EACCES) routes through the same settle path instead of crashing the driver
625
+ - Default `timeoutMs` bumped 120s → 300s; codex with reasoning tokens occasionally needs >2 min for complex fixtures
626
+ - Timeout error message now includes captured stdout/stderr byte counts for diagnostic visibility
627
+
628
+ ## Fix 2: `lib/report.mjs` — error-state rendering without crashing
629
+
630
+ **Defect**: when ANY fixture errored on EITHER arm, `report.mjs` crashed with `Cannot read properties of undefined (reading 'recall')` because per-fixture iteration accessed `run.score.recall` without checking whether `run` had an `error` instead.
631
+
632
+ **Fix**:
633
+
634
+ - Per-fixture loop now branches on `run.error` and renders a `FAILED — <message>` section with the duration, instead of trying to render score data that doesn't exist
635
+ - Aggregate section now detects "at least one arm errored on every fixture" and surfaces that explicitly instead of computing a nonsensical recall delta on empty data
636
+
637
+ ## Why these matter
638
+
639
+ The harness will be re-run for every future prompt change (severity-vs-urgency refactor, structured-output tweaks, additional baseline rules). Without these fixes, a single codex non-determinism event would cost 12+ minutes of wall-clock per hung fixture, and the report would crash trying to render the result. The fixes turn the harness from "works when codex is cooperative" into "works regardless of codex's mood."
640
+
641
+ ## What's unchanged
642
+
643
+ Hook source, broker, cache, lock, parser, prompt rendering — none of these touch runtime code. Pure maintainer-tooling fix.
644
+
645
+ Plugin test count unchanged at 313; lint clean across 6 workspaces.
646
+
647
+ - [#119](https://github.com/Lykhoyda/ask-llm/pull/119) [`0f67df2`](https://github.com/Lykhoyda/ask-llm/commit/0f67df285fa8b892dc31c5b8e3bc68388431d36a) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # Parallel-fire test fixtures — closes the MultiEdit + concurrent-hook test gap
648
+
649
+ Adds 6 new tests + a `slow` scenario to the fake-codex fixture, closing
650
+ the empirical gap surfaced by the deep-investigation tracing: the 313
651
+ pre-existing plugin tests used `tool_name: "Edit"` exclusively, with
652
+ zero MultiEdit payloads and zero concurrent-hook scenarios. The actual
653
+ codex-pair workload — agentic Claude making multiple Edit/Write/Multi-
654
+ Edit tool calls per turn — wasn't exercised by any test.
655
+
656
+ ## New tests (`packages/claude-plugin/src/__tests__/codex-pair-watch.test.ts`)
657
+
658
+ 1. **MultiEdit payload acceptance** — pins that `{tool_name: "MultiEdit",
659
+ tool_input: {file_path, edits: [...]}}` reaches the codex-spawn path
660
+ and logs a review entry with `tool: "MultiEdit"`. Guards against
661
+ silent payload-shape drift if Claude Code's MultiEdit schema ever
662
+ changes.
663
+
664
+ 2. **Cache participation (MultiEdit→MultiEdit)** — pins that the cache
665
+ key is content-derived (not tool-name-derived) so identical-content
666
+ MultiEdit re-fires hit the cache. Closes a regression class: a
667
+ tool_name-specific cache bypass.
668
+
669
+ 3. **Cross-file parallel fires (3 concurrent processes)** — fires 3
670
+ hooks concurrently via `Promise.all` on 3 different files. Verifies:
671
+
672
+ - All 3 exit 0
673
+ - 3 distinct review log entries with distinct file paths
674
+ - 3 separate cache entries across cache buckets
675
+ - 3 separate per-file repetition shards under `state/repetitions/`
676
+ - No cross-file contention (ADR-097 sharded layout invariant)
677
+
678
+ 4. **Same-file in-flight coalescing (ADR-087)** — fires hook A with the
679
+ `slow` codex scenario, waits 250ms (past lock acquisition), fires
680
+ hook B on the same file. Verifies hook B logs `verdict: "skipped"`
681
+ with `coalesced` in the reason, emits no systemMessage, and that
682
+ only ONE review verdict (from hook A) lands in the log.
683
+
684
+ 5. **MultiEdit + ignore gate** — verifies an ignored file matched by
685
+ `.codex-pair/ignore` is skipped pre-codex even when the tool is
686
+ MultiEdit. Guards against a tool_name-specific gate bypass.
687
+
688
+ 6. **Slow-scenario fixture self-test** — sanity-pins that the new
689
+ `slow` scenario actually sleeps for `FAKE_CODEX_SLEEP_MS` before
690
+ emitting NONE. If someone breaks the fixture, this gives a direct
691
+ failure pointing at the cause rather than confusing race-flakes
692
+ in the dependent coalescing test.
693
+
694
+ ## New fake-codex `slow` scenario (`_fixtures/codex`)
695
+
696
+ Adds a configurable-latency scenario: sleeps `FAKE_CODEX_SLEEP_MS`
697
+ (default 500ms) then emits a NONE verdict. Enables deterministic
698
+ race-window control for the in-flight coalescing test without the
699
+ 30-second `timeout` scenario's wall-clock penalty.
700
+
701
+ ## Test count and wall-clock impact
702
+
703
+ - Test count: 313 → 319 (+6).
704
+ - Wall-clock: 4.2s → 7.1s (+2.9s), dominated by the 1.5s slow-scenario
705
+ hold-time in the coalescing test plus ~500ms for 3 concurrent
706
+ codex spawns in the cross-file test. Acceptable.
707
+ - Lint clean across 6 workspaces.
708
+
709
+ No production code changes. The fixture file (`_fixtures/codex`) is
710
+ test-only and not shipped to npm consumers.
711
+
712
+ ## 0.7.1
713
+
714
+ ### Patch Changes
715
+
716
+ - [#111](https://github.com/Lykhoyda/ask-llm/pull/111) [`ab40290`](https://github.com/Lykhoyda/ask-llm/commit/ab40290fecdbabec75436579d06152f6218251d6) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # ADR-097 — codex-pair UX hotfix on ADR-096
717
+
718
+ Closes the four `/multi-review` findings explicitly tracked as "follow-on hotfix
719
+ before wide adoption" in the v0.7.0 changeset. Both Gemini and Codex
720
+ independently flagged each at 80+ confidence; all four reproduced empirically
721
+ before fixing per the ADR-095 verify-before-fixing discipline.
722
+
723
+ 1. **TOCTOU race on singleton `repetitions.json`** (Gemini 95, Codex 88) →
724
+ state moves from `<markerDir>/.codex-pair/state/repetitions.json` to
725
+ `<markerDir>/.codex-pair/state/repetitions/<sha256(file)[0:16]>.json`. Each
726
+ shard's read-modify-write is now naturally serialized by ADR-087's per-file
727
+ inflight lock. Schema bumped to `v: 2`.
728
+
729
+ 2. **Unbounded state growth** (Codex 85) → `sweepStaleRepetitions` drops
730
+ shards older than 30 days, called probabilistically (5% per update) so
731
+ abandoned files don't accumulate state.
732
+
733
+ 3. **Cache-hit double-count under rapid re-saves** (Gemini 87) → new
734
+ read-only `getBlockingFromShard` surfaces blocking entries without
735
+ mutating state. Cache-hit branch in `codex-pair-watch.mjs` uses this
736
+ instead of `updateRepetitions`. Rapid undo/redo cycles can no longer
737
+ push a finding to BLOCKING without a real new live review.
738
+
739
+ 4. **Include-list negation-only edge case** (Codex 82) → `.codex-pair/include`
740
+ with ONLY negation rules (e.g. just `!build/**`) previously gated every
741
+ file out (no positive rule = no match for anything). Now the negations
742
+ transform into positive ignore-list entries with an info-level log line
743
+ explaining the semantic mapping.
744
+
745
+ Backward-compat shims keep the v1 `loadRepetitions`/`saveRepetitions` exports
746
+ as no-ops so external scripts that imported the v1 surface don't break at
747
+ import time. No data migration needed — repetition state is advisory and
748
+ regenerates from continued reviews; any lingering v1 `repetitions.json` file
749
+ on disk is harmless (different path, ignored by new code, won't be swept by
750
+ the new TTL).
751
+
752
+ Test count 308 → 313 (+5 ADR-097 regressions). Lint clean across 6 workspaces.
753
+
754
+ - Updated dependencies [[`ab40290`](https://github.com/Lykhoyda/ask-llm/commit/ab40290fecdbabec75436579d06152f6218251d6)]:
755
+ - ask-gemini-mcp@1.6.5
756
+ - ask-codex-mcp@0.3.7
757
+ - ask-ollama-mcp@0.3.2
758
+
759
+ ## 0.7.0
760
+
761
+ ### Minor Changes
762
+
763
+ - [#108](https://github.com/Lykhoyda/ask-llm/pull/108) [`190e5c9`](https://github.com/Lykhoyda/ask-llm/commit/190e5c9ee95b8241b0c788e3df2ea4fd3721b074) Thanks [@Lykhoyda](https://github.com/Lykhoyda)! - # v0.7.0 — Tier 3 broker, layout consolidation, codex-pair UX improvements
764
+
765
+ Major release across the codex-pair feature: shipped the full Tier 3
766
+ `codex app-server` broker (eliminates ~3-10s cold-spawn per edit when
767
+ opted in via `ASK_CODEX_BROKER=1`), consolidated all hook state under
768
+ a single `.codex-pair/` directory, removed the deprecated PreToolUse
769
+ Gemini pre-commit hook, and added three codex-pair UX improvements
770
+ born from end-of-Tier-3 lived-experience review.
771
+
772
+ ## Highlights
773
+
774
+ ### Tier 3 broker — `codex app-server` integration (ADR-093)
775
+
776
+ A long-lived `codex app-server` JSON-RPC sidecar replaces the per-edit
777
+ cold-spawn cost (15-30s) with a warm-connection path (~5-15s, savings
778
+ of 3-10s per fire). Spawned once per Claude Code session, torn down at
779
+ SessionEnd, with stale-broker recovery for crashed-session orphans.
780
+
781
+ Implementation across four milestones:
782
+
783
+ - **M1**: Protocol discovery via `codex app-server generate-json-schema`.
784
+ Refined `lib/broker.mjs` interface; pinned `BROKER_PROTOCOL_VERSION =
785
+ "v2"`, `JSONRPC_METHODS`, `JSONRPC_NOTIFICATIONS`, `buildVerdictSchema()`.
786
+
787
+ - **M2**: Hand-rolled minimal RFC 6455 WebSocket client (`broker-transport.
788
+ mjs`, ~280 LOC) supporting both `unix://` and `ws://`; JSON-RPC 2.0
789
+ layer with tolerant parsing (`broker-rpc.mjs`); SessionStart spawn +
790
+ handshake + atomic descriptor write; SessionEnd SIGTERM grace +
791
+ cleanup; `clearStaleBrokerState` for orphan recovery (`broker-
792
+ lifecycle.mjs`).
793
+
794
+ - **M3**: Real `submitReview` body — `thread/start { ephemeral: true,
795
+ approvalPolicy: "never", sandbox: "read-only" }` → `turn/start` with
796
+ `outputSchema` constraint matching `parser.mjs::parseConcernsJson` →
797
+ listen for `turn/completed` → extract final agentMessage → return.
798
+ `rpc.waitFor(method, predicate, timeoutMs)` race-safe notification
799
+ primitive. Error mapping via `err.verdict` (matches existing
800
+ `verdictFromError` contract) with structured `err.timeout`,
801
+ `err.aborted` markers.
802
+
803
+ - **M4**: Hook integration. `isBrokerEnabled(markerDir)` checks env +
804
+ descriptor + protocol version + pid liveness. `runCodexWithFallback`
805
+ dispatches to the broker via `runWithBroker` when enabled; on
806
+ `err.brokerFailure` (transport / handshake / parse failures) silently
807
+ falls back to per-edit `spawnCodex` per the ADR-077 silent-on-error
808
+ contract. Cache integration unchanged — broker and spawn modes share
809
+ the same cache entries (cross-mode reuse is a feature).
810
+
811
+ Opt-in via `ASK_CODEX_BROKER=1`. Default-off behavior byte-identical
812
+ to v0.6.x.
813
+
814
+ ### `.codex-pair/` layout consolidation (ADR-092)
815
+
816
+ All hook state nested under a single project-local directory:
817
+
818
+ | Before (flat) | After (nested) |
819
+ | ----------------------------- | ----------------------------- |
820
+ | `.codex-pair-context.md` | `.codex-pair/context.md` |
821
+ | `.codex-pair-log.jsonl` | `.codex-pair/log.jsonl` |
822
+ | `.codex-pair-ignore` | `.codex-pair/ignore` |
823
+ | `.codex-pair-cache/` | `.codex-pair/cache/` |
824
+ | `.codex-pair-state/paused` | `.codex-pair/state/paused` |
825
+ | `.codex-pair-state/inflight/` | `.codex-pair/state/inflight/` |
826
+
827
+ `.gitignore` collapses from 4 enumerated codex-pair entries to one
828
+ `.codex-pair/` line — future state files inherit the ignore
829
+ automatically. Path-resolver pattern in `lib/state.mjs` is the single
830
+ source of truth.
831
+
832
+ **Migration for existing users**: manual `mv` of legacy flat paths into
833
+ `.codex-pair/`. No migration helper ships; behavior is byte-identical
834
+ to v0.6.x once paths are moved. Cache JSON shape, log JSONL shape,
835
+ broker interface, atomicity contracts all unchanged.
836
+
837
+ ### Codex-pair UX improvements (ADR-096)
838
+
839
+ Three improvements identified from end-of-Tier-3 lived-experience
840
+ review (ADR-095), targeting the 81% finding-ignored rate observed in
841
+ real M2 development:
842
+
843
+ 1. **Inclusion-list scoping** (`.codex-pair/include`). Gitignore-style
844
+ globs, mirror of `.codex-pair/ignore`. When present + non-empty,
845
+ ONLY files matching at least one rule are reviewed. Lets users
846
+ restrict codex-pair to high-stakes paths (`src/billing/**`,
847
+ `src/auth/**`) and avoid paying ~$0.05/edit on routine refactor
848
+ code. Include gate runs BEFORE ignore (include narrows; ignore
849
+ excludes from narrowed set).
850
+
851
+ 2. **Repetition detector** (`.codex-pair/state/repetitions.json`).
852
+ Tracks per-(file, concernHash) consecutive flag counts. Concerns
853
+ absent from a re-review are dropped (assumed fixed); concerns
854
+ present again increment. When count crosses `REPETITION_BLOCKING_
855
+ THRESHOLD` (3), the finding is escalated.
856
+
857
+ 3. **Loud-formatting** for repeated-ignored findings. When the
858
+ threshold is crossed, `buildVerdictMessage` prefixes the
859
+ systemMessage with a multi-line 🛑 banner so the consumer
860
+ (Claude or human) cannot silently scroll past. Poor-man's STOPPER
861
+ mode within PostToolUse hook constraints (Claude Code's hook
862
+ protocol doesn't currently support blocking the next tool call).
863
+
864
+ ### PreToolUse pre-commit Gemini hook removed (ADR-094)
865
+
866
+ The advisory-only PreToolUse hook that ran Gemini against staged
867
+ diffs has been removed:
868
+
869
+ - Codex-pair delivers strictly better recall continuously during
870
+ editing (HIGH/MED concerns surface to Claude on next turn; LOW
871
+ concerns log).
872
+ - `/gemini-review` covers the on-demand explicit-review need with
873
+ the same Gemini-CLI dependency.
874
+ - Removing eliminates per-Bash dispatch latency and simplifies the
875
+ "what hooks does this plugin install?" model.
876
+
877
+ **For users who relied on the advisory output**: switch to
878
+ `git diff --cached | ask-gemini-run "review these staged changes"`
879
+ or `/gemini-review` before committing. Both are documented in the
880
+ README.
881
+
882
+ ### Internal: codex-pair debt paydown + reviewer-agent calibration (ADR-095)
883
+
884
+ End-of-Tier-2 forensic audit of `.codex-pair/log.jsonl` revealed
885
+ codex-pair flagged 32 unique bugs during development; 21 were
886
+ ignored in flight (2 of them BLOCKING — un-sent WebSocket upgrade
887
+
888
+ - ESM `require()` — that `/multi-review` independently re-caught
889
+ 5+ hours later).
890
+
891
+ * 6 verified-real bug fixes after empirical reproduction tracing
892
+ * 1 documented false-positive (`child.unref()` is by design per ADR-090)
893
+ * 3 deferred-known-limitations tracked in ROADMAP
894
+ * `agents/codex-reviewer.md` calibration: severity-first reporting,
895
+ mandatory reproduction paths, ADR-aware false-positive filtering,
896
+ anti-noise heuristics
897
+
898
+ ## What's not in this release (known follow-ons)
899
+
900
+ - Full severity-vs-urgency refactor (breaking prompt + parser change).
901
+ - True platform-level STOPPER signal (requires upstream Claude Code
902
+ support for `decision: "block"` on PostToolUse).
903
+ - Per-finding "acknowledged" persistence.
904
+ - Multi-review ADR-096 findings (TOCTOU race on repetitions.json
905
+ cross-file updates; unbounded state growth without TTL; include-list
906
+ negation-only edge case; cache-hit double-count under rapid re-saves)
907
+ — tracked for a follow-on hotfix before wide adoption.
908
+
909
+ ## Test count trajectory
910
+
911
+ 230 → 245 (M2 PR1) → 254 (M2 PR2) → 264 (M2 PR3) → 271 (M2 hotfix [#103](https://github.com/Lykhoyda/ask-llm/issues/103))
912
+ → 278 (ADR-095 debt) → 284 (M3) → 289 (M3 hotfix) → 300 (M4) → 308
913
+ (ADR-096). All tests pass; lint clean across 6 workspaces.
914
+
915
+ ## 0.6.2
916
+
917
+ ### Patch Changes
918
+
919
+ - Fix two ≥80-confidence findings from the multi-review on PR [#76](https://github.com/Lykhoyda/ask-llm/issues/76):
920
+
921
+ **1. Catch handler now uses hoisted `markerAnchor` instead of `process.cwd()`** (both Gemini and Codex flagged). The unhandled-exception path in `main().catch(...)` previously walked up from `process.cwd()` to find the marker, which undermined the v0.6.1 cross-repo fix for any error that happened AFTER payload parsing. Now: `markerAnchor` is hoisted to module scope; `main()` sets it to `dirname(filePath)` once payload is validated; the catch handler reads `markerAnchor ?? process.cwd()` — using cwd only as a true last resort when `main()` threw before payload parsing.
922
+
923
+ **2. Documented Windows compatibility caveat** for the `$PWD` workaround in `apps/docs/plugin/hooks.md`. The `sh -c '...'` form requires a POSIX shell, which Windows users on cmd.exe/PowerShell don't have natively. Added a one-line note pointing Windows users at Git for Windows (which provides `sh` via MINGW64) or recommending an absolute Windows path instead.
924
+
925
+ Both fixes are tiny (~5 LOC each), no architectural changes. New structural test pins the catch-handler hoist invariant so a future refactor can't silently regress.
926
+
927
+ ## 0.6.1
928
+
929
+ ### Patch Changes
930
+
931
+ - Fix: codex-pair marker resolution now anchors to the edited file's directory, not `process.cwd()` (issue [#65](https://github.com/Lykhoyda/ask-llm/issues/65)). In multi-repo workflows where Claude Code's cwd is one repo but the edit happens in another, the previous behavior wrote logs to the cwd's repo instead of the edited file's repo, producing "where did my log go?" confusion. The fix uses `dirname(tool_input.file_path)` — always absolute per Claude Code's hook payload contract — as the marker walk's anchor. The `main().catch` unhandled-exception fallback retains its cwd-based lookup since `filePath` isn't in scope there; the structural test was tightened to allow this distinction.
932
+
933
+ Side effect: shipping this as v0.6.1 also triggers Claude Code's plugin cache refresh for pre-existing sessions still pinned to the stale v0.6.0 install (issue [#74](https://github.com/Lykhoyda/ask-llm/issues/74)) — the next `/reload-plugins` or session restart will see "new version available" and re-fetch from origin.
934
+
935
+ ## 0.6.0
936
+
937
+ ### Minor Changes
938
+
939
+ - Prep v0.6.0 — codex-pair hook improvements release. Umbrella version covering a coordinated batch of hardening, observability, speed, and DX improvements to the codex-pair PostToolUse hook. Planned scope across three phases:
940
+
941
+ **Phase 1 — Hardening + observability (bundled PR):**
942
+
943
+ - Log rotation: cap `.codex-pair-log.jsonl` at ~2MB / 1000 entries via atomic rewrite (env override `CODEX_PAIR_MAX_LOG_BYTES`).
944
+ - Structured run-state verdicts: explicit `none | concerns | skipped | error | spawn_failed | timeout | parse_failed | cached`, mirrored into the `systemMessage` prefix.
945
+ - Expanded skip patterns: add font files, archives, language-specific lockfiles, minified assets.
946
+ - Default-model drift guard: read model defaults from a shipped `codex-pair-defaults.json` instead of hardcoded literals; structural test links the file to `codex-mcp/constants.ts`.
947
+
948
+ **Phase 2 — Foundation + adaptive context (sequential PRs):**
949
+
950
+ - Local config in marker frontmatter: YAML frontmatter in `.codex-pair-context.md` for `model`, `fallbackModel`, `timeoutMs`, `maxFileBytes`, `surfaceThreshold`. Hand-rolled zero-dependency parser.
951
+ - Adaptive context strategy at the file-size boundary: under-cap → full file (unchanged); over-cap + tracked → imports header + `git diff -U20 HEAD` + partial-view instruction; over-cap + untracked → head+tail slice with same instruction. Replaces today's silent skip.
952
+ - `.codex-pair-ignore`: gitignore-style globs for granular per-file/per-directory opt-out, no `systemMessage` on match (preserves silent-gating UX).
953
+
954
+ **Phase 3 — Speed + recovery (parallelizable PRs):**
955
+
956
+ - Content-hash response cache: `sha256(model + prompt + fileContent + surfaceThreshold)` keyed cache under `<markerDir>/.codex-pair-cache/`, 10-minute TTL, 50-file LRU eviction.
957
+ - Log viewer CLI: standalone `scripts/codex-pair-log.mjs` with `--latest`, `--summary`, `--file`, `--since` subcommands. Zero workspace imports.
958
+ - Failure-class retry with jitter: retry-once on transient network/5xx errors (`ECONNRESET`, `ETIMEDOUT`, `502`/`503`/`504`, etc.). Quota and timeout failures keep their existing terminal paths.
959
+
960
+ Constraints preserved through all items: zero workspace imports (marketplace install compatibility), always exit 0 (never break Claude's tool flow), LOW concerns stay in log only by default (ADR-077 threshold-in-hook), synchronous-blocking hook semantics (agent-accountability argument). Reasoning-effort tuning and async/fire-and-forget patterns are explicitly out of scope for this batch.
961
+
962
+ ## 0.5.0
963
+
964
+ ### Minor Changes
965
+
966
+ - codex-pair hook now emits a `systemMessage` notice to Claude Code on every run — `OK` when no concerns are found, `WARN` with HIGH/MED bodies when concerns surface, and `SKIP`/`ERROR` when the hook attempts work but can't complete (unreadable file, oversize file, codex timeout). Previously the hook was silent on the happy path, so review activity was only visible in `.codex-pair-log.jsonl`. The threshold-in-hook design from ADR-077 is preserved: LOW concern bodies still go to the log only, with a count surfaced in the verdict header.