one-code-extension 0.4.1 → 0.5.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 (419) hide show
  1. package/README.md +16 -5
  2. package/agents/general-purpose.md +2 -2
  3. package/docs/guide/README.md +2 -1
  4. package/docs/guide/bring-your-claude-code-setup.md +60 -9
  5. package/docs/guide/configuration.md +48 -14
  6. package/docs/guide/differences-from-claude-code.md +32 -23
  7. package/docs/guide/doctor.md +20 -13
  8. package/docs/guide/hooks.md +18 -3
  9. package/docs/guide/installation.md +27 -4
  10. package/docs/guide/permissions-modes-and-auto-mode.md +225 -49
  11. package/docs/guide/providers-and-models.md +137 -54
  12. package/docs/guide/reference.md +27 -15
  13. package/docs/guide/sessions-and-context.md +69 -16
  14. package/docs/guide/skills-plugins-and-mcp.md +57 -20
  15. package/docs/guide/subagents-and-workflows.md +95 -29
  16. package/docs/guide/tasks-and-background-work.md +101 -26
  17. package/docs/guide/terminal-interface.md +24 -12
  18. package/docs/guide/tools.md +46 -5
  19. package/docs/guide/troubleshooting.md +13 -9
  20. package/docs/guide/windows.md +58 -31
  21. package/extensions/artifacts/gallery.ts +227 -0
  22. package/extensions/artifacts/index.ts +288 -0
  23. package/extensions/artifacts/store.ts +570 -0
  24. package/extensions/artifacts/viewer.ts +199 -0
  25. package/extensions/ask-user/description.ts +67 -0
  26. package/extensions/ask-user/dialogs.ts +80 -0
  27. package/extensions/ask-user/index.ts +37 -33
  28. package/extensions/ask-user/questions.ts +32 -7
  29. package/extensions/ask-user/widget.ts +45 -25
  30. package/extensions/auto-mode/actions.ts +6 -0
  31. package/extensions/auto-mode/cache.ts +88 -0
  32. package/extensions/auto-mode/classifier-prompt.ts +5 -4
  33. package/extensions/auto-mode/classifier.ts +290 -65
  34. package/extensions/auto-mode/config.ts +72 -20
  35. package/extensions/auto-mode/decision-log.ts +2 -0
  36. package/extensions/auto-mode/defaults.ts +1 -1
  37. package/extensions/auto-mode/denials.ts +123 -0
  38. package/extensions/auto-mode/git-checkout-programs.ts +187 -0
  39. package/extensions/auto-mode/git-status-meta.ts +159 -0
  40. package/extensions/auto-mode/history.ts +189 -0
  41. package/extensions/auto-mode/instructions.ts +58 -52
  42. package/extensions/auto-mode/model-select.ts +159 -134
  43. package/extensions/auto-mode/paths.ts +57 -5
  44. package/extensions/auto-mode/pause.ts +57 -2
  45. package/extensions/auto-mode/prompt.ts +37 -21
  46. package/extensions/auto-mode/read-only-options.ts +724 -0
  47. package/extensions/auto-mode/resolved-paths-meta.ts +133 -0
  48. package/extensions/auto-mode/rules.ts +18 -1
  49. package/extensions/auto-mode/safety-floor.ts +361 -18
  50. package/extensions/auto-mode/setup-run.ts +20 -14
  51. package/extensions/auto-mode/shell-analysis.ts +764 -490
  52. package/extensions/auto-mode/shell-parse.ts +885 -0
  53. package/extensions/auto-mode/system-note.ts +33 -0
  54. package/extensions/auto-mode/transcript.ts +80 -51
  55. package/extensions/background/cron.ts +515 -0
  56. package/extensions/background/index.ts +514 -236
  57. package/extensions/background/loop-fire.ts +136 -0
  58. package/extensions/background/loop-preamble.ts +59 -0
  59. package/extensions/background/loop-skill.ts +163 -0
  60. package/extensions/background/monitor-batch.ts +53 -0
  61. package/extensions/background/noop-fold.ts +128 -0
  62. package/extensions/background/switch-guard.ts +52 -0
  63. package/extensions/background/wakeup.ts +159 -55
  64. package/extensions/bash/background.ts +53 -17
  65. package/extensions/bash/child.ts +7 -0
  66. package/extensions/bash/description.ts +188 -0
  67. package/extensions/bash/guards.ts +15 -67
  68. package/extensions/bash/index.ts +88 -35
  69. package/extensions/branding/compaction-keep.ts +63 -0
  70. package/extensions/branding/declined.ts +22 -0
  71. package/extensions/branding/index.ts +133 -9
  72. package/extensions/branding/prompt-editor.ts +53 -6
  73. package/extensions/branding/queued-edit.ts +31 -0
  74. package/extensions/branding/replaced-builtins.ts +68 -0
  75. package/extensions/branding/startup.ts +33 -71
  76. package/extensions/btw/index.ts +229 -71
  77. package/extensions/btw/panel.ts +228 -100
  78. package/extensions/btw/prompt.ts +41 -4
  79. package/extensions/claude-compat/index.ts +7 -11
  80. package/extensions/claude-context/index.ts +446 -58
  81. package/extensions/compaction/cut.ts +157 -0
  82. package/extensions/compaction/index.ts +216 -75
  83. package/extensions/compaction/kept-thinking.ts +62 -0
  84. package/extensions/compaction/prompt.ts +15 -12
  85. package/extensions/context-budget/index.ts +24 -5
  86. package/extensions/context-management/index.ts +25 -0
  87. package/extensions/doctor/build.ts +59 -8
  88. package/extensions/doctor/builtins.ts +84 -0
  89. package/extensions/doctor/cli.ts +7 -1
  90. package/extensions/doctor/compat.ts +88 -23
  91. package/extensions/doctor/dependencies.ts +41 -5
  92. package/extensions/doctor/fix-prompt.ts +9 -2
  93. package/extensions/doctor/index.ts +102 -58
  94. package/extensions/doctor/models.ts +102 -63
  95. package/extensions/doctor/presets.ts +42 -27
  96. package/extensions/doctor/report.ts +19 -2
  97. package/extensions/doctor/viewer.ts +49 -27
  98. package/extensions/effort/index.ts +72 -19
  99. package/extensions/effort/settings.ts +21 -0
  100. package/extensions/effort/slider.ts +24 -20
  101. package/extensions/exit/index.ts +32 -1
  102. package/extensions/file-tracker/index.ts +337 -26
  103. package/extensions/file-tracker/replay.ts +96 -10
  104. package/extensions/file-tracker/restore.ts +63 -0
  105. package/extensions/file-tracker/results.ts +66 -0
  106. package/extensions/file-tracker/shell-reads.ts +211 -0
  107. package/extensions/file-tracker/tracker.ts +32 -15
  108. package/extensions/footer/footer-line.ts +45 -24
  109. package/extensions/footer/index.ts +47 -2
  110. package/extensions/footer/pr.ts +34 -5
  111. package/extensions/hooks/compaction.ts +7 -0
  112. package/extensions/hooks/executor.ts +32 -30
  113. package/extensions/hooks/index.ts +198 -31
  114. package/extensions/hooks/matcher.ts +3 -0
  115. package/extensions/hooks/protocol.ts +41 -3
  116. package/extensions/hooks/settings.ts +50 -19
  117. package/extensions/hooks/subagent-bridge.ts +2 -0
  118. package/extensions/hooks/trust.ts +13 -5
  119. package/extensions/idle-compact/index.ts +119 -0
  120. package/extensions/idle-compact/policy.ts +143 -0
  121. package/extensions/init/index.ts +11 -10
  122. package/extensions/init/prompt.ts +25 -32
  123. package/extensions/interrupted/index.ts +13 -1
  124. package/extensions/kept-thinking/index.ts +27 -0
  125. package/extensions/lib/agent-cron.ts +130 -0
  126. package/extensions/lib/agent-loader.ts +15 -1
  127. package/extensions/lib/agent-view.ts +85 -0
  128. package/extensions/lib/anthropic-payload.ts +82 -1
  129. package/extensions/lib/anthropic-server-call.ts +230 -0
  130. package/extensions/lib/anthropic-server-tools.ts +485 -0
  131. package/extensions/lib/app-launch.mjs +94 -0
  132. package/extensions/lib/argument-hints.ts +190 -0
  133. package/extensions/lib/atomic-write.ts +6 -2
  134. package/extensions/lib/auto-memory.ts +75 -0
  135. package/extensions/lib/bash-parser.ts +84 -0
  136. package/extensions/lib/btw-fork.ts +93 -0
  137. package/extensions/lib/child-extensions.ts +42 -0
  138. package/extensions/lib/child-writes.ts +45 -0
  139. package/extensions/lib/claude-context.ts +515 -100
  140. package/extensions/lib/claude-external-includes.ts +68 -0
  141. package/extensions/lib/claude-id.ts +22 -0
  142. package/extensions/lib/claude-rules.ts +323 -0
  143. package/extensions/lib/claude-settings.ts +76 -4
  144. package/extensions/lib/compaction-boundary.ts +36 -0
  145. package/extensions/lib/compaction-keep.mjs +83 -0
  146. package/extensions/lib/config-mode.ts +112 -0
  147. package/extensions/lib/consent-dialogs.ts +63 -0
  148. package/extensions/lib/consent-preview.ts +5 -1
  149. package/extensions/lib/consent-stores.ts +48 -0
  150. package/extensions/lib/context-facts.ts +78 -0
  151. package/extensions/lib/context-stack.ts +81 -0
  152. package/extensions/lib/deferred.ts +219 -25
  153. package/extensions/lib/dock-rows.ts +60 -0
  154. package/extensions/lib/empty-tool-result.ts +27 -0
  155. package/extensions/lib/environment-block.ts +76 -0
  156. package/extensions/lib/fetch-timeout.ts +24 -6
  157. package/extensions/{system-prompt → lib}/git-status.ts +51 -13
  158. package/extensions/lib/git.ts +75 -13
  159. package/extensions/lib/grammars/LICENSE-tree-sitter-bash +21 -0
  160. package/extensions/lib/grammars/README.md +2 -0
  161. package/extensions/lib/grammars/tree-sitter-bash.wasm +0 -0
  162. package/extensions/lib/guide-docs.ts +45 -0
  163. package/extensions/lib/headless-output.ts +46 -0
  164. package/extensions/lib/hook-gate.ts +7 -7
  165. package/extensions/lib/interrupt.ts +20 -4
  166. package/extensions/lib/key-input.ts +455 -0
  167. package/extensions/lib/keys.ts +14 -1
  168. package/extensions/lib/local-command.ts +47 -13
  169. package/extensions/lib/mcp-overrides.ts +1 -1
  170. package/extensions/lib/mcp-share.ts +46 -0
  171. package/extensions/lib/memory-content.ts +146 -0
  172. package/extensions/lib/memory-index.ts +18 -0
  173. package/extensions/lib/memory.ts +134 -123
  174. package/extensions/lib/model-catalog/huggingface.json +174 -0
  175. package/extensions/lib/model-catalog/models-dev.json +18297 -0
  176. package/extensions/lib/model-catalog/openrouter.json +5252 -0
  177. package/extensions/lib/model-catalog-data.ts +513 -0
  178. package/extensions/lib/model-catalog.ts +462 -0
  179. package/extensions/lib/model-choice-warnings.ts +137 -0
  180. package/extensions/lib/model-pairings.ts +152 -0
  181. package/extensions/{auto-mode → lib}/model-picker.ts +26 -43
  182. package/extensions/lib/model-policy.ts +112 -15
  183. package/extensions/lib/model-tier.ts +283 -355
  184. package/extensions/lib/model-unusable.ts +1 -1
  185. package/extensions/lib/newer-model.ts +100 -0
  186. package/extensions/lib/notices.ts +87 -0
  187. package/extensions/lib/notifications.ts +308 -64
  188. package/extensions/lib/one-code-settings.ts +74 -8
  189. package/extensions/lib/open-browser.ts +63 -0
  190. package/extensions/lib/openrouter-generation.ts +94 -0
  191. package/extensions/lib/operation-deadline.ts +30 -0
  192. package/extensions/lib/original-command.ts +4 -4
  193. package/extensions/lib/package-version.ts +1 -1
  194. package/extensions/lib/panel-focus.ts +134 -0
  195. package/extensions/lib/paths.ts +17 -2
  196. package/extensions/lib/permission-gate.ts +72 -6
  197. package/extensions/lib/persisted-output.ts +60 -8
  198. package/extensions/lib/pi-ai-estimate.ts +19 -3
  199. package/extensions/lib/pi-version.ts +21 -2
  200. package/extensions/lib/plan-mode-channels.ts +20 -5
  201. package/extensions/lib/plugins.ts +26 -17
  202. package/extensions/lib/powershell-parse-script.ts +208 -0
  203. package/extensions/lib/powershell-parser.ts +344 -0
  204. package/extensions/lib/process-tree.ts +131 -8
  205. package/extensions/lib/prompt-options.ts +82 -0
  206. package/extensions/lib/queued-delivery.ts +44 -0
  207. package/extensions/lib/reminders.ts +364 -58
  208. package/extensions/lib/replaced-builtins.mjs +199 -0
  209. package/extensions/lib/replay-call.ts +70 -0
  210. package/extensions/lib/request-replay.ts +439 -0
  211. package/extensions/lib/scratchpad.ts +81 -14
  212. package/extensions/lib/send-now-channel.ts +7 -0
  213. package/extensions/lib/session-model-tier.ts +51 -0
  214. package/extensions/lib/session-work.ts +64 -0
  215. package/extensions/lib/settings-channels.ts +4 -4
  216. package/extensions/lib/shell-exit-semantics.ts +170 -0
  217. package/extensions/lib/shell-quote.ts +11 -0
  218. package/extensions/lib/shell-result.ts +70 -0
  219. package/extensions/lib/shell-spawn.ts +70 -6
  220. package/extensions/lib/shell-tool.ts +75 -25
  221. package/extensions/lib/side-call-cache.ts +124 -0
  222. package/extensions/lib/side-call-run.ts +96 -0
  223. package/extensions/lib/side-call-usage.ts +38 -0
  224. package/extensions/lib/side-call.ts +13 -1
  225. package/extensions/lib/single-flight.ts +18 -0
  226. package/extensions/lib/skill-body.ts +42 -0
  227. package/extensions/lib/skill-scan.ts +63 -24
  228. package/extensions/lib/spill-file.ts +140 -0
  229. package/extensions/lib/subagent-handback.ts +113 -0
  230. package/extensions/lib/system-role.ts +156 -0
  231. package/extensions/lib/terminal-text.ts +114 -0
  232. package/extensions/lib/text-width.ts +47 -16
  233. package/extensions/lib/timer-ops.ts +20 -0
  234. package/extensions/lib/tool-additions.ts +149 -0
  235. package/extensions/lib/tool-call-corruption.ts +134 -0
  236. package/extensions/lib/tool-path.ts +66 -0
  237. package/extensions/lib/tool-variants.ts +69 -0
  238. package/extensions/lib/tui-render.ts +255 -27
  239. package/extensions/lib/turn-budget-layout.ts +143 -0
  240. package/extensions/lib/update-check.mjs +15 -2
  241. package/extensions/lib/usage-bus.ts +1 -1
  242. package/extensions/lib/user-denial.ts +38 -0
  243. package/extensions/lib/workspace-channel.ts +16 -0
  244. package/extensions/lib/worktree-channel.ts +31 -3
  245. package/extensions/lib/worktree-isolation.ts +40 -10
  246. package/extensions/lsp/client.ts +8 -9
  247. package/extensions/lsp/index.ts +70 -4
  248. package/extensions/lsp/keep-alive.ts +1 -1
  249. package/extensions/lsp/trust.ts +119 -0
  250. package/extensions/lsp/watcher.ts +1 -1
  251. package/extensions/mcp/announce.ts +87 -5
  252. package/extensions/mcp/client.ts +161 -48
  253. package/extensions/mcp/config.ts +132 -8
  254. package/extensions/mcp/discovery.ts +19 -0
  255. package/extensions/mcp/index.ts +209 -71
  256. package/extensions/mcp/oauth/browser.ts +38 -17
  257. package/extensions/mcp/oauth/flow.ts +25 -17
  258. package/extensions/mcp/oauth/provider.ts +14 -8
  259. package/extensions/mcp/oauth/store.ts +34 -16
  260. package/extensions/mcp/panel/keys.ts +12 -11
  261. package/extensions/mcp/panel/render.ts +9 -6
  262. package/extensions/mcp/schema.ts +104 -5
  263. package/extensions/mcp/trust.ts +151 -67
  264. package/extensions/memory/entries.ts +23 -14
  265. package/extensions/memory/index.ts +134 -28
  266. package/extensions/memory/open-external.ts +33 -18
  267. package/extensions/memory/panel.ts +135 -26
  268. package/extensions/newer-model/index.ts +31 -0
  269. package/extensions/notebook/description.ts +18 -0
  270. package/extensions/notebook/index.ts +6 -5
  271. package/extensions/notebook/notebook.ts +1 -1
  272. package/extensions/permissions/index.ts +1300 -381
  273. package/extensions/permissions/matcher.ts +425 -74
  274. package/extensions/permissions/modes.ts +6 -4
  275. package/extensions/permissions/panel/host.ts +130 -0
  276. package/extensions/permissions/panel/keys.ts +48 -0
  277. package/extensions/permissions/panel/render.ts +450 -0
  278. package/extensions/permissions/panel/state.ts +550 -0
  279. package/extensions/permissions/powershell-cmdlets.ts +198 -0
  280. package/extensions/permissions/powershell-paths.ts +197 -0
  281. package/extensions/permissions/powershell-rules.ts +207 -280
  282. package/extensions/permissions/powershell-tree.ts +557 -0
  283. package/extensions/permissions/project-trust.ts +27 -11
  284. package/extensions/permissions/protected-paths.ts +14 -2
  285. package/extensions/permissions/session-grant.ts +6 -0
  286. package/extensions/permissions/settings.ts +166 -31
  287. package/extensions/permissions/subagent-gate.ts +25 -0
  288. package/extensions/permissions/workspace.ts +78 -0
  289. package/extensions/plan-mode/index.ts +156 -69
  290. package/extensions/plan-mode/reminder.ts +89 -21
  291. package/extensions/plan-mode/texts.ts +177 -0
  292. package/extensions/plan-mode/viewer.ts +92 -27
  293. package/extensions/plugins/counts.ts +3 -3
  294. package/extensions/plugins/index.ts +61 -46
  295. package/extensions/plugins/install/install.ts +16 -0
  296. package/extensions/plugins/marketplace/sync.ts +9 -3
  297. package/extensions/plugins/marketplace/types.ts +3 -1
  298. package/extensions/plugins/panel/keys.ts +21 -24
  299. package/extensions/plugins/panel/render.ts +12 -6
  300. package/extensions/plugins/shell-expand.ts +107 -0
  301. package/extensions/plugins/template.ts +32 -15
  302. package/extensions/powershell/child.ts +7 -0
  303. package/extensions/powershell/description.ts +38 -6
  304. package/extensions/powershell/guards.ts +1 -1
  305. package/extensions/powershell/index.ts +12 -7
  306. package/extensions/recap/index.ts +65 -60
  307. package/extensions/recap/prompt.ts +2 -2
  308. package/extensions/recap/scheduler.ts +3 -5
  309. package/extensions/search-tools/grep-merge.ts +39 -0
  310. package/extensions/search-tools/index.ts +0 -0
  311. package/extensions/send-now/chord.ts +62 -0
  312. package/extensions/send-now/index.ts +133 -0
  313. package/extensions/session-title/index.ts +3 -0
  314. package/extensions/session-title/title.ts +4 -1
  315. package/extensions/skill/code-review.ts +97 -0
  316. package/extensions/skill/index.ts +421 -101
  317. package/extensions/skill/invoke.ts +128 -18
  318. package/extensions/skill/listing.ts +133 -9
  319. package/extensions/skill/panel/keys.ts +15 -16
  320. package/extensions/skill/panel/render.ts +5 -2
  321. package/extensions/skill/panel/state.ts +12 -1
  322. package/extensions/subagents/agent-args.ts +39 -0
  323. package/extensions/subagents/agent-description.ts +132 -0
  324. package/extensions/subagents/agents.ts +116 -23
  325. package/extensions/subagents/announce.ts +69 -0
  326. package/extensions/subagents/default-model.ts +2 -3
  327. package/extensions/subagents/delegation-steer.ts +4 -4
  328. package/extensions/subagents/fork-cache.ts +76 -0
  329. package/extensions/subagents/guide-agent.ts +189 -0
  330. package/extensions/subagents/hand-back-review.ts +3 -0
  331. package/extensions/subagents/index.ts +1493 -824
  332. package/extensions/subagents/live-runs.ts +26 -6
  333. package/extensions/subagents/model-select.ts +38 -25
  334. package/extensions/subagents/outcome.ts +2 -2
  335. package/extensions/subagents/panel-keys.ts +73 -31
  336. package/extensions/subagents/panel-render.ts +120 -96
  337. package/extensions/subagents/panel-widget.ts +60 -89
  338. package/extensions/subagents/runner.ts +108 -80
  339. package/extensions/subagents/runs.ts +39 -5
  340. package/extensions/subagents/send-to-main-tool.ts +1 -1
  341. package/extensions/subagents/session-turns.ts +32 -8
  342. package/extensions/subagents/shell-panel.ts +36 -178
  343. package/extensions/subagents/tasks-dialog.ts +170 -0
  344. package/extensions/subagents/viewport-mirror.ts +95 -0
  345. package/extensions/subagents/worktree.ts +57 -13
  346. package/extensions/system-prompt/environment.ts +19 -19
  347. package/extensions/system-prompt/idle-turn.ts +65 -0
  348. package/extensions/system-prompt/index.ts +131 -47
  349. package/extensions/system-prompt/template.ts +24 -50
  350. package/extensions/system-prompt/tiers/common.ts +23 -64
  351. package/extensions/system-prompt/tiers/frontier.ts +32 -11
  352. package/extensions/system-prompt/tiers/low.ts +67 -45
  353. package/extensions/system-prompt/tiers/mid.ts +96 -38
  354. package/extensions/system-reminder/index.ts +175 -13
  355. package/extensions/tasks/descriptions.ts +190 -0
  356. package/extensions/tasks/index.ts +120 -41
  357. package/extensions/tasks/store.ts +83 -16
  358. package/extensions/tool-call-corruption/child.ts +7 -0
  359. package/extensions/tool-call-corruption/index.ts +237 -0
  360. package/extensions/tool-search/announce.ts +16 -0
  361. package/extensions/tool-search/index.ts +189 -41
  362. package/extensions/tool-style/index.ts +68 -10
  363. package/extensions/tool-style/write-description.ts +40 -0
  364. package/extensions/tool-style/write-render.ts +237 -0
  365. package/extensions/turn-duration/index.ts +7 -3
  366. package/extensions/turn-duration/line.ts +47 -4
  367. package/extensions/web/backends.ts +6 -9
  368. package/extensions/web/description.ts +50 -0
  369. package/extensions/web/index.ts +118 -53
  370. package/extensions/web/native-call.ts +15 -0
  371. package/extensions/web/native-results.ts +41 -0
  372. package/extensions/web-fetch/description.ts +42 -0
  373. package/extensions/web-fetch/extract.ts +53 -6
  374. package/extensions/web-fetch/index.ts +125 -76
  375. package/extensions/web-fetch/page-content.ts +19 -0
  376. package/extensions/web-fetch/response.ts +49 -0
  377. package/extensions/web-fetch/summarize.ts +9 -10
  378. package/extensions/workflow/agent-session.ts +105 -18
  379. package/extensions/workflow/args.ts +24 -0
  380. package/extensions/workflow/description.ts +67 -0
  381. package/extensions/workflow/globals.ts +17 -3
  382. package/extensions/workflow/index.ts +145 -162
  383. package/extensions/workflow/records.ts +1 -0
  384. package/extensions/workflow/run-manager.ts +29 -6
  385. package/extensions/workflow/saved-workflows.ts +3 -2
  386. package/extensions/workflow/types.ts +22 -1
  387. package/extensions/workflow/viewer.ts +54 -24
  388. package/extensions/workflow/widget.ts +20 -0
  389. package/extensions/worktree/descriptions.ts +91 -0
  390. package/extensions/worktree/guards.ts +316 -54
  391. package/extensions/worktree/index.ts +121 -39
  392. package/extensions/worktree/powershell-guards.ts +167 -0
  393. package/extensions/worktree/rewrite.ts +14 -16
  394. package/package.json +18 -7
  395. package/skills/artifact-design/SKILL.md +85 -0
  396. package/skills/code-review/SKILL.md +20 -20
  397. package/skills/code-review/cells/arguments-and-flags.md +19 -0
  398. package/skills/code-review/cells/high-3x5-recall-verify.md +137 -0
  399. package/skills/code-review/cells/high-8-inline.md +122 -0
  400. package/skills/code-review/cells/low-1-pass-max4.md +27 -0
  401. package/skills/code-review/cells/low-1-pass-min-files-4.md +28 -0
  402. package/skills/code-review/cells/max-5x5-verify-sweep.md +162 -0
  403. package/skills/code-review/cells/medium-3x5-verify.md +132 -0
  404. package/skills/code-review/cells/minimal-prompt.md +32 -0
  405. package/skills/code-review/cells/xhigh-10-inline-sweep.md +149 -0
  406. package/skills/code-review/cells/xhigh-5x5-verify-sweep.md +162 -0
  407. package/skills/fewer-permission-prompts/SKILL.md +1 -1
  408. package/skills/loop/SKILL.md +11 -0
  409. package/skills/security-review/SKILL.md +2 -5
  410. package/skills/simplify/SKILL.md +7 -5
  411. package/skills/workflow-authoring/SKILL.md +143 -0
  412. package/themes/onecode-light.json +1 -1
  413. package/themes/onecode.json +1 -1
  414. package/types/app.d.ts +58 -0
  415. package/types/community-packages.d.ts +26 -1
  416. package/extensions/auto-mode/recoverability.ts +0 -229
  417. package/extensions/lib/capability-index.ts +0 -466
  418. package/extensions/lib/model-facts.generated.json +0 -2675
  419. package/extensions/lib/model-facts.ts +0 -162
