@ikarmic/forge-core 4.4.0 → 5.0.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 (573) hide show
  1. package/LICENSE +44 -21
  2. package/README.md +2 -2
  3. package/dist/agent/agent.d.ts +0 -1
  4. package/dist/agent/agent.js +84 -32
  5. package/dist/agent/architect.d.ts +3 -1
  6. package/dist/agent/architect.js +1 -1
  7. package/dist/agent/cache-hints.d.ts +0 -1
  8. package/dist/agent/cache-hints.js +0 -1
  9. package/dist/agent/cost-router.d.ts +0 -1
  10. package/dist/agent/cost-router.js +2 -1
  11. package/dist/agent/enhance-prompt.d.ts +7 -0
  12. package/dist/agent/enhance-prompt.js +30 -0
  13. package/dist/agent/index.d.ts +0 -1
  14. package/dist/agent/index.js +0 -1
  15. package/dist/agent/loop-guard.d.ts +21 -0
  16. package/dist/agent/loop-guard.js +41 -0
  17. package/dist/agent/prompts.d.ts +0 -1
  18. package/dist/agent/prompts.js +0 -1
  19. package/dist/agent/think-tags.d.ts +0 -1
  20. package/dist/agent/think-tags.js +0 -1
  21. package/dist/agent/verify.d.ts +0 -1
  22. package/dist/agent/verify.js +0 -1
  23. package/dist/ai-comments/index.d.ts +0 -1
  24. package/dist/ai-comments/index.js +0 -1
  25. package/dist/attachments.d.ts +46 -0
  26. package/dist/attachments.js +178 -0
  27. package/dist/browser/cdp.d.ts +0 -1
  28. package/dist/browser/cdp.js +0 -1
  29. package/dist/browser/chrome.d.ts +0 -1
  30. package/dist/browser/chrome.js +0 -1
  31. package/dist/browser/session.d.ts +0 -1
  32. package/dist/browser/session.js +0 -1
  33. package/dist/checkpoints/index.d.ts +0 -1
  34. package/dist/checkpoints/index.js +0 -1
  35. package/dist/checkpoints/store.d.ts +0 -1
  36. package/dist/checkpoints/store.js +0 -1
  37. package/dist/checkpoints/types.d.ts +0 -1
  38. package/dist/checkpoints/types.js +0 -1
  39. package/dist/code-index/builder.d.ts +0 -1
  40. package/dist/code-index/builder.js +4 -1
  41. package/dist/code-index/index-store.d.ts +0 -1
  42. package/dist/code-index/index-store.js +0 -1
  43. package/dist/code-index/parser.d.ts +0 -1
  44. package/dist/code-index/parser.js +0 -1
  45. package/dist/code-index/types.d.ts +0 -1
  46. package/dist/code-index/types.js +0 -1
  47. package/dist/commands/custom-commands.d.ts +24 -0
  48. package/dist/commands/custom-commands.js +98 -0
  49. package/dist/config-file.d.ts +4 -1
  50. package/dist/config-file.js +0 -1
  51. package/dist/config.d.ts +0 -1
  52. package/dist/config.js +0 -1
  53. package/dist/context/compaction.d.ts +0 -1
  54. package/dist/context/compaction.js +17 -3
  55. package/dist/context/mask.d.ts +0 -1
  56. package/dist/context/mask.js +1 -2
  57. package/dist/credentials/index.d.ts +0 -1
  58. package/dist/credentials/index.js +0 -1
  59. package/dist/credentials/types.d.ts +0 -1
  60. package/dist/credentials/types.js +0 -1
  61. package/dist/diff/index.d.ts +0 -1
  62. package/dist/diff/index.js +0 -1
  63. package/dist/diff/unified-diff.d.ts +0 -1
  64. package/dist/diff/unified-diff.js +42 -16
  65. package/dist/git/auto-commit.d.ts +1 -2
  66. package/dist/git/auto-commit.js +17 -5
  67. package/dist/git/index.d.ts +0 -1
  68. package/dist/git/index.js +0 -1
  69. package/dist/github/github-tools.d.ts +83 -0
  70. package/dist/github/github-tools.js +175 -0
  71. package/dist/hooks/agent-runner.d.ts +0 -1
  72. package/dist/hooks/agent-runner.js +0 -1
  73. package/dist/hooks/bus.d.ts +0 -1
  74. package/dist/hooks/bus.js +0 -1
  75. package/dist/hooks/config.d.ts +0 -1
  76. package/dist/hooks/config.js +0 -1
  77. package/dist/hooks/events.d.ts +0 -1
  78. package/dist/hooks/events.js +0 -1
  79. package/dist/hooks/index.d.ts +0 -1
  80. package/dist/hooks/index.js +0 -1
  81. package/dist/hooks/loader.d.ts +0 -1
  82. package/dist/hooks/loader.js +0 -1
  83. package/dist/hooks/runner.d.ts +0 -1
  84. package/dist/hooks/runner.js +0 -1
  85. package/dist/hooks/watch-coalescer.d.ts +0 -1
  86. package/dist/hooks/watch-coalescer.js +0 -1
  87. package/dist/hooks/watch-ignore.d.ts +0 -1
  88. package/dist/hooks/watch-ignore.js +0 -1
  89. package/dist/hooks/watcher.d.ts +0 -1
  90. package/dist/hooks/watcher.js +0 -1
  91. package/dist/index.d.ts +21 -9
  92. package/dist/index.js +16 -5
  93. package/dist/lazy-model.d.ts +0 -1
  94. package/dist/lazy-model.js +0 -1
  95. package/dist/lint/auto-lint.d.ts +0 -1
  96. package/dist/lint/auto-lint.js +0 -1
  97. package/dist/lint/index.d.ts +0 -1
  98. package/dist/lint/index.js +0 -1
  99. package/dist/lsp/client.d.ts +0 -1
  100. package/dist/lsp/client.js +0 -1
  101. package/dist/lsp/diagnostics.d.ts +0 -1
  102. package/dist/lsp/diagnostics.js +0 -1
  103. package/dist/lsp/index.d.ts +0 -1
  104. package/dist/lsp/index.js +0 -1
  105. package/dist/mcp/catalog.d.ts +0 -1
  106. package/dist/mcp/catalog.js +0 -1
  107. package/dist/mcp/index.d.ts +0 -1
  108. package/dist/mcp/index.js +0 -1
  109. package/dist/mcp/json-schema-to-zod.d.ts +0 -1
  110. package/dist/mcp/json-schema-to-zod.js +0 -1
  111. package/dist/mcp/manager.d.ts +0 -1
  112. package/dist/mcp/manager.js +0 -1
  113. package/dist/mcp/marketplace-types.d.ts +0 -1
  114. package/dist/mcp/marketplace-types.js +0 -1
  115. package/dist/mcp/marketplace.d.ts +0 -1
  116. package/dist/mcp/marketplace.js +0 -1
  117. package/dist/mcp/mcp-client.d.ts +0 -1
  118. package/dist/mcp/mcp-client.js +0 -1
  119. package/dist/mcp/mcp-config.d.ts +0 -1
  120. package/dist/mcp/mcp-config.js +0 -1
  121. package/dist/mcp/registry.d.ts +0 -1
  122. package/dist/mcp/registry.js +0 -1
  123. package/dist/memory/memory-store.d.ts +57 -11
  124. package/dist/memory/memory-store.js +236 -70
  125. package/dist/memory/rank.d.ts +20 -0
  126. package/dist/memory/rank.js +64 -0
  127. package/dist/memory/stale.d.ts +18 -0
  128. package/dist/memory/stale.js +45 -0
  129. package/dist/model-alias.d.ts +0 -1
  130. package/dist/model-alias.js +0 -1
  131. package/dist/model-catalog.d.ts +0 -1
  132. package/dist/model-catalog.js +0 -1
  133. package/dist/model-list.d.ts +0 -1
  134. package/dist/model-list.js +0 -1
  135. package/dist/orchestrator/board-tools.d.ts +0 -1
  136. package/dist/orchestrator/board-tools.js +0 -1
  137. package/dist/orchestrator/board.d.ts +0 -1
  138. package/dist/orchestrator/board.js +0 -1
  139. package/dist/orchestrator/index.d.ts +0 -1
  140. package/dist/orchestrator/index.js +0 -1
  141. package/dist/orchestrator/orchestrator.d.ts +0 -1
  142. package/dist/orchestrator/orchestrator.js +0 -1
  143. package/dist/orchestrator/router.d.ts +0 -1
  144. package/dist/orchestrator/router.js +0 -1
  145. package/dist/orchestrator/specialists-registry.d.ts +0 -1
  146. package/dist/orchestrator/specialists-registry.js +0 -1
  147. package/dist/orchestrator/specialists.d.ts +0 -1
  148. package/dist/orchestrator/specialists.js +5 -6
  149. package/dist/orchestrator/types.d.ts +0 -1
  150. package/dist/orchestrator/types.js +0 -1
  151. package/dist/plugins/index.d.ts +0 -1
  152. package/dist/plugins/index.js +0 -1
  153. package/dist/plugins/install.d.ts +0 -1
  154. package/dist/plugins/install.js +0 -1
  155. package/dist/plugins/loader.d.ts +0 -1
  156. package/dist/plugins/loader.js +0 -1
  157. package/dist/policy/audit.d.ts +0 -1
  158. package/dist/policy/audit.js +0 -1
  159. package/dist/policy/policy.d.ts +0 -1
  160. package/dist/policy/policy.js +0 -1
  161. package/dist/policy/proxy.d.ts +0 -1
  162. package/dist/policy/proxy.js +0 -1
  163. package/dist/pricing.d.ts +0 -1
  164. package/dist/pricing.js +0 -1
  165. package/dist/providers.d.ts +0 -1
  166. package/dist/providers.js +0 -1
  167. package/dist/repomap/index.d.ts +0 -1
  168. package/dist/repomap/index.js +0 -1
  169. package/dist/repomap/repo-map.d.ts +0 -1
  170. package/dist/repomap/repo-map.js +0 -1
  171. package/dist/semantic/chunker.d.ts +0 -1
  172. package/dist/semantic/chunker.js +0 -1
  173. package/dist/semantic/embedder.d.ts +0 -1
  174. package/dist/semantic/embedder.js +0 -1
  175. package/dist/semantic/semantic-index.d.ts +0 -1
  176. package/dist/semantic/semantic-index.js +4 -1
  177. package/dist/semantic/vector-store.d.ts +0 -1
  178. package/dist/semantic/vector-store.js +0 -1
  179. package/dist/sessions/index.d.ts +2 -1
  180. package/dist/sessions/index.js +2 -1
  181. package/dist/sessions/prune.d.ts +23 -0
  182. package/dist/sessions/prune.js +35 -0
  183. package/dist/sessions/search.d.ts +22 -0
  184. package/dist/sessions/search.js +66 -0
  185. package/dist/sessions/session-export.d.ts +0 -1
  186. package/dist/sessions/session-export.js +0 -1
  187. package/dist/sessions/session-store.d.ts +0 -1
  188. package/dist/sessions/session-store.js +0 -1
  189. package/dist/sessions/watch.d.ts +0 -1
  190. package/dist/sessions/watch.js +0 -1
  191. package/dist/settings-export.d.ts +0 -1
  192. package/dist/settings-export.js +0 -1
  193. package/dist/skills/activator.d.ts +0 -1
  194. package/dist/skills/activator.js +0 -1
  195. package/dist/skills/index.d.ts +0 -1
  196. package/dist/skills/index.js +0 -1
  197. package/dist/skills/loader.d.ts +0 -1
  198. package/dist/skills/loader.js +0 -1
  199. package/dist/skills/marketplace-types.d.ts +0 -1
  200. package/dist/skills/marketplace-types.js +0 -1
  201. package/dist/skills/marketplace.d.ts +0 -1
  202. package/dist/skills/marketplace.js +0 -1
  203. package/dist/skills/parser.d.ts +0 -1
  204. package/dist/skills/parser.js +0 -1
  205. package/dist/skills/types.d.ts +0 -1
  206. package/dist/skills/types.js +0 -1
  207. package/dist/specs/generate.d.ts +0 -1
  208. package/dist/specs/generate.js +0 -1
  209. package/dist/specs/index.d.ts +2 -1
  210. package/dist/specs/index.js +1 -1
  211. package/dist/specs/store.d.ts +7 -1
  212. package/dist/specs/store.js +33 -1
  213. package/dist/specs/sync.d.ts +29 -0
  214. package/dist/specs/sync.js +155 -0
  215. package/dist/specs/tasks-parser.d.ts +0 -1
  216. package/dist/specs/tasks-parser.js +0 -1
  217. package/dist/specs/types.d.ts +2 -1
  218. package/dist/specs/types.js +0 -1
  219. package/dist/steering/glob.d.ts +0 -1
  220. package/dist/steering/glob.js +0 -1
  221. package/dist/steering/index.d.ts +0 -1
  222. package/dist/steering/index.js +0 -1
  223. package/dist/steering/loader.d.ts +0 -1
  224. package/dist/steering/loader.js +0 -1
  225. package/dist/steering/project-instructions.d.ts +0 -1
  226. package/dist/steering/project-instructions.js +0 -1
  227. package/dist/steering/select.d.ts +0 -1
  228. package/dist/steering/select.js +0 -1
  229. package/dist/steering/types.d.ts +0 -1
  230. package/dist/steering/types.js +0 -1
  231. package/dist/structured/index.d.ts +0 -1
  232. package/dist/structured/index.js +0 -1
  233. package/dist/structured/retry.d.ts +0 -1
  234. package/dist/structured/retry.js +0 -1
  235. package/dist/structured/schema.d.ts +0 -1
  236. package/dist/structured/schema.js +0 -1
  237. package/dist/tools/browser-tools.d.ts +0 -1
  238. package/dist/tools/browser-tools.js +0 -1
  239. package/dist/tools/codebase-search.d.ts +0 -1
  240. package/dist/tools/codebase-search.js +0 -1
  241. package/dist/tools/command-allow.d.ts +0 -1
  242. package/dist/tools/command-allow.js +0 -1
  243. package/dist/tools/edit-file.d.ts +0 -1
  244. package/dist/tools/edit-file.js +0 -1
  245. package/dist/tools/fetch-url.d.ts +0 -1
  246. package/dist/tools/fetch-url.js +0 -1
  247. package/dist/tools/find-references.d.ts +0 -1
  248. package/dist/tools/find-references.js +0 -1
  249. package/dist/tools/find-symbol.d.ts +0 -1
  250. package/dist/tools/find-symbol.js +0 -1
  251. package/dist/tools/ignore-rules.d.ts +15 -0
  252. package/dist/tools/ignore-rules.js +84 -0
  253. package/dist/tools/index.d.ts +3 -3
  254. package/dist/tools/index.js +5 -3
  255. package/dist/tools/list-files.d.ts +3 -1
  256. package/dist/tools/list-files.js +8 -1
  257. package/dist/tools/list-symbols.d.ts +0 -1
  258. package/dist/tools/list-symbols.js +0 -1
  259. package/dist/tools/memory.d.ts +34 -2
  260. package/dist/tools/memory.js +118 -26
  261. package/dist/tools/notebook.d.ts +69 -0
  262. package/dist/tools/notebook.js +163 -0
  263. package/dist/tools/policy.d.ts +0 -1
  264. package/dist/tools/policy.js +0 -1
  265. package/dist/tools/read-file.d.ts +8 -2
  266. package/dist/tools/read-file.js +19 -2
  267. package/dist/tools/read-image.d.ts +0 -1
  268. package/dist/tools/read-image.js +0 -1
  269. package/dist/tools/read-only.d.ts +0 -1
  270. package/dist/tools/read-only.js +0 -1
  271. package/dist/tools/redact.d.ts +0 -1
  272. package/dist/tools/redact.js +0 -1
  273. package/dist/tools/result-cache.d.ts +0 -1
  274. package/dist/tools/result-cache.js +0 -1
  275. package/dist/tools/run-command.d.ts +0 -1
  276. package/dist/tools/run-command.js +0 -1
  277. package/dist/tools/sandbox-loader.d.ts +0 -1
  278. package/dist/tools/sandbox-loader.js +0 -1
  279. package/dist/tools/search-files.d.ts +5 -3
  280. package/dist/tools/search-files.js +8 -1
  281. package/dist/tools/shared.d.ts +0 -1
  282. package/dist/tools/shared.js +0 -1
  283. package/dist/tools/sub-agent.d.ts +0 -1
  284. package/dist/tools/sub-agent.js +0 -1
  285. package/dist/tools/web-search.d.ts +55 -0
  286. package/dist/tools/web-search.js +131 -0
  287. package/dist/tools/write-file.d.ts +0 -1
  288. package/dist/tools/write-file.js +0 -1
  289. package/dist/types.d.ts +43 -2
  290. package/dist/types.js +0 -1
  291. package/dist/verify/detect.d.ts +0 -1
  292. package/dist/verify/detect.js +0 -1
  293. package/dist/verify/index.d.ts +0 -1
  294. package/dist/verify/index.js +0 -1
  295. package/dist/worktree/branch-ops.d.ts +0 -1
  296. package/dist/worktree/branch-ops.js +0 -1
  297. package/dist/worktree/index.d.ts +0 -1
  298. package/dist/worktree/index.js +0 -1
  299. package/dist/worktree/worktree.d.ts +0 -1
  300. package/dist/worktree/worktree.js +0 -1
  301. package/package.json +4 -2
  302. package/dist/agent/agent.d.ts.map +0 -1
  303. package/dist/agent/agent.js.map +0 -1
  304. package/dist/agent/architect.d.ts.map +0 -1
  305. package/dist/agent/architect.js.map +0 -1
  306. package/dist/agent/cache-hints.d.ts.map +0 -1
  307. package/dist/agent/cache-hints.js.map +0 -1
  308. package/dist/agent/cost-router.d.ts.map +0 -1
  309. package/dist/agent/cost-router.js.map +0 -1
  310. package/dist/agent/index.d.ts.map +0 -1
  311. package/dist/agent/index.js.map +0 -1
  312. package/dist/agent/prompts.d.ts.map +0 -1
  313. package/dist/agent/prompts.js.map +0 -1
  314. package/dist/agent/think-tags.d.ts.map +0 -1
  315. package/dist/agent/think-tags.js.map +0 -1
  316. package/dist/agent/verify.d.ts.map +0 -1
  317. package/dist/agent/verify.js.map +0 -1
  318. package/dist/ai-comments/index.d.ts.map +0 -1
  319. package/dist/ai-comments/index.js.map +0 -1
  320. package/dist/browser/cdp.d.ts.map +0 -1
  321. package/dist/browser/cdp.js.map +0 -1
  322. package/dist/browser/chrome.d.ts.map +0 -1
  323. package/dist/browser/chrome.js.map +0 -1
  324. package/dist/browser/session.d.ts.map +0 -1
  325. package/dist/browser/session.js.map +0 -1
  326. package/dist/checkpoints/index.d.ts.map +0 -1
  327. package/dist/checkpoints/index.js.map +0 -1
  328. package/dist/checkpoints/store.d.ts.map +0 -1
  329. package/dist/checkpoints/store.js.map +0 -1
  330. package/dist/checkpoints/types.d.ts.map +0 -1
  331. package/dist/checkpoints/types.js.map +0 -1
  332. package/dist/code-index/builder.d.ts.map +0 -1
  333. package/dist/code-index/builder.js.map +0 -1
  334. package/dist/code-index/index-store.d.ts.map +0 -1
  335. package/dist/code-index/index-store.js.map +0 -1
  336. package/dist/code-index/parser.d.ts.map +0 -1
  337. package/dist/code-index/parser.js.map +0 -1
  338. package/dist/code-index/types.d.ts.map +0 -1
  339. package/dist/code-index/types.js.map +0 -1
  340. package/dist/config-file.d.ts.map +0 -1
  341. package/dist/config-file.js.map +0 -1
  342. package/dist/config.d.ts.map +0 -1
  343. package/dist/config.js.map +0 -1
  344. package/dist/context/compaction.d.ts.map +0 -1
  345. package/dist/context/compaction.js.map +0 -1
  346. package/dist/context/mask.d.ts.map +0 -1
  347. package/dist/context/mask.js.map +0 -1
  348. package/dist/credentials/index.d.ts.map +0 -1
  349. package/dist/credentials/index.js.map +0 -1
  350. package/dist/credentials/types.d.ts.map +0 -1
  351. package/dist/credentials/types.js.map +0 -1
  352. package/dist/diff/index.d.ts.map +0 -1
  353. package/dist/diff/index.js.map +0 -1
  354. package/dist/diff/unified-diff.d.ts.map +0 -1
  355. package/dist/diff/unified-diff.js.map +0 -1
  356. package/dist/git/auto-commit.d.ts.map +0 -1
  357. package/dist/git/auto-commit.js.map +0 -1
  358. package/dist/git/index.d.ts.map +0 -1
  359. package/dist/git/index.js.map +0 -1
  360. package/dist/hooks/agent-runner.d.ts.map +0 -1
  361. package/dist/hooks/agent-runner.js.map +0 -1
  362. package/dist/hooks/bus.d.ts.map +0 -1
  363. package/dist/hooks/bus.js.map +0 -1
  364. package/dist/hooks/config.d.ts.map +0 -1
  365. package/dist/hooks/config.js.map +0 -1
  366. package/dist/hooks/events.d.ts.map +0 -1
  367. package/dist/hooks/events.js.map +0 -1
  368. package/dist/hooks/index.d.ts.map +0 -1
  369. package/dist/hooks/index.js.map +0 -1
  370. package/dist/hooks/loader.d.ts.map +0 -1
  371. package/dist/hooks/loader.js.map +0 -1
  372. package/dist/hooks/runner.d.ts.map +0 -1
  373. package/dist/hooks/runner.js.map +0 -1
  374. package/dist/hooks/watch-coalescer.d.ts.map +0 -1
  375. package/dist/hooks/watch-coalescer.js.map +0 -1
  376. package/dist/hooks/watch-ignore.d.ts.map +0 -1
  377. package/dist/hooks/watch-ignore.js.map +0 -1
  378. package/dist/hooks/watcher.d.ts.map +0 -1
  379. package/dist/hooks/watcher.js.map +0 -1
  380. package/dist/index.d.ts.map +0 -1
  381. package/dist/index.js.map +0 -1
  382. package/dist/lazy-model.d.ts.map +0 -1
  383. package/dist/lazy-model.js.map +0 -1
  384. package/dist/lint/auto-lint.d.ts.map +0 -1
  385. package/dist/lint/auto-lint.js.map +0 -1
  386. package/dist/lint/index.d.ts.map +0 -1
  387. package/dist/lint/index.js.map +0 -1
  388. package/dist/lsp/client.d.ts.map +0 -1
  389. package/dist/lsp/client.js.map +0 -1
  390. package/dist/lsp/diagnostics.d.ts.map +0 -1
  391. package/dist/lsp/diagnostics.js.map +0 -1
  392. package/dist/lsp/index.d.ts.map +0 -1
  393. package/dist/lsp/index.js.map +0 -1
  394. package/dist/mcp/catalog.d.ts.map +0 -1
  395. package/dist/mcp/catalog.js.map +0 -1
  396. package/dist/mcp/index.d.ts.map +0 -1
  397. package/dist/mcp/index.js.map +0 -1
  398. package/dist/mcp/json-schema-to-zod.d.ts.map +0 -1
  399. package/dist/mcp/json-schema-to-zod.js.map +0 -1
  400. package/dist/mcp/manager.d.ts.map +0 -1
  401. package/dist/mcp/manager.js.map +0 -1
  402. package/dist/mcp/marketplace-types.d.ts.map +0 -1
  403. package/dist/mcp/marketplace-types.js.map +0 -1
  404. package/dist/mcp/marketplace.d.ts.map +0 -1
  405. package/dist/mcp/marketplace.js.map +0 -1
  406. package/dist/mcp/mcp-client.d.ts.map +0 -1
  407. package/dist/mcp/mcp-client.js.map +0 -1
  408. package/dist/mcp/mcp-config.d.ts.map +0 -1
  409. package/dist/mcp/mcp-config.js.map +0 -1
  410. package/dist/mcp/registry.d.ts.map +0 -1
  411. package/dist/mcp/registry.js.map +0 -1
  412. package/dist/memory/memory-store.d.ts.map +0 -1
  413. package/dist/memory/memory-store.js.map +0 -1
  414. package/dist/model-alias.d.ts.map +0 -1
  415. package/dist/model-alias.js.map +0 -1
  416. package/dist/model-catalog.d.ts.map +0 -1
  417. package/dist/model-catalog.js.map +0 -1
  418. package/dist/model-list.d.ts.map +0 -1
  419. package/dist/model-list.js.map +0 -1
  420. package/dist/orchestrator/board-tools.d.ts.map +0 -1
  421. package/dist/orchestrator/board-tools.js.map +0 -1
  422. package/dist/orchestrator/board.d.ts.map +0 -1
  423. package/dist/orchestrator/board.js.map +0 -1
  424. package/dist/orchestrator/index.d.ts.map +0 -1
  425. package/dist/orchestrator/index.js.map +0 -1
  426. package/dist/orchestrator/orchestrator.d.ts.map +0 -1
  427. package/dist/orchestrator/orchestrator.js.map +0 -1
  428. package/dist/orchestrator/router.d.ts.map +0 -1
  429. package/dist/orchestrator/router.js.map +0 -1
  430. package/dist/orchestrator/specialists-registry.d.ts.map +0 -1
  431. package/dist/orchestrator/specialists-registry.js.map +0 -1
  432. package/dist/orchestrator/specialists.d.ts.map +0 -1
  433. package/dist/orchestrator/specialists.js.map +0 -1
  434. package/dist/orchestrator/types.d.ts.map +0 -1
  435. package/dist/orchestrator/types.js.map +0 -1
  436. package/dist/plugins/index.d.ts.map +0 -1
  437. package/dist/plugins/index.js.map +0 -1
  438. package/dist/plugins/install.d.ts.map +0 -1
  439. package/dist/plugins/install.js.map +0 -1
  440. package/dist/plugins/loader.d.ts.map +0 -1
  441. package/dist/plugins/loader.js.map +0 -1
  442. package/dist/policy/audit.d.ts.map +0 -1
  443. package/dist/policy/audit.js.map +0 -1
  444. package/dist/policy/policy.d.ts.map +0 -1
  445. package/dist/policy/policy.js.map +0 -1
  446. package/dist/policy/proxy.d.ts.map +0 -1
  447. package/dist/policy/proxy.js.map +0 -1
  448. package/dist/pricing.d.ts.map +0 -1
  449. package/dist/pricing.js.map +0 -1
  450. package/dist/providers.d.ts.map +0 -1
  451. package/dist/providers.js.map +0 -1
  452. package/dist/repomap/index.d.ts.map +0 -1
  453. package/dist/repomap/index.js.map +0 -1
  454. package/dist/repomap/repo-map.d.ts.map +0 -1
  455. package/dist/repomap/repo-map.js.map +0 -1
  456. package/dist/semantic/chunker.d.ts.map +0 -1
  457. package/dist/semantic/chunker.js.map +0 -1
  458. package/dist/semantic/embedder.d.ts.map +0 -1
  459. package/dist/semantic/embedder.js.map +0 -1
  460. package/dist/semantic/semantic-index.d.ts.map +0 -1
  461. package/dist/semantic/semantic-index.js.map +0 -1
  462. package/dist/semantic/vector-store.d.ts.map +0 -1
  463. package/dist/semantic/vector-store.js.map +0 -1
  464. package/dist/sessions/index.d.ts.map +0 -1
  465. package/dist/sessions/index.js.map +0 -1
  466. package/dist/sessions/session-export.d.ts.map +0 -1
  467. package/dist/sessions/session-export.js.map +0 -1
  468. package/dist/sessions/session-store.d.ts.map +0 -1
  469. package/dist/sessions/session-store.js.map +0 -1
  470. package/dist/sessions/watch.d.ts.map +0 -1
  471. package/dist/sessions/watch.js.map +0 -1
  472. package/dist/settings-export.d.ts.map +0 -1
  473. package/dist/settings-export.js.map +0 -1
  474. package/dist/skills/activator.d.ts.map +0 -1
  475. package/dist/skills/activator.js.map +0 -1
  476. package/dist/skills/index.d.ts.map +0 -1
  477. package/dist/skills/index.js.map +0 -1
  478. package/dist/skills/loader.d.ts.map +0 -1
  479. package/dist/skills/loader.js.map +0 -1
  480. package/dist/skills/marketplace-types.d.ts.map +0 -1
  481. package/dist/skills/marketplace-types.js.map +0 -1
  482. package/dist/skills/marketplace.d.ts.map +0 -1
  483. package/dist/skills/marketplace.js.map +0 -1
  484. package/dist/skills/parser.d.ts.map +0 -1
  485. package/dist/skills/parser.js.map +0 -1
  486. package/dist/skills/types.d.ts.map +0 -1
  487. package/dist/skills/types.js.map +0 -1
  488. package/dist/specs/generate.d.ts.map +0 -1
  489. package/dist/specs/generate.js.map +0 -1
  490. package/dist/specs/index.d.ts.map +0 -1
  491. package/dist/specs/index.js.map +0 -1
  492. package/dist/specs/store.d.ts.map +0 -1
  493. package/dist/specs/store.js.map +0 -1
  494. package/dist/specs/tasks-parser.d.ts.map +0 -1
  495. package/dist/specs/tasks-parser.js.map +0 -1
  496. package/dist/specs/types.d.ts.map +0 -1
  497. package/dist/specs/types.js.map +0 -1
  498. package/dist/steering/glob.d.ts.map +0 -1
  499. package/dist/steering/glob.js.map +0 -1
  500. package/dist/steering/index.d.ts.map +0 -1
  501. package/dist/steering/index.js.map +0 -1
  502. package/dist/steering/loader.d.ts.map +0 -1
  503. package/dist/steering/loader.js.map +0 -1
  504. package/dist/steering/project-instructions.d.ts.map +0 -1
  505. package/dist/steering/project-instructions.js.map +0 -1
  506. package/dist/steering/select.d.ts.map +0 -1
  507. package/dist/steering/select.js.map +0 -1
  508. package/dist/steering/types.d.ts.map +0 -1
  509. package/dist/steering/types.js.map +0 -1
  510. package/dist/structured/index.d.ts.map +0 -1
  511. package/dist/structured/index.js.map +0 -1
  512. package/dist/structured/retry.d.ts.map +0 -1
  513. package/dist/structured/retry.js.map +0 -1
  514. package/dist/structured/schema.d.ts.map +0 -1
  515. package/dist/structured/schema.js.map +0 -1
  516. package/dist/tools/browser-tools.d.ts.map +0 -1
  517. package/dist/tools/browser-tools.js.map +0 -1
  518. package/dist/tools/codebase-search.d.ts.map +0 -1
  519. package/dist/tools/codebase-search.js.map +0 -1
  520. package/dist/tools/command-allow.d.ts.map +0 -1
  521. package/dist/tools/command-allow.js.map +0 -1
  522. package/dist/tools/edit-file.d.ts.map +0 -1
  523. package/dist/tools/edit-file.js.map +0 -1
  524. package/dist/tools/fetch-url.d.ts.map +0 -1
  525. package/dist/tools/fetch-url.js.map +0 -1
  526. package/dist/tools/find-references.d.ts.map +0 -1
  527. package/dist/tools/find-references.js.map +0 -1
  528. package/dist/tools/find-symbol.d.ts.map +0 -1
  529. package/dist/tools/find-symbol.js.map +0 -1
  530. package/dist/tools/index.d.ts.map +0 -1
  531. package/dist/tools/index.js.map +0 -1
  532. package/dist/tools/list-files.d.ts.map +0 -1
  533. package/dist/tools/list-files.js.map +0 -1
  534. package/dist/tools/list-symbols.d.ts.map +0 -1
  535. package/dist/tools/list-symbols.js.map +0 -1
  536. package/dist/tools/memory.d.ts.map +0 -1
  537. package/dist/tools/memory.js.map +0 -1
  538. package/dist/tools/policy.d.ts.map +0 -1
  539. package/dist/tools/policy.js.map +0 -1
  540. package/dist/tools/read-file.d.ts.map +0 -1
  541. package/dist/tools/read-file.js.map +0 -1
  542. package/dist/tools/read-image.d.ts.map +0 -1
  543. package/dist/tools/read-image.js.map +0 -1
  544. package/dist/tools/read-only.d.ts.map +0 -1
  545. package/dist/tools/read-only.js.map +0 -1
  546. package/dist/tools/redact.d.ts.map +0 -1
  547. package/dist/tools/redact.js.map +0 -1
  548. package/dist/tools/result-cache.d.ts.map +0 -1
  549. package/dist/tools/result-cache.js.map +0 -1
  550. package/dist/tools/run-command.d.ts.map +0 -1
  551. package/dist/tools/run-command.js.map +0 -1
  552. package/dist/tools/sandbox-loader.d.ts.map +0 -1
  553. package/dist/tools/sandbox-loader.js.map +0 -1
  554. package/dist/tools/search-files.d.ts.map +0 -1
  555. package/dist/tools/search-files.js.map +0 -1
  556. package/dist/tools/shared.d.ts.map +0 -1
  557. package/dist/tools/shared.js.map +0 -1
  558. package/dist/tools/sub-agent.d.ts.map +0 -1
  559. package/dist/tools/sub-agent.js.map +0 -1
  560. package/dist/tools/write-file.d.ts.map +0 -1
  561. package/dist/tools/write-file.js.map +0 -1
  562. package/dist/types.d.ts.map +0 -1
  563. package/dist/types.js.map +0 -1
  564. package/dist/verify/detect.d.ts.map +0 -1
  565. package/dist/verify/detect.js.map +0 -1
  566. package/dist/verify/index.d.ts.map +0 -1
  567. package/dist/verify/index.js.map +0 -1
  568. package/dist/worktree/branch-ops.d.ts.map +0 -1
  569. package/dist/worktree/branch-ops.js.map +0 -1
  570. package/dist/worktree/index.d.ts.map +0 -1
  571. package/dist/worktree/index.js.map +0 -1
  572. package/dist/worktree/worktree.d.ts.map +0 -1
  573. package/dist/worktree/worktree.js.map +0 -1
@@ -5,4 +5,3 @@
5
5
  * extension's pending-changes review UI. No I/O, no platform deps.
6
6
  */
7
7
  export { computeUnifiedDiff, computeDiffSummary, } from './unified-diff.js';
8
- //# sourceMappingURL=index.js.map
@@ -69,4 +69,3 @@ export interface DiffSummary {
69
69
  summary: string;
70
70
  }
71
71
  export declare function computeDiffSummary(before: string, after: string, options?: DiffOptions): DiffSummary;
72
- //# sourceMappingURL=unified-diff.d.ts.map
@@ -121,21 +121,48 @@ function splitLines(s) {
121
121
  parts.pop();
122
122
  return parts;
123
123
  }
124
+ /** Past this many table cells the middle of the diff is reported as removed-then-added (about 64 MB at most). */
125
+ const MAX_LCS_CELLS = 4_000_000;
124
126
  /**
125
- * Compute the LCS table and walk it back to produce a flat list of
126
- * operations. Standard LCS-Diff algorithm: O(N*M) time + space.
127
- *
128
- * For very large files this allocates O(N*M) which can blow memory;
129
- * see the file-level docstring for the size guideline.
127
+ * Line diff as a flat list of operations. Lines shared at the start and end are matched directly, and
128
+ * only the middle goes through the standard O(N*M) LCS table; a middle too big for that (a rewritten
129
+ * file) is reported as everything removed, then everything added, so memory stays bounded.
130
130
  */
131
131
  function diffLines(oldLines, newLines) {
132
- const n = oldLines.length;
133
- const m = newLines.length;
134
- // lcs[i][j] = length of LCS of oldLines[0..i] and newLines[0..j].
132
+ let head = 0;
133
+ while (head < oldLines.length && head < newLines.length && oldLines[head] === newLines[head])
134
+ head++;
135
+ let tail = 0;
136
+ while (tail < oldLines.length - head &&
137
+ tail < newLines.length - head &&
138
+ oldLines[oldLines.length - 1 - tail] === newLines[newLines.length - 1 - tail]) {
139
+ tail++;
140
+ }
141
+ const out = [];
142
+ for (let i = 0; i < head; i++)
143
+ out.push({ kind: 'equal', oldIndex: i, newIndex: i });
144
+ for (const op of diffMiddle(oldLines, newLines, head, oldLines.length - tail, newLines.length - tail))
145
+ out.push(op);
146
+ for (let t = tail; t > 0; t--) {
147
+ out.push({ kind: 'equal', oldIndex: oldLines.length - t, newIndex: newLines.length - t });
148
+ }
149
+ return out;
150
+ }
151
+ /** LCS diff of oldLines[from..oldEnd) against newLines[from..newEnd); indexes stay relative to the full arrays. */
152
+ function diffMiddle(oldLines, newLines, from, oldEnd, newEnd) {
153
+ const n = oldEnd - from;
154
+ const m = newEnd - from;
155
+ const replaced = () => [
156
+ ...Array.from({ length: n }, (_, i) => ({ kind: 'remove', oldIndex: from + i })),
157
+ ...Array.from({ length: m }, (_, j) => ({ kind: 'add', newIndex: from + j })),
158
+ ];
159
+ if (n === 0 || m === 0 || (n + 1) * (m + 1) > MAX_LCS_CELLS)
160
+ return replaced();
161
+ // lcs[i][j] = length of LCS of the first i old lines and the first j new lines of the middle.
135
162
  const lcs = Array.from({ length: n + 1 }, () => new Array(m + 1).fill(0));
136
163
  for (let i = 1; i <= n; i++) {
137
164
  for (let j = 1; j <= m; j++) {
138
- if (oldLines[i - 1] === newLines[j - 1]) {
165
+ if (oldLines[from + i - 1] === newLines[from + j - 1]) {
139
166
  lcs[i][j] = lcs[i - 1][j - 1] + 1;
140
167
  }
141
168
  else {
@@ -148,26 +175,26 @@ function diffLines(oldLines, newLines) {
148
175
  let i = n;
149
176
  let j = m;
150
177
  while (i > 0 && j > 0) {
151
- if (oldLines[i - 1] === newLines[j - 1]) {
152
- out.push({ kind: 'equal', oldIndex: i - 1, newIndex: j - 1 });
178
+ if (oldLines[from + i - 1] === newLines[from + j - 1]) {
179
+ out.push({ kind: 'equal', oldIndex: from + i - 1, newIndex: from + j - 1 });
153
180
  i--;
154
181
  j--;
155
182
  }
156
183
  else if (lcs[i - 1][j] >= lcs[i][j - 1]) {
157
- out.push({ kind: 'remove', oldIndex: i - 1 });
184
+ out.push({ kind: 'remove', oldIndex: from + i - 1 });
158
185
  i--;
159
186
  }
160
187
  else {
161
- out.push({ kind: 'add', newIndex: j - 1 });
188
+ out.push({ kind: 'add', newIndex: from + j - 1 });
162
189
  j--;
163
190
  }
164
191
  }
165
192
  while (i > 0) {
166
- out.push({ kind: 'remove', oldIndex: i - 1 });
193
+ out.push({ kind: 'remove', oldIndex: from + i - 1 });
167
194
  i--;
168
195
  }
169
196
  while (j > 0) {
170
- out.push({ kind: 'add', newIndex: j - 1 });
197
+ out.push({ kind: 'add', newIndex: from + j - 1 });
171
198
  j--;
172
199
  }
173
200
  out.reverse();
@@ -354,4 +381,3 @@ function formatFullDelete(oldLines, oldLabel, newLabel, filePath) {
354
381
  void filePath;
355
382
  return header + hunk + body;
356
383
  }
357
- //# sourceMappingURL=unified-diff.js.map
@@ -28,7 +28,7 @@ export declare function diffForFiles(cwd: string, files: string[]): Promise<stri
28
28
  /** Deterministic message used when no model is available or it fails. */
29
29
  export declare function fallbackCommitMessage(files: string[]): string;
30
30
  export declare function commitMessagePrompt(diff: string, task?: string): string;
31
- /** Strip fences/quotes a model may wrap around the message. */
31
+ /** Strip an inline `<think>` block (MiniMax and other reasoning models) and the fences/quotes a model may wrap around the message. */
32
32
  export declare function cleanCommitMessage(text: string): string;
33
33
  /** Draft a commit message with `model` (typically the cheap model); never throws. */
34
34
  export declare function generateCommitMessage(diff: string, files: string[], model: ModelConfig | undefined, task?: string, modelFactory?: (cfg: ModelConfig) => LanguageModel): Promise<string>;
@@ -61,4 +61,3 @@ export declare function afterRun(cwd: string, state: {
61
61
  task?: string;
62
62
  modelFactory?: (cfg: ModelConfig) => LanguageModel;
63
63
  }): Promise<ForgeCommit | null>;
64
- //# sourceMappingURL=auto-commit.d.ts.map
@@ -6,6 +6,7 @@
6
6
  import { execFile } from 'node:child_process';
7
7
  import { promisify } from 'node:util';
8
8
  import { generateText } from 'ai';
9
+ import { stripThinkTags } from '../agent/think-tags.js';
9
10
  import { createLanguageModel } from '../providers.js';
10
11
  const execFileAsync = promisify(execFile);
11
12
  async function git(cwd, args) {
@@ -62,8 +63,10 @@ async function identityArgs(cwd, attribute) {
62
63
  export async function commitFiles(cwd, files, message, options = {}) {
63
64
  if (files.length === 0)
64
65
  return null;
66
+ const stagedAmong = async () => (await git(cwd, ['diff', '--cached', '--name-only', '--', ...files])).split('\n').filter(Boolean);
67
+ const stagedBefore = new Set(await stagedAmong());
65
68
  await git(cwd, ['add', '-A', '--', ...files]);
66
- const staged = (await git(cwd, ['diff', '--cached', '--name-only', '--', ...files])).split('\n').filter(Boolean);
69
+ const staged = await stagedAmong();
67
70
  if (staged.length === 0)
68
71
  return null;
69
72
  const full = `${message.trim()}\n\n${FORGE_TRAILER}`;
@@ -71,7 +74,17 @@ export async function commitFiles(cwd, files, message, options = {}) {
71
74
  if (!options.verify)
72
75
  args.push('--no-verify');
73
76
  args.push('-m', full, '--', ...staged);
74
- await git(cwd, args);
77
+ try {
78
+ await git(cwd, args);
79
+ }
80
+ catch (err) {
81
+ // The commit was refused (a pre-commit hook, a locked index). Do not leave the user's files
82
+ // staged by us: unstage what we staged, but keep what they had staged on purpose.
83
+ const ours = staged.filter((f) => !stagedBefore.has(f));
84
+ if (ours.length > 0)
85
+ await git(cwd, ['reset', '-q', '--', ...ours]).catch(() => undefined);
86
+ throw err;
87
+ }
75
88
  const commit = (await git(cwd, ['rev-parse', 'HEAD'])).trim();
76
89
  return { commit, message: message.trim(), files: staged };
77
90
  }
@@ -103,9 +116,9 @@ export function commitMessagePrompt(diff, task) {
103
116
  const clipped = diff.length > MAX_DIFF_CHARS ? `${diff.slice(0, MAX_DIFF_CHARS)}\n[diff truncated]` : diff;
104
117
  return `Write a git commit message for this diff in conventional-commit style (type(scope): subject, imperative mood, under 72 characters). Add a short body only if the change needs explaining. Reply with the message only, no quotes or code fences.${task ? `\n\nThe change was made for this request: ${task}` : ''}\n\n${clipped}`;
105
118
  }
106
- /** Strip fences/quotes a model may wrap around the message. */
119
+ /** Strip an inline `<think>` block (MiniMax and other reasoning models) and the fences/quotes a model may wrap around the message. */
107
120
  export function cleanCommitMessage(text) {
108
- return text
121
+ return stripThinkTags(text)
109
122
  .replace(/^```[a-z]*\n?|\n?```$/gi, '')
110
123
  .trim()
111
124
  .replace(/^["'`]+|["'`]+$/g, '')
@@ -170,4 +183,3 @@ export async function afterRun(cwd, state, options) {
170
183
  const message = await generateCommitMessage(diff, files, options.model, options.task, options.modelFactory);
171
184
  return commitFiles(cwd, files, message, options);
172
185
  }
173
- //# sourceMappingURL=auto-commit.js.map
@@ -1,3 +1,2 @@
1
1
  export { FORGE_TRAILER, afterRun, beforeRun, changedFiles, cleanCommitMessage, commitDirty, commitFiles, commitMessagePrompt, diffForFiles, fallbackCommitMessage, generateCommitMessage, isGitRepo, undoLastForgeCommit, } from './auto-commit.js';
2
2
  export type { ForgeCommit, GitCommitOptions, UndoResult } from './auto-commit.js';
3
- //# sourceMappingURL=index.d.ts.map
package/dist/git/index.js CHANGED
@@ -1,2 +1 @@
1
1
  export { FORGE_TRAILER, afterRun, beforeRun, changedFiles, cleanCommitMessage, commitDirty, commitFiles, commitMessagePrompt, diffForFiles, fallbackCommitMessage, generateCommitMessage, isGitRepo, undoLastForgeCommit, } from './auto-commit.js';
2
- //# sourceMappingURL=index.js.map
@@ -0,0 +1,83 @@
1
+ import { z } from 'zod';
2
+ import type { ToolDefinition } from '../types.js';
3
+ export interface GitHubConfig {
4
+ token: string;
5
+ /** For tests. */
6
+ fetch?: typeof fetch;
7
+ }
8
+ export interface RepoRef {
9
+ owner: string;
10
+ repo: string;
11
+ /** REST API base, e.g. `https://api.github.com`. */
12
+ apiBase: string;
13
+ }
14
+ /** The token from the environment, or undefined. */
15
+ export declare function githubFromEnv(env?: NodeJS.ProcessEnv): GitHubConfig | undefined;
16
+ /** Owner, repo and API base from a remote URL (https, ssh or scp-like), or null for a non-GitHub-shaped URL. */
17
+ export declare function parseRemote(url: string): RepoRef | null;
18
+ export declare function repoFor(cwd: string): Promise<RepoRef>;
19
+ export declare function currentBranch(cwd: string): Promise<string>;
20
+ export interface PullRequestReport {
21
+ number: number;
22
+ title: string;
23
+ state: string;
24
+ draft: boolean;
25
+ url: string;
26
+ base: string;
27
+ head: string;
28
+ body: string;
29
+ reviews: Array<{
30
+ user: string;
31
+ state: string;
32
+ body: string;
33
+ }>;
34
+ reviewComments: Array<{
35
+ user: string;
36
+ path: string;
37
+ line: number | null;
38
+ body: string;
39
+ }>;
40
+ discussion: Array<{
41
+ user: string;
42
+ body: string;
43
+ }>;
44
+ checks: Array<{
45
+ name: string;
46
+ status: string;
47
+ conclusion: string | null;
48
+ }>;
49
+ }
50
+ declare const readParams: z.ZodObject<{
51
+ number: z.ZodOptional<z.ZodNumber>;
52
+ }, "strip", z.ZodTypeAny, {
53
+ number?: number | undefined;
54
+ }, {
55
+ number?: number | undefined;
56
+ }>;
57
+ export declare function createGitHubReadTool(cfg: GitHubConfig): ToolDefinition<z.infer<typeof readParams>, PullRequestReport>;
58
+ declare const createParams: z.ZodObject<{
59
+ title: z.ZodString;
60
+ body: z.ZodString;
61
+ base: z.ZodOptional<z.ZodString>;
62
+ head: z.ZodOptional<z.ZodString>;
63
+ draft: z.ZodOptional<z.ZodBoolean>;
64
+ }, "strip", z.ZodTypeAny, {
65
+ title: string;
66
+ body: string;
67
+ draft?: boolean | undefined;
68
+ base?: string | undefined;
69
+ head?: string | undefined;
70
+ }, {
71
+ title: string;
72
+ body: string;
73
+ draft?: boolean | undefined;
74
+ base?: string | undefined;
75
+ head?: string | undefined;
76
+ }>;
77
+ export declare function createGitHubCreateTool(cfg: GitHubConfig): ToolDefinition<z.infer<typeof createParams>, {
78
+ number: number;
79
+ url: string;
80
+ draft: boolean;
81
+ }>;
82
+ export declare function createGitHubTools(cfg: GitHubConfig): ToolDefinition[];
83
+ export {};
@@ -0,0 +1,175 @@
1
+ /**
2
+ * GitHub pull-request tools, for the repository the agent works in (its `origin` remote):
3
+ * - `github_pr_read`: a PR's description, reviews, review comments, discussion and checks
4
+ * (the current branch's open PR when no number is given), so the agent can act on review.
5
+ * - `github_pr_create`: open a PR from a pushed branch. Destructive: it publishes, so it
6
+ * is always approved first, even in autonomous mode.
7
+ *
8
+ * Opt-in (`AgentConfig.github`) and token-based (`GITHUB_TOKEN` / `GH_TOKEN`, or a token the
9
+ * host supplies, such as VS Code's GitHub sign-in). GitHub Enterprise remotes use `<host>/api/v3`.
10
+ */
11
+ import { execFile } from 'node:child_process';
12
+ import { promisify } from 'node:util';
13
+ import { z } from 'zod';
14
+ const execFileAsync = promisify(execFile);
15
+ const BODY_MAX = 4_000;
16
+ const COMMENT_MAX = 1_500;
17
+ const LIST_MAX = 50;
18
+ /** The token from the environment, or undefined. */
19
+ export function githubFromEnv(env = process.env) {
20
+ const token = env.GITHUB_TOKEN?.trim() || env.GH_TOKEN?.trim();
21
+ return token ? { token } : undefined;
22
+ }
23
+ /** Owner, repo and API base from a remote URL (https, ssh or scp-like), or null for a non-GitHub-shaped URL. */
24
+ export function parseRemote(url) {
25
+ const trimmed = url.trim();
26
+ const m = /^(?:https?|ssh|git):\/\/(?:[^@/]+@)?([^/:]+)(?::\d+)?\/([^/]+)\/([^/]+?)(?:\.git)?\/?$/.exec(trimmed) ??
27
+ /^(?:[^@]+@)?([^:/]+):([^/]+)\/([^/]+?)(?:\.git)?$/.exec(trimmed);
28
+ if (!m)
29
+ return null;
30
+ const host = m[1].toLowerCase();
31
+ const apiBase = host === 'github.com' ? 'https://api.github.com' : `https://${host}/api/v3`;
32
+ return { owner: m[2], repo: m[3], apiBase };
33
+ }
34
+ async function git(cwd, args) {
35
+ const { stdout } = await execFileAsync('git', args, { cwd, timeout: 15_000 });
36
+ return stdout.trim();
37
+ }
38
+ export async function repoFor(cwd) {
39
+ let url;
40
+ try {
41
+ url = await git(cwd, ['remote', 'get-url', 'origin']);
42
+ }
43
+ catch {
44
+ throw new Error('this repository has no "origin" remote');
45
+ }
46
+ const ref = parseRemote(url);
47
+ if (!ref)
48
+ throw new Error(`cannot tell the GitHub repository from the origin remote (${url})`);
49
+ return ref;
50
+ }
51
+ export async function currentBranch(cwd) {
52
+ // symbolic-ref also answers on a branch with no commits yet; it fails only on a detached HEAD.
53
+ const branch = await git(cwd, ['symbolic-ref', '--short', '-q', 'HEAD']).catch(() => '');
54
+ if (!branch)
55
+ throw new Error('not on a branch (detached HEAD)');
56
+ return branch;
57
+ }
58
+ function clip(text, max) {
59
+ const s = typeof text === 'string' ? text : '';
60
+ return s.length > max ? `${s.slice(0, max)}… (${s.length - max} more characters)` : s;
61
+ }
62
+ async function api(cfg, repo, method, path, body, signal) {
63
+ const res = await (cfg.fetch ?? fetch)(`${repo.apiBase}${path}`, {
64
+ method,
65
+ headers: {
66
+ Accept: 'application/vnd.github+json',
67
+ Authorization: `Bearer ${cfg.token}`,
68
+ 'X-GitHub-Api-Version': '2022-11-28',
69
+ 'User-Agent': 'ikarmic-forge',
70
+ ...(body !== undefined ? { 'Content-Type': 'application/json' } : {}),
71
+ },
72
+ ...(body !== undefined ? { body: JSON.stringify(body) } : {}),
73
+ signal: signal ? AbortSignal.any([signal, AbortSignal.timeout(20_000)]) : AbortSignal.timeout(20_000),
74
+ });
75
+ const data = (await res.json().catch(() => ({})));
76
+ if (!res.ok) {
77
+ const detail = [data.message, ...(data.errors ?? []).map((e) => e.message)].filter(Boolean).join('; ');
78
+ throw new Error(`GitHub ${method} ${path} failed: HTTP ${res.status}${detail ? ` (${detail})` : ''}`);
79
+ }
80
+ return data;
81
+ }
82
+ const login = (u) => u?.login ?? 'unknown';
83
+ const readParams = z.object({
84
+ number: z.number().int().positive().optional().describe('PR number. Default: the open PR for the current branch.'),
85
+ });
86
+ export function createGitHubReadTool(cfg) {
87
+ return {
88
+ name: 'github_pr_read',
89
+ description: "Read a GitHub pull request in this repository: description, reviews, line comments, discussion and CI checks. Without a number it reads the current branch's open PR. Use it to see what reviewers asked for or why CI failed.",
90
+ parameters: readParams,
91
+ destructive: false,
92
+ execute: async (args, ctx) => {
93
+ const repo = await repoFor(ctx.cwd);
94
+ const base = `/repos/${repo.owner}/${repo.repo}`;
95
+ let number = args.number;
96
+ if (number === undefined) {
97
+ const branch = await currentBranch(ctx.cwd);
98
+ const open = (await api(cfg, repo, 'GET', `${base}/pulls?state=open&head=${encodeURIComponent(`${repo.owner}:${branch}`)}`, undefined, ctx.abortSignal));
99
+ if (!Array.isArray(open) || open.length === 0)
100
+ throw new Error(`no open pull request for branch ${branch}`);
101
+ number = open[0].number;
102
+ }
103
+ const pr = (await api(cfg, repo, 'GET', `${base}/pulls/${number}`, undefined, ctx.abortSignal));
104
+ const [reviews, comments, discussion] = (await Promise.all([
105
+ api(cfg, repo, 'GET', `${base}/pulls/${number}/reviews?per_page=${LIST_MAX}`, undefined, ctx.abortSignal),
106
+ api(cfg, repo, 'GET', `${base}/pulls/${number}/comments?per_page=${LIST_MAX}`, undefined, ctx.abortSignal),
107
+ api(cfg, repo, 'GET', `${base}/issues/${number}/comments?per_page=${LIST_MAX}`, undefined, ctx.abortSignal),
108
+ ]));
109
+ const sha = pr.head?.sha;
110
+ const checks = sha
111
+ ? (await api(cfg, repo, 'GET', `${base}/commits/${sha}/check-runs?per_page=${LIST_MAX}`, undefined, ctx.abortSignal).catch(() => ({ check_runs: [] })))
112
+ .check_runs
113
+ : [];
114
+ return {
115
+ number,
116
+ title: String(pr.title ?? ''),
117
+ state: pr.merged_at ? 'merged' : String(pr.state ?? ''),
118
+ draft: pr.draft === true,
119
+ url: String(pr.html_url ?? ''),
120
+ base: String(pr.base?.ref ?? ''),
121
+ head: String(pr.head?.ref ?? ''),
122
+ body: clip(pr.body, BODY_MAX),
123
+ // Approvals without text are still worth seeing; empty COMMENTED shells are not.
124
+ reviews: (reviews ?? [])
125
+ .filter((r) => r.state !== 'COMMENTED' || (typeof r.body === 'string' && r.body.trim()))
126
+ .map((r) => ({ user: login(r.user), state: String(r.state), body: clip(r.body, COMMENT_MAX) })),
127
+ reviewComments: (comments ?? []).map((c) => ({
128
+ user: login(c.user),
129
+ path: String(c.path ?? ''),
130
+ line: typeof c.line === 'number' ? c.line : typeof c.original_line === 'number' ? c.original_line : null,
131
+ body: clip(c.body, COMMENT_MAX),
132
+ })),
133
+ discussion: (discussion ?? []).map((c) => ({ user: login(c.user), body: clip(c.body, COMMENT_MAX) })),
134
+ checks: (checks ?? []).map((c) => ({ name: String(c.name), status: String(c.status), conclusion: c.conclusion ?? null })),
135
+ };
136
+ },
137
+ };
138
+ }
139
+ const createParams = z.object({
140
+ title: z.string().min(1).max(256).describe('PR title.'),
141
+ body: z.string().max(60_000).describe('PR description (Markdown): what changed and why, and how it was tested.'),
142
+ base: z.string().optional().describe("Branch to merge into. Default: the repository's default branch."),
143
+ head: z.string().optional().describe('Branch with the changes. Default: the current branch. It must already be pushed.'),
144
+ draft: z.boolean().optional().describe('Open as a draft (default true).'),
145
+ });
146
+ export function createGitHubCreateTool(cfg) {
147
+ return {
148
+ name: 'github_pr_create',
149
+ description: 'Open a pull request on GitHub for a branch that is already pushed (push it with run_command first: git push -u origin <branch>). Opens a draft unless draft=false. This publishes to GitHub, so the user approves it first.',
150
+ parameters: createParams,
151
+ destructive: true,
152
+ execute: async (args, ctx) => {
153
+ const repo = await repoFor(ctx.cwd);
154
+ const base = `/repos/${repo.owner}/${repo.repo}`;
155
+ const head = args.head ?? (await currentBranch(ctx.cwd));
156
+ const into = args.base ?? (await api(cfg, repo, 'GET', base, undefined, ctx.abortSignal)).default_branch;
157
+ if (head === into)
158
+ throw new Error(`the head branch is the base branch (${head}); work on a separate branch`);
159
+ try {
160
+ const pr = (await api(cfg, repo, 'POST', `${base}/pulls`, { title: args.title, body: args.body, head, base: into, draft: args.draft ?? true }, ctx.abortSignal));
161
+ return { number: pr.number, url: String(pr.html_url), draft: pr.draft === true };
162
+ }
163
+ catch (err) {
164
+ const msg = err.message;
165
+ if (/HTTP 422/.test(msg) && /head|not.*found|No commits/i.test(msg)) {
166
+ throw new Error(`${msg}. Is ${head} pushed and ahead of ${into}? Push it with: git push -u origin ${head}`);
167
+ }
168
+ throw err;
169
+ }
170
+ },
171
+ };
172
+ }
173
+ export function createGitHubTools(cfg) {
174
+ return [createGitHubReadTool(cfg), createGitHubCreateTool(cfg)];
175
+ }
@@ -14,4 +14,3 @@ export interface AgentHookRunnerOptions {
14
14
  maxIterations?: number;
15
15
  }
16
16
  export declare function createAgentHookRunner(options: AgentHookRunnerOptions): AgentHookRunner;
17
- //# sourceMappingURL=agent-runner.d.ts.map
@@ -42,4 +42,3 @@ export function createAgentHookRunner(options) {
42
42
  }
43
43
  };
44
44
  }
45
- //# sourceMappingURL=agent-runner.js.map
@@ -93,4 +93,3 @@ export declare class HooksBus {
93
93
  /** Filter matcher entries down to those that apply to this event. */
94
94
  private filterByMatcher;
95
95
  }
96
- //# sourceMappingURL=bus.d.ts.map
package/dist/hooks/bus.js CHANGED
@@ -157,4 +157,3 @@ function expandPrompt(prompt, event) {
157
157
  };
158
158
  return prompt.replace(/\{\{(\w+)\}\}/g, (_m, key) => values[key] ?? '');
159
159
  }
160
- //# sourceMappingURL=bus.js.map
@@ -111,4 +111,3 @@ export declare function validateToolSandboxConfig(raw: unknown): string[];
111
111
  * matches everything.
112
112
  */
113
113
  export declare function matcherMatches(matcher: string, toolName: string): boolean;
114
- //# sourceMappingURL=config.d.ts.map
@@ -187,4 +187,3 @@ export function matcherMatches(matcher, toolName) {
187
187
  }
188
188
  return false;
189
189
  }
190
- //# sourceMappingURL=config.js.map
@@ -87,4 +87,3 @@ export declare function eventToolName(event: HookEvent): string | undefined;
87
87
  * glob" for this one event. Returns undefined for every other event.
88
88
  */
89
89
  export declare function eventFilePath(event: HookEvent): string | undefined;
90
- //# sourceMappingURL=events.d.ts.map
@@ -42,4 +42,3 @@ export function eventFilePath(event) {
42
42
  return event.path;
43
43
  return undefined;
44
44
  }
45
- //# sourceMappingURL=events.js.map
@@ -18,4 +18,3 @@ export { AGENT_HOOK_TOOLS, createAgentHookRunner, type AgentHookRunnerOptions }
18
18
  export { shouldIgnoreWatchPath } from './watch-ignore.js';
19
19
  export { FileChangeCoalescer, type FileChangeType } from './watch-coalescer.js';
20
20
  export { watchFilesystem } from './watcher.js';
21
- //# sourceMappingURL=index.d.ts.map
@@ -13,4 +13,3 @@ export { AGENT_HOOK_TOOLS, createAgentHookRunner } from './agent-runner.js';
13
13
  export { shouldIgnoreWatchPath } from './watch-ignore.js';
14
14
  export { FileChangeCoalescer } from './watch-coalescer.js';
15
15
  export { watchFilesystem } from './watcher.js';
16
- //# sourceMappingURL=index.js.map
@@ -50,4 +50,3 @@ export declare function readSettings(filePath: string): Promise<{
50
50
  * tolerated; the loader returns an empty config instead of throwing.
51
51
  */
52
52
  export declare function loadHooksConfig(cwd: string): Promise<LoadHooksResult>;
53
- //# sourceMappingURL=loader.d.ts.map
@@ -138,4 +138,3 @@ export async function loadHooksConfig(cwd) {
138
138
  sources,
139
139
  };
140
140
  }
141
- //# sourceMappingURL=loader.js.map
@@ -40,4 +40,3 @@ export declare function eventToEnv(event: HookEvent): Record<string, string>;
40
40
  * log, or swallow.
41
41
  */
42
42
  export declare function runHook(event: HookEvent, config: ShellHookConfig): Promise<HookRunResult>;
43
- //# sourceMappingURL=runner.d.ts.map
@@ -182,4 +182,3 @@ export function runHook(event, config) {
182
182
  });
183
183
  });
184
184
  }
185
- //# sourceMappingURL=runner.js.map
@@ -20,4 +20,3 @@ export declare class FileChangeCoalescer {
20
20
  /** Cancel every pending timer without dispatching. Call on watcher shutdown. */
21
21
  dispose(): void;
22
22
  }
23
- //# sourceMappingURL=watch-coalescer.d.ts.map
@@ -24,4 +24,3 @@ export class FileChangeCoalescer {
24
24
  this.timers.clear();
25
25
  }
26
26
  }
27
- //# sourceMappingURL=watch-coalescer.js.map
@@ -6,4 +6,3 @@
6
6
  * in v1: same as checkpoint capture's own ignore list.
7
7
  */
8
8
  export declare function shouldIgnoreWatchPath(relPath: string): boolean;
9
- //# sourceMappingURL=watch-ignore.d.ts.map
@@ -9,4 +9,3 @@ export function shouldIgnoreWatchPath(relPath) {
9
9
  const segments = relPath.split(/[\\/]/);
10
10
  return segments.some((seg) => seg === 'node_modules' || seg.startsWith('.'));
11
11
  }
12
- //# sourceMappingURL=watch-ignore.js.map
@@ -35,4 +35,3 @@ import type { FileChangeType } from './watch-coalescer.js';
35
35
  export declare function watchFilesystem(cwd: string, onChange: (relPath: string, changeType: FileChangeType) => void): {
36
36
  close(): Promise<void>;
37
37
  };
38
- //# sourceMappingURL=watcher.d.ts.map
@@ -61,4 +61,3 @@ export function watchFilesystem(cwd, onChange) {
61
61
  },
62
62
  };
63
63
  }
64
- //# sourceMappingURL=watcher.js.map
package/dist/index.d.ts CHANGED
@@ -1,4 +1,10 @@
1
1
  export { Agent, applySandbox } from './agent/agent.js';
2
+ export { LoopGuard } from './agent/loop-guard.js';
3
+ export { enhancePrompt } from './agent/enhance-prompt.js';
4
+ export { stripThinkTags } from './agent/think-tags.js';
5
+ export { createGitHubCreateTool, createGitHubReadTool, createGitHubTools, githubFromEnv, parseRemote, type GitHubConfig, type PullRequestReport, type RepoRef, } from './github/github-tools.js';
6
+ export { createWebSearchTool, searchWeb, WEB_SEARCH_PROVIDERS, webSearchFromEnv, webSearchProblem, type WebSearchConfig, type WebSearchProvider, type WebSearchResult, } from './tools/web-search.js';
7
+ export { attachmentKind, attachmentBytes, attachmentParts, attachmentProblem, describeAttachment, detectMediaType, loadAttachment, makeAttachment, mediaPartTokens, MAX_ATTACHMENT_BYTES, MAX_IMAGE_ATTACHMENT_BYTES, type Attachment, type AttachmentKind, } from './attachments.js';
2
8
  export type { CredentialStore } from './credentials/types.js';
3
9
  export { CREDENTIAL_SERVICE_NAME, credentialAccountKey } from './credentials/index.js';
4
10
  export type { LoadToolSandboxResult } from './tools/sandbox-loader.js';
@@ -19,18 +25,24 @@ export { architectPhaseConfig, editorLimits, editorPhaseConfig, editorTask, isUs
19
25
  export type { ArchitectOptions } from './agent/architect.js';
20
26
  export { lookupPricing, computeCostUsd, formatCost, costFor, knownModelIds, } from './pricing.js';
21
27
  export type { ModelPricing, ResolvedPricing } from './pricing.js';
22
- export { buildMemoryBlock, composeSectionUpdate, findProjectMemoryRoot, globalMemoryPath, injectMemory, loadMemory, parseMemory, projectMemoryPath, readMemoryFile, trimToBytes, writeMemoryFile, DEFAULT_INJECTION_BUDGET, DEFAULT_MAX_BYTES, GLOBAL_MEMORY_DIR, GLOBAL_MEMORY_FILE, PROJECT_MEMORY_DIR, PROJECT_MEMORY_FILE, } from './memory/memory-store.js';
23
- export type { LoadedMemory, MemoryInjection, MemorySection, MemorySource, } from './memory/memory-store.js';
24
- export type { MemoryReadResult, MemoryWriteResult } from './tools/memory.js';
28
+ export { buildMemoryBlock, composeSectionUpdate, findProjectMemoryRoot, globalMemoryPath, injectMemory, loadMemory, normalizeHeading, parseMemory, projectMemoryPath, readMemoryFile, trimToBytes, capMemory, removeSection, writeMemoryFile, DEFAULT_INJECTION_BUDGET, DEFAULT_MAX_BYTES, GLOBAL_MEMORY_DIR, GLOBAL_MEMORY_FILE, PROJECT_MEMORY_DIR, PROJECT_MEMORY_FILE, } from './memory/memory-store.js';
29
+ export { scoreSections, tokenize } from './memory/rank.js';
30
+ export type { ScoredSection } from './memory/rank.js';
31
+ export { checkStale, staleKey } from './memory/stale.js';
32
+ export type { StaleOptions } from './memory/stale.js';
33
+ export type { LoadedMemory, InjectOptions, MemoryInjection, MemorySection, MemorySource, MemoryType, SectionMeta, } from './memory/memory-store.js';
34
+ export { MAX_BODY_CHARS } from './tools/memory.js';
35
+ export type { MemoryForgetResult, MemoryReadResult, MemoryWriteResult } from './tools/memory.js';
25
36
  export { buildLlmSummarizer, compactMessages, estimateMessageTokens, estimateTokens, getModelWindowTokens, shouldCompact, } from './context/compaction.js';
26
37
  export type { CompactionResult, Summarizer } from './context/compaction.js';
27
38
  export { defaultModelFor, detectProvider, envVarForProvider, fastDefaultFor, hasProviderKey, readModelConfigFromEnv, resolveApiKey, SUPPORTED_PROVIDERS, } from './config.js';
28
39
  export { loadMcpConfig, parseMcpConfig, connectAll, connectOne, closeAll, mcpResultToValue, jsonSchemaToZod, } from './mcp/index.js';
29
40
  export type { McpConfigFile, McpServerSpec, ConnectedMcpServer, } from './mcp/index.js';
30
41
  export { createLanguageModel, formatModelId, pickAvailableProvider, resolveModelFromEnv, resolveModelFromEnvAsync } from './providers.js';
31
- export { defaultSessionDir, generateSessionId, saveSession, loadSession, deleteSession, listSessions, findLatestSession, formatSessionMarkdown, formatSessionJson, appendedSince, summarizeMessage, watchSession, } from './sessions/index.js';
32
- export type { Session, ListEntry, FormatOptions, SessionUpdate, WatchSessionOptions } from './sessions/index.js';
33
- export { BUILTIN_TOOLS, editFileTool, fetchUrlTool, findSymbolTool, listFilesTool, memoryReadTool, memoryWriteTool, readFileTool, runCommandTool, searchFilesTool, subAgentTool, writeFileTool, checkPolicyViolation, globToRegex, mergeToolSandbox, normalizePathPattern, pathMatchesAny, redact, countRedactions, buildRules, ToolResultCache, buildCacheKey, cachedExecute, } from './tools/index.js';
42
+ export { defaultSessionDir, generateSessionId, saveSession, loadSession, deleteSession, listSessions, findLatestSession, formatSessionMarkdown, formatSessionJson, appendedSince, summarizeMessage, watchSession, searchSessions, sessionText, pruneSessions, pruneByRetention, } from './sessions/index.js';
43
+ export type { Session, ListEntry, FormatOptions, SessionUpdate, WatchSessionOptions, SessionMatch, SearchSessionsOptions, SessionPruneOptions, SessionPruneResult } from './sessions/index.js';
44
+ export { commandDirs, expandCustomCommand, formatCustomCommands, loadCustomCommands, parseCommandFile, type CustomCommand, } from './commands/custom-commands.js';
45
+ export { BUILTIN_TOOLS, editFileTool, fetchUrlTool, findSymbolTool, listFilesTool, memoryReadTool, memoryForgetTool, memoryWriteTool, readFileTool, runCommandTool, searchFilesTool, subAgentTool, writeFileTool, checkPolicyViolation, globToRegex, mergeToolSandbox, normalizePathPattern, pathMatchesAny, redact, countRedactions, buildRules, ToolResultCache, buildCacheKey, cachedExecute, } from './tools/index.js';
34
46
  export type { AgentConfig, AgentEvent, AgentRunOptions, AgentRunReason, AgentRunResult, AnyLanguageModel, ApprovalDecision, CommandRunner, ModelRouter, VerifyConfig, ApprovalRequest, LanguageModelFactory, ModelConfig, PricePerMillionTokens, ProviderName, RedactOptions, ToolContext, ToolDefinition, ToolPolicy, ToolSandbox, } from './types.js';
35
47
  export type { CacheKeyParts, CacheStats } from './tools/index.js';
36
48
  export type { RedactionRule, RedactionResult } from './tools/index.js';
@@ -62,8 +74,8 @@ export type { InstalledMcpServer, InstalledServerMetadata, MarketplaceCatalog, M
62
74
  export { MARKETPLACE_CATALOG_VERSION } from './mcp/marketplace-types.js';
63
75
  export { CheckpointStore, type CheckpointStoreLimits } from './checkpoints/index.js';
64
76
  export type { CaptureOptions, Checkpoint, CheckpointFile, CheckpointFileStatus, CheckpointSummary, CheckpointTrigger, PruneResult, RestoreResult, } from './checkpoints/index.js';
65
- export { SpecStore, isSafeSpecId, runKey, slugifyTaskForSpecId, SPEC_READONLY_TOOLS, splitSpecSections, convertToCheckboxes, parseTasks, setTaskDone } from './specs/index.js';
66
- export type { SpecDraft, SpecRunRecord, SpecRuns, SpecSections, SpecSummary, SpecTask } from './specs/index.js';
77
+ export { SpecStore, isSafeSpecId, runKey, slugifyTaskForSpecId, SPEC_READONLY_TOOLS, splitSpecSections, convertToCheckboxes, parseTasks, setTaskDone, changedSince, changeSize, keepDoneTasks, referencedPaths, specDrift, syncSpecTask } from './specs/index.js';
78
+ export type { SpecDraft, SpecRunRecord, SpecRuns, SpecSections, SpecSummary, SpecTask, SpecDrift } from './specs/index.js';
67
79
  export { BUILTIN_SPECIALISTS, defaultConfigPath, effectiveToolsFor, BOARD_TOOL_NAMES, createBoardTools, DEFAULT_BOARD_CAP, getRegisteredSpecialist, getSpecialist, MessageBoard, listSpecialists, loadSpecialistsFromConfig, parseRouterOutput, registerSpecialist, resolveEffectiveModel, ROUTER_SYSTEM_PROMPT, runOrchestrator, runRouter, saveSpecialistsToConfig, unregisterSpecialist, validateSpecialistConfig, _resetSpecialistsForTests, _customSpecialistCount, } from './orchestrator/index.js';
68
80
  export type { BoardMessage } from './orchestrator/index.js';
69
81
  export type { BuiltInSpecialistId, CustomSpecialistConfig, LoadSpecialistsResult, OrchestratorOptions, OrchestratorPlan, OrchestratorProgressEvent, OrchestratorRunResult, OrchestratorStep, OrchestratorStepResult, SpecialistConfig, SpecialistId, SpecialistsConfigFile, } from './orchestrator/index.js';
@@ -89,4 +101,4 @@ export { READ_ONLY_TOOLS, resolveAutoApprove } from './tools/read-only.js';
89
101
  export { autoRunCommands, autoRunFingerprint, detectProjectChecks, formatProjectCommandsBlock, projectScriptsFingerprint } from './verify/index.js';
90
102
  export { isAlwaysAllowable, isListedCommand, needsScriptFingerprint, normalizeCommand } from './tools/command-allow.js';
91
103
  export type { CheckKind, DetectedCheck, DetectedChecks } from './verify/index.js';
92
- //# sourceMappingURL=index.d.ts.map
104
+ export { IgnoreRules, IGNORE_FILE_NAMES, findGitRoot } from './tools/ignore-rules.js';