@polderlabs/bizar 6.2.4 → 6.3.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 (332) hide show
  1. package/.claude/CLAUDE.md +15 -0
  2. package/.claude/agents/_shared/AGENT_BASELINE.md +168 -0
  3. package/.claude/agents/_shared/CLAUDE_TOOLS.md +412 -0
  4. package/.claude/agents/_shared/SKILLS.md +109 -0
  5. package/.claude/agents/agent-browser.md +80 -0
  6. package/.claude/agents/baldr.md +49 -0
  7. package/.claude/agents/forseti.md +51 -0
  8. package/.claude/agents/frigg.md +42 -0
  9. package/.claude/agents/heimdall.md +33 -0
  10. package/.claude/agents/hermod.md +53 -0
  11. package/.claude/agents/mimir.md +49 -0
  12. package/.claude/agents/odin.md +287 -0
  13. package/.claude/agents/quick.md +34 -0
  14. package/.claude/agents/semble-search.md +50 -0
  15. package/.claude/agents/thor.md +53 -0
  16. package/.claude/agents/tyr.md +56 -0
  17. package/.claude/agents/vidarr.md +54 -0
  18. package/.claude/agents/vor.md +53 -0
  19. package/.claude/commands/audit.md +25 -0
  20. package/.claude/commands/bizar.md +22 -0
  21. package/.claude/commands/explain.md +17 -0
  22. package/.claude/commands/init.md +29 -0
  23. package/.claude/commands/learn.md +44 -0
  24. package/.claude/commands/plan.md +35 -0
  25. package/.claude/commands/plow-through.md +50 -0
  26. package/.claude/commands/pr-review.md +49 -0
  27. package/.claude/commands/setup-provider.md +96 -0
  28. package/.claude/commands/tailscale-serve.md +100 -0
  29. package/.claude/commands/team.md +132 -0
  30. package/.claude/commands/test.md +62 -0
  31. package/.claude/commands/validate.md +68 -0
  32. package/.claude/commands/visual-plan.md +24 -0
  33. package/.claude/hooks/README.md +92 -0
  34. package/.claude/hooks/posttooluse-editwrite.mjs +91 -0
  35. package/.claude/hooks/pretooluse-bash.mjs +81 -0
  36. package/.claude/hooks/pretooluse-editwrite.mjs +139 -0
  37. package/.claude/hooks/sessionend-recall.mjs +74 -0
  38. package/.claude/hooks/sessionstart-prime.mjs +80 -0
  39. package/.claude/hooks/userpromptsubmit-tag.mjs +80 -0
  40. package/.claude/settings.json +116 -0
  41. package/.claude/skills/9router/SKILL.md +80 -0
  42. package/.claude/skills/9router-chat/SKILL.md +73 -0
  43. package/.claude/skills/9router-embeddings/SKILL.md +69 -0
  44. package/.claude/skills/9router-image/SKILL.md +86 -0
  45. package/.claude/skills/9router-stt/SKILL.md +79 -0
  46. package/.claude/skills/9router-tts/SKILL.md +80 -0
  47. package/.claude/skills/9router-web-fetch/SKILL.md +99 -0
  48. package/.claude/skills/9router-web-search/SKILL.md +91 -0
  49. package/.claude/skills/bizar/README.md +9 -0
  50. package/.claude/skills/bizar/SKILL.md +450 -0
  51. package/.claude/skills/cpp-coding-standards/README.md +28 -0
  52. package/.claude/skills/cpp-coding-standards/SKILL.md +634 -0
  53. package/.claude/skills/cpp-coding-standards/references/concurrency.md +320 -0
  54. package/.claude/skills/cpp-coding-standards/references/error-handling.md +229 -0
  55. package/.claude/skills/cpp-coding-standards/references/memory-safety.md +216 -0
  56. package/.claude/skills/cpp-coding-standards/references/modern-idioms.md +282 -0
  57. package/.claude/skills/cpp-coding-standards/references/review-checklist.md +96 -0
  58. package/.claude/skills/cpp-testing/README.md +28 -0
  59. package/.claude/skills/cpp-testing/SKILL.md +304 -0
  60. package/.claude/skills/cpp-testing/references/coverage.md +370 -0
  61. package/.claude/skills/cpp-testing/references/framework-compare.md +175 -0
  62. package/.claude/skills/cpp-testing/references/host-test-for-embedded.md +499 -0
  63. package/.claude/skills/cpp-testing/references/mocking.md +364 -0
  64. package/.claude/skills/cpp-testing/references/tdd-workflow.md +308 -0
  65. package/.claude/skills/cubesandbox/SKILL.md +148 -0
  66. package/.claude/skills/embedded-esp-idf/README.md +41 -0
  67. package/.claude/skills/embedded-esp-idf/SKILL.md +439 -0
  68. package/.claude/skills/embedded-esp-idf/references/freertos-patterns.md +214 -0
  69. package/.claude/skills/embedded-esp-idf/references/host-tests.md +164 -0
  70. package/.claude/skills/embedded-esp-idf/references/idf-py-commands.md +157 -0
  71. package/.claude/skills/embedded-esp-idf/references/kconfig.md +159 -0
  72. package/.claude/skills/embedded-esp-idf/references/logging-discipline.md +118 -0
  73. package/.claude/skills/embedded-esp-idf/references/memory-and-iram.md +137 -0
  74. package/.claude/skills/embedded-esp-idf/references/nvs.md +121 -0
  75. package/.claude/skills/embedded-esp-idf/references/packed-structs.md +192 -0
  76. package/.claude/skills/embedded-esp-idf/scripts/idf_env.sh +47 -0
  77. package/.claude/skills/embedded-esp-idf/scripts/size_check.sh +77 -0
  78. package/.claude/skills/glyph/SKILL.md +163 -0
  79. package/.claude/skills/harness-engineering/SKILL.md +143 -0
  80. package/.claude/skills/lightrag/SKILL.md +81 -0
  81. package/.claude/skills/memory-protocol/SKILL.md +105 -0
  82. package/.claude/skills/obsidian/SKILL.md +306 -0
  83. package/.claude/skills/read-the-damn-docs/SKILL.md +113 -0
  84. package/.claude/skills/self-improvement/SKILL.md +64 -0
  85. package/README.md +87 -59
  86. package/bizar-dash/dist/assets/{EnvVarsSection-DXM8gRm_.js → EnvVarsSection-B58aiJiE.js} +1 -1
  87. package/bizar-dash/dist/assets/{EnvVarsSection-DXM8gRm_.js.map → EnvVarsSection-B58aiJiE.js.map} +1 -1
  88. package/bizar-dash/dist/assets/{MobileChat-BnKN_Ks_.js → MobileChat-BJrqwVDd.js} +1 -1
  89. package/bizar-dash/dist/assets/{MobileChat-BnKN_Ks_.js.map → MobileChat-BJrqwVDd.js.map} +1 -1
  90. package/bizar-dash/dist/assets/{MobileSettings-DjCPxC-Q.js → MobileSettings-CEQNJNLJ.js} +1 -1
  91. package/bizar-dash/dist/assets/{MobileSettings-DjCPxC-Q.js.map → MobileSettings-CEQNJNLJ.js.map} +1 -1
  92. package/bizar-dash/dist/assets/{main-DYiZqMrn.js → main-IvfQAOfy.js} +1 -1
  93. package/bizar-dash/dist/assets/{main-DYiZqMrn.js.map → main-IvfQAOfy.js.map} +1 -1
  94. package/bizar-dash/dist/assets/{markdown-C6mXtQxD.js → markdown-tOLaD6nm.js} +1 -1
  95. package/bizar-dash/dist/assets/{markdown-C6mXtQxD.js.map → markdown-tOLaD6nm.js.map} +1 -1
  96. package/bizar-dash/dist/assets/{mobile-CMHqtLV2.js → mobile-DYCHcUpq.js} +1 -1
  97. package/bizar-dash/dist/assets/{mobile-CMHqtLV2.js.map → mobile-DYCHcUpq.js.map} +1 -1
  98. package/bizar-dash/dist/assets/{mobile-layout-3jIhHX_p.js → mobile-layout-CBHjpwsb.js} +2 -2
  99. package/bizar-dash/dist/assets/{mobile-layout-3jIhHX_p.js.map → mobile-layout-CBHjpwsb.js.map} +1 -1
  100. package/bizar-dash/dist/assets/{useSlashCommands-DtITw8Xv.js → useSlashCommands-Bd7_FA6U.js} +2 -2
  101. package/bizar-dash/dist/assets/{useSlashCommands-DtITw8Xv.js.map → useSlashCommands-Bd7_FA6U.js.map} +1 -1
  102. package/bizar-dash/dist/assets/{vendor-CeHGtduv.js → vendor-C843201K.js} +12 -12
  103. package/bizar-dash/dist/assets/vendor-C843201K.js.map +1 -0
  104. package/bizar-dash/dist/index.html +6 -6
  105. package/bizar-dash/dist/mobile.html +2 -2
  106. package/bizar-dash/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -1
  107. package/bizar-dash/src/server/api.mjs +4 -4
  108. package/bizar-dash/src/server/background-store.mjs +15 -16
  109. package/bizar-dash/src/server/bg-poller.mjs +25 -35
  110. package/bizar-dash/src/server/bg-retry.mjs +66 -194
  111. package/bizar-dash/src/server/claude-bg-spawner.mjs +390 -0
  112. package/bizar-dash/src/server/claude-info.mjs +412 -0
  113. package/bizar-dash/src/server/{cline-runner.mjs → claude-runner.mjs} +53 -48
  114. package/bizar-dash/src/server/claude-sdk.mjs +191 -0
  115. package/bizar-dash/src/server/providers-store.mjs +22 -49
  116. package/bizar-dash/src/server/routes/background.mjs +24 -20
  117. package/bizar-dash/src/server/routes/chat.mjs +223 -326
  118. package/bizar-dash/src/server/routes/claude-session-detail.mjs +329 -0
  119. package/bizar-dash/src/server/routes/claude-sessions.mjs +259 -0
  120. package/bizar-dash/src/server/routes/tasks.mjs +20 -28
  121. package/bizar-dash/src/server/task-delegator.mjs +76 -77
  122. package/bizar-dash/src/web/components/chat/useChat.ts +23 -27
  123. package/bizar-dash/src/web/views/Chat.tsx +8 -8
  124. package/cli/bin.mjs +31 -18
  125. package/cli/commands/claude-cmd.mjs +348 -0
  126. package/cli/commands/install.mjs +12 -11
  127. package/cli/commands/sandbox.mjs +220 -0
  128. package/cli/commands/validate.mjs +252 -288
  129. package/cli/dev-link.test.mjs +11 -11
  130. package/cli/doctor.mjs +131 -213
  131. package/cli/install.mjs +33 -37
  132. package/cli/install.test.mjs +9 -9
  133. package/cli/provision-claude.mjs +893 -0
  134. package/cli/provision.mjs +330 -226
  135. package/cli/provision.test.mjs +102 -0
  136. package/cli/utils.mjs +72 -58
  137. package/config/AGENTS.md +28 -28
  138. package/config/agents/_shared/AGENT_BASELINE.md +104 -684
  139. package/config/skills/bizar/SKILL.md +197 -0
  140. package/config/skills/cubesandbox/SKILL.md +148 -0
  141. package/config/skills/harness-engineering/SKILL.md +142 -0
  142. package/install.sh +66 -44
  143. package/package.json +19 -11
  144. package/packages/sdk/ARCHITECTURE.md +40 -36
  145. package/packages/sdk/package-lock.json +32 -0
  146. package/packages/sdk/package.json +15 -5
  147. package/{plugins/bizar → packages/sdk}/src/dangerous-patterns.ts +6 -28
  148. package/packages/sdk/src/fingerprint.ts +0 -0
  149. package/packages/sdk/src/index.ts +38 -73
  150. package/packages/sdk/src/mcp/bin.ts +51 -0
  151. package/packages/sdk/src/mcp/server.ts +498 -0
  152. package/{plugins/bizar/src/memory-vault.ts → packages/sdk/src/memory/index.ts} +18 -21
  153. package/packages/sdk/tests/sdk.test.mjs +148 -0
  154. package/packages/sdk/vitest.config.ts +1 -1
  155. package/scripts/bh-full-e2e.mjs +166 -363
  156. package/scripts/check-deps.mjs +28 -46
  157. package/scripts/mirror-claude-md.sh +78 -0
  158. package/scripts/test-in-container.sh +157 -0
  159. package/templates/clean-state-checklist.md +3 -3
  160. package/templates/sprint-contract.md +2 -2
  161. package/bizar-dash/.bizar/activity.log +0 -3
  162. package/bizar-dash/.omx/logs/omx-2026-07-07.jsonl +0 -1
  163. package/bizar-dash/.omx/state/session.json +0 -10
  164. package/bizar-dash/bizar-design/EXPLANATION.md +0 -307
  165. package/bizar-dash/bizar-design/INSTRUCTIONS.md +0 -149
  166. package/bizar-dash/bizar-design/canvas.html +0 -281
  167. package/bizar-dash/bizar-design/canvas.html.artifact.json +0 -19
  168. package/bizar-dash/bizar-design/components.css +0 -1665
  169. package/bizar-dash/bizar-design/components.html +0 -557
  170. package/bizar-dash/bizar-design/components.html.artifact.json +0 -19
  171. package/bizar-dash/bizar-design/desktop/agents.html +0 -74
  172. package/bizar-dash/bizar-design/desktop/agents.html.artifact.json +0 -19
  173. package/bizar-dash/bizar-design/desktop/memory.html +0 -75
  174. package/bizar-dash/bizar-design/desktop/memory.html.artifact.json +0 -19
  175. package/bizar-dash/bizar-design/desktop/metrics.html +0 -63
  176. package/bizar-dash/bizar-design/desktop/metrics.html.artifact.json +0 -19
  177. package/bizar-dash/bizar-design/desktop/overview.html +0 -95
  178. package/bizar-dash/bizar-design/desktop/overview.html.artifact.json +0 -19
  179. package/bizar-dash/bizar-design/desktop/settings.html +0 -70
  180. package/bizar-dash/bizar-design/desktop/settings.html.artifact.json +0 -19
  181. package/bizar-dash/bizar-design/icons.svg +0 -44
  182. package/bizar-dash/bizar-design/index.html +0 -192
  183. package/bizar-dash/bizar-design/index.html.artifact.json +0 -19
  184. package/bizar-dash/bizar-design/mobile/agents.html +0 -29
  185. package/bizar-dash/bizar-design/mobile/agents.html.artifact.json +0 -19
  186. package/bizar-dash/bizar-design/mobile/memory.html +0 -28
  187. package/bizar-dash/bizar-design/mobile/memory.html.artifact.json +0 -19
  188. package/bizar-dash/bizar-design/mobile/metrics.html +0 -29
  189. package/bizar-dash/bizar-design/mobile/metrics.html.artifact.json +0 -19
  190. package/bizar-dash/bizar-design/mobile/overview.html +0 -33
  191. package/bizar-dash/bizar-design/mobile/overview.html.artifact.json +0 -19
  192. package/bizar-dash/bizar-design/mobile/settings.html +0 -28
  193. package/bizar-dash/bizar-design/mobile/settings.html.artifact.json +0 -19
  194. package/bizar-dash/bizar-design/prototype.js +0 -114
  195. package/bizar-dash/bizar-design/tokens.css +0 -106
  196. package/bizar-dash/dist/assets/vendor-CeHGtduv.js.map +0 -1
  197. package/bizar-dash/node_modules/.package-lock.json +0 -6
  198. package/bizar-dash/package-lock.json +0 -6
  199. package/bizar-dash/src/server/cline-sdk.mjs +0 -132
  200. package/bizar-dash/src/server/routes/cline-session-detail.mjs +0 -559
  201. package/bizar-dash/src/server/routes/cline-sessions.mjs +0 -291
  202. package/cli/commands/cline-cmd.mjs +0 -289
  203. package/cli/commands/validate.test.mjs +0 -344
  204. package/cli/doctor.test.mjs +0 -350
  205. package/config/cline.json.template +0 -342
  206. package/packages/sdk/src/client.ts +0 -188
  207. package/packages/sdk/src/cline-events.ts +0 -134
  208. package/packages/sdk/src/cline-types.ts +0 -66
  209. package/packages/sdk/src/cline.ts +0 -339
  210. package/packages/sdk/src/errors.ts +0 -129
  211. package/packages/sdk/src/events.ts +0 -153
  212. package/packages/sdk/src/types.ts +0 -176
  213. package/packages/sdk/tests/client.test.ts +0 -217
  214. package/packages/sdk/tests/errors.test.ts +0 -108
  215. package/packages/sdk/tests/events.test.ts +0 -139
  216. package/packages/sdk/tests/fixtures/fetch-mock.ts +0 -152
  217. package/packages/sdk/tests/fixtures/sse-mock.ts +0 -30
  218. package/plugins/bizar/ARCHITECTURE.md +0 -142
  219. package/plugins/bizar/CONSTRAINTS.md +0 -67
  220. package/plugins/bizar/LICENSE +0 -21
  221. package/plugins/bizar/README.md +0 -448
  222. package/plugins/bizar/index.ts +0 -872
  223. package/plugins/bizar/package.json +0 -39
  224. package/plugins/bizar/scripts/check-forbidden-imports.sh +0 -33
  225. package/plugins/bizar/src/background-state.ts +0 -641
  226. package/plugins/bizar/src/background.ts +0 -1806
  227. package/plugins/bizar/src/cline-runner.ts +0 -203
  228. package/plugins/bizar/src/clineruntime.ts +0 -227
  229. package/plugins/bizar/src/commands-impl.ts +0 -151
  230. package/plugins/bizar/src/commands.ts +0 -1799
  231. package/plugins/bizar/src/compaction.d.mts +0 -48
  232. package/plugins/bizar/src/compaction.mjs +0 -192
  233. package/plugins/bizar/src/dashboard-client.ts +0 -233
  234. package/plugins/bizar/src/event-stream.ts +0 -606
  235. package/plugins/bizar/src/fingerprint.ts +0 -120
  236. package/plugins/bizar/src/handoff.ts +0 -79
  237. package/plugins/bizar/src/hooks/memory-flush-on-compact.ts +0 -123
  238. package/plugins/bizar/src/hooks/memory-inject.ts +0 -247
  239. package/plugins/bizar/src/hooks/memory-write-on-end.ts +0 -188
  240. package/plugins/bizar/src/hooks/skill-curator.ts +0 -180
  241. package/plugins/bizar/src/http-client.ts +0 -467
  242. package/plugins/bizar/src/key-rotation.ts +0 -218
  243. package/plugins/bizar/src/logger.ts +0 -144
  244. package/plugins/bizar/src/loop-engineering.ts +0 -241
  245. package/plugins/bizar/src/loop.ts +0 -176
  246. package/plugins/bizar/src/mistake-recovery.ts +0 -98
  247. package/plugins/bizar/src/odin.ts +0 -227
  248. package/plugins/bizar/src/options.ts +0 -470
  249. package/plugins/bizar/src/plan-fs.ts +0 -323
  250. package/plugins/bizar/src/reasoning-clean.ts +0 -454
  251. package/plugins/bizar/src/report.ts +0 -178
  252. package/plugins/bizar/src/research-prompt.ts +0 -35
  253. package/plugins/bizar/src/serve-info.ts +0 -228
  254. package/plugins/bizar/src/serve.ts +0 -496
  255. package/plugins/bizar/src/settings.ts +0 -349
  256. package/plugins/bizar/src/state.ts +0 -298
  257. package/plugins/bizar/src/tool-discipline.ts +0 -105
  258. package/plugins/bizar/src/tools/agent-browser.ts +0 -315
  259. package/plugins/bizar/src/tools/bg-collect.ts +0 -131
  260. package/plugins/bizar/src/tools/bg-get-comments.ts +0 -266
  261. package/plugins/bizar/src/tools/bg-kill.ts +0 -116
  262. package/plugins/bizar/src/tools/bg-pause.ts +0 -99
  263. package/plugins/bizar/src/tools/bg-report-progress.ts +0 -115
  264. package/plugins/bizar/src/tools/bg-resume.ts +0 -94
  265. package/plugins/bizar/src/tools/bg-send-message.ts +0 -223
  266. package/plugins/bizar/src/tools/bg-spawn.ts +0 -502
  267. package/plugins/bizar/src/tools/bg-status.ts +0 -130
  268. package/plugins/bizar/src/tools/graph-query.ts +0 -278
  269. package/plugins/bizar/src/tools/loop-engineering.ts +0 -193
  270. package/plugins/bizar/src/tools/memory-list.ts +0 -43
  271. package/plugins/bizar/src/tools/memory-read.ts +0 -69
  272. package/plugins/bizar/src/tools/memory-search.ts +0 -47
  273. package/plugins/bizar/src/tools/memory-write.ts +0 -54
  274. package/plugins/bizar/src/tools/open-kb.ts +0 -198
  275. package/plugins/bizar/src/tools/plan-action.ts +0 -785
  276. package/plugins/bizar/src/tools/read-glyph-feedback.ts +0 -191
  277. package/plugins/bizar/src/tools/team-spawn.ts +0 -73
  278. package/plugins/bizar/src/tools/team-status.ts +0 -76
  279. package/plugins/bizar/src/tools/wait-for-feedback.ts +0 -415
  280. package/plugins/bizar/src/trajectory.ts +0 -104
  281. package/plugins/bizar/tests/README.md +0 -99
  282. package/plugins/bizar/tests/attach-handler-bug.test.ts +0 -169
  283. package/plugins/bizar/tests/background-state.test.ts +0 -277
  284. package/plugins/bizar/tests/background.test.ts +0 -402
  285. package/plugins/bizar/tests/block.test.ts +0 -195
  286. package/plugins/bizar/tests/canonical-key-order.test.ts +0 -75
  287. package/plugins/bizar/tests/clineruntime-config.test.ts +0 -283
  288. package/plugins/bizar/tests/commands-impl.test.ts +0 -316
  289. package/plugins/bizar/tests/commands.test.ts +0 -584
  290. package/plugins/bizar/tests/compaction.test.ts +0 -264
  291. package/plugins/bizar/tests/config.test.ts +0 -128
  292. package/plugins/bizar/tests/dashboard-client.test.ts +0 -159
  293. package/plugins/bizar/tests/dispose.test.ts +0 -336
  294. package/plugins/bizar/tests/event-stream.test.ts +0 -409
  295. package/plugins/bizar/tests/event.test.ts +0 -262
  296. package/plugins/bizar/tests/fingerprint.test.ts +0 -162
  297. package/plugins/bizar/tests/http-client.test.ts +0 -404
  298. package/plugins/bizar/tests/init-helpers.test.ts +0 -203
  299. package/plugins/bizar/tests/integration/slash-command.test.ts +0 -349
  300. package/plugins/bizar/tests/integration/tool-routing.test.ts +0 -98
  301. package/plugins/bizar/tests/key-rotation.test.ts +0 -396
  302. package/plugins/bizar/tests/loop-engineering.test.ts +0 -168
  303. package/plugins/bizar/tests/loop.test.ts +0 -397
  304. package/plugins/bizar/tests/memory-write-on-end.test.ts +0 -92
  305. package/plugins/bizar/tests/mistake-recovery.test.ts +0 -116
  306. package/plugins/bizar/tests/odin.test.ts +0 -125
  307. package/plugins/bizar/tests/options.test.ts +0 -329
  308. package/plugins/bizar/tests/reasoning-clean.test.ts +0 -422
  309. package/plugins/bizar/tests/safety.test.ts +0 -256
  310. package/plugins/bizar/tests/serve.test.ts +0 -339
  311. package/plugins/bizar/tests/settings.test.ts +0 -351
  312. package/plugins/bizar/tests/stall-think.test.ts +0 -750
  313. package/plugins/bizar/tests/state.test.ts +0 -276
  314. package/plugins/bizar/tests/tool-discipline.test.ts +0 -77
  315. package/plugins/bizar/tests/tools/agent-browser.test.ts +0 -98
  316. package/plugins/bizar/tests/tools/bg-collect.test.ts +0 -337
  317. package/plugins/bizar/tests/tools/bg-get-comments.test.ts +0 -485
  318. package/plugins/bizar/tests/tools/bg-kill.test.ts +0 -235
  319. package/plugins/bizar/tests/tools/bg-pause.test.ts +0 -61
  320. package/plugins/bizar/tests/tools/bg-report-progress.test.ts +0 -79
  321. package/plugins/bizar/tests/tools/bg-resume.test.ts +0 -40
  322. package/plugins/bizar/tests/tools/bg-send-message.test.ts +0 -116
  323. package/plugins/bizar/tests/tools/bg-spawn-delegation.test.ts +0 -147
  324. package/plugins/bizar/tests/tools/bg-spawn-http.test.ts +0 -233
  325. package/plugins/bizar/tests/tools/bg-spawn.test.ts +0 -311
  326. package/plugins/bizar/tests/tools/bg-status.test.ts +0 -217
  327. package/plugins/bizar/tests/tools/cline-runner.test.ts +0 -115
  328. package/plugins/bizar/tests/tools/plan-action.test.ts +0 -599
  329. package/plugins/bizar/tests/tools/read-glyph-feedback.test.ts +0 -253
  330. package/plugins/bizar/tests/tools/wait-for-feedback.test.ts +0 -390
  331. package/plugins/bizar/tests/update-deadlock.test.ts +0 -151
  332. package/plugins/bizar/tsconfig.json +0 -29
