kibi-cli 2.3.0 → 2.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (380) hide show
  1. package/dist/cli-json-command.d.ts +6 -0
  2. package/dist/cli-json-command.d.ts.map +1 -1
  3. package/dist/cli-json-command.js +39 -11
  4. package/dist/cli-operation-loader.d.ts.map +1 -1
  5. package/dist/cli-operation-loader.js +7 -0
  6. package/dist/cli-operation-metadata.d.ts +13 -5
  7. package/dist/cli-operation-metadata.d.ts.map +1 -1
  8. package/dist/cli-operation-metadata.js +15 -5
  9. package/dist/cli-protocol.d.ts +14 -0
  10. package/dist/cli-protocol.d.ts.map +1 -1
  11. package/dist/cli-protocol.js +31 -2
  12. package/dist/cli-register-maintenance.d.ts.map +1 -1
  13. package/dist/cli-register-maintenance.js +7 -0
  14. package/dist/cli-register-proof.d.ts.map +1 -1
  15. package/dist/cli-register-proof.js +13 -0
  16. package/dist/commands/check.d.ts.map +1 -1
  17. package/dist/commands/check.js +11 -2
  18. package/dist/commands/discovery-shared.d.ts.map +1 -1
  19. package/dist/commands/discovery-shared.js +8 -2
  20. package/dist/commands/engine.d.ts.map +1 -1
  21. package/dist/commands/engine.js +4 -2
  22. package/dist/commands/gc.d.ts.map +1 -1
  23. package/dist/commands/gc.js +7 -0
  24. package/dist/commands/init-helpers.d.ts.map +1 -1
  25. package/dist/commands/init-helpers.js +0 -1
  26. package/dist/commands/merge-driver.d.ts +31 -0
  27. package/dist/commands/merge-driver.d.ts.map +1 -0
  28. package/dist/commands/merge-driver.js +268 -0
  29. package/dist/commands/migrate.d.ts.map +1 -1
  30. package/dist/commands/migrate.js +281 -14
  31. package/dist/commands/proof-compact.d.ts +9 -0
  32. package/dist/commands/proof-compact.d.ts.map +1 -0
  33. package/dist/commands/proof-compact.js +58 -0
  34. package/dist/commands/prove.d.ts +38 -0
  35. package/dist/commands/prove.d.ts.map +1 -1
  36. package/dist/commands/prove.js +222 -47
  37. package/dist/commands/sync/persistence.d.ts.map +1 -1
  38. package/dist/commands/sync/persistence.js +61 -16
  39. package/dist/commands/sync.d.ts +8 -0
  40. package/dist/commands/sync.d.ts.map +1 -1
  41. package/dist/commands/sync.js +42 -16
  42. package/dist/diagnostics.js +1 -1
  43. package/dist/engine-limits.d.ts +74 -0
  44. package/dist/engine-limits.d.ts.map +1 -0
  45. package/dist/engine-limits.js +201 -0
  46. package/dist/engine.d.ts +10 -0
  47. package/dist/engine.d.ts.map +1 -1
  48. package/dist/engine.js +57 -9
  49. package/dist/extractors/manifest.d.ts +8 -0
  50. package/dist/extractors/manifest.d.ts.map +1 -1
  51. package/dist/extractors/manifest.js +34 -5
  52. package/dist/extractors/markdown.d.ts +8 -0
  53. package/dist/extractors/markdown.d.ts.map +1 -1
  54. package/dist/extractors/markdown.js +57 -0
  55. package/dist/extractors/relationships.d.ts.map +1 -1
  56. package/dist/extractors/relationships.js +2 -0
  57. package/dist/intent-search.d.ts +4 -1
  58. package/dist/intent-search.d.ts.map +1 -1
  59. package/dist/intent-search.js +186 -33
  60. package/dist/operations/bootstrap/candidate-helpers.d.ts.map +1 -1
  61. package/dist/operations/bootstrap/candidate-helpers.js +8 -1
  62. package/dist/operations/bootstrap/candidates.d.ts.map +1 -1
  63. package/dist/operations/bootstrap/candidates.js +55 -39
  64. package/dist/operations/bootstrap/discovery.js +1 -1
  65. package/dist/operations/bootstrap/generate.d.ts +2 -0
  66. package/dist/operations/bootstrap/generate.d.ts.map +1 -1
  67. package/dist/operations/bootstrap/generate.js +107 -37
  68. package/dist/operations/bootstrap/guidance-actions.d.ts.map +1 -1
  69. package/dist/operations/bootstrap/guidance-actions.js +3 -0
  70. package/dist/operations/bootstrap/guidance.d.ts.map +1 -1
  71. package/dist/operations/bootstrap/guidance.js +7 -1
  72. package/dist/operations/bootstrap/intent-claims.d.ts +17 -0
  73. package/dist/operations/bootstrap/intent-claims.d.ts.map +1 -0
  74. package/dist/operations/bootstrap/intent-claims.js +103 -0
  75. package/dist/operations/bootstrap/markdown-candidates.d.ts +2 -0
  76. package/dist/operations/bootstrap/markdown-candidates.d.ts.map +1 -1
  77. package/dist/operations/bootstrap/markdown-candidates.js +32 -10
  78. package/dist/operations/bootstrap/presentation.d.ts +2 -0
  79. package/dist/operations/bootstrap/presentation.d.ts.map +1 -1
  80. package/dist/operations/bootstrap/presentation.js +66 -3
  81. package/dist/operations/bootstrap/requirement-claims.d.ts +1 -0
  82. package/dist/operations/bootstrap/requirement-claims.d.ts.map +1 -1
  83. package/dist/operations/bootstrap/requirement-claims.js +13 -1
  84. package/dist/operations/bootstrap/types.d.ts +28 -0
  85. package/dist/operations/bootstrap/types.d.ts.map +1 -1
  86. package/dist/operations/bootstrap/types.js +16 -0
  87. package/dist/operations/bootstrap/validation.d.ts +4 -0
  88. package/dist/operations/bootstrap/validation.d.ts.map +1 -0
  89. package/dist/operations/bootstrap/validation.js +20 -0
  90. package/dist/operations/migration/inventory-rederive.d.ts +81 -0
  91. package/dist/operations/migration/inventory-rederive.d.ts.map +1 -0
  92. package/dist/operations/migration/inventory-rederive.js +484 -0
  93. package/dist/operations/migration/kb-sources.d.ts +53 -0
  94. package/dist/operations/migration/kb-sources.d.ts.map +1 -0
  95. package/dist/operations/migration/kb-sources.js +233 -0
  96. package/dist/operations/migration/origin-backfill.d.ts +39 -0
  97. package/dist/operations/migration/origin-backfill.d.ts.map +1 -0
  98. package/dist/operations/migration/origin-backfill.js +164 -0
  99. package/dist/operations/migration/polarity-values.d.ts +10 -0
  100. package/dist/operations/migration/polarity-values.d.ts.map +1 -0
  101. package/dist/operations/migration/polarity-values.js +60 -0
  102. package/dist/operations/migration/schema6.d.ts +59 -0
  103. package/dist/operations/migration/schema6.d.ts.map +1 -0
  104. package/dist/operations/migration/schema6.js +379 -0
  105. package/dist/operations/migration/source-paths.d.ts +131 -0
  106. package/dist/operations/migration/source-paths.d.ts.map +1 -0
  107. package/dist/operations/migration/source-paths.js +308 -0
  108. package/dist/operations/migration/superseded-closure.d.ts +54 -0
  109. package/dist/operations/migration/superseded-closure.d.ts.map +1 -0
  110. package/dist/operations/migration/superseded-closure.js +187 -0
  111. package/dist/operations/modeling/logic-modeling.d.ts.map +1 -1
  112. package/dist/operations/modeling/logic-modeling.js +3 -5
  113. package/dist/operations/modeling/model-requirement.d.ts.map +1 -1
  114. package/dist/operations/modeling/model-requirement.js +225 -67
  115. package/dist/operations/mutation/contradictions.d.ts +16 -0
  116. package/dist/operations/mutation/contradictions.d.ts.map +1 -1
  117. package/dist/operations/mutation/contradictions.js +32 -0
  118. package/dist/operations/mutation/delete.d.ts.map +1 -1
  119. package/dist/operations/mutation/delete.js +15 -7
  120. package/dist/operations/mutation/origin.d.ts +21 -0
  121. package/dist/operations/mutation/origin.d.ts.map +1 -0
  122. package/dist/operations/mutation/origin.js +78 -0
  123. package/dist/operations/mutation/plan-apply-journal.d.ts +182 -0
  124. package/dist/operations/mutation/plan-apply-journal.d.ts.map +1 -0
  125. package/dist/operations/mutation/plan-apply-journal.js +613 -0
  126. package/dist/operations/mutation/predicate-vocabulary-guard.d.ts +3 -1
  127. package/dist/operations/mutation/predicate-vocabulary-guard.d.ts.map +1 -1
  128. package/dist/operations/mutation/predicate-vocabulary-guard.js +13 -2
  129. package/dist/operations/mutation/relationships.d.ts +5 -5
  130. package/dist/operations/mutation/relationships.d.ts.map +1 -1
  131. package/dist/operations/mutation/relationships.js +31 -11
  132. package/dist/operations/mutation/serialization.d.ts.map +1 -1
  133. package/dist/operations/mutation/serialization.js +3 -1
  134. package/dist/operations/mutation/source-authoring.d.ts +6 -0
  135. package/dist/operations/mutation/source-authoring.d.ts.map +1 -1
  136. package/dist/operations/mutation/source-authoring.js +7 -1
  137. package/dist/operations/mutation/symbol-refresh.d.ts.map +1 -1
  138. package/dist/operations/mutation/symbol-refresh.js +4 -1
  139. package/dist/operations/mutation/types.d.ts +14 -0
  140. package/dist/operations/mutation/types.d.ts.map +1 -1
  141. package/dist/operations/mutation/upsert.d.ts +30 -3
  142. package/dist/operations/mutation/upsert.d.ts.map +1 -1
  143. package/dist/operations/mutation/upsert.js +105 -35
  144. package/dist/operations/mutation/validate-upsert.d.ts +6 -0
  145. package/dist/operations/mutation/validate-upsert.d.ts.map +1 -1
  146. package/dist/operations/mutation/validate-upsert.js +34 -30
  147. package/dist/operations/planning/apply-plan.d.ts.map +1 -1
  148. package/dist/operations/planning/apply-plan.js +751 -144
  149. package/dist/operations/planning/compile-intent.d.ts +34 -1
  150. package/dist/operations/planning/compile-intent.d.ts.map +1 -1
  151. package/dist/operations/planning/compile-intent.js +314 -98
  152. package/dist/operations/proof/code-scope.d.ts +28 -0
  153. package/dist/operations/proof/code-scope.d.ts.map +1 -1
  154. package/dist/operations/proof/code-scope.js +72 -0
  155. package/dist/operations/proof/compact-receipts.d.ts +49 -0
  156. package/dist/operations/proof/compact-receipts.d.ts.map +1 -0
  157. package/dist/operations/proof/compact-receipts.js +160 -0
  158. package/dist/operations/proof/ingest-proof.d.ts +2 -0
  159. package/dist/operations/proof/ingest-proof.d.ts.map +1 -1
  160. package/dist/operations/proof/ingest-proof.js +44 -23
  161. package/dist/operations/proof/prune-receipts.d.ts.map +1 -1
  162. package/dist/operations/proof/prune-receipts.js +5 -9
  163. package/dist/operations/proof/receipt-compaction.d.ts +48 -0
  164. package/dist/operations/proof/receipt-compaction.d.ts.map +1 -0
  165. package/dist/operations/proof/receipt-compaction.js +121 -0
  166. package/dist/operations/semantic-advisor/analysis-receipt.d.ts.map +1 -1
  167. package/dist/operations/semantic-advisor/analysis-receipt.js +12 -1
  168. package/dist/operations/semantic-advisor/analyze-prose.d.ts +2 -1
  169. package/dist/operations/semantic-advisor/analyze-prose.d.ts.map +1 -1
  170. package/dist/operations/semantic-advisor/analyze-prose.js +51 -5
  171. package/dist/operations/semantic-advisor/clauses.d.ts +1 -0
  172. package/dist/operations/semantic-advisor/clauses.d.ts.map +1 -1
  173. package/dist/operations/semantic-advisor/clauses.js +11 -1
  174. package/dist/operations/semantic-advisor/conditional-rules.d.ts +33 -0
  175. package/dist/operations/semantic-advisor/conditional-rules.d.ts.map +1 -0
  176. package/dist/operations/semantic-advisor/conditional-rules.js +262 -0
  177. package/dist/operations/semantic-advisor/ingestion-boundary.d.ts +3 -1
  178. package/dist/operations/semantic-advisor/ingestion-boundary.d.ts.map +1 -1
  179. package/dist/operations/semantic-advisor/ingestion-boundary.js +14 -6
  180. package/dist/operations/semantic-advisor/plugin-orchestration.js +1 -1
  181. package/dist/prolog/codec.d.ts.map +1 -1
  182. package/dist/prolog/codec.js +2 -1
  183. package/dist/prolog.d.ts +9 -0
  184. package/dist/prolog.d.ts.map +1 -1
  185. package/dist/prolog.js +56 -10
  186. package/dist/proof/command-test-report.d.ts +74 -0
  187. package/dist/proof/command-test-report.d.ts.map +1 -0
  188. package/dist/proof/command-test-report.js +206 -0
  189. package/dist/public/branch-resolver.d.ts +1 -0
  190. package/dist/public/branch-resolver.d.ts.map +1 -1
  191. package/dist/public/branch-resolver.js +1 -0
  192. package/dist/public/diagnostic-usage.d.ts +14 -0
  193. package/dist/public/diagnostic-usage.d.ts.map +1 -1
  194. package/dist/public/diagnostic-usage.js +55 -1
  195. package/dist/public/entity-origin.d.ts +69 -0
  196. package/dist/public/entity-origin.d.ts.map +1 -0
  197. package/dist/public/entity-origin.js +142 -0
  198. package/dist/public/impact/full-kb-quality.d.ts.map +1 -1
  199. package/dist/public/impact/full-kb-quality.js +1 -0
  200. package/dist/public/impact/requirement-quality.js +1 -1
  201. package/dist/public/operations/catalog.d.ts +203 -20
  202. package/dist/public/operations/catalog.d.ts.map +1 -1
  203. package/dist/public/operations/catalog.js +3 -0
  204. package/dist/public/operations/check-executor.d.ts.map +1 -1
  205. package/dist/public/operations/check-executor.js +8 -0
  206. package/dist/public/operations/contracts.d.ts +0 -5
  207. package/dist/public/operations/contracts.d.ts.map +1 -1
  208. package/dist/public/operations/contracts.js +63 -14
  209. package/dist/public/operations/discovery-entities.d.ts +15 -0
  210. package/dist/public/operations/discovery-entities.d.ts.map +1 -1
  211. package/dist/public/operations/discovery-entities.js +59 -0
  212. package/dist/public/operations/discovery-executors.d.ts +6 -1
  213. package/dist/public/operations/discovery-executors.d.ts.map +1 -1
  214. package/dist/public/operations/discovery-executors.js +65 -6
  215. package/dist/public/operations/index.d.ts +1 -0
  216. package/dist/public/operations/index.d.ts.map +1 -1
  217. package/dist/public/operations/index.js +1 -0
  218. package/dist/public/operations/migration-plan.d.ts +5 -0
  219. package/dist/public/operations/migration-plan.d.ts.map +1 -1
  220. package/dist/public/operations/migration-plan.js +26 -1
  221. package/dist/public/operations/node-ports.d.ts.map +1 -1
  222. package/dist/public/operations/node-ports.js +24 -3
  223. package/dist/public/operations/origin-review.d.ts +51 -0
  224. package/dist/public/operations/origin-review.d.ts.map +1 -0
  225. package/dist/public/operations/origin-review.js +307 -0
  226. package/dist/public/operations/predicate-schema-conformance.js +1 -1
  227. package/dist/public/operations/repair-plan.d.ts.map +1 -1
  228. package/dist/public/operations/repair-plan.js +4 -0
  229. package/dist/public/operations/result-envelope.d.ts.map +1 -1
  230. package/dist/public/operations/result-envelope.js +17 -5
  231. package/dist/public/operations/runtime-types.d.ts +9 -0
  232. package/dist/public/operations/runtime-types.d.ts.map +1 -1
  233. package/dist/public/operations/schema6-check-actions.d.ts +127 -0
  234. package/dist/public/operations/schema6-check-actions.d.ts.map +1 -0
  235. package/dist/public/operations/schema6-check-actions.js +575 -0
  236. package/dist/public/operations/source-path-dangling.d.ts +17 -0
  237. package/dist/public/operations/source-path-dangling.d.ts.map +1 -0
  238. package/dist/public/operations/source-path-dangling.js +66 -0
  239. package/dist/public/operations/specs/bootstrap.d.ts +73 -1
  240. package/dist/public/operations/specs/bootstrap.d.ts.map +1 -1
  241. package/dist/public/operations/specs/bootstrap.js +66 -1
  242. package/dist/public/operations/specs/check-rules.generated.d.ts +1 -1
  243. package/dist/public/operations/specs/check-rules.generated.d.ts.map +1 -1
  244. package/dist/public/operations/specs/check-rules.generated.js +15 -1
  245. package/dist/public/operations/specs/check.d.ts +2 -2
  246. package/dist/public/operations/specs/check.js +1 -1
  247. package/dist/public/operations/specs/composite.d.ts +351 -0
  248. package/dist/public/operations/specs/composite.d.ts.map +1 -0
  249. package/dist/public/operations/specs/composite.js +96 -0
  250. package/dist/public/operations/specs/discovery.d.ts +8 -3
  251. package/dist/public/operations/specs/discovery.d.ts.map +1 -1
  252. package/dist/public/operations/specs/discovery.js +8 -3
  253. package/dist/public/operations/specs/modeling.d.ts +2 -2
  254. package/dist/public/operations/specs/modeling.js +2 -2
  255. package/dist/public/operations/specs/mutation-schemas.d.ts +73 -8
  256. package/dist/public/operations/specs/mutation-schemas.d.ts.map +1 -1
  257. package/dist/public/operations/specs/mutation-schemas.js +43 -7
  258. package/dist/public/operations/specs/mutation.d.ts +1 -1
  259. package/dist/public/operations/specs/mutation.js +1 -1
  260. package/dist/public/operations/specs/planning.d.ts +2 -2
  261. package/dist/public/operations/specs/planning.js +4 -4
  262. package/dist/public/operations/specs/reporting.d.ts.map +1 -1
  263. package/dist/public/operations/specs/reporting.js +13 -26
  264. package/dist/public/operations/specs/upsert.d.ts +79 -9
  265. package/dist/public/operations/specs/upsert.d.ts.map +1 -1
  266. package/dist/public/operations/specs/upsert.js +6 -1
  267. package/dist/public/operations/symbol-repair-plan.d.ts.map +1 -1
  268. package/dist/public/operations/symbol-repair-plan.js +3 -1
  269. package/dist/public/operations/types.d.ts +1 -1
  270. package/dist/public/operations/types.d.ts.map +1 -1
  271. package/dist/public/proof-receipt.d.ts +1 -0
  272. package/dist/public/proof-receipt.d.ts.map +1 -1
  273. package/dist/public/schemas/entity.d.ts.map +1 -1
  274. package/dist/public/schemas/entity.js +52 -0
  275. package/dist/public/schemas/relationship.d.ts.map +1 -1
  276. package/dist/public/schemas/relationship.js +2 -0
  277. package/dist/public/skills/kibi-bootstrap/SKILL.md +52 -11
  278. package/dist/public/skills/kibi-bootstrap/resources/bootstrap.md +12 -1
  279. package/dist/public/skills/kibi-usage/SKILL.md +82 -18
  280. package/dist/public/skills/kibi-usage/resources/fact-lanes.md +5 -5
  281. package/dist/public/skills/kibi-usage/resources/kb-improvement.md +1 -1
  282. package/dist/public/skills/kibi-usage/resources/logic-ir.md +2 -2
  283. package/dist/public/skills/kibi-usage/resources/operation-access.md +29 -1
  284. package/dist/public/skills/kibi-usage/resources/ui-requirements.md +4 -4
  285. package/dist/public/skills/kibi-usage/resources/workflows.md +42 -25
  286. package/dist/public/telemetry-acceptance.d.ts +64 -0
  287. package/dist/public/telemetry-acceptance.d.ts.map +1 -1
  288. package/dist/public/telemetry-acceptance.js +143 -7
  289. package/dist/public/telemetry-remediation.d.ts.map +1 -1
  290. package/dist/public/telemetry-remediation.js +26 -10
  291. package/dist/relationships/shards.d.ts +13 -0
  292. package/dist/relationships/shards.d.ts.map +1 -1
  293. package/dist/relationships/shards.js +54 -28
  294. package/dist/runtime/cli-runtime.d.ts.map +1 -1
  295. package/dist/runtime/cli-runtime.js +44 -3
  296. package/dist/runtime/detached-snapshot.d.ts +38 -0
  297. package/dist/runtime/detached-snapshot.d.ts.map +1 -0
  298. package/dist/runtime/detached-snapshot.js +92 -0
  299. package/dist/schemas/entity.schema.json +122 -0
  300. package/dist/search-answer.d.ts +157 -0
  301. package/dist/search-answer.d.ts.map +1 -0
  302. package/dist/search-answer.js +846 -0
  303. package/dist/traceability/impact-knowledge.d.ts.map +1 -1
  304. package/dist/traceability/impact-knowledge.js +7 -0
  305. package/dist/traceability/symbol-extract.js +3 -3
  306. package/dist/traceability/temp-kb.d.ts.map +1 -1
  307. package/dist/traceability/temp-kb.js +12 -0
  308. package/dist/types/entities.d.ts +13 -0
  309. package/dist/types/entities.d.ts.map +1 -1
  310. package/dist/types/relationships.d.ts +1 -1
  311. package/dist/types/relationships.d.ts.map +1 -1
  312. package/dist/utils/branch-resolver.d.ts +37 -1
  313. package/dist/utils/branch-resolver.d.ts.map +1 -1
  314. package/dist/utils/branch-resolver.js +130 -3
  315. package/dist/utils/repo-relative-path.d.ts +18 -0
  316. package/dist/utils/repo-relative-path.d.ts.map +1 -0
  317. package/dist/utils/repo-relative-path.js +58 -0
  318. package/dist/utils/rule-registry.generated.d.ts +75 -3
  319. package/dist/utils/rule-registry.generated.d.ts.map +1 -1
  320. package/dist/utils/rule-registry.generated.js +89 -3
  321. package/dist/utils/schema-version.d.ts +1 -1
  322. package/dist/utils/schema-version.d.ts.map +1 -1
  323. package/dist/utils/schema-version.js +4 -3
  324. package/dist/utils/strict-modeling.d.ts +1 -1
  325. package/dist/utils/strict-modeling.d.ts.map +1 -1
  326. package/dist/utils/strict-modeling.js +23 -3
  327. package/package.json +3 -3
  328. package/schema/entities.pl +22 -0
  329. package/schema/relationships.pl +14 -0
  330. package/schema/validation.pl +45 -1
  331. package/src/public/branch-resolver.ts +1 -0
  332. package/src/public/diagnostic-usage.ts +59 -1
  333. package/src/public/entity-origin.ts +175 -0
  334. package/src/public/impact/full-kb-quality.ts +1 -0
  335. package/src/public/impact/requirement-quality.ts +1 -1
  336. package/src/public/operations/catalog.ts +3 -0
  337. package/src/public/operations/check-executor.ts +15 -0
  338. package/src/public/operations/contracts.ts +75 -15
  339. package/src/public/operations/discovery-entities.ts +74 -0
  340. package/src/public/operations/discovery-executors.ts +88 -10
  341. package/src/public/operations/index.ts +1 -0
  342. package/src/public/operations/migration-plan.ts +30 -1
  343. package/src/public/operations/node-ports.ts +24 -3
  344. package/src/public/operations/origin-review.ts +375 -0
  345. package/src/public/operations/predicate-schema-conformance.ts +1 -1
  346. package/src/public/operations/repair-plan.ts +4 -0
  347. package/src/public/operations/result-envelope.ts +18 -6
  348. package/src/public/operations/runtime-types.ts +9 -0
  349. package/src/public/operations/schema6-check-actions.ts +699 -0
  350. package/src/public/operations/source-path-dangling.ts +81 -0
  351. package/src/public/operations/specs/bootstrap.ts +78 -4
  352. package/src/public/operations/specs/check-rules.generated.ts +15 -1
  353. package/src/public/operations/specs/check.ts +1 -1
  354. package/src/public/operations/specs/composite.ts +141 -0
  355. package/src/public/operations/specs/discovery.ts +9 -3
  356. package/src/public/operations/specs/modeling.ts +2 -2
  357. package/src/public/operations/specs/mutation-schemas.ts +49 -7
  358. package/src/public/operations/specs/mutation.ts +1 -1
  359. package/src/public/operations/specs/planning.ts +4 -4
  360. package/src/public/operations/specs/reporting.ts +13 -38
  361. package/src/public/operations/specs/upsert.ts +7 -1
  362. package/src/public/operations/symbol-repair-plan.ts +3 -1
  363. package/src/public/operations/types.ts +2 -0
  364. package/src/public/proof-receipt.ts +1 -0
  365. package/src/public/schemas/entity.ts +57 -0
  366. package/src/public/schemas/relationship.ts +2 -0
  367. package/src/public/skills/kibi-bootstrap/SKILL.md +52 -11
  368. package/src/public/skills/kibi-bootstrap/resources/bootstrap.md +12 -1
  369. package/src/public/skills/kibi-usage/SKILL.md +82 -18
  370. package/src/public/skills/kibi-usage/resources/fact-lanes.md +5 -5
  371. package/src/public/skills/kibi-usage/resources/kb-improvement.md +1 -1
  372. package/src/public/skills/kibi-usage/resources/logic-ir.md +2 -2
  373. package/src/public/skills/kibi-usage/resources/operation-access.md +29 -1
  374. package/src/public/skills/kibi-usage/resources/ui-requirements.md +4 -4
  375. package/src/public/skills/kibi-usage/resources/workflows.md +42 -25
  376. package/src/public/telemetry-acceptance-types.d.ts +4 -1
  377. package/src/public/telemetry-acceptance.ts +210 -7
  378. package/src/public/telemetry-remediation.ts +39 -10
  379. package/src/schemas/entity.schema.json +122 -0
  380. package/src/schemas/relationship.schema.json +2 -0
