gnosys 5.10.0 → 5.11.1

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 (500) hide show
  1. package/README.md +66 -0
  2. package/dist/cli.d.ts +0 -1
  3. package/dist/cli.js +293 -139
  4. package/dist/index.d.ts +5 -1
  5. package/dist/index.js +429 -349
  6. package/dist/lib/archive.d.ts +3 -4
  7. package/dist/lib/archive.js +0 -1
  8. package/dist/lib/ask.d.ts +3 -4
  9. package/dist/lib/ask.js +2 -2
  10. package/dist/lib/atomicWrite.d.ts +7 -0
  11. package/dist/lib/atomicWrite.js +46 -0
  12. package/dist/lib/attachments.d.ts +0 -1
  13. package/dist/lib/attachments.js +0 -1
  14. package/dist/lib/audioExtract.d.ts +0 -1
  15. package/dist/lib/audioExtract.js +0 -1
  16. package/dist/lib/audit.d.ts +0 -1
  17. package/dist/lib/audit.js +0 -1
  18. package/dist/lib/bootstrap.d.ts +1 -2
  19. package/dist/lib/bootstrap.js +0 -1
  20. package/dist/lib/centralize.d.ts +20 -0
  21. package/dist/lib/centralize.js +34 -0
  22. package/dist/lib/chat/SlashPalette.d.ts +2 -3
  23. package/dist/lib/chat/SlashPalette.js +0 -1
  24. package/dist/lib/chat/boot-splash.d.ts +1 -2
  25. package/dist/lib/chat/boot-splash.js +0 -1
  26. package/dist/lib/chat/choose.d.ts +0 -1
  27. package/dist/lib/chat/choose.js +0 -2
  28. package/dist/lib/chat/commands.d.ts +1 -2
  29. package/dist/lib/chat/commands.js +0 -1
  30. package/dist/lib/chat/components/CitationText.d.ts +1 -2
  31. package/dist/lib/chat/components/CitationText.js +0 -1
  32. package/dist/lib/chat/components/MarkdownRenderer.d.ts +0 -1
  33. package/dist/lib/chat/components/MarkdownRenderer.js +0 -1
  34. package/dist/lib/chat/components/ToolCallCard.d.ts +1 -2
  35. package/dist/lib/chat/components/ToolCallCard.js +0 -1
  36. package/dist/lib/chat/focus.d.ts +3 -3
  37. package/dist/lib/chat/focus.js +0 -1
  38. package/dist/lib/chat/index.d.ts +3 -4
  39. package/dist/lib/chat/index.js +2 -2
  40. package/dist/lib/chat/intent.d.ts +1 -17
  41. package/dist/lib/chat/intent.js +2 -3
  42. package/dist/lib/chat/llmTurn.d.ts +5 -6
  43. package/dist/lib/chat/llmTurn.js +0 -1
  44. package/dist/lib/chat/recall.d.ts +2 -3
  45. package/dist/lib/chat/recall.js +1 -2
  46. package/dist/lib/chat/render.d.ts +2 -3
  47. package/dist/lib/chat/render.js +0 -1
  48. package/dist/lib/chat/session.d.ts +0 -1
  49. package/dist/lib/chat/session.js +0 -1
  50. package/dist/lib/chat/theme.d.ts +0 -1
  51. package/dist/lib/chat/theme.js +0 -1
  52. package/dist/lib/chat/toolFence.d.ts +2 -2
  53. package/dist/lib/chat/toolFence.js +0 -1
  54. package/dist/lib/chat/tools.d.ts +0 -1
  55. package/dist/lib/chat/tools.js +0 -1
  56. package/dist/lib/chat/types.d.ts +0 -1
  57. package/dist/lib/chat/types.js +0 -1
  58. package/dist/lib/chat/write.d.ts +5 -5
  59. package/dist/lib/chat/write.js +0 -1
  60. package/dist/lib/chunkSplitter.d.ts +0 -1
  61. package/dist/lib/chunkSplitter.js +0 -1
  62. package/dist/lib/cleanup.d.ts +0 -1
  63. package/dist/lib/cleanup.js +0 -1
  64. package/dist/lib/config.d.ts +0 -1
  65. package/dist/lib/config.js +3 -3
  66. package/dist/lib/dashboard.d.ts +3 -4
  67. package/dist/lib/dashboard.js +0 -1
  68. package/dist/lib/db.d.ts +0 -1
  69. package/dist/lib/db.js +40 -8
  70. package/dist/lib/dbSearch.d.ts +3 -4
  71. package/dist/lib/dbSearch.js +0 -1
  72. package/dist/lib/dbWrite.d.ts +2 -3
  73. package/dist/lib/dbWrite.js +0 -1
  74. package/dist/lib/desktopNotify.d.ts +0 -1
  75. package/dist/lib/desktopNotify.js +0 -1
  76. package/dist/lib/docxExtract.d.ts +0 -1
  77. package/dist/lib/docxExtract.js +22 -1
  78. package/dist/lib/dream.d.ts +2 -3
  79. package/dist/lib/dream.js +2 -2
  80. package/dist/lib/embeddings.d.ts +0 -3
  81. package/dist/lib/embeddings.js +7 -3
  82. package/dist/lib/export.d.ts +6 -2
  83. package/dist/lib/export.js +24 -2
  84. package/dist/lib/exportProject.d.ts +4 -3
  85. package/dist/lib/exportProject.js +3 -1
  86. package/dist/lib/federated.d.ts +1 -2
  87. package/dist/lib/federated.js +0 -1
  88. package/dist/lib/fileDetect.d.ts +0 -1
  89. package/dist/lib/fileDetect.js +0 -1
  90. package/dist/lib/graph.d.ts +4 -4
  91. package/dist/lib/graph.js +0 -1
  92. package/dist/lib/heartbeat.d.ts +0 -13
  93. package/dist/lib/heartbeat.js +1 -2
  94. package/dist/lib/hybridSearch.d.ts +5 -21
  95. package/dist/lib/hybridSearch.js +0 -1
  96. package/dist/lib/idFormat.d.ts +0 -2
  97. package/dist/lib/idFormat.js +1 -2
  98. package/dist/lib/imageExtract.d.ts +0 -1
  99. package/dist/lib/imageExtract.js +0 -1
  100. package/dist/lib/import.d.ts +6 -5
  101. package/dist/lib/import.js +3 -33
  102. package/dist/lib/importProject.d.ts +4 -4
  103. package/dist/lib/importProject.js +1 -2
  104. package/dist/lib/ingest.d.ts +3 -4
  105. package/dist/lib/ingest.js +2 -2
  106. package/dist/lib/lensing.d.ts +1 -2
  107. package/dist/lib/lensing.js +0 -1
  108. package/dist/lib/llm.d.ts +6 -45
  109. package/dist/lib/llm.js +27 -9
  110. package/dist/lib/lock.d.ts +0 -1
  111. package/dist/lib/lock.js +0 -1
  112. package/dist/lib/log.d.ts +4 -0
  113. package/dist/lib/log.js +85 -0
  114. package/dist/lib/machineConfig.d.ts +2 -3
  115. package/dist/lib/machineConfig.js +14 -3
  116. package/dist/lib/machineMigrate.d.ts +0 -1
  117. package/dist/lib/machineMigrate.js +0 -1
  118. package/dist/lib/maintenance.d.ts +4 -5
  119. package/dist/lib/maintenance.js +0 -1
  120. package/dist/lib/mcpClientConfig.d.ts +20 -0
  121. package/dist/lib/mcpClientConfig.js +50 -0
  122. package/dist/lib/mcpHttp.d.ts +52 -0
  123. package/dist/lib/mcpHttp.js +227 -0
  124. package/dist/lib/migrate.d.ts +1 -2
  125. package/dist/lib/migrate.js +1 -1
  126. package/dist/lib/modelValidation.d.ts +0 -1
  127. package/dist/lib/modelValidation.js +0 -1
  128. package/dist/lib/multimodalIngest.d.ts +1 -2
  129. package/dist/lib/multimodalIngest.js +0 -1
  130. package/dist/lib/packageManager.d.ts +5 -0
  131. package/dist/lib/packageManager.js +30 -0
  132. package/dist/lib/paths.d.ts +0 -7
  133. package/dist/lib/paths.js +1 -2
  134. package/dist/lib/pdfExtract.d.ts +0 -1
  135. package/dist/lib/pdfExtract.js +0 -1
  136. package/dist/lib/platform.d.ts +24 -0
  137. package/dist/lib/platform.js +114 -0
  138. package/dist/lib/portfolio.d.ts +1 -2
  139. package/dist/lib/portfolio.js +0 -1
  140. package/dist/lib/portfolioHtml.d.ts +1 -2
  141. package/dist/lib/portfolioHtml.js +0 -1
  142. package/dist/lib/preferences.d.ts +6 -2
  143. package/dist/lib/preferences.js +19 -1
  144. package/dist/lib/progress.d.ts +2 -2
  145. package/dist/lib/progress.js +0 -1
  146. package/dist/lib/projectIdentity.d.ts +1 -2
  147. package/dist/lib/projectIdentity.js +5 -5
  148. package/dist/lib/projectPaths.d.ts +2 -2
  149. package/dist/lib/projectPaths.js +0 -1
  150. package/dist/lib/projectScan.d.ts +2 -2
  151. package/dist/lib/projectScan.js +0 -1
  152. package/dist/lib/recall.d.ts +6 -6
  153. package/dist/lib/recall.js +0 -1
  154. package/dist/lib/remote.d.ts +7 -20
  155. package/dist/lib/remote.js +58 -3
  156. package/dist/lib/remoteWizard.d.ts +1 -2
  157. package/dist/lib/remoteWizard.js +124 -7
  158. package/dist/lib/resolver.d.ts +1 -2
  159. package/dist/lib/resolver.js +2 -3
  160. package/dist/lib/retry.d.ts +0 -1
  161. package/dist/lib/retry.js +1 -2
  162. package/dist/lib/rulesGen.d.ts +2 -8
  163. package/dist/lib/rulesGen.js +1 -2
  164. package/dist/lib/search.d.ts +1 -2
  165. package/dist/lib/search.js +1 -1
  166. package/dist/lib/searchTypes.d.ts +18 -0
  167. package/dist/lib/searchTypes.js +2 -0
  168. package/dist/lib/setup/coldStart.d.ts +0 -1
  169. package/dist/lib/setup/coldStart.js +0 -1
  170. package/dist/lib/setup/configSetRender.d.ts +0 -1
  171. package/dist/lib/setup/configSetRender.js +0 -1
  172. package/dist/lib/setup/dreamRender.d.ts +0 -1
  173. package/dist/lib/setup/dreamRender.js +0 -1
  174. package/dist/lib/setup/dreamState.d.ts +2 -2
  175. package/dist/lib/setup/dreamState.js +0 -1
  176. package/dist/lib/setup/modelsRender.d.ts +0 -1
  177. package/dist/lib/setup/modelsRender.js +0 -1
  178. package/dist/lib/setup/remoteRender.d.ts +0 -1
  179. package/dist/lib/setup/remoteRender.js +0 -1
  180. package/dist/lib/setup/routingRender.d.ts +0 -1
  181. package/dist/lib/setup/routingRender.js +0 -1
  182. package/dist/lib/setup/sections/ides.d.ts +1 -2
  183. package/dist/lib/setup/sections/ides.js +3 -2
  184. package/dist/lib/setup/sections/preferences.d.ts +1 -2
  185. package/dist/lib/setup/sections/preferences.js +3 -2
  186. package/dist/lib/setup/sections/routing.d.ts +1 -2
  187. package/dist/lib/setup/sections/routing.js +0 -1
  188. package/dist/lib/setup/storePath.d.ts +0 -1
  189. package/dist/lib/setup/storePath.js +0 -1
  190. package/dist/lib/setup/summary.d.ts +1 -2
  191. package/dist/lib/setup/summary.js +0 -1
  192. package/dist/lib/setup/syncProjectsRender.d.ts +0 -1
  193. package/dist/lib/setup/syncProjectsRender.js +0 -1
  194. package/dist/lib/setup/ui/diff.d.ts +0 -1
  195. package/dist/lib/setup/ui/diff.js +0 -1
  196. package/dist/lib/setup/ui/footer.d.ts +0 -1
  197. package/dist/lib/setup/ui/footer.js +0 -1
  198. package/dist/lib/setup/ui/header.d.ts +0 -1
  199. package/dist/lib/setup/ui/header.js +0 -1
  200. package/dist/lib/setup/ui/index.d.ts +0 -1
  201. package/dist/lib/setup/ui/index.js +0 -1
  202. package/dist/lib/setup/ui/menu.d.ts +0 -1
  203. package/dist/lib/setup/ui/menu.js +0 -1
  204. package/dist/lib/setup/ui/panel.d.ts +0 -1
  205. package/dist/lib/setup/ui/panel.js +0 -1
  206. package/dist/lib/setup/ui/prompt.d.ts +0 -1
  207. package/dist/lib/setup/ui/prompt.js +0 -1
  208. package/dist/lib/setup/ui/safePrompt.d.ts +0 -1
  209. package/dist/lib/setup/ui/safePrompt.js +0 -1
  210. package/dist/lib/setup/ui/spinner.d.ts +0 -1
  211. package/dist/lib/setup/ui/spinner.js +0 -1
  212. package/dist/lib/setup/ui/status.d.ts +0 -1
  213. package/dist/lib/setup/ui/status.js +0 -1
  214. package/dist/lib/setup/ui/table.d.ts +0 -1
  215. package/dist/lib/setup/ui/table.js +0 -1
  216. package/dist/lib/setup/ui/title.d.ts +0 -1
  217. package/dist/lib/setup/ui/title.js +0 -1
  218. package/dist/lib/setup/ui/tokens.d.ts +0 -1
  219. package/dist/lib/setup/ui/tokens.js +0 -1
  220. package/dist/lib/setup.d.ts +2 -31
  221. package/dist/lib/setup.js +56 -54
  222. package/dist/lib/staticSearch.d.ts +0 -1
  223. package/dist/lib/staticSearch.js +0 -1
  224. package/dist/lib/store.d.ts +0 -1
  225. package/dist/lib/store.js +0 -1
  226. package/dist/lib/structuredIngest.d.ts +0 -1
  227. package/dist/lib/structuredIngest.js +0 -1
  228. package/dist/lib/tags.d.ts +0 -1
  229. package/dist/lib/tags.js +0 -1
  230. package/dist/lib/timeline.d.ts +2 -3
  231. package/dist/lib/timeline.js +3 -4
  232. package/dist/lib/trace.d.ts +1 -16
  233. package/dist/lib/trace.js +0 -1
  234. package/dist/lib/upgrade.d.ts +4 -2
  235. package/dist/lib/upgrade.js +15 -3
  236. package/dist/lib/videoExtract.d.ts +0 -1
  237. package/dist/lib/videoExtract.js +2 -5
  238. package/dist/lib/webIndex.d.ts +1 -3
  239. package/dist/lib/webIndex.js +0 -1
  240. package/dist/lib/webIngest.d.ts +13 -1
  241. package/dist/lib/webIngest.js +98 -24
  242. package/dist/lib/wikilinks.d.ts +3 -3
  243. package/dist/lib/wikilinks.js +0 -1
  244. package/dist/postinstall.d.ts +0 -1
  245. package/dist/postinstall.js +0 -1
  246. package/dist/sandbox/client.d.ts +0 -1
  247. package/dist/sandbox/client.js +0 -1
  248. package/dist/sandbox/helper-template.d.ts +0 -1
  249. package/dist/sandbox/helper-template.js +0 -1
  250. package/dist/sandbox/manager.d.ts +0 -9
  251. package/dist/sandbox/manager.js +2 -3
  252. package/dist/sandbox/server.d.ts +2 -3
  253. package/dist/sandbox/server.js +7 -7
  254. package/docs/logo.svg +25 -0
  255. package/package.json +18 -6
  256. package/prompts/synthesize.md +2 -0
  257. package/dist/cli.d.ts.map +0 -1
  258. package/dist/cli.js.map +0 -1
  259. package/dist/index.d.ts.map +0 -1
  260. package/dist/index.js.map +0 -1
  261. package/dist/lib/archive.d.ts.map +0 -1
  262. package/dist/lib/archive.js.map +0 -1
  263. package/dist/lib/ask.d.ts.map +0 -1
  264. package/dist/lib/ask.js.map +0 -1
  265. package/dist/lib/attachments.d.ts.map +0 -1
  266. package/dist/lib/attachments.js.map +0 -1
  267. package/dist/lib/audioExtract.d.ts.map +0 -1
  268. package/dist/lib/audioExtract.js.map +0 -1
  269. package/dist/lib/audit.d.ts.map +0 -1
  270. package/dist/lib/audit.js.map +0 -1
  271. package/dist/lib/bootstrap.d.ts.map +0 -1
  272. package/dist/lib/bootstrap.js.map +0 -1
  273. package/dist/lib/chat/SlashPalette.d.ts.map +0 -1
  274. package/dist/lib/chat/SlashPalette.js.map +0 -1
  275. package/dist/lib/chat/boot-splash.d.ts.map +0 -1
  276. package/dist/lib/chat/boot-splash.js.map +0 -1
  277. package/dist/lib/chat/choose.d.ts.map +0 -1
  278. package/dist/lib/chat/choose.js.map +0 -1
  279. package/dist/lib/chat/commands.d.ts.map +0 -1
  280. package/dist/lib/chat/commands.js.map +0 -1
  281. package/dist/lib/chat/components/CitationText.d.ts.map +0 -1
  282. package/dist/lib/chat/components/CitationText.js.map +0 -1
  283. package/dist/lib/chat/components/MarkdownRenderer.d.ts.map +0 -1
  284. package/dist/lib/chat/components/MarkdownRenderer.js.map +0 -1
  285. package/dist/lib/chat/components/ToolCallCard.d.ts.map +0 -1
  286. package/dist/lib/chat/components/ToolCallCard.js.map +0 -1
  287. package/dist/lib/chat/focus.d.ts.map +0 -1
  288. package/dist/lib/chat/focus.js.map +0 -1
  289. package/dist/lib/chat/index.d.ts.map +0 -1
  290. package/dist/lib/chat/index.js.map +0 -1
  291. package/dist/lib/chat/intent.d.ts.map +0 -1
  292. package/dist/lib/chat/intent.js.map +0 -1
  293. package/dist/lib/chat/llmTurn.d.ts.map +0 -1
  294. package/dist/lib/chat/llmTurn.js.map +0 -1
  295. package/dist/lib/chat/recall.d.ts.map +0 -1
  296. package/dist/lib/chat/recall.js.map +0 -1
  297. package/dist/lib/chat/render.d.ts.map +0 -1
  298. package/dist/lib/chat/render.js.map +0 -1
  299. package/dist/lib/chat/session.d.ts.map +0 -1
  300. package/dist/lib/chat/session.js.map +0 -1
  301. package/dist/lib/chat/theme.d.ts.map +0 -1
  302. package/dist/lib/chat/theme.js.map +0 -1
  303. package/dist/lib/chat/toolFence.d.ts.map +0 -1
  304. package/dist/lib/chat/toolFence.js.map +0 -1
  305. package/dist/lib/chat/tools.d.ts.map +0 -1
  306. package/dist/lib/chat/tools.js.map +0 -1
  307. package/dist/lib/chat/types.d.ts.map +0 -1
  308. package/dist/lib/chat/types.js.map +0 -1
  309. package/dist/lib/chat/write.d.ts.map +0 -1
  310. package/dist/lib/chat/write.js.map +0 -1
  311. package/dist/lib/chunkSplitter.d.ts.map +0 -1
  312. package/dist/lib/chunkSplitter.js.map +0 -1
  313. package/dist/lib/cleanup.d.ts.map +0 -1
  314. package/dist/lib/cleanup.js.map +0 -1
  315. package/dist/lib/config.d.ts.map +0 -1
  316. package/dist/lib/config.js.map +0 -1
  317. package/dist/lib/dashboard.d.ts.map +0 -1
  318. package/dist/lib/dashboard.js.map +0 -1
  319. package/dist/lib/db.d.ts.map +0 -1
  320. package/dist/lib/db.js.map +0 -1
  321. package/dist/lib/dbSearch.d.ts.map +0 -1
  322. package/dist/lib/dbSearch.js.map +0 -1
  323. package/dist/lib/dbWrite.d.ts.map +0 -1
  324. package/dist/lib/dbWrite.js.map +0 -1
  325. package/dist/lib/desktopNotify.d.ts.map +0 -1
  326. package/dist/lib/desktopNotify.js.map +0 -1
  327. package/dist/lib/docxExtract.d.ts.map +0 -1
  328. package/dist/lib/docxExtract.js.map +0 -1
  329. package/dist/lib/dream.d.ts.map +0 -1
  330. package/dist/lib/dream.js.map +0 -1
  331. package/dist/lib/embeddings.d.ts.map +0 -1
  332. package/dist/lib/embeddings.js.map +0 -1
  333. package/dist/lib/export.d.ts.map +0 -1
  334. package/dist/lib/export.js.map +0 -1
  335. package/dist/lib/exportProject.d.ts.map +0 -1
  336. package/dist/lib/exportProject.js.map +0 -1
  337. package/dist/lib/federated.d.ts.map +0 -1
  338. package/dist/lib/federated.js.map +0 -1
  339. package/dist/lib/fileDetect.d.ts.map +0 -1
  340. package/dist/lib/fileDetect.js.map +0 -1
  341. package/dist/lib/graph.d.ts.map +0 -1
  342. package/dist/lib/graph.js.map +0 -1
  343. package/dist/lib/heartbeat.d.ts.map +0 -1
  344. package/dist/lib/heartbeat.js.map +0 -1
  345. package/dist/lib/history.d.ts +0 -39
  346. package/dist/lib/history.d.ts.map +0 -1
  347. package/dist/lib/history.js +0 -112
  348. package/dist/lib/history.js.map +0 -1
  349. package/dist/lib/hybridSearch.d.ts.map +0 -1
  350. package/dist/lib/hybridSearch.js.map +0 -1
  351. package/dist/lib/idFormat.d.ts.map +0 -1
  352. package/dist/lib/idFormat.js.map +0 -1
  353. package/dist/lib/imageExtract.d.ts.map +0 -1
  354. package/dist/lib/imageExtract.js.map +0 -1
  355. package/dist/lib/import.d.ts.map +0 -1
  356. package/dist/lib/import.js.map +0 -1
  357. package/dist/lib/importProject.d.ts.map +0 -1
  358. package/dist/lib/importProject.js.map +0 -1
  359. package/dist/lib/ingest.d.ts.map +0 -1
  360. package/dist/lib/ingest.js.map +0 -1
  361. package/dist/lib/lensing.d.ts.map +0 -1
  362. package/dist/lib/lensing.js.map +0 -1
  363. package/dist/lib/llm.d.ts.map +0 -1
  364. package/dist/lib/llm.js.map +0 -1
  365. package/dist/lib/lock.d.ts.map +0 -1
  366. package/dist/lib/lock.js.map +0 -1
  367. package/dist/lib/machineConfig.d.ts.map +0 -1
  368. package/dist/lib/machineConfig.js.map +0 -1
  369. package/dist/lib/machineMigrate.d.ts.map +0 -1
  370. package/dist/lib/machineMigrate.js.map +0 -1
  371. package/dist/lib/maintenance.d.ts.map +0 -1
  372. package/dist/lib/maintenance.js.map +0 -1
  373. package/dist/lib/migrate.d.ts.map +0 -1
  374. package/dist/lib/migrate.js.map +0 -1
  375. package/dist/lib/modelValidation.d.ts.map +0 -1
  376. package/dist/lib/modelValidation.js.map +0 -1
  377. package/dist/lib/multimodalIngest.d.ts.map +0 -1
  378. package/dist/lib/multimodalIngest.js.map +0 -1
  379. package/dist/lib/paths.d.ts.map +0 -1
  380. package/dist/lib/paths.js.map +0 -1
  381. package/dist/lib/pdfExtract.d.ts.map +0 -1
  382. package/dist/lib/pdfExtract.js.map +0 -1
  383. package/dist/lib/portfolio.d.ts.map +0 -1
  384. package/dist/lib/portfolio.js.map +0 -1
  385. package/dist/lib/portfolioHtml.d.ts.map +0 -1
  386. package/dist/lib/portfolioHtml.js.map +0 -1
  387. package/dist/lib/preferences.d.ts.map +0 -1
  388. package/dist/lib/preferences.js.map +0 -1
  389. package/dist/lib/progress.d.ts.map +0 -1
  390. package/dist/lib/progress.js.map +0 -1
  391. package/dist/lib/projectIdentity.d.ts.map +0 -1
  392. package/dist/lib/projectIdentity.js.map +0 -1
  393. package/dist/lib/projectPaths.d.ts.map +0 -1
  394. package/dist/lib/projectPaths.js.map +0 -1
  395. package/dist/lib/projectScan.d.ts.map +0 -1
  396. package/dist/lib/projectScan.js.map +0 -1
  397. package/dist/lib/recall.d.ts.map +0 -1
  398. package/dist/lib/recall.js.map +0 -1
  399. package/dist/lib/remote.d.ts.map +0 -1
  400. package/dist/lib/remote.js.map +0 -1
  401. package/dist/lib/remoteWizard.d.ts.map +0 -1
  402. package/dist/lib/remoteWizard.js.map +0 -1
  403. package/dist/lib/resolver.d.ts.map +0 -1
  404. package/dist/lib/resolver.js.map +0 -1
  405. package/dist/lib/retry.d.ts.map +0 -1
  406. package/dist/lib/retry.js.map +0 -1
  407. package/dist/lib/rulesGen.d.ts.map +0 -1
  408. package/dist/lib/rulesGen.js.map +0 -1
  409. package/dist/lib/search.d.ts.map +0 -1
  410. package/dist/lib/search.js.map +0 -1
  411. package/dist/lib/setup/coldStart.d.ts.map +0 -1
  412. package/dist/lib/setup/coldStart.js.map +0 -1
  413. package/dist/lib/setup/configSetRender.d.ts.map +0 -1
  414. package/dist/lib/setup/configSetRender.js.map +0 -1
  415. package/dist/lib/setup/dreamRender.d.ts.map +0 -1
  416. package/dist/lib/setup/dreamRender.js.map +0 -1
  417. package/dist/lib/setup/dreamState.d.ts.map +0 -1
  418. package/dist/lib/setup/dreamState.js.map +0 -1
  419. package/dist/lib/setup/modelsRender.d.ts.map +0 -1
  420. package/dist/lib/setup/modelsRender.js.map +0 -1
  421. package/dist/lib/setup/remoteRender.d.ts.map +0 -1
  422. package/dist/lib/setup/remoteRender.js.map +0 -1
  423. package/dist/lib/setup/routingRender.d.ts.map +0 -1
  424. package/dist/lib/setup/routingRender.js.map +0 -1
  425. package/dist/lib/setup/sections/ides.d.ts.map +0 -1
  426. package/dist/lib/setup/sections/ides.js.map +0 -1
  427. package/dist/lib/setup/sections/preferences.d.ts.map +0 -1
  428. package/dist/lib/setup/sections/preferences.js.map +0 -1
  429. package/dist/lib/setup/sections/routing.d.ts.map +0 -1
  430. package/dist/lib/setup/sections/routing.js.map +0 -1
  431. package/dist/lib/setup/storePath.d.ts.map +0 -1
  432. package/dist/lib/setup/storePath.js.map +0 -1
  433. package/dist/lib/setup/summary.d.ts.map +0 -1
  434. package/dist/lib/setup/summary.js.map +0 -1
  435. package/dist/lib/setup/syncProjectsRender.d.ts.map +0 -1
  436. package/dist/lib/setup/syncProjectsRender.js.map +0 -1
  437. package/dist/lib/setup/ui/diff.d.ts.map +0 -1
  438. package/dist/lib/setup/ui/diff.js.map +0 -1
  439. package/dist/lib/setup/ui/footer.d.ts.map +0 -1
  440. package/dist/lib/setup/ui/footer.js.map +0 -1
  441. package/dist/lib/setup/ui/header.d.ts.map +0 -1
  442. package/dist/lib/setup/ui/header.js.map +0 -1
  443. package/dist/lib/setup/ui/index.d.ts.map +0 -1
  444. package/dist/lib/setup/ui/index.js.map +0 -1
  445. package/dist/lib/setup/ui/menu.d.ts.map +0 -1
  446. package/dist/lib/setup/ui/menu.js.map +0 -1
  447. package/dist/lib/setup/ui/panel.d.ts.map +0 -1
  448. package/dist/lib/setup/ui/panel.js.map +0 -1
  449. package/dist/lib/setup/ui/prompt.d.ts.map +0 -1
  450. package/dist/lib/setup/ui/prompt.js.map +0 -1
  451. package/dist/lib/setup/ui/safePrompt.d.ts.map +0 -1
  452. package/dist/lib/setup/ui/safePrompt.js.map +0 -1
  453. package/dist/lib/setup/ui/spinner.d.ts.map +0 -1
  454. package/dist/lib/setup/ui/spinner.js.map +0 -1
  455. package/dist/lib/setup/ui/status.d.ts.map +0 -1
  456. package/dist/lib/setup/ui/status.js.map +0 -1
  457. package/dist/lib/setup/ui/table.d.ts.map +0 -1
  458. package/dist/lib/setup/ui/table.js.map +0 -1
  459. package/dist/lib/setup/ui/title.d.ts.map +0 -1
  460. package/dist/lib/setup/ui/title.js.map +0 -1
  461. package/dist/lib/setup/ui/tokens.d.ts.map +0 -1
  462. package/dist/lib/setup/ui/tokens.js.map +0 -1
  463. package/dist/lib/setup.d.ts.map +0 -1
  464. package/dist/lib/setup.js.map +0 -1
  465. package/dist/lib/staticSearch.d.ts.map +0 -1
  466. package/dist/lib/staticSearch.js.map +0 -1
  467. package/dist/lib/store.d.ts.map +0 -1
  468. package/dist/lib/store.js.map +0 -1
  469. package/dist/lib/structuredIngest.d.ts.map +0 -1
  470. package/dist/lib/structuredIngest.js.map +0 -1
  471. package/dist/lib/tags.d.ts.map +0 -1
  472. package/dist/lib/tags.js.map +0 -1
  473. package/dist/lib/timeline.d.ts.map +0 -1
  474. package/dist/lib/timeline.js.map +0 -1
  475. package/dist/lib/trace.d.ts.map +0 -1
  476. package/dist/lib/trace.js.map +0 -1
  477. package/dist/lib/upgrade.d.ts.map +0 -1
  478. package/dist/lib/upgrade.js.map +0 -1
  479. package/dist/lib/videoExtract.d.ts.map +0 -1
  480. package/dist/lib/videoExtract.js.map +0 -1
  481. package/dist/lib/webIndex.d.ts.map +0 -1
  482. package/dist/lib/webIndex.js.map +0 -1
  483. package/dist/lib/webIngest.d.ts.map +0 -1
  484. package/dist/lib/webIngest.js.map +0 -1
  485. package/dist/lib/wikilinks.d.ts.map +0 -1
  486. package/dist/lib/wikilinks.js.map +0 -1
  487. package/dist/postinstall.d.ts.map +0 -1
  488. package/dist/postinstall.js.map +0 -1
  489. package/dist/sandbox/client.d.ts.map +0 -1
  490. package/dist/sandbox/client.js.map +0 -1
  491. package/dist/sandbox/helper-template.d.ts.map +0 -1
  492. package/dist/sandbox/helper-template.js.map +0 -1
  493. package/dist/sandbox/index.d.ts +0 -10
  494. package/dist/sandbox/index.d.ts.map +0 -1
  495. package/dist/sandbox/index.js +0 -10
  496. package/dist/sandbox/index.js.map +0 -1
  497. package/dist/sandbox/manager.d.ts.map +0 -1
  498. package/dist/sandbox/manager.js.map +0 -1
  499. package/dist/sandbox/server.d.ts.map +0 -1
  500. package/dist/sandbox/server.js.map +0 -1
