gentle-pi 5.0.0 → 5.1.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 (234) hide show
  1. package/README.md +1 -1
  2. package/assets/agents/gentle-ai-explore.md +3 -6
  3. package/assets/agents/gentle-ai-verify.md +1 -1
  4. package/assets/agents/gentle-ai-worker.md +9 -9
  5. package/assets/agents/jd-fix-agent.md +1 -1
  6. package/assets/agents/jd-judge-a.md +0 -1
  7. package/assets/agents/jd-judge-b.md +0 -1
  8. package/assets/migrations/agent-body-history.json +6 -0
  9. package/assets/orchestrator-full-delegation.md +1 -1
  10. package/assets/orchestrator-maintenance.md +11 -0
  11. package/assets/orchestrator-quota-recovery.md +1 -1
  12. package/assets/orchestrator-skills.md +10 -0
  13. package/assets/orchestrator-verification.md +9 -7
  14. package/assets/orchestrator.md +1 -1
  15. package/bin/gentle-shell.mjs +67 -15
  16. package/contracts/review-provider-contract-mirror/provider-contract.lock.json +10 -10
  17. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/manifest.json +5 -5
  18. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/orchestration/pi.md +5 -3
  19. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/routing/pi.md +1 -1
  20. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/schemas/lens.schema.json +3 -3
  21. package/contracts/review-provider-contract-mirror/v1.7.0/bundle/vectors/lens.json +1 -0
  22. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/generated/provider-capabilities.baseline.json +3 -3
  23. package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/generated/provider-roles.baseline.json +3 -3
  24. package/docs/bundled-install.md +2 -2
  25. package/docs/delegated-verification.md +8 -4
  26. package/docs/desktop-feed.md +15 -6
  27. package/docs/desktop-rpc.md +44 -20
  28. package/docs/gentle-shell-desktop.md +10 -3
  29. package/docs/gentle-shell.md +17 -13
  30. package/docs/install-wizard.md +2 -2
  31. package/docs/odd-preparation-continuity.md +2 -2
  32. package/docs/permission-modes.md +10 -2
  33. package/docs/readme-reference.md +46 -11
  34. package/docs/session-profile-format.md +33 -7
  35. package/docs/work-continuity.md +7 -7
  36. package/docs/yolo-mode.md +1 -1
  37. package/extensions/child-context.ts +2 -11
  38. package/extensions/gentle-agents.ts +47 -28
  39. package/extensions/gentle-ai.ts +573 -353
  40. package/extensions/gentle-desktop-feed.ts +13 -3
  41. package/extensions/gentle-fast.ts +9 -2
  42. package/extensions/gentle-shell.ts +142 -55
  43. package/extensions/gentle-tps.ts +5 -0
  44. package/extensions/quiet-tools.ts +13 -22
  45. package/extensions/skill-registry.ts +9 -1
  46. package/herdr/mods/gentle-agents/snapshot.js +30 -23
  47. package/herdr/mods/gentle-chat/feed.js +6 -0
  48. package/herdr/mods/gentle-chat/main.js +76 -16
  49. package/herdr/mods/gentle-chat/session.js +13 -5
  50. package/herdr/mods/gentle-chat/snapshot.js +30 -23
  51. package/herdr/mods/gentle-chat/ui.js +7 -1
  52. package/herdr/mods/gentle-inspector/main.js +2 -0
  53. package/herdr/mods/gentle-inspector/snapshot.js +30 -23
  54. package/herdr/mods/gentle-palette/main.js +1 -1
  55. package/herdr/mods/gentle-palette/snapshot.js +30 -23
  56. package/herdr/mods/gentle-pane/snapshot.js +30 -23
  57. package/herdr/mods/gentle-sidebar/snapshot.js +30 -23
  58. package/herdr/mods/gentle-spaces/snapshot.js +30 -23
  59. package/herdr/mods/gentle-status/snapshot.js +30 -23
  60. package/herdr/mods/gentle-tabs/main.js +3 -2
  61. package/herdr/mods/gentle-tabs/new-tab.js +9 -0
  62. package/herdr/mods/gentle-tabs/snapshot.js +30 -23
  63. package/herdr/mods/gentle-tokens/snapshot.js +30 -23
  64. package/lib/agent-profiles.ts +50 -10
  65. package/lib/agents-config.ts +59 -4
  66. package/lib/agents-runner.ts +34 -1
  67. package/lib/auto-permission-runtime.ts +2 -1
  68. package/lib/background-jobs-tools.ts +24 -16
  69. package/lib/claude-bridge-config.ts +41 -0
  70. package/lib/desktop-agent-definitions-service.ts +10 -6
  71. package/lib/desktop-command-rpc.ts +71 -0
  72. package/lib/desktop-feed-sources.ts +44 -1
  73. package/lib/desktop-feed.ts +41 -29
  74. package/lib/desktop-rpc-agent-definitions.ts +7 -3
  75. package/lib/desktop-rpc-changes.ts +13 -4
  76. package/lib/desktop-rpc-config.ts +106 -3
  77. package/lib/exploration-budget.ts +3 -7
  78. package/lib/gentle-design.ts +23 -4
  79. package/lib/gentle-shell-desktop.ts +85 -0
  80. package/lib/gentle-shell-launcher.ts +106 -3
  81. package/lib/mcp-config.ts +214 -0
  82. package/lib/native-review-cli.ts +78 -34
  83. package/lib/odd-phase-inference.ts +1 -1
  84. package/lib/orchestrator-mode-policy.ts +25 -12
  85. package/lib/path-consent-fence.ts +113 -0
  86. package/lib/pi-settings.ts +157 -0
  87. package/lib/review-continuation-registry.ts +7 -20
  88. package/lib/review-coordinator.ts +5 -0
  89. package/lib/review-host-relay.ts +2 -35
  90. package/lib/review-integration-v2.ts +31 -12
  91. package/lib/sensitive-paths.ts +22 -2
  92. package/lib/session-profile-freeze.ts +11 -4
  93. package/lib/session-worktree-registry.ts +11 -5
  94. package/lib/shell-card.ts +27 -1
  95. package/lib/shell-changes-view.ts +6 -2
  96. package/lib/shell-changes.ts +94 -37
  97. package/lib/shell-git-worker.ts +158 -0
  98. package/lib/shell-idle-changes.ts +88 -0
  99. package/lib/shell-untracked-cache.ts +142 -0
  100. package/lib/shell-untracked-lines.ts +178 -0
  101. package/lib/tps-policy.ts +85 -0
  102. package/lib/vim-editor-adapter.ts +3 -2
  103. package/lib/voice-artifacts.ts +8 -1
  104. package/lib/voice-install.ts +7 -3
  105. package/lib/yolo-session-policy.ts +2 -2
  106. package/package.json +1 -1
  107. package/runtime/gentle-shell-desktop.mjs +85 -0
  108. package/runtime/gentle-shell-launcher.mjs +106 -3
  109. package/runtime/native-review-cli.mjs +77 -33
  110. package/runtime/review-integration-v2.mjs +31 -12
  111. package/runtime/sensitive-paths.mjs +22 -2
  112. package/scripts/gentle-ai-installer.mjs +10 -10
  113. package/scripts/main-channel.mjs +27 -7
  114. package/scripts/verify-package-files.mjs +13 -12
  115. package/skills/rdd-defect-workflow/SKILL.md +2 -2
  116. package/tests/agent-profiles-workflow.test.ts +102 -0
  117. package/tests/agents-config.test.ts +1 -2
  118. package/tests/agents-protocol.test.ts +1 -1
  119. package/tests/agents-runner.test.ts +94 -2
  120. package/tests/append-system-prompt-route.test.ts +16 -11
  121. package/tests/auto-permission-runtime.test.ts +4 -4
  122. package/tests/bounded-stop-contract.test.ts +50 -62
  123. package/tests/child-context-files.test.ts +6 -6
  124. package/tests/child-web-package.test.ts +1 -1
  125. package/tests/controlled-engineering-editor.test.ts +192 -0
  126. package/tests/controlled-engineering-launch.test.ts +136 -0
  127. package/tests/controlled-engineering.test.ts +244 -0
  128. package/tests/delivery-b-rendered-surfaces.test.ts +1 -1
  129. package/tests/desktop-feed-tool-summaries.test.ts +1 -1
  130. package/tests/desktop-feed-transcript.test.ts +17 -0
  131. package/tests/desktop-feed.test.ts +141 -7
  132. package/tests/desktop-liveness.test.ts +125 -0
  133. package/tests/desktop-persona.test.ts +17 -0
  134. package/tests/desktop-rpc-agent-definitions.test.ts +23 -2
  135. package/tests/desktop-rpc-changes.test.ts +80 -3
  136. package/tests/desktop-rpc-config-mcp-fidelity.test.ts +106 -0
  137. package/tests/desktop-rpc-config-readonly-stores.test.ts +458 -0
  138. package/tests/desktop-rpc-config.test.ts +5 -2
  139. package/tests/desktop-rpc-design.test.ts +21 -0
  140. package/tests/desktop-rpc-session-snapshot-commands.test.ts +50 -0
  141. package/tests/desktop-session-switch.test.ts +237 -0
  142. package/tests/desktop-target-session.test.ts +104 -0
  143. package/tests/destructive-command-guard.test.ts +187 -0
  144. package/tests/devbinary/pi-host-relay.devtest.ts +73 -9
  145. package/tests/exploration-budget.test.ts +2 -26
  146. package/tests/fixtures/primary-session-prompt/gentleman.golden.md +14 -10
  147. package/tests/full-delegation-closure.test.ts +19 -9
  148. package/tests/generic-agent-tools.test.ts +3 -3
  149. package/tests/gentle-agents.test.ts +214 -9
  150. package/tests/gentle-ai-exploration-budget.test.ts +3 -2
  151. package/tests/gentle-ai-installer.test.ts +52 -51
  152. package/tests/gentle-ai.test.ts +29 -5
  153. package/tests/gentle-chat-read-failure.test.ts +74 -0
  154. package/tests/gentle-chat-session-read.test.ts +127 -0
  155. package/tests/gentle-design.test.ts +39 -0
  156. package/tests/gentle-shell-desktop.test.ts +108 -0
  157. package/tests/gentle-shell-launcher-auto-provision.test.ts +152 -0
  158. package/tests/gentle-shell-launcher-machine-output.test.ts +356 -0
  159. package/tests/gentle-shell.test.ts +93 -12
  160. package/tests/gentle-tps.test.ts +57 -0
  161. package/tests/independent-recovery-delivery.test.ts +15 -13
  162. package/tests/installer-preflight.test.ts +3 -2
  163. package/tests/job-turn-end-texts.test.ts +57 -0
  164. package/tests/lazy-module-contradictions-contract.test.ts +1 -2
  165. package/tests/main-channel.test.ts +12 -1
  166. package/tests/maintainer/desktop-rpc.maintest.ts +2 -2
  167. package/tests/native-review-capability-contract.test.ts +7 -1
  168. package/tests/native-review-cli.test.ts +113 -1
  169. package/tests/no-self-pause-contract.test.ts +8 -7
  170. package/tests/odd-phase-inference.test.ts +2 -2
  171. package/tests/odd-routing-canonical-ratchet.test.ts +1 -1
  172. package/tests/odd-routing-contract.test.ts +1 -1
  173. package/tests/orchestrator-budget.test.ts +7 -2
  174. package/tests/orchestrator-prompt-diet-contract.test.ts +5 -5
  175. package/tests/orchestrator-skills-inline-contract.test.ts +26 -0
  176. package/tests/package-manifest.test.ts +11 -16
  177. package/tests/packaged-agent-codemode.test.ts +79 -0
  178. package/tests/path-consent-fence.test.ts +326 -0
  179. package/tests/pi-update-launcher.test.ts +1 -1
  180. package/tests/primary-session-prompt.test.ts +9 -7
  181. package/tests/profile-fast-tier.test.ts +79 -4
  182. package/tests/progress-rule-contract.test.ts +54 -0
  183. package/tests/rdd-delivery-warning.test.ts +42 -4
  184. package/tests/review-actor-tool-deny.test.ts +1 -2
  185. package/tests/review-continuation-registry.test.ts +17 -17
  186. package/tests/review-controller-native-recovery.test.ts +100 -0
  187. package/tests/review-controller-native-routing.test.ts +129 -24
  188. package/tests/review-coordinator.test.ts +14 -0
  189. package/tests/review-host-relay-restart-parity.test.ts +2 -52
  190. package/tests/review-host-relay-routing.test.ts +57 -297
  191. package/tests/review-host-relay.test.ts +0 -46
  192. package/tests/review-integration-v2-forward.test.ts +39 -2
  193. package/tests/review-json-arguments.test.ts +30 -9
  194. package/tests/review-one-call-findings.test.ts +1 -0
  195. package/tests/review-untracked-inventory-replay.test.ts +181 -0
  196. package/tests/runtime-harness.mjs +27 -1
  197. package/tests/sensitive-path-tools.test.ts +155 -4
  198. package/tests/session-profile-extension.test.ts +90 -11
  199. package/tests/session-profile-freeze.test.ts +49 -2
  200. package/tests/session-profile-v1-compat.test.ts +11 -3
  201. package/tests/session-worktree-registry.test.ts +23 -0
  202. package/tests/shell-changes-idle-start.test.ts +510 -0
  203. package/tests/shell-changes-untracked-bound.test.ts +230 -0
  204. package/tests/shell-changes-view.test.ts +8 -2
  205. package/tests/shell-changes.test.ts +134 -0
  206. package/tests/shell-git-runner-stall.test.ts +74 -0
  207. package/tests/shell-git-worker-fallback.test.ts +140 -0
  208. package/tests/shell-git-worker-lifetime.test.ts +91 -0
  209. package/tests/shell-render-cache-runtime.test.ts +256 -3
  210. package/tests/shell-untracked-cache.test.ts +213 -0
  211. package/tests/short-check-routing-contract.test.ts +11 -7
  212. package/tests/skill-registry.test.ts +3 -3
  213. package/tests/support/chat-ui.ts +39 -0
  214. package/tests/t7-recovery-preservation.test.ts +68 -0
  215. package/tests/tps-policy.test.ts +96 -0
  216. package/tests/turn-end-rule-contract.test.ts +155 -0
  217. package/tests/turn-end-scope.test.ts +39 -0
  218. package/tests/verification-scoped-stop-contract.test.ts +1 -1
  219. package/tests/verification-tiers-contract.test.ts +4 -3
  220. package/tests/verify-first-launch-contract.test.ts +19 -7
  221. package/tests/vim-editor-adapter.test.ts +4 -4
  222. package/tests/voice-install.test.ts +97 -11
  223. package/tests/windows-hidden-processes.test.ts +11 -44
  224. package/tests/work-continuity-contract.test.ts +48 -55
  225. package/tests/yolo-session-policy.test.ts +2 -0
  226. package/contracts/review-provider-contract-mirror/v1.6.0/bundle/vectors/lens.json +0 -1
  227. package/extensions/codegraph-tools.ts +0 -437
  228. package/tests/child-codegraph-bootstrap.test.ts +0 -74
  229. package/tests/codegraph-tools.test.ts +0 -554
  230. /package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/README.md +0 -0
  231. /package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/schemas/refuter.schema.json +0 -0
  232. /package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/schemas/targeted-validator.schema.json +0 -0
  233. /package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/vectors/refuter.json +0 -0
  234. /package/contracts/review-provider-contract-mirror/{v1.6.0 → v1.7.0}/bundle/vectors/targeted-validator.json +0 -0
