kibi-cli 2.2.0 → 2.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 (230) hide show
  1. package/dist/cli-json-command.d.ts.map +1 -1
  2. package/dist/cli-json-command.js +2 -2
  3. package/dist/cli-operation-loader.d.ts.map +1 -1
  4. package/dist/cli-operation-loader.js +3 -0
  5. package/dist/cli-operation-metadata.d.ts +5 -1
  6. package/dist/cli-operation-metadata.d.ts.map +1 -1
  7. package/dist/cli-operation-metadata.js +6 -1
  8. package/dist/cli-register-maintenance.d.ts.map +1 -1
  9. package/dist/cli-register-maintenance.js +7 -0
  10. package/dist/cli-register-reporting.d.ts.map +1 -1
  11. package/dist/cli-register-reporting.js +4 -0
  12. package/dist/commands/check-diff.d.ts +5 -0
  13. package/dist/commands/check-diff.d.ts.map +1 -0
  14. package/dist/commands/check-diff.js +62 -0
  15. package/dist/commands/check-generated.d.ts.map +1 -1
  16. package/dist/commands/check-generated.js +41 -18
  17. package/dist/commands/check.d.ts.map +1 -1
  18. package/dist/commands/check.js +210 -73
  19. package/dist/commands/doctor.d.ts.map +1 -1
  20. package/dist/commands/doctor.js +63 -29
  21. package/dist/commands/github-init.d.ts.map +1 -1
  22. package/dist/commands/github-init.js +9 -2
  23. package/dist/commands/merge-driver.d.ts +31 -0
  24. package/dist/commands/merge-driver.d.ts.map +1 -0
  25. package/dist/commands/merge-driver.js +268 -0
  26. package/dist/commands/sync/manifest.d.ts.map +1 -1
  27. package/dist/commands/sync/manifest.js +3 -1
  28. package/dist/engine.d.ts +15 -1
  29. package/dist/engine.d.ts.map +1 -1
  30. package/dist/engine.js +252 -52
  31. package/dist/extractors/symbols-coordinator.d.ts +7 -0
  32. package/dist/extractors/symbols-coordinator.d.ts.map +1 -1
  33. package/dist/extractors/symbols-coordinator.js +75 -39
  34. package/dist/operations/bootstrap/candidates.js +1 -1
  35. package/dist/operations/bootstrap/discovery.js +1 -1
  36. package/dist/operations/bootstrap/generate.d.ts.map +1 -1
  37. package/dist/operations/bootstrap/generate.js +21 -5
  38. package/dist/operations/bootstrap/guidance-actions.d.ts.map +1 -1
  39. package/dist/operations/bootstrap/guidance-actions.js +3 -0
  40. package/dist/operations/bootstrap/guidance.d.ts.map +1 -1
  41. package/dist/operations/bootstrap/guidance.js +7 -1
  42. package/dist/operations/bootstrap/intent-claims.d.ts +17 -0
  43. package/dist/operations/bootstrap/intent-claims.d.ts.map +1 -0
  44. package/dist/operations/bootstrap/intent-claims.js +95 -0
  45. package/dist/operations/bootstrap/presentation.d.ts +2 -0
  46. package/dist/operations/bootstrap/presentation.d.ts.map +1 -1
  47. package/dist/operations/bootstrap/presentation.js +60 -1
  48. package/dist/operations/bootstrap/types.d.ts +28 -0
  49. package/dist/operations/bootstrap/types.d.ts.map +1 -1
  50. package/dist/operations/bootstrap/types.js +16 -0
  51. package/dist/operations/modeling/predicate-inference-1.js +1 -1
  52. package/dist/operations/mutation/source-authoring.d.ts.map +1 -1
  53. package/dist/operations/mutation/source-authoring.js +175 -53
  54. package/dist/operations/mutation/symbol-refresh.d.ts.map +1 -1
  55. package/dist/operations/mutation/symbol-refresh.js +4 -1
  56. package/dist/operations/mutation/upsert.d.ts.map +1 -1
  57. package/dist/operations/mutation/upsert.js +5 -7
  58. package/dist/operations/planning/apply-plan.d.ts.map +1 -1
  59. package/dist/operations/planning/apply-plan.js +5 -9
  60. package/dist/operations/proof/ingest-proof.d.ts.map +1 -1
  61. package/dist/operations/proof/ingest-proof.js +1 -0
  62. package/dist/operations/semantic-advisor/analysis-receipt.d.ts.map +1 -1
  63. package/dist/operations/semantic-advisor/analysis-receipt.js +7 -1
  64. package/dist/operations/semantic-advisor/analyze-prose.d.ts.map +1 -1
  65. package/dist/operations/semantic-advisor/analyze-prose.js +26 -4
  66. package/dist/operations/semantic-advisor/clauses.d.ts +1 -0
  67. package/dist/operations/semantic-advisor/clauses.d.ts.map +1 -1
  68. package/dist/operations/semantic-advisor/clauses.js +7 -1
  69. package/dist/performance-trace.d.ts +17 -0
  70. package/dist/performance-trace.d.ts.map +1 -0
  71. package/dist/performance-trace.js +134 -0
  72. package/dist/plugins/approved-source-analyzers.d.ts +13 -0
  73. package/dist/plugins/approved-source-analyzers.d.ts.map +1 -0
  74. package/dist/plugins/approved-source-analyzers.generated.d.ts +71 -0
  75. package/dist/plugins/approved-source-analyzers.generated.d.ts.map +1 -0
  76. package/dist/plugins/approved-source-analyzers.generated.js +77 -0
  77. package/dist/plugins/approved-source-analyzers.js +3 -0
  78. package/dist/plugins/maintenance-source-analysis.d.ts +14 -0
  79. package/dist/plugins/maintenance-source-analysis.d.ts.map +1 -0
  80. package/dist/plugins/maintenance-source-analysis.js +191 -0
  81. package/dist/plugins/registry.d.ts +2 -1
  82. package/dist/plugins/registry.d.ts.map +1 -1
  83. package/dist/plugins/registry.js +6 -1
  84. package/dist/plugins/source-analysis-service.d.ts +36 -1
  85. package/dist/plugins/source-analysis-service.d.ts.map +1 -1
  86. package/dist/plugins/source-analysis-service.js +184 -27
  87. package/dist/plugins/source-change-analysis.d.ts +15 -0
  88. package/dist/plugins/source-change-analysis.d.ts.map +1 -0
  89. package/dist/plugins/source-change-analysis.js +54 -0
  90. package/dist/plugins/source-classification.d.ts +41 -0
  91. package/dist/plugins/source-classification.d.ts.map +1 -0
  92. package/dist/plugins/source-classification.js +490 -0
  93. package/dist/prolog/swipl-resolver.d.ts +88 -0
  94. package/dist/prolog/swipl-resolver.d.ts.map +1 -0
  95. package/dist/prolog/swipl-resolver.js +446 -0
  96. package/dist/prolog.d.ts +15 -1
  97. package/dist/prolog.d.ts.map +1 -1
  98. package/dist/prolog.js +67 -6
  99. package/dist/public/diagnostic-usage.d.ts +14 -0
  100. package/dist/public/diagnostic-usage.d.ts.map +1 -1
  101. package/dist/public/diagnostic-usage.js +55 -1
  102. package/dist/public/impact/analyzer.d.ts.map +1 -1
  103. package/dist/public/impact/analyzer.js +56 -5
  104. package/dist/public/impact/diagnostics.d.ts.map +1 -1
  105. package/dist/public/impact/diagnostics.js +3 -1
  106. package/dist/public/impact/manifest.d.ts.map +1 -1
  107. package/dist/public/impact/manifest.js +15 -1
  108. package/dist/public/impact/source-changes.d.ts.map +1 -1
  109. package/dist/public/impact/source-changes.js +35 -27
  110. package/dist/public/impact/types.d.ts +2 -0
  111. package/dist/public/impact/types.d.ts.map +1 -1
  112. package/dist/public/operations/catalog.d.ts +117 -1
  113. package/dist/public/operations/catalog.d.ts.map +1 -1
  114. package/dist/public/operations/catalog.js +2 -0
  115. package/dist/public/operations/contracts.d.ts.map +1 -1
  116. package/dist/public/operations/contracts.js +309 -8
  117. package/dist/public/operations/impact-review-preparation.d.ts +14 -0
  118. package/dist/public/operations/impact-review-preparation.d.ts.map +1 -0
  119. package/dist/public/operations/impact-review-preparation.js +379 -0
  120. package/dist/public/operations/index.d.ts +2 -0
  121. package/dist/public/operations/index.d.ts.map +1 -1
  122. package/dist/public/operations/index.js +2 -0
  123. package/dist/public/operations/node-ports.d.ts.map +1 -1
  124. package/dist/public/operations/node-ports.js +1 -35
  125. package/dist/public/operations/proof-receipt-projection.d.ts +5 -0
  126. package/dist/public/operations/proof-receipt-projection.d.ts.map +1 -0
  127. package/dist/public/operations/proof-receipt-projection.js +36 -0
  128. package/dist/public/operations/specs/bootstrap.d.ts +73 -1
  129. package/dist/public/operations/specs/bootstrap.d.ts.map +1 -1
  130. package/dist/public/operations/specs/bootstrap.js +66 -1
  131. package/dist/public/operations/specs/impact-review-preparation.d.ts +47 -0
  132. package/dist/public/operations/specs/impact-review-preparation.d.ts.map +1 -0
  133. package/dist/public/operations/specs/impact-review-preparation.js +43 -0
  134. package/dist/public/operations/symbol-repair-plan.d.ts.map +1 -1
  135. package/dist/public/operations/symbol-repair-plan.js +3 -1
  136. package/dist/public/operations/types.d.ts +1 -1
  137. package/dist/public/operations/types.d.ts.map +1 -1
  138. package/dist/public/skills/kibi-bootstrap/SKILL.md +47 -11
  139. package/dist/public/skills/kibi-bootstrap/resources/bootstrap.md +6 -1
  140. package/dist/public/skills/kibi-usage/SKILL.md +14 -0
  141. package/dist/public/skills/kibi-usage/resources/operation-access.md +5 -0
  142. package/dist/public/telemetry-acceptance.d.ts +8 -0
  143. package/dist/public/telemetry-acceptance.d.ts.map +1 -1
  144. package/dist/public/telemetry-acceptance.js +10 -0
  145. package/dist/traceability/analysis-gate.d.ts +39 -0
  146. package/dist/traceability/analysis-gate.d.ts.map +1 -0
  147. package/dist/traceability/analysis-gate.js +51 -0
  148. package/dist/traceability/git-change-snapshot.d.ts +27 -0
  149. package/dist/traceability/git-change-snapshot.d.ts.map +1 -0
  150. package/dist/traceability/git-change-snapshot.js +411 -0
  151. package/dist/traceability/git-staged.d.ts +5 -1
  152. package/dist/traceability/git-staged.d.ts.map +1 -1
  153. package/dist/traceability/git-staged.js +16 -11
  154. package/dist/traceability/impact-evaluator.d.ts +54 -0
  155. package/dist/traceability/impact-evaluator.d.ts.map +1 -0
  156. package/dist/traceability/impact-evaluator.js +270 -0
  157. package/dist/traceability/impact-git-tree.d.ts +12 -0
  158. package/dist/traceability/impact-git-tree.d.ts.map +1 -0
  159. package/dist/traceability/impact-git-tree.js +46 -0
  160. package/dist/traceability/impact-knowledge.d.ts +16 -0
  161. package/dist/traceability/impact-knowledge.d.ts.map +1 -0
  162. package/dist/traceability/impact-knowledge.js +165 -0
  163. package/dist/traceability/impact-policy.d.ts +15 -0
  164. package/dist/traceability/impact-policy.d.ts.map +1 -0
  165. package/dist/traceability/impact-policy.js +48 -0
  166. package/dist/traceability/impact-policy.v1.schema.json +48 -0
  167. package/dist/traceability/impact-pr-diff.d.ts +5 -0
  168. package/dist/traceability/impact-pr-diff.d.ts.map +1 -0
  169. package/dist/traceability/impact-pr-diff.js +83 -0
  170. package/dist/traceability/impact-record-validation.d.ts +9 -0
  171. package/dist/traceability/impact-record-validation.d.ts.map +1 -0
  172. package/dist/traceability/impact-record-validation.js +113 -0
  173. package/dist/traceability/impact-review.d.ts +148 -0
  174. package/dist/traceability/impact-review.d.ts.map +1 -0
  175. package/dist/traceability/impact-review.js +494 -0
  176. package/dist/traceability/impact-review.schema.json +365 -0
  177. package/dist/traceability/impact-side-evidence.d.ts +13 -0
  178. package/dist/traceability/impact-side-evidence.d.ts.map +1 -0
  179. package/dist/traceability/impact-side-evidence.js +240 -0
  180. package/dist/traceability/reviewed-coordinate-refresh.d.ts +10 -0
  181. package/dist/traceability/reviewed-coordinate-refresh.d.ts.map +1 -0
  182. package/dist/traceability/reviewed-coordinate-refresh.js +49 -0
  183. package/dist/traceability/snapshot-knowledge.d.ts +4 -0
  184. package/dist/traceability/snapshot-knowledge.d.ts.map +1 -0
  185. package/dist/traceability/snapshot-knowledge.js +98 -0
  186. package/dist/traceability/staged-file-coverage.d.ts +23 -0
  187. package/dist/traceability/staged-file-coverage.d.ts.map +1 -1
  188. package/dist/traceability/staged-impact-contract.d.ts.map +1 -1
  189. package/dist/traceability/staged-impact-contract.js +2 -16
  190. package/dist/traceability/staged-symbols-manifest.d.ts +4 -0
  191. package/dist/traceability/staged-symbols-manifest.d.ts.map +1 -1
  192. package/dist/traceability/staged-symbols-manifest.js +17 -6
  193. package/dist/traceability/symbol-extract.d.ts +3 -5
  194. package/dist/traceability/symbol-extract.d.ts.map +1 -1
  195. package/dist/traceability/symbol-extract.js +49 -34
  196. package/dist/traceability/temp-kb.d.ts +1 -1
  197. package/dist/traceability/temp-kb.d.ts.map +1 -1
  198. package/dist/traceability/temp-kb.js +49 -13
  199. package/dist/traceability/trusted-pr-event.d.ts +13 -0
  200. package/dist/traceability/trusted-pr-event.d.ts.map +1 -0
  201. package/dist/traceability/trusted-pr-event.js +105 -0
  202. package/dist/utils/canonical-path.d.ts +3 -0
  203. package/dist/utils/canonical-path.d.ts.map +1 -0
  204. package/dist/utils/canonical-path.js +33 -0
  205. package/package.json +14 -5
  206. package/src/public/diagnostic-usage.ts +59 -1
  207. package/src/public/impact/analyzer.ts +88 -5
  208. package/src/public/impact/diagnostics.ts +7 -5
  209. package/src/public/impact/manifest.ts +14 -1
  210. package/src/public/impact/source-changes.ts +39 -34
  211. package/src/public/impact/types.ts +5 -0
  212. package/src/public/operations/catalog.ts +2 -0
  213. package/src/public/operations/contracts.ts +385 -9
  214. package/src/public/operations/impact-review-preparation.ts +548 -0
  215. package/src/public/operations/index.ts +2 -0
  216. package/src/public/operations/node-ports.ts +1 -39
  217. package/src/public/operations/proof-receipt-projection.ts +39 -0
  218. package/src/public/operations/specs/bootstrap.ts +78 -4
  219. package/src/public/operations/specs/impact-review-preparation.ts +46 -0
  220. package/src/public/operations/symbol-repair-plan.ts +3 -1
  221. package/src/public/operations/types.ts +1 -0
  222. package/src/public/skills/kibi-bootstrap/SKILL.md +47 -11
  223. package/src/public/skills/kibi-bootstrap/resources/bootstrap.md +6 -1
  224. package/src/public/skills/kibi-usage/SKILL.md +14 -0
  225. package/src/public/skills/kibi-usage/resources/operation-access.md +5 -0
  226. package/src/public/telemetry-acceptance.ts +9 -0
  227. package/src/traceability/impact-policy.v1.schema.json +48 -0
  228. package/src/traceability/impact-review.schema.json +365 -0
  229. package/templates/github/kibi-badge.yml +0 -4
  230. package/templates/github/kibi-report.yml +0 -4