@@ -9,9 +9,9 @@
9
9
  * search/ask → searches archive if active results insufficient,
10
10
  * then dearchives used memories back to active
11
11
  */
12
- import { GnosysStore, Memory } from "./store.js";
13
- import { GnosysDB } from "./db.js";
14
- import { GnosysConfig } from "./config.js";
12
+ import type { GnosysStore, Memory } from "./store.js";
13
+ import type { GnosysDB } from "./db.js";
14
+ import type { GnosysConfig } from "./config.js";
15
15
  export interface ArchivedMemory {
16
16
  id: string;
17
17
  title: string;
@@ -93,4 +93,3 @@ export declare class GnosysArchive {
93
93
  * Criteria: days since last reinforced > maxActiveDays AND decayed confidence < minConfidence
94
94
  */
95
95
  export declare function getArchiveEligible(memories: Memory[], config: GnosysConfig): Memory[];
96
- //# sourceMappingURL=archive.d.ts.map
@@ -313,4 +313,3 @@ export function getArchiveEligible(memories, config) {
313
313
  return daysSince > maxDays && decayed < minConf;
314
314
  });
315
315
  }
316
- //# sourceMappingURL=archive.js.map
package/dist/lib/ask.d.ts CHANGED
@@ -5,9 +5,9 @@
5
5
  * Supports streaming and "deep query" mode (auto follow-up on insufficient context).