package/README.md CHANGED
@@ -83,7 +83,7 @@ The [`@one-ai/one-code`](https://www.npmjs.com/package/@one-ai/one-code)
83
83
  app package bundles a pinned version of pi and provides the `onecode` command.
84
84
  The [`one-code-extension`](https://www.npmjs.com/package/one-code-extension)
85
85
  package uses your existing pi installation and is tested against pi versions
86
- 0.83 through 0.86. For the extension package, use `pi` in place of `onecode`.
86
+ 0.84.3 through 1.3. For the extension package, use `pi` in place of `onecode`.
87
87
 
88
88
  The app opens in a full-screen terminal interface by default. See the
89
89
  [installation guide](docs/guide/installation.md) for display settings and more
@@ -141,6 +141,13 @@ One Code builds that adaptation into the harness:
141
141
  endpoint change. One Code provides shared tool interfaces and selects
142
142
  supporting models from the provider's catalog, subject to capability
143
143
  requirements.
144
+ - **Auto mode on any provider.** Claude Code's auto mode now sends each
145
+ tool call to the API server for a safety check, using a request field
146
+ the endpoint has to support. Claude Code keeps its local classifier as a
147
+ fallback only for a while ([LiteLLM's notes](https://docs.litellm.ai/blog/claude-code-server-side-auto-mode)
148
+ give October 23, 2026), so an endpoint without that support can leave
149
+ auto mode unavailable. One Code runs its own two-stage classifier on a
150
+ model from your provider, so auto mode works wherever your models run.
144
151
  - **An open harness you can change.** One Code's prompts, tools, and
145
152
  workflows are implemented as pi extensions. You can inspect them,
146
153
  change their behavior, and add your own.
@@ -239,8 +246,8 @@ Press **ctrl+q**, or **alt+m** on Windows and WSL, to cycle through manual,
239
246
  accept-edits, plan, and auto modes. In plan mode, the agent investigates and
240
247
  writes a plan file before you approve implementation.
241
248
 
242
- Use `/permissions` to inspect rules and `/auto-mode` to configure the
243
- classifier.
249
+ Use `/permissions` to manage rules and approve calls auto mode blocked, and
250
+ `/auto-mode` to configure the classifier.
244
251
 
245
252
  The permission system provides application-level controls. For operating
246
253
  system isolation, run One Code inside a container. See
@@ -258,11 +265,13 @@ hook configuration.
258
265
  | Long sessions | Per-repository memory, a session scratchpad, and context compaction. |
259
266
  | Task tracking | A pinned progress widget, background monitors, and scheduled wake-ups. |
260
267
  | Tool discovery | Tools loaded on demand to reduce prompt overhead. |
268
+ | Artifacts | HTML pages the model writes (reports, dashboards, small tools), saved in `~/.onecode/artifacts/` with every version kept, and opened in your browser. |
261
269
  | Reasoning and appearance | `/effort` or **shift+tab** to set reasoning effort; `onecode` and `onecode-light` themes. |
262
270
  | Customization | pi extensions, themes, and settings. |
263
271
 
264
- Bundled skills include `simplify`, `code-review`, `security-review`, and
265
- `fewer-permission-prompts`. A project skill with the same name takes precedence.
272
+ Bundled skills include `simplify`, `code-review`, `security-review`,
273
+ `fewer-permission-prompts`, and `artifact-design`. A project skill with the
274
+ same name takes precedence.
266
275
 
267
276
  For scripting and session management:
268
277
 
@@ -309,6 +318,8 @@ pi list
309
318
 
310
319
  The [user guide](docs/guide/README.md) covers setup, configuration, providers,
311
320
  permissions, workflows, tools, session management, and troubleshooting.
321
+ If you want to change One Code itself, the [developer docs](docs/dev/README.md)
322
+ cover the architecture, the rules extensions follow, and how to test.
312
323
 
313
324
  For the ideas behind the project, read
314
325
  [Harness Engineering 101](https://isuruwijesiri.com/harness-engineering-101/).
@@ -9,8 +9,8 @@ You have the project's full tool set. Work autonomously: the agent that delegate
9
9
  to you cannot answer follow-up questions, so make reasonable decisions and state
10
10
  the assumptions you made.
11
11
 
12
- Your final message is the entire result — it is read by another agent, not by a
13
- human watching your progress. So:
12
+ Your report is the entire result: hand it back with SubagentHandback. It is
13
+ read by another agent, not by a human watching your progress. So:
14
14
 
15
15
  - Lead with the answer or outcome, not a description of your process.
16
16
  - Include the concrete details the caller needs: file paths with line numbers,
@@ -46,7 +46,8 @@ If you've never run One Code, read these in order:
46
46
  - [Every One Code settings key](configuration.md#settings-reference)
47
47
  - [Provider API keys](providers-and-models.md#store-keys-as-environment-variables)
48
48
  - [Web-search providers and fallback order](providers-and-models.md#web-search-on-providers-without-a-search-api)
49
- - [Subagent and classifier models](subagents-and-workflows.md#choose-the-subagent-model)
49
+ - [Subagent model selection](subagents-and-workflows.md#choose-the-subagent-model)
50
+ - [Automatic classifier model selection](permissions-modes-and-auto-mode.md#the-classifier-model)
50
51
  - [Default permission mode](permissions-modes-and-auto-mode.md#choose-the-starting-mode)
51
52
  - [Auto-mode configuration keys](permissions-modes-and-auto-mode.md#configure-auto-mode)
52
53
  - [Language-server setup](configuration.md#language-server-diagnostics)
@@ -7,6 +7,10 @@ existing setup works without changes. There's no import step and nothing
7
7
  to convert. Open a project that already has a `.claude/` directory, and One
8
8
  Code picks up each of the following as it is.
9
9
 
10
+ That's the default, Claude-compatible mode. If you'd rather One Code ignore
11
+ your Claude Code setup entirely, switch to independent mode. See
12
+ [Run One Code on its own setup](#run-one-code-on-its-own-setup).
13
+
10
14
  ## Project instructions: CLAUDE.md
11
15
 
12
16
  One Code loads `CLAUDE.md` files and includes them in the model's context
@@ -15,17 +19,25 @@ exactly as Claude Code does: your global `~/.claude/CLAUDE.md`, then the
15
19
  directory, plus any `CLAUDE.local.md` beside them for private instructions.
16
20
  `@path` imports are expanded in place.
17
21
 
18
- If a directory has no `CLAUDE.md`, One Code uses its `AGENTS.md` instead, so
19
- a repository that standardized on `AGENTS.md` works too. A `CLAUDE.md` takes
20
- precedence over an `AGENTS.md` in the same directory.
22
+ If the project has no `CLAUDE.md` or `CLAUDE.local.md` anywhere on that
23
+ path, One Code loads its `AGENTS.md` files instead, in the same places, plus
24
+ any `.claude/AGENTS.md`. So a repository that standardized on `AGENTS.md`
25
+ works too. Once a `CLAUDE.md` exists, the `AGENTS.md` files are left out,
26
+ the same rule Claude Code follows.
27
+
28
+ Claude Code's `instructionFiles` option changes that rule, and One Code
29
+ honours it: `claude-md` never loads `AGENTS.md`, `claude-md-and-agents-md`
30
+ loads it beside `CLAUDE.md`, and `managed-only` drops your own and the
31
+ project's instruction files.
21
32
 
22
33
  To give One Code instructions that Claude Code shouldn't read, add an
23
34
  `ONECODE.md`. See [ONECODE.md](sessions-and-context.md#onecodemd).
24
35
 
25
- To generate a `CLAUDE.md` for a project that lacks one, run `/init`. It has
26
- the model survey the project (build, test, and lint commands, layout,
27
- existing AI-tool configuration), ask you about what the code can't answer,
28
- and write the file. It never overwrites an existing `CLAUDE.md` silently.
36
+ To generate a `CLAUDE.md` for a project that lacks one, run `/init`. It sends
37
+ the prompt Claude Code's `/init` sends: the model reads the project and writes
38
+ down how to build, lint, and test it and the big-picture architecture, folding
39
+ in your README and any Cursor, Copilot, or `AGENTS.md` rules. If the project
40
+ already has a `CLAUDE.md`, it suggests improvements instead.
29
41
 
30
42
  ## Skills, commands, and agents
31
43
 
@@ -78,14 +90,17 @@ The keys One Code honors:
78
90
  | `permissions.allow`, `permissions.deny`, `permissions.ask` | All | Project allow rules need one-time approval. See [Permissions](permissions-modes-and-auto-mode.md#permission-rules). |
79
91
  | `permissions.defaultMode` | All | A project file can't select `auto` or `bypassPermissions`. |
80
92
  | `permissions.disableBypassPermissionsMode` | All | `"disable"` refuses bypass mode from any source. |
93
+ | `permissions.blockReadsOutsideWorkingDirectories` | All | `true` makes the read tools refuse paths outside the working directories. See [Reads outside the working directories](permissions-modes-and-auto-mode.md#reads-outside-the-working-directories). |
94
+ | `permissions.additionalDirectories` | All | Project directories need one-time approval. See [Workspace directories](permissions-modes-and-auto-mode.md#workspace-directories). |
81
95
  | `autoMode.*` | User, managed | Never read from project files. See [Configure auto mode](permissions-modes-and-auto-mode.md#configure-auto-mode). |
82
96
  | `hooks` | All | Project hooks need one-time approval. See [Hooks](hooks.md). |
83
97
  | `env.CLAUDE_CODE_SUBAGENT_MODEL` | User, managed | The only `env` key read. |
84
98
  | `enabledPlugins` | All | Later scope wins per plugin. |
85
- | `enabledMcpjsonServers`, `disabledMcpjsonServers`, `enableAllProjectMcpServers` | User, untracked local | Never from a checked-in project file. |
99
+ | `enabledMcpjsonServers`, `enableAllProjectMcpServers` | User | Never from a project file, local included. |
100
+ | `disabledMcpjsonServers` | User, local | |
86
101
  | `mcpServers` | `~/.claude.json`, `.claude/settings.local.json` | |
87
102
 
88
- Not honored: `permissions.additionalDirectories`, other `env` keys,
103
+ Not honored: other `env` keys,
89
104
  `includeCoAuthoredBy`, `apiKeyHelper`, `forceLoginMethod`,
90
105
  `cleanupPeriodDays`, and `spinnerTipsEnabled`. Run `/doctor report` to see,
91
106
  for every file found, which keys were used, ignored, or refused.
@@ -112,6 +127,42 @@ memories. This is the one place One Code writes under `~/.claude`. Run
112
127
  `/memory` to open memory and instruction files. See
113
128
  [Memory](sessions-and-context.md#memory).
114
129
 
130
+ ## Run One Code on its own setup
131
+
132
+ Maybe you don't use Claude Code at all, or you want One Code's
133
+ instructions, agents and memory kept apart from it. Independent mode does
134
+ that: One Code stops reading anything of Claude Code's. No `~/.claude`, no
135
+ project `.claude/`, no `CLAUDE.md`, no `~/.claude.json` or `.mcp.json`, and
136
+ no managed settings either.
137
+
138
+ To switch, run `/memory`, press **↑** to reach the **Config sources** row,
139
+ and press **Enter**. One Code asks first, since this changes everywhere it
140
+ reads configuration from: press **Enter** again to switch, or **Esc** to
141
+ keep the mode you have. The row shows **(from next start)** until you restart
142
+ One Code, because the switch applies to the next session, not the one
143
+ you're in. `/doctor` shows which mode is running.
144
+
145
+ Here's where each mode looks:
146
+
147
+ | What | Claude-compatible (default) | Independent |
148
+ |---|---|---|
149
+ | Instructions | `CLAUDE.md` family, or `AGENTS.md` when there's none; `ONECODE.md` | `AGENTS.md` in every directory; `ONECODE.md` |
150
+ | Skills | `.claude/skills/`, `~/.claude/skills/`, `.agents/skills/`, `~/.agents/skills/`, pi's skills | `.agents/skills/`, `~/.agents/skills/`, pi's skills |
151
+ | Commands, agents, workflows | `.claude/` and `~/.claude/` | `.onecode/` and `~/.onecode/` (`commands/`, `agents/`, `workflows/`) |
152
+ | Settings, hooks, permissions | Claude Code's settings files, managed settings, and One Code's files | One Code's files only: `~/.onecode/settings.json` and the per-repository one |
153
+ | MCP servers | `~/.claude.json`, `.mcp.json`, `.claude/settings.local.json`, pi's `mcp.json` files | pi's `mcp.json` files |
154
+ | Memory | `~/.claude/projects/<slug>/memory/` | `~/.onecode/projects/<slug>/memory/` |
155
+ | Worktrees | `.claude/worktrees/` | `.onecode/worktrees/` |
156
+
157
+ In independent mode, the settings you'd put in `~/.claude/settings.json`
158
+ (permissions, `defaultMode`, hooks, the `env` block, `autoMode`) go in
159
+ `~/.onecode/settings.json` instead, with the same keys. Memories don't move
160
+ between modes, so each mode starts with its own.
161
+
162
+ Independent mode skips managed settings too. If your organization manages
163
+ Claude Code with a policy file, that policy doesn't apply to One Code in
164
+ this mode.
165
+
115
166
  ## What stays separate
116
167
 
117
168
  One Code's own state lives in `~/.onecode`. Everything it saves (a chosen
@@ -23,11 +23,15 @@ Code reads but never writes.
23
23
  | Claude Code user configuration that One Code reads | `~/.claude/settings.json` |
24
24
  | Claude Code project configuration that One Code reads | `.claude/settings.json`, `.claude/settings.local.json` |
25
25
 
26
+ In independent mode One Code doesn't read either Claude Code file; Claude
27
+ Code's settings keys, such as `permissions`, `hooks` and `env`, go in One
28
+ Code's two files instead.
29
+
26
30
  The per-repository slug is derived from the repository root, so worktrees
27
31
  and subdirectories of one repository share one file.
28
32
 
29
- Commands such as `/allow`, `/subagent`, `/auto-mode model`, and the
30
- `/mcp` panel write to One Code's files. Both One Code files are written
33
+ Commands such as `/allow`, `/subagent`, `/auto-mode model`, and the `/mcp`
34
+ panel write to One Code's files. Both One Code files are written
31
35
  atomically; a malformed file is reported rather than overwritten.
32
36
 
33
37
  ### Relocating directories
@@ -35,10 +39,14 @@ atomically; a malformed file is reported rather than overwritten.
35
39
  | Variable | Moves |
36
40
  |---|---|
37
41
  | `ONECODE_STATE_DIR` | One Code's state (default `~/.onecode`). |
38
- | `PI_CODING_AGENT_DIR` | pi's agent directory. The bundled app sets it to `~/.onecode/agent`. |
42
+ | `ONECODE_AGENT_DIR` | pi's agent directory under the bundled app (default `~/.onecode/agent`). |
43
+ | `PI_CODING_AGENT_DIR` | pi's agent directory on your own pi. The bundled app ignores it, so it never touches your own pi's settings. |
39
44
  | `CLAUDE_CONFIG_DIR` | Where Claude Code's user configuration is read from (default `~/.claude`). |
40
45
 
41
- Setting one doesn't move the others.
46
+ Setting one doesn't move the others. Commands the bundled app runs for you
47
+ (the `bash` tool, `!` commands, hooks, MCP servers, and language servers)
48
+ get your own `PI_CODING_AGENT_DIR` back, so a `pi` started from inside a
49
+ session is your own pi, not the app.
42
50
 
43
51
  ## What is stored under ~/.onecode
44
52
 
@@ -46,13 +54,16 @@ Setting one doesn't move the others.
46
54
  |---|---|
47
55
  | `settings.json` | User-wide One Code settings. |
48
56
  | `projects/<slug>/settings.json` | Per-repository settings. |
57
+ | `projects/<slug>/memory/` | Per-repository memory, in independent mode. |
58
+ | `agents/`, `commands/`, `workflows/` | Your agents, slash commands and saved workflows, in independent mode. |
49
59
  | `agent/` | pi's own state under the bundled app: credentials, model catalog, sessions, pi's settings, and One Code's plugin directory (`agent/plugins/`). |
50
60
  | `plans/<name>.md` | Plan files from plan mode. |
61
+ | `artifacts/` | Pages published with the `artifact` tool: `index.html` is the gallery; each `<id>/` holds the current page, its details, and `versions/` with every earlier version. |
51
62
  | `hooks/project-approvals.json` | Which projects' hooks you approved. |
52
63
  | `mcp/project-approvals.json` | Which projects' MCP servers you approved. |
53
64
  | `permissions/project-allow-approvals.json` | Which projects' allow rules you trusted. |
54
- | `mcp-auth/<server>.json` | OAuth tokens for MCP servers, owner-readable only. |
55
- | `cache/artificial-analysis.json` | The cached model-capability snapshot, when a key is set. |
65
+ | `mcp-auth/<server>-<hash>.json` | OAuth tokens for MCP servers, one file per server name, URL and headers, owner-readable only. |
66
+ | `cache/model-catalog/` | The daily copy of the models.dev, OpenRouter and Hugging Face catalogs behind the model tiers. |
56
67
  | `hooks/hooks-decisions.jsonl` | A hook decision log, written only while `CC_HOOKS_DEBUG` is set. |
57
68
 
58
69
  The bundled app also keeps a timestamp of its last update check at
@@ -66,20 +77,27 @@ appear in `projects/<slug>/settings.json`.
66
77
  | Key | Type | Set by | Effect |
67
78
  |---|---|---|---|
68
79
  | `subagentModel` | string | `/subagent` | Default model for subagents and workflow agents: `provider/model-id`, a short alias, or `inherit`. |
80
+ | `suggestNewerModels` | boolean | By hand | Suggest a newer model in the same line at a similar or lower price. Defaults to `true`; `false` turns off notices and the `/doctor` suggestion. |
81
+ | `modelTiers` | object | By hand (user settings only) | Your own tier for a model, keyed by `provider/id` or by the provider's model id alone: `frontier`, `workhorse`, `cheap` or `tiny`. See [Prompting adapts to the model](providers-and-models.md#prompting-adapts-to-the-model). |
82
+ | `refreshModelCatalog` | boolean | By hand | `false` stops the daily refresh of the model catalogs behind the tiers; the copy on disk stays in use. Defaults to `true`. |
69
83
  | `permissions.allow` | string array | `/allow` (per repository) or `/allow … global` | Allow rules in Claude Code's format. |
70
84
  | `autoMode.environment` | string array | `/auto-mode setup` | Describes your environment to the classifier. |
71
85
  | `autoMode.hard_deny`, `autoMode.soft_deny`, `autoMode.allow` | string array | `/auto-mode setup` | Extra classifier rules, appended to the built-ins. |
72
- | `autoMode.classifierModel` | string | `/auto-mode model` | The classifier model. |
73
86
  | `autoMode.classifyAllShell` | boolean | By hand | Send every shell command to the classifier. |
87
+ | `autoMode.classifierModel` | string | `/auto-mode model` | The classifier model, `provider/model-id`, instead of the automatic pick. Read from this file and managed settings only, never from `~/.claude` or a project. |
74
88
  | `autoMode.logDecisions` | boolean | By hand | Log every gate decision next to the session files. |
75
89
  | `webSearch.apiKeys.brave`, `webSearch.apiKeys.tavily` | string | By hand | Search keys when the environment variables are not set. |
76
90
  | `webSearch.order` | string array | By hand | Order of the fallback search backends: `brave`, `tavily`, `exa-free`. |
77
- | `capabilityIndex.artificialAnalysisApiKey` | string | By hand | Artificial Analysis key for measured model selection. |
78
91
  | `disabledMcpServers` | string array | `/mcp` (user or per repository) | MCP servers kept disabled. |
92
+ | `artifacts.autoOpen` | boolean | By hand | `false` stops the browser opening when the model publishes a new artifact. Defaults to `true`. |
93
+ | `enableWorkflows` | boolean | By hand (user or per repository) | `false` turns the `workflow` tool off. Defaults to `true`. |
94
+ | `disableWorkflows` | boolean | By hand (user or per repository) | `true` turns the `workflow` tool off, whatever `enableWorkflows` says. |
95
+ | `workflowSizeGuideline` | string | By hand (user or per repository) | How big the model keeps a workflow: `small` (under 5 agents), `medium` (under 10, the default), `large` (under 50) or `unrestricted`. A guideline, not a limit. |
96
+ | `configMode` | string | `/memory` | `claude-compatible` (the default) or `independent`. Applies from the next start. See [Run One Code on its own setup](bring-your-claude-code-setup.md#run-one-code-on-its-own-setup). |
79
97
 
80
- Two keys are stamped alongside model choices (`subagentModelSetFor`,
81
- `autoMode.classifierModelSetFor`) to record the provider a choice was made
82
- on; leave them alone.
98
+ `subagentModelSetFor` and `autoMode.classifierModelSetFor` are stamped
99
+ alongside the subagent and classifier choices to record the provider each
100
+ was made on; leave them alone.
83
101
 
84
102
  The main model chosen with `/model` is saved in pi's own settings file as
85
103
  `defaultProvider` and `defaultModel`, not in One Code's.
@@ -90,15 +108,20 @@ The bundled app starts in full-screen mode with the `onecode` theme and
90
108
  quiet startup. It sets these on first run in pi's settings and never
91
109
  overrides a value you change later.
92
110
 
93
- On your own pi, to use full-screen mode for one session:
111
+ On your own pi, 1.0 and later start in full-screen mode. On an older pi,
112
+ to use full-screen mode for one session:
94
113
 
95
114
  ```bash
96
115
  pi --tui-mode fullscreen
97
116
  ```
98
117
 
118
+ To keep the terminal's normal screen and scrollback instead, use
119
+ `--tui-mode regular`, or set `"tuiMode": "regular"` in pi's settings.
120
+
99
121
  For a persistent setting, merge these keys into pi's settings file (the
100
122
  first two rows of the table under [Where settings live](#where-settings-live)),
101
- preserving its other keys such as `packages`:
123
+ preserving its other keys such as `packages`. On pi 1.0 and later you can
124
+ leave out `tuiMode`, since full-screen is already the default:
102
125
 
103
126
  ```json
104
127
  {
@@ -122,9 +145,20 @@ Set the subagent default with `/subagent`, or apply a preset with
122
145
  [Providers and models](providers-and-models.md) and
123
146
  [Choose the subagent model](subagents-and-workflows.md#choose-the-subagent-model).
124
147
 
148
+ If you pick a model that has a newer version in the same line, say Qwen 3.6
149
+ 27B when Qwen 3.8 27B exists, One Code tells you when the session starts or
150
+ when you switch models. It only suggests a model you can use with your
151
+ credentials, released later, and priced at most 10% higher (blending three
152
+ input tokens to one output token, since coding work is input-heavy).
153
+
154
+ The notice shows once per session and model, with the `/model` command to
155
+ switch. It never switches for you and never enters the conversation, and
156
+ `/doctor` reports the same suggestion. Print and JSON runs don't show it. To
157
+ turn it off, add `"suggestNewerModels": false` to `~/.onecode/settings.json`.
158
+
125
159
  ## Permission settings
126
160
 
127
- `/permissions` shows the mode and rules, `/allow` adds a rule, and
161
+ `/permissions` opens the permissions panel, `/allow` adds a rule, and
128
162
  `/auto-mode setup` configures the classifier. **ctrl+q** (**alt+m** on Windows and WSL) cycles modes. To
129
163
  start a session in a given mode:
130
164
 
@@ -29,8 +29,16 @@ so nothing surprises you.
29
29
  | Models | Anthropic models. | Any provider pi supports, switchable mid-session, with a different model per role. |
30
30
  | Tool names on the wire | PascalCase (`Read`, `Bash`). | snake_case (`read`, `bash`); `Agent` and `SendMessage` keep their names. Claude Code names still work in rules and hook matchers. |
31
31
  | Permission-mode key | shift+tab. | ctrl+q; alt+m on Windows and WSL. pi reserves shift+tab for the reasoning-effort dial and, on Windows, ctrl+q for queuing a follow-up. |
32
- | Task-list key | ctrl+t. | `/tasks show` and `/tasks hide`. pi reserves ctrl+t for thinking blocks. |
33
- | Deleting files in auto mode | The whole project directory is trusted. | A delete is approved only when git can recover the file; otherwise the classifier decides. |
32
+ | Send queued messages now (**ctrl+x ctrl+s**) | Running tools move to the background, and **ctrl+enter** works too where the terminal sends it. | Running tools are cancelled, and only **ctrl+x ctrl+s** is bound. |
33
+ | Task-list key | ctrl+t. | alt+t; ctrl+\\ on macOS. pi reserves ctrl+t for thinking blocks, and macOS terminals type a character for option+t. |
34
+ | Where auto mode's classifier runs | On Anthropic's API server, through a request field the endpoint must support; the local classifier is a fallback only until about October 23, 2026 ([LiteLLM's notes](https://docs.litellm.ai/blog/claude-code-server-side-auto-mode)). | In the harness, on a model from your own provider, so auto mode works with any provider. |
35
+ | Permission shortcuts by model | One set for every model; auto mode needs a Sonnet- or Opus-class model. | Claude Code's shortcuts for frontier and workhorse models. Cheap and tiny models, which Claude Code can't run in auto mode, get stricter checks. |
36
+ | Deleting files in auto mode | An in-project `rm` runs without the classifier; `git reset --hard` is classified. | The same with frontier and workhorse models. With cheap and tiny models, every delete goes to the classifier. |
37
+ | Reading outside the working directories in auto mode | Runs without the classifier after a one-time question. | The same with frontier and workhorse models, except credential files, which are classified. With cheap and tiny models, the classifier decides. |
38
+ | A path in the project that is a symlink to somewhere outside it, in auto mode | The classifier judges the command as written. | The classifier is also told where the path really leads, so a write to `notes.txt` that lands in `~/.ssh/authorized_keys` is judged as that write. |
39
+ | Approving a call auto mode denied | `/permissions` tells the model permission was granted; the retry is judged again. | The approval lets that exact call run once without the classifier. |
40
+ | Auto-mode built-in rules | A section's built-in rules can be switched off. | Always in effect; your rules only add to them. |
41
+ | Workspace directories | Reads, edits in accept-edits mode, and auto-mode writes. | The same, except that credential files there still prompt. With cheap and tiny models, auto-mode writes there go to the classifier. |
34
42
  | Bypass mode | Protected paths stay protected. | Bypass mode bypasses everything, including protected paths. |
35
43
  | First-run consent for auto mode | Asked once. | Not asked. Auto mode is on from the first session. |
36
44
  | OS sandbox | Paired with auto mode. | None. Run One Code in a container for OS-level isolation. |
@@ -44,11 +52,15 @@ so nothing surprises you.
44
52
  ## Tools that are not provided
45
53
 
46
54
  These Claude Code tools depend on Anthropic-hosted or desktop services and
47
- have no equivalent here: `Artifact`, `ReportFindings`,
48
- `ShareOnboardingGuide`, `PushNotification`, `RemoteTrigger`, `DesignSync`,
49
- `CronCreate`, `CronList`, `CronDelete`, `EndConversation`, and
50
- `SendFeedback`. Scheduling within a session is available through `/loop`
51
- and `schedule_wakeup`; scheduled cloud sessions aren't.
55
+ have no equivalent here: `ReportFindings`, `ShareOnboardingGuide`,
56
+ `PushNotification`, `RemoteTrigger`, `DesignSync`, `EndConversation`, and
57
+ `SendFeedback`. `Artifact` is local: One Code saves the page on your
58
+ machine and opens it in your browser instead of publishing it to claude.ai.
59
+ The page has no runtime capabilities (no shared data, comments, or calls
60
+ back to the model), and there are no artifact types such as slide decks.
61
+ See [Artifacts](tools.md#artifacts). Scheduling within a session is
62
+ available through the cron tools, `/loop`, and `schedule_wakeup`;
63
+ scheduled cloud sessions aren't.
52
64
 
53
65
  The `Agent` tool's remote isolation option isn't implemented.
54
66
 
@@ -56,17 +68,18 @@ The `Agent` tool's remote isolation option isn't implemented.
56
68
 
57
69
  Claude Code commands with no One Code or pi counterpart: `/cost` (the
58
70
  footer shows cost instead), `/status`, `/vim`, `/terminal-setup`, `/bug`,
59
- `/help`, `/rewind`, `/add-dir`, `/hooks`, `/ide`, `/install-github-app`,
71
+ `/help`, `/rewind`, `/hooks`, `/ide`, `/install-github-app`,
60
72
  `/statusline`, `/privacy-settings`, and `/upgrade`. pi's `/changelog` and
61
73
  `/settings` cover part of `/release-notes` and `/config`. `/review` is
62
74
  available through the `commit-commands` plugin when installed.
63
75
 
64
76
  ## Skills that are not bundled
65
77
 
66
- One Code bundles four of Claude Code's built-in skills: `simplify`,
67
- `code-review`, `security-review`, and `fewer-permission-prompts`. It does
68
- not bundle the skills that need Claude Code's hosted or desktop surfaces
69
- (`design`, `dataviz`, the `artifact-*` guides, and the publishers), the
78
+ One Code bundles six of Claude Code's built-in skills: `loop`, `simplify`,
79
+ `code-review`, `security-review`, `fewer-permission-prompts`, and
80
+ `artifact-design` (adapted to local artifacts). It does not bundle the skills
81
+ that need Claude Code's hosted or desktop surfaces (`design`, `dataviz`,
82
+ `artifact-capabilities`, `artifact-diagramming`, and the publishers), the
70
83
  account and desktop skills (`update-config`, `keybindings-help`,
71
84
  `claude-in-chrome`, `debug`, `usage`, `schedule`, `batch`,
72
85
  `claude-code-guide`), the run-skill generators, or the `claude-api`
@@ -83,9 +96,8 @@ action but never pre-approve one. See [Hooks](hooks.md).
83
96
 
84
97
  ## Settings keys that are ignored
85
98
 
86
- `permissions.additionalDirectories` isn't honored. The `env` block is read
87
- only for `CLAUDE_CODE_SUBAGENT_MODEL`, and only from user and managed
88
- scope. `includeCoAuthoredBy`, `apiKeyHelper`, `forceLoginMethod`,
99
+ The `env` block is read only for `CLAUDE_CODE_SUBAGENT_MODEL`, and only
100
+ from user and managed scope. `includeCoAuthoredBy`, `apiKeyHelper`, `forceLoginMethod`,
89
101
  `cleanupPeriodDays`, and `spinnerTipsEnabled` aren't read. Run
90
102
  `/doctor report` to see, per file, which keys were used, ignored, or
91
103
  refused.
@@ -106,11 +118,11 @@ every model. The content is the same; only the placement differs.
106
118
  default on Windows, `CLAUDE_CODE_USE_POWERSHELL_TOOL=0` turns it off), and
107
119
  your `PowerShell(...)` rules, `CLAUDE_CODE_GIT_BASH_PATH`, and per-hook
108
120
  `shell` field work unchanged. The PowerShell tool's description is Claude
109
- Code's own text. What differs: One Code has no PowerShell command parser
110
- yet, so in auto mode every PowerShell command that isn't on Claude Code's
111
- read-only cmdlet list goes to the classifier (Claude Code auto-approves
112
- more in-project work), and the git-recoverability shortcut for in-project
113
- deletes is bash-only. Verified on CI runners and through a `pwsh` on
121
+ Code's own text. PowerShell commands are judged from PowerShell's own
122
+ parse, as in Claude Code. What differs: native commands run from
123
+ PowerShell (`git status`, `npm test`) always go to the classifier in auto
124
+ mode, where Claude Code approves some of them itself. Read-only uses of
125
+ Windows' own `findstr` and `where.exe` are the exceptions. Verified on CI runners and through a `pwsh` on
114
126
  macOS; a real Windows desktop has not been driven end to end yet. See
115
127
  [Windows](windows.md).
116
128
 
@@ -138,9 +150,6 @@ every model. The content is the same; only the placement differs.
138
150
  - Running a skill in a one-shot run (`-p '/simplify'`) delivers the skill
139
151
  but starts no model turn, so the process exits without doing anything.
140
152
  Interactive sessions are unaffected.
141
- - The reasoning effort set with `/effort` doesn't persist across
142
- restarts; the model chosen with `/model` does. To save a level, open
143
- pi's `/thinking` picker and press **ctrl+s**, or pass `--thinking`.
144
153
  - A subagent spawn that is blocked before it starts can leave its requested
145
154
  run name reserved; a retry with the same name is renamed automatically.
146
155
  - Under pi's RPC transport, `SessionStart` hooks fire twice per `/clear`.
@@ -28,10 +28,13 @@ the findings.
28
28
  offers, and where the credential came from. An error when none is
29
29
  ready, with the free options named.
30
30
  3. **Models.** The main model with its price and context window, the
31
- prompt tier it gets, the reasoning effort, the subagent model and how it
32
- was chosen, the auto-mode classifier model, the reader model used by
33
- web fetch and recaps, capability verdicts for each role when an
34
- Artificial Analysis key is set, and the permission mode.
31
+ prompt tier it gets and the rule that set it, the reasoning effort, the
32
+ subagent model and how it was chosen, the auto-mode classifier model and
33
+ your `/auto-mode model` setting, the reader model used by web fetch and
34
+ recaps, how fresh the model catalogs behind the tiers are, and the
35
+ permission mode. A model you chose by hand gets a warning when a newer one
36
+ is available in its line or it's far weaker than your main model, and the
37
+ classifier one also when its context window is smaller than your session's.
35
38
  4. **Presets.** The three model presets for your provider and the model
36
39
  each role would get under each.
37
40
  5. **Imported configuration.** Every settings file found, with the keys One
@@ -53,22 +56,26 @@ In the panel, press **f** to run the checkup on the report you're reading.
53
56
 
54
57
  ## Model presets
55
58
 
56
- A preset sets the main model, the subagent model, and the classifier model
57
- together, from the provider you're connected to. Only current-generation,
58
- priced models that support tool calls are considered.
59
+ A preset sets the main model and subagent model from the provider you're
60
+ connected to, and returns the classifier to the automatic pick. Each preset's
61
+ preview shows the classifier its main model would get (see
62
+ [Automatic model selection](providers-and-models.md#automatic-model-selection)).
63
+ A preset only recommends a main model that's priced, can call tools, and isn't
64
+ replaced by a newer model this provider serves. It also skips any model
65
+ `/doctor` would flag as having a newer version at about the same price, so a
66
+ preset never points you at a model the same report calls outdated.
59
67
 
60
68
  | Preset | Main model | Subagents | Classifier |
61
69
  |---|---|---|---|
62
- | `economical` | The cheapest small model. | Inherit the main model. | Automatic. |
63
- | `balanced` | The cheapest Sonnet-class model. | Chosen automatically (a cheaper Sonnet-class model when one exists, else the main model). | Automatic. |
70
+ | `economical` | The cheapest cheap-tier model, else the cheapest workhorse or frontier one. | Inherit the main model. | Automatic. |
71
+ | `balanced` | The cheapest workhorse- or frontier-tier model. | Chosen automatically (a cheaper model in the main model's tier or above when one exists, else the main model). | Automatic. |
64
72
  | `quality` | The most capable model available. | Inherit the main model. | Automatic. |
65
73
 
66
74
  `/doctor presets` shows what each preset would pick. `/doctor preset balanced`
67
75
  applies one; the aliases `economy`, `cheap`, `balance`, `max`, `maximum`,
68
- and `best` also work. Applying a preset writes the subagent and classifier
69
- choices to `~/.onecode/settings.json` and remembers the main model as pi's
70
- default. Undo any part with `/model`, `/subagent clear`, or
71
- `/auto-mode model clear`.
76
+ and `best` also work. Applying a preset writes the subagent choice to
77
+ `~/.onecode/settings.json` and remembers the main model as pi's
78
+ default. Undo the changes with `/model`, `/subagent clear` or `/auto-mode model`.
72
79
 
73
80
  ## The command-line form
74
81
 
@@ -24,6 +24,12 @@ stored in `~/.onecode/hooks/project-approvals.json` with a hash of the hook
24
24
  configuration, so any change asks again. Declining is remembered for the
25
25
  session only. User, managed, and plugin hooks never prompt.
26
26
 
27
+ Set `disableAllHooks: true` in your user settings to skip user, project, and
28
+ plugin hooks. Managed hooks still run unless managed settings also disable
29
+ hooks, and a managed value always takes precedence. In a project's
30
+ `.claude/settings.json` or `.claude/settings.local.json`, the setting skips only
31
+ that project's own hooks, so a repository you clone can't switch off yours.
32
+
27
33
  Only command hooks are supported. Hook entries of type `http`, `prompt`, or
28
34
  `agent` are skipped with a diagnostic.
29
35
 
@@ -71,7 +77,10 @@ The hook's standard input is a JSON object with these fields:
71
77
  | `reason` | `SessionEnd` | `clear`, `logout`, `prompt_input_exit`, or `other`. |
72
78
  | `agent_id`, `agent_type` | Inside a subagent | Identify the subagent making the call. |
73
79
 
74
- The hook's environment also carries `CLAUDE_PROJECT_DIR`.
80
+ The hook's environment also carries `CLAUDE_PROJECT_DIR`, the parent project
81
+ root. A worktree-isolated child's hooks run in the child's working directory,
82
+ while settings and project-hook approval still come from the parent project.
83
+ Cancelling a turn stops its running hooks and their descendant processes.
75
84
 
76
85
  Hook matchers match on the tool name. Claude Code's PascalCase names work.
77
86
 
@@ -84,13 +93,14 @@ Hook matchers match on the tool name. Claude Code's PascalCase names work.
84
93
  | Exit code 2 | The action is blocked. Standard error is the reason. |
85
94
  | Any other exit code | The hook passes and its output is ignored. |
86
95
  | Timeout | `PreToolUse` and `UserPromptSubmit` block (fail closed). Other events pass. |
96
+ | Output exceeds 1,000,000 bytes on either stream | The command stops. `PreToolUse` and `UserPromptSubmit` block; other events show a notice. Incomplete output is not used as a verdict or context. |
87
97
  | The command could not be started | The hook passes; this is an environment problem, not a verdict. |
88
98
 
89
99
  Envelope fields honored in a JSON result:
90
100
 
91
101
  | Field | Effect |
92
102
  |---|---|
93
- | `continue: false` | Blocks, with `stopReason` as the reason. |
103
+ | `continue: false` | Blocks, with `stopReason` as the reason. For `Stop`, ends the turn without requesting another response. |
94
104
  | `decision: "block"` | Blocks, with `reason` as the reason. |
95
105
  | `hookSpecificOutput.permissionDecision` | `"deny"` and `"ask"` both block, with `permissionDecisionReason`. `"allow"` is read but never honored; a hook can't pre-approve an action, and the permission gate still runs. |
96
106
  | `hookSpecificOutput.updatedInput` | Replaces the tool's input (`PreToolUse`). |
@@ -99,7 +109,12 @@ Envelope fields honored in a JSON result:
99
109
  | `systemMessage` | Shown to you. |
100
110
 
101
111
  A `PreToolUse` block stops the call before the permission gate runs, so no
102
- approval prompt appears for a hook-blocked call.
112
+ approval prompt appears for a hook-blocked call. A malformed response from one
113
+ hook does not discard another hook's denial.
114
+
115
+ A blocking `Stop` hook can request at most eight consecutive continuations per
116
+ user turn. The ninth block ends the turn with a notice. Hooks still receive
117
+ `stop_hook_active` so they can stop requesting continuations earlier.
103
118
 
104
119
  ## Debugging hooks
105
120
 
@@ -102,9 +102,31 @@ pi install npm:one-code-extension
102
102
  ```
103
103
 
104
104
  Use `pi` in place of `onecode` for every command in this guide. The
105
- extension is tested against pi 0.83 through 0.86 and warns at startup when
106
- your pi is outside that range. Full-screen mode is opt-in on your own pi;
107
- see [Full-screen mode and themes](configuration.md#full-screen-mode-and-themes).
105
+ extension is tested against pi 0.84.3 through 1.3 and warns at startup when
106
+ your pi is outside that range. It doesn't load on a pi older than 0.84.3;
107
+ update pi first with `pi update`. pi 1.0 and later start in full-screen mode;
108
+ on an older pi it's opt-in. See
109
+ [Full-screen mode and themes](configuration.md#full-screen-mode-and-themes).
110
+
111
+ pi 0.99 and later ship their own tool search and MCP as built-in
112
+ extensions. One Code brings its own versions of both, so pi skips the
113
+ built-ins and prints a warning about each at every start. The warnings tell
114
+ you to remove the extension that replaced them. Don't: that's One Code. To
115
+ hide them, run `pi config` and turn off `tool-search` and `mcp` under
116
+ Built-in, or add this to `~/.pi/agent/settings.json`:
117
+
118
+ ```json
119
+ {
120
+ "extensions": ["-builtin:tool-search", "-builtin:mcp"]
121
+ }
122
+ ```
123
+
124
+ On the first start where the built-ins are still on, One Code asks whether
125
+ to turn them off for you and explains why. Say yes and it adds those two
126
+ entries to your settings; the warnings stop from the next start. Say no and
127
+ it won't ask again, but it shows a short notice under pi's warnings, and
128
+ `/doctor` can still make the change. The bundled app turns both off on its
129
+ own.
108
130
 
109
131
  A few interface refinements are applied only by the bundled app, because
110
132
  they patch pi internals the extension API can't reach: a clean exit that
@@ -149,7 +171,8 @@ A Homebrew install sees the notice a day after the npm release, because
149
171
  Homebrew refuses packages younger than that and `brew upgrade` would find
150
172
  nothing sooner. Set `ONECODE_NO_UPDATE_CHECK=1` to skip the check;
151
173
  `--offline` skips it too.
152
- On your own pi, update with `pi update --extensions`.
174
+ On your own pi, update the extension with `pi update npm:one-code-extension`.
175
+ A bare `pi update` updates pi itself and skips extensions.
153
176
 
154
177
  Both packages are released together with the same version number.
155
178