@@ -1 +1 @@
1
- {"version":3,"file":"diagnostic-usage.d.ts","sourceRoot":"","sources":["../../src/public/diagnostic-usage.ts"],"names":[],"mappings":"AASA,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,YAAY,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IACzD,QAAQ,CAAC,SAAS,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC;IAC7D,QAAQ,CAAC,SAAS,EAAE,IAAI,CAAC;IACzB,QAAQ,CAAC,UAAU,CAAC,EAAE,IAAI,CAAC;IAC3B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AAC,MAAM,EAAE,SAAS,GAAG,OAAO,CAAC;IACrC,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;CAC3B;AAuBD,wBAAgB,6BAA6B,CAC3C,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,GACtC,MAAM,CAIR;AAkHD,wBAAgB,2BAA2B,CACzC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EACvC,SAAS,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,GAAG,IAAI,EACnD,MAAM,EAAE,OAAO,GACd,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAwEzB;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,GAAG,GAAE,MAAM,CAAC,UAAwB,GACnC,OAAO,CAKT;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,GAAG,GAAE,MAAM,CAAC,UAAwB,GACnC,MAAM,CAIR;AA2BD,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,oBAAoB,GAAG,IAAI,CAmC1E"}
@@ -1,6 +1,7 @@
1
1
  import { createHash, randomUUID } from "node:crypto";