6
6
  * Uses the LLM abstraction layer — works with Anthropic, Ollama, or any future provider.
7
7
  */
8
- import { GnosysHybridSearch } from "./hybridSearch.js";
9
- import { GnosysConfig } from "./config.js";
10
- import { GnosysResolver } from "./resolver.js";
8
+ import type { GnosysHybridSearch } from "./hybridSearch.js";
9
+ import { type GnosysConfig } from "./config.js";
10
+ import type { GnosysResolver } from "./resolver.js";
11
11
  export interface AskResult {
12
12
  answer: string;
13
13
  sources: {
@@ -74,4 +74,3 @@ export declare class GnosysAsk {
74
74
  */
75
75
  private extractCitedSources;
76
76
  }
77
- //# sourceMappingURL=ask.d.ts.map
package/dist/lib/ask.js CHANGED
@@ -13,6 +13,7 @@ import { getLLMProvider } from "./llm.js";
13
13
  import { GnosysArchive } from "./archive.js";
14
14
  import { GnosysMaintenanceEngine } from "./maintenance.js";
15
15
  import { auditLog } from "./audit.js";
16
+ import { getSecureStorageSetupHint } from "./platform.js";
16
17
  const __filename = fileURLToPath(import.meta.url);
17
18
  const __dirname = path.dirname(__filename);
18
19
  /**
@@ -132,7 +133,7 @@ export class GnosysAsk {
132
133
  }
133
134
  if (envVar) {
134
135
  throw new Error(`gnosys_ask requires an LLM. Configured default provider "${providerName}" has no key. ` +
135
- `Set ${envVar} in your shell, run 'gnosys setup' to store one in the macOS Keychain, or add llm.${providerName}.apiKey to gnosys.json.`);
136
+ `Set ${envVar} in your shell, run 'gnosys setup' to store one in ${getSecureStorageSetupHint()}, or add llm.${providerName}.apiKey to gnosys.json.`);
136
137
  }
137
138
  throw new Error(`gnosys_ask requires an LLM. Provider "${providerName}" is not available. Run 'gnosys setup' to configure one.`);
138
139
  }
@@ -329,4 +330,3 @@ export class GnosysAsk {
329
330
  return cited;
330
331
  }
331
332
  }
332
- //# sourceMappingURL=ask.js.map
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Atomic file writes — temp file in the same directory, then rename into place.
3
+ */
4
+ /** Atomically write `data` to `dest` (async). */
5
+ export declare function atomicWriteFile(dest: string, data: string): Promise<void>;
6
+ /** Atomically write `data` to `dest` (sync). */
7
+ export declare function atomicWriteFileSync(dest: string, data: string): void;
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Atomic file writes — temp file in the same directory, then rename into place.
3
+ */
4
+ import { promises as fsp } from "fs";
5
+ import * as fs from "fs";
6
+ import path from "path";
7
+ import { randomBytes } from "crypto";
8
+ function tmpPathFor(dest) {
9
+ const dir = path.dirname(dest);
10
+ const base = path.basename(dest);
11
+ return path.join(dir, `.${base}.${process.pid}.${randomBytes(4).toString("hex")}.tmp`);
12
+ }
13
+ /** Atomically write `data` to `dest` (async). */
14
+ export async function atomicWriteFile(dest, data) {
15
+ const tmp = tmpPathFor(dest);
16
+ try {
17
+ await fsp.writeFile(tmp, data, "utf-8");
18
+ await fsp.rename(tmp, dest);
19
+ }
20
+ catch (err) {
21
+ try {
22
+ await fsp.unlink(tmp);
23
+ }
24
+ catch {
25
+ // temp may not exist
26
+ }
27
+ throw err;
28
+ }
29
+ }
30
+ /** Atomically write `data` to `dest` (sync). */
31
+ export function atomicWriteFileSync(dest, data) {
32
+ const tmp = tmpPathFor(dest);
33
+ try {
34
+ fs.writeFileSync(tmp, data, "utf-8");
35
+ fs.renameSync(tmp, dest);
36
+ }
37
+ catch (err) {
38
+ try {
39
+ fs.unlinkSync(tmp);
40
+ }
41
+ catch {
42
+ // temp may not exist
43
+ }
44
+ throw err;
45
+ }
46
+ }
@@ -40,4 +40,3 @@ export declare function getAttachmentPath(storePath: string, uuid: string, ext:
40
40
  * tracks which memories reference it.
41
41
  */
42
42
  export declare function linkMemoryToAttachment(storePath: string, uuid: string, memoryId: string): Promise<void>;
43
- //# sourceMappingURL=attachments.d.ts.map
@@ -151,4 +151,3 @@ export async function linkMemoryToAttachment(storePath, uuid, memoryId) {
151
151
  await writeManifest(storePath, manifest);
152
152
  }
153
153
  }
154
- //# sourceMappingURL=attachments.js.map
@@ -36,4 +36,3 @@ export interface TranscriptionOptions {
36
36
  * 5. Throw an error with setup instructions
37
37
  */
38
38
  export declare function transcribeAudio(filePath: string, options?: TranscriptionOptions): Promise<TranscriptResult>;
39
- //# sourceMappingURL=audioExtract.d.ts.map
@@ -217,4 +217,3 @@ export async function transcribeAudio(filePath, options) {
217
217
  " 3. Local Whisper: npm install @huggingface/transformers\n" +
218
218
  "Or set multimodal.transcriptionProvider in gnosys.json.");
219
219
  }
220
- //# sourceMappingURL=audioExtract.js.map
@@ -57,4 +57,3 @@ export declare function formatAuditTimeline(entries: AuditEntry[]): string;
57
57
  * Close the audit stream cleanly.
58
58
  */
59
59
  export declare function closeAudit(): void;
60
- //# sourceMappingURL=audit.d.ts.map
package/dist/lib/audit.js CHANGED
@@ -175,4 +175,3 @@ export function closeAudit() {
175
175
  auditStream = null;
176
176
  }
177
177
  }
178
- //# sourceMappingURL=audit.js.map
@@ -4,7 +4,7 @@
4
4
  * Scans a directory for markdown/text files and creates memories from them.
5
5
  * Supports both raw import (no LLM) and enriched import (LLM structures content).
6
6
  */
7
- import { GnosysStore, MemoryFrontmatter } from "./store.js";
7
+ import type { GnosysStore, MemoryFrontmatter } from "./store.js";
8
8
  export interface BootstrapOptions {
9
9
  /** Source directory to scan */
10
10
  sourceDir: string;
@@ -53,4 +53,3 @@ export declare function parseFileForImport(content: string, relativePath: string
53
53
  * Bootstrap: batch-import files from a directory into a Gnosys store.
54
54
  */
55
55
  export declare function bootstrap(store: GnosysStore, options: BootstrapOptions): Promise<BootstrapResult>;
56
- //# sourceMappingURL=bootstrap.d.ts.map
@@ -160,4 +160,3 @@ export async function bootstrap(store, options) {
160
160
  }
161
161
  return result;
162
162
  }
163
- //# sourceMappingURL=bootstrap.js.map
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Seed a central server's brain from a local one (v5.12 Phase E).
3
+ *
4
+ * When you move from local-stdio to the central-server topology, the new host
5
+ * (a Docker volume, another machine) starts empty. `centralizeDb` makes a
6
+ * CONSISTENT copy of this machine's `~/.gnosys/gnosys.db` into a target dir,
7
+ * using SQLite's online backup API so it's safe even while the source is in use
8
+ * (WAL is handled — no torn copy).
9
+ */
10
+ export interface CentralizeResult {
11
+ source: string;
12
+ target: string;
13
+ bytes: number;
14
+ }
15
+ export declare function centralizeDb(opts: {
16
+ to: string;
17
+ force?: boolean;
18
+ /** Override the source DB file (defaults to this machine's central DB). */
19
+ sourceDb?: string;
20
+ }): Promise<CentralizeResult>;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Seed a central server's brain from a local one (v5.12 Phase E).
3
+ *
4
+ * When you move from local-stdio to the central-server topology, the new host
5
+ * (a Docker volume, another machine) starts empty. `centralizeDb` makes a
6
+ * CONSISTENT copy of this machine's `~/.gnosys/gnosys.db` into a target dir,
7
+ * using SQLite's online backup API so it's safe even while the source is in use
8
+ * (WAL is handled — no torn copy).
9
+ */
10
+ import fs from "fs";
11
+ import path from "path";
12
+ import Database from "better-sqlite3";
13
+ import { getCentralDbPath } from "./paths.js";
14
+ export async function centralizeDb(opts) {
15
+ const source = opts.sourceDb ?? getCentralDbPath();
16
+ if (!fs.existsSync(source)) {
17
+ throw new Error(`No local brain found at ${source}`);
18
+ }
19
+ const target = path.join(opts.to, "gnosys.db");
20
+ if (fs.existsSync(target) && !opts.force) {
21
+ throw new Error(`Target already exists: ${target} (use --force to overwrite)`);
22
+ }
23
+ fs.mkdirSync(opts.to, { recursive: true });
24
+ // Online backup → a single consistent gnosys.db at the target (handles WAL).
25
+ const db = new Database(source);
26
+ db.pragma("busy_timeout = 5000");
27
+ try {
28
+ await db.backup(target);
29
+ }
30
+ finally {
31
+ db.close();
32
+ }
33
+ return { source, target, bytes: fs.statSync(target).size };
34
+ }
@@ -13,8 +13,8 @@
13
13
  * back into its own input. Keeping it dumb makes it trivial to test
14
14
  * and reuse.
15
15
  */
16
- import React from "react";
17
- import { CommandSpec } from "./commands.js";
16
+ import type React from "react";
17
+ import type { CommandSpec } from "./commands.js";
18
18
  export interface SlashPaletteProps {
19
19
  /** Full text currently in the input buffer (used to filter). */
20
20
  filter: string;
@@ -31,4 +31,3 @@ export interface SlashPaletteProps {
31
31
  */
32
32
  export declare function filterCommands(commands: CommandSpec[], filter: string): CommandSpec[];
33
33
  export declare const SlashPalette: React.FC<SlashPaletteProps>;
34
- //# sourceMappingURL=SlashPalette.d.ts.map
@@ -46,4 +46,3 @@ export const SlashPalette = ({ filter, commands, selectedIndex, maxItems = 8, })
46
46
  return (_jsxs(Box, { flexDirection: "row", children: [_jsxs(Text, { color: isSelected ? "black" : undefined, backgroundColor: isSelected ? "cyan" : undefined, children: [isSelected ? "▶ " : " ", cmd.name.padEnd(18)] }), _jsxs(Text, { dimColor: true, children: [" ", cmd.summary] })] }, cmd.name));
47
47
  }), moreBelow && _jsxs(Text, { dimColor: true, children: ["\u2193 ", matches.length - end, " more below"] }), _jsx(Text, { dimColor: true, children: SHORTCUT_HINT })] }));