@@ -4,7 +4,7 @@ export { executePlanBootstrap } from "../../../operations/bootstrap/generate.js"
4
4
  export declare const planBootstrapSpec: {
5
5
  readonly name: "kb_plan_bootstrap";
6
6
  readonly cliName: "plan-bootstrap";
7
- readonly description: "Generate a deterministic, snapshot-bound kibi.bootstrap-plan.v1 for repository onboarding. Read-only analysis returns evidence, bounded context questions, exact dependency-ordered actions, a canonical plan hash, and no mutation side effects.";
7
+ readonly description: "Generate a deterministic, snapshot-bound kibi.bootstrap-plan.v1 for repository onboarding. Read-only analysis of the repository plus any declared knowledge sources and cited intent claims returns evidence, bounded context questions, exact dependency-ordered actions, a canonical plan hash, and no mutation side effects.";
8
8
  readonly businessInputSchema: {
9
9
  readonly type: "object";
10
10
  readonly properties: {
@@ -71,6 +71,78 @@ export declare const planBootstrapSpec: {
71
71
  };
72
72
  readonly description: "Optional verification commands, documents, or checkpoints to reference in the output.";
73
73
  };
74
+ readonly knowledgeSources: {
75
+ readonly type: "array";
76
+ readonly maxItems: 50;
77
+ readonly description: "Knowledge sources outside the code that the human confirmed during the bootstrap interview (issue trackers, wikis, specs, decision logs). Kibi never contacts them; the agent reads them through its own connectors and cites them from intentClaims. Bound into the plan hash.";
78
+ readonly items: {
79
+ readonly type: "object";
80
+ readonly required: readonly ["id", "kind", "title", "locator", "authority"];
81
+ readonly additionalProperties: false;
82
+ readonly properties: {
83
+ readonly id: {
84
+ readonly type: "string";
85
+ readonly pattern: "^[a-z0-9][a-z0-9-]*$";
86
+ readonly description: "Stable kebab-case handle that intentClaims cite, for example jira-payments.";
87
+ };
88
+ readonly kind: {
89
+ readonly type: "string";
90
+ readonly enum: readonly ["issue_tracker", "wiki", "specification", "design", "decision_log", "support", "chat", "repository_docs", "other"];
91
+ };
92
+ readonly title: {
93
+ readonly type: "string";
94
+ readonly minLength: 1;
95
+ };
96
+ readonly locator: {
97
+ readonly type: "string";
98
+ readonly minLength: 1;
99
+ readonly description: "Where the source lives: a URL, project key, space name, or repo-relative path.";
100
+ };
101
+ readonly authority: {
102
+ readonly type: "string";
103
+ readonly enum: readonly ["authoritative", "supporting", "stale"];
104
+ readonly description: "The human's call: authoritative claims become higher-confidence candidates, supporting claims lower ones, and stale sources are cited but never produce candidates.";
105
+ };
106
+ readonly connector: {
107
+ readonly type: "string";
108
+ readonly description: "Optional name of the MCP server or tool the agent used to read the source.";
109
+ };
110
+ readonly notes: {
111
+ readonly type: "string";
112
+ };
113
+ };
114
+ };
115
+ };
116
+ readonly intentClaims: {
117
+ readonly type: "array";
118
+ readonly maxItems: 200;
119
+ readonly description: "Statements of product intent the agent harvested from knowledgeSources, each citing its source. Normative claims the strict modeler can ground become cited req candidates; the rest become explicit authoring follow-ups. Bound into the plan hash.";
120
+ readonly items: {
121
+ readonly type: "object";
122
+ readonly required: readonly ["statement", "sourceId", "reference"];
123
+ readonly additionalProperties: false;
124
+ readonly properties: {
125
+ readonly statement: {
126
+ readonly type: "string";
127
+ readonly minLength: 1;
128
+ readonly description: "One normative statement in the source's meaning, for example 'Refunds must not exceed the original charge.'";
129
+ };
130
+ readonly sourceId: {
131
+ readonly type: "string";
132
+ readonly description: "The id of a declared knowledge source.";
133
+ };
134
+ readonly reference: {
135
+ readonly type: "string";
136
+ readonly minLength: 1;
137
+ readonly description: "Exact citation inside the source: a ticket key, page URL, or section anchor.";
138
+ };
139
+ readonly excerpt: {
140
+ readonly type: "string";
141
+ readonly description: "Optional short quote supporting the claim.";
142
+ };
143
+ };
144
+ };
145
+ };
74
146
  };
75
147
  };