2
- import { appendFileSync, mkdirSync } from "node:fs";
2
+ import { appendFileSync, existsSync, mkdirSync, readFileSync } from "node:fs";
3
3
  import path from "node:path";
4
+ import { fileURLToPath } from "node:url";
4
5
  import { appendPayloadCountField, normalizeResultPayload, } from "./operations/result-envelope.js";
5
6
  function isRecord(value) {
6
7
  return Boolean(value) && typeof value === "object" && !Array.isArray(value);
@@ -177,6 +178,56 @@ export function deriveDiagnosticUsageFields(tool, args, telemetry, result) {
177
178
  fields.result_summary = `${tool} completed`;
178
179
  return fields;
179
180
  }
181
+ /**
182
+ * Whether the operator opted into usage telemetry through the environment.
183
+ *
184
+ * `KIBI_DIAGNOSTIC_MODE` is the one opt-in shared with the MCP server, so a
185
+ * single setting covers both peer surfaces. `KIBI_CLI_DIAGNOSTIC_MODE` is the
186
+ * older CLI-only spelling and keeps working.
187
+ */
188
+ export function diagnosticEnvOptIn(env = process.env) {
189
+ return ["KIBI_DIAGNOSTIC_MODE", "KIBI_CLI_DIAGNOSTIC_MODE"].some((key) => {
190
+ const value = env[key]?.trim().toLowerCase();
191
+ return value === "1" || value === "true";
192
+ });
193
+ }
194
+ /**
195
+ * The host that ran this CLI call. Hosts that launch Kibi set `KIBI_HOST`;
196
+ * Claude Code marks every shell it runs with `CLAUDECODE=1`, which is the
197
+ * only ambient signal trusted here. Anything else stays `unknown`.
198
+ */
199
+ export function diagnosticCliHost(env = process.env) {
200
+ const explicit = env.KIBI_HOST?.trim() || env.KIBI_MCP_HOST?.trim();
201
+ if (explicit)
202
+ return explicit;
203
+ return env.CLAUDECODE === "1" ? "claude-code" : "unknown";
204
+ }
205
+ let cachedCliPackageVersion;
206
+ function cliPackageVersion() {
207
+ if (cachedCliPackageVersion !== undefined)
208
+ return cachedCliPackageVersion;
209
+ cachedCliPackageVersion = null;
210
+ let current = path.dirname(fileURLToPath(import.meta.url));
211
+ while (true) {
212
+ const candidate = path.join(current, "package.json");
213
+ if (existsSync(candidate)) {
214
+ try {
215
+ const parsed = JSON.parse(readFileSync(candidate, "utf8"));
216
+ if (isRecord(parsed) && typeof parsed.version === "string") {
217
+ cachedCliPackageVersion = parsed.version;
218
+ }
219
+ }
220
+ catch {
221
+ // An unreadable manifest leaves the version unknown.
222
+ }
223
+ return cachedCliPackageVersion;
224
+ }
225
+ const parent = path.dirname(current);
226
+ if (parent === current)
227
+ return null;
228
+ current = parent;
229
+ }
230
+ }
180
231
  export function appendCliDiagnosticUsage(input) {
181
232
  const finishedAt = input.finishedAt ?? new Date();
182
233
  const requestId = input.requestId ?? `cli-${randomUUID()}`;
@@ -189,6 +240,9 @@ export function appendCliDiagnosticUsage(input) {
189
240
  request_id: requestId,
190
241
  tool: input.tool,
191
242
  interface: "cli_json",
243
+ host: diagnosticCliHost(),
244
+ package_version: cliPackageVersion(),
245
+ workspace_root: input.workspaceRoot,
192
246
  telemetry: input.telemetry,
193
247
  business_args: input.businessArgs,
194
248
  status: input.status,
@@ -1 +1 @@
1
- {"version":3,"file":"analyzer.d.ts","sourceRoot":"","sources":["../../../src/public/impact/analyzer.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EACV,wBAAwB,EACxB,uBAAuB,EACxB,MAAM,YAAY,CAAC;AAEpB,wBAAsB,wBAAwB,CAC5C,OAAO,EAAE,wBAAwB,GAChC,OAAO,CAAC,uBAAuB,CAAC,CAmElC"}
1
+ {"version":3,"file":"analyzer.d.ts","sourceRoot":"","sources":["../../../src/public/impact/analyzer.ts"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EACV,wBAAwB,EACxB,uBAAuB,EACxB,MAAM,YAAY,CAAC;AAEpB,wBAAsB,wBAAwB,CAC5C,OAAO,EAAE,wBAAwB,GAChC,OAAO,CAAC,uBAAuB,CAAC,CA2IlC"}
@@ -1,27 +1,76 @@
1
1
  import * as path from "node:path";
2
+ import { createMaintenanceSourceAnalysisService, readSnapshotSourceConfig, } from "../../plugins/maintenance-source-analysis.js";
3
+ import { analyzeSourceChanges, assertSourceAnalysisGate, } from "../../plugins/source-change-analysis.js";
4
+ import { captureStagedSnapshot } from "../../traceability/git-change-snapshot.js";
5
+ import { readSnapshotKnowledge } from "../../traceability/snapshot-knowledge.js";
2
6
  import { extractSymbolsFromStagedFileAsync } from "../../traceability/symbol-extract.js";
3
7
  import { createSemanticReviewDiagnostics, createSymbolGranularityDiagnostics, } from "./diagnostics.js";
4
8
  import { createImpactManifestLookup, readImpactManifestResults, } from "./manifest.js";
9
+ import { normalizeSourceFile } from "./source-changes.js";
5
10
  import { collectSourceChanges, uniqueSorted } from "./source-changes.js";
6
11
  import { buildNextActions, collectLinkedEntities, formatExtractedSymbols, } from "./summaries.js";
7
12
  import { createSymbolQualityDiagnostics } from "./symbol-quality.js";
8
13
  export async function analyzeChangedFileImpact(options) {
9
14
  const workspaceRoot = path.resolve(options.workspaceRoot);
10
- const sourceChanges = collectSourceChanges({ ...options, workspaceRoot });
11
- const sourceFiles = uniqueSorted(sourceChanges.map((change) => change.file));
12
- const manifestResults = readImpactManifestResults(workspaceRoot);
15
+ const snapshot = options.staged
16
+ ? captureStagedSnapshot(workspaceRoot)
17
+ : undefined;
18
+ const filter = new Set((options.sourceFiles ?? []).map((file) => normalizeSourceFile(workspaceRoot, file)));
19
+ const snapshotAnalysisInventory = snapshot
20
+ ? snapshot.inventory.filter((file) => filter.size === 0 || filter.has(file.path))
21
+ : undefined;
22
+ const snapshotSourceInventory = snapshot
23
+ ? snapshot.inventory.filter((file) => file.analysisDepth !== "metadata" &&
24
+ !file.skipReason &&
25
+ file.content !== undefined &&
26
+ (filter.size === 0 || filter.has(file.path)))
27
+ : undefined;
28
+ const sourceChanges = snapshot
29
+ ? (snapshotSourceInventory ?? []).map((file) => ({
30
+ file: file.path,
31
+ status: file.status,
32
+ hunkRanges: file.hunkRanges,
33
+ content: file.content ?? "",
34
+ }))
35
+ : collectSourceChanges({ ...options, workspaceRoot });
36
+ const service = createMaintenanceSourceAnalysisService(workspaceRoot, snapshot ? readSnapshotSourceConfig(snapshot) : undefined);
37
+ const analyses = snapshot
38
+ ? await analyzeSourceChanges(snapshotAnalysisInventory ?? [], service)
39
+ : undefined;
40
+ if (analyses)
41
+ assertSourceAnalysisGate(snapshotAnalysisInventory ?? [], analyses);
42
+ const sourceFiles = uniqueSorted(snapshot
43
+ ? snapshot.inventory
44
+ .filter((file) => file.analysisDepth !== "metadata" &&
45
+ (filter.size === 0 || filter.has(file.path)))
46
+ .map((file) => file.path)
47
+ : sourceChanges.map((change) => change.file));
48
+ const manifestResults = snapshot
49
+ ? readSnapshotKnowledge(snapshot.readGit, snapshot.headTree, snapshot.readBlobs).filter((result) => result.entity.type === "symbol")
50
+ : readImpactManifestResults(workspaceRoot);
13
51
  const manifestLookup = createImpactManifestLookup(manifestResults);
14
52
  const symbolsByFile = new Map();
15
53
  const sourceContentByFile = new Map();
54
+ const sourceSymbolsByFile = new Map();
16
55
  for (const change of sourceChanges) {
17
56
  sourceContentByFile.set(change.file, change.content);
18
- // Maintenance path: builtin-only (do not pass registry / workspaceRoot).
57
+ const analysis = analyses?.get(change.file)?.after ??
58
+ (await service.analyzeTextV2(change.file, change.content));
19
59
  const extracted = await extractSymbolsFromStagedFileAsync({
20
60
  path: change.file,
21
61
  status: change.status,
22
62
  hunkRanges: [...change.hunkRanges],
23
63
  content: change.content,
24
- }, manifestLookup, {});
64
+ }, manifestLookup, { analyzeText: async () => analysis });
65
+ const allSymbols = await extractSymbolsFromStagedFileAsync({
66
+ path: change.file,
67
+ status: change.status,
68
+ content: change.content,
69
+ hunkRanges: [
70
+ { start: 1, end: Math.max(1, change.content.split("\n").length) },
71
+ ],
72
+ }, manifestLookup, { analyzeText: async () => analysis });
73
+ sourceSymbolsByFile.set(change.file, allSymbols);
25
74
  symbolsByFile.set(change.file, extracted.filter((symbol) => symbol.hunkRanges.length > 0));
26
75
  }
27
76
  const activeSourceFiles = new Set(sourceFiles);
@@ -34,6 +83,7 @@ export async function analyzeChangedFileImpact(options) {
34
83
  manifestResults: activeManifestResults,
35
84
  symbolsByFile,
36
85
  sourceContentByFile,
86
+ sourceSymbolsByFile,
37
87
  workspaceRoot,
38
88
  }),
39
89
  ...createSymbolQualityDiagnostics({
@@ -46,6 +96,7 @@ export async function analyzeChangedFileImpact(options) {
46
96
  const cappedDiagnostics = maxDiagnostics !== undefined && maxDiagnostics >= 0
47
97
  ? impactDiagnostics.slice(0, maxDiagnostics)
48
98
  : impactDiagnostics;
99
+ snapshot?.assertUnchanged();
49
100
  return {
50
101
  impactDiagnostics: cappedDiagnostics,
51
102
  sourceFiles,
@@ -1 +1 @@
1
- {"version":3,"file":"diagnostics.d.ts","sourceRoot":"","sources":["../../../src/public/impact/diagnostics.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAYrF,OAAO,KAAK,EACV,iBAAiB,EACjB,gCAAgC,EAChC,mCAAmC,EACpC,MAAM,YAAY,CAAC;AA2FpB,wBAAgB,kCAAkC,CAChD,OAAO,EAAE,mCAAmC,GAC3C,oBAAoB,EAAE,CA+CxB;AAED,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,gCAAgC,GACxC,oBAAoB,EAAE,CAsBxB;AAED,wBAAgB,4BAA4B,CAC1C,WAAW,EAAE,SAAS,oBAAoB,EAAE,GAC3C,OAAO,CAET;AAED,wBAAgB,6BAA6B,CAC3C,WAAW,EAAE,SAAS,iBAAiB,EAAE,GACxC,OAAO,CAIT"}
1
+ {"version":3,"file":"diagnostics.d.ts","sourceRoot":"","sources":["../../../src/public/impact/diagnostics.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,0CAA0C,CAAC;AAYrF,OAAO,KAAK,EACV,iBAAiB,EACjB,gCAAgC,EAChC,mCAAmC,EACpC,MAAM,YAAY,CAAC;AA6FpB,wBAAgB,kCAAkC,CAChD,OAAO,EAAE,mCAAmC,GAC3C,oBAAoB,EAAE,CA+CxB;AAED,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,gCAAgC,GACxC,oBAAoB,EAAE,CAsBxB;AAED,wBAAgB,4BAA4B,CAC1C,WAAW,EAAE,SAAS,oBAAoB,EAAE,GAC3C,OAAO,CAET;AAED,wBAAgB,6BAA6B,CAC3C,WAAW,EAAE,SAAS,iBAAiB,EAAE,GACxC,OAAO,CAIT"}
@@ -38,7 +38,9 @@ function readSourceSymbols(sourceFile, sourceContentByFile, workspaceRoot) {
38
38
  });
39
39
  }
40
40
  function getGranularSymbolsForSourceFile(sourceFile, options) {
41
- const sourceSymbols = readSourceSymbols(sourceFile, options.sourceContentByFile, options.workspaceRoot ?? process.cwd());
41
+ const sourceSymbols = options.sourceSymbolsByFile
42
+ ? (options.sourceSymbolsByFile.get(sourceFile) ?? [])
43
+ : readSourceSymbols(sourceFile, options.sourceContentByFile, options.workspaceRoot ?? process.cwd());
42
44
  const changedSymbols = options.symbolsByFile.get(sourceFile);
43
45
  return {
44
46
  candidateSymbols: changedSymbols ?? sourceSymbols,
@@ -1 +1 @@
1
- {"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../../../src/public/impact/manifest.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;AAc3E,wBAAgB,yBAAyB,CACvC,aAAa,EAAE,MAAM,GACpB,SAAS,gBAAgB,EAAE,CAkB7B;AAED,wBAAgB,0BAA0B,CACxC,eAAe,EAAE,SAAS,gBAAgB,EAAE,GAC3C,cAAc,CAYhB"}
1
+ {"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../../../src/public/impact/manifest.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAErE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;AAc3E,wBAAgB,yBAAyB,CACvC,aAAa,EAAE,MAAM,GACpB,SAAS,gBAAgB,EAAE,CAkB7B;AAED,wBAAgB,0BAA0B,CACxC,eAAe,EAAE,SAAS,gBAAgB,EAAE,GAC3C,cAAc,CAwBhB"}
@@ -1,6 +1,7 @@
1
1
  import { existsSync } from "node:fs";
2
2
  import * as path from "node:path";
3
3
  import { extractFromManifest } from "../../extractors/manifest.js";
4
+ import { createManifestLookupSentinelKey } from "../../traceability/symbol-extract.js";
4
5
  import { CANONICAL_ENTITY_PATHS } from "../../utils/kb-paths.js";
5
6
  import { isTraceabilityRelationshipType } from "../symbol-granularity.js";
6
7
  import { normalizeSourceFile } from "./source-changes.js";
@@ -29,9 +30,22 @@ export function readImpactManifestResults(workspaceRoot) {
29
30
  }
30
31
  export function createImpactManifestLookup(manifestResults) {
31
32
  const manifestLookup = new Map();
33
+ manifestLookup.set(createManifestLookupSentinelKey(".kb/symbols.yaml"), {
34
+ id: "__captured_manifest__",
35
+ relationships: [],
36
+ });
37
+ const ambiguous = new Set();
32
38
  for (const result of manifestResults) {
33
39
  const sourceFile = result.sourceFile ?? result.entity.source;
34
- manifestLookup.set(`${sourceFile}:${result.entity.title}`, {
40
+ const key = `${sourceFile}:${result.entity.title}`;
41
+ if (ambiguous.has(key))
42
+ continue;
43
+ if (manifestLookup.has(key)) {
44
+ manifestLookup.delete(key);
45
+ ambiguous.add(key);
46
+ continue;
47
+ }
48
+ manifestLookup.set(key, {
35
49
  id: result.entity.id,
36
50
  relationships: toTraceabilityRelationships(result.relationships),
37
51
  });
@@ -1 +1 @@
1
- {"version":3,"file":"source-changes.d.ts","sourceRoot":"","sources":["../../../src/public/impact/source-changes.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,wBAAwB,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAiBzE,wBAAgB,mBAAmB,CACjC,aAAa,EAAE,MAAM,EACrB,UAAU,EAAE,MAAM,GACjB,MAAM,CAKR;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,MAAM,EAAE,CAE/D;AA6HD,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,wBAAwB,GAChC,YAAY,EAAE,CAchB"}
1
+ {"version":3,"file":"source-changes.d.ts","sourceRoot":"","sources":["../../../src/public/impact/source-changes.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,wBAAwB,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAMzE,wBAAgB,mBAAmB,CACjC,aAAa,EAAE,MAAM,EACrB,UAAU,EAAE,MAAM,GACjB,MAAM,CAKR;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,MAAM,EAAE,CAE/D;AA4ID,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,wBAAwB,GAChC,YAAY,EAAE,CAchB"}
@@ -1,20 +1,11 @@
1
- import { execSync } from "node:child_process";
2
- import { existsSync, readFileSync } from "node:fs";
1
+ import { execFileSync, execSync } from "node:child_process";
2
+ import { existsSync, lstatSync, readFileSync, realpathSync } from "node:fs";
3
3
  import * as path from "node:path";
4
+ import { isQualifiedSourcePath } from "../../plugins/source-classification.js";
4
5
  import { getStagedFiles, parseHunksFromDiff, } from "../../traceability/git-staged.js";
5
6
  import { hasMeaningfulSourceDiff } from "./diff-meaning.js";
6
- const SOURCE_EXTENSIONS = new Set([
7
- ".ts",
8
- ".tsx",
9
- ".js",
10
- ".jsx",
11
- ".mts",
12
- ".cts",
13
- ".mjs",
14
- ".cjs",
15
- ]);
16
7
  function isSupportedSourcePath(filePath) {
17
- return SOURCE_EXTENSIONS.has(path.extname(filePath));
8
+ return isQualifiedSourcePath(filePath);
18
9
  }
19
10
  export function normalizeSourceFile(workspaceRoot, sourceFile) {
20
11
  const relativePath = path.isAbsolute(sourceFile)
@@ -25,26 +16,41 @@ export function normalizeSourceFile(workspaceRoot, sourceFile) {
25
16
  export function uniqueSorted(values) {
26
17
  return [...new Set(values)].sort();
27
18
  }
28
- function escapeGitPath(filePath) {
29
- return filePath.replace(/\\/g, "\\\\").replace(/"/g, '\\"');
30
- }
31
- function runGit(workspaceRoot, command) {
32
- return execSync(command, { cwd: workspaceRoot, encoding: "utf8" });
19
+ function runGit(workspaceRoot, args) {
20
+ return execFileSync("git", [...args], {
21
+ cwd: workspaceRoot,
22
+ encoding: "utf8",
23
+ env: { ...process.env, GIT_LITERAL_PATHSPECS: "1" },
24
+ });
33
25
  }
34
26
  function readWorkingTreeSource(workspaceRoot, sourceFile) {
35
27
  const absolutePath = path.resolve(workspaceRoot, sourceFile);
36
- if (!existsSync(absolutePath))
28
+ const relative = path.relative(workspaceRoot, absolutePath);
29
+ if (!relative || relative.startsWith("..") || path.isAbsolute(relative))
30
+ throw new Error("Source path must remain inside the workspace");
31
+ if (!existsSync(absolutePath) || !lstatSync(absolutePath).isFile())
32
+ return null;
33
+ const actualRelative = path.relative(realpathSync(workspaceRoot), realpathSync(absolutePath));
34
+ if (actualRelative.startsWith("..") || path.isAbsolute(actualRelative))
35
+ throw new Error("Source path escapes the workspace");
36
+ const bytes = readFileSync(absolutePath);
37
+ if (bytes.includes(0))
38
+ return null;
39
+ try {
40
+ return new TextDecoder("utf-8", { fatal: true }).decode(bytes);
41
+ }
42
+ catch {
37
43
  return null;
38
- return readFileSync(absolutePath, "utf8");
44
+ }
39
45
  }
40
46
  function fullFileHunk(content) {
41
47
  return [{ start: 1, end: Math.max(1, content.split(/\r?\n/).length) }];
42
48
  }
43
49
  function getWorkingTreeDiffSourceFiles(workspaceRoot) {
44
50
  try {
45
- return uniqueSorted(runGit(workspaceRoot, "git diff --name-only --diff-filter=ACMR")
46
- .split(/\r?\n/)
47
- .map((filePath) => normalizeSourceFile(workspaceRoot, filePath.trim()))
51
+ return uniqueSorted(runGit(workspaceRoot, ["diff", "--name-only", "-z", "--diff-filter=ACMR"])
52
+ .split("\0")
53
+ .map((filePath) => normalizeSourceFile(workspaceRoot, filePath))
48
54
  .filter((filePath) => filePath.length > 0)
49
55
  .filter(isSupportedSourcePath));
50
56
  }
@@ -54,7 +60,7 @@ function getWorkingTreeDiffSourceFiles(workspaceRoot) {
54
60
  }
55
61
  function getWorkingTreeHunks(workspaceRoot, sourceFile) {
56
62
  try {
57
- const diffText = runGit(workspaceRoot, `git diff -U0 -- "${escapeGitPath(sourceFile)}"`);
63
+ const diffText = runGit(workspaceRoot, ["diff", "-U0", "--", sourceFile]);
58
64
  return parseHunksFromDiff(diffText);
59
65
  }
60
66
  catch {
@@ -69,7 +75,8 @@ function getStagedSourceChanges(workspaceRoot, sourceFileFilter) {
69
75
  .flatMap((file) => {
70
76
  if (file.content === undefined || file.hunkRanges.length === 0)
71
77
  return [];
72
- if (file.diffText !== undefined &&
78
+ if (!/\.(pyi?|go|rs)$/.test(file.path) &&
79
+ file.diffText !== undefined &&
73
80
  !hasMeaningfulSourceDiff(file.diffText)) {
74
81
  return [];
75
82
  }
@@ -91,8 +98,9 @@ function getWorkingTreeSourceChanges(workspaceRoot, sourceFileFilter) {
91
98
  const content = readWorkingTreeSource(workspaceRoot, sourceFile);
92
99
  if (content === null)
93
100
  return [];
94
- const diffText = runGit(workspaceRoot, `git diff -U0 -- "${escapeGitPath(sourceFile)}"`);
95
- if (!hasMeaningfulSourceDiff(diffText))
101
+ const diffText = runGit(workspaceRoot, ["diff", "-U0", "--", sourceFile]);
102
+ if (!/\.(pyi?|go|rs)$/.test(sourceFile) &&
103
+ !hasMeaningfulSourceDiff(diffText))
96
104
  return [];
97
105
  const hunkRanges = getWorkingTreeHunks(workspaceRoot, sourceFile);
98
106
  if (hunkRanges.length === 0)
@@ -26,6 +26,8 @@ export type SymbolGranularityDiagnosticsOptions = {
26
26
  readonly activeEntityIds?: ReadonlySet<string>;
27
27
  readonly symbolsByFile: SymbolsByFile;
28
28
  readonly sourceContentByFile?: ReadonlyMap<string, string>;
29
+ /** Complete snapshot analysis; when supplied, filesystem fallback is forbidden. */
30
+ readonly sourceSymbolsByFile?: ReadonlyMap<string, readonly ExtractedSymbol[]>;
29
31
  readonly workspaceRoot?: string;
30
32
  };
31
33
  export type SemanticReviewDiagnosticsOptions = {
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/public/impact/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAC9E,OAA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647
  readonly name: "kb_plan_bootstrap";
648
648
  readonly cliName: "plan-bootstrap";
649
- 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.";
649
+ 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.";
650
650
  readonly businessInputSchema: {
651
651
  readonly type: "object";
652
652
  readonly properties: {
@@ -713,6 +713,78 @@ export declare const OPERATION_CATALOG: readonly [{
713
713
  };
714
714
  readonly description: "Optional verification commands, documents, or checkpoints to reference in the output.";
715
715
  };
716
+ readonly knowledgeSources: {
717
+ readonly type: "array";
718
+ readonly maxItems: 50;
719
+ 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.";
720
+ readonly items: {
721
+ readonly type: "object";
722
+ readonly required: readonly ["id", "kind", "title", "locator", "authority"];
723
+ readonly additionalProperties: false;
724
+ readonly properties: {
725
+ readonly id: {
726
+ readonly type: "string";
727
+ readonly pattern: "^[a-z0-9][a-z0-9-]*$";
728
+ readonly description: "Stable kebab-case handle that intentClaims cite, for example jira-payments.";
729
+ };
730
+ readonly kind: {
731
+ readonly type: "string";
732
+ readonly enum: readonly ["issue_tracker", "wiki", "specification", "design", "decision_log", "support", "chat", "repository_docs", "other"];
733
+ };
734
+ readonly title: {
735
+ readonly type: "string";
736
+ readonly minLength: 1;
737
+ };
738
+ readonly locator: {
739
+ readonly type: "string";
740
+ readonly minLength: 1;
741
+ readonly description: "Where the source lives: a URL, project key, space name, or repo-relative path.";
742
+ };
743
+ readonly authority: {
744
+ readonly type: "string";
745
+ readonly enum: readonly ["authoritative", "supporting", "stale"];
746
+ 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.";
747
+ };
748
+ readonly connector: {
749
+ readonly type: "string";
750
+ readonly description: "Optional name of the MCP server or tool the agent used to read the source.";
751
+ };
752
+ readonly notes: {
753
+ readonly type: "string";
754
+ };
755
+ };
756
+ };
757
+ };
758
+ readonly intentClaims: {
759
+ readonly type: "array";
760
+ readonly maxItems: 200;
761
+ 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.";
762
+ readonly items: {
763
+ readonly type: "object";
764
+ readonly required: readonly ["statement", "sourceId", "reference"];
765
+ readonly additionalProperties: false;
766
+ readonly properties: {
767
+ readonly statement: {
768
+ readonly type: "string";
769
+ readonly minLength: 1;
770
+ readonly description: "One normative statement in the source's meaning, for example 'Refunds must not exceed the original charge.'";
771
+ };
772
+ readonly sourceId: {
773
+ readonly type: "string";
774
+ readonly description: "The id of a declared knowledge source.";
775
+ };
776
+ readonly reference: {
777
+ readonly type: "string";
778
+ readonly minLength: 1;
779
+ readonly description: "Exact citation inside the source: a ticket key, page URL, or section anchor.";
780
+ };
781
+ readonly excerpt: {
782
+ readonly type: "string";
783
+ readonly description: "Optional short quote supporting the claim.";
784
+ };
785
+ };
786
+ };
787
+ };
716
788
  };
717
789
  };
718
790
  };
@@ -1520,6 +1592,50 @@ export declare const OPERATION_CATALOG: readonly [{
1520
1592
  readonly requiresProlog: true;
1521
1593
  readonly effects: readonly ["kb-read", "workspace-read"];
1522
1594
  readonly execute: typeof import("./check-executor.js").executeCheck;
1595
+ }, {
1596
+ readonly name: "kb_prepare_impact_review";
1597
+ readonly cliName: "prepare-impact-review";
1598
+ readonly description: "Prepare complete content-bound impact-review authoring inputs from the current staged snapshot or explicitly selected immutable Git commits. Returns strict reviewer schemas and an unauthored template; it does not decide, approve, sign, stage, or prove the review.";
1599
+ readonly businessInputSchema: {
1600
+ readonly type: "object";
1601
+ readonly additionalProperties: false;
1602
+ readonly required: readonly ["scope"];
1603
+ readonly properties: {
1604
+ readonly scope: {
1605
+ readonly oneOf: readonly [{
1606
+ readonly type: "object";
1607
+ readonly additionalProperties: false;
1608
+ readonly required: readonly ["kind"];
1609
+ readonly properties: {
1610
+ readonly kind: {
1611
+ readonly const: "staged";
1612
+ };
1613
+ };
1614
+ }, {
1615
+ readonly type: "object";
1616
+ readonly additionalProperties: false;
1617
+ readonly required: readonly ["kind", "baseCommit", "headCommit"];
1618
+ readonly properties: {
1619
+ readonly kind: {
1620
+ readonly const: "diff";
1621
+ };
1622
+ readonly baseCommit: {
1623
+ readonly type: "string";
1624
+ readonly pattern: "^(?:[a-f0-9]{40}|[a-f0-9]{64})$";
1625
+ };
1626
+ readonly headCommit: {
1627
+ readonly type: "string";
1628
+ readonly pattern: "^(?:[a-f0-9]{40}|[a-f0-9]{64})$";
1629
+ };
1630
+ };
1631
+ }];
1632
+ };
1633
+ };
1634
+ };
1635
+ readonly requiresProlog: false;
1636
+ readonly effects: readonly ["workspace-read", "kb-read"];
1637
+ readonly agentVisibleStructuredData: true;
1638
+ readonly execute: typeof import("./impact-review-preparation.js").executePrepareImpactReview;
1523
1639
  }, {
1524
1640
  readonly name: "kb_sparql_remote";
1525
1641
  readonly cliName: "sparql-remote";
@@ -1 +1 @@
1
- {"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../../../src/public/operations/catalog.ts"],"names":[],"mappings":"AA2BA,OAAO,KAAK,EACV,aAAa,EACb,aAAa,EACb,qBAAqB,EACtB,MAAM,YAAY,CAAC;AAEpB,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBe,CAAC;AAyF9C,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,aAAa,GAClB,qBAAqB,CA+BvB;AAQD,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,qBAAqB,GAAG,SAAS,EACvC,IAAI,EAAE,aAAa,GAClB,qBAAqB,CAKvB;AAED,wBAAgB,OAAO,CAAC,IAAI,EAAE,aAAa,GAAG,qBAAqB,CAElE;AAGD,wBAAgB,SAAS,IAAI,SAAS,qBAAqB,EAAE,CAE5D"}
@@ -2,6 +2,7 @@ import { OPERATION_DATA_SCHEMAS, declaredEffects, } from "./contracts.js";
2
2
  import { planBootstrapSpec } from "./specs/bootstrap.js";
3
3
  import { checkSpec } from "./specs/check.js";
4
4
  import { querySpec, searchSpec, statusSpec } from "./specs/discovery.js";
5
+ import { prepareImpactReviewSpec } from "./specs/impact-review-preparation.js";
5
6
  import { modelRequirementSpec, suggestPredicatesSpec, } from "./specs/modeling.js";
6
7
  import { deleteSpec, upsertSpec, validateUpsertSpec, } from "./specs/mutation.js";
7
8
  import { applyPlanSpec, compileIntentSpec } from "./specs/planning.js";
@@ -28,6 +29,7 @@ export const OPERATION_CATALOG = [
28
29
  upsertSpec,
29
30
  deleteSpec,
30
31
  checkSpec,
32
+ prepareImpactReviewSpec,
31
33
  sparqlRemoteSpec,
32
34
  compileIntentSpec,
33
35
  applyPlanSpec,
@@ -1 +1 @@
1
- {"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../src/public/operations/contracts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,0BAA0B,EAC1B,aAAa,EACd,MAAM,YAAY,CAAC;AAEpB,oEAAoE;AACpE,MAAM,MAAM,mBAAmB,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;AAwDpE;;uEAEuE;AACvE,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,mBAAmB,GAC1B,mBAAmB,CAMrB;AAED;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAC3C,MAAM,CAAC,aAAa,EAAE,mBAAmB,CAAC,CAyQ3C,CAAC;AAgDF,wBAAgB,uBAAuB,CACrC,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,SAAS;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,EAAE,EAClD,YAAY,EAAE,MAAM,GACnB,IAAI,CAIN;AAED,wBAAgB,eAAe,CAC7B,SAAS,EAAE,aAAa,EACxB,OAAO,EAAE,SAAS,eAAe,EAAE,GAClC,SAAS,0BAA0B,EAAE,CAoBvC"}
1
+ {"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../src/public/operations/contracts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,eAAe,EACf,0BAA0B,EAC1B,aAAa,EACd,MAAM,YAAY,CAAC;AAEpB,oEAAoE;AACpE,MAAM,MAAM,mBAAmB,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;AAsZpE;;uEAEuE;AACvE,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,mBAAmB,GAC1B,mBAAmB,CAMrB;AAED;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAC3C,MAAM,CAAC,aAAa,EAAE,mBAAmB,CAAC,CAkS3C,CAAC;AAiDF,wBAAgB,uBAAuB,C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