@@ -64,9 +64,9 @@ The [v2.6.0 release](https://github.com/Gentleman-Programming/gentle-pi/releases
64
64
  - Registered worktrees survive reloads. `/gentle:changes` groups each dirty root (the session's repository and its subagents' worktrees) and shows Git status, line counts, and lazy diffs against HEAD without conflating identical paths from different worktrees.
65
65
  - Fullscreen pointer navigation and the responsive sidebar keep changes, agents, and TODO usable at changing terminal widths; cached frames avoid redrawing inactive sidebar content while live status still updates.
66
66
  - The Agents List and Details views preserve the orchestrator/session hierarchy and completion, abort, and lost-exit history. Parent-child queries and notifications have an explicit handoff path, while model, effort, and usage stay observable per task.
67
- - Named `/gentle:profiles` atomically route the orchestrator separately from packaged and review roles, and carry a per-profile orchestrator workflow mode (`w` on the models screen: organic, where the orchestrator may implement inline, or full delegation, where every implementation goes to a subagent); see the [technical reference](readme-reference.md#agent-model-profiles) for the profile model. Full delegation pays off with an expensive orchestrator and light workers; on small tasks it costs a few times the wall time of organic, so see [Orchestrator workflow mode](readme-reference.md#orchestrator-workflow-mode) for the measured cost and which mode to pick.
67
+ - Named `/gentle:profiles` atomically route the orchestrator separately from packaged and review roles, and carry a per-profile orchestrator workflow mode (`w` on the models screen: organic, where the orchestrator may implement inline, or full delegation, where every implementation goes to a subagent); see the [technical reference](readme-reference.md#agent-model-profiles) for the profile model. Full delegation pays off with an expensive orchestrator and light workers; on small tasks it costs a few times the wall time of organic, so see [Orchestrator workflow mode](readme-reference.md#orchestrator-workflow-mode) for the measured cost and which mode to pick. A profile can also turn on [Controlled Engineering](readme-reference.md#controlled-engineering) (`c` on the models screen, off by default), which adds authoring rules against unrequested machinery to the sessions that write or verify code.
68
68
 
69
- The source checkout declares `gentle-pi` `5.0.0` with a package-local Gentle AI `v5.0.0` pin; the source manifest does not establish whether that version is published. The mirror uses the signed provider bundle published with v5.0.0. Its bundle version stays `1.6.0`, and the native review CLI still advertises `capabilities/v2.6` without legacy authority.
69
+ The source checkout declares `gentle-pi` `5.1.0` with a package-local Gentle AI `v5.1.0` pin; the source manifest does not establish whether that version is published. The mirror uses the signed provider bundle `1.7.0` published with v5.1.0. The native review CLI still advertises `capabilities/v2.6` without legacy authority.
70
70
 
71
71
  ## Shell interactions and runtime behavior
72
72
 
@@ -173,7 +173,7 @@ While a draft holds chips, a strip above the prompt lists each one:
173
173
 
174
174
  ### Changes
175
175
 
176
- Changes shows the **current Git state** — working tree against HEAD, untracked files included — of the session's repository and of every worktree or repository its subagents used that still exists. Nothing is scanned at startup; the list fills at the first turn end or when the panel opens, then refreshes at each turn end and while the panel is open. Fullscreen, the sidebar, and mouse interaction are unchanged.
176
+ Changes shows the **current Git state** — working tree against HEAD, untracked files included — of the session's repository and of every worktree or repository its subagents used that still exists. Startup and reload do not wait for an inventory. After the first shell frame, Changes loads in the background once the session is idle and there has been no typing for 250 ms. If a turn starts first, its normal turn-end refresh loads the list instead. If an idle scan cannot read a root, it retries after 1, 3, and 10 seconds of quiet, stopping once all roots are readable or those three retries are used. Typing restarts the current wait; starting a turn or shutting down cancels it. Turn end, opening the panel, and registering a worktree still refresh immediately, and the panel keeps refreshing while open.
177
177
 
178
178
  ```text
179
179
  ✎ 3 files · +42 −7 · extensions/gentle-shell.ts, lib/shell-bar.ts, tests/x.test.ts · /gentle:changes
@@ -189,7 +189,11 @@ Changes shows the **current Git state** — working tree against HEAD, untracked
189
189
 
190
190
  ### Bounds and session lifetime
191
191
 
192
- Changes lists every changed file outside the untracked dependency-backup exclusion without a count limit. One selected diff is bounded at 1 MiB or 20,000 lines; beyond that the panel shows "Diff too large — press o to open in editor." If Git times out, partial diff output is discarded and the pane shows "no diff for this file"; press `o` to inspect the file in the editor.
192
+ Changes lists every changed file outside the untracked dependency-backup exclusion without a count limit. If an inventory hits its 64 MiB budget for reading untracked files, the list is shown with partial line counts, which finish in later quiet passes. Files without a count go before re-counts of edited files. An unreadable file reports zero for the current scan and is retried on the next refresh without scheduling an extra scan on its own. A failed read gives its share of the budget back within the same scan, so unreadable files never keep readable ones waiting. Quiet passes stop as soon as one of them leaves the number of pending files where it was; the next refresh (a turn end, opening the panel) starts them again if anything moved. A Git read that cannot run or times out marks its root as failed, with the usual notice, never as a repository without commits. Desktop's `get_changes` makes at most two passes per request. If any counts are still deferred, the response and each affected file include `countsPending: true`; an affected file's `added` value may be zero or stale. When all counts are complete, the field is absent.
193
+
194
+ Like Git, Changes treats an untracked file with a NUL byte in its first 8,000 bytes as binary: it shows `+0`, reads no further bytes, and does not mark the count pending. Text files within the 1 MiB counting limit are counted in full. Counts are reused when size and modification time match, including across sessions. The versioned cache lives outside the repository at `<Pi agent directory>/cache/gentle-shell-untracked-lines/`, with one file per real repository root. Changes loads it on the first scan of that root, batches saves, and flushes completed counts on shutdown. An unavailable cache does not prevent counting.
195
+
196
+ One selected diff is bounded at 1 MiB or 20,000 lines; beyond that the panel shows "Diff too large — press o to open in editor." If Git times out, partial diff output is discarded and the pane shows "no diff for this file"; press `o` to inspect the file in the editor. On POSIX, inventory Git runs in a lazy worker that exits on session shutdown or after 30 seconds without work. Bounded diff reads keep the original UTF-8 truncation behavior.
193
197
 
194
198
  Captured evidence (`gentle-pi.session-change/v1`) is still stored for session statistics and root discovery, capped at 256 operations and 4 MiB per session, without affecting the Changes list. Reload and resume read the same state from Git; new sessions and forks do not inherit another session's worktrees.
195
199
 
@@ -346,7 +350,7 @@ Gentle Shell ships its own interactive tools instead of depending on third-party
346
350
 
347
351
  ### Gentle Agents
348
352
 
349
- The current package requires Pi 1.2.0 or newer and Node `^22.19.0 || >=23.6.0` (22.19.0 or a later 22.x release, or 23.6.0 or newer; Node 23.0–23.5 are not supported). Development tests resolve Pi through the open `>=1.0.0` development range. The private Vim editor adapter admits only the audited Pi `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, and `1.6.0` releases; any other release keeps ordinary prompt editing until its editor is audited. Use the latest Pi release; gentle-pi does not update your installed Pi automatically. Children, including any `GENTLE_PI_AGENTS_PI` override, must emit `agent_settled`: `agent_end` records a run's output but is not completion because retries or queued continuations may follow.
353
+ The current package requires Pi 1.2.0 or newer and Node `^22.19.0 || >=23.6.0` (22.19.0 or a later 22.x release, or 23.6.0 or newer; Node 23.0–23.5 are not supported). Development tests resolve Pi through the open `>=1.0.0` development range. The private Vim editor adapter admits only the audited Pi `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, `1.6.0`, and `1.6.1` releases; any other release keeps ordinary prompt editing until its editor is audited. Use the latest Pi release; gentle-pi does not update your installed Pi automatically. Children, including any `GENTLE_PI_AGENTS_PI` override, must emit `agent_settled`: `agent_end` records a run's output but is not completion because retries or queued continuations may follow.
350
354
 
351
355
  The `subagent_*` tools and the agents card replace the third-party subagents package (remove `npm:pi-subagents-j0k3r` from your pi packages; while it is still installed the tools stay unregistered and a warning says so at startup). Agent definitions and settings are the ones you already have: markdown agents in `~/.pi/agent/agents/`, `~/.pi/agent/subagents/`, `<cwd>/.pi/agents/`, `<cwd>/.pi/subagents/` (project beats global, `subagents/` beats `agents/`), and `subagents.json` at the global and project level (`default_model`, `default_effort`, `default_mode`, `model_profiles`, `stall_timeout_ms`, `tool_stall_timeout_ms`, `max_concurrency`, `history_max_tasks`, `report_max_bytes`). A finished child's report is delivered into your context up to `report_max_bytes` (default 16384) UTF-8 bytes; a longer one arrives as its head, a truncation line with the exact byte counts naming `subagent_result`, and the end of the report (its last 2048 bytes at most, from a line start), so a closing summary that a memory provider reads from the delivered text is not lost (a report whose part after the head is 2048 bytes or less is delivered whole); a report from a `jd-*` or `review-*` agent, or one that is a single JSON object or array, is never cut, and `subagent_result` returns the full text.
352
356
 
@@ -363,7 +367,7 @@ The card is above the editor in every mode, including fullscreen — it is not o
363
367
 
364
368
  Every subagent is its own `pi --mode rpc` child process, so the terminal never runs subagent work: the host reads JSON lines, applies each one as a small delta to a bounded per-task thread, and notifies only the listeners of that task. A task-mode child's question (`ctx.ui.select`, `confirm`, `input`, `editor`) reaches you as an ordinary pi dialog; a background child's question is dismissed. Subagents have no automatic total execution timeout: a long-running child remains live while it continues emitting RPC events. A silent child still times out through the configurable `stall_timeout_ms` watchdog (default four minutes). An announced tool call that is still running is live work, not silence, so it is bounded by `tool_stall_timeout_ms` instead (default 30 minutes, never below `stall_timeout_ms`). Closing pi stops the children that are still running.
365
369
 
366
- Delegated children (`GENTLE_PI_AGENTS_CHILD=1`) load the same context files as their parent, minus the gentle-ai managed blocks that bind themselves to the orchestrator, such as `orchestrator` and `agent-routing` (the full list lives in [`lib/child-context-files.ts`](../lib/child-context-files.ts)), and minus the `engram-protocol` memory block, which gentle-engram injects itself every turn. Every other managed block (for example `codegraph-guidance`, or `remote-authorization` nested inside `agent-routing`) and all unmanaged project text reach the child unchanged. A marker counts only when it is alone on its line outside fenced code; if a file's markers are unbalanced, mismatched, or ambiguous, that file is passed through unfiltered. The filtering lives in the packaged `extensions/child-context.ts`, which every child loads (see below); if that file is missing, the child starts without it and keeps today's unfiltered context. The extension registers only a `before_agent_start` hook and does nothing outside a child session; the primary session applies the same filter itself while Gentle Shell injects its own orchestrator prompt. Only the injected context is filtered: every file on disk keeps all of its blocks, so a runtime that reads the same file as a workspace file and carries no runtime-injected protocol (OpenClaw) still gets the `engram-protocol` block.
370
+ Delegated children (`GENTLE_PI_AGENTS_CHILD=1`) load the same context files as their parent, minus the gentle-ai managed blocks that bind themselves to the orchestrator, such as `orchestrator` and `agent-routing` (the full list lives in [`lib/child-context-files.ts`](../lib/child-context-files.ts)), and minus the `engram-protocol` memory block, which gentle-engram injects itself every turn. Every other managed block (for example `remote-authorization` nested inside `agent-routing`) and all unmanaged project text reach the child unchanged. A marker counts only when it is alone on its line outside fenced code; if a file's markers are unbalanced, mismatched, or ambiguous, that file is passed through unfiltered. The filtering lives in the packaged `extensions/child-context.ts`, which every child loads (see below); if that file is missing, the child starts without it and keeps today's unfiltered context. The extension registers only a `before_agent_start` hook and does nothing outside a child session; the primary session applies the same filter itself while Gentle Shell injects its own orchestrator prompt. Only the injected context is filtered: every file on disk keeps all of its blocks, so a runtime that reads the same file as a workspace file and carries no runtime-injected protocol (OpenClaw) still gets the `engram-protocol` block.
367
371
 
368
372
  Children of the package-owned `gentle-ai-worker`, `gentle-ai-explore`, and `gentle-ai-verify` agents start without Pi's skills catalog: the parent passes the exact skill paths they need, which they open with `read`. Gentle Agents sets `GENTLE_PI_AGENTS_NO_SKILLS_CATALOG=1` for those children, and `extensions/child-context.ts` empties the loaded skills before the first prompt, so no `<available_skills>` section is sent under either launch form, including the package's own skills in the Gentle Shell launch below. An agent with one of those names in a project `.pi/agents/` or a `subagents/` directory, and every other agent, keeps the full catalog.
369
373
 
@@ -373,7 +377,7 @@ In the isolated Gentle Shell home, `settings.json` does not declare gentle-pi; t
373
377
  - Children also skip the UI-only entrypoints: `startup-banner`, `gentle-music`, `gentle-star-prompt`, and `gentle-tps` register nothing when `GENTLE_PI_AGENTS_CHILD=1`, because a child has no terminal to paint. A child's `rpc` inputs therefore no longer count toward the star prompt. Parent sessions are unchanged, and the must-run child behavior listed above stays loaded.
374
378
  - An agent definition's frontmatter is read for `name`, `description`, `model`, `thinking` (also `effort`, `thinking_level`), `mode` (also `subagent_mode`), and `tools`. Any other key, for example `extensions:`, is ignored: the agent still loads and Gentle Shell reports `<file>: unknown frontmatter key "<key>" is ignored` as a discovery notice. A child's extensions are set by the host, never by the agent file.
375
379
  - A guardrails command classed `confirm` becomes a child question like any other above: a task-mode child asks the parent user and waits for the answer; a background child's question is dismissed.
376
- - A tool the agent requests in `--tools` that does not exist in the child when its first prompt starts adds a task note, for example `gentle-agents: requested tools missing in child: codegraph`. MCP tools (`mcp__*`) are not checked because they register later.
380
+ - A tool the agent requests in `--tools` that does not exist in the child when its first prompt starts adds a task note, for example `gentle-agents: requested tools missing in child: gentle_review_scope`. MCP tools (`mcp__*`) are not checked because they register later.
377
381
  - Without the signal, for example after a manual `pi -e <package>` launch, children fall back to `extensions/child-context.ts`, `extensions/child-safety.ts`, and `extensions/nan-provider.ts` only, with no missing-tool note. That fallback list is frozen; new child behavior ships in the package.
378
382
  - A takeover forwards every package the parent loaded, so a settings package with no extensions (for example a skills-only package with only a `package.json`), which already makes the takeover parent fail with `Failed to load extension`, makes the child fail the same way; this limitation predates forwarding.
379
383
 
@@ -400,9 +404,9 @@ In the isolated Gentle Shell home, `settings.json` does not declare gentle-pi; t
400
404
 
401
405
  ### Background jobs
402
406
 
403
- Use synchronous bash for local, finite, deterministic checks reasonably expected to finish within 30 seconds, with an explicit timeout <= 30 seconds (30 included). Use `bash_background` for longer or unknown duration, external waits, CI, builds, and servers. Inline means the same parent, not necessarily synchronous bash. Report a timeout as failure; never automatically retry, restart, or migrate it to background. Preserve RED/GREEN and public-check exit codes, stdout, and stderr; do not defer or batch Engram bugfix saves and session summaries or bypass RDD. This is agent-facing guidance, not runtime enforcement and not a performance guarantee.
407
+ Use synchronous bash for local, finite, deterministic checks likely to finish within 30s (explicit timeout <= 30s, inclusive). Use `bash_background` for longer or unknown duration, external waits, CI, builds, servers, deploys, and long tests. Inline means the same parent, not necessarily synchronous bash. Report synchronous timeouts as failures. Read output and diagnose the cause. Rerun with a fix within explicit limits, never the same timed-out invocation. If duration is the cause, say so; the same command may run in background. Preserve RED/GREEN and public-check exit codes, stdout, and stderr; do not defer or batch Engram bugfix saves and session summaries or bypass RDD. This is agent-facing guidance, not runtime enforcement and not a performance guarantee.
404
408
 
405
- Waiting on CI, a build, or a server should cost neither a `sleep` loop nor a subagent, and neither should reacting to a log or a CI run while it progresses. `bash_background` runs a shell command in the background and returns a job id at once; the agent ends its turn or keeps working, and when the command exits the agent gets one message with the exit code, the last output lines, and the output file path. The wait condition lives inside the command, so its exit is the event:
409
+ Waiting on CI, a build, or a server should cost neither a `sleep` loop nor a subagent, and neither should reacting to a log or a CI run while it progresses. `bash_background` runs a shell command in the background and returns a job id at once. The agent continues independent in-scope work now and ends the turn to wait only when none remains. On exit the agent gets one message with the exit code, the last output lines, and the output file path. The wait condition lives inside the command, so its exit is the event:
406
410
 
407
411
  ```bash
408
412
  gh run watch 12345 --exit-status # CI finished
@@ -410,12 +414,12 @@ until curl -sf localhost:3000/health; do sleep 1; done # server is up
410
414
  ```
411
415
 
412
416
  - Jobs run through Pi's own Bash execution: your configured `shellPath` and `shellCommandPrefix`, a process group per job, and process-tree kill. `bash_background` is a separate tool; native `bash` is unchanged.
413
- - The exit notice uses the same delivery as background subagent results: it is steered into a running turn at the next turn boundary, or stored and wakes an idle session. A job the agent stops with `job_stop` sends no notice; one you stop from `/gentle:jobs` is reported to the agent as stopped by the user.
417
+ - The exit notice uses the same delivery as background subagent results: it is steered into a running turn at the next turn boundary, or stored and wakes an idle session. The agent reads the result and continues the authorized work that depended on the job; a non-zero exit is an obstacle to diagnose, not the end of the task. A job the agent stops with `job_stop` sends no notice; one you stop from `/gentle:jobs` is reported to the agent as stopped by the user.
414
418
  - stdout and stderr go to a temp file (`gentle-jobs-*/job-N.log`), never into the context; the agent reads it with `read` when it needs more than the tail. The tail keeps the last 20 lines, each capped at its newest 2,000 characters, and the log directory is removed when the session shuts down.
415
419
  - `bash_background` passes through the same command confirmation, YOLO waiver, and child safety guards as `bash`.
416
- - While the orchestrator has background work running (a subagent task or a background job), a `bash` call that only sleeps (`sleep 10`, `sleep 2m`, or several such sleeps joined by `&&`/`;`) is refused with a message to end the turn, because each completion already arrives as its own message. Wait conditions such as `until ...; do sleep 1; done`, sleeps mixed with real commands, `bash_background`, and `monitor` are never refused, and `sleep` is unrestricted when nothing runs in the background.
420
+ - While the orchestrator has background work running (a subagent task or a background job), a `bash` call that only sleeps (`sleep 10`, `sleep 2m`, or several such sleeps joined by `&&`/`;`) is refused with a message to continue independent work and end the turn only when none remains, because each completion already arrives as its own message. Wait conditions such as `until ...; do sleep 1; done`, sleeps mixed with real commands, `bash_background`, and `monitor` are never refused, and `sleep` is unrestricted when nothing runs in the background.
417
421
  - Jobs live in memory, belong to the session that started them, and are stopped when the session shuts down. At most 25 run at once.
418
- - `monitor` is a background job whose every output line is an event, delivered while the command keeps running — for example `tail -f app.log | grep --line-buffered ERROR`, or a loop that prints each CI check as it finishes. Lines within 200 ms share one notice of at most 20 lines (the rest are counted, and stay in the log); notices waiting for a busy agent coalesce. `timeout_seconds` is mandatory (1–1800): the monitor is stopped when it expires and reports its event count. One that prints more than 120 lines within 60 seconds is stopped as a flood, so filter its output. When the command exits, a final notice reports the exit code and event count. It goes through the same command guards as `bash`.
422
+ - `monitor` is a background job whose every output line is an event, delivered while the command keeps running — for example `tail -f app.log | grep --line-buffered ERROR`, or a loop that prints each CI check as it finishes. Lines within 200 ms share one notice of at most 20 lines (the rest are counted, and stay in the log); notices waiting for a busy agent coalesce. `timeout_seconds` is mandatory (1–1800). When that agent-configured limit expires, the monitor ends and reports its event count; this is not a failure or a user stop. A new monitor is allowed only if watching is still needed for authorized work and other limits allow it. One that prints more than 120 lines within 60 seconds is stopped as a flood, so filter its output. When the command exits, a final notice reports the exit code and event count. The same wait rule applies: continue independent in-scope work and resume dependent work on relevant events or the exit notice. It goes through the same command guards as `bash`.
419
423
  - `/gentle:jobs` opens a full-terminal overlay with this session's jobs beside the selected job's command, status, output file, and live output tail; `↑`/`↓` or `j`/`k` move, `s` stops the selected running job, `q` closes (narrow terminals: `Tab` toggles details, `Escape` goes back). In fullscreen, click a visible job or the details, Stop and close controls; hovered targets use the shared orange role, and Stop rechecks the selected job's current identity and running status. The footer shows `⧗ N jobs` while any run. In fullscreen at 140 columns or wider, running jobs also get their own collapsible sidebar card (`⧗ Jobs`), one row per job with its elapsed time, newest first; it paints nothing only while nothing is current — no running jobs and no finished result still inside its 60-second tail, the Status card never repeats it, and `ctrl+shift+j` (or clicking the card's header) collapses it; `GENTLE_PI_JOBS_KEY` remaps the shortcut, with an empty value or `off` disabling it.
420
424
 
421
425
  ### Conflict markers in commits
@@ -491,7 +495,7 @@ You do not need the command: ask in plain language for a screen, mockup, landing
491
495
  The canvas opens in navigation mode: the mouse wheel and trackpad pan or zoom the canvas, even over an artboard, a drag on the empty canvas pans it (a drag on an artboard moves it; see **Layout**), and Ctrl/Cmd + wheel zooms. Hovering an artboard shows "Click to use this design"; clicking it enters focus mode, which shows that artboard at 100% as wide as the window (**Desktop**, see **Sizes**; an artboard designed wider than the window keeps its width and is drawn smaller to fit, with the zoom showing how much) and lets it own the pointer and keyboard, so its own scrolling, hovers, buttons, and inputs behave like the real page. While an artboard is in focus, it keeps 8 px from the window's edges with a 48 px band below it for "Back to canvas", the comments panel hides to make room, the other artboards are hidden, the canvas does not pan or zoom, and an artboard taller than the window scrolls inside its frame. To return to navigation mode, press the floating "Back to canvas" button or `Shift+Esc`, which works even while typing inside the artboard; plain `Esc` stays with the design, and the previous zoom, position, and comments panel are restored. Comment mode keeps working in both modes: a click picks an element instead of entering focus mode.
492
496
 
493
497
  - While the agent is busy, the run is queued as a follow-up.
494
- - `/gentle:design open [slug]` shows a design on a local canvas in the default browser: every artboard side by side at its manifest size, with its title and tradeoff; zoom with the buttons or Ctrl/Cmd + wheel, pan by scrolling or by dragging the empty canvas, and Fit to the window. The view starts fitted and fits again when the window or the panel changes size, until you zoom or pan yourself; while you write a comment it waits, and the next size change fits it. The canvas reloads an artboard when its file changes and the whole design when `design.json` changes. Without a slug it opens the most recent design. The URL is always printed; when the browser cannot be opened, open it manually.
498
+ - `/gentle:design open [slug]` shows a design on a local canvas in the default browser: every artboard side by side at its manifest size, with its title and tradeoff; zoom with the buttons or Ctrl/Cmd + wheel, pan by scrolling or by dragging the empty canvas, and Fit to the window. The view starts fitted and fits again when the window or the panel changes size, until you zoom or pan yourself; while you write a comment it waits, and the next size change fits it. The canvas reloads an artboard when its file changes and the whole design when `design.json` changes. Without a slug it opens the most recent design. The URL is always printed; when the browser cannot be opened, open it manually. A host that shows the canvas itself, such as the desktop app, sets `GENTLE_DESIGN_OPEN_BROWSER=0` so an open never launches the system browser; the canvas still starts and the URL is still printed (the `gentle_design` tool returns `opened: false, browserDisabled: true`).
495
499
  - **Tool rail** (left of the canvas): few tools, each an icon with a word under it: **Move** (`V`, leaves Comment mode) and **Comment** (`C`), one pressed pair; **Overview** (`F`), which fits every board like **Fit**; and **Settings** (a gear) at the bottom, a menu with **Design system board** (shows `design/system.html` in focus mode; unavailable when there is none), **Keyboard shortcuts** (`?`), the list of every shortcut, **Technical details**, a checkbox (off by default) that turns on the token inspector (see **Tokens**), the theme, two radio items under a **Theme** heading: **Gentleman**, the Gentleman brand's pink on plum, and **Neutral**, the default gray and blue (saved in this browser, `localStorage`, key `gentle-design:theme`, applied at once and from the first paint on reload; artboards keep their own colors, while the Comment mode outlines drawn inside them follow the theme), and the language, three radio items under a **Language** heading: **Español**, **English** and **Match the browser**, the default, which follows the browser's language (Spanish for any `es` language, English for anything else) and changes with it. The choice is saved in this browser (`localStorage`, key `gentle-design:language`; a browser that blocks storage keeps it for the page only) and applies at once, without reloading any artboard: the canvas's own words on every surface (the rail, the top bar, the artboards' controls and handoff row, the keyboard shortcuts list, the minimap, the preview sizes with All sizes and the Overflows chip, the ⋯ export menu, Compare, the layout's messages, the Comments panel and the comment box, **Partial implementations** with its dates, the token inspector and **Quality**, whose accessibility findings are shown in the chosen language) and the page's `lang` switch (a message already on the status line or in a toast keeps the language it was shown in), while comment text, artboard titles and tradeoffs, and design file names stay as written; the menu notes that Messages to the agent stay in English, as everything the canvas sends to the session does: a comment goes as you wrote it, the request **Ask the agent to fix** prefills is in English, and so are the findings in it, even when the card shows them in Spanish. `]` shows or hides the Comments panel. Settings keeps the usual menu keys (arrows, `Home`, `End`, `Enter`, `Esc` back to the button, `Tab` or a click outside to close). Compare covers the rail, which stays inactive until **Back to canvas**. Single-key shortcuts are ignored while typing, with Ctrl, Alt or Cmd (a key typed with AltGr still counts as a single key), while the comment popover, a menu or Compare is open, and in focus mode, where only `Shift+Esc` applies; while the list is open only its own key works, and closes it. These keys are the defaults and can be changed in the **Keyboard shortcuts** list: **Change** next to an action (Move, Comment, Overview, the Comments panel, the minimap or **Show keyboard shortcuts**, the list itself) waits for the next key and gives that action the single key pressed (a letter, digit or punctuation key, without Ctrl, Alt or Cmd, AltGr allowed; `Esc` cancels the wait and `Tab` moves on and ends it), and a key another action already uses is refused with a message naming that action, so nothing changes. **Reset** puts one action back on its default key and **Restore defaults** puts them all back. The keys are saved in this browser (`localStorage`, key `gentle-design:shortcuts`) for every design the running canvas shows (when the browser cannot save them, the list says the change holds for this page only); the browser keeps them per canvas address, and the canvas server listens on a new port each time it starts, so after a restart the shortcuts are back to their defaults, an unusable or conflicting saved entry falls back to that action's default, and the rail's tooltips, the Comments button, the minimap, **Settings** and the list always show the current keys. `Esc`, `Shift+Esc`, the arrows, `Space`, `Enter`, `Tab` and the zoom keys (`+`, `-`, `0`) stay fixed and cannot be assigned.
496
500
  - **Layout**: in Move mode, drag an artboard by any part of it (its title, its frame, the gaps in its header; not its buttons) to move it anywhere on the canvas, in canvas pixels at any zoom; the artboard you press shows selected, outlined whole, until you press the empty canvas or `Esc`, and a still click on its frame still opens it. A drag on the empty canvas pans, and holding `Space` pans from anywhere, even over an artboard. **Row**, **Column** and **Grid** in the top bar lay every artboard out again, 80 px apart, and fit the view; a moved artboard makes the layout free (none of the three pressed). Where the artboards sit is saved once per move or arrangement in `design/<slug>/layout.json` (the system board under the key `system`), restored when the design opens, and followed live by every open canvas page; without the file the artboards sit in a row, and a file that cannot be read never stops the canvas: a `layout.json` that cannot be read or used (not valid JSON, no valid layout or a position more than 2,000,000 px from the origin, too large, or not a regular file) keeps the artboards where they are and says so in the status line, and until it can be read again (or is removed) nothing is saved over it: moving an artboard or **Row**, **Column** and **Grid** change only the view. A read with no answer from the server keeps the artboards where they are without a message. A save that fails says so in the status line, and the message stays (a `design.json` reload shows it again) while the layout is unsaved; the next save that succeeds clears it. The arrangement is off inside an artboard, in Compare and when no board shows, and in Comment mode a drag on an artboard pans instead of moving it, so a click still picks an element. `Space` held on **Row**, **Column** or **Grid** just clicked pans too; a button reached with `Tab` keeps `Space` for itself. Moving an artboard by hand (free positioning) is pointer-only: from the keyboard, **Row**, **Column** and **Grid** lay the artboards out, and on the canvas the arrow keys pan, `+` and `-` zoom and `0` fits every board.
497
501
  - **Sizes**: the **Preview size** button in the top bar, after **Row**, **Column** and **Grid**, shows the open artboard's size with its icon, name and `<width> × <height>` (`Desktop 1440 × 900`); it works on an open artboard only, so outside focus mode it is disabled and its tooltip says to open an artboard. It opens a menu with the usual menu keys (arrows, `Home`, `End`, `Enter`, `Esc` back to the button, `Tab` or a click outside to close) and **Phone** (390 × 844), **Tablet** (820 × 1180), **Desktop** (the window's width less its 8 px margins, at the artboard's height in `design.json`, never narrower than the artboard's own width; checked when focus mode starts), **All sizes**, and a **Custom** width field (whole px from 240 to 2560, applied with `Enter`; the height stays the artboard's own). A width out of range keeps the menu open and says which numbers it takes. A size resizes the artboard's frame at 100% without reloading it, so the design's own media queries respond; a size taller than the window is clipped like a tall artboard, and one wider than the window keeps its width and is drawn smaller to fit. **All sizes** shows the open artboard at Phone, Tablet and **As designed** (the artboard's own size in `design.json`) side by side below its title, each in its own iframe at its true width so the design's media queries apply, all drawn at one scale that fits the window (each label names the size and the scale); live reload reloads every frame. Comment mode and pins work at every size and in every All sizes frame: a pick opens the comment box beside the element in the frame it was made in. A frame whose page is wider than it shows an **Overflows** chip at its bottom right, whose tooltip says the content is wider than that many px; the open artboard's own frame shows it only at a single size. A comment made at Phone, Tablet, a custom width or in an All sizes frame records that size unless it is the artboard's own; Desktop records none, since its width is the window's. Its card in the comments panel shows the size it was made at (`Phone 390 × 844`, `Tablet 820 × 1180` or `<width> × <height>`). Leaving focus mode, or opening another artboard, restores the artboard's own size and closes All sizes.
@@ -59,8 +59,8 @@ it lets the window close.
59
59
  Current requirements come from `package.json` and
60
60
  [`gentle-ai-installer.mjs`](../scripts/gentle-ai-installer.mjs): Node `^22.19.0 || >=23.6.0`
61
61
  (22.19.0 or a later 22.x release, or 23.6.0 or newer; 23.0–23.5 are not
62
- supported), Pi ≥1.2.0, pnpm acquisition 11.1.1, Gentle Shell package 4.0.0 and package-local
63
- Gentle AI 5.0.0. Windows native source builds require Go ≥1.25.10 when the
62
+ supported), Pi ≥1.2.0, pnpm acquisition 11.1.1, Gentle Shell package 5.1.0 and package-local
63
+ Gentle AI 5.1.0. Windows native source builds require Go ≥1.25.10 when the
64
64
  required usable native binary is missing. A reusable binary does not require Go.
65
65
  When a build needs Go and the user's Go is missing, older or unchecked, the installer uses
66
66
  its own [pinned Go](#pinned-go) instead of blocking.
@@ -17,8 +17,8 @@ Source: `42c68c46859f1724ce9179d8781dd4ee35c13a00`, `odd/tasks/review-one-call.m
17
17
 
18
18
  This accounts only for removed mandatory mirror reads, excluding protocol envelopes. Targeted local inspection, full mirror writes and initial/recovery reads remain. Tools may expose extra bytes or clip outputs. This is instruction-volume accounting, **not an observed agent run, model-compliance result, token-cost measurement or latency benchmark**. It does not establish the cause or duration of the original incidents. Available local project sessions predate the November reports and were not treated as reproductions.
19
19
 
20
- No new telemetry, framework, budget, agent, tracking artifact, approval or authority layer was introduced. No memory records were created for the accounting fixture. Existing consent, verification, delivery and correction limits are unchanged.
20
+ No new telemetry, framework, budget, agent, tracking artifact, approval or authority layer was introduced. No memory records were created for the accounting fixture. Consent, verification, delivery and explicit limits still apply. Worker corrections follow the [progress rule](delegated-verification.md#parent-continuation-after-a-workers-partial-handoff): diagnose each obstacle and change what caused it, without a default attempt limit.
21
21
 
22
22
  ## Validation
23
23
 
24
- The existing prompt-diet and work-continuity suites pass. They check instruction contracts and parent prompt delivery, not model choices. The provider-owned mirrored routing's Close step now owns the authorized-work boundary (contract 1.6.0 field-test mirror): a pending child is a wait event whose completion resumes the turn, and only a real human decision, the user's explicit stop, an already-decided denial, missing consent, or an exhausted limit stops the affected work, never unrelated authorized work. The always-on prompt defers to that boundary and keeps only Pi-owned reuse, budget, and guard clauses. No RDD switch, native guard, question tool, or surface policy changed. A representative real task trace is still needed to measure time to the first useful edit, repeated reads/consultations and redundant verification, and to decide whether other causes remain.
24
+ The existing prompt-diet and work-continuity suites pass. They check instruction contracts and parent prompt delivery, not model choices. The provider-owned mirrored routing's Close step now owns the authorized-work boundary (contract 1.7.0 field-test mirror): a pending child is a wait event whose completion resumes the turn. A real human decision, the user's explicit stop, a denial, missing consent, or an exhausted limit stops only the affected work. If a check fails, continue while a permitted route remains. If none remains, report the affected work as incomplete and continue independent authorized work; a technical dead end does not itself require a human decision. The always-on prompt defers to that boundary and keeps only Pi-owned reuse, budget, and guard clauses. No RDD switch, native guard, question tool, or surface policy changed. A representative real task trace is still needed to measure time to the first useful edit, repeated reads/consultations and redundant verification, and to decide whether other causes remain.
@@ -1,6 +1,14 @@
1
1
  # Choose how permission questions are handled
2
2
 
3
- Use **Normal**, **Auto**, **YOLO**, or **Super Yolo** for the current primary session. Optionally save any of them as the user-global default for future sessions. These modes do not redesign Gentle Shell delegation, expand the task you authorized, or replace independent safety and consent. One always-on exception: reading the task's exact resolved skill files (the selected `SKILL.md` plus its referenced instruction files, by registry, catalog or parent-supplied paths) needs no per-file permission question in any mode; secrets, sensitive paths, unrelated personal files and explicit user prohibitions still apply.
3
+ Use **Normal**, **Auto**, **YOLO**, or **Super Yolo** for the current primary session. Optionally save any of them as the user-global default for future sessions. These modes do not redesign Gentle Shell delegation, expand the task you authorized, or replace independent safety and consent. One always-on exception: reading the task's exact resolved skill files (for example, the selected `SKILL.md` plus its referenced instruction files, by registry, catalog or parent-supplied paths) needs no per-file permission question in any mode when those exact files are indexed by the session; secrets, sensitive paths, unrelated personal files and explicit user prohibitions still apply.
4
+
5
+ ## File tools outside the session worktree
6
+
7
+ `read`, `write`, `edit`, `grep`, `find`, and `ls` ask before using a target outside the session's Git worktree (or session directory outside Git) and its registered same-clone worktrees. The dialog names the resolved, absolute target. A yes grants access to that target for the rest of the live session, not its children or neighbors. Without an interactive UI, an ungranted outside target is blocked.
8
+
9
+ The OS temp directory (session `TMPDIR`, `/tmp`, or `/var/tmp`) does not need this consent. Neither does `read` of an exact skill file indexed by Pi or Gentle Shell; nearby files and writes to outside skill files are not exempt. Sensitive paths still deny first. In Auto, a confirmed access still goes through the classifier. YOLO already covers non-sensitive reads and listings, and Super Yolo waives permission prompts; neither mode overrides hard denials.
10
+
11
+ This is a consent check, not a filesystem sandbox. It does not inspect every file inside a search target, and it does not cover `bash` or custom tools.
4
12
 
5
13
  ## Tool context in Auto
6
14
 
@@ -53,7 +61,7 @@ Changing the default does **not** change the current session. To return this ses
53
61
  | **Normal** | Existing permission behavior; the default when no valid global preference exists. Guarded-command confirmations offer scoped choices: **Allow once**, **Allow for this session** (remembers the guarded identity until the session ends) and **Always allow <family>** (persists `guardedCommands[key]="allow"` for non-push guards, or a push-variant entry in the user-level `runtime-guardrails.json`), besides **Deny**. Recognized data-loss commands never offer Always allow; hosts without a select dialog keep the plain yes/no confirm. |
54
62
  | **Auto** | A separate reviewer using the current session model checks eligible actions against live user intent before execution. Local reads are classified too; locality does not exempt an action from explicit restrictions. |
55
63
  | **YOLO** | Standing permission for ordinary already-authorized work and delivery; no Auto classifier. Destructive and independent consent boundaries remain, except recursive removal of the session's own [temp scratch](yolo-mode.md#temp-scratch-removal). Destructive confirmations apply only to commands the session actually runs: destructive text quoted from issues, files or docs is not an execution. Reading and listing non-sensitive material outside the workspace (the agent's own skills, docs, configuration) needs no permission question; sensitive-path and private-credential blocks still win. [Full YOLO details](yolo-mode.md). |
56
- | **Super Yolo** | No permission prompts at all, including data-loss confirmations and configured guardrail actions. The only remaining line is the sensitive-path guard: read/write/edit of `.env`, `.ssh`, keychains, `*.pem/*.key/*.p12/*.pfx`, `auth.json`, `secrets/` and cloud credential files stays hard-blocked. Code-level catastrophic denies (`rm -rf /`, `--no-preserve-root`, `git reset --hard`, forced clean, force push) also remain. |
64
+ | **Super Yolo** | No permission prompts at all, including data-loss confirmations and configured guardrail actions. The only remaining line is the sensitive-path guard: the `read`, `grep`, `find`, `ls`, `write` and `edit` tools refuse `.env`, `.ssh`, keychains, `*.pem/*.key/*.p12/*.pfx`, `auth.json`, `secrets/` and cloud credential files. A shell command is judged as a whole line: such a path in it is blocked when the line contains a command that shows, copies, sends, opens, deletes or prints the environment (`cat`, `cp`, `scp`, `curl`, `git`, `rm`, `printenv`, `xargs` and similar), `cd`/`pushd`, `.`/`source` (env files excepted), or, for a path under `.ssh`, a program that creates files there (`install`, `touch`, `mkdir`, `ssh-keygen`, `ssh-copy-id`); also when the path is a script rather than a path (`bash -c "…"`), the first word of a command, or a redirection target. Any other command may hand a secret file to a program (`docker compose --env-file .env.local`, `ssh -i key`), but a line mixing a secret file and a reader is blocked as a whole. `printenv` and `env` are blocked, but `export -p`, `declare`, `set` and `echo "$VAR"` after sourcing an env file are not. Other limits: the guard does not see unlisted programs that print or send a file, writes into `.ssh` through `docker run -v` or an unlisted program, readers assembled at run time, interpreters given a key as an argument, or program output. Code-level catastrophic denies (`rm -rf /`, `--no-preserve-root`, `git reset --hard`, forced clean, force push) also remain. |
57
65
 
58
66
  ## Commands and menu
59
67
 
@@ -187,7 +187,7 @@ otherwise `herdr` from `PATH`, without a shell.
187
187
  | **Skill creation workflow** | Provides the `gentle-ai-skill-creator`/`gentle-ai-skill-improver` skills, `/skill-creation` prompt, and packaged style guide for LLM-first skills. |
188
188
  | **Delivery skills** | Includes issue-first PRs, chained PRs, work-unit commits, cognitive docs, comment writing, and Judgment Day review. |
189
189
  | **Bounded native review** | Freezes one candidate, dispatches only controller-selected lenses, and records native authority. Review outcomes are informational; delivery follows ordinary repository policy. |
190
- | **Verified native runtime** | The current source checkout provisions the exact package-local Gentle AI v5.0.0 runtime: signed, SHA-256-pinned release archives on Darwin/Linux and a Go SumDB-verified source build on Windows x64/arm64. It validates package-local integrity and rejects PATH, global, sibling, symlink, and mode fallbacks. |
190
+ | **Verified native runtime** | The current source checkout provisions the exact package-local Gentle AI v5.1.0 runtime: signed, SHA-256-pinned release archives on Darwin/Linux and a Go SumDB-verified source build on Windows x64/arm64. It validates package-local integrity and rejects PATH, global, sibling, symlink, and mode fallbacks. |
191
191
  | **Runtime safety** | Blocks destructive shell commands, asks for confirmation for sensitive operations, and blocks direct read/write/edit/grep/find/ls access to sensitive paths (the guard checks the tool's `path` input, so a search scoped to a directory still reads whatever that directory contains, and bash is not covered). Blocks writing a test file that reads git history at a literal commit or points `TMPDIR` inside the working directory (including a relative path such as `.tmp`, `./.tmp`, or `tmp/x`), in the primary session and in subagents. Refuses native review tools (`gentle_review*`) called from inside another tool, such as a codemode script: they run only as direct tool calls. |
192
192
 
193
193
  ## TPS notifications
@@ -198,6 +198,8 @@ The notification sums the reported usage of assistant messages in that run. TPS
198
198
 
199
199
  An old manually installed `tps.ts` (for example, `.pi/extensions/tps.ts`) may produce duplicate notifications alongside the bundled extension. Disable or remove that manual copy yourself if you do not want both; Gentle Shell does not delete it.
200
200
 
201
+ The notification can be turned off in `/gentle:customize` under **Notifications**, with the `TPS usage notification` rows: the preference persists in the gentle-pi config home as `tps.json` (schema `gentle-pi.tps/v1`, `enabled` boolean, default enabled) and applies from the next agent run without a reload. A missing, malformed or unreadable file keeps notifying, and an explicit toggle in the card replaces a malformed file.
202
+
201
203
  ## Audio notifications
202
204
 
203
205
  Audio is off by default. `/gentle:customize` → **Notifications** shows audio controls directly in the same customization modal, separate from visual settings and profiles: global enable/disable, three independent type groups (**Success**, **Error**, **Attention**) that each own a builtin tone or a validated absolute local WAV, per-event exceptions folded behind **Advanced**, explicit preview, and process mute/resume. Enter cycles a type/event sound; `f` edits its local WAV path inline and `p` previews it. Preview does not enable or save automatic audio. Invalid/unreadable configuration requires fresh explicit replacement confirmation. RPC (including interactive hosts) and children remain silent. Linux/macOS listening and manual lifecycle verification are pending; Windows audio is unavailable. See [sound notifications](sound-notifications.md) for the complete schema, defaults, file security, retention costs and manual matrix.
@@ -256,11 +258,11 @@ This installs the current npm release from the `latest` dist-tag. For a reproduc
256
258
 
257
259
  ### Source checkout
258
260
 
259
- This checkout declares its `gentle-pi` version in [`package.json`](../package.json), with a package-local Gentle AI `v5.0.0` pin. Checkout metadata alone is not proof of npm publication; verify the registry version and its release workflow.
261
+ This checkout declares `gentle-pi` `5.1.0` in [`package.json`](../package.json), with a package-local Gentle AI `v5.1.0` pin. Checkout metadata alone is not proof of npm publication; verify the registry version and its release workflow.
260
262
 
261
263
  ### Pi compatibility
262
264
 
263
- The current package requires Pi 1.2.0 or newer and Node `^22.19.0 || >=23.6.0` (22.19.0 or a later 22.x release, or 23.6.0 or newer; Node 23.0–23.5 are not supported). Development tests resolve Pi through the open `>=1.0.0` development range. The private Vim editor adapter admits only the audited Pi `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, and `1.6.0` releases; any other release keeps ordinary prompt editing until its editor is audited. Use the latest Pi release; gentle-pi does not update your installed Pi automatically. Children, including any `GENTLE_PI_AGENTS_PI` override, must emit `agent_settled`: `agent_end` records a run's output but is not completion because retries or queued continuations may follow.
265
+ The current package requires Pi 1.2.0 or newer and Node `^22.19.0 || >=23.6.0` (22.19.0 or a later 22.x release, or 23.6.0 or newer; Node 23.0–23.5 are not supported). Development tests resolve Pi through the open `>=1.0.0` development range. The private Vim editor adapter admits only the audited Pi `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, `1.6.0`, and `1.6.1` releases; any other release keeps ordinary prompt editing until its editor is audited. Use the latest Pi release; gentle-pi does not update your installed Pi automatically. Children, including any `GENTLE_PI_AGENTS_PI` override, must emit `agent_settled`: `agent_end` records a run's output but is not completion because retries or queued continuations may follow.
264
266
 
265
267
  The [`v2.6.0` release](https://github.com/Gentleman-Programming/gentle-shell/releases/tag/v2.6.0) added persistent registered worktrees and grouped `/gentle:changes` views; fuller workspace interaction details are in the [Gentle Shell reference](gentle-shell.md). It also adds named atomic `/gentle:profiles`, native review intended-untracked selection and provider continuations, and opt-in custom ask responses. Pi recognizes its global Git-managed package path; subsystems install with explicit recovery guidance when npm lifecycle work was skipped. Windows keeps child consoles hidden and fixes ownership mode; Gentle Todo keeps the next pending task visible when collapsed.
266
268
 
@@ -280,7 +282,7 @@ Native RDD was introduced in `gentle-pi` `v0.15.0` on 2026-07-10 with bounded re
280
282
 
281
283
  RDD is optional and on by default (since Gentle AI v4.0.0). Open `/gentle:rdd` to inspect the effective mode and deciding source, then explicitly select a repository or machine-wide action. The RDD entry in `/gentle:customize` shows the state checked when the card opened; explicitly applying it closes Customize and opens the same selector with fresh status. Highlighting the entry does not change RDD. Cancelling leaves both unchanged. Repository enable clears a clone-local off but cannot override machine-wide off; machine-wide enable does not clear a clone-local off. `/gentle:review-mode status|enable|disable` retains its existing clone-local behavior. These controls neither grant provider review consent nor change permission modes. The `.git/gentle-ai/candidate-views` parent must sit on a filesystem that honors private POSIX modes (or equivalent Windows ACLs); WSL DrvFS mounts without metadata can reject START before lineage creation.
282
284
 
283
- The source checkout's RDD integration installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned release assets with asset and executable SHA-256 verification (signed archives for source pin `v5.0.0`; raw prerelease binaries only under a prerelease pin). Windows x64 and arm64 build the exact `v5.0.0` source tag from the `/v5` Go module with a local Go 1.25.10+ toolchain, a sealed Go environment, `GOTOOLCHAIN=local`, and `GOSUMDB=sum.golang.org`; it does not download Go automatically (the [installation wizard](install-wizard.md#pinned-go) can put its own pinned Go first on PATH for that build). Go runs in a short private directory under the system temp directory, never inside the package, because a deep pnpm store path pushes Go's working directories past MAX_PATH; a failed build prints its whole cause chain with the failing command's output tail. Windows provenance is Go-toolchain plus SumDB evidence and postinstall tamper detection, **not** Authenticode or protection against a malicious joint binary-and-manifest replacement. Package-private locks coordinate cooperative concurrent or crashed installers; their tombstones fail closed. A malicious same-user process with write access to package-private `node_modules` is outside that protocol because it can already replace package code, binary, or manifest, and portable Node has no pathname-delete CAS. It never uses `PATH` or a global `gentle-ai` installation. For development or offline installs only, set `GENTLE_PI_SKIP_GENTLE_AI_INSTALL=1`; native review operations then fail closed with an actionable `package-local-binary-missing` error. To recover explicitly, if `GENTLE_PI_SKIP_GENTLE_AI_INSTALL` is set, remove or unset it before changing to the installed `gentle-pi` package directory. Then run `node scripts/install-gentle-ai.mjs`. This invokes the package-owned installer without relying on a global binary or npm configuration change. A missing binary can result from skipped lifecycle scripts, but does not prove that lifecycle scripts were disabled.
285
+ The source checkout's RDD integration installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned release assets with asset and executable SHA-256 verification (signed archives for source pin `v5.1.0`; raw prerelease binaries only under a prerelease pin). Windows x64 and arm64 build the exact `v5.1.0` source tag from the `/v5` Go module with a local Go 1.25.10+ toolchain, a sealed Go environment, `GOTOOLCHAIN=local`, and `GOSUMDB=sum.golang.org`; it does not download Go automatically (the [installation wizard](install-wizard.md#pinned-go) can put its own pinned Go first on PATH for that build). Go runs in a short private directory under the system temp directory, never inside the package, because a deep pnpm store path pushes Go's working directories past MAX_PATH; a failed build prints its whole cause chain with the failing command's output tail. Windows provenance is Go-toolchain plus SumDB evidence and postinstall tamper detection, **not** Authenticode or protection against a malicious joint binary-and-manifest replacement. Package-private locks coordinate cooperative concurrent or crashed installers; their tombstones fail closed. A malicious same-user process with write access to package-private `node_modules` is outside that protocol because it can already replace package code, binary, or manifest, and portable Node has no pathname-delete CAS. It never uses `PATH` or a global `gentle-ai` installation. For development or offline installs only, set `GENTLE_PI_SKIP_GENTLE_AI_INSTALL=1`; native review operations then fail closed with an actionable `package-local-binary-missing` error. To recover explicitly, if `GENTLE_PI_SKIP_GENTLE_AI_INSTALL` is set, remove or unset it before changing to the installed `gentle-pi` package directory. Then run `node scripts/install-gentle-ai.mjs`. This invokes the package-owned installer without relying on a global binary or npm configuration change. A missing binary can result from skipped lifecycle scripts, but does not prove that lifecycle scripts were disabled.
284
286
 
285
287
  Recommended companion packages, into the standalone `gentle-shell` home:
286
288
 
@@ -354,6 +356,7 @@ gentle-shell desktop [--yes] [--no-open] | --status | --uninstall
354
356
  | `--package-root <dir>` | Force this directory as the gentle-pi package to load, taking over from any conflicting package the target `settings.json` already declares (see "Loading the package" below). |
355
357
  | `--help`, `-h` | Print usage (flags, commands, env vars) and exit 0. |
356
358
  | `--version` | Print `gentle-shell <version>`, `pi <version>`, and `home <mode> <dir>`, then exit 0. |
359
+ | `--version --json` | Print the same facts as one JSON line for programs, then exit 0: `{"schema":"gentle-shell.version/v1","gentleShell":"<version>","pi":"<version>"\|null,"home":{"mode":"link"\|"isolated"\|"path","dir":"<dir>"}}`. `pi` is `null` when Pi is installed but its version could not be read; with no Pi installed at all, it fails like `--version`, with the missing-Pi message on stderr and exit 1. `--json` belongs to the launcher only together with `--version` and no other Pi argument; anywhere else (including after `--`) it is forwarded to Pi. |
357
360
  | `--` | Everything after is forwarded to pi verbatim, even text that looks like a `gentle-shell` flag. |
358
361
 
359
362
  `--link`, `--isolated`, and `--home` are mutually exclusive; combining two is a usage error, as is `--home` or `--home=` with an empty value. Effective-home precedence: an explicit flag wins, then the persisted `home` subcommand choice, then the `--isolated` default. Every argument gentle-shell does not recognize — `--mode rpc`, `-p "..."`, etc. — is forwarded to pi unchanged.
@@ -443,8 +446,22 @@ Requires the package-local gentle-ai pin at v3.6.0 or newer — the pin that add
443
446
 
444
447
  `setup` runs gentle-ai with `GENTLE_AI_PI_EXCLUDE_PACKAGES=npm:gentle-pi` (merged with any value you already set), so a Gentle AI that supports package exclusion (gentle-ai #5503) never installs the launcher-owned `npm:gentle-pi` at all. An older Gentle AI ignores the variable and its managed Pi stack declares `npm:gentle-pi` itself in the home's `settings.json` as part of that install. Once gentle-ai exits 0, `setup` removes any such declaration again immediately: this launcher always loads its own gentle-pi (its own package root, or a take-over — see "Loading the package" below), never the one gentle-ai's stack just installed, so leaving that declaration in place would let the home drift onto whatever gentle-pi npm last installed — or, for a developer running from a source checkout, onto the published npm package — instead of the running launcher's own copy. `setup` also removes `npm:@juicesharp/rpiv-ask-user-question` the same way, if gentle-ai declared it: that package conflicts with gentle-pi's own first-party `ask_user_question` tool, and Pi refuses to load two providers for the same tool name (tracked upstream as gentle-ai #4820). `--dry-run` only reports both pending removals instead of running them. A home only ever keeps a `npm:gentle-pi` declaration — and so only ever stops getting the launcher's own injection (see "Loading the package" below) — when something puts it back after `setup` runs: a hand-edited `settings.json`, or `gentle-shell install npm:gentle-pi` run manually; in that case the home behaves like a regular Pi agent home with gentle-pi installed, and `gentle-shell update npm:gentle-pi` updates it like any other package.
445
448
 
449
+ **Checking whether a home needs setup**: `gentle-shell [home selectors] setup --check` reports whether the resolved home needs `setup` and why, from the same `~/.gentle-shell/config.json` provisioning record, gentle-ai pin and gentle-pi version that automatic first-run setup compares. It only reads: it runs before the home bootstrap, the startup update check and Pi resolution, so it creates no home, writes no config, downloads nothing and needs no Pi. It accepts only `--json`; any other argument exits 2. It exits 0 when the home is set up and 1 when it needs setup, printing one line (`gentle-shell: <dir> is set up`, or ``gentle-shell: <dir> needs setup (<reasons>); run `gentle-shell [selectors] setup` ``). With `--json` it prints one JSON line in both cases instead, without the home directory:
450
+
451
+ ```json
452
+ {"schema":"gentle-shell.setup-check/v1","needsSetup":true,"home":{"mode":"isolated"},"reasons":["never-provisioned"],"foreign":false}
453
+ ```
454
+
455
+ `reasons` is empty when set up, `["never-provisioned"]` when the home has no record, and otherwise names `"gentle-ai-changed"` and/or `"gentle-pi-changed"` (a record from before gentle-pi tracking counts as `"gentle-pi-changed"`). `foreign` is `true` for a home automatic setup never touches: every `--link` home, and a `--home` that is Pi's own default agent home or a directory with content Gentle Shell did not create; only a manual `setup` provisions it. A `--link` home is also never recorded, even after a manual `setup`, so it always reports `never-provisioned`; treat a foreign home as managed by the user. A client should parse the JSON line rather than rely on exit 1 alone: exit 1 only says setup is needed, while `reasons` and `foreign` say why and whether automatic setup will ever do it.
456
+
457
+ When the launcher config or the home cannot be read (for example `config.json` is unreadable or is a directory), `setup --check` exits 3 and reports why without any path: with `--json`, one line `{"schema":"gentle-shell.setup-check/v1","error":"could not read the launcher config or home (EISDIR)"}` on stdout; otherwise `gentle-shell setup --check: <message>` on stderr. A `config.json` that is not valid JSON is not an error: like every launch, the check treats it as having no record.
458
+
459
+ The check compares the running copy's gentle-ai pin and gentle-pi version, the same ones automatic setup in that copy compares. In a bundled install a launch only continues in another copy after you accept an update at the interactive startup prompt (which never appears for a command such as `setup --check`); that new copy then compares its own pin and version on its first launch, so a check run before such an update describes the copy you had.
460
+
446
461
  **Configuring MCP servers**: `gentle-shell mcp <command>` runs Pi's own `mcp` command against the resolved home, so a standalone install configures MCP without a separate `pi` command. For example, `gentle-shell mcp add <name> -- <command> [args...]` adds a stdio server, `gentle-shell mcp add <name> --url <url>` adds a remote one, and `gentle-shell mcp list` shows what the home's `mcp.json` defines. Restart Gentle Shell to load new servers.
447
462
 
463
+ `gentle-shell mcp list --json` is forwarded to Pi unchanged and prints Pi's own JSON listing, not a Gentle Shell format. It includes each server's transport details (its URL, or its command and arguments) and its config source path, and it connects to every enabled server to report its state, exiting 1 when one fails. A desktop client that only needs names, transports and enabled state should prefer the in-session `mcp` store over this command.
464
+
448
465
  **MCP connection status for extensions**: [Observe native MCP status](mcp-status.md) documents the sanitized snapshot/event API, feature detection on older Pi builds, and the isolated maintainer integration check. Configured counts and registered tools are not connectivity evidence.
449
466
 
450
467
  **MCP migration**: Pi >= 0.99.0 provides built-in MCP; gentle-ai retires `pi-mcp-adapter` instead of installing it. After successful setup and package cleanup, Gentle Shell warns on stderr if `settings.json` still contains `"-builtin:mcp"`, `mcp.json` defines servers, and no active adapter remains. The warning names both files and the entry to remove. Setup never removes that entry or edits `mcp.json`: disabling MCP may be intentional. To enable those servers, remove only `"-builtin:mcp"` from `extensions` in the named `settings.json`, preserve other entries, and restart Pi. A declaration with `autoload: false` and no enabling extension patterns, an empty `extensions` list, or an ordinary `extensions: ["!**"]` filter without force-includes is inactive. Other nonempty filters require matching actual package resources, so setup reports uncertain adapter activity instead of silently treating the adapter as active. This read-only check also runs after automatic provisioning, but not during `--dry-run`. Errors encountered by the diagnostic produce an inspection warning without changing a successful setup's exit code; existing install and cleanup failures still propagate normally.
@@ -778,7 +795,7 @@ Text outside managed markers, other managed blocks, and kept blocks nested insid
778
795
  | Wrong cwd, worktree/git accident, merge recovery, confusing test/env issue | Stop, preserve the affected scope, and investigate separately before resuming. |
779
796
  | The runtime signals the context backstop | Pause and delegate the next bounded unit that needs several steps (its reads, edits, and checks), or stop and explain the exact blocker. Single small edits and state checks stay inline; keep command output bounded; a small task still runs its focused test and suite inline. |
780
797
 
781
- The primary session also receives a one-shot, nonblocking `Exploration budget:` notice when successful tracked discovery in one request exceeds three lookups or 40,000 UTF-8 output text bytes. Bytes are an approximate evidence-budget signal, not a token count. The covered tools are `read`, `grep`, `find`, `ls`, `mem_search`, `mem_get_observation`, `mem_context`, `codegraph` with `query` or `explore` operation, `codegraph_query`, `codegraph_explore`, and their `mcp__codegraph__`-prefixed CodeGraph names. Bash and PowerShell commands count only when the existing pure phase inference classifies them as `exploring`; commands classified as checking or unknown are excluded. This is an accounting heuristic, never permission to execute a command. Other memory tool names or aliases are not counted. Local CodeGraph init and failure fallback results do not count. Nested discovery counts only under a direct `codemode` or `mcp` call, not inside review, mutation, or verification tools. Counters span tool turns and automatic retries and reset at the next primary request; child and failed results are excluded. Direct and nested results remain untouched; the notice is a separate context message steered into an already-active run before its next model step. It is never sent while idle and never starts a new agent run. It is guidance, not a gate, a delegation guarantee, or permission to bypass mutation guards. Preparation for an already understood authorized inline write remains exempt.
798
+ The primary session also receives a one-shot, nonblocking `Exploration budget:` notice when successful tracked discovery in one request exceeds three lookups or 40,000 UTF-8 output text bytes. Bytes are an approximate evidence-budget signal, not a token count. The covered tools are `read`, `grep`, `find`, `ls`, `mem_search`, `mem_get_observation`, `mem_context`, and the optional MCP tools `mcp__codegraph__codegraph_query` and `mcp__codegraph__codegraph_explore`. If selected, gentle-ai installs CodeGraph and exposes it to Pi through `~/.pi/agent/mcp.json`. Bash and PowerShell commands count only when the existing pure phase inference classifies them as `exploring`; commands classified as checking or unknown are excluded. This is an accounting heuristic, never permission to execute a command. Other memory tool names or aliases are not counted. Nested discovery counts only under a direct `codemode` or `mcp` call, not inside review, mutation, or verification tools. Counters span tool turns and automatic retries and reset at the next primary request; child and failed results are excluded. Direct and nested results remain untouched; the notice is a separate context message steered into an already-active run before its next model step. It is never sent while idle and never starts a new agent run. It is guidance, not a gate, a delegation guarantee, or permission to bypass mutation guards. Preparation for an already understood authorized inline write remains exempt.
782
799
 
783
800
  The intended balanced loop for a bounded bugfix is:
784
801
 
@@ -879,7 +896,7 @@ flowchart TD
879
896
 
880
897
  VALIDATE is informational. Commit, push, PR, and release commands follow ordinary repository policy; RDD never authorizes, rewrites, consumes review state for, or blocks them. Dangerous-command safety and destructive-review consent remain independent.
881
898
 
882
- For the source checkout, native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v5.0.0 executable, independently hashes it, then negotiates `gentle-ai.review-integration/v2` outside the repository. Capabilities are cached by that executable digest. Every START, target status, FINALIZE, and validate request passes the same contract identifier. Negotiated envelopes decode exactly against the vendored schemas; `recover` routes only the provider-selected `action_disposition`, and optional additions require a future compatible schema/minor that the provider explicitly advertises and the consumer negotiates.
899
+ For the source checkout, native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v5.1.0 executable, independently hashes it, then negotiates `gentle-ai.review-integration/v2` outside the repository. Capabilities are cached by that executable digest. Every START, target status, FINALIZE, and validate request passes the same contract identifier. Negotiated envelopes decode exactly against the vendored schemas; `recover` routes only the provider-selected `action_disposition`, and optional additions require a future compatible schema/minor that the provider explicitly advertises and the consumer negotiates.
883
900
 
884
901
  Contract `/v2` replaces the Base64 `candidate_diff` reviewer transport of `/v1` with immutable `base_tree`/`candidate_tree` plus an ordered `changed_path_manifest` and never an inline patch. `gentle-pi` negotiates `/v2` only, with no dual-lane fallback; the cutover landed as one atomic commit against gentle-ai v2.2.2 (tracked by the `migrate-review-integration-v2` change), and the `/v1` schemas stay packaged because the `/v2` schemas `$ref` into their fragments. This provider contract version is unrelated to Pi's own internal "compact-v2" review-authority naming used below — the shared digit is coincidental, not a version pairing.
885
902
 
@@ -891,7 +908,7 @@ Windows skips automatic candidate-owner sweeping during startup and candidate ma
891
908
 
892
909
  On POSIX, if START rejects a group- or world-accessible `.git/gentle-ai/candidate-views` parent, Pi reports `candidate-owner-parent-privacy` before native START. When a sanitized probe shows the filesystem cannot represent private POSIX modes (for example WSL DrvFS mounts without `metadata`), Pi instead reports `candidate-owner-parent-chmod-ineffective` with guidance to move the Git common directory to a POSIX-metadata filesystem or enable metadata support. Inspect that parent's ownership and permissions and correct them out of band before retrying; Pi does not change them automatically. Other owner-preparation failures retain a generic diagnostic rather than exposing filesystem errors. `inspect` runs the same read-only privacy assert before advertising a ready `review.start` and withholds the advertisement with the identical typed diagnostic under `candidate-view-preflight-blocked`, so STATUS and START stop disagreeing about a candidate whose view cannot materialize (gentle-ai#2196).
893
910
 
894
- Once the source checkout's pinned gentle-ai runtime (currently v5.0.0) has written review authority, rollback MUST preserve every native store and receipt and MUST NOT run a downgraded binary against that repository. Disable the Pi route or roll forward to a compatible authority-aware release instead; deleting authority data or reinstalling an older binary is not a rollback path.
911
+ Once the source checkout's pinned gentle-ai runtime (currently v5.1.0) has written review authority, rollback MUST preserve every native store and receipt and MUST NOT run a downgraded binary against that repository. Disable the Pi route or roll forward to a compatible authority-aware release instead; deleting authority data or reinstalling an older binary is not a rollback path.
895
912
 
896
913
  ### FINALIZE wrapper input
897
914
 
@@ -1274,7 +1291,7 @@ Every profile also carries an orchestrator workflow mode: `organic` or `full-del
1274
1291
 
1275
1292
  On the models screen, `w` toggles the shown profile's mode and `s` saves it together with that profile's routing. The Orchestrator row shows the mode beside the tier indicator, both modes with the same weight and differenced only by glyph and label, and its description line states what each mode does.
1276
1293
 
1277
- The mode travels with the profile and is resolved on every prompt build, so switching profiles changes the orchestrator's rules on the next turn in both directions, with no restart. It is stored beside the profiles in `profiles.json`, under `workflow` keyed by profile name: `organic` needs no entry, so a profile that never opted in serializes exactly as before, and only a `full-delegation` mode is written. `GENTLE_PI_ORCHESTRATOR_MODE=organic|full-delegation` overrides the profile for the process, which is meant for CI and headless runs.
1294
+ The mode travels with the profile and is resolved on every prompt build, so switching profiles changes the orchestrator's rules on the next turn in both directions, with no restart. It is stored beside the profiles in `profiles.json`, under `workflow` keyed by profile name: `organic` needs no entry, so a profile that never opted in serializes exactly as before, and only a `full-delegation` mode is written (or the mode beside [Controlled Engineering](#controlled-engineering) when that option is on). `GENTLE_PI_ORCHESTRATOR_MODE=organic|full-delegation` overrides the profile for the process, which is meant for CI and headless runs.
1278
1295
 
1279
1296
  Full delegation is a deliberate trade-off for an expensive orchestrator paired with light workers, for example DeepSeek Flash or a local model: every authorized change goes to a worker, small ones included, so expect a few times the wall time of organic on small tasks. In the #1494 three-fix fixture (2026-11-10, n=3 sequential runs per arm, bare Pi median 45.5 s and about $0.036 per run, Pi catalog cost estimates), organic took about 1.2x the wall time at about $0.10 per run. With the orchestrator held at `openai-codex/gpt-6-astra` at `medium`, full delegation took about 3.9x and about $0.66 per run with `openai/gpt-6.1-terra` at `max` workers (orchestrator $0.59, workers $0.05), and about 3.4x and at least $0.58 per run with `nan/deepseek-v4-flash` workers (NaN models are unpriced, so that is a floor). The orchestrator is about 90% of the cost because it carries the always-on prompt for 9-13 turns, so lighter workers save some time (about 24 s here) but little money, and on small tasks only organic stayed within 1.5x of bare Pi. See the [measurement report](../odd/tasks/1494-overhead-measurement.md). For full delegation, give the worker roles lighter models and effort than the orchestrator; prefer organic, on the profile or for one run with `GENTLE_PI_ORCHESTRATOR_MODE=organic`, when small-task latency or cost matters. The profile's `orchestrator` entry moves the live session when you select the profile in `/gentle:profiles`, and **Make default** writes it to `settings.json` for new sessions. A repo profile pin routes roles only, so under a pin the orchestrator stays the session model from `settings.json`, and `--model` (for example in a `-p` run) overrides it for that run.
1280
1297
 
@@ -1286,6 +1303,22 @@ The mode changes the runtime as well as the prompt, so the two never disagree:
1286
1303
 
1287
1304
  `assets/orchestrator-full-delegation-card.md` is generated: it projects the rules both modes share out of `orchestrator-delegation.md`, `orchestrator-writer.md` and `orchestrator-delegation-reference.md`, which stay their single source. After editing any of them, run `node scripts/build-full-delegation-card.mjs --write`; `tests/full-delegation-closure.test.ts` fails while the card is out of date, and also fails if a full delegation session could reach an organic routing rule through any asset it names.
1288
1305
 
1306
+ ### Controlled Engineering
1307
+
1308
+ Every profile can also turn on **Controlled Engineering**, off by default. It adds one `## Controlled Engineering` section to the system prompt with authoring rules against unrequested machinery. The section comes in two forms that share a common part (work the way the project already works: use the commands, environment and data setup its AGENTS.md, README, scripts or CI document, run a documented command as written, and report a failing one instead of building a replacement):
1309
+
1310
+ - the **writer section** adds the rules for building: name the evidence for each thing you build, start from the smallest change at the root, leave out new states, options, retries, wrappers, copies or compatibility paths no requirement names, verify in proportion (the project's tests for what changed plus the test of each changed rule are enough; anything beyond needs a reason stated in one line first), keep validation, data-loss handling, security checks and the test of each changed rule, and close with an `Additions:` line;
1311
+ - the **verifier section** adds only the rules for verifying: run the project's documented commands for what changed in your own copy of the repository, never create a container, database, toolchain or environment of your own (report the check as not verified instead), and say in one line why before doing anything beyond that. It decides how a verifier verifies at every risk level; how much to verify and review consent stay as the broader guidance says.
1312
+
1313
+ On the models screen, `c` toggles the shown profile's option and `s` saves it together with that profile's routing and orchestrator mode; **Use in this session** saves a changed option first, like the mode. While it is on, the Orchestrator row shows `· controlled` after the mode chip.
1314
+
1315
+ The section reaches only sessions that write or verify code:
1316
+
1317
+ - the primary session gets the writer section, when its profile has the option on and its orchestrator mode is `organic` (a full delegation orchestrator does not write); the mode that counts is the session's effective mode, so `GENTLE_PI_ORCHESTRATOR_MODE` decides it when set;
1318
+ - `gentle-ai-worker` and `jd-fix-agent` children get the writer section, and `gentle-ai-verify` children get the verifier section, when the launching session's profile has the option on, whatever its mode. The launcher passes this in `GENTLE_PI_CONTROLLED_ENGINEERING` as `writer` or `verify`; any other value gives no section.
1319
+
1320
+ Explore, review and every other agent never receive it. A child launched by hand with only the curated child extensions (without the Gentle Shell package) does not receive the section either; the normal Gentle Shell launch does. The option is read on every prompt build and every launch, so a profile switch applies on the next turn. It is stored in the same `workflow` entry as the mode, as `"controlledEngineering": true` beside `orchestratorMode`; off is never written, so a profile that does not enable it serializes exactly as before and gets exactly today's prompt. Only exactly `true` turns it on; any other value reads as off and drops nothing, so the entry keeps its orchestrator mode.
1321
+
1289
1322
  ### Model fallback chains
1290
1323
 
1291
1324
  Each profile can give every agent an ordered list of fallback models, kept in `profile-fallbacks.json` next to `profiles.json` (older versions keep reading `profiles.json` and simply never fall back):
@@ -1374,6 +1407,8 @@ Every parent session uses one profile for its subagent launches, the footer and
1374
1407
 
1375
1408
  A session that never selected a profile resolves the shared defaults once, at startup: the local pin (`p`), then the repository declaration (`P`), then the globally active profile in `profiles.json`. It keeps that profile's name, routing, and origin (`local`, `repo`, or `global`). Changing a pin, the repository declaration, the active profile, or the profile's content afterwards affects new sessions only, the same way Pi's "set as default" for the orchestrator model leaves open sessions alone. Outside a Git worktree the repository declaration is still read, as non-Git writer admission does.
1376
1409
 
1410
+ **Startup record.** At that same own start the session appends its startup state to the session file: the profile with its origin and full definition, orchestrator included, or a clear marked as started with no profile. Resume, fork, reload and subagent children write no record, because none of them is a session's start, and a session from before the record was introduced writes nothing. `follow` mode never writes one and ignores a recorded startup state when reading, while an explicit choice still wins; the Fast tier follows the same rule. On resume the record feeds reviewers and the Fast tier, and the live model is not switched again: Pi restores the session's own model from its `model_change` entries.
1411
+
1377
1412
  **Live orchestrator at own start.** A new parent session that starts on a profile also switches its live orchestrator to that profile's `orchestrator` entry, resolved through the `p → P → G` layers of its own directory. Pi's persisted default remains only when no profile resolves or the entry is missing or unavailable (model not found or credentials missing); a failed switch keeps the current model and notifies you. This never writes `settings.json`. Follow mode and subagent children do not switch.
1378
1413
 
1379
1414
  **Behavior change for unpinned sessions.** Without a pin or declaration, launches now use the globally active profile from `profiles.json`, replacing the materialized `subagents.json` routing wholesale like a pin does. Before, an unpinned launch read the materialized stores. When nothing is pinned and no profile is active, the session freezes "no profile" and keeps routing through the materialized stores, as before; a pin added later does not change it.
@@ -1394,7 +1429,7 @@ The notice appears once per distinct change: further launches stay quiet until t
1394
1429
 
1395
1430
  **Task card layer token.** Every agents task card shows which layer supplied the launch's model, right after the model itself (for example `nan/glm5.3 · binding`): `binding` (selected in this session), `frozen:local` / `frozen:repo` / `frozen:global` (the startup snapshot and its origin), `pin:local` / `pin:repo` (a repository pin won), `declaration` (a non-Git repository declaration won), `profile` (the globally active profile routing), `definition` (the agent's own frontmatter), or `default` (Pi's default model). This makes staleness visible: a launch through a frozen session keeps showing its frozen token even after the editable layers below it change on disk.
1396
1431
 
1397
- **Current limits.** The frozen profile is kept in memory for the life of the Pi process, so `/reload` keeps it. A session whose newest record holds its startup state (written by `/gentle:profiles clear`) resumes on that state instead. Otherwise the limit applies to the startup-frozen profile: resuming a session in a new process (`--resume`, `--continue`, `--session`), `/new`, and `/fork` freeze it again from the defaults current at that moment, and the drift notice memory starts empty, so a pending change is announced once more. A profile chosen with **Use in this session** is not affected: it is restored from the current branch of the session file, and it records the startup state when the session knows it, so a later clear can return there. Recording the frozen profile at every startup is planned.
1432
+ **Current limits.** The frozen profile is kept in memory for the life of the Pi process, so `/reload` keeps it. A session's own start records its startup state in the session file, so a session resumed in a new process (`--resume`, `--continue`, `--session`) keeps the profile it started with, origin and definition included. A session from before that record existed has none and freezes again from the defaults current at resume; `/fork` writes no record either, so it freezes from the defaults current at that moment and the drift notice memory starts empty, announcing a pending change once more. A profile chosen with **Use in this session** is not affected: it is restored from the current branch of the session file, and it records the startup state when the session knows it, so a later clear can return there. The record never switches the live model again: reviewers and the Fast tier read its orchestrator, and Pi restores the session's own model from its `model_change` entries.
1398
1433
 
1399
1434
  ## Commands
1400
1435
 
@@ -1526,7 +1561,7 @@ The frame labels INSERT, NORMAL, VISUAL (characterwise), or VISUAL LINE (linewis
1526
1561
 
1527
1562
  **Deliberate `/` divergence from Claude Code:** NORMAL `/` hands off to **Pi's native slash commands and skills**, enters INSERT, and inserts `/` at the existing cursor. Pi offers slash completion only at the start of the first line; elsewhere it inserts a literal slash without moving or replacing the draft. There is **no reverse prompt-history search**. Pi's explicit history shortcuts still work, transferring to INSERT first. Unknown NORMAL printable input, encoded text and bracketed paste do not silently insert; application shortcuts can transfer to INSERT before acting.
1528
1563
 
1529
- This is a bounded command subset, not full Claude Code/Vim parity. The private editor adapter supports only the audited Pi coding-agent/TUI `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, and `1.6.0` package pairs. The two 0.99 releases have byte-identical editor and undo-stack sources. Pi 1.0.0, 1.1.0 and 1.2.0 are separately audited against the touched state, paste/history, cursor/layout, autocomplete and undo-snapshot contracts. Pi 1.2.0's paired APC fake-cursor markers remain intact so the host can suppress software cursors when hardware cursors are visible; selection inversion and empty-prompt hints support both these markers and legacy SGR cursors. Pi 1.5.0 keeps undo-stack.js and editor-component.js byte-identical to 1.2.0; its editor.js adds a read-only `capturesViewportInput` getter and autocomplete pageUp/pageDown matching, and its keys.js adds Kitty F1-F12 mappings plus the functional PUA filter — all additive to input handling, leaving the audited state, paste, layout and autocomplete contracts unchanged. Pi 1.5.1 keeps undo-stack.js, keys.js and both custom-editor sources byte-identical to 1.5.0; its editor.js stops appending "undefined" to renumbered paste markers that have no size suffix, and its TUI strips every cursor marker from terminal output rather than only the first. Pi 1.5.2 ships the same pi-tui files as 1.5.1. Pi 1.6.0 keeps undo-stack.js, keys.js, editor-component.js and both custom-editor sources byte-identical to 1.5.2; its editor.js only narrows when autocomplete Enter submits a slash command (command-name menus only) and its utils.js adds a faster grapheme path, so the audited state, paste, layout and undo contracts are unchanged. Current bundled and unbundled 1.2.0 tests prove identity, edit/undo, paste, selection, wrapping/scroll and autocomplete behavior, not old/new byte identity. Fabricated metadata tests preserve exact-version admission coverage for the older audited releases. Version metadata must come from a canonical candidate host package root whose actual `CustomEditor` and `Editor` classes match the loaded classes, never from the extension's local metadata or CLI path alone. Unknown versions, mismatched prototypes, or invalid layouts fail closed: a single compatibility warning is shown and the prompt continues with ordinary editing instead of silently entering inert NORMAL mode. Operations that would cross a registered collapsed paste marker, or encounter duplicate occurrences of a registered marker ID, are rejected without editing it. Visual highlighting relies on Pi's render layout and may be omitted if its geometry cannot be validated. No live-terminal proof of every layout or complete parity is claimed.
1564
+ This is a bounded command subset, not full Claude Code/Vim parity. The private editor adapter supports only the audited Pi coding-agent/TUI `0.99.1`, `0.99.2`, `1.0.0`, `1.1.0`, `1.2.0`, `1.3.0`, `1.4.0`, `1.5.0`, `1.5.1`, `1.5.2`, `1.6.0`, and `1.6.1` package pairs. The two 0.99 releases have byte-identical editor and undo-stack sources. Pi 1.0.0, 1.1.0 and 1.2.0 are separately audited against the touched state, paste/history, cursor/layout, autocomplete and undo-snapshot contracts. Pi 1.2.0's paired APC fake-cursor markers remain intact so the host can suppress software cursors when hardware cursors are visible; selection inversion and empty-prompt hints support both these markers and legacy SGR cursors. Pi 1.5.0 keeps undo-stack.js and editor-component.js byte-identical to 1.2.0; its editor.js adds a read-only `capturesViewportInput` getter and autocomplete pageUp/pageDown matching, and its keys.js adds Kitty F1-F12 mappings plus the functional PUA filter — all additive to input handling, leaving the audited state, paste, layout and autocomplete contracts unchanged. Pi 1.5.1 keeps undo-stack.js, keys.js and both custom-editor sources byte-identical to 1.5.0; its editor.js stops appending "undefined" to renumbered paste markers that have no size suffix, and its TUI strips every cursor marker from terminal output rather than only the first. Pi 1.5.2 ships the same pi-tui files as 1.5.1. Pi 1.6.0 keeps undo-stack.js, keys.js, editor-component.js and both custom-editor sources byte-identical to 1.5.2; its editor.js only narrows when autocomplete Enter submits a slash command (command-name menus only) and its utils.js adds a faster grapheme path, so the audited state, paste, layout and undo contracts are unchanged. Current bundled and unbundled 1.2.0 tests prove identity, edit/undo, paste, selection, wrapping/scroll and autocomplete behavior, not old/new byte identity. Fabricated metadata tests preserve exact-version admission coverage for the older audited releases. Version metadata must come from a canonical candidate host package root whose actual `CustomEditor` and `Editor` classes match the loaded classes, never from the extension's local metadata or CLI path alone. Unknown versions, mismatched prototypes, or invalid layouts fail closed: a single compatibility warning is shown and the prompt continues with ordinary editing instead of silently entering inert NORMAL mode. Operations that would cross a registered collapsed paste marker, or encounter duplicate occurrences of a registered marker ID, are rejected without editing it. Visual highlighting relies on Pi's render layout and may be omitted if its geometry cannot be validated. No live-terminal proof of every layout or complete parity is claimed.
1530
1565
 
1531
1566
  Startup banner settings remain global in `banner.json` under `GENTLE_PI_CONFIG_HOME` (default `~/.pi/gentle-ai`). Existing `showRose` and `showTextLogo` opt-outs independently control the main startup artwork; both default to enabled. Changes apply on the next session or `/reload`. Color presets are `pink` (default), `cyan`, `yellow`, and `green`. The static sidebar heading is independent of these preferences and follows the active theme.
1532
1567
 
@@ -1598,13 +1633,13 @@ To opt out:
1598
1633
  | `contracts/review-integration/v2/` | Byte-identical provider schemas and conformance fixtures for contract `review-integration/v2` (immutable `base_tree`/`candidate_tree`, ordered `changed_path_manifest`, no inline candidate diff), hash-checked before packaging. |
1599
1634
  | `extensions/startup-banner.ts` | Shows and configures the startup intro, color presets, and compact runtime panel. |
1600
1635
  | `extensions/skill-registry.ts` | Maintains `.atl/skill-registry.md` from project/user skills and closes file watchers on shutdown. |
1601
- | `extensions/codegraph-tools.ts` | Runs workspace-scoped CodeGraph init/query/explore and keeps `.codegraph/` out of git through the worktree's local `info/exclude` (never a tracked file). |
1602
1636
  | `contracts/review-provider-contract-mirror/` | Verified mirror of the Gentle AI provider contract bundle: the `orchestration/pi.md` review execution contract and the `routing/pi.md` ODD steps. Refresh it only with `node scripts/mirror-provider-contract.mjs --bundle <local archive or tree>`; `pnpm run check:provider-contract` checks it offline against its lock. |
1603
1637
  | `assets/orchestrator.md` | Parent-session orchestration contract (always-on core). |
1604
1638
  | `assets/orchestrator-delegation.md` | Lazy-loaded delegation card read when the parent delegates: the mirrored gentle-ai triggers, handoff, and launch rules. |
1605
1639
  | `assets/orchestrator-delegation-reference.md` | Lazy-loaded delegation reference read only when named: per-action table, Work Routing Ladder, background policy, runtime bindings, canonical workflows. |
1606
1640
  | `assets/orchestrator-tracking.md` | Lazy-loaded large-task ODD tracking: authorization, research, checks and consent, phase signaling, RDD assess, delivery. |
1607
1641
  | `assets/orchestrator-verification.md` | Lazy-loaded Verification rule, native risk tiers, and writer verification contract. |
1642
+ | `assets/orchestrator-maintenance.md` | Lazy-loaded parent-only prerequisites for worker-prohibited maintenance or rollback. |
1608
1643
  | `assets/orchestrator-writer.md` | Lazy-loaded allowed edit surfaces and Judgment Day fix dispatch. |
1609
1644
  | `assets/orchestrator-prompts.md` | Lazy-loaded lossless blocking-prompt relays and the provider-defect classification stub; the report workflow loads from the `gentle-ai-provider-defect-report` skill. |
1610
1645
  | `assets/orchestrator-memory.md` | Lazy-loaded ODD feature continuity and memory lifecycle rules. |
@@ -27,13 +27,39 @@ The decoder accepts the closed origin set `user`, `local`, `repo`, and `global`.
27
27
  A malformed `startup` field is dropped, so the record keeps the routing a v1
28
28
  reader gives it, and a `startup` on a clear other than `"none"` reads as a
29
29
  legacy clear. A v1 reader ignores `startup`, reads a startup record as an
30
- explicit choice and a clear with `startup: "none"` as a clear; launch routing
31
- is the same except in the case gentle-shell#2742 section 2 documents (a session
32
- that started with no profile, resumed by a v1 version after a default
33
- appeared). A bound empty snapshot is not a
34
- clear. Snapshots are detached, known invalid fields reject the whole binding,
35
- and unknown extra fields carry no routing meaning. Existing route normalization
36
- supports legacy model strings and `effort`; valid `thinking` takes precedence.
30
+ explicit choice and a clear with `startup: "none"` as a clear. Launch routing
31
+ is the same except in the documented divergences:
32
+
33
+ | Case | Current version | A v1 reader |
34
+ | --- | --- | --- |
35
+ | No profile at start, a default appeared since (gentle-shell#2742 section 2) | Keeps no session profile | Routes the default that appeared |
36
+ | `follow` mode on a recorded startup bind (gentle-shell#1064 A3) | Ignores the startup bind and resolves the current defaults; an explicit choice still wins | Routes the recorded bind |
37
+ | A session recorded at its own start, resumed (gentle-shell#1064 A3) | Resumes on the recorded startup state, origin and full definition included | Reads the same record as an explicit choice and routes it |
38
+
39
+ A bound empty snapshot is not a clear. Snapshots are detached, known invalid
40
+ fields reject the whole binding, and unknown extra fields carry no routing
41
+ meaning. Existing route normalization supports legacy model strings and
42
+ `effort`; valid `thinking` takes precedence.
43
+
44
+ ## Startup record
45
+
46
+ A session records its startup state at its own start, at the same moment it
47
+ freezes it in memory: the startup bind with its origin and full normalized
48
+ definition, orchestrator included, or the `clear` marked `startup: "none"` when
49
+ no profile resolves in any layer. Nothing else is a session's start, so a
50
+ resume, fork, reload or child session writes no record. A session from before
51
+ this record was introduced writes nothing and keeps its previous behavior: it
52
+ freezes on resume, and clear appends a legacy clear. A session with no session
53
+ file has nothing to append, so only the in-memory freeze carries its state.
54
+
55
+ A `follow` session never writes a startup record and, when reading, ignores a
56
+ startup bind and resolves the current defaults; an explicit choice still wins.
57
+ The Fast tier follows the same rule, so a `follow` session reads the default
58
+ tier of its own start rather than a recorded startup orchestrator.
59
+
60
+ On resume the record supplies the startup state reviewers and the Fast tier
61
+ read, orchestrator included. The live model is not switched again: Pi restores
62
+ the session's model from its own `model_change` entries.
37
63
 
38
64
  ## Replay
39
65
 
@@ -2,14 +2,14 @@
2
2
 
3
3
  ## Scope and delivered guidance
4
4
 
5
- This is a Shell prompt-guidance improvement, not an incident closure for #2211 or #1669. The provider-owned canonical Close now owns the authorized-work boundary: authorized steps continue, a pending child is a wait event whose completion resumes the turn without asking the human, and only a real human decision, the user's explicit stop, a denial, missing consent, or an exhausted limit stops the work it applies to, never independent authorized work. Pi's always-on continuity keeps its unique guard, budget, worker-continuation, and maintenance clauses without restating that boundary or licensing a generic **Needs your decision** stop. The parent-only maintenance route remains guidance for an explicitly authorized operation a worker cannot perform. None of these rules grants permission, changes correction limits, or implements a backup or rollback operation.
5
+ This is a Shell prompt-guidance improvement, not an incident closure for #2211 or #1669. The provider-owned canonical Close now owns the authorized-work boundary: run authorized steps; wait for a pending child whose completion will resume the turn without asking the human. A real human decision, an explicit user stop, a denial, missing consent, or an exhausted limit stops only the work it applies to. If a failure has no permitted route left, report the affected work as incomplete rather than waiting for a decision nobody needs to make. Continue independent authorized work. Pi's always-on continuity keeps its unique guard, budget, worker-continuation, and maintenance clauses without restating that boundary or licensing a generic **Needs your decision** stop. The parent-only maintenance route remains guidance for an explicitly authorized operation a worker cannot perform. The worker's progress rule does not grant permission, change explicit limits, or implement a backup or rollback operation.
6
6
 
7
7
  | Situation | Guidance delivered to the parent |
8
8
  | --- | --- |
9
- | A test or harness check fails, but a correction and rerun remain in scope and within the existing budget | Correct and continue without asking for approval of each transition. Do not reset the budget or weaken the check. |
10
- | The human specified one run, no retries, or diagnostic only | Honor that limit; correct only within the existing correction budget and never reset or weaken it. |
11
- | Proof is missing, partial, unavailable, or declined; consent is required; an action is denied; or the correction budget is exhausted | Missing proof forbids claiming completion of the affected work, never an independently authorized next step; a required authorized check the existing budget still allows keeps running. Denial, missing consent, and exhaustion stop only the work they apply to. Terminal outcomes and existing bounded-stop rules remain binding; an unavailable verifier is not retried automatically. The narrow human-requested quota recovery below is a separate attempt. |
12
- | A worker exhausts its correction limit and returns `status: partial` with its diagnosed loop cause | The worker's cycle ends, not the unit. The parent decides the next step from that evidence without asking the user: it names the cause and acts on it (organic mode may fix inline when small and understood; full delegation launches a new bounded writer carrying the diagnosis and new evidence with a changed scope or hypothesis). It never repeats the same attempt; the same cause again, or no new hypothesis, blocks that unit while independent work continues. Only a genuinely human decision goes to the user. See `docs/delegated-verification.md`. |
9
+ | A test or harness check fails, and correction remains in scope | A failed check is an obstacle. Keep correcting while each attempt names a cause from the output and changes something to address it. Never repeat the same change or stop because of an attempt count. |
10
+ | The human specified one run, no retries, or diagnostic only | Honor the explicit limit only for the work it names. Do not reset or bypass it. |
11
+ | Proof is missing, partial, unavailable, or declined; consent is required; an action is denied; or an explicit limit is exhausted | Missing proof forbids claiming completion of the affected work, never an independently authorized next step. Keep running required authorized checks that any applicable limit still allows. Denial, missing consent, and exhaustion stop only the work they apply to. Terminal outcomes and native review budgets remain binding; an unavailable verifier is not retried automatically. The narrow human-requested quota recovery below is a separate attempt. |
12
+ | The same cause fails again after a real fix with no new hypothesis; passing would require weakening, skipping or rewriting the check; or correction would cross allowed edit surfaces or an explicit limit | The worker returns `status: partial` with evidence. The worker's cycle ends, not the unit. On any such partial handoff, even after the first failure, the parent acts on the diagnosis without asking the user, within user scope and native authority: organic mode may fix inline when small and understood; full delegation launches a new bounded writer carrying the diagnosis and new evidence with a changed scope or hypothesis. The parent never repeats the same attempt or bypasses a limit. With no permitted new approach, it reports only that work as incomplete and continues independent work. Only a genuinely human decision goes to the user. See `docs/delegated-verification.md`. |
13
13
  | A worker cannot perform an upgrade | Only the parent may act after explicit authorization of the operation, exact scope and ownership, preservation, permitted tools, applicable fresh consent and guards, a validated backup, applicable artifact/migration validation, and a recovery path are established. |
14
14
  | An authorized rollback mixes task changes and unrelated changes, even in one file | Preserve unrelated edits; remove only proven task-created helpers. Never blanket restore, reset, or clean. Ambiguous ownership or denial stops the operation. |
15
15
 
@@ -29,7 +29,7 @@ This guidance changes no runtime quota detection, provider selection, or native
29
29
 
30
30
  ## Current bounded checks
31
31
 
32
- On the earlier Windows workspace, with existing dependencies and no installation, network, provider, or model calls, the bounded verification run recorded these results against the then-current contract 1.4.0 mirror. The current field-test mirror is contract 1.6.0 and `node scripts/check-provider-contract.mjs` validates its bytes:
32
+ On the earlier Windows workspace, with existing dependencies and no installation, network, provider, or model calls, the bounded verification run recorded these results against the then-current contract 1.4.0 mirror. The current field-test mirror is contract 1.7.0 and `node scripts/check-provider-contract.mjs` validates its bytes:
33
33
 
34
34
  | Command | Result |
35
35
  | --- | --- |
@@ -54,6 +54,6 @@ Those four selected cases are bounded Windows evidence only. They do not attribu
54
54
 
55
55
  ## Ownership and review limits
56
56
 
57
- The continuity clarification is Shell-owned and defers to the provider-owned Close contract for the authorized-work boundary. This delivery consumes the contract 1.6.0 field-test mirror generated from the finished canonical source through `scripts/mirror-provider-contract.mjs`; Pi never hand-edits bundle bytes or the manifest digest, and the released installer pin and capability rows remain unchanged. A released provider, installer, RDD-switch, native-guard, question-tool, or surface-policy change requires separate authority.
57
+ The continuity clarification is Shell-owned and defers to the provider-owned Close contract for the authorized-work boundary. This delivery consumes the contract 1.7.0 field-test mirror generated from the finished canonical source through `scripts/mirror-provider-contract.mjs`; Pi never hand-edits bundle bytes or the manifest digest, and the released installer pin and capability rows remain unchanged. A released provider, installer, RDD-switch, native-guard, question-tool, or surface-policy change requires separate authority.
58
58
 
59
59
  Global RDD was on. An earlier preflight stopped with `immutable_review_transport_unsupported`; no review authority was started, no receipt exists, and review or mode was not retried. That unavailable review transport does not itself authorize or prohibit ordinary delivery; any delivery decision must use its applicable authority and evidence. Earlier wording advisories concerned the diagnostic-only sentence, now removed with the generic terminal license, and the maintenance sentence, which remains guidance without new authority. No GitHub issue status was consulted, and this document does not claim publishing, delivery approval, or issue closure.