48
48
  };
49
- //# sourceMappingURL=SlashPalette.js.map
@@ -8,10 +8,9 @@
8
8
  *
9
9
  * 4 visible rows × 29 cols — fits any terminal ≥80 cols comfortably.
10
10
  */
11
- import React from "react";
11
+ import type React from "react";
12
12
  export interface BootSplashProps {
13
13
  /** Subtitle line under the wordmark — usually the version + tagline. */
14
14
  subtitle?: string;
15
15
  }
16
16
  export declare const BootSplash: React.FC<BootSplashProps>;
17
- //# sourceMappingURL=boot-splash.d.ts.map
@@ -8,4 +8,3 @@ const SPLASH_ROWS = [
8
8
  { before: "/___/ ", o: " ", after: " /___/ " },
9
9
  ];
10
10
  export const BootSplash = ({ subtitle }) => (_jsxs(Box, { flexDirection: "column", marginTop: 1, marginBottom: 1, children: [SPLASH_ROWS.map((row, i) => (_jsxs(Box, { children: [_jsx(Text, { color: THEME.text, children: row.before }), _jsx(Text, { color: THEME.accent, bold: true, children: row.o }), _jsx(Text, { color: THEME.text, children: row.after })] }, i))), subtitle && (_jsx(Box, { marginTop: 1, children: _jsxs(Text, { color: THEME.muted, children: [" ", subtitle] }) }))] }));