76
148
  };
@@ -1 +1 @@
1
- {"version":3,"file":"bootstrap.d.ts","sourceRoot":"","sources":["../../../../src/public/operations/specs/bootstrap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAOjF,YAAY,EACV,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,GACpB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAGjF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmF7B,CAAC"}
1
+ {"version":3,"file":"bootstrap.d.ts","sourceRoot":"","sources":["../../../../src/public/operations/specs/bootstrap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AASjF,YAAY,EACV,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,GACpB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AAGjF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2J7B,CAAC"}
@@ -1,10 +1,11 @@
1
1
  import { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
2
+ import { KNOWLEDGE_SOURCE_AUTHORITIES, KNOWLEDGE_SOURCE_KINDS, } from "../../../operations/bootstrap/types.js";
2
3
  export { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
3
4
  // implements REQ-KIBI-BOOTSTRAP-PLAN
4
5
  export const planBootstrapSpec = {
5
6
  name: "kb_plan_bootstrap",
6
7
  cliName: "plan-bootstrap",
7
- description: "Generate a deterministic, snapshot-bound kibi.bootstrap-plan.v1 for repository onboarding. Read-only analysis returns evidence, bounded context questions, exact dependency-ordered actions, a canonical plan hash, and no mutation side effects.",
8
+ description: "Generate a deterministic, snapshot-bound kibi.bootstrap-plan.v1 for repository onboarding. Read-only analysis of the repository plus any declared knowledge sources and cited intent claims returns evidence, bounded context questions, exact dependency-ordered actions, a canonical plan hash, and no mutation side effects.",
8
9
  businessInputSchema: {
9
10
  type: "object",
10
11
  properties: {
@@ -63,6 +64,70 @@ export const planBootstrapSpec = {
63
64
  items: { type: "string" },
64
65
  description: "Optional verification commands, documents, or checkpoints to reference in the output.",
65
66
  },
67
+ knowledgeSources: {
68
+ type: "array",
69
+ maxItems: 50,
70
+ description: "Knowledge sources outside the code that the human confirmed during the bootstrap interview (issue trackers, wikis, specs, decision logs). Kibi never contacts them; the agent reads them through its own connectors and cites them from intentClaims. Bound into the plan hash.",
71
+ items: {
72
+ type: "object",
73
+ required: ["id", "kind", "title", "locator", "authority"],
74
+ additionalProperties: false,
75
+ properties: {
76
+ id: {
77
+ type: "string",
78
+ pattern: "^[a-z0-9][a-z0-9-]*$",
79
+ description: "Stable kebab-case handle that intentClaims cite, for example jira-payments.",
80
+ },
81
+ kind: { type: "string", enum: [...KNOWLEDGE_SOURCE_KINDS] },
82
+ title: { type: "string", minLength: 1 },
83
+ locator: {
84
+ type: "string",
85
+ minLength: 1,
86
+ description: "Where the source lives: a URL, project key, space name, or repo-relative path.",
87
+ },
88
+ authority: {
89
+ type: "string",
90
+ enum: [...KNOWLEDGE_SOURCE_AUTHORITIES],
91
+ description: "The human's call: authoritative claims become higher-confidence candidates, supporting claims lower ones, and stale sources are cited but never produce candidates.",
92
+ },
93
+ connector: {
94
+ type: "string",
95
+ description: "Optional name of the MCP server or tool the agent used to read the source.",
96
+ },
97
+ notes: { type: "string" },
98
+ },
99
+ },
100
+ },
101
+ intentClaims: {
102
+ type: "array",
103
+ maxItems: 200,
104
+ description: "Statements of product intent the agent harvested from knowledgeSources, each citing its source. Normative claims the strict modeler can ground become cited req candidates; the rest become explicit authoring follow-ups. Bound into the plan hash.",
105
+ items: {
106
+ type: "object",
107
+ required: ["statement", "sourceId", "reference"],
108
+ additionalProperties: false,
109
+ properties: {
110
+ statement: {
111
+ type: "string",
112
+ minLength: 1,
113
+ description: "One normative statement in the source's meaning, for example 'Refunds must not exceed the original charge.'",
114
+ },
115
+ sourceId: {
116
+ type: "string",
117
+ description: "The id of a declared knowledge source.",
118
+ },
119
+ reference: {
120
+ type: "string",
121
+ minLength: 1,
122
+ description: "Exact citation inside the source: a ticket key, page URL, or section anchor.",
123
+ },
124
+ excerpt: {
125
+ type: "string",
126
+ description: "Optional short quote supporting the claim.",
127
+ },
128
+ },
129
+ },
130
+ },
66
131
  },
67
132
  },
68
133
  },
@@ -1,5 +1,5 @@
1
1
  /** Every selectable kb_check rule name, registry order. */
2
2
  export declare const SELECTABLE_RULE_NAMES: readonly string[];
3
3
  /** Comma-separated "Allowed:" fragment for the kb_check rules description. */
4
- export declare const SELECTABLE_RULES_ALLOWED = "must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, no-cycles, required-fields, deprecated-adr-no-successor, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, predicate-schema-conformance";
4
+ export declare const SELECTABLE_RULES_ALLOWED = "must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, source-path-dangling, no-cycles, required-fields, deprecated-adr-no-successor, superseded-requirement-open, scenario-feasibility, scenario-feasibility-unknown, exception-claim-keys, numeric-string-value, rule-key-arguments-missing, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, exception-unapproved, exception-approval-self-attested, agent-requirement-unapproved, requirement-rationale-missing, symbol-owner-superseded, adr-unlinked, adr-proposed, predicate-schema-conformance";
5
5
  //# sourceMappingURL=check-rules.generated.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"check-rules.generated.d.ts","sourceRoot":"","sources":["../../../../src/public/operations/specs/check-rules.generated.ts"],"names":[],"mappings":"AAUA,2DAA2D;AAC3D,eAAO,MAAM,qBAAqB,EAAE,SAAS,MAAM,EA4BlD,CAAC;AAGF,8EAA8E;AAC9E,eAAO,MAAM,wBAAwB,ijBAC2gB,CAAC"}
1
+ {"version":3,"file":"check-rules.generated.d.ts","sourceRoot":"","sources":["../../../../src/public/operations/specs/check-rules.generated.ts"],"names":[],"mappings":"AAUA,2DAA2D;AAC3D,eAAO,MAAM,qBAAqB,EAAE,SAAS,MAAM,EA0ClD,CAAC;AAGF,8EAA8E;AAC9E,eAAO,MAAM,wBAAwB,04BACo2B,CAAC"}
@@ -14,9 +14,16 @@ export const SELECTABLE_RULE_NAMES = [
14
14
  "symbol-traceability",
15
15
  "no-dangling-refs",
16
16
  "source-relationship-parity",
17
+ "source-path-dangling",
17
18
  "no-cycles",
18
19
  "required-fields",
19
20
  "deprecated-adr-no-successor",
21
+ "superseded-requirement-open",
22
+ "scenario-feasibility",
23
+ "scenario-feasibility-unknown",
24
+ "exception-claim-keys",
25
+ "numeric-string-value",
26
+ "rule-key-arguments-missing",
20
27
  "domain-contradictions",
21
28
  "logic-coverage",
22
29
  "rule-safety",
@@ -35,8 +42,15 @@ export const SELECTABLE_RULE_NAMES = [
35
42
  "subject-key-identity",
36
43
  "subject-key-shape",
37
44
  "ontology-quality",
45
+ "exception-unapproved",
46
+ "exception-approval-self-attested",
47
+ "agent-requirement-unapproved",
48
+ "requirement-rationale-missing",
49
+ "symbol-owner-superseded",
50
+ "adr-unlinked",
51
+ "adr-proposed",
38
52
  "predicate-schema-conformance",
39
53
  ];
40
54
  // implements REQ-006
41
55
  /** Comma-separated "Allowed:" fragment for the kb_check rules description. */
42
- export const SELECTABLE_RULES_ALLOWED = "must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, no-cycles, required-fields, deprecated-adr-no-successor, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, predicate-schema-conformance";
56
+ export const SELECTABLE_RULES_ALLOWED = "must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, source-path-dangling, no-cycles, required-fields, deprecated-adr-no-successor, superseded-requirement-open, scenario-feasibility, scenario-feasibility-unknown, exception-claim-keys, numeric-string-value, rule-key-arguments-missing, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, exception-unapproved, exception-approval-self-attested, agent-requirement-unapproved, requirement-rationale-missing, symbol-owner-superseded, adr-unlinked, adr-proposed, predicate-schema-conformance";
@@ -12,7 +12,7 @@ export declare const checkSpec: {
12
12
  readonly type: "string";
13
13
  readonly enum: readonly string[];
14
14
  };
15
- readonly description: "Optional rule subset. Allowed: must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, no-cycles, required-fields, deprecated-adr-no-successor, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, predicate-schema-conformance. If omitted, server runs canonical and advisory rules plus the full-KB qualityDiagnostics audit scan, including usage telemetry acceptance when evidence exists; migration rules run only when explicitly selected. Advisory and migration findings are non-blocking qualityDiagnostics. If supplied, server preserves scoped validation and skips the full-KB advisory scan.";
15
+ readonly description: "Optional rule subset. Allowed: must-priority-coverage, symbol-coverage, symbol-traceability, no-dangling-refs, source-relationship-parity, source-path-dangling, no-cycles, required-fields, deprecated-adr-no-successor, superseded-requirement-open, scenario-feasibility, scenario-feasibility-unknown, exception-claim-keys, numeric-string-value, rule-key-arguments-missing, domain-contradictions, logic-coverage, rule-safety, rule-verifiability, query-plan-safety, req-status-vocabulary, strict-fact-shape, strict-req-fact-pairing, predicate-verifiability, strict-readiness, semantic-completeness, proof-contract-symbols, entity-id-style, domain-redundancy, domain-implication, subject-key-identity, subject-key-shape, ontology-quality, exception-unapproved, exception-approval-self-attested, agent-requirement-unapproved, requirement-rationale-missing, symbol-owner-superseded, adr-unlinked, adr-proposed, predicate-schema-conformance. If omitted, server runs canonical and advisory rules plus the full-KB qualityDiagnostics audit scan, including usage telemetry acceptance when evidence exists; migration rules run only when explicitly selected. Advisory and migration findings are non-blocking qualityDiagnostics. If supplied, server preserves scoped validation and skips the full-KB advisory scan.";
16
16
  };
17
17
  readonly sourceFiles: {
18
18
  readonly type: "array";
@@ -45,7 +45,7 @@ export declare const checkSpec: {
45
45
  readonly async: {
46
46
  readonly type: "boolean";
47
47
  readonly default: false;
48
- readonly description: "When true, start the check as a background job and return a kibi.job.v1 receipt immediately instead of holding the request until the tool timeout. Poll kb_job_status with the returned jobId. Use for full checks on large KBs that exceed the configured tool timeout.";
48
+ readonly description: "When true, start the check as a background job and return a kibi.job.v1 receipt immediately instead of holding the request until the tool timeout. Poll kb_job_status with the returned jobId. Use for full checks on large KBs that exceed the configured tool timeout. The MCP server registers kb_job_status only when KIBI_MCP_OPTIONAL_TOOLS includes it; otherwise async runs the check synchronously.";
49
49
  };
50
50
  };
51
51
  };
@@ -44,7 +44,7 @@ export const checkSpec = {
44
44
  async: {
45
45
  type: "boolean",
46
46
  default: false,
47
- description: "When true, start the check as a background job and return a kibi.job.v1 receipt immediately instead of holding the request until the tool timeout. Poll kb_job_status with the returned jobId. Use for full checks on large KBs that exceed the configured tool timeout.",
47
+ description: "When true, start the check as a background job and return a kibi.job.v1 receipt immediately instead of holding the request until the tool timeout. Poll kb_job_status with the returned jobId. Use for full checks on large KBs that exceed the configured tool timeout. The MCP server registers kb_job_status only when KIBI_MCP_OPTIONAL_TOOLS includes it; otherwise async runs the check synchronously.",
48
48
  },
49
49
  },
50
50
  },
@@ -0,0 +1,351 @@
1
+ import type { OperationContext } from "../runtime-types.js";
2
+ import type { OperationResult } from "../types.js";
3
+ /**
4
+ * Composite operations keep the agent-facing tool list short. Each one
5
+ * dispatches to an existing operation by `action` or `mode` and returns that
6
+ * operation's payload unchanged plus the selector, so the narrower CLI routes
7
+ * and the composite tool always agree.
8
+ */
9
+ type Executor = (input: never, context: OperationContext) => Promise<unknown>;
10
+ export declare function dispatchComposite(selector: "action" | "mode", routes: Readonly<Record<string, {
11
+ readonly execute: Executor;
12
+ readonly businessInputSchema: Readonly<Record<string, unknown>>;
13
+ }>>, input: Readonly<Record<string, unknown>>, context: OperationContext): Promise<OperationResult<Record<string, unknown>>>;
14
+ export declare const SKILL_ROUTES: {
15
+ readonly list: {
16
+ readonly name: "kb_skills_list";
17
+ readonly cliName: "skills list";
18
+ readonly description: "List bundled Kibi agent skills available for progressive disclosure. Read-only; does not mutate the KB or require Prolog.";
19
+ readonly businessInputSchema: {
20
+ readonly type: "object";
21
+ readonly properties: {};
22
+ };
23
+ readonly requiresProlog: false;
24
+ readonly effects: readonly ["local-read"];
25
+ readonly execute: (_input: Readonly<Record<string, unknown>>, _context: OperationContext) => Promise<OperationResult<{
26
+ readonly skills: readonly import("../../skills.js").SkillManifest[];
27
+ }>>;
28
+ };
29
+ readonly load: {
30
+ readonly name: "kb_skills_load";
31
+ readonly cliName: "skills load";
32
+ readonly description: "Load a bundled Kibi agent skill by ID, returning its manifest metadata, Markdown body, declared resources, content hash, and source type. Read-only; does not execute scripts or require Prolog.";
33
+ readonly businessInputSchema: {
34
+ readonly type: "object";
35
+ readonly required: readonly ["id"];
36
+ readonly properties: {
37
+ readonly id: {
38
+ readonly type: "string";
39
+ readonly description: "Bundled skill ID to load. Example: 'kibi-usage'.";
40
+ };
41
+ };
42
+ };
43
+ readonly requiresProlog: false;
44
+ readonly effects: readonly ["local-read"];
45
+ readonly execute: (input: Readonly<Record<string, unknown>>, _context: OperationContext) => Promise<OperationResult<{
46
+ readonly metadata: import("../../skills.js").SkillManifest;
47
+ readonly body: string;
48
+ readonly resources: readonly string[];
49
+ readonly contentHash: string;
50
+ readonly sourceType: "bundled";
51
+ }>>;
52
+ };
53
+ readonly read: {
54
+ readonly name: "kb_skills_read";
55
+ readonly cliName: "skills read";
56
+ readonly description: "Read a declared resource from a bundled Kibi agent skill. Resource paths are restricted to the skill manifest; arbitrary file paths are not exposed. Read-only; does not require Prolog.";
57
+ readonly businessInputSchema: {
58
+ readonly type: "object";
59
+ readonly required: readonly ["id", "resource"];
60
+ readonly properties: {
61
+ readonly id: {
62
+ readonly type: "string";
63
+ readonly description: "Bundled skill ID. Example: 'kibi-usage'.";
64
+ };
65
+ readonly resource: {
66
+ readonly type: "string";
67
+ readonly description: "Manifest-declared resource path to read. Example: 'resources/workflows.md'.";
68
+ };
69
+ };
70
+ };
71
+ readonly requiresProlog: false;
72
+ readonly effects: readonly ["local-read"];
73
+ readonly execute: (input: Readonly<Record<string, unknown>>, _context: OperationContext) => Promise<OperationResult<{
74
+ readonly content: string;
75
+ }>>;
76
+ };
77
+ };
78
+ export declare const MODEL_ROUTES: {
79
+ readonly analyze: {
80
+ readonly name: "kb_semantic_advisor";
81
+ readonly cliName: "semantic-advisor";
82
+ readonly description: "Analyze requirement prose without mutating the KB and return semantic advisor receipts with modeling suggestions. Use before constructing kb_upsert payloads when prose may contain machine-checkable logic. Suggestions can include strict-property facts, predicate facts, ambiguity observations, or ontology-gap observations; all suggestions are advisory and reviewable.";
83
+ readonly businessInputSchema: {
84
+ readonly type: "object";
85
+ readonly required: readonly ["text"];
86
+ readonly properties: {
87
+ readonly text: {
88
+ readonly type: "string";
89
+ readonly description: "Requirement prose to inspect for machine-checkable modeling suggestions.";
90
+ };
91
+ readonly clauses: {
92
+ readonly type: "array";
93
+ readonly items: {
94
+ readonly type: "string";
95
+ };
96
+ readonly description: "Optional complete list of atomic requirement clauses supplied by the caller. Use this for compound prose so every normative clause receives a stable claim key and independent grounding review.";
97
+ };
98
+ readonly interpretations: {
99
+ readonly type: "array";
100
+ readonly maxItems: 3;
101
+ readonly description: "Optional host-LLM typed kibi.logic.v1 interpretations. Kibi validates and canonicalizes them; raw Prolog is not accepted.";
102
+ readonly items: {
103
+ readonly type: "object";
104
+ readonly required: readonly ["claim_key", "claim_text", "ir"];
105
+ readonly properties: {
106
+ readonly claim_key: {
107
+ readonly type: "string";
108
+ };
109
+ readonly claim_text: {
110
+ readonly type: "string";
111
+ };
112
+ readonly confidence: {
113
+ readonly type: "number";
114
+ readonly minimum: 0;
115
+ readonly maximum: 1;
116
+ };
117
+ readonly span: {
118
+ readonly type: "object";
119
+ };
120
+ readonly ir: {
121
+ readonly type: "object";
122
+ };
123
+ };
124
+ };
125
+ };
126
+ readonly type: {
127
+ readonly type: "string";
128
+ readonly enum: readonly ["req", "scenario", "test", "adr", "flag", "event", "symbol", "fact"];
129
+ readonly default: "req";
130
+ readonly description: "Entity type context for analysis. Requirement, domain-fact, and supporting prose all receive a proposition ledger; only requirements receive deterministic modeling suggestions.";
131
+ };
132
+ readonly id: {
133
+ readonly type: "string";
134
+ readonly description: "Optional requirement ID used for deterministic draft relationship guidance.";
135
+ };
136
+ readonly title: {
137
+ readonly type: "string";
138
+ readonly description: "Optional requirement title for draft apply plans.";
139
+ };
140
+ readonly source: {
141
+ readonly type: "string";
142
+ readonly description: "Optional provenance for draft suggestions.";
143
+ };
144
+ readonly status: {
145
+ readonly type: "string";
146
+ readonly description: "Optional requirement status for draft suggestions.";
147
+ };
148
+ };
149
+ };
150
+ readonly requiresProlog: false;
151
+ readonly effects: readonly ["local-read"];
152
+ readonly execute: (input: Readonly<Record<string, unknown>>, context: OperationContext) => Promise<import("../../../operations/semantic-advisor/types.js").SemanticAdvisorOperationResult>;
153
+ };
154
+ readonly requirement: {
155
+ readonly name: "kb_model_requirement";
156
+ readonly cliName: "model-requirement";
157
+ readonly description: "Convert a prose requirement plus optional extracted claim fields into a deterministic strict-lane write set. Read-only modeling returns a sequential applyPlan for later kb_upsert calls. High-confidence claims emit req+fact strict output; lower-confidence claims emit an observation review artifact. Includes migration warnings when legacy schemaVersion metadata is detected.";
158
+ readonly businessInputSchema: {
159
+ readonly type: "object";
160
+ readonly required: readonly ["text"];
161
+ readonly properties: {
162
+ readonly text: {
163
+ readonly type: "string";
164
+ readonly description: "Required prose requirement text to model. Example: 'Customer data must be retained for 7 years.'";
165
+ };
166
+ readonly source: {
167
+ readonly type: "string";
168
+ readonly description: "Optional primary source path or provenance root used for stable IDs and text refs. Example: '.kb/requirements/customer-retention.md'.";
169
+ };
170
+ readonly sourceFiles: {
171
+ readonly type: "array";
172
+ readonly items: {
173
+ readonly type: "string";
174
+ };
175
+ readonly description: "Optional related source files. The first value is used as the source fallback when source is omitted.";
176
+ };
177
+ readonly confidence: {
178
+ readonly type: "number";
179
+ readonly default: 0.8;
180
+ readonly minimum: 0;
181
+ readonly maximum: 1;
182
+ readonly description: "Confidence score for the extracted claim. >= 0.70 yields strict-lane output; lower confidence yields observation-only review output.";
183
+ };
184
+ readonly subjectKey: {
185
+ readonly type: "string";
186
+ readonly description: "Optional extracted semantic claim subjectKey. Example: 'Customer.Data'.";
187
+ };
188
+ readonly propertyKey: {
189
+ readonly type: "string";
190
+ readonly description: "Optional extracted semantic claim propertyKey. Example: 'Retention Years'.";
191
+ };
192
+ readonly operator: {
193
+ readonly type: "string";
194
+ readonly enum: readonly ["eq", "gt", "gte", "lt", "lte", "neq", "bool", "polarity"];
195
+ readonly description: "Optional extracted semantic claim operator. Use gt/lt for strict bounds ('greater than zero' is gt 0, not gte 0). Example: 'eq'.";
196
+ };
197
+ readonly value: {
198
+ readonly description: "Optional extracted semantic claim value. Accepts string, number, or boolean.";
199
+ };
200
+ readonly provenance: {
201
+ readonly type: "string";
202
+ readonly description: "Optional extracted text reference. Falls back to source when omitted. Example: '.kb/requirements/customer-retention.md#L1'.";
203
+ };
204
+ readonly existingLogicClaims: {
205
+ readonly type: "array";
206
+ readonly items: {
207
+ readonly type: "string";
208
+ readonly pattern: "^CLAIM-[A-F0-9]{16}$";
209
+ };
210
+ readonly uniqueItems: true;
211
+ readonly description: "Existing requirement logic_claims values. The returned requirement update merges the new atomic claim key into this manifest instead of replacing prior claims.";
212
+ };
213
+ readonly requirementId: {
214
+ readonly type: "string";
215
+ readonly description: "Optional existing requirement ID to receive the requires_rule relationship.";
216
+ };
217
+ readonly claimKey: {
218
+ readonly type: "string";
219
+ readonly description: "Optional advisor-issued claim key for the exact proposition represented by logic.";
220
+ };
221
+ readonly claimText: {
222
+ readonly type: "string";
223
+ readonly description: "Optional exact proposition text represented by logic; defaults to text.";
224
+ };
225
+ readonly logic: {
226
+ readonly type: "object";
227
+ readonly description: "Optional typed kibi.logic.v1 IR. Kibi validates and canonicalizes it into a rule fact; raw Prolog is rejected.";
228
+ };
229
+ };
230
+ };
231
+ readonly requiresProlog: true;
232
+ readonly effects: readonly ["kb-read"];
233
+ readonly execute: typeof import("../../../operations/modeling/model-requirement.js").executeModelRequirement;
234
+ };
235
+ readonly predicates: {
236
+ readonly name: "kb_suggest_predicates";
237
+ readonly cliName: "suggest-predicates";
238
+ readonly description: "Suggest ontology predicate schemas for prose requirements before agents write facts. Retrieval/ranking is followed by a semantic applicability gate and conservative binding review; complete-looking generic placeholders never trigger application. Read-only guidance returns additive candidate diagnostics, an applicable predicate-fact plan only for a semantically eligible candidate with reviewed bindings, or an explicit ontology-gap observation plus a deterministic review-only predicate schema draft when no schema fits.";
239
+ readonly businessInputSchema: {
240
+ readonly type: "object";
241
+ readonly required: readonly ["text"];
242
+ readonly properties: {
243
+ readonly text: {
244
+ readonly type: "string";
245
+ readonly description: "Required prose requirement or claim to classify into ontology predicates. Example: 'When users navigate away, draft edits must auto-save.'.";
246
+ };
247
+ readonly requirementId: {
248
+ readonly type: "string";
249
+ readonly description: "Optional existing requirement ID. When provided, the response includes a relationshipPlan describing the req -> fact requires_predicate link to attach after preserving existing requirement metadata.";
250
+ };
251
+ readonly source: {
252
+ readonly type: "string";
253
+ readonly description: "Optional provenance or text reference for generated predicate facts or ontology-gap observations.";
254
+ };
255
+ readonly subjectHint: {
256
+ readonly type: "string";
257
+ readonly description: "Optional canonical subject key to use as the first predicate argument. Example: 'editor.annotation'.";
258
+ };
259
+ readonly maxCandidates: {
260
+ readonly type: "integer";
261
+ readonly default: 5;
262
+ readonly minimum: 1;
263
+ readonly maximum: 20;
264
+ readonly description: "Maximum ranked predicate candidates to return. Default: 5.";
265
+ };
266
+ readonly minScore: {
267
+ readonly type: "number";
268
+ readonly default: 0.35;
269
+ readonly minimum: 0;
270
+ readonly maximum: 1;
271
+ readonly description: "Minimum candidate score. Higher values make ontology-gap fallback more likely. Default: 0.35.";
272
+ };
273
+ readonly includeExistingSchemas: {
274
+ readonly type: "boolean";
275
+ readonly default: true;
276
+ readonly description: "Whether to include existing KB fact_kind=predicate_schema facts alongside Kibi's built-in predicate catalog. Default: true.";
277
+ };
278
+ readonly schemaId: {
279
+ readonly type: "string";
280
+ readonly minLength: 1;
281
+ readonly description: "Optional exact reviewed predicate schema ID. When supplied, Kibi selects that schema instead of lexical rank order and fails closed if it is unavailable.";
282
+ };
283
+ readonly argumentBindings: {
284
+ readonly type: "object";
285
+ readonly additionalProperties: {
286
+ readonly type: "string";
287
+ readonly minLength: 1;
288
+ };
289
+ readonly description: "Optional exact predicate argument values keyed by a candidate schema's argument_names. Required before applying a candidate whose binding_status is incomplete; Kibi never substitutes guessed values for unbound arguments.";
290
+ };
291
+ readonly polarityHint: {
292
+ readonly type: "string";
293
+ readonly enum: readonly ["assert", "deny"];
294
+ readonly description: "Optional reviewed polarity override for claims whose surface negation does not express predicate denial. Use only after reviewing the selected schema and full claim scope.";
295
+ };
296
+ readonly existingLogicClaims: {
297
+ readonly type: "array";
298
+ readonly items: {
299
+ readonly type: "string";
300
+ readonly pattern: "^CLAIM-[A-F0-9]{16}$";
301
+ };
302
+ readonly uniqueItems: true;
303
+ readonly description: "Existing requirement logic_claims values. Returned relationship guidance includes a merged manifest so repeated clause modeling does not discard earlier claims.";
304
+ };
305
+ };
306
+ };
307
+ readonly requiresProlog: true;
308
+ readonly effects: readonly ["kb-read"];
309
+ readonly execute: typeof import("../../../operations/modeling/suggest-predicates.js").executeSuggestPredicates;
310
+ };
311
+ };
312
+ export declare const skillsSpec: {
313
+ readonly name: "kb_skills";
314
+ readonly cliName: "skill";
315
+ readonly description: "Read bundled Kibi agent skills (workflow guidance). action:list returns the catalog; action:load returns a skill's metadata, Markdown body, declared resources and content hash (start with id 'kibi-usage'); action:read returns one manifest-declared resource. Read-only; does not require Prolog.";
316
+ readonly businessInputSchema: {
317
+ readonly type: "object";
318
+ readonly required: readonly ["action"];
319
+ readonly properties: {
320
+ readonly action: {
321
+ readonly type: "string";
322
+ readonly enum: readonly ["list", "load", "read"];
323
+ readonly description: "list, load (needs id) or read (needs id and resource).";
324
+ };
325
+ };
326
+ };
327
+ readonly requiresProlog: false;
328
+ readonly effects: readonly ["local-read"];
329
+ readonly execute: (input: Readonly<Record<string, unknown>>, context: OperationContext) => Promise<OperationResult<Record<string, unknown>>>;
330
+ };
331
+ export declare const modelSpec: {
332
+ readonly name: "kb_model";
333
+ readonly cliName: "model";
334
+ readonly description: "Turn requirement prose into checkable structure without writing the KB. mode:analyze returns the semantic advisor receipt: the clause ledger, what is grounded, what is ambiguous and suggested modeling (pass clauses for compound prose and optional typed kibi.logic.v1 interpretations). mode:requirement converts one claim (subjectKey, propertyKey, operator, value, or typed logic) into a strict-lane write set and applyPlan. mode:predicates ranks ontology predicate schemas and returns an applicable predicate-fact plan only for reviewed bindings, otherwise an ontology-gap observation. Apply returned plans with kb_upsert.";
335
+ readonly businessInputSchema: {
336
+ readonly type: "object";
337
+ readonly required: readonly ["mode", "text"];
338
+ readonly properties: {
339
+ readonly mode: {
340
+ readonly type: "string";
341
+ readonly enum: readonly ["analyze", "requirement", "predicates"];
342
+ readonly description: "analyze (advisor receipt), requirement (strict claim write set) or predicates (ontology predicate plan).";
343
+ };
344
+ };
345
+ };
346
+ readonly requiresProlog: true;
347
+ readonly effects: readonly ["kb-read"];
348
+ readonly execute: (input: Readonly<Record<string, unknown>>, context: OperationContext) => Promise<OperationResult<Record<string, unknown>>>;
349
+ };
350
+ export {};
351
+ //# sourceMappingURL=composite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"composite.d.ts","sourceRoot":"","sources":["../../../../src/public/operations/specs/composite.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAiB,MAAM,aAAa,CAAC;AAMlE;;;;;GAKG;AACH,KAAK,QAAQ,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,gBAAgB,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;AAkB9E,wBAAsB,iBAAiB,CACrC,QAAQ,EAAE,QAAQ,GAAG,MAAM,EAC3B,MAAM,EAAE,QAAQ,CACd,MAAM,CACJ,MAAM,EACN;IACE,QAAQ,CAAC,OAAO,EAAE,QAAQ,CAAC;IAC3B,QAAQ,CAAC,mBAAmB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;CACjE,CACF,CACF,EACD,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EACxC,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,eAAe,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CA+BnD;AAGD,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIf,CAAC;AAGX,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIf,CAAC;AAGX,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;CAqBW,CAAC;AAGnC,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;CAwBY,CAAC"}