@weavelogic/knowledge-graph-agent 0.2.0 → 0.4.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 (711) hide show
  1. package/README.md +972 -303
  2. package/dist/_virtual/_commonjsHelpers.js +7 -0
  3. package/dist/_virtual/_commonjsHelpers.js.map +1 -0
  4. package/dist/_virtual/additionalItems.js +5 -0
  5. package/dist/_virtual/additionalItems.js.map +1 -0
  6. package/dist/_virtual/additionalProperties.js +5 -0
  7. package/dist/_virtual/additionalProperties.js.map +1 -0
  8. package/dist/_virtual/ajv.js +6 -0
  9. package/dist/_virtual/ajv.js.map +1 -0
  10. package/dist/_virtual/ajv2.js +5 -0
  11. package/dist/_virtual/ajv2.js.map +1 -0
  12. package/dist/_virtual/allOf.js +5 -0
  13. package/dist/_virtual/allOf.js.map +1 -0
  14. package/dist/_virtual/anyOf.js +5 -0
  15. package/dist/_virtual/anyOf.js.map +1 -0
  16. package/dist/_virtual/applicability.js +5 -0
  17. package/dist/_virtual/applicability.js.map +1 -0
  18. package/dist/_virtual/boolSchema.js +5 -0
  19. package/dist/_virtual/boolSchema.js.map +1 -0
  20. package/dist/_virtual/code.js +5 -0
  21. package/dist/_virtual/code.js.map +1 -0
  22. package/dist/_virtual/code2.js +5 -0
  23. package/dist/_virtual/code2.js.map +1 -0
  24. package/dist/_virtual/const.js +5 -0
  25. package/dist/_virtual/const.js.map +1 -0
  26. package/dist/_virtual/contains.js +5 -0
  27. package/dist/_virtual/contains.js.map +1 -0
  28. package/dist/_virtual/core.js +5 -0
  29. package/dist/_virtual/core.js.map +1 -0
  30. package/dist/_virtual/dataType.js +5 -0
  31. package/dist/_virtual/dataType.js.map +1 -0
  32. package/dist/_virtual/defaults.js +5 -0
  33. package/dist/_virtual/defaults.js.map +1 -0
  34. package/dist/_virtual/dependencies.js +5 -0
  35. package/dist/_virtual/dependencies.js.map +1 -0
  36. package/dist/_virtual/draft7.js +5 -0
  37. package/dist/_virtual/draft7.js.map +1 -0
  38. package/dist/_virtual/enum.js +5 -0
  39. package/dist/_virtual/enum.js.map +1 -0
  40. package/dist/_virtual/equal.js +5 -0
  41. package/dist/_virtual/equal.js.map +1 -0
  42. package/dist/_virtual/errors.js +5 -0
  43. package/dist/_virtual/errors.js.map +1 -0
  44. package/dist/_virtual/format.js +5 -0
  45. package/dist/_virtual/format.js.map +1 -0
  46. package/dist/_virtual/formats.js +5 -0
  47. package/dist/_virtual/formats.js.map +1 -0
  48. package/dist/_virtual/id.js +5 -0
  49. package/dist/_virtual/id.js.map +1 -0
  50. package/dist/_virtual/if.js +5 -0
  51. package/dist/_virtual/if.js.map +1 -0
  52. package/dist/_virtual/index.js +8 -0
  53. package/dist/_virtual/index.js.map +1 -0
  54. package/dist/_virtual/index10.js +5 -0
  55. package/dist/_virtual/index10.js.map +1 -0
  56. package/dist/_virtual/index11.js +5 -0
  57. package/dist/_virtual/index11.js.map +1 -0
  58. package/dist/_virtual/index12.js +5 -0
  59. package/dist/_virtual/index12.js.map +1 -0
  60. package/dist/_virtual/index2.js +5 -0
  61. package/dist/_virtual/index2.js.map +1 -0
  62. package/dist/_virtual/index3.js +5 -0
  63. package/dist/_virtual/index3.js.map +1 -0
  64. package/dist/_virtual/index4.js +5 -0
  65. package/dist/_virtual/index4.js.map +1 -0
  66. package/dist/_virtual/index5.js +5 -0
  67. package/dist/_virtual/index5.js.map +1 -0
  68. package/dist/_virtual/index6.js +5 -0
  69. package/dist/_virtual/index6.js.map +1 -0
  70. package/dist/_virtual/index7.js +5 -0
  71. package/dist/_virtual/index7.js.map +1 -0
  72. package/dist/_virtual/index8.js +5 -0
  73. package/dist/_virtual/index8.js.map +1 -0
  74. package/dist/_virtual/index9.js +5 -0
  75. package/dist/_virtual/index9.js.map +1 -0
  76. package/dist/_virtual/items.js +5 -0
  77. package/dist/_virtual/items.js.map +1 -0
  78. package/dist/_virtual/items2020.js +5 -0
  79. package/dist/_virtual/items2020.js.map +1 -0
  80. package/dist/_virtual/keyword.js +5 -0
  81. package/dist/_virtual/keyword.js.map +1 -0
  82. package/dist/_virtual/limit.js +5 -0
  83. package/dist/_virtual/limit.js.map +1 -0
  84. package/dist/_virtual/limitItems.js +5 -0
  85. package/dist/_virtual/limitItems.js.map +1 -0
  86. package/dist/_virtual/limitLength.js +5 -0
  87. package/dist/_virtual/limitLength.js.map +1 -0
  88. package/dist/_virtual/limitNumber.js +5 -0
  89. package/dist/_virtual/limitNumber.js.map +1 -0
  90. package/dist/_virtual/limitProperties.js +5 -0
  91. package/dist/_virtual/limitProperties.js.map +1 -0
  92. package/dist/_virtual/metadata.js +5 -0
  93. package/dist/_virtual/metadata.js.map +1 -0
  94. package/dist/_virtual/multipleOf.js +5 -0
  95. package/dist/_virtual/multipleOf.js.map +1 -0
  96. package/dist/_virtual/names.js +5 -0
  97. package/dist/_virtual/names.js.map +1 -0
  98. package/dist/_virtual/not.js +5 -0
  99. package/dist/_virtual/not.js.map +1 -0
  100. package/dist/_virtual/oneOf.js +5 -0
  101. package/dist/_virtual/oneOf.js.map +1 -0
  102. package/dist/_virtual/pattern.js +5 -0
  103. package/dist/_virtual/pattern.js.map +1 -0
  104. package/dist/_virtual/patternProperties.js +5 -0
  105. package/dist/_virtual/patternProperties.js.map +1 -0
  106. package/dist/_virtual/prefixItems.js +5 -0
  107. package/dist/_virtual/prefixItems.js.map +1 -0
  108. package/dist/_virtual/properties.js +5 -0
  109. package/dist/_virtual/properties.js.map +1 -0
  110. package/dist/_virtual/propertyNames.js +5 -0
  111. package/dist/_virtual/propertyNames.js.map +1 -0
  112. package/dist/_virtual/ref.js +5 -0
  113. package/dist/_virtual/ref.js.map +1 -0
  114. package/dist/_virtual/ref_error.js +5 -0
  115. package/dist/_virtual/ref_error.js.map +1 -0
  116. package/dist/_virtual/required.js +5 -0
  117. package/dist/_virtual/required.js.map +1 -0
  118. package/dist/_virtual/resolve.js +5 -0
  119. package/dist/_virtual/resolve.js.map +1 -0
  120. package/dist/_virtual/rules.js +5 -0
  121. package/dist/_virtual/rules.js.map +1 -0
  122. package/dist/_virtual/scope.js +5 -0
  123. package/dist/_virtual/scope.js.map +1 -0
  124. package/dist/_virtual/subschema.js +5 -0
  125. package/dist/_virtual/subschema.js.map +1 -0
  126. package/dist/_virtual/thenElse.js +5 -0
  127. package/dist/_virtual/thenElse.js.map +1 -0
  128. package/dist/_virtual/types.js +5 -0
  129. package/dist/_virtual/types.js.map +1 -0
  130. package/dist/_virtual/ucs2length.js +5 -0
  131. package/dist/_virtual/ucs2length.js.map +1 -0
  132. package/dist/_virtual/uniqueItems.js +5 -0
  133. package/dist/_virtual/uniqueItems.js.map +1 -0
  134. package/dist/_virtual/uri.js +5 -0
  135. package/dist/_virtual/uri.js.map +1 -0
  136. package/dist/_virtual/util.js +5 -0
  137. package/dist/_virtual/util.js.map +1 -0
  138. package/dist/_virtual/validation_error.js +5 -0
  139. package/dist/_virtual/validation_error.js.map +1 -0
  140. package/dist/agents/analyst-agent.d.ts +230 -0
  141. package/dist/agents/analyst-agent.d.ts.map +1 -0
  142. package/dist/agents/analyst-agent.js +793 -0
  143. package/dist/agents/analyst-agent.js.map +1 -0
  144. package/dist/agents/architect-agent.d.ts +248 -0
  145. package/dist/agents/architect-agent.d.ts.map +1 -0
  146. package/dist/agents/architect-agent.js +685 -0
  147. package/dist/agents/architect-agent.js.map +1 -0
  148. package/dist/agents/base-agent.d.ts +169 -0
  149. package/dist/agents/base-agent.d.ts.map +1 -0
  150. package/dist/agents/base-agent.js +441 -0
  151. package/dist/agents/base-agent.js.map +1 -0
  152. package/dist/agents/coder-agent.d.ts +191 -0
  153. package/dist/agents/coder-agent.d.ts.map +1 -0
  154. package/dist/agents/coder-agent.js +1008 -0
  155. package/dist/agents/coder-agent.js.map +1 -0
  156. package/dist/agents/index.d.ts +18 -0
  157. package/dist/agents/index.d.ts.map +1 -0
  158. package/dist/agents/index.js +40 -0
  159. package/dist/agents/index.js.map +1 -0
  160. package/dist/agents/registry.d.ts +213 -0
  161. package/dist/agents/registry.d.ts.map +1 -0
  162. package/dist/agents/registry.js +419 -0
  163. package/dist/agents/registry.js.map +1 -0
  164. package/dist/agents/researcher-agent.d.ts +226 -0
  165. package/dist/agents/researcher-agent.d.ts.map +1 -0
  166. package/dist/agents/researcher-agent.js +572 -0
  167. package/dist/agents/researcher-agent.js.map +1 -0
  168. package/dist/agents/rules-engine.d.ts +320 -0
  169. package/dist/agents/rules-engine.d.ts.map +1 -0
  170. package/dist/agents/rules-engine.js +552 -0
  171. package/dist/agents/rules-engine.js.map +1 -0
  172. package/dist/agents/tester-agent.d.ts +219 -0
  173. package/dist/agents/tester-agent.d.ts.map +1 -0
  174. package/dist/agents/tester-agent.js +683 -0
  175. package/dist/agents/tester-agent.js.map +1 -0
  176. package/dist/agents/types.d.ts +425 -0
  177. package/dist/agents/types.d.ts.map +1 -0
  178. package/dist/agents/types.js +57 -0
  179. package/dist/agents/types.js.map +1 -0
  180. package/dist/audit/config.d.ts +150 -0
  181. package/dist/audit/config.d.ts.map +1 -0
  182. package/dist/audit/config.js +111 -0
  183. package/dist/audit/config.js.map +1 -0
  184. package/dist/audit/index.d.ts +38 -0
  185. package/dist/audit/index.d.ts.map +1 -0
  186. package/dist/audit/services/audit-chain.d.ts +276 -0
  187. package/dist/audit/services/audit-chain.d.ts.map +1 -0
  188. package/dist/audit/services/audit-chain.js +502 -0
  189. package/dist/audit/services/audit-chain.js.map +1 -0
  190. package/dist/audit/services/index.d.ts +11 -0
  191. package/dist/audit/services/index.d.ts.map +1 -0
  192. package/dist/audit/services/syndication.d.ts +334 -0
  193. package/dist/audit/services/syndication.d.ts.map +1 -0
  194. package/dist/audit/services/syndication.js +589 -0
  195. package/dist/audit/services/syndication.js.map +1 -0
  196. package/dist/audit/types.d.ts +453 -0
  197. package/dist/audit/types.d.ts.map +1 -0
  198. package/dist/caching/index.d.ts +55 -0
  199. package/dist/caching/index.d.ts.map +1 -0
  200. package/dist/caching/index.js +206 -0
  201. package/dist/caching/index.js.map +1 -0
  202. package/dist/caching/lru-cache.d.ts +254 -0
  203. package/dist/caching/lru-cache.d.ts.map +1 -0
  204. package/dist/caching/types.d.ts +95 -0
  205. package/dist/caching/types.d.ts.map +1 -0
  206. package/dist/chunking/chunker.d.ts +94 -0
  207. package/dist/chunking/chunker.d.ts.map +1 -0
  208. package/dist/chunking/index.d.ts +125 -0
  209. package/dist/chunking/index.d.ts.map +1 -0
  210. package/dist/chunking/index.js +283 -0
  211. package/dist/chunking/index.js.map +1 -0
  212. package/dist/chunking/types.d.ts +92 -0
  213. package/dist/chunking/types.d.ts.map +1 -0
  214. package/dist/cli/commands/audit.d.ts +21 -0
  215. package/dist/cli/commands/audit.d.ts.map +1 -0
  216. package/dist/cli/commands/audit.js +621 -0
  217. package/dist/cli/commands/audit.js.map +1 -0
  218. package/dist/cli/commands/commit.d.ts +11 -0
  219. package/dist/cli/commands/commit.d.ts.map +1 -0
  220. package/dist/cli/commands/commit.js +379 -0
  221. package/dist/cli/commands/commit.js.map +1 -0
  222. package/dist/cli/commands/config.d.ts +8 -0
  223. package/dist/cli/commands/config.d.ts.map +1 -0
  224. package/dist/cli/commands/config.js +107 -0
  225. package/dist/cli/commands/config.js.map +1 -0
  226. package/dist/cli/commands/cultivate.d.ts +16 -0
  227. package/dist/cli/commands/cultivate.d.ts.map +1 -0
  228. package/dist/cli/commands/cultivate.js +254 -0
  229. package/dist/cli/commands/cultivate.js.map +1 -0
  230. package/dist/cli/commands/diagnostics.d.ts +8 -0
  231. package/dist/cli/commands/diagnostics.d.ts.map +1 -0
  232. package/dist/cli/commands/diagnostics.js +140 -0
  233. package/dist/cli/commands/diagnostics.js.map +1 -0
  234. package/dist/cli/commands/generate.d.ts +13 -0
  235. package/dist/cli/commands/generate.d.ts.map +1 -0
  236. package/dist/cli/commands/init-primitives.d.ts +19 -0
  237. package/dist/cli/commands/init-primitives.d.ts.map +1 -0
  238. package/dist/cli/commands/init-primitives.js +208 -0
  239. package/dist/cli/commands/init-primitives.js.map +1 -0
  240. package/dist/cli/commands/sop.d.ts +14 -0
  241. package/dist/cli/commands/sop.d.ts.map +1 -0
  242. package/dist/cli/commands/sop.js +598 -0
  243. package/dist/cli/commands/sop.js.map +1 -0
  244. package/dist/cli/commands/vector.d.ts +14 -0
  245. package/dist/cli/commands/vector.d.ts.map +1 -0
  246. package/dist/cli/commands/vector.js +429 -0
  247. package/dist/cli/commands/vector.js.map +1 -0
  248. package/dist/cli/commands/workflow.d.ts +12 -0
  249. package/dist/cli/commands/workflow.d.ts.map +1 -0
  250. package/dist/cli/commands/workflow.js +471 -0
  251. package/dist/cli/commands/workflow.js.map +1 -0
  252. package/dist/cli/index.d.ts.map +1 -1
  253. package/dist/cli/index.js +66 -1
  254. package/dist/cli/index.js.map +1 -1
  255. package/dist/config/index.d.ts +153 -0
  256. package/dist/config/index.d.ts.map +1 -0
  257. package/dist/config/index.js +141 -0
  258. package/dist/config/index.js.map +1 -0
  259. package/dist/config/manager.d.ts +136 -0
  260. package/dist/config/manager.d.ts.map +1 -0
  261. package/dist/config/types.d.ts +127 -0
  262. package/dist/config/types.d.ts.map +1 -0
  263. package/dist/core/cache.d.ts +185 -0
  264. package/dist/core/cache.d.ts.map +1 -0
  265. package/dist/core/cache.js +435 -0
  266. package/dist/core/cache.js.map +1 -0
  267. package/dist/cultivation/deep-analyzer.d.ts +129 -0
  268. package/dist/cultivation/deep-analyzer.d.ts.map +1 -0
  269. package/dist/cultivation/deep-analyzer.js +322 -0
  270. package/dist/cultivation/deep-analyzer.js.map +1 -0
  271. package/dist/cultivation/index.d.ts +13 -0
  272. package/dist/cultivation/index.d.ts.map +1 -0
  273. package/dist/cultivation/seed-generator.d.ts +92 -0
  274. package/dist/cultivation/seed-generator.d.ts.map +1 -0
  275. package/dist/cultivation/seed-generator.js +1033 -0
  276. package/dist/cultivation/seed-generator.js.map +1 -0
  277. package/dist/cultivation/types.d.ts +230 -0
  278. package/dist/cultivation/types.d.ts.map +1 -0
  279. package/dist/database/schemas/index.d.ts +85 -0
  280. package/dist/database/schemas/index.d.ts.map +1 -0
  281. package/dist/generators/claude-md.d.ts +7 -0
  282. package/dist/generators/claude-md.d.ts.map +1 -1
  283. package/dist/generators/claude-md.js.map +1 -1
  284. package/dist/generators/docs-init.d.ts +6 -0
  285. package/dist/generators/docs-init.d.ts.map +1 -1
  286. package/dist/generators/docs-init.js.map +1 -1
  287. package/dist/health/checks.d.ts +135 -0
  288. package/dist/health/checks.d.ts.map +1 -0
  289. package/dist/health/index.d.ts +119 -0
  290. package/dist/health/index.d.ts.map +1 -0
  291. package/dist/health/index.js +191 -0
  292. package/dist/health/index.js.map +1 -0
  293. package/dist/health/monitor.d.ts +146 -0
  294. package/dist/health/monitor.d.ts.map +1 -0
  295. package/dist/health/types.d.ts +135 -0
  296. package/dist/health/types.d.ts.map +1 -0
  297. package/dist/index.d.ts +32 -0
  298. package/dist/index.d.ts.map +1 -1
  299. package/dist/index.js +182 -1
  300. package/dist/index.js.map +1 -1
  301. package/dist/integrations/auto-commit.d.ts +175 -0
  302. package/dist/integrations/auto-commit.d.ts.map +1 -0
  303. package/dist/integrations/auto-commit.js +399 -0
  304. package/dist/integrations/auto-commit.js.map +1 -0
  305. package/dist/integrations/git.d.ts +299 -0
  306. package/dist/integrations/git.d.ts.map +1 -0
  307. package/dist/integrations/git.js +465 -0
  308. package/dist/integrations/git.js.map +1 -0
  309. package/dist/mcp-server/bin.d.ts +11 -0
  310. package/dist/mcp-server/bin.d.ts.map +1 -0
  311. package/dist/mcp-server/handlers/index.d.ts +57 -0
  312. package/dist/mcp-server/handlers/index.d.ts.map +1 -0
  313. package/dist/mcp-server/handlers/index.js +235 -0
  314. package/dist/mcp-server/handlers/index.js.map +1 -0
  315. package/dist/mcp-server/index.d.ts +28 -0
  316. package/dist/mcp-server/index.d.ts.map +1 -0
  317. package/dist/mcp-server/server.d.ts +133 -0
  318. package/dist/mcp-server/server.d.ts.map +1 -0
  319. package/dist/mcp-server/server.js +280 -0
  320. package/dist/mcp-server/server.js.map +1 -0
  321. package/dist/mcp-server/tools/agents/index.d.ts +10 -0
  322. package/dist/mcp-server/tools/agents/index.d.ts.map +1 -0
  323. package/dist/mcp-server/tools/agents/list.d.ts +19 -0
  324. package/dist/mcp-server/tools/agents/list.d.ts.map +1 -0
  325. package/dist/mcp-server/tools/agents/spawn.d.ts +19 -0
  326. package/dist/mcp-server/tools/agents/spawn.d.ts.map +1 -0
  327. package/dist/mcp-server/tools/audit/checkpoint.d.ts +58 -0
  328. package/dist/mcp-server/tools/audit/checkpoint.d.ts.map +1 -0
  329. package/dist/mcp-server/tools/audit/checkpoint.js +73 -0
  330. package/dist/mcp-server/tools/audit/checkpoint.js.map +1 -0
  331. package/dist/mcp-server/tools/audit/index.d.ts +53 -0
  332. package/dist/mcp-server/tools/audit/index.d.ts.map +1 -0
  333. package/dist/mcp-server/tools/audit/index.js +12 -0
  334. package/dist/mcp-server/tools/audit/index.js.map +1 -0
  335. package/dist/mcp-server/tools/audit/query.d.ts +58 -0
  336. package/dist/mcp-server/tools/audit/query.d.ts.map +1 -0
  337. package/dist/mcp-server/tools/audit/query.js +125 -0
  338. package/dist/mcp-server/tools/audit/query.js.map +1 -0
  339. package/dist/mcp-server/tools/audit/sync.d.ts +58 -0
  340. package/dist/mcp-server/tools/audit/sync.d.ts.map +1 -0
  341. package/dist/mcp-server/tools/audit/sync.js +126 -0
  342. package/dist/mcp-server/tools/audit/sync.js.map +1 -0
  343. package/dist/mcp-server/tools/graph/generate.d.ts +21 -0
  344. package/dist/mcp-server/tools/graph/generate.d.ts.map +1 -0
  345. package/dist/mcp-server/tools/graph/index.d.ts +11 -0
  346. package/dist/mcp-server/tools/graph/index.d.ts.map +1 -0
  347. package/dist/mcp-server/tools/graph/query.d.ts +22 -0
  348. package/dist/mcp-server/tools/graph/query.d.ts.map +1 -0
  349. package/dist/mcp-server/tools/graph/stats.d.ts +22 -0
  350. package/dist/mcp-server/tools/graph/stats.d.ts.map +1 -0
  351. package/dist/mcp-server/tools/health.d.ts +21 -0
  352. package/dist/mcp-server/tools/health.d.ts.map +1 -0
  353. package/dist/mcp-server/tools/index.d.ts +16 -0
  354. package/dist/mcp-server/tools/index.d.ts.map +1 -0
  355. package/dist/mcp-server/tools/registry.d.ts +90 -0
  356. package/dist/mcp-server/tools/registry.d.ts.map +1 -0
  357. package/dist/mcp-server/tools/registry.js +753 -0
  358. package/dist/mcp-server/tools/registry.js.map +1 -0
  359. package/dist/mcp-server/tools/search/index.d.ts +10 -0
  360. package/dist/mcp-server/tools/search/index.d.ts.map +1 -0
  361. package/dist/mcp-server/tools/search/nodes.d.ts +22 -0
  362. package/dist/mcp-server/tools/search/nodes.d.ts.map +1 -0
  363. package/dist/mcp-server/tools/search/tags.d.ts +22 -0
  364. package/dist/mcp-server/tools/search/tags.d.ts.map +1 -0
  365. package/dist/mcp-server/tools/vector/index.d.ts +12 -0
  366. package/dist/mcp-server/tools/vector/index.d.ts.map +1 -0
  367. package/dist/mcp-server/tools/vector/index.js +12 -0
  368. package/dist/mcp-server/tools/vector/index.js.map +1 -0
  369. package/dist/mcp-server/tools/vector/search.d.ts +41 -0
  370. package/dist/mcp-server/tools/vector/search.d.ts.map +1 -0
  371. package/dist/mcp-server/tools/vector/search.js +224 -0
  372. package/dist/mcp-server/tools/vector/search.js.map +1 -0
  373. package/dist/mcp-server/tools/vector/trajectory.d.ts +39 -0
  374. package/dist/mcp-server/tools/vector/trajectory.d.ts.map +1 -0
  375. package/dist/mcp-server/tools/vector/trajectory.js +170 -0
  376. package/dist/mcp-server/tools/vector/trajectory.js.map +1 -0
  377. package/dist/mcp-server/tools/vector/upsert.d.ts +44 -0
  378. package/dist/mcp-server/tools/vector/upsert.d.ts.map +1 -0
  379. package/dist/mcp-server/tools/vector/upsert.js +175 -0
  380. package/dist/mcp-server/tools/vector/upsert.js.map +1 -0
  381. package/dist/mcp-server/tools/workflow/index.d.ts +29 -0
  382. package/dist/mcp-server/tools/workflow/index.d.ts.map +1 -0
  383. package/dist/mcp-server/tools/workflow/index.js +12 -0
  384. package/dist/mcp-server/tools/workflow/index.js.map +1 -0
  385. package/dist/mcp-server/tools/workflow/list.d.ts +41 -0
  386. package/dist/mcp-server/tools/workflow/list.d.ts.map +1 -0
  387. package/dist/mcp-server/tools/workflow/list.js +195 -0
  388. package/dist/mcp-server/tools/workflow/list.js.map +1 -0
  389. package/dist/mcp-server/tools/workflow/start.d.ts +40 -0
  390. package/dist/mcp-server/tools/workflow/start.d.ts.map +1 -0
  391. package/dist/mcp-server/tools/workflow/start.js +165 -0
  392. package/dist/mcp-server/tools/workflow/start.js.map +1 -0
  393. package/dist/mcp-server/tools/workflow/status.d.ts +38 -0
  394. package/dist/mcp-server/tools/workflow/status.d.ts.map +1 -0
  395. package/dist/mcp-server/tools/workflow/status.js +97 -0
  396. package/dist/mcp-server/tools/workflow/status.js.map +1 -0
  397. package/dist/mcp-server/types/index.d.ts +286 -0
  398. package/dist/mcp-server/types/index.d.ts.map +1 -0
  399. package/dist/memory/index.d.ts +10 -0
  400. package/dist/memory/index.d.ts.map +1 -0
  401. package/dist/memory/vault-sync.d.ts +212 -0
  402. package/dist/memory/vault-sync.d.ts.map +1 -0
  403. package/dist/memory/vault-sync.js +463 -0
  404. package/dist/memory/vault-sync.js.map +1 -0
  405. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/index.js +296 -0
  406. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/index.js.map +1 -0
  407. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-compat.js +71 -0
  408. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-compat.js.map +1 -0
  409. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-json-schema-compat.js +26 -0
  410. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-json-schema-compat.js.map +1 -0
  411. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/protocol.js +407 -0
  412. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/protocol.js.map +1 -0
  413. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/types.js +1332 -0
  414. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/types.js.map +1 -0
  415. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/validation/ajv-provider.js +71 -0
  416. package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/validation/ajv-provider.js.map +1 -0
  417. package/dist/node_modules/ajv/dist/ajv.js +84 -0
  418. package/dist/node_modules/ajv/dist/ajv.js.map +1 -0
  419. package/dist/node_modules/ajv/dist/compile/codegen/code.js +160 -0
  420. package/dist/node_modules/ajv/dist/compile/codegen/code.js.map +1 -0
  421. package/dist/node_modules/ajv/dist/compile/codegen/index.js +728 -0
  422. package/dist/node_modules/ajv/dist/compile/codegen/index.js.map +1 -0
  423. package/dist/node_modules/ajv/dist/compile/codegen/scope.js +152 -0
  424. package/dist/node_modules/ajv/dist/compile/codegen/scope.js.map +1 -0
  425. package/dist/node_modules/ajv/dist/compile/errors.js +131 -0
  426. package/dist/node_modules/ajv/dist/compile/errors.js.map +1 -0
  427. package/dist/node_modules/ajv/dist/compile/index.js +234 -0
  428. package/dist/node_modules/ajv/dist/compile/index.js.map +1 -0
  429. package/dist/node_modules/ajv/dist/compile/names.js +44 -0
  430. package/dist/node_modules/ajv/dist/compile/names.js.map +1 -0
  431. package/dist/node_modules/ajv/dist/compile/ref_error.js +22 -0
  432. package/dist/node_modules/ajv/dist/compile/ref_error.js.map +1 -0
  433. package/dist/node_modules/ajv/dist/compile/resolve.js +163 -0
  434. package/dist/node_modules/ajv/dist/compile/resolve.js.map +1 -0
  435. package/dist/node_modules/ajv/dist/compile/rules.js +35 -0
  436. package/dist/node_modules/ajv/dist/compile/rules.js.map +1 -0
  437. package/dist/node_modules/ajv/dist/compile/util.js +173 -0
  438. package/dist/node_modules/ajv/dist/compile/util.js.map +1 -0
  439. package/dist/node_modules/ajv/dist/compile/validate/applicability.js +27 -0
  440. package/dist/node_modules/ajv/dist/compile/validate/applicability.js.map +1 -0
  441. package/dist/node_modules/ajv/dist/compile/validate/boolSchema.js +58 -0
  442. package/dist/node_modules/ajv/dist/compile/validate/boolSchema.js.map +1 -0
  443. package/dist/node_modules/ajv/dist/compile/validate/dataType.js +193 -0
  444. package/dist/node_modules/ajv/dist/compile/validate/dataType.js.map +1 -0
  445. package/dist/node_modules/ajv/dist/compile/validate/defaults.js +43 -0
  446. package/dist/node_modules/ajv/dist/compile/validate/defaults.js.map +1 -0
  447. package/dist/node_modules/ajv/dist/compile/validate/index.js +522 -0
  448. package/dist/node_modules/ajv/dist/compile/validate/index.js.map +1 -0
  449. package/dist/node_modules/ajv/dist/compile/validate/keyword.js +126 -0
  450. package/dist/node_modules/ajv/dist/compile/validate/keyword.js.map +1 -0
  451. package/dist/node_modules/ajv/dist/compile/validate/subschema.js +89 -0
  452. package/dist/node_modules/ajv/dist/compile/validate/subschema.js.map +1 -0
  453. package/dist/node_modules/ajv/dist/core.js +628 -0
  454. package/dist/node_modules/ajv/dist/core.js.map +1 -0
  455. package/dist/node_modules/ajv/dist/refs/data.json.js +24 -0
  456. package/dist/node_modules/ajv/dist/refs/data.json.js.map +1 -0
  457. package/dist/node_modules/ajv/dist/refs/json-schema-draft-07.json.js +25 -0
  458. package/dist/node_modules/ajv/dist/refs/json-schema-draft-07.json.js.map +1 -0
  459. package/dist/node_modules/ajv/dist/runtime/equal.js +16 -0
  460. package/dist/node_modules/ajv/dist/runtime/equal.js.map +1 -0
  461. package/dist/node_modules/ajv/dist/runtime/ucs2length.js +30 -0
  462. package/dist/node_modules/ajv/dist/runtime/ucs2length.js.map +1 -0
  463. package/dist/node_modules/ajv/dist/runtime/uri.js +16 -0
  464. package/dist/node_modules/ajv/dist/runtime/uri.js.map +1 -0
  465. package/dist/node_modules/ajv/dist/runtime/validation_error.js +20 -0
  466. package/dist/node_modules/ajv/dist/runtime/validation_error.js.map +1 -0
  467. package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js +59 -0
  468. package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js.map +1 -0
  469. package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js +114 -0
  470. package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js.map +1 -0
  471. package/dist/node_modules/ajv/dist/vocabularies/applicator/allOf.js +32 -0
  472. package/dist/node_modules/ajv/dist/vocabularies/applicator/allOf.js.map +1 -0
  473. package/dist/node_modules/ajv/dist/vocabularies/applicator/anyOf.js +22 -0
  474. package/dist/node_modules/ajv/dist/vocabularies/applicator/anyOf.js.map +1 -0
  475. package/dist/node_modules/ajv/dist/vocabularies/applicator/contains.js +100 -0
  476. package/dist/node_modules/ajv/dist/vocabularies/applicator/contains.js.map +1 -0
  477. package/dist/node_modules/ajv/dist/vocabularies/applicator/dependencies.js +103 -0
  478. package/dist/node_modules/ajv/dist/vocabularies/applicator/dependencies.js.map +1 -0
  479. package/dist/node_modules/ajv/dist/vocabularies/applicator/if.js +75 -0
  480. package/dist/node_modules/ajv/dist/vocabularies/applicator/if.js.map +1 -0
  481. package/dist/node_modules/ajv/dist/vocabularies/applicator/index.js +68 -0
  482. package/dist/node_modules/ajv/dist/vocabularies/applicator/index.js.map +1 -0
  483. package/dist/node_modules/ajv/dist/vocabularies/applicator/items.js +64 -0
  484. package/dist/node_modules/ajv/dist/vocabularies/applicator/items.js.map +1 -0
  485. package/dist/node_modules/ajv/dist/vocabularies/applicator/items2020.js +43 -0
  486. package/dist/node_modules/ajv/dist/vocabularies/applicator/items2020.js.map +1 -0
  487. package/dist/node_modules/ajv/dist/vocabularies/applicator/not.js +36 -0
  488. package/dist/node_modules/ajv/dist/vocabularies/applicator/not.js.map +1 -0
  489. package/dist/node_modules/ajv/dist/vocabularies/applicator/oneOf.js +64 -0
  490. package/dist/node_modules/ajv/dist/vocabularies/applicator/oneOf.js.map +1 -0
  491. package/dist/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js +81 -0
  492. package/dist/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js.map +1 -0
  493. package/dist/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js +22 -0
  494. package/dist/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js.map +1 -0
  495. package/dist/node_modules/ajv/dist/vocabularies/applicator/properties.js +66 -0
  496. package/dist/node_modules/ajv/dist/vocabularies/applicator/properties.js.map +1 -0
  497. package/dist/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js +49 -0
  498. package/dist/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js.map +1 -0
  499. package/dist/node_modules/ajv/dist/vocabularies/applicator/thenElse.js +23 -0
  500. package/dist/node_modules/ajv/dist/vocabularies/applicator/thenElse.js.map +1 -0
  501. package/dist/node_modules/ajv/dist/vocabularies/code.js +140 -0
  502. package/dist/node_modules/ajv/dist/vocabularies/code.js.map +1 -0
  503. package/dist/node_modules/ajv/dist/vocabularies/core/id.js +19 -0
  504. package/dist/node_modules/ajv/dist/vocabularies/core/id.js.map +1 -0
  505. package/dist/node_modules/ajv/dist/vocabularies/core/index.js +27 -0
  506. package/dist/node_modules/ajv/dist/vocabularies/core/index.js.map +1 -0
  507. package/dist/node_modules/ajv/dist/vocabularies/core/ref.js +132 -0
  508. package/dist/node_modules/ajv/dist/vocabularies/core/ref.js.map +1 -0
  509. package/dist/node_modules/ajv/dist/vocabularies/discriminator/index.js +114 -0
  510. package/dist/node_modules/ajv/dist/vocabularies/discriminator/index.js.map +1 -0
  511. package/dist/node_modules/ajv/dist/vocabularies/discriminator/types.js +18 -0
  512. package/dist/node_modules/ajv/dist/vocabularies/discriminator/types.js.map +1 -0
  513. package/dist/node_modules/ajv/dist/vocabularies/draft7.js +31 -0
  514. package/dist/node_modules/ajv/dist/vocabularies/draft7.js.map +1 -0
  515. package/dist/node_modules/ajv/dist/vocabularies/format/format.js +95 -0
  516. package/dist/node_modules/ajv/dist/vocabularies/format/format.js.map +1 -0
  517. package/dist/node_modules/ajv/dist/vocabularies/format/index.js +16 -0
  518. package/dist/node_modules/ajv/dist/vocabularies/format/index.js.map +1 -0
  519. package/dist/node_modules/ajv/dist/vocabularies/metadata.js +27 -0
  520. package/dist/node_modules/ajv/dist/vocabularies/metadata.js.map +1 -0
  521. package/dist/node_modules/ajv/dist/vocabularies/validation/const.js +36 -0
  522. package/dist/node_modules/ajv/dist/vocabularies/validation/const.js.map +1 -0
  523. package/dist/node_modules/ajv/dist/vocabularies/validation/enum.js +56 -0
  524. package/dist/node_modules/ajv/dist/vocabularies/validation/enum.js.map +1 -0
  525. package/dist/node_modules/ajv/dist/vocabularies/validation/index.js +52 -0
  526. package/dist/node_modules/ajv/dist/vocabularies/validation/index.js.map +1 -0
  527. package/dist/node_modules/ajv/dist/vocabularies/validation/limitItems.js +34 -0
  528. package/dist/node_modules/ajv/dist/vocabularies/validation/limitItems.js.map +1 -0
  529. package/dist/node_modules/ajv/dist/vocabularies/validation/limitLength.js +39 -0
  530. package/dist/node_modules/ajv/dist/vocabularies/validation/limitLength.js.map +1 -0
  531. package/dist/node_modules/ajv/dist/vocabularies/validation/limitNumber.js +37 -0
  532. package/dist/node_modules/ajv/dist/vocabularies/validation/limitNumber.js.map +1 -0
  533. package/dist/node_modules/ajv/dist/vocabularies/validation/limitProperties.js +34 -0
  534. package/dist/node_modules/ajv/dist/vocabularies/validation/limitProperties.js.map +1 -0
  535. package/dist/node_modules/ajv/dist/vocabularies/validation/multipleOf.js +33 -0
  536. package/dist/node_modules/ajv/dist/vocabularies/validation/multipleOf.js.map +1 -0
  537. package/dist/node_modules/ajv/dist/vocabularies/validation/pattern.js +34 -0
  538. package/dist/node_modules/ajv/dist/vocabularies/validation/pattern.js.map +1 -0
  539. package/dist/node_modules/ajv/dist/vocabularies/validation/required.js +89 -0
  540. package/dist/node_modules/ajv/dist/vocabularies/validation/required.js.map +1 -0
  541. package/dist/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js +75 -0
  542. package/dist/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js.map +1 -0
  543. package/dist/node_modules/ajv-formats/dist/formats.js +209 -0
  544. package/dist/node_modules/ajv-formats/dist/formats.js.map +1 -0
  545. package/dist/node_modules/ajv-formats/dist/index.js +51 -0
  546. package/dist/node_modules/ajv-formats/dist/index.js.map +1 -0
  547. package/dist/node_modules/ajv-formats/dist/limit.js +80 -0
  548. package/dist/node_modules/ajv-formats/dist/limit.js.map +1 -0
  549. package/dist/node_modules/fast-deep-equal/index.js +39 -0
  550. package/dist/node_modules/fast-deep-equal/index.js.map +1 -0
  551. package/dist/node_modules/fast-uri/index.js +261 -0
  552. package/dist/node_modules/fast-uri/index.js.map +1 -0
  553. package/dist/node_modules/fast-uri/lib/schemes.js +215 -0
  554. package/dist/node_modules/fast-uri/lib/schemes.js.map +1 -0
  555. package/dist/node_modules/fast-uri/lib/utils.js +261 -0
  556. package/dist/node_modules/fast-uri/lib/utils.js.map +1 -0
  557. package/dist/node_modules/json-schema-traverse/index.js +92 -0
  558. package/dist/node_modules/json-schema-traverse/index.js.map +1 -0
  559. package/dist/node_modules/zod/v4/classic/errors.js +37 -0
  560. package/dist/node_modules/zod/v4/classic/errors.js.map +1 -0
  561. package/dist/node_modules/zod/v4/classic/iso.js +43 -0
  562. package/dist/node_modules/zod/v4/classic/iso.js.map +1 -0
  563. package/dist/node_modules/zod/v4/classic/parse.js +13 -0
  564. package/dist/node_modules/zod/v4/classic/parse.js.map +1 -0
  565. package/dist/node_modules/zod/v4/classic/schemas.js +688 -0
  566. package/dist/node_modules/zod/v4/classic/schemas.js.map +1 -0
  567. package/dist/node_modules/zod/v4/core/api.js +492 -0
  568. package/dist/node_modules/zod/v4/core/api.js.map +1 -0
  569. package/dist/node_modules/zod/v4/core/checks.js +405 -0
  570. package/dist/node_modules/zod/v4/core/checks.js.map +1 -0
  571. package/dist/node_modules/zod/v4/core/core.js +58 -0
  572. package/dist/node_modules/zod/v4/core/core.js.map +1 -0
  573. package/dist/node_modules/zod/v4/core/doc.js +38 -0
  574. package/dist/node_modules/zod/v4/core/doc.js.map +1 -0
  575. package/dist/node_modules/zod/v4/core/errors.js +82 -0
  576. package/dist/node_modules/zod/v4/core/errors.js.map +1 -0
  577. package/dist/node_modules/zod/v4/core/parse.js +60 -0
  578. package/dist/node_modules/zod/v4/core/parse.js.map +1 -0
  579. package/dist/node_modules/zod/v4/core/regexes.js +87 -0
  580. package/dist/node_modules/zod/v4/core/regexes.js.map +1 -0
  581. package/dist/node_modules/zod/v4/core/registries.js +52 -0
  582. package/dist/node_modules/zod/v4/core/registries.js.map +1 -0
  583. package/dist/node_modules/zod/v4/core/schemas.js +1283 -0
  584. package/dist/node_modules/zod/v4/core/schemas.js.map +1 -0
  585. package/dist/node_modules/zod/v4/core/util.js +341 -0
  586. package/dist/node_modules/zod/v4/core/util.js.map +1 -0
  587. package/dist/node_modules/zod/v4/core/versions.js +9 -0
  588. package/dist/node_modules/zod/v4/core/versions.js.map +1 -0
  589. package/dist/node_modules/zod-to-json-schema/dist/esm/parsers/string.js +2 -0
  590. package/dist/node_modules/zod-to-json-schema/dist/esm/parsers/string.js.map +1 -0
  591. package/dist/reasoning/index.d.ts +74 -0
  592. package/dist/reasoning/index.d.ts.map +1 -0
  593. package/dist/reasoning/index.js +124 -0
  594. package/dist/reasoning/index.js.map +1 -0
  595. package/dist/reasoning/tracker.d.ts +210 -0
  596. package/dist/reasoning/tracker.d.ts.map +1 -0
  597. package/dist/reasoning/types.d.ts +146 -0
  598. package/dist/reasoning/types.d.ts.map +1 -0
  599. package/dist/recovery/backup.d.ts +110 -0
  600. package/dist/recovery/backup.d.ts.map +1 -0
  601. package/dist/recovery/index.d.ts +70 -0
  602. package/dist/recovery/index.d.ts.map +1 -0
  603. package/dist/recovery/index.js +186 -0
  604. package/dist/recovery/index.js.map +1 -0
  605. package/dist/recovery/integrity.d.ts +74 -0
  606. package/dist/recovery/integrity.d.ts.map +1 -0
  607. package/dist/recovery/types.d.ts +94 -0
  608. package/dist/recovery/types.d.ts.map +1 -0
  609. package/dist/services/index.d.ts +130 -0
  610. package/dist/services/index.d.ts.map +1 -0
  611. package/dist/services/index.js +134 -0
  612. package/dist/services/index.js.map +1 -0
  613. package/dist/services/manager.d.ts +140 -0
  614. package/dist/services/manager.d.ts.map +1 -0
  615. package/dist/services/types.d.ts +106 -0
  616. package/dist/services/types.d.ts.map +1 -0
  617. package/dist/services/watchers.d.ts +95 -0
  618. package/dist/services/watchers.d.ts.map +1 -0
  619. package/dist/sops/compliance-checker.d.ts +83 -0
  620. package/dist/sops/compliance-checker.d.ts.map +1 -0
  621. package/dist/sops/compliance-checker.js +399 -0
  622. package/dist/sops/compliance-checker.js.map +1 -0
  623. package/dist/sops/gap-analyzer.d.ts +124 -0
  624. package/dist/sops/gap-analyzer.d.ts.map +1 -0
  625. package/dist/sops/gap-analyzer.js +313 -0
  626. package/dist/sops/gap-analyzer.js.map +1 -0
  627. package/dist/sops/index.d.ts +14 -0
  628. package/dist/sops/index.d.ts.map +1 -0
  629. package/dist/sops/overlay-manager.d.ts +115 -0
  630. package/dist/sops/overlay-manager.d.ts.map +1 -0
  631. package/dist/sops/overlay-manager.js +394 -0
  632. package/dist/sops/overlay-manager.js.map +1 -0
  633. package/dist/sops/registry.d.ts +73 -0
  634. package/dist/sops/registry.d.ts.map +1 -0
  635. package/dist/sops/registry.js +919 -0
  636. package/dist/sops/registry.js.map +1 -0
  637. package/dist/sops/types.d.ts +377 -0
  638. package/dist/sops/types.d.ts.map +1 -0
  639. package/dist/sops/types.js +46 -0
  640. package/dist/sops/types.js.map +1 -0
  641. package/dist/utils/error-recovery.d.ts +230 -0
  642. package/dist/utils/error-recovery.d.ts.map +1 -0
  643. package/dist/utils/error-recovery.js +228 -0
  644. package/dist/utils/error-recovery.js.map +1 -0
  645. package/dist/utils/error-taxonomy.d.ts +149 -0
  646. package/dist/utils/error-taxonomy.d.ts.map +1 -0
  647. package/dist/utils/error-taxonomy.js +260 -0
  648. package/dist/utils/error-taxonomy.js.map +1 -0
  649. package/dist/utils/index.d.ts +11 -0
  650. package/dist/utils/index.d.ts.map +1 -0
  651. package/dist/utils/logger.d.ts +139 -0
  652. package/dist/utils/logger.d.ts.map +1 -0
  653. package/dist/utils/logger.js +311 -0
  654. package/dist/utils/logger.js.map +1 -0
  655. package/dist/vector/config.d.ts +300 -0
  656. package/dist/vector/config.d.ts.map +1 -0
  657. package/dist/vector/config.js +124 -0
  658. package/dist/vector/config.js.map +1 -0
  659. package/dist/vector/index.d.ts +50 -0
  660. package/dist/vector/index.d.ts.map +1 -0
  661. package/dist/vector/services/index.d.ts +13 -0
  662. package/dist/vector/services/index.d.ts.map +1 -0
  663. package/dist/vector/services/trajectory-tracker.d.ts +405 -0
  664. package/dist/vector/services/trajectory-tracker.d.ts.map +1 -0
  665. package/dist/vector/services/trajectory-tracker.js +445 -0
  666. package/dist/vector/services/trajectory-tracker.js.map +1 -0
  667. package/dist/vector/services/vector-store.d.ts +339 -0
  668. package/dist/vector/services/vector-store.d.ts.map +1 -0
  669. package/dist/vector/services/vector-store.js +748 -0
  670. package/dist/vector/services/vector-store.js.map +1 -0
  671. package/dist/vector/types.d.ts +677 -0
  672. package/dist/vector/types.d.ts.map +1 -0
  673. package/dist/workflow/adapters/goap-adapter.d.ts +196 -0
  674. package/dist/workflow/adapters/goap-adapter.d.ts.map +1 -0
  675. package/dist/workflow/adapters/goap-adapter.js +706 -0
  676. package/dist/workflow/adapters/goap-adapter.js.map +1 -0
  677. package/dist/workflow/adapters/index.d.ts +10 -0
  678. package/dist/workflow/adapters/index.d.ts.map +1 -0
  679. package/dist/workflow/config.d.ts +135 -0
  680. package/dist/workflow/config.d.ts.map +1 -0
  681. package/dist/workflow/config.js +92 -0
  682. package/dist/workflow/config.js.map +1 -0
  683. package/dist/workflow/handlers/index.d.ts +9 -0
  684. package/dist/workflow/handlers/index.d.ts.map +1 -0
  685. package/dist/workflow/handlers/webhook-handlers.d.ts +397 -0
  686. package/dist/workflow/handlers/webhook-handlers.d.ts.map +1 -0
  687. package/dist/workflow/handlers/webhook-handlers.js +454 -0
  688. package/dist/workflow/handlers/webhook-handlers.js.map +1 -0
  689. package/dist/workflow/index.d.ts +42 -0
  690. package/dist/workflow/index.d.ts.map +1 -0
  691. package/dist/workflow/services/index.d.ts +9 -0
  692. package/dist/workflow/services/index.d.ts.map +1 -0
  693. package/dist/workflow/services/workflow-service.d.ts +318 -0
  694. package/dist/workflow/services/workflow-service.d.ts.map +1 -0
  695. package/dist/workflow/services/workflow-service.js +577 -0
  696. package/dist/workflow/services/workflow-service.js.map +1 -0
  697. package/dist/workflow/types.d.ts +470 -0
  698. package/dist/workflow/types.d.ts.map +1 -0
  699. package/dist/workflow/workflows/realtime-collab.d.ts +245 -0
  700. package/dist/workflow/workflows/realtime-collab.d.ts.map +1 -0
  701. package/dist/workflows/index.d.ts +11 -0
  702. package/dist/workflows/index.d.ts.map +1 -0
  703. package/dist/workflows/registry.d.ts +118 -0
  704. package/dist/workflows/registry.d.ts.map +1 -0
  705. package/dist/workflows/registry.js +575 -0
  706. package/dist/workflows/registry.js.map +1 -0
  707. package/dist/workflows/types.d.ts +322 -0
  708. package/dist/workflows/types.d.ts.map +1 -0
  709. package/dist/workflows/types.js +16 -0
  710. package/dist/workflows/types.js.map +1 -0
  711. package/package.json +1 -1
@@ -0,0 +1,598 @@
1
+ import { Command } from "commander";
2
+ import { existsSync, mkdirSync, writeFileSync } from "fs";
3
+ import { resolve, join } from "path";
4
+ import { ComplianceStatus, SOPPriority } from "../../sops/types.js";
5
+ import { getSopCount, getCategories, getSOPsByCategory, getSOPById, getAllSOPs } from "../../sops/registry.js";
6
+ import { checkCompliance } from "../../sops/compliance-checker.js";
7
+ import { analyzeGaps } from "../../sops/gap-analyzer.js";
8
+ import { createMultiLayerGraph, addComplianceOverlay, getComplianceSummary } from "../../sops/overlay-manager.js";
9
+ function createSOPCommands() {
10
+ const sop = new Command("sop").description("AI-SDLC SOP compliance commands");
11
+ sop.command("init").description("Initialize AI-SDLC SOP standards layer").option("-p, --path <path>", "Project root path", process.cwd()).option("-d, --docs <path>", "Documentation path", "docs").option("-c, --categories <categories>", "SOP categories to include (comma-separated)").option("-v, --verbose", "Verbose output").action(async (options) => {
12
+ const projectRoot = resolve(options.path);
13
+ const docsPath = options.docs;
14
+ const verbose = options.verbose;
15
+ console.log("\n🏛️ Initializing AI-SDLC SOP Standards Layer\n");
16
+ try {
17
+ let categories;
18
+ if (options.categories) {
19
+ categories = options.categories.split(",").map((c) => c.trim());
20
+ }
21
+ const graph = createMultiLayerGraph({
22
+ graphId: `sop-${Date.now()}`,
23
+ graphName: "AI-SDLC Compliance Graph",
24
+ includeAllSOPs: !categories,
25
+ categories
26
+ });
27
+ const sopDir = join(projectRoot, docsPath, "sop");
28
+ if (!existsSync(sopDir)) {
29
+ mkdirSync(sopDir, { recursive: true });
30
+ }
31
+ const graphPath = join(sopDir, "standards-graph.json");
32
+ writeFileSync(graphPath, JSON.stringify(graph, null, 2));
33
+ console.log(` ✓ Created standards layer with ${getSopCount()} SOPs`);
34
+ console.log(` ✓ Saved graph to ${graphPath}`);
35
+ if (verbose) {
36
+ console.log("\n Categories included:");
37
+ for (const category of getCategories()) {
38
+ const count = getSOPsByCategory(category).length;
39
+ console.log(` - ${category}: ${count} SOPs`);
40
+ }
41
+ }
42
+ const indexPath = join(sopDir, "SOP-INDEX.md");
43
+ const indexContent = generateSOPIndex(categories);
44
+ writeFileSync(indexPath, indexContent);
45
+ console.log(` ✓ Created SOP index at ${indexPath}`);
46
+ console.log("\n✨ SOP standards layer initialized!\n");
47
+ console.log("Next steps:");
48
+ console.log(' - Run "kg sop check" to assess compliance');
49
+ console.log(' - Run "kg sop gaps" to identify gaps');
50
+ console.log(' - Run "kg sop report" to generate compliance report');
51
+ console.log("");
52
+ } catch (error) {
53
+ console.error("\n❌ SOP initialization failed:", error);
54
+ process.exit(1);
55
+ }
56
+ });
57
+ sop.command("check").description("Check project compliance against AI-SDLC SOPs").option("-p, --path <path>", "Project root path", process.cwd()).option("-d, --docs <path>", "Documentation path", "docs").option("-s, --sop <id>", "Check specific SOP by ID").option("-c, --category <category>", "Check SOPs in specific category").option("--deep", "Perform deep analysis of file contents").option("--threshold <number>", "Minimum compliance threshold (0-100)", "50").option("-v, --verbose", "Verbose output").option("--json", "Output as JSON").action(async (options) => {
58
+ const projectRoot = resolve(options.path);
59
+ const docsPath = options.docs;
60
+ const verbose = options.verbose;
61
+ const threshold = parseInt(options.threshold, 10);
62
+ if (!options.json) {
63
+ console.log("\n🔍 Checking AI-SDLC SOP Compliance\n");
64
+ }
65
+ try {
66
+ const checkOptions = {
67
+ projectRoot,
68
+ docsPath,
69
+ deepAnalysis: options.deep,
70
+ assessor: "cli-automated"
71
+ };
72
+ if (options.sop) {
73
+ checkOptions.sopIds = [options.sop];
74
+ }
75
+ if (options.category) {
76
+ checkOptions.categories = [options.category];
77
+ }
78
+ const result = await checkCompliance(checkOptions);
79
+ if (options.json) {
80
+ console.log(JSON.stringify(result, null, 2));
81
+ return;
82
+ }
83
+ console.log(` Project: ${result.projectName}`);
84
+ console.log(` Overall Score: ${getScoreEmoji(result.overallScore)} ${result.overallScore}%
85
+ `);
86
+ console.log(" Category Scores:");
87
+ for (const [category, score] of Object.entries(result.categoryScores)) {
88
+ if (score > 0) {
89
+ console.log(` ${getScoreEmoji(score)} ${formatCategory(category)}: ${score}%`);
90
+ }
91
+ }
92
+ console.log("");
93
+ const compliant = result.assessments.filter((a) => a.status === ComplianceStatus.COMPLIANT).length;
94
+ const partial = result.assessments.filter((a) => a.status === ComplianceStatus.PARTIAL).length;
95
+ const nonCompliant = result.assessments.filter((a) => a.status === ComplianceStatus.NON_COMPLIANT).length;
96
+ console.log(" Assessment Summary:");
97
+ console.log(` ✅ Compliant: ${compliant}`);
98
+ console.log(` 🟡 Partial: ${partial}`);
99
+ console.log(` ❌ Non-compliant: ${nonCompliant}`);
100
+ console.log("");
101
+ if (verbose) {
102
+ console.log(" Detailed Assessments:");
103
+ for (const assessment of result.assessments) {
104
+ const sop2 = getSOPById(assessment.sopId);
105
+ if (sop2) {
106
+ console.log(`
107
+ ${getStatusIcon(assessment.status)} ${sop2.title}`);
108
+ console.log(` Score: ${assessment.score}%`);
109
+ console.log(` Met: ${assessment.requirementsMet.length}/${assessment.requirementsMet.length + assessment.requirementsGaps.length}`);
110
+ }
111
+ }
112
+ console.log("");
113
+ }
114
+ if (result.overallScore < threshold) {
115
+ console.log(` ⚠️ Below compliance threshold of ${threshold}%`);
116
+ console.log(' Run "kg sop gaps" to see remediation recommendations\n');
117
+ } else {
118
+ console.log(` ✨ Meets compliance threshold of ${threshold}%
119
+ `);
120
+ }
121
+ if (result.evidence.length > 0 && verbose) {
122
+ console.log(` Evidence Found: ${result.evidence.length} items`);
123
+ }
124
+ } catch (error) {
125
+ console.error("\n❌ Compliance check failed:", error);
126
+ process.exit(1);
127
+ }
128
+ });
129
+ sop.command("gaps").description("Analyze compliance gaps and generate remediation recommendations").option("-p, --path <path>", "Project root path", process.cwd()).option("-d, --docs <path>", "Documentation path", "docs").option("--priority <priority>", "Minimum gap priority (critical, high, medium, low)").option("--category <category>", "Filter by category").option("--roadmap", "Include remediation roadmap").option("-v, --verbose", "Verbose output").option("--json", "Output as JSON").action(async (options) => {
130
+ const projectRoot = resolve(options.path);
131
+ const docsPath = options.docs;
132
+ const verbose = options.verbose;
133
+ if (!options.json) {
134
+ console.log("\n📋 Analyzing Compliance Gaps\n");
135
+ }
136
+ try {
137
+ const checkResult = await checkCompliance({
138
+ projectRoot,
139
+ docsPath,
140
+ deepAnalysis: true
141
+ });
142
+ let minPriority;
143
+ if (options.priority) {
144
+ minPriority = options.priority;
145
+ }
146
+ let categories;
147
+ if (options.category) {
148
+ categories = [options.category];
149
+ }
150
+ const gapResult = analyzeGaps(checkResult, {
151
+ minPriority,
152
+ categories,
153
+ generateRemediation: true
154
+ });
155
+ if (options.json) {
156
+ console.log(JSON.stringify(gapResult, null, 2));
157
+ return;
158
+ }
159
+ console.log(` Total Gaps: ${gapResult.totalGaps}`);
160
+ console.log(` Compliance: ${gapResult.summary.compliancePercentage}%`);
161
+ console.log(` Complexity: ${gapResult.summary.overallComplexity}
162
+ `);
163
+ console.log(" Gaps by Priority:");
164
+ console.log(` 🔴 Critical: ${gapResult.byPriority[SOPPriority.CRITICAL].length}`);
165
+ console.log(` 🟠 High: ${gapResult.byPriority[SOPPriority.HIGH].length}`);
166
+ console.log(` 🟡 Medium: ${gapResult.byPriority[SOPPriority.MEDIUM].length}`);
167
+ console.log(` 🟢 Low: ${gapResult.byPriority[SOPPriority.LOW].length}`);
168
+ console.log("");
169
+ console.log(" Gaps by Category:");
170
+ for (const [category, gaps] of Object.entries(gapResult.byCategory)) {
171
+ if (gaps.length > 0) {
172
+ console.log(` ${formatCategory(category)}: ${gaps.length}`);
173
+ }
174
+ }
175
+ console.log("");
176
+ if (gapResult.criticalGaps.length > 0) {
177
+ console.log(" 🚨 Critical Gaps (Immediate Action Required):");
178
+ for (const gap of gapResult.criticalGaps) {
179
+ const sop2 = getSOPById(gap.sopId);
180
+ console.log(`
181
+ • ${sop2?.title || gap.sopId}`);
182
+ console.log(` ${gap.description.substring(0, 80)}...`);
183
+ console.log(` Effort: ${gap.effort}`);
184
+ }
185
+ console.log("");
186
+ }
187
+ if (gapResult.roadmap?.quickWins && gapResult.roadmap.quickWins.length > 0) {
188
+ console.log(" 💡 Quick Wins (High Impact, Low Effort):");
189
+ for (const gap of gapResult.roadmap.quickWins.slice(0, 5)) {
190
+ const sop2 = getSOPById(gap.sopId);
191
+ console.log(` • ${sop2?.title || gap.sopId}`);
192
+ }
193
+ console.log("");
194
+ }
195
+ if (options.roadmap && gapResult.roadmap) {
196
+ console.log(" 📍 Remediation Roadmap:");
197
+ for (const phase of gapResult.roadmap.phases) {
198
+ console.log(`
199
+ Phase ${phase.phase}: ${phase.name}`);
200
+ console.log(` Focus: ${phase.focus}`);
201
+ console.log(` Gaps: ${phase.gaps.length}`);
202
+ console.log(` Effort: ${phase.effort}`);
203
+ }
204
+ console.log("");
205
+ }
206
+ if (verbose) {
207
+ console.log(" All Gaps:");
208
+ for (const gap of gapResult.gaps) {
209
+ console.log(`
210
+ [${gap.priority.toUpperCase()}] ${gap.id}`);
211
+ console.log(` SOP: ${gap.sopId}`);
212
+ console.log(` Description: ${gap.description.substring(0, 100)}...`);
213
+ console.log(` Remediation: ${gap.remediation.substring(0, 100)}...`);
214
+ }
215
+ console.log("");
216
+ }
217
+ } catch (error) {
218
+ console.error("\n❌ Gap analysis failed:", error);
219
+ process.exit(1);
220
+ }
221
+ });
222
+ sop.command("report").description("Generate comprehensive compliance report").option("-p, --path <path>", "Project root path", process.cwd()).option("-d, --docs <path>", "Documentation path", "docs").option("-o, --output <file>", "Output file path").option("-f, --format <format>", "Output format (md, json, html)", "md").option("--include-evidence", "Include evidence details").option("--include-roadmap", "Include remediation roadmap").action(async (options) => {
223
+ const projectRoot = resolve(options.path);
224
+ const docsPath = options.docs;
225
+ const format = options.format;
226
+ console.log("\n📝 Generating Compliance Report\n");
227
+ try {
228
+ const checkResult = await checkCompliance({
229
+ projectRoot,
230
+ docsPath,
231
+ deepAnalysis: true
232
+ });
233
+ const gapResult = analyzeGaps(checkResult, {
234
+ generateRemediation: true
235
+ });
236
+ const graph = createMultiLayerGraph();
237
+ addComplianceOverlay(graph, checkResult, gapResult);
238
+ const summary = getComplianceSummary(graph);
239
+ let report;
240
+ if (format === "json") {
241
+ report = JSON.stringify({
242
+ checkResult,
243
+ gapResult,
244
+ summary,
245
+ generatedAt: (/* @__PURE__ */ new Date()).toISOString()
246
+ }, null, 2);
247
+ } else if (format === "html") {
248
+ report = generateHTMLReport(checkResult, gapResult, summary, options);
249
+ } else {
250
+ report = generateMarkdownReport(checkResult, gapResult, summary, options);
251
+ }
252
+ if (options.output) {
253
+ const outputPath = resolve(options.output);
254
+ writeFileSync(outputPath, report);
255
+ console.log(` ✓ Report saved to ${outputPath}`);
256
+ } else {
257
+ const sopDir = join(projectRoot, docsPath, "sop");
258
+ if (!existsSync(sopDir)) {
259
+ mkdirSync(sopDir, { recursive: true });
260
+ }
261
+ const outputPath = join(sopDir, `COMPLIANCE-REPORT.${format}`);
262
+ writeFileSync(outputPath, report);
263
+ console.log(` ✓ Report saved to ${outputPath}`);
264
+ }
265
+ console.log("\n✨ Report generated successfully!\n");
266
+ } catch (error) {
267
+ console.error("\n❌ Report generation failed:", error);
268
+ process.exit(1);
269
+ }
270
+ });
271
+ sop.command("list").description("List available AI-SDLC SOPs").option("-c, --category <category>", "Filter by category").option("--irb", "Show only SOPs requiring AI-IRB review").option("--json", "Output as JSON").action((options) => {
272
+ let sops = getAllSOPs();
273
+ if (options.category) {
274
+ sops = getSOPsByCategory(options.category);
275
+ }
276
+ if (options.irb) {
277
+ sops = sops.filter((s) => s.irbTypicallyRequired);
278
+ }
279
+ if (options.json) {
280
+ console.log(JSON.stringify(sops, null, 2));
281
+ return;
282
+ }
283
+ console.log("\n📚 AI-SDLC Standard Operating Procedures\n");
284
+ console.log(` Total: ${sops.length} SOPs
285
+ `);
286
+ const byCategory = /* @__PURE__ */ new Map();
287
+ for (const sop2 of sops) {
288
+ if (!byCategory.has(sop2.category)) {
289
+ byCategory.set(sop2.category, []);
290
+ }
291
+ byCategory.get(sop2.category).push(sop2);
292
+ }
293
+ for (const [category, categorySops] of byCategory) {
294
+ console.log(` ${formatCategory(category)} (${categorySops.length}):`);
295
+ for (const sop2 of categorySops) {
296
+ const irb = sop2.irbTypicallyRequired ? " 🔬" : "";
297
+ console.log(` • ${sop2.id}: ${sop2.title}${irb}`);
298
+ }
299
+ console.log("");
300
+ }
301
+ });
302
+ return sop;
303
+ }
304
+ function getScoreEmoji(score) {
305
+ if (score >= 90) return "✅";
306
+ if (score >= 70) return "🟡";
307
+ if (score >= 50) return "🟠";
308
+ return "🔴";
309
+ }
310
+ function getStatusIcon(status) {
311
+ switch (status) {
312
+ case ComplianceStatus.COMPLIANT:
313
+ return "✅";
314
+ case ComplianceStatus.PARTIAL:
315
+ return "🟡";
316
+ case ComplianceStatus.NON_COMPLIANT:
317
+ return "❌";
318
+ case ComplianceStatus.NOT_APPLICABLE:
319
+ return "⚪";
320
+ case ComplianceStatus.PENDING:
321
+ return "⏳";
322
+ default:
323
+ return "❓";
324
+ }
325
+ }
326
+ function formatCategory(category) {
327
+ return category.split("-").map((word) => word.charAt(0).toUpperCase() + word.slice(1)).join(" ");
328
+ }
329
+ function generateSOPIndex(categories) {
330
+ const sops = categories ? categories.flatMap((c) => getSOPsByCategory(c)) : getAllSOPs();
331
+ let content = `---
332
+ title: AI-SDLC SOP Index
333
+ type: standards
334
+ created: ${(/* @__PURE__ */ new Date()).toISOString().split("T")[0]}
335
+ tags: [sop, ai-sdlc, compliance, standards]
336
+ ---
337
+
338
+ # AI-SDLC Standard Operating Procedures
339
+
340
+ This document provides an index of AI-SDLC SOPs applicable to this project.
341
+
342
+ ## Overview
343
+
344
+ - **Total SOPs**: ${sops.length}
345
+ - **Source**: [AI-SDLC-SOPs](https://github.com/AISDLC/AI-SDLC-SOPs)
346
+ - **Generated**: ${(/* @__PURE__ */ new Date()).toISOString()}
347
+
348
+ ## SOPs by Category
349
+
350
+ `;
351
+ const byCategory = /* @__PURE__ */ new Map();
352
+ for (const sop of sops) {
353
+ if (!byCategory.has(sop.category)) {
354
+ byCategory.set(sop.category, []);
355
+ }
356
+ byCategory.get(sop.category).push(sop);
357
+ }
358
+ for (const [category, categorySops] of byCategory) {
359
+ content += `### ${formatCategory(category)}
360
+
361
+ `;
362
+ for (const sop of categorySops) {
363
+ const irb = sop.irbTypicallyRequired ? " 🔬" : "";
364
+ content += `- **${sop.id}**: ${sop.title}${irb}
365
+ `;
366
+ content += ` - Priority: ${sop.priority}
367
+ `;
368
+ content += ` - Requirements: ${sop.requirements.length}
369
+ `;
370
+ }
371
+ content += "\n";
372
+ }
373
+ content += `## Legend
374
+
375
+ - 🔬 Requires AI-IRB review
376
+ - Requirements count indicates number of checkable items
377
+
378
+ ## Next Steps
379
+
380
+ 1. Run \`kg sop check\` to assess current compliance
381
+ 2. Run \`kg sop gaps\` to identify remediation needs
382
+ 3. Run \`kg sop report\` to generate detailed report
383
+ `;
384
+ return content;
385
+ }
386
+ function generateMarkdownReport(checkResult, gapResult, summary, options) {
387
+ let report = `---
388
+ title: AI-SDLC Compliance Report
389
+ type: report
390
+ generated: ${(/* @__PURE__ */ new Date()).toISOString()}
391
+ tags: [compliance, sop, report]
392
+ ---
393
+
394
+ # AI-SDLC Compliance Report
395
+
396
+ **Project**: ${checkResult.projectName}
397
+ **Generated**: ${checkResult.checkedAt.toISOString()}
398
+
399
+ ## Executive Summary
400
+
401
+ | Metric | Value |
402
+ |--------|-------|
403
+ | Overall Score | ${checkResult.overallScore}% |
404
+ | Compliant SOPs | ${summary.compliant} |
405
+ | Partial Compliance | ${summary.partial} |
406
+ | Non-Compliant | ${summary.nonCompliant} |
407
+ | Pending Assessment | ${summary.pending} |
408
+ | Total Gaps | ${gapResult.totalGaps} |
409
+
410
+ ## Category Scores
411
+
412
+ `;
413
+ for (const [category, score] of Object.entries(checkResult.categoryScores)) {
414
+ if (score > 0) {
415
+ report += `- **${formatCategory(category)}**: ${score}%
416
+ `;
417
+ }
418
+ }
419
+ report += `
420
+ ## Gap Analysis
421
+
422
+ ### By Priority
423
+
424
+ | Priority | Count |
425
+ |----------|-------|
426
+ | Critical | ${gapResult.byPriority[SOPPriority.CRITICAL].length} |
427
+ | High | ${gapResult.byPriority[SOPPriority.HIGH].length} |
428
+ | Medium | ${gapResult.byPriority[SOPPriority.MEDIUM].length} |
429
+ | Low | ${gapResult.byPriority[SOPPriority.LOW].length} |
430
+
431
+ ### Effort Breakdown
432
+
433
+ - Low effort: ${gapResult.summary.totalEffort.low}
434
+ - Medium effort: ${gapResult.summary.totalEffort.medium}
435
+ - High effort: ${gapResult.summary.totalEffort.high}
436
+
437
+ ## Critical Gaps
438
+
439
+ `;
440
+ if (gapResult.criticalGaps.length > 0) {
441
+ for (const gap of gapResult.criticalGaps) {
442
+ const sop = getSOPById(gap.sopId);
443
+ report += `### ${sop?.title || gap.sopId}
444
+
445
+ - **Gap ID**: ${gap.id}
446
+ - **Requirement**: ${gap.requirementId}
447
+ - **Priority**: ${gap.priority}
448
+ - **Effort**: ${gap.effort}
449
+ - **Impact**: ${gap.impact}
450
+
451
+ **Remediation**: ${gap.remediation}
452
+
453
+ ---
454
+
455
+ `;
456
+ }
457
+ } else {
458
+ report += "No critical gaps identified.\n\n";
459
+ }
460
+ if (options.includeRoadmap && gapResult.roadmap) {
461
+ report += `## Remediation Roadmap
462
+
463
+ `;
464
+ for (const phase of gapResult.roadmap.phases) {
465
+ report += `### Phase ${phase.phase}: ${phase.name}
466
+
467
+ - **Focus**: ${phase.focus}
468
+ - **Effort**: ${phase.effort}
469
+ - **Gaps**: ${phase.gaps.length}
470
+
471
+ `;
472
+ }
473
+ }
474
+ if (options.includeEvidence && checkResult.evidence.length > 0) {
475
+ report += `## Evidence Found
476
+
477
+ `;
478
+ for (const evidence of checkResult.evidence) {
479
+ report += `- **${evidence.requirementId}**: ${evidence.description}
480
+ - File: \`${evidence.filePath}\`
481
+ - Confidence: ${Math.round(evidence.confidence * 100)}%
482
+ `;
483
+ }
484
+ }
485
+ report += `
486
+ ## Recommendations
487
+
488
+ `;
489
+ if (gapResult.criticalGaps.length > 0) {
490
+ report += `1. **Address Critical Gaps Immediately**: ${gapResult.criticalGaps.length} critical gaps require immediate attention.
491
+ `;
492
+ }
493
+ if (gapResult.roadmap?.quickWins && gapResult.roadmap.quickWins.length > 0) {
494
+ report += `2. **Quick Wins**: ${gapResult.roadmap.quickWins.length} high-impact, low-effort improvements available.
495
+ `;
496
+ }
497
+ if (checkResult.overallScore < 50) {
498
+ report += `3. **Compliance Baseline**: Current score of ${checkResult.overallScore}% is below recommended baseline. Focus on foundational SOPs.
499
+ `;
500
+ }
501
+ report += `
502
+ ---
503
+
504
+ *Report generated by Knowledge Graph Agent - AI-SDLC SOP Compliance Module*
505
+ `;
506
+ return report;
507
+ }
508
+ function generateHTMLReport(checkResult, gapResult, summary, options) {
509
+ return `<!DOCTYPE html>
510
+ <html lang="en">
511
+ <head>
512
+ <meta charset="UTF-8">
513
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
514
+ <title>AI-SDLC Compliance Report</title>
515
+ <style>
516
+ body { font-family: system-ui, sans-serif; max-width: 1200px; margin: 0 auto; padding: 2rem; }
517
+ .score { font-size: 3rem; font-weight: bold; }
518
+ .score.high { color: #22c55e; }
519
+ .score.medium { color: #f59e0b; }
520
+ .score.low { color: #ef4444; }
521
+ .card { border: 1px solid #e5e7eb; border-radius: 8px; padding: 1rem; margin: 1rem 0; }
522
+ .grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
523
+ table { width: 100%; border-collapse: collapse; }
524
+ th, td { border: 1px solid #e5e7eb; padding: 0.5rem; text-align: left; }
525
+ th { background: #f9fafb; }
526
+ .badge { display: inline-block; padding: 0.25rem 0.5rem; border-radius: 4px; font-size: 0.875rem; }
527
+ .badge.critical { background: #fef2f2; color: #b91c1c; }
528
+ .badge.high { background: #fff7ed; color: #c2410c; }
529
+ .badge.medium { background: #fefce8; color: #a16207; }
530
+ .badge.low { background: #f0fdf4; color: #15803d; }
531
+ </style>
532
+ </head>
533
+ <body>
534
+ <h1>AI-SDLC Compliance Report</h1>
535
+ <p><strong>Project:</strong> ${checkResult.projectName}</p>
536
+ <p><strong>Generated:</strong> ${checkResult.checkedAt.toISOString()}</p>
537
+
538
+ <div class="grid">
539
+ <div class="card">
540
+ <h3>Overall Score</h3>
541
+ <div class="score ${checkResult.overallScore >= 70 ? "high" : checkResult.overallScore >= 50 ? "medium" : "low"}">
542
+ ${checkResult.overallScore}%
543
+ </div>
544
+ </div>
545
+ <div class="card">
546
+ <h3>Compliance Status</h3>
547
+ <p>✅ Compliant: ${summary.compliant}</p>
548
+ <p>🟡 Partial: ${summary.partial}</p>
549
+ <p>❌ Non-compliant: ${summary.nonCompliant}</p>
550
+ </div>
551
+ <div class="card">
552
+ <h3>Gap Summary</h3>
553
+ <p>Total Gaps: ${gapResult.totalGaps}</p>
554
+ <p>Critical: ${gapResult.criticalGaps.length}</p>
555
+ <p>Complexity: ${gapResult.summary.overallComplexity}</p>
556
+ </div>
557
+ </div>
558
+
559
+ <h2>Category Scores</h2>
560
+ <table>
561
+ <tr><th>Category</th><th>Score</th></tr>
562
+ ${Object.entries(checkResult.categoryScores).filter(([, score]) => score > 0).map(([cat, score]) => `<tr><td>${formatCategory(cat)}</td><td>${score}%</td></tr>`).join("")}
563
+ </table>
564
+
565
+ <h2>Gaps by Priority</h2>
566
+ <table>
567
+ <tr><th>Priority</th><th>Count</th></tr>
568
+ <tr><td><span class="badge critical">Critical</span></td><td>${gapResult.byPriority[SOPPriority.CRITICAL].length}</td></tr>
569
+ <tr><td><span class="badge high">High</span></td><td>${gapResult.byPriority[SOPPriority.HIGH].length}</td></tr>
570
+ <tr><td><span class="badge medium">Medium</span></td><td>${gapResult.byPriority[SOPPriority.MEDIUM].length}</td></tr>
571
+ <tr><td><span class="badge low">Low</span></td><td>${gapResult.byPriority[SOPPriority.LOW].length}</td></tr>
572
+ </table>
573
+
574
+ ${gapResult.criticalGaps.length > 0 ? `
575
+ <h2>Critical Gaps</h2>
576
+ ${gapResult.criticalGaps.map((gap) => {
577
+ const sop = getSOPById(gap.sopId);
578
+ return `
579
+ <div class="card">
580
+ <h3>${sop?.title || gap.sopId}</h3>
581
+ <p><strong>Gap ID:</strong> ${gap.id}</p>
582
+ <p><strong>Impact:</strong> ${gap.impact}</p>
583
+ <p><strong>Remediation:</strong> ${gap.remediation}</p>
584
+ </div>
585
+ `;
586
+ }).join("")}
587
+ ` : ""}
588
+
589
+ <footer style="margin-top: 2rem; padding-top: 1rem; border-top: 1px solid #e5e7eb; color: #6b7280;">
590
+ <p>Generated by Knowledge Graph Agent - AI-SDLC SOP Compliance Module</p>
591
+ </footer>
592
+ </body>
593
+ </html>`;
594
+ }
595
+ export {
596
+ createSOPCommands
597
+ };
598
+ //# sourceMappingURL=sop.js.map