11
- //# sourceMappingURL=boot-splash.js.map
@@ -72,4 +72,3 @@ export declare function extractChooseFence(text: string): ExtractResult;
72
72
  export declare function parseChooseYaml(yaml: string): ChooseBlock;
73
73
  /** Format a user's selection as a synthetic user turn. */
74
74
  export declare function formatSelection(option: ChooseOption): string;
75
- //# sourceMappingURL=choose.d.ts.map
@@ -130,7 +130,6 @@ export function parseChooseYaml(yaml) {
130
130
  const detailMatch = line.match(/^\s*detail:\s*(.+?)\s*$/);
131
131
  if (detailMatch) {
132
132
  current.detail = detailMatch[1];
133
- continue;
134
133
  }
135
134
  }
136
135
  // Flush the last option
@@ -143,4 +142,3 @@ export function formatSelection(option) {
143
142
  const detail = option.detail ? ` (${option.detail})` : "";
144
143
  return `[picked: ${option.id} — ${option.label}${detail}]`;
145
144
  }
146
- //# sourceMappingURL=choose.js.map
@@ -11,7 +11,7 @@
11
11
  * /reinforce, /remember, /save-turn, /attach, /focus, /branch, /resume-focus,
12
12
  * /dream-here, /search-chats, /export.
13
13
  */
14
- import { Turn } from "./types.js";
14
+ import type { Turn } from "./types.js";
15
15
  export interface CommandContext {
16
16
  /** Current session ID. */
17
17
  sessionId: string;
@@ -93,4 +93,3 @@ export declare function listCommands(): CommandSpec[];
93
93
  export declare function findCommand(name: string): CommandSpec | undefined;
94
94
  /** Parse a raw input line and dispatch if it's a slash command. Returns null if it's not a command. */
95
95
  export declare function dispatchCommand(raw: string, ctx: CommandContext): Promise<CommandResult | null>;
96
- //# sourceMappingURL=commands.d.ts.map
@@ -364,4 +364,3 @@ export async function dispatchCommand(raw, ctx) {
364
364
  }
365
365
  return await cmd.handler(ctx, args);
366
366
  }
367
- //# sourceMappingURL=commands.js.map
@@ -16,7 +16,7 @@
16
16
  * Stripped ellipses are preserved in the visible text but the URI carries
17
17
  * the full id when available.
18
18
  */
19
- import React from "react";
19
+ import type React from "react";
20
20
  export interface CitationTextProps {
21
21
  text: string;
22
22
  }
@@ -39,4 +39,3 @@ type Segment = PlainSegment | CitationSegment;
39
39
  /** Split `text` into plain / citation segments in left-to-right order. */
40
40
  export declare function splitCitations(text: string): Segment[];
41
41
  export {};
42
- //# sourceMappingURL=CitationText.d.ts.map
@@ -38,4 +38,3 @@ export function splitCitations(text) {
38
38
  }
39
39
  return out.length > 0 ? out : [{ kind: "plain", text }];
40
40
  }
41
- //# sourceMappingURL=CitationText.js.map
@@ -26,4 +26,3 @@ export interface MarkdownRendererProps {
26
26
  text: string;
27
27
  }
28
28
  export declare const MarkdownRenderer: React.FC<MarkdownRendererProps>;
29
- //# sourceMappingURL=MarkdownRenderer.d.ts.map
@@ -152,4 +152,3 @@ function extractInlineText(tokens) {
152
152
  })
153
153
  .join("");
154
154
  }
155
- //# sourceMappingURL=MarkdownRenderer.js.map
@@ -9,7 +9,7 @@
9
9
  * Visual: rounded border in brand red on dark background, slight inset
10
10
  * from the turn body. Errors render with the error red.
11
11
  */
12
- import React from "react";
12
+ import type React from "react";
13
13
  import type { ToolCallRecord } from "../types.js";
14
14
  export interface ToolCallCardProps {
15
15
  call: ToolCallRecord;
@@ -17,4 +17,3 @@ export interface ToolCallCardProps {
17
17
  expanded: boolean;
18
18
  }
19
19
  export declare const ToolCallCard: React.FC<ToolCallCardProps>;
20
- //# sourceMappingURL=ToolCallCard.d.ts.map
@@ -17,4 +17,3 @@ function truncate(s, max) {
17
17
  return s;
18
18
  return s.slice(0, max - 1) + "…";
19
19
  }
20
- //# sourceMappingURL=ToolCallCard.js.map
@@ -13,8 +13,8 @@
13
13
  * window — distills the buffer into a memory, replaces it with a single
14
14
  * system reference. Transparent to the user.
15
15
  */
16
- import { Turn } from "./types.js";
17
- export interface FocusSnapshot {
16
+ import type { Turn } from "./types.js";
17
+ interface FocusSnapshot {
18
18
  /** Focus name. */
19
19
  topic: string;
20
20
  /** When this snapshot was created. */
@@ -67,4 +67,4 @@ export declare function shouldAutoSummarize(buffer: Turn[], contextWindowTokens:
67
67
  * Used in Phase 7's auto-summarize and exposed for /save-turn-style flows.
68
68
  */
69
69
  export declare function buildSummaryPrompt(buffer: Turn[], focus: string | null): string;
70
- //# sourceMappingURL=focus.d.ts.map
70
+ export {};
@@ -117,4 +117,3 @@ ${transcript}
117
117
 
118
118
  Output the distilled memory as plain markdown. No fences, no commentary.`;
119
119
  }
120
- //# sourceMappingURL=focus.js.map
@@ -8,9 +8,9 @@
8
8
  * - Mount the ink ChatApp
9
9
  * - On exit, flush a session_end event
10
10
  */
11
- import { GnosysConfig } from "../config.js";
12
- import { SessionEvent } from "./session.js";
13
- import { Turn } from "./types.js";
11
+ import type { GnosysConfig } from "../config.js";
12
+ import { type SessionEvent } from "./session.js";
13
+ import type { Turn } from "./types.js";
14
14
  export interface StartChatOptions {
15
15
  config: GnosysConfig;
16
16
  resume?: string;
@@ -29,4 +29,3 @@ export declare function startChat(opts: StartChatOptions): Promise<void>;
29
29
  export declare function printSessionList(limit?: number): void;
30
30
  /** Print search results across all session logs (for `gnosys chat --search`). */
31
31
  export declare function printSearchResults(query: string, limit?: number): void;
32
- //# sourceMappingURL=index.d.ts.map
@@ -11,6 +11,7 @@
11
11
  import { GnosysDB } from "../db.js";
12
12
  import { startSession, appendEvent, readSession, listSessions, searchSessions, } from "./session.js";
13
13
  import { resolveTaskModel } from "../config.js";
14
+ import { logError } from "../log.js";
14
15
  /** Reconstruct the conversation buffer from session log events. */
15
16
  export function bufferFromEvents(events) {
16
17
  const turns = [];
@@ -76,7 +77,7 @@ export async function startChat(opts) {
76
77
  if (opts.resume) {
77
78
  const events = readSession(opts.resume);
78
79
  if (events.length === 0) {
79
- console.error(`Session not found: ${opts.resume}`);
80
+ logError(new Error(`Session not found: ${opts.resume}`), { module: "chat", op: "resume" });
80
81
  process.exit(1);
81
82
  }
82
83
  sessionId = opts.resume;
@@ -155,4 +156,3 @@ export function printSearchResults(query, limit = 30) {
155
156
  console.log(` ${m.sessionId.slice(0, 12)}… [${m.event.type}] ${preview}`);
156
157
  }
157
158
  }
158
- //# sourceMappingURL=index.js.map
@@ -13,7 +13,7 @@
13
13
  * Phase 5 wires patterns whose target commands already exist (Phases 2–4).
14
14
  * /focus and /branch (Phase 7) are added in their own phase.
15
15
  */
16
- import { GnosysConfig } from "../config.js";
16
+ import type { GnosysConfig } from "../config.js";
17
17
  export type InferredIntent = {
18
18
  command: "/pin";
19
19
  args: string[];
@@ -55,25 +55,10 @@ export type InferredIntent = {
55
55
  confidence: "high" | "medium";
56
56
  matchedPattern?: string;
57
57
  };
58
- export interface PatternRule {
59
- /** Regex to match. Capture group 1 is the args text (joined as `args[0]` if present). */
60
- pattern: RegExp;
61
- command: InferredIntent["command"];
62
- /** Whether this is a destructive action that needs confirm-before-fire. */
63
- destructive: boolean;
64
- /** Human-readable description shown in the confirm prompt. */
65
- description: string;
66
- }
67
- export declare const PATTERNS: PatternRule[];
68
58
  /** Try to match a user input against the pattern rules. Returns null if no pattern fires. */
69
59
  export declare function matchPattern(userInput: string): InferredIntent | null;
70
60
  /** True when the input has imperative-y signals — a hint that LLM classification might pay off. */
71
61
  export declare function hasImperativeSignal(userInput: string): boolean;
72
- /**
73
- * Optional: ask a cheap LLM to classify the intent.
74
- * Returns null when the LLM is unavailable or the response can't be parsed.
75
- */
76
- export declare function classifyWithLLM(config: GnosysConfig, userInput: string): Promise<InferredIntent | null>;
77
62
  /** Whether the inferred command is destructive enough to warrant a confirm prompt. */
78
63
  export declare function isDestructive(command: InferredIntent["command"]): boolean;
79
64
  /** Render a [Y/n/edit] prompt label for the inferred intent. */
@@ -97,4 +82,3 @@ export declare function newAcceptanceLog(): IntentAcceptanceLog;
97
82
  export declare function shouldAutoAccept(log: IntentAcceptanceLog, matchedPattern: string | undefined): boolean;
98
83
  /** Record a confirmed acceptance of a pattern. */
99
84
  export declare function recordAcceptance(log: IntentAcceptanceLog, matchedPattern: string | undefined): void;
100
- //# sourceMappingURL=intent.d.ts.map
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import { getLLMProvider } from "../llm.js";
17
17
  // Patterns are ordered most specific → most general. First match wins.
18
- export const PATTERNS = [
18
+ const PATTERNS = [
19
19
  // Quit/exit
20
20
  {
21
21
  pattern: /^\s*(?:thanks[,.\s]*)?(?:that(?:'s| is) all|i'?m done|goodbye|bye|quit|exit)\s*[.!]?\s*$/i,
@@ -105,7 +105,7 @@ export function hasImperativeSignal(userInput) {
105
105
  * Optional: ask a cheap LLM to classify the intent.
106
106
  * Returns null when the LLM is unavailable or the response can't be parsed.
107
107
  */
108
- export async function classifyWithLLM(config, userInput) {
108
+ async function classifyWithLLM(config, userInput) {
109
109
  try {
110
110
  const provider = getLLMProvider(config, "structuring");
111
111
  const prompt = `You are a router. Map this user message to ONE of these chat commands, or "none" if it's just a normal chat turn.
@@ -189,4 +189,3 @@ export function recordAcceptance(log, matchedPattern) {
189
189
  return;
190
190
  log.acceptCounts.set(matchedPattern, (log.acceptCounts.get(matchedPattern) ?? 0) + 1);
191
191
  }
192
- //# sourceMappingURL=intent.js.map
@@ -5,11 +5,11 @@
5
5
  * Phase 3 adds recall integration; Phase 5 adds intent classification;
6
6
  * Phase 6 adds gnosys-choose protocol; Phase 7 adds focus-aware system prompt.
7
7
  */
8
- import { GnosysConfig } from "../config.js";
9
- import { LLMProvider } from "../llm.js";
10
- import { LLMProviderName } from "../config.js";
11
- import { Turn } from "./types.js";
12
- import { RecalledMemory } from "./recall.js";
8
+ import { type GnosysConfig } from "../config.js";
9
+ import { type LLMProvider } from "../llm.js";
10
+ import type { LLMProviderName } from "../config.js";
11
+ import type { Turn } from "./types.js";
12
+ import { type RecalledMemory } from "./recall.js";
13
13
  export interface LLMTurnOptions {
14
14
  /** Conversation buffer to send (will be formatted into a single prompt). */
15
15
  buffer: Turn[];
@@ -52,4 +52,3 @@ export interface LLMTurnResult {
52
52
  export declare function runTurn(config: GnosysConfig, opts: LLMTurnOptions): Promise<LLMTurnResult>;
53
53
  /** Build a provider for /provider switching mid-session. */
54
54
  export declare function buildProvider(config: GnosysConfig, providerName: LLMProviderName, model?: string): LLMProvider;
55
- //# sourceMappingURL=llmTurn.d.ts.map
@@ -103,4 +103,3 @@ export function buildProvider(config, providerName, model) {
103
103
  const resolvedModel = model ?? getProviderModel(config, providerName);
104
104
  return createProvider(providerName, resolvedModel, config);
105
105
  }
106
- //# sourceMappingURL=llmTurn.js.map
@@ -5,8 +5,8 @@
5
5
  * for injection into the LLM system prompt. Always includes pinned memories
6
6
  * regardless of search relevance.
7
7
  */
8
- import { GnosysDB } from "../db.js";
9
- import { Turn } from "./types.js";
8
+ import type { GnosysDB } from "../db.js";
9
+ import type { Turn } from "./types.js";
10
10
  export type RecallScope = "project" | "user" | "global" | "federated";
11
11
  export interface RecallOptions {
12
12
  /** Search query — usually the latest user input plus a tail of conversation. */
@@ -55,4 +55,3 @@ export declare function runRecall(db: GnosysDB, opts: RecallOptions): RecallResu
55
55
  export declare function formatRecallForPrompt(memories: RecalledMemory[]): string;
56
56
  /** Reinforce a memory: bump modified date so it's surfaced as recent. */
57
57
  export declare function reinforceMemory(db: GnosysDB, memoryId: string): boolean;
58
- //# sourceMappingURL=recall.d.ts.map
@@ -49,7 +49,7 @@ export function runRecall(db, opts) {
49
49
  projectId: opts.projectId,
50
50
  scopeFilter: scopeFilter,
51
51
  });
52
- let considered = results.length + opts.pinnedIds.length;
52
+ const considered = results.length + opts.pinnedIds.length;
53
53
  for (const r of results) {
54
54
  if (memories.length - opts.pinnedIds.length >= limit)
55
55
  break;
@@ -106,4 +106,3 @@ export function reinforceMemory(db, memoryId) {
106
106
  });
107
107
  return true;
108
108
  }
109
- //# sourceMappingURL=recall.js.map
@@ -15,8 +15,8 @@
15
15
  * └────────────────────────────────────────┘
16
16
  */
17
17
  import React from "react";
18
- import { ChatHeaderInfo, Turn } from "./types.js";
19
- import { GnosysConfig } from "../config.js";
18
+ import type { ChatHeaderInfo, Turn } from "./types.js";
19
+ import type { GnosysConfig } from "../config.js";
20
20
  export interface ChatAppProps {
21
21
  initialHeader: ChatHeaderInfo;
22
22
  initialBuffer: Turn[];
@@ -27,4 +27,3 @@ export interface ChatAppProps {
27
27
  onExit?: () => void;
28
28
  }
29
29
  export declare const ChatApp: React.FC<ChatAppProps>;
30
- //# sourceMappingURL=render.d.ts.map
@@ -847,4 +847,3 @@ const StatusLine = ({ status }) => {
847
847
  return _jsxs(Text, { color: THEME.error, children: ["error: ", status.message] });
848
848
  }
849
849
  };
850
- //# sourceMappingURL=render.js.map
@@ -118,4 +118,3 @@ export declare function searchSessions(query: string, limit?: number): Array<{
118
118
  sessionId: string;
119
119
  event: SessionEvent;
120
120
  }>;
121
- //# sourceMappingURL=session.d.ts.map
@@ -145,4 +145,3 @@ export function searchSessions(query, limit = 50) {
145
145
  }
146
146
  return matches;
147
147
  }
148
- //# sourceMappingURL=session.js.map
@@ -36,4 +36,3 @@ export declare const ROLES: {
36
36
  readonly toolCallBorder: "#C04C4C";
37
37
  readonly spinner: "#C04C4C";
38
38
  };
39
- //# sourceMappingURL=theme.d.ts.map
@@ -40,4 +40,3 @@ export const ROLES = {
40
40
  toolCallBorder: THEME.accent,
41
41
  spinner: THEME.accent,
42
42
  };
43
- //# sourceMappingURL=theme.js.map
@@ -12,7 +12,7 @@
12
12
  * read in one go). Each parse returns the tool name + key/value args + the
13
13
  * surrounding text so the renderer can show the conversation cleanly.
14
14
  */
15
- export interface ParsedToolCall {
15
+ interface ParsedToolCall {
16
16
  tool: string;
17
17
  args: Record<string, string>;
18
18
  /** Source text of the full fence (for fail-soft display when needed). */
@@ -51,4 +51,4 @@ export declare function parseToolBody(body: string): {
51
51
  tool: string;
52
52
  args: Record<string, string>;
53
53
  };
54
- //# sourceMappingURL=toolFence.d.ts.map
54
+ export {};
@@ -87,4 +87,3 @@ export function parseToolBody(body) {
87
87
  }
88
88
  return { tool, args };
89
89
  }
90
- //# sourceMappingURL=toolFence.js.map