package/cli/provision.mjs CHANGED
@@ -1,16 +1,13 @@
1
1
  /**
2
2
  * cli/provision.mjs
3
3
  *
4
- * v4.4.7 — Unified installer + updater.
4
+ * v6.3.0 — Unified installer + updater (Claude Code-native).
5
5
  *
6
6
  * `bizar install` and `bizar update` used to be two separate code paths
7
7
  * (install.sh + cli/install.mjs for install, cli/update.mjs for update)
8
- * with massive overlap: both copied agents, both patched cline.json,
8
+ * with massive overlap: both copied agents, both patched settings.json,
9
9
  * both ran the plugin copy, both kicked off the service, both called
10
- * `bizar doctor` at the end. The two paths diverged over time, and the
11
- * user-visible bug was that `update` tried to install separate npm
12
- * packages (@polderlabs/bizar-plugin, @polderlabs/bizar-dash) that no
13
- * longer exist.
10
+ * `bizar doctor` at the end. The two paths diverged over time.
14
11
  *
15
12
  * This module is the single source of truth. Both `bizar install` and
16
13
  * `bizar update` call `runProvision({ mode, ... })`. The differences
@@ -21,9 +18,10 @@
21
18
  * doctor. Does NOT kill running instances (fresh install
22
19
  * has none).
23
20
  * update: refresh an existing install. Kills running instances,
24
- * upgrades @polderlabs/bizar + cline via npm, re-copies
25
- * agent files / plugin / skills, re-patches cline.json
26
- * (idempotent), restarts the dashboard, runs doctor.
21
+ * upgrades @polderlabs/bizar + @anthropic-ai/claude-code via
22
+ * npm, re-copies agent files / skills / commands, re-patches
23
+ * ~/.claude/settings.json (idempotent), restarts the
24
+ * dashboard, runs doctor.
27
25
  *
28
26
  * Both modes are safe to re-run — every step is idempotent and skips
29
27
  * work that's already done.
@@ -58,55 +56,57 @@ export const PKG_MAIN = '@polderlabs/bizar';
58
56
  export const BIZAR_HOME = bizarConfigDir();
59
57
 
60
58
  /**
61
- * Resolve the Cline config directory.
59
+ * Resolve the Claude Code config directory.
62
60
  *
63
- * Cline (v3.0+) uses `~/.cline/` (or `$CLINE_DIR`) as the global config dir
64
- * for `agents/`, `skills/`, `plugins/`, `hooks/`, `rules/`, `workflows/`.
65
- * It also checks `~/.agents/skills/` for global agents, and
66
- * `~/Documents/Cline/{Plugins,Hooks,Rules,Workflows,Agents}/` as a
67
- * Documents-side mirror.
61
+ * Claude Code (v1.0+) uses `~/.claude/` (or `$CLAUDE_CONFIG_DIR`) as the
62
+ * global config dir for `agents/`, `skills/`, `plugins/`, `commands/`,
63
+ * `hooks/`, and `settings.json`.
68
64
  *
69
- * v4.4.7–v5.6.0 of this provisioner hard-coded `~/.config/cline/`, which was
70
- * the OpenCode layout. After the Phase-1 Cline migration (v5.6.0-beta.9),
71
- * agents/commands/skills were still being written to `~/.config/cline/` and
72
- * silently invisible to the `cline` CLI. Fixed in v5.6.0-beta.12.
65
+ * Resolution order (matches Claude Code's configuration discovery):
66
+ * 1. `process.env.CLAUDE_CONFIG_DIR` (explicit override)
67
+ * 2. `$HOME/.claude` (the Claude Code default)
68
+ * 3. (Windows only) `%USERPROFILE%/.claude`
73
69
  *
74
- * Resolution order (matches Cline's `resolveClineDir()` in
75
- * `@cline/shared/dist/storage/index.js`):
76
- * 1. `process.env.CLINE_DIR` (explicit override)
77
- * 2. `$HOME/.cline` (the Cline default — matches `cline config --config` discovery)
78
- * 3. (Windows only) `%APPDATA%\cline`
79
- *
80
- * `BIZAR_LEGACY_CLINE_DIR=1` opts back into the old `~/.config/cline/`
81
- * layout for users who deliberately want the legacy path.
70
+ * `BIZAR_LEGACY_CLAUDE_DIR=1` opts back into the old Cline layout
71
+ * (`~/.config/cline/`) for users who deliberately want the legacy path.
72
+ * Removed in v6.3.0 Claude Code is the only supported backend.
82
73
  */
83
- function resolveClineDir() {
84
- if (process.env.BIZAR_LEGACY_CLINE_DIR === '1') {
74
+ function resolveClaudeDir() {
75
+ if (process.env.BIZAR_LEGACY_CLAUDE_DIR === '1') {
85
76
  return join(
86
77
  process.env.XDG_CONFIG_HOME || join(HOME, '.config'),
87
78
  'cline',
88
79
  );
89
80
  }
90
- if (process.env.CLINE_DIR && process.env.CLINE_DIR.trim()) {
91
- return process.env.CLINE_DIR.trim();
81
+ if (process.env.CLAUDE_CONFIG_DIR && process.env.CLAUDE_CONFIG_DIR.trim()) {
82
+ return process.env.CLAUDE_CONFIG_DIR.trim();
92
83
  }
93
84
  if (process.platform === 'win32') {
94
- return join(process.env.APPDATA || HOME, 'cline');
85
+ return join(HOME, '.claude');
95
86
  }
96
- return join(HOME, '.cline');
87
+ return join(HOME, '.claude');
97
88
  }
98
89
 
99
- export const CLINE_DIR = resolveClineDir();
90
+ /**
91
+ * Compatibility export — many existing checks still reference this name.
92
+ * @deprecated Use `CLAUDE_DIR` instead.
93
+ */
94
+ export const CLAUDE_DIR = resolveClaudeDir();
95
+
96
+ /**
97
+ * Back-compat alias used by other modules + scripts.
98
+ * Same value as CLAUDE_DIR; kept so old imports still resolve.
99
+ * @deprecated Use `CLAUDE_DIR` instead.
100
+ */
101
+ export const CLINE_DIR = resolveClaudeDir();
100
102
 
101
103
  /**
102
104
  * Legacy Cline directory (the old OpenCode layout).
103
105
  *
104
- * Kept as an opt-in fallback for users who already have agents/commands/
105
- * skills installed under `~/.config/cline/` and want to keep using them
106
- * there. The installer writes new content to `CLINE_DIR` (current Cline
107
- * default) but still emits a warning if `LEGACY_CLINE_DIR` exists.
106
+ * Kept as an opt-in fallback. The installer warns but does not write
107
+ * here under the v6.3.0 Claude Code-native flow.
108
108
  */
109
- export const LEGACY_CLINE_DIR = join(
109
+ export const LEGACY_CLAUDE_DIR = join(
110
110
  process.env.XDG_CONFIG_HOME || join(HOME, '.config'),
111
111
  'cline',
112
112
  );
@@ -237,6 +237,73 @@ export function writeInstallMarker({ version, repoPath, serviceUnit }) {
237
237
  }
238
238
  }
239
239
 
240
+ /**
241
+ * v6.2.5 - Register every `config/skills/<name>/SKILL.md` in
242
+ * `${agentsDir}/.skill-lock.json` so Cline's marketplace UI
243
+ * (`isMarketplaceSkillInstalled`) actually shows them as installed.
244
+ *
245
+ * Cline reads `~/.agents/.skill-lock.json` as its source of truth for
246
+ * skill installation state. The Bizar harness mirrors SKILL.md files
247
+ * to both `~/.cline/skills/` and `~/.agents/skills/`, but Cline still
248
+ * shows "No skills installed" in the Skills tab until each entry is
249
+ * registered here. Verified via `npx skills list -g` (writes the entry
250
+ * then the skill appears).
251
+ *
252
+ * Idempotent: entries already tagged `source: 'bizar/builtin'` only
253
+ * get their `updatedAt` refreshed; user-installed skills (any other
254
+ * source) are never touched.
255
+ *
256
+ * @param {object} opts
257
+ * @param {string} opts.skillsSrc - directory containing config/skills/<name>
258
+ * @param {string} opts.agentsDir - typically HOME/.agents
259
+ * @returns {{ok: boolean, count: number, path: string}}
260
+ */
261
+ export function writeBizarSkillLock({ skillsSrc, agentsDir }) {
262
+ if (!existsSync(skillsSrc)) {
263
+ return { ok: true, count: 0, path: join(agentsDir, '.skill-lock.json') };
264
+ }
265
+ const lockPath = join(agentsDir, '.skill-lock.json');
266
+ let lock = { version: 3, skills: {} };
267
+ try {
268
+ const raw = readFileSync(lockPath, 'utf8');
269
+ lock = JSON.parse(raw);
270
+ if (!lock.skills || typeof lock.skills !== 'object') lock.skills = {};
271
+ if (typeof lock.version !== 'number') lock.version = 3;
272
+ } catch {
273
+ // first install - start fresh
274
+ }
275
+ const now = new Date().toISOString();
276
+ let count = 0;
277
+ for (const skillDir of readdirSync(skillsSrc, { withFileTypes: true })) {
278
+ if (!skillDir.isDirectory()) continue;
279
+ const name = skillDir.name;
280
+ const existing = lock.skills[name];
281
+ if (existing && existing.source === 'bizar/builtin') {
282
+ existing.updatedAt = now;
283
+ count += 1;
284
+ continue;
285
+ }
286
+ lock.skills[name] = {
287
+ source: 'bizar/builtin',
288
+ sourceType: 'local',
289
+ sourceUrl: 'https://github.com/DrB0rk/BizarHarness',
290
+ skillPath: 'config/skills/' + name + '/SKILL.md',
291
+ skillFolderHash: 'bizar-managed',
292
+ pluginName: 'bizar',
293
+ installedAt: existing && existing.installedAt ? existing.installedAt : now,
294
+ updatedAt: now,
295
+ };
296
+ count += 1;
297
+ }
298
+ try {
299
+ mkdirSync(agentsDir, { recursive: true });
300
+ writeFileSync(lockPath, JSON.stringify(lock, null, 2));
301
+ return { ok: true, count, path: lockPath };
302
+ } catch (err) {
303
+ return { ok: false, count: 0, path: lockPath, error: err.message };
304
+ }
305
+ }
306
+
240
307
  // ─── State detection ──────────────────────────────────────────────────────────
241
308
 
242
309
  /**
@@ -252,7 +319,7 @@ export function writeInstallMarker({ version, repoPath, serviceUnit }) {
252
319
  * clineJson: { path, hasPluginEntry, exists },
253
320
  * service: { installed, running, unitPath },
254
321
  * dashboard: { running, pid, port },
255
- * clineCli: { version, latest },
322
+ * claudeCli: { version, latest },
256
323
  * headsUpState: { ok, blockerCount, warningCount },
257
324
  * gitRepo: boolean, // are we running from a git checkout?
258
325
  * }
@@ -298,9 +365,9 @@ export function detectState({ cwd = process.cwd() } = {}) {
298
365
  const pkgVersion = globalRoot ? currentVersion(PKG_MAIN) : null;
299
366
  const pkgLatest = latestVersion(PKG_MAIN);
300
367
 
301
- // ── Plugin copy (deployed to ${CLINE_DIR}/plugins/bizar) ──
368
+ // ── Plugin copy (deployed to ${CLAUDE_DIR}/plugins/bizar) ──
302
369
  const pluginSourceDir = pkgRoot ? join(pkgRoot, 'plugins', 'bizar') : null;
303
- const pluginDestDir = join(CLINE_DIR, 'plugins', 'bizar');
370
+ const pluginDestDir = join(CLAUDE_DIR, 'plugins', 'bizar');
304
371
  let pluginInstalled = false;
305
372
  let pluginUpToDate = false;
306
373
  let pluginSymlink = false;
@@ -325,13 +392,12 @@ export function detectState({ cwd = process.cwd() } = {}) {
325
392
  }
326
393
 
327
394
  // ── cline.json plugin entry ───────────────────────────────────────
328
- const clineJsonPath = join(CLINE_DIR, 'cline.json');
329
- const clineJson = readJsonSafe(clineJsonPath, null);
330
- let hasPluginEntry = false;
331
- if (clineJson && Array.isArray(clineJson.plugin)) {
332
- hasPluginEntry = clineJson.plugin.some(
333
- (p) => Array.isArray(p) && typeof p[0] === 'string' && p[0].includes('plugins/bizar'),
334
- );
395
+ // v6.3.0 Read Claude Code settings.json (replaces cline.json).
396
+ const claudeSettingsPath = join(CLAUDE_DIR, 'settings.json');
397
+ const claudeSettings = readJsonSafe(claudeSettingsPath, null);
398
+ let hasMcpServerEntry = false;
399
+ if (claudeSettings && claudeSettings.mcpServers && typeof claudeSettings.mcpServers === 'object') {
400
+ hasMcpServerEntry = !!claudeSettings.mcpServers.bizar;
335
401
  }
336
402
 
337
403
  // ── Background service ─────────────────────────────────────────────
@@ -351,10 +417,10 @@ export function detectState({ cwd = process.cwd() } = {}) {
351
417
  const dashboardPid = readLivePid(DASHBOARD_PID_FILE);
352
418
  const dashboardPort = parseInt(readTextSafe(DASHBOARD_PORT_FILE, '').trim(), 10) || null;
353
419
 
354
- // ── cline CLI version ───────────────────────────────────────────
355
- const clineCli = {
356
- version: currentVersion('cline'),
357
- latest: latestVersion('cline'),
420
+ // ── Claude Code CLI version ────────────────────────────────────────
421
+ const claudeCli = {
422
+ version: currentVersion('@anthropic-ai/claude-code'),
423
+ latest: latestVersion('@anthropic-ai/claude-code'),
358
424
  };
359
425
 
360
426
  // ── Heads-up gate (.bizar/PRE_PUSH_NOTES.md) ───────────────────────
@@ -388,10 +454,10 @@ export function detectState({ cwd = process.cwd() } = {}) {
388
454
  upToDate: pluginUpToDate,
389
455
  symlink: pluginSymlink,
390
456
  },
391
- clineJson: {
392
- path: clineJsonPath,
393
- exists: !!clineJson,
394
- hasPluginEntry,
457
+ claudeSettings: {
458
+ path: claudeSettingsPath,
459
+ exists: !!claudeSettings,
460
+ hasMcpServerEntry,
395
461
  },
396
462
  service: {
397
463
  installed: serviceInstalled,
@@ -404,7 +470,7 @@ export function detectState({ cwd = process.cwd() } = {}) {
404
470
  pid: dashboardPid,
405
471
  port: dashboardPort,
406
472
  },
407
- clineCli,
473
+ claudeCli,
408
474
  headsUpState,
409
475
  gitRepo,
410
476
  installedMods,
@@ -559,40 +625,53 @@ export async function ensureNpmPackage(pkg, { mode, dryRun, force }) {
559
625
  }
560
626
 
561
627
  export async function updateClineCli({ dryRun, force }) {
562
- const current = currentVersion('cline');
563
- const latest = latestVersion('cline');
628
+ // v6.3.0 Back-compat alias. The new code path upgrades the
629
+ // `@anthropic-ai/claude-code` npm package instead of `cline`.
630
+ return updateClaudeCodeCli({ dryRun, force });
631
+ }
632
+
633
+ export async function updateClaudeCodeCli({ dryRun, force }) {
634
+ const current = currentVersion('@anthropic-ai/claude-code');
635
+ const latest = latestVersion('@anthropic-ai/claude-code');
564
636
 
565
637
  if (current && current === latest && !force) {
566
- return { ok: true, message: `cline@${current} up to date`, installed: current };
638
+ return {
639
+ ok: true,
640
+ message: `@anthropic-ai/claude-code@${current} up to date`,
641
+ installed: current,
642
+ };
567
643
  }
568
644
 
569
645
  if (dryRun) {
570
- return { ok: true, message: '[dry-run] cline upgrade' };
646
+ return { ok: true, message: '[dry-run] @anthropic-ai/claude-code upgrade' };
571
647
  }
572
648
 
573
- // Prefer the upstream installer (`cline upgrade`). Falls back to npm.
574
- const r1 = spawnSync('cline', ['upgrade'], { stdio: 'inherit' });
575
- if (r1.status === 0) {
576
- return { ok: true, message: 'cline updated via `cline upgrade`' };
577
- }
578
- console.log(chalk.dim(' cline upgrade not available; falling back to npm'));
579
- const npm2Args = ['install', '-g', 'cline@latest'];
649
+ // Claude Code ships via npm; `claude upgrade` is not a built-in
650
+ // subcommand. Always go through npm.
651
+ const npmArgs = ['install', '-g', '@anthropic-ai/claude-code@latest'];
580
652
  if (process.env.NPM_CONFIG_PREFIX) {
581
- npm2Args.push('--prefix', process.env.NPM_CONFIG_PREFIX);
653
+ npmArgs.push('--prefix', process.env.NPM_CONFIG_PREFIX);
582
654
  }
583
- const r2 = spawnSync('npm', npm2Args, { stdio: 'inherit', timeout: 600000 });
584
- if (r2.status === null && r2.error?.code === 'ETIMEDOUT') {
585
- return { ok: false, message: 'cline install timed out after 10 minutes' };
655
+ const r = spawnSync('npm', npmArgs, { stdio: 'inherit', timeout: 600000 });
656
+ if (r.status === null && r.error?.code === 'ETIMEDOUT') {
657
+ return {
658
+ ok: false,
659
+ message: '@anthropic-ai/claude-code install timed out after 10 minutes',
660
+ };
586
661
  }
587
- if (r2.status === 0) {
588
- return { ok: true, message: 'cline updated via npm' };
662
+ if (r.status !== 0) {
663
+ return { ok: false, message: '@anthropic-ai/claude-code install failed' };
589
664
  }
590
- return { ok: false, message: 'cline update failed' };
665
+ return {
666
+ ok: true,
667
+ message: '@anthropic-ai/claude-code updated',
668
+ installed: latestVersion('@anthropic-ai/claude-code'),
669
+ };
591
670
  }
592
671
 
593
672
  /**
594
673
  * Copy `plugins/bizar/` from the npm-installed package into
595
- * `${CLINE_DIR}/plugins/bizar/`. Skips if the dest is a dev symlink
674
+ * `${CLAUDE_DIR}/plugins/bizar/`. Skips if the dest is a dev symlink
596
675
  * (set by `bizar dev-link`). Idempotent — safe to re-run.
597
676
  *
598
677
  * Bug history (v5.6.0-beta.12): the cp filter used to be
@@ -620,31 +699,27 @@ export async function copyPluginToCline({ dryRun, force }) {
620
699
  };
621
700
  }
622
701
 
623
- // v5.6.0-beta.14: require a package.json with a `cline` field before
624
- // copying. Per https://docs.cline.bot/customization/plugins without
625
- // the `cline.plugins` manifest, Cline falls back to recursive
626
- // auto-discovery and tries to load every .ts file in the plugin tree
627
- // (including `src/tools/*.ts`, `tests/*.test.ts`) as a plugin module,
628
- // which produces ~100 `Invalid plugin module` errors at startup.
629
- // Refuse to copy a plugin that isn't actually a Cline plugin.
702
+ // v6.3.0 Claude Code uses MCP servers, not the legacy Cline
703
+ // plugin manifest. The Bizar SDK ships under packages/sdk/ and is
704
+ // registered in ~/.claude/settings.json as `mcpServers.bizar`. The
705
+ // plugins/bizar/ tree is now a thin shim that re-exports the SDK,
706
+ // and we no longer copy it into ${CLAUDE_DIR}/plugins/bizar/.
707
+ // We only verify that the source has a package.json (sanity check).
630
708
  const pkgJsonPath = join(src, 'package.json');
631
709
  if (!existsSync(pkgJsonPath)) {
632
710
  return {
633
711
  ok: false,
634
712
  message:
635
713
  `plugin source missing package.json at ${pkgJsonPath} — ` +
636
- `rebuild @polderlabs/bizar (the plugin must ship a cline field)`,
714
+ `rebuild @polderlabs/bizar`,
637
715
  };
638
716
  }
639
717
  try {
640
718
  const pkg = JSON.parse(readFileSync(pkgJsonPath, 'utf8'));
641
- if (!pkg.cline?.plugins?.length) {
719
+ if (!pkg.name) {
642
720
  return {
643
721
  ok: false,
644
- message:
645
- `plugin package.json at ${pkgJsonPath} is missing the ` +
646
- 'cline.plugins manifest required by Cline — see ' +
647
- 'https://docs.cline.bot/customization/plugins',
722
+ message: `plugin package.json at ${pkgJsonPath} is missing required 'name' field`,
648
723
  };
649
724
  }
650
725
  } catch (err) {
@@ -721,7 +796,7 @@ export async function copyPluginToCline({ dryRun, force }) {
721
796
 
722
797
  // Copy the SDK into the deployed plugin's node_modules so Bun can
723
798
  // resolve @polderlabs/bizar-sdk when loading the plugin from
724
- // ${CLINE_DIR}/plugins/bizar/.
799
+ // ${CLAUDE_DIR}/plugins/bizar/.
725
800
  const sdkSrc = join(state.pkgRoot, 'node_modules', '@polderlabs', 'bizar-sdk');
726
801
  const sdkDst = join(dest, 'node_modules', '@polderlabs', 'bizar-sdk');
727
802
  if (existsSync(sdkSrc)) {
@@ -729,16 +804,18 @@ export async function copyPluginToCline({ dryRun, force }) {
729
804
  await cp(sdkSrc, sdkDst, { recursive: true });
730
805
  }
731
806
 
732
- // Wire runtime deps (`zod`, `@cline/*`) into the deployed plugin's
733
- // node_modules/ so Bun's module resolver finds them when loading the
734
- // plugin from ${CLINE_DIR}/plugins/bizar/. Without this, the plugin
735
- // throws "Cannot find module 'zod' (+2 more)" at startup.
807
+ // Wire runtime deps (`zod`, `@anthropic-ai/claude-agent-sdk`) into
808
+ // the deployed plugin's node_modules/ so Bun's module resolver
809
+ // finds them when loading the plugin from
810
+ // ${CLAUDE_DIR}/plugins/bizar/. Without this, the plugin throws
811
+ // "Cannot find module 'zod' (+2 more)" at startup.
736
812
  //
737
813
  // The resolution logic lives in `cli/plugin-runtime-deps.mjs` and is
738
814
  // shared with the legacy installer (`cli/install.mjs`). It searches
739
- // the Bizar npm pkg's own `node_modules/`, then the `cline` npm
740
- // pkg's `node_modules/`, then the dev source tree. Symlinks are
741
- // preferred; recursive copy is the fallback.
815
+ // the Bizar npm pkg's own `node_modules/`, then the
816
+ // `@anthropic-ai/claude-code` npm pkg's `node_modules/`, then the
817
+ // dev source tree. Symlinks are preferred; recursive copy is the
818
+ // fallback.
742
819
  //
743
820
  // Only wire when the plugin entry is a `.ts` source file. If the
744
821
  // plugin ships a pre-bundled `dist/index.js`, the runtime deps are
@@ -827,155 +904,134 @@ function readdirSyncSafe(p) {
827
904
  }
828
905
 
829
906
  /**
830
- * Ensure the Bizar plugin entry exists in `${CLINE_DIR}/cline.json`.
907
+ * Ensure the Bizar plugin entry exists in `${CLAUDE_DIR}/cline.json`.
831
908
  * Idempotent: if the entry already exists, no-op.
832
909
  */
833
910
  export async function patchClineJson({ dryRun, force }) {
834
- const cfgPath = join(CLINE_DIR, 'cline.json');
911
+ // v6.3.0 Claude Code-native. The "plugin entry" model is gone;
912
+ // Claude Code uses an MCP server entry in `mcpServers` plus optional
913
+ // hooks in `hooks`. We still expose this function under the old name
914
+ // for back-compat with callers (e.g. update.mjs), but the body now
915
+ // patches ~/.claude/settings.json.
916
+ return patchClaudeSettings({ dryRun, force });
917
+ }
918
+
919
+ export async function patchClaudeSettings({ dryRun, force }) {
920
+ const cfgPath = join(CLAUDE_DIR, 'settings.json');
835
921
  if (!existsSync(cfgPath)) {
836
922
  if (dryRun) {
837
923
  return { ok: true, message: `[dry-run] would bootstrap ${cfgPath}` };
838
924
  }
839
- mkdirSync(CLINE_DIR, { recursive: true });
840
- const templateSrc = join(REPO_ROOT, 'config', 'cline.json');
925
+ mkdirSync(CLAUDE_DIR, { recursive: true });
926
+ const templateSrc = join(REPO_ROOT, 'config', 'claude.settings.json');
841
927
  if (existsSync(templateSrc)) {
842
- const { copyFileSync } = await import('node:fs');
843
- copyFileSync(templateSrc, cfgPath);
928
+ const { copyFileSync: cfs } = await import('node:fs');
929
+ cfs(templateSrc, cfgPath);
844
930
  return { ok: true, message: `${cfgPath} bootstrapped from package template` };
845
931
  }
846
932
  writeFileSync(cfgPath, JSON.stringify({
847
- $schema: 'https://docs.cline.bot/config.json',
848
- plugin: [],
933
+ $schema: 'https://json.schemastore.org/claude-code-settings.json',
934
+ mcpServers: {
935
+ bizar: {
936
+ command: 'bizar-mcp',
937
+ args: [],
938
+ },
939
+ },
940
+ hooks: {},
849
941
  }, null, 2));
850
942
  return { ok: true, message: `${cfgPath} created` };
851
943
  }
852
944
 
853
- // File exists. Check whether the Bizar entry is already there.
945
+ // File exists. Patch the Bizar config surface idempotently.
854
946
  const cfg = readJsonSafe(cfgPath, null);
855
947
  if (!cfg || typeof cfg !== 'object') {
856
948
  return { ok: false, message: `${cfgPath} is not valid JSON` };
857
949
  }
858
- const plugins = Array.isArray(cfg.plugin) ? cfg.plugin : [];
859
- const hasEntry = plugins.some(
860
- (p) => Array.isArray(p) && typeof p[0] === 'string' && p[0].includes('plugins/bizar'),
861
- );
862
950
 
863
- // v6.2.2 — Multi-patch installer. On every install/update, ensure the
864
- // Bizar config surface is present in cline.json:
951
+ // v6.3.0 — Multi-patch installer. On every install/update, ensure the
952
+ // Bizar config surface is present in ~/.claude/settings.json:
865
953
  //
866
- // 1. plugin entry add if missing (the critical one; without this
867
- // the Bizar plugin never loads).
868
- // 2. default_agentset to "odin" if missing.
869
- // 3. $schemaadd if missing (helps editors validate).
870
- // 4. instructions point at .cline/instructions/bizar-tools.md if
871
- // missing, so Cline loads the tool reference on every session.
872
- // 5. permissions — set to "allow" if missing.
873
- // 6. snapshot — set to false if missing.
874
- //
875
- // v6.2.2 REMOVED:
876
- // - provider.9router (was added automatically in v6.0.1–v6.2.1)
877
- // - provider.minimax (legacy fallback)
954
+ // 1. mcpServers.bizarregister the Bizar MCP server (the critical
955
+ // entry; without this, Claude Code has no access to Bizar tools).
956
+ // 2. $schemaadd if missing (helps editors validate).
957
+ // 3. hookspoint at .claude/hooks/bizar-tools.md so Claude Code
958
+ // fires them on every session.
878
959
  //
879
960
  // Per user request: "the installer should do nothing with providers,
880
- // the user has to configure it themselves." The user picks their own
881
- // provider, plugs in their API key, and configures which model catalog
882
- // to use. The installer just sets up the Bizar scaffolding (plugin
883
- // entry, default agent, schema, instructions, etc.) and stays out of
961
+ // the user has to configure it themselves." The installer sets up the
962
+ // Bizar scaffolding (MCP server entry, schema, hooks) and stays out of
884
963
  // provider configuration entirely.
885
964
  //
886
965
  // All patches are additive and idempotent. We never overwrite a value
887
966
  // the user has set; the `force` flag bypasses that protection for the
888
- // plugin entry only.
889
- let addedDefaultAgent = false;
967
+ // MCP server entry only.
968
+ let addedMcpServer = false;
890
969
  let addedSchema = false;
891
- let addedInstructions = false;
892
- let addedPermissions = false;
893
- let addedSnapshot = false;
894
-
895
- // 1. default_agent
896
- if (!cfg.default_agent) {
897
- cfg.default_agent = 'odin';
898
- addedDefaultAgent = true;
970
+ let addedHooks = false;
971
+
972
+ const mcpServers = (cfg.mcpServers && typeof cfg.mcpServers === 'object')
973
+ ? cfg.mcpServers : {};
974
+ if (!mcpServers.bizar) {
975
+ mcpServers.bizar = {
976
+ command: 'bizar-mcp',
977
+ args: [],
978
+ };
979
+ addedMcpServer = true;
899
980
  }
981
+ cfg.mcpServers = mcpServers;
900
982
 
901
983
  // 2. $schema
902
984
  if (!cfg.$schema) {
903
- cfg.$schema = 'https://docs.cline.bot/config.json';
985
+ cfg.$schema = 'https://json.schemastore.org/claude-code-settings.json';
904
986
  addedSchema = true;
905
987
  }
906
988
 
907
- // 3. instructions — point at the bundled Bizar tools reference.
908
- if (!cfg.instructions || (Array.isArray(cfg.instructions) && cfg.instructions.length === 0)) {
909
- cfg.instructions = ['.cline/instructions/bizar-tools.md'];
910
- addedInstructions = true;
911
- }
912
-
913
- // 4. permission
914
- if (!cfg.permission) {
915
- cfg.permission = 'allow';
916
- addedPermissions = true;
917
- }
918
-
919
- // 5. snapshot
920
- if (typeof cfg.snapshot !== 'boolean') {
921
- cfg.snapshot = false;
922
- addedSnapshot = true;
989
+ // 3. hooks — point at the bundled Bizar hooks file.
990
+ if (!cfg.hooks || (typeof cfg.hooks === 'object' && Object.keys(cfg.hooks).length === 0)) {
991
+ cfg.hooks = {
992
+ SessionStart: [
993
+ {
994
+ hooks: [
995
+ {
996
+ type: 'command',
997
+ command: 'cat .claude/hooks/bizar-tools.md',
998
+ },
999
+ ],
1000
+ },
1001
+ ],
1002
+ };
1003
+ addedHooks = true;
923
1004
  }
924
1005
 
925
- const anyAdded = addedDefaultAgent || addedSchema
926
- || addedInstructions || addedPermissions || addedSnapshot;
1006
+ const anyAdded = addedMcpServer || addedSchema || addedHooks;
927
1007
 
928
- if (hasEntry && !force && !anyAdded) {
929
- return { ok: true, message: 'cline.json already has Bizar plugin entry' };
1008
+ if (!addedMcpServer && !force && !anyAdded) {
1009
+ return { ok: true, message: 'settings.json already has Bizar MCP server entry' };
930
1010
  }
931
1011
 
932
1012
  if (dryRun) {
933
1013
  const added = [];
934
- if (!hasEntry) added.push('plugin entry');
935
- if (addedDefaultAgent) added.push('default_agent');
1014
+ if (addedMcpServer) added.push('mcpServers.bizar');
936
1015
  if (addedSchema) added.push('$schema');
937
- if (addedInstructions) added.push('instructions');
938
- if (addedPermissions) added.push('permission');
939
- if (addedSnapshot) added.push('snapshot');
940
- return { ok: true, message: `[dry-run] would patch cline.json with: ${added.join(', ')}` };
941
- }
942
-
943
- if (!hasEntry) {
944
- // v5.6.0-beta.14: point at the plugin DIRECTORY (not a file inside
945
- // it). Cline reads `package.json#cline.plugins` from there and loads
946
- // the entry point declared in the manifest. Pointing at `index.ts`
947
- // directly used to work, but with the new auto-discovery rules (see
948
- // https://docs.cline.bot/customization/plugins) it can cause every
949
- // .ts file under the plugin tree to be loaded as a separate plugin
950
- // module — producing ~100 `Invalid plugin module` errors at startup.
951
- plugins.push(['./plugins/bizar', {
952
- loopThresholdWarn: 5,
953
- loopThresholdEscalate: 8,
954
- loopThresholdBlock: 12,
955
- loopWindowSize: 10,
956
- clineruntimeMaxConsecutiveMistakes: 6,
957
- }]);
958
- cfg.plugin = plugins;
1016
+ if (addedHooks) added.push('hooks');
1017
+ return { ok: true, message: `[dry-run] would patch settings.json with: ${added.join(', ')}` };
959
1018
  }
960
1019
 
961
1020
  writeFileSync(cfgPath, JSON.stringify(cfg, null, 2) + '\n');
962
1021
  const added = [];
963
- if (!hasEntry) added.push('plugin entry');
964
- if (addedDefaultAgent) added.push('default_agent');
1022
+ if (addedMcpServer) added.push('mcpServers.bizar');
965
1023
  if (addedSchema) added.push('$schema');
966
- if (addedInstructions) added.push('instructions');
967
- if (addedPermissions) added.push('permission');
968
- if (addedSnapshot) added.push('snapshot');
1024
+ if (addedHooks) added.push('hooks');
969
1025
  return {
970
1026
  ok: true,
971
1027
  message: added.length > 0
972
- ? `cline.json patched: ${added.join(', ')}`
973
- : 'cline.json already complete',
1028
+ ? `settings.json patched: ${added.join(', ')}`
1029
+ : 'settings.json already complete',
974
1030
  };
975
1031
  }
976
1032
 
977
1033
  /**
978
- * Copy `config/agents/*.md` into `${CLINE_DIR}/agents/`. Idempotent.
1034
+ * Copy `config/agents/*.md` into `${CLAUDE_DIR}/agents/`. Idempotent.
979
1035
  * Doesn't overwrite existing files unless `force: true`.
980
1036
  */
981
1037
  export async function syncAgentFiles({ dryRun, force }) {
@@ -991,11 +1047,11 @@ export async function syncAgentFiles({ dryRun, force }) {
991
1047
  * (frontmatter + body). Both are valid: the body is the system prompt,
992
1048
  * the frontmatter is config. To make agents loadable by the Cline CLI
993
1049
  * we copy both `.md` (legacy / docs) and `.yaml` (Cline-loadable) into
994
- * `${CLINE_DIR}/agents/`. The YAML version is auto-generated if
1050
+ * `${CLAUDE_DIR}/agents/`. The YAML version is auto-generated if
995
1051
  * missing, with the `name` field added from the filename.
996
1052
  */
997
1053
  const srcDir = join(REPO_ROOT, 'config', 'agents');
998
- const dstDir = join(CLINE_DIR, 'agents');
1054
+ const dstDir = join(CLAUDE_DIR, 'agents');
999
1055
  if (!existsSync(srcDir)) {
1000
1056
  return { ok: true, message: 'no bundled agents to sync' };
1001
1057
  }
@@ -1145,7 +1201,7 @@ function mdToClineAgentYaml(mdText, fallbackName) {
1145
1201
  * `lightrag`, `memory-protocol`, `self-improvement`) were silently
1146
1202
  * missing from the installed Cline.
1147
1203
  * - Each skill is copied as its OWN subdirectory under
1148
- * `${CLINE_DIR}/skills/<name>/` (e.g. `skills/obsidian/SKILL.md`),
1204
+ * `${CLAUDE_DIR}/skills/<name>/` (e.g. `skills/obsidian/SKILL.md`),
1149
1205
  * matching Cline's `resolveSkillsConfigSearchPaths` layout. Previously
1150
1206
  * all skills were flattened into one dir, causing `SKILL.md` from
1151
1207
  * each to overwrite the previous one — only the last copy survived.
@@ -1154,7 +1210,7 @@ function mdToClineAgentYaml(mdText, fallbackName) {
1154
1210
  * - Idempotent: re-running refreshes content but never deletes user
1155
1211
  * additions.
1156
1212
  *
1157
- * v6.0.1 — also syncs `config/rules/*.md` into `${CLINE_DIR}/rules/`.
1213
+ * v6.0.1 — also syncs `config/rules/*.md` into `${CLAUDE_DIR}/rules/`.
1158
1214
  * Previously `config/rules/*.md` was only copied by the legacy
1159
1215
  * `cli/copy.mjs:installRules()` helper, never invoked by `bizar install`
1160
1216
  * or `bizar update` (which both go through `runProvision`). This meant
@@ -1190,7 +1246,7 @@ export async function syncConfigExtras({ dryRun }) {
1190
1246
  // Cline searches `~/.cline/commands/` for command files (.md).
1191
1247
  const commandsSrc = join(REPO_ROOT, 'config', 'commands');
1192
1248
  if (existsSync(commandsSrc)) {
1193
- const commandsDst = join(CLINE_DIR, 'commands');
1249
+ const commandsDst = join(CLAUDE_DIR, 'commands');
1194
1250
  mkdirSync(commandsDst, { recursive: true });
1195
1251
  // One subdir per command (matching Cline's command loading pattern).
1196
1252
  for (const cmd of readdirSync(commandsSrc, { withFileTypes: true })) {
@@ -1209,7 +1265,7 @@ export async function syncConfigExtras({ dryRun }) {
1209
1265
  // Legacy: also drop a copy under `commands-bizar/` for back-compat
1210
1266
  // with anyone referencing the v3.x command tree path.
1211
1267
  if (existsSync(commandsSrc)) {
1212
- const commandsBizarDst = join(CLINE_DIR, 'commands-bizar');
1268
+ const commandsBizarDst = join(CLAUDE_DIR, 'commands-bizar');
1213
1269
  mkdirSync(commandsBizarDst, { recursive: true });
1214
1270
  for (const cmd of readdirSync(commandsSrc, { withFileTypes: true })) {
1215
1271
  if (!cmd.isFile()) continue;
@@ -1224,7 +1280,7 @@ export async function syncConfigExtras({ dryRun }) {
1224
1280
  // subdir of `config/skills/` (no hardcoded list).
1225
1281
  const skillsSrc = join(REPO_ROOT, 'config', 'skills');
1226
1282
  if (existsSync(skillsSrc)) {
1227
- const skillsDst = join(CLINE_DIR, 'skills');
1283
+ const skillsDst = join(CLAUDE_DIR, 'skills');
1228
1284
  mkdirSync(skillsDst, { recursive: true });
1229
1285
  for (const skillDir of readdirSync(skillsSrc, { withFileTypes: true })) {
1230
1286
  if (!skillDir.isDirectory()) continue;
@@ -1248,6 +1304,46 @@ export async function syncConfigExtras({ dryRun }) {
1248
1304
  }
1249
1305
  }
1250
1306
 
1307
+ // v6.2.5 - Register every Bizar skill in `~/.agents/.skill-lock.json`
1308
+ // so Cline's marketplace UI (`isMarketplaceSkillInstalled`) actually
1309
+ // shows them. Without this, users see "0 skills" in the Skills tab
1310
+ // even though the files are correctly mirrored. See the
1311
+ // `writeBizarSkillLock` JSDoc for the full rationale.
1312
+ if (existsSync(skillsSrc)) {
1313
+ const skillLock = writeBizarSkillLock({
1314
+ skillsSrc,
1315
+ agentsDir: join(HOME, '.agents'),
1316
+ });
1317
+ if (!skillLock.ok && skillLock.error) {
1318
+ console.warn(`bizar: skill lock write failed: ${skillLock.error}`);
1319
+ }
1320
+ }
1321
+
1322
+ // v6.2.5 - Mirror `config/agents/_shared/AGENT_BASELINE.md` to both
1323
+ // `~/.cline/skills/agent-baseline/SKILL.md` and
1324
+ // `~/.agents/skills/agent-baseline/SKILL.md`. The auto-loaded
1325
+ // `config/agents/_shared/AGENT_BASELINE.md` references skills by
1326
+ // `name: agent-baseline`, which the Cline skill loader resolves
1327
+ // via `~/.cline/skills/agent-baseline/SKILL.md` (and the
1328
+ // `npx skills` lookup uses `~/.agents/skills/...`). Without this
1329
+ // mirror the agent-baseline SKILL.md never appears in the
1330
+ // marketplace / loader, and the baseline fails to attach.
1331
+ const sharedAgentsDir = join(REPO_ROOT, 'config', 'agents', '_shared');
1332
+ if (existsSync(join(sharedAgentsDir, 'AGENT_BASELINE.md'))) {
1333
+ const baselineSkillDir1 = join(CLAUDE_DIR, 'skills', 'agent-baseline');
1334
+ const baselineSkillDir2 = join(HOME, '.agents', 'skills', 'agent-baseline');
1335
+ mkdirSync(baselineSkillDir1, { recursive: true });
1336
+ mkdirSync(baselineSkillDir2, { recursive: true });
1337
+ copyFileSync(
1338
+ join(sharedAgentsDir, 'AGENT_BASELINE.md'),
1339
+ join(baselineSkillDir1, 'SKILL.md'),
1340
+ );
1341
+ copyFileSync(
1342
+ join(sharedAgentsDir, 'AGENT_BASELINE.md'),
1343
+ join(baselineSkillDir2, 'SKILL.md'),
1344
+ );
1345
+ }
1346
+
1251
1347
  // ── Hooks ────────────────────────────────────────────────────
1252
1348
  // v6.2.1 — Cline hooks are real executable scripts (PreToolUse,
1253
1349
  // PostToolUse, TaskStart, TaskResume, UserPromptSubmit). They live in
@@ -1269,7 +1365,7 @@ export async function syncConfigExtras({ dryRun }) {
1269
1365
  .map((e) => e.name);
1270
1366
 
1271
1367
  // Install to ~/.cline/hooks/ (used by --hooks-dir override)
1272
- const hooksDst1 = join(CLINE_DIR, 'hooks');
1368
+ const hooksDst1 = join(CLAUDE_DIR, 'hooks');
1273
1369
  mkdirSync(hooksDst1, { recursive: true });
1274
1370
  for (const hookFile of hookFiles) {
1275
1371
  const src = join(hooksSrc, hookFile);
@@ -1302,7 +1398,7 @@ export async function syncConfigExtras({ dryRun }) {
1302
1398
  // existed but was empty on a fresh install.
1303
1399
  const rulesSrc = join(REPO_ROOT, 'config', 'rules');
1304
1400
  if (existsSync(rulesSrc)) {
1305
- const rulesDst = join(CLINE_DIR, 'rules');
1401
+ const rulesDst = join(CLAUDE_DIR, 'rules');
1306
1402
  mkdirSync(rulesDst, { recursive: true });
1307
1403
  let ruleCount = 0;
1308
1404
  for (const entry of readdirSync(rulesSrc, { withFileTypes: true })) {
@@ -1320,7 +1416,7 @@ export async function syncConfigExtras({ dryRun }) {
1320
1416
  // ── Workflows ────────────────────────────────────────────────
1321
1417
  const workflowsSrc = join(REPO_ROOT, 'config', 'workflows');
1322
1418
  if (existsSync(workflowsSrc)) {
1323
- const workflowsDst = join(CLINE_DIR, 'workflows');
1419
+ const workflowsDst = join(CLAUDE_DIR, 'workflows');
1324
1420
  mkdirSync(workflowsDst, { recursive: true });
1325
1421
  await copyDirIfExists(workflowsSrc, workflowsDst);
1326
1422
  counts.workflows = 1;
@@ -1332,7 +1428,7 @@ export async function syncConfigExtras({ dryRun }) {
1332
1428
  // path). Clean up those legacy flat dirs so users on older installs
1333
1429
  // don't keep seeing the wrong skill.
1334
1430
  for (const legacy of ['skill']) {
1335
- const p = join(CLINE_DIR, legacy);
1431
+ const p = join(CLAUDE_DIR, legacy);
1336
1432
  if (existsSync(p)) {
1337
1433
  // Only remove if it's flat (no subdirs). Real skill dirs under
1338
1434
  // skills/<name>/SKILL.md live in `skills/`, not `skill/`.
@@ -1703,7 +1799,7 @@ export function spawnFreshDashboard({ port } = {}) {
1703
1799
  * 5. Upgrade npm packages (bizar + cline).
1704
1800
  * 6. Shell to install.sh for system-deps + service registration.
1705
1801
  * 7. Sync agent files, slash commands, skills, hooks, workflows.
1706
- * 8. Copy plugin to ${CLINE_DIR}/plugins/bizar/.
1802
+ * 8. Copy plugin to ${CLAUDE_DIR}/plugins/bizar/.
1707
1803
  * 9. Patch cline.json with the Bizar plugin entry.
1708
1804
  * 10. (update only) Restart dashboard.
1709
1805
  * 11. Doctor health check.
@@ -1760,7 +1856,11 @@ export async function runProvision(opts = {}) {
1760
1856
  if (mode === 'update') {
1761
1857
  console.log(' Installed vs. latest:');
1762
1858
  printVersionMatrix([
1763
- { label: 'cline', current: state.clineCli.version, latest: state.clineCli.latest },
1859
+ {
1860
+ label: '@anthropic-ai/claude-code',
1861
+ current: state.claudeCli.version,
1862
+ latest: state.claudeCli.latest,
1863
+ },
1764
1864
  { label: PKG_MAIN, current: state.pkgVersion, latest: state.pkgLatest },
1765
1865
  ]);
1766
1866
  console.log('');
@@ -1819,7 +1919,9 @@ export async function runProvision(opts = {}) {
1819
1919
  };
1820
1920
 
1821
1921
  if (mode === 'update') {
1822
- await runStep('cline', () => updateClineCli({ dryRun, force }));
1922
+ await runStep('@anthropic-ai/claude-code', () =>
1923
+ updateClaudeCodeCli({ dryRun, force }),
1924
+ );
1823
1925
  }
1824
1926
  await runStep(PKG_MAIN, () => ensureNpmPackage(PKG_MAIN, { mode, dryRun, force }));
1825
1927
 
@@ -1832,7 +1934,7 @@ export async function runProvision(opts = {}) {
1832
1934
  // ── 6.5. LightRAG install (Node-side, in case shell script skipped) ─
1833
1935
  await runStep('lightrag-server', () => installLightragProvision({ dryRun }));
1834
1936
 
1835
- // ── 7-9. Sync agent files, commands, skills, plugin, cline.json ──
1937
+ // ── 7-9. Sync agent files, commands, skills, plugin, settings.json
1836
1938
  console.log('');
1837
1939
  await runStep('agent files + slash commands + skills', () =>
1838
1940
  Promise.all([
@@ -1844,10 +1946,9 @@ export async function runProvision(opts = {}) {
1844
1946
  return { ok: allOk, message: msgs || 'synced' };
1845
1947
  }),
1846
1948
  );
1847
- await runStep(`plugin ${CLINE_DIR}/plugins/bizar/`, () =>
1848
- copyPluginToCline({ dryRun, force }),
1949
+ await runStep('settings.json Bizar entry', () =>
1950
+ patchClaudeSettings({ dryRun, force }),
1849
1951
  );
1850
- await runStep('cline.json plugin entry', () => patchClineJson({ dryRun, force }));
1851
1952
 
1852
1953
  // ── 9.5. v5.x — issue #7. Restart the system service so it picks up
1853
1954
  // the freshly-installed binary. We do this AFTER the npm upgrade
@@ -1945,27 +2046,26 @@ export async function runProvision(opts = {}) {
1945
2046
  }
1946
2047
 
1947
2048
  // ── 13. Provider bootstrap warning ───────────────────────────────
1948
- // v6.2.2 — The installer no longer configures a provider. The user
2049
+ // v6.3.0 — The installer no longer configures a provider. The user
1949
2050
  // must add their own. After a successful install, surface a clear
1950
- // hint pointing them at the right places.
2051
+ // hint pointing them at Claude Code's settings.json.
1951
2052
  if (mode === 'install' && !dryRun && !anyFail) {
1952
- const cfgPath = join(CLINE_DIR, 'cline.json');
2053
+ const cfgPath = join(CLAUDE_DIR, 'settings.json');
1953
2054
  const cfg = readJsonSafe(cfgPath, null);
1954
- const hasProvider = cfg && cfg.provider && Object.keys(cfg.provider).length > 0;
1955
- if (!hasProvider) {
1956
- console.log(chalk.yellow(' ⚠ No provider configured in cline.json.'));
2055
+ // Claude Code doesn't have a "provider" config block; providers
2056
+ // are configured in `env` (per-session overrides) or via the
2057
+ // `claude` CLI's `/config` command. We only check for the env
2058
+ // presence here.
2059
+ const hasAnthropicKey = !!process.env.ANTHROPIC_API_KEY;
2060
+ if (!hasAnthropicKey) {
2061
+ console.log(chalk.yellow(' ⚠ No ANTHROPIC_API_KEY in your environment.'));
1957
2062
  console.log(chalk.yellow(' `bizar install` no longer touches provider config (v6.2.2+).'));
1958
- console.log(chalk.yellow(' You must add one yourself — see the "Provider setup" section below.'));
2063
+ console.log(chalk.yellow(' You must set one yourself — see the "Provider setup" section below.'));
1959
2064
  console.log('');
1960
2065
  console.log(chalk.cyan(' ┌─ Provider setup ─────────────────────────────────────────────┐'));
1961
- console.log(chalk.cyan(' │ 1. Edit ~/.cline/cline.json and add a `provider` block: │'));
1962
- console.log(chalk.cyan(' │ { "provider": { "9router": { │'));
1963
- console.log(chalk.cyan(' │ "baseUrl": "http://localhost:20128/v1", │'));
1964
- console.log(chalk.cyan(' │ "apiKey": "<your-key>", │'));
1965
- console.log(chalk.cyan(' │ "models": { "minimax/MiniMax-M3": {}, │'));
1966
- console.log(chalk.cyan(' │ "minimax/MiniMax-M2.7": {} } } } │'));
1967
- console.log(chalk.cyan(' │ │'));
1968
- console.log(chalk.cyan(' │ 2. Or run `bizar connect` for an interactive TUI setup. │'));
2066
+ console.log(chalk.cyan(' │ 1. Export ANTHROPIC_API_KEY in your shell, or: │'));
2067
+ console.log(chalk.cyan(' │ 2. Run `claude /login` to authenticate via OAuth. │'));
2068
+ console.log(chalk.cyan(' │ 3. Or run `bizar connect` for an interactive TUI setup. │'));
1969
2069
  console.log(chalk.cyan(' └──────────────────────────────────────────────────────────────┘'));
1970
2070
  console.log('');
1971
2071
  console.log(chalk.dim(' Models available at http://localhost:20128/v1/models:'));
@@ -2061,7 +2161,11 @@ export async function runCheck(channel = 'stable') {
2061
2161
 
2062
2162
  const state = detectState();
2063
2163
  printVersionMatrix([
2064
- { label: 'cline', current: state.clineCli.version, latest: state.clineCli.latest },
2164
+ {
2165
+ label: '@anthropic-ai/claude-code',
2166
+ current: state.claudeCli.version,
2167
+ latest: state.claudeCli.latest,
2168
+ },
2065
2169
  { label: PKG_MAIN, current: state.pkgVersion, latest: state.pkgLatest },
2066
2170
  ]);
2067
2171