kibi-cli 0.19.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli-operation-loader.d.ts.map +1 -1
- package/dist/cli-operation-loader.js +53 -20
- package/dist/cli-operation-metadata.d.ts +20 -8
- package/dist/cli-operation-metadata.d.ts.map +1 -1
- package/dist/cli-operation-metadata.js +23 -8
- package/dist/cli-protocol.d.ts.map +1 -1
- package/dist/cli-protocol.js +38 -8
- package/dist/cli-register-foundation.d.ts.map +1 -1
- package/dist/cli-register-foundation.js +14 -2
- package/dist/cli-register-maintenance.d.ts.map +1 -1
- package/dist/cli-register-maintenance.js +26 -4
- package/dist/cli-register-reporting.d.ts.map +1 -1
- package/dist/cli-register-reporting.js +10 -0
- package/dist/cli-register-verification.d.ts +3 -0
- package/dist/cli-register-verification.d.ts.map +1 -0
- package/dist/cli-register-verification.js +16 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +2 -0
- package/dist/commands/aggregated-checks.d.ts +1 -2
- package/dist/commands/aggregated-checks.d.ts.map +1 -1
- package/dist/commands/aggregated-checks.js +14 -9
- package/dist/commands/branch.d.ts +36 -0
- package/dist/commands/branch.d.ts.map +1 -1
- package/dist/commands/branch.js +371 -40
- package/dist/commands/check.d.ts.map +1 -1
- package/dist/commands/check.js +20 -67
- package/dist/commands/discovery-shared.d.ts.map +1 -1
- package/dist/commands/discovery-shared.js +10 -19
- package/dist/commands/doctor.d.ts +4 -1
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +259 -24
- package/dist/commands/engine.d.ts.map +1 -1
- package/dist/commands/engine.js +10 -7
- package/dist/commands/gc.d.ts +5 -2
- package/dist/commands/gc.d.ts.map +1 -1
- package/dist/commands/gc.js +140 -71
- package/dist/commands/github-init.d.ts +56 -0
- package/dist/commands/github-init.d.ts.map +1 -0
- package/dist/commands/github-init.js +310 -0
- package/dist/commands/init-helpers.d.ts +1 -1
- package/dist/commands/init-helpers.d.ts.map +1 -1
- package/dist/commands/init-helpers.js +73 -25
- package/dist/commands/init.d.ts +2 -0
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +79 -24
- package/dist/commands/legacy-storage-migration.d.ts +54 -0
- package/dist/commands/legacy-storage-migration.d.ts.map +1 -0
- package/dist/commands/legacy-storage-migration.js +277 -0
- package/dist/commands/migrate.d.ts +7 -0
- package/dist/commands/migrate.d.ts.map +1 -1
- package/dist/commands/migrate.js +244 -91
- package/dist/commands/report.d.ts +24 -0
- package/dist/commands/report.d.ts.map +1 -0
- package/dist/commands/report.js +191 -0
- package/dist/commands/sync/cache.d.ts +16 -3
- package/dist/commands/sync/cache.d.ts.map +1 -1
- package/dist/commands/sync/cache.js +111 -4
- package/dist/commands/sync/discovery.d.ts +23 -2
- package/dist/commands/sync/discovery.d.ts.map +1 -1
- package/dist/commands/sync/discovery.js +196 -15
- package/dist/commands/sync/extraction.d.ts +8 -1
- package/dist/commands/sync/extraction.d.ts.map +1 -1
- package/dist/commands/sync/extraction.js +38 -4
- package/dist/commands/sync/manifest.d.ts +8 -5
- package/dist/commands/sync/manifest.d.ts.map +1 -1
- package/dist/commands/sync/manifest.js +142 -39
- package/dist/commands/sync/persistence.d.ts.map +1 -1
- package/dist/commands/sync/persistence.js +3 -0
- package/dist/commands/sync.d.ts +6 -0
- package/dist/commands/sync.d.ts.map +1 -1
- package/dist/commands/sync.js +304 -79
- package/dist/commands/verify.d.ts +10 -0
- package/dist/commands/verify.d.ts.map +1 -0
- package/dist/commands/verify.js +126 -0
- package/dist/diagnostics.d.ts +1 -1
- package/dist/diagnostics.d.ts.map +1 -1
- package/dist/engine.d.ts +96 -3
- package/dist/engine.d.ts.map +1 -1
- package/dist/engine.js +392 -23
- package/dist/env.d.ts.map +1 -1
- package/dist/env.js +5 -6
- package/dist/extractors/manifest.d.ts +8 -1
- package/dist/extractors/manifest.d.ts.map +1 -1
- package/dist/extractors/manifest.js +51 -9
- package/dist/extractors/markdown.d.ts +2 -1
- package/dist/extractors/markdown.d.ts.map +1 -1
- package/dist/extractors/markdown.js +21 -3
- package/dist/extractors/playwright-cases.d.ts +24 -0
- package/dist/extractors/playwright-cases.d.ts.map +1 -0
- package/dist/extractors/playwright-cases.js +126 -0
- package/dist/extractors/relationships.d.ts.map +1 -1
- package/dist/extractors/relationships.js +1 -0
- package/dist/extractors/symbol-coordinates.d.ts +81 -3
- package/dist/extractors/symbol-coordinates.d.ts.map +1 -1
- package/dist/extractors/symbol-coordinates.js +389 -51
- package/dist/extractors/symbols-coordinator.js +11 -1
- package/dist/intent-search.d.ts +60 -0
- package/dist/intent-search.d.ts.map +1 -0
- package/dist/intent-search.js +433 -0
- package/dist/operations/bootstrap/activation.d.ts.map +1 -0
- package/dist/operations/{autopilot → bootstrap}/activation.js +48 -31
- package/dist/operations/{autopilot → bootstrap}/candidate-helpers.d.ts.map +1 -1
- package/dist/operations/bootstrap/candidates.d.ts +4 -0
- package/dist/operations/{autopilot → bootstrap}/candidates.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/candidates.js +22 -8
- package/dist/operations/{autopilot → bootstrap}/discovery-evidence.d.ts +2 -2
- package/dist/operations/{autopilot → bootstrap}/discovery-evidence.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/discovery-evidence.js +46 -6
- package/dist/operations/{autopilot → bootstrap}/discovery.d.ts +1 -1
- package/dist/operations/bootstrap/discovery.d.ts.map +1 -0
- package/dist/operations/{autopilot → bootstrap}/discovery.js +21 -14
- package/dist/operations/bootstrap/generate.d.ts +8 -0
- package/dist/operations/bootstrap/generate.d.ts.map +1 -0
- package/dist/operations/bootstrap/generate.js +204 -0
- package/dist/operations/{autopilot → bootstrap}/guidance-actions.d.ts +2 -2
- package/dist/operations/{autopilot → bootstrap}/guidance-actions.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/guidance-actions.js +4 -4
- package/dist/operations/{autopilot → bootstrap}/guidance.d.ts +2 -2
- package/dist/operations/{autopilot → bootstrap}/guidance.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/guidance.js +2 -0
- package/dist/operations/{autopilot → bootstrap}/markdown-candidates.d.ts +2 -2
- package/dist/operations/{autopilot → bootstrap}/markdown-candidates.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/markdown-candidates.js +4 -3
- package/dist/operations/bootstrap/presentation.d.ts +15 -0
- package/dist/operations/bootstrap/presentation.d.ts.map +1 -0
- package/dist/operations/bootstrap/presentation.js +177 -0
- package/dist/operations/{autopilot → bootstrap}/requirement-claims.d.ts.map +1 -1
- package/dist/operations/{autopilot → bootstrap}/types.d.ts +63 -21
- package/dist/operations/bootstrap/types.d.ts.map +1 -0
- package/dist/operations/bootstrap/types.js +25 -0
- package/dist/operations/modeling/model-requirement.d.ts.map +1 -1
- package/dist/operations/modeling/model-requirement.js +4 -17
- package/dist/operations/modeling/predicate-applicability.d.ts +16 -0
- package/dist/operations/modeling/predicate-applicability.d.ts.map +1 -0
- package/dist/operations/modeling/predicate-applicability.js +276 -0
- package/dist/operations/modeling/predicate-applyplan.d.ts +13 -2
- package/dist/operations/modeling/predicate-applyplan.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-applyplan.js +100 -3
- package/dist/operations/modeling/predicate-bindings.d.ts +6 -0
- package/dist/operations/modeling/predicate-bindings.d.ts.map +1 -0
- package/dist/operations/modeling/predicate-bindings.js +122 -0
- package/dist/operations/modeling/predicate-catalog-4.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-catalog-4.js +155 -0
- package/dist/operations/modeling/predicate-inference-1.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-inference-1.js +8 -0
- package/dist/operations/modeling/predicate-inference-launcher.d.ts +10 -0
- package/dist/operations/modeling/predicate-inference-launcher.d.ts.map +1 -0
- package/dist/operations/modeling/predicate-inference-launcher.js +13 -0
- package/dist/operations/modeling/predicate-inference.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-inference.js +4 -0
- package/dist/operations/modeling/predicate-loader.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-loader.js +7 -0
- package/dist/operations/modeling/predicate-ranker.d.ts +8 -1
- package/dist/operations/modeling/predicate-ranker.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-ranker.js +156 -24
- package/dist/operations/modeling/predicate-score-3.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-score-3.js +6 -0
- package/dist/operations/modeling/predicate-types.d.ts +34 -0
- package/dist/operations/modeling/predicate-types.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-usage-hints-3.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-usage-hints-3.js +40 -0
- package/dist/operations/modeling/predicate-utils.d.ts.map +1 -1
- package/dist/operations/modeling/predicate-utils.js +2 -0
- package/dist/operations/modeling/suggest-predicates.d.ts +1 -1
- package/dist/operations/modeling/suggest-predicates.d.ts.map +1 -1
- package/dist/operations/modeling/suggest-predicates.js +170 -32
- package/dist/operations/mutation/delete.d.ts.map +1 -1
- package/dist/operations/mutation/delete.js +415 -19
- package/dist/operations/mutation/entity-projection.d.ts +11 -0
- package/dist/operations/mutation/entity-projection.d.ts.map +1 -0
- package/dist/operations/mutation/entity-projection.js +14 -0
- package/dist/operations/mutation/relationships.d.ts +10 -0
- package/dist/operations/mutation/relationships.d.ts.map +1 -1
- package/dist/operations/mutation/relationships.js +71 -1
- package/dist/operations/mutation/serialization.d.ts.map +1 -1
- package/dist/operations/mutation/serialization.js +1 -0
- package/dist/operations/mutation/source-authoring.d.ts +61 -0
- package/dist/operations/mutation/source-authoring.d.ts.map +1 -0
- package/dist/operations/mutation/source-authoring.js +543 -0
- package/dist/operations/mutation/symbol-compiler-lock.d.ts +51 -0
- package/dist/operations/mutation/symbol-compiler-lock.d.ts.map +1 -0
- package/dist/operations/mutation/symbol-compiler-lock.js +274 -0
- package/dist/operations/mutation/symbol-granularity.d.ts.map +1 -1
- package/dist/operations/mutation/symbol-granularity.js +34 -3
- package/dist/operations/mutation/symbol-refresh.d.ts +18 -1
- package/dist/operations/mutation/symbol-refresh.d.ts.map +1 -1
- package/dist/operations/mutation/symbol-refresh.js +225 -63
- package/dist/operations/mutation/types.d.ts +57 -1
- package/dist/operations/mutation/types.d.ts.map +1 -1
- package/dist/operations/mutation/upsert.d.ts.map +1 -1
- package/dist/operations/mutation/upsert.js +363 -24
- package/dist/operations/mutation/validation.d.ts.map +1 -1
- package/dist/operations/mutation/validation.js +1 -0
- package/dist/operations/planning/apply-plan.d.ts +117 -0
- package/dist/operations/planning/apply-plan.d.ts.map +1 -0
- package/dist/operations/planning/apply-plan.js +1437 -0
- package/dist/operations/planning/compile-intent.d.ts +106 -0
- package/dist/operations/planning/compile-intent.d.ts.map +1 -0
- package/dist/operations/planning/compile-intent.js +562 -0
- package/dist/operations/semantic-advisor/analyze-prose.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/analyze-prose.js +6 -2
- package/dist/operations/semantic-advisor/clauses.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/clauses.js +15 -2
- package/dist/operations/semantic-advisor/ingestion-boundary.d.ts.map +1 -1
- package/dist/operations/semantic-advisor/ingestion-boundary.js +7 -3
- package/dist/operations/semantic-advisor/predicate-rules-launcher.d.ts +51 -0
- package/dist/operations/semantic-advisor/predicate-rules-launcher.d.ts.map +1 -0
- package/dist/operations/semantic-advisor/predicate-rules-launcher.js +96 -0
- package/dist/operations/semantic-advisor/types.d.ts +13 -5
- package/dist/operations/semantic-advisor/types.d.ts.map +1 -1
- package/dist/operations/verification/ingest-verification.d.ts +29 -0
- package/dist/operations/verification/ingest-verification.d.ts.map +1 -0
- package/dist/operations/verification/ingest-verification.js +192 -0
- package/dist/prolog/codec.d.ts.map +1 -1
- package/dist/prolog/codec.js +2 -1
- package/dist/prolog.d.ts.map +1 -1
- package/dist/prolog.js +27 -8
- package/dist/public/branch-resolver.d.ts +1 -0
- package/dist/public/branch-resolver.d.ts.map +1 -1
- package/dist/public/branch-resolver.js +1 -0
- package/dist/public/check-types.d.ts +2 -2
- package/dist/public/check-types.d.ts.map +1 -1
- package/dist/public/check-types.js +16 -16
- package/dist/public/diagnostic-usage.d.ts.map +1 -1
- package/dist/public/diagnostic-usage.js +69 -1
- package/dist/public/distribution-parity.d.ts +1 -1
- package/dist/public/distribution-parity.d.ts.map +1 -1
- package/dist/public/distribution-parity.js +1 -0
- package/dist/public/ignore-policy.d.ts.map +1 -1
- package/dist/public/ignore-policy.js +16 -4
- package/dist/public/impact/coverage-depth-quality.d.ts +6 -1
- package/dist/public/impact/coverage-depth-quality.d.ts.map +1 -1
- package/dist/public/impact/coverage-depth-quality.js +21 -3
- package/dist/public/impact/full-kb-quality.d.ts +4 -2
- package/dist/public/impact/full-kb-quality.d.ts.map +1 -1
- package/dist/public/impact/full-kb-quality.js +61 -1
- package/dist/public/impact/manifest.d.ts.map +1 -1
- package/dist/public/impact/manifest.js +2 -5
- package/dist/public/operational-artifacts.d.ts.map +1 -1
- package/dist/public/operational-artifacts.js +7 -1
- package/dist/public/operations/catalog.d.ts +682 -67
- package/dist/public/operations/catalog.d.ts.map +1 -1
- package/dist/public/operations/catalog.js +126 -4
- package/dist/public/operations/check-executor.d.ts +2 -2
- package/dist/public/operations/check-executor.d.ts.map +1 -1
- package/dist/public/operations/check-executor.js +72 -13
- package/dist/public/operations/check-format-shared.d.ts +3 -0
- package/dist/public/operations/check-format-shared.d.ts.map +1 -1
- package/dist/public/operations/check-format-shared.js +3 -0
- package/dist/public/operations/check-helpers.d.ts +27 -2
- package/dist/public/operations/check-helpers.d.ts.map +1 -1
- package/dist/public/operations/check-helpers.js +62 -26
- package/dist/public/operations/contracts.d.ts +11 -0
- package/dist/public/operations/contracts.d.ts.map +1 -0
- package/dist/public/operations/contracts.js +325 -0
- package/dist/public/operations/discovery-executors.d.ts +37 -1
- package/dist/public/operations/discovery-executors.d.ts.map +1 -1
- package/dist/public/operations/discovery-executors.js +206 -6
- package/dist/public/operations/index.d.ts +9 -4
- package/dist/public/operations/index.d.ts.map +1 -1
- package/dist/public/operations/index.js +8 -3
- package/dist/public/operations/migration-plan.d.ts +101 -0
- package/dist/public/operations/migration-plan.d.ts.map +1 -0
- package/dist/public/operations/migration-plan.js +537 -0
- package/dist/public/operations/node-ports.d.ts.map +1 -1
- package/dist/public/operations/node-ports.js +68 -8
- package/dist/public/operations/prolog-json.d.ts +14 -0
- package/dist/public/operations/prolog-json.d.ts.map +1 -1
- package/dist/public/operations/prolog-json.js +44 -5
- package/dist/public/operations/repair-plan.d.ts.map +1 -1
- package/dist/public/operations/repair-plan.js +1 -0
- package/dist/public/operations/result-envelope.d.ts +13 -0
- package/dist/public/operations/result-envelope.d.ts.map +1 -0
- package/dist/public/operations/result-envelope.js +104 -0
- package/dist/public/operations/runtime-types.d.ts +97 -7
- package/dist/public/operations/runtime-types.d.ts.map +1 -1
- package/dist/public/operations/source-relationship-parity.d.ts +13 -0
- package/dist/public/operations/source-relationship-parity.d.ts.map +1 -0
- package/dist/public/operations/source-relationship-parity.js +162 -0
- package/dist/public/operations/specs/{autopilot.d.ts → bootstrap.d.ts} +9 -9
- package/dist/public/operations/specs/bootstrap.d.ts.map +1 -0
- package/dist/public/operations/specs/{autopilot.js → bootstrap.js} +8 -7
- package/dist/public/operations/specs/check.d.ts +4 -4
- package/dist/public/operations/specs/check.d.ts.map +1 -1
- package/dist/public/operations/specs/check.js +4 -3
- package/dist/public/operations/specs/discovery.d.ts +87 -3
- package/dist/public/operations/specs/discovery.d.ts.map +1 -1
- package/dist/public/operations/specs/discovery.js +53 -3
- package/dist/public/operations/specs/modeling.d.ts +3 -3
- package/dist/public/operations/specs/modeling.js +3 -3
- package/dist/public/operations/specs/mutation-schemas.d.ts +190 -47
- package/dist/public/operations/specs/mutation-schemas.d.ts.map +1 -1
- package/dist/public/operations/specs/mutation-schemas.js +3 -1
- package/dist/public/operations/specs/mutation.d.ts +42 -2
- package/dist/public/operations/specs/mutation.d.ts.map +1 -1
- package/dist/public/operations/specs/mutation.js +26 -2
- package/dist/public/operations/specs/planning.d.ts +270 -0
- package/dist/public/operations/specs/planning.d.ts.map +1 -0
- package/dist/public/operations/specs/planning.js +191 -0
- package/dist/public/operations/specs/reporting.d.ts +4 -1
- package/dist/public/operations/specs/reporting.d.ts.map +1 -1
- package/dist/public/operations/specs/reporting.js +46 -1
- package/dist/public/operations/specs/upsert.d.ts +204 -47
- package/dist/public/operations/specs/upsert.d.ts.map +1 -1
- package/dist/public/operations/specs/upsert.js +9 -0
- package/dist/public/operations/specs/verification.d.ts +78 -0
- package/dist/public/operations/specs/verification.d.ts.map +1 -0
- package/dist/public/operations/specs/verification.js +62 -0
- package/dist/public/operations/symbol-repair-plan.d.ts +11 -0
- package/dist/public/operations/symbol-repair-plan.d.ts.map +1 -0
- package/dist/public/operations/symbol-repair-plan.js +123 -0
- package/dist/public/operations/types.d.ts +52 -1
- package/dist/public/operations/types.d.ts.map +1 -1
- package/dist/public/playwright-case-id.d.ts +8 -0
- package/dist/public/playwright-case-id.d.ts.map +1 -0
- package/dist/public/playwright-case-id.js +25 -0
- package/dist/public/schemas/entity.d.ts.map +1 -1
- package/dist/public/schemas/entity.js +4 -2
- package/dist/public/skills/kibi-bootstrap/SKILL.md +58 -0
- package/dist/public/skills/kibi-bootstrap/resources/bootstrap.md +11 -0
- package/dist/public/skills/kibi-bootstrap/resources/branch-lifecycle.md +7 -0
- package/dist/public/skills/kibi-bootstrap/resources/operation-access.md +5 -0
- package/dist/public/skills/kibi-bootstrap/resources/source-authoring.md +8 -0
- package/dist/public/skills/kibi-freshness/SKILL.md +39 -9
- package/dist/public/skills/kibi-freshness/resources/branch-lifecycle.md +7 -0
- package/dist/public/skills/kibi-freshness/resources/operation-access.md +6 -0
- package/dist/public/skills/kibi-freshness/resources/source-authoring.md +7 -0
- package/dist/public/skills/kibi-traceability/SKILL.md +47 -47
- package/dist/public/skills/kibi-traceability/resources/branch-lifecycle.md +7 -0
- package/dist/public/skills/kibi-traceability/resources/operation-access.md +5 -0
- package/dist/public/skills/kibi-traceability/resources/source-authoring.md +6 -0
- package/dist/public/skills/kibi-traceability/resources/traceability.md +8 -0
- package/dist/public/skills/kibi-usage/SKILL.md +115 -239
- package/dist/public/skills/kibi-usage/resources/branch-lifecycle.md +31 -0
- package/dist/public/skills/kibi-usage/resources/kb-improvement.md +38 -0
- package/dist/public/skills/kibi-usage/resources/operation-access.md +36 -38
- package/dist/public/skills/kibi-usage/resources/relationship-directions.md +3 -3
- package/dist/public/skills/kibi-usage/resources/source-authoring.md +31 -0
- package/dist/public/skills/kibi-usage/resources/workflows.md +56 -3
- package/dist/public/symbol-granularity.d.ts +1 -1
- package/dist/public/symbol-granularity.d.ts.map +1 -1
- package/dist/public/symbol-granularity.js +1 -0
- package/dist/public/telemetry-acceptance.d.ts +7 -0
- package/dist/public/telemetry-acceptance.d.ts.map +1 -1
- package/dist/public/telemetry-acceptance.js +8 -1
- package/dist/public/telemetry-remediation.js +1 -1
- package/dist/public/verification-receipt.d.ts +206 -39
- package/dist/public/verification-receipt.d.ts.map +1 -1
- package/dist/public/verification-receipt.js +171 -4
- package/dist/relationships/shards.d.ts +16 -0
- package/dist/relationships/shards.d.ts.map +1 -1
- package/dist/relationships/shards.js +87 -2
- package/dist/report/brand.d.ts +19 -0
- package/dist/report/brand.d.ts.map +1 -0
- package/dist/report/brand.js +112 -0
- package/dist/report/html-report.d.ts +19 -0
- package/dist/report/html-report.d.ts.map +1 -0
- package/dist/report/html-report.js +963 -0
- package/dist/report/relative-time.d.ts +4 -0
- package/dist/report/relative-time.d.ts.map +1 -0
- package/dist/report/relative-time.js +46 -0
- package/dist/report/report-view.d.ts +17 -0
- package/dist/report/report-view.d.ts.map +1 -0
- package/dist/report/report-view.js +33 -0
- package/dist/report/repository.d.ts +35 -0
- package/dist/report/repository.d.ts.map +1 -0
- package/dist/report/repository.js +151 -0
- package/dist/runtime/cli-runtime.d.ts.map +1 -1
- package/dist/runtime/cli-runtime.js +82 -22
- package/dist/schemas/entity.schema.json +1148 -273
- package/dist/traceability/evidence-model.d.ts +2 -2
- package/dist/traceability/evidence-model.d.ts.map +1 -1
- package/dist/traceability/evidence-model.js +2 -2
- package/dist/traceability/git-staged.d.ts.map +1 -1
- package/dist/traceability/git-staged.js +15 -40
- package/dist/traceability/markdown-validate.d.ts.map +1 -1
- package/dist/traceability/markdown-validate.js +12 -7
- package/dist/traceability/staged-impact-contract.d.ts +3 -3
- package/dist/traceability/staged-impact-contract.d.ts.map +1 -1
- package/dist/traceability/staged-impact-contract.js +10 -38
- package/dist/traceability/staged-symbols-manifest.d.ts.map +1 -1
- package/dist/traceability/staged-symbols-manifest.js +8 -3
- package/dist/traceability/temp-kb.d.ts.map +1 -1
- package/dist/traceability/temp-kb.js +3 -0
- package/dist/types/entities.d.ts +3 -0
- package/dist/types/entities.d.ts.map +1 -1
- package/dist/utils/branch-resolver.d.ts +24 -10
- package/dist/utils/branch-resolver.d.ts.map +1 -1
- package/dist/utils/branch-resolver.js +121 -38
- package/dist/utils/branch-store-locator.d.ts +23 -0
- package/dist/utils/branch-store-locator.d.ts.map +1 -0
- package/dist/utils/branch-store-locator.js +90 -0
- package/dist/utils/branch-store.d.ts +15 -0
- package/dist/utils/branch-store.d.ts.map +1 -0
- package/dist/utils/branch-store.js +130 -0
- package/dist/utils/config.d.ts +39 -37
- package/dist/utils/config.d.ts.map +1 -1
- package/dist/utils/config.js +107 -119
- package/dist/utils/kb-manifest.d.ts +35 -0
- package/dist/utils/kb-manifest.d.ts.map +1 -0
- package/dist/utils/kb-manifest.js +154 -0
- package/dist/utils/kb-paths.d.ts +54 -0
- package/dist/utils/kb-paths.d.ts.map +1 -0
- package/dist/utils/kb-paths.js +125 -0
- package/dist/utils/manifest-paths.d.ts +4 -4
- package/dist/utils/manifest-paths.d.ts.map +1 -1
- package/dist/utils/manifest-paths.js +8 -56
- package/dist/utils/rule-registry.d.ts +48 -20
- package/dist/utils/rule-registry.d.ts.map +1 -1
- package/dist/utils/rule-registry.js +82 -77
- package/dist/utils/schema-version.d.ts +5 -5
- package/dist/utils/schema-version.d.ts.map +1 -1
- package/dist/utils/schema-version.js +26 -6
- package/dist/utils/strict-modeling.d.ts +0 -4
- package/dist/utils/strict-modeling.d.ts.map +1 -1
- package/dist/utils/strict-modeling.js +7 -8
- package/dist/verification/playwright-reporter.d.ts +21 -0
- package/dist/verification/playwright-reporter.d.ts.map +1 -0
- package/dist/verification/playwright-reporter.js +114 -0
- package/package.json +46 -7
- package/schema/config.json +2 -2
- package/schema/manifest.json +26 -0
- package/src/public/branch-resolver.ts +1 -0
- package/src/public/check-types.ts +22 -19
- package/src/public/diagnostic-usage.ts +79 -1
- package/src/public/distribution-parity.ts +1 -0
- package/src/public/ignore-policy.ts +16 -10
- package/src/public/impact/coverage-depth-quality.ts +36 -0
- package/src/public/impact/full-kb-quality.ts +118 -5
- package/src/public/impact/manifest.ts +2 -4
- package/src/public/operational-artifacts.ts +9 -1
- package/src/public/operations/catalog.ts +146 -9
- package/src/public/operations/check-executor.ts +102 -15
- package/src/public/operations/check-format-shared.ts +6 -0
- package/src/public/operations/check-helpers.ts +74 -35
- package/src/public/operations/contracts.ts +366 -0
- package/src/public/operations/discovery-executors.ts +299 -12
- package/src/public/operations/index.ts +9 -4
- package/src/public/operations/migration-plan.ts +740 -0
- package/src/public/operations/node-ports.ts +84 -10
- package/src/public/operations/prolog-json.ts +60 -5
- package/src/public/operations/repair-plan.ts +1 -0
- package/src/public/operations/result-envelope.ts +136 -0
- package/src/public/operations/runtime-types.ts +91 -5
- package/src/public/operations/source-relationship-parity.ts +226 -0
- package/src/public/operations/specs/{autopilot.ts → bootstrap.ts} +17 -16
- package/src/public/operations/specs/check.ts +4 -3
- package/src/public/operations/specs/discovery.ts +57 -3
- package/src/public/operations/specs/modeling.ts +3 -3
- package/src/public/operations/specs/mutation-schemas.ts +6 -1
- package/src/public/operations/specs/mutation.ts +27 -2
- package/src/public/operations/specs/planning.ts +234 -0
- package/src/public/operations/specs/reporting.ts +55 -1
- package/src/public/operations/specs/upsert.ts +10 -0
- package/src/public/operations/specs/verification.ts +78 -0
- package/src/public/operations/symbol-repair-plan.ts +164 -0
- package/src/public/operations/types.ts +62 -1
- package/src/public/playwright-case-id.ts +35 -0
- package/src/public/schemas/entity.ts +7 -2
- package/src/public/skills/kibi-bootstrap/SKILL.md +58 -0
- package/src/public/skills/kibi-bootstrap/resources/bootstrap.md +11 -0
- package/src/public/skills/kibi-bootstrap/resources/branch-lifecycle.md +7 -0
- package/src/public/skills/kibi-bootstrap/resources/operation-access.md +5 -0
- package/src/public/skills/kibi-bootstrap/resources/source-authoring.md +8 -0
- package/src/public/skills/kibi-freshness/SKILL.md +39 -9
- package/src/public/skills/kibi-freshness/resources/branch-lifecycle.md +7 -0
- package/src/public/skills/kibi-freshness/resources/operation-access.md +6 -0
- package/src/public/skills/kibi-freshness/resources/source-authoring.md +7 -0
- package/src/public/skills/kibi-traceability/SKILL.md +47 -47
- package/src/public/skills/kibi-traceability/resources/branch-lifecycle.md +7 -0
- package/src/public/skills/kibi-traceability/resources/operation-access.md +5 -0
- package/src/public/skills/kibi-traceability/resources/source-authoring.md +6 -0
- package/src/public/skills/kibi-traceability/resources/traceability.md +8 -0
- package/src/public/skills/kibi-usage/SKILL.md +115 -239
- package/src/public/skills/kibi-usage/resources/branch-lifecycle.md +31 -0
- package/src/public/skills/kibi-usage/resources/kb-improvement.md +38 -0
- package/src/public/skills/kibi-usage/resources/operation-access.md +36 -38
- package/src/public/skills/kibi-usage/resources/relationship-directions.md +3 -3
- package/src/public/skills/kibi-usage/resources/source-authoring.md +31 -0
- package/src/public/skills/kibi-usage/resources/workflows.md +56 -3
- package/src/public/symbol-granularity.ts +1 -0
- package/src/public/telemetry-acceptance.ts +16 -1
- package/src/public/telemetry-remediation.ts +1 -1
- package/src/public/verification-receipt.ts +248 -6
- package/src/schemas/entity.schema.json +1148 -273
- package/templates/github/kibi-badge.yml +86 -0
- package/templates/github/kibi-report.yml +84 -0
- package/dist/operations/autopilot/activation.d.ts.map +0 -1
- package/dist/operations/autopilot/candidates.d.ts +0 -4
- package/dist/operations/autopilot/discovery.d.ts.map +0 -1
- package/dist/operations/autopilot/generate.d.ts +0 -8
- package/dist/operations/autopilot/generate.d.ts.map +0 -1
- package/dist/operations/autopilot/generate.js +0 -112
- package/dist/operations/autopilot/presentation.d.ts +0 -13
- package/dist/operations/autopilot/presentation.d.ts.map +0 -1
- package/dist/operations/autopilot/presentation.js +0 -91
- package/dist/operations/autopilot/types.d.ts.map +0 -1
- package/dist/operations/autopilot/types.js +0 -8
- package/dist/public/operations/specs/autopilot.d.ts.map +0 -1
- package/dist/public/skills/init-kibi/SKILL.md +0 -62
- package/src/public/skills/init-kibi/SKILL.md +0 -62
- /package/dist/operations/{autopilot → bootstrap}/activation.d.ts +0 -0
- /package/dist/operations/{autopilot → bootstrap}/candidate-helpers.d.ts +0 -0
- /package/dist/operations/{autopilot → bootstrap}/candidate-helpers.js +0 -0
- /package/dist/operations/{autopilot → bootstrap}/requirement-claims.d.ts +0 -0
- /package/dist/operations/{autopilot → bootstrap}/requirement-claims.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prolog-json.d.ts","sourceRoot":"","sources":["../../../src/public/operations/prolog-json.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"prolog-json.d.ts","sourceRoot":"","sources":["../../../src/public/operations/prolog-json.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,MAAM,sBAAsB,GAAG,OAAO,GAAG,OAAO,CAAC;AAEvD;;;;;GAKG;AACH,qBAAa,wBAAyB,SAAQ,KAAK;IACjD,QAAQ,CAAC,IAAI,gCAAgC;IAC7C,QAAQ,CAAC,KAAK,EAAE,sBAAsB,CAAC;IACvC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,gBAAgB,EAAE,SAAS,MAAM,EAAE,CAAC;gBAG3C,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,sBAAsB,EAC7B,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,OAAO;CAiBjB;AAUD,wBAAsB,qBAAqB,CAAC,CAAC,EAC3C,MAAM,EAAE,UAAU,EAClB,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,CAAC,CAAC,CAqDZ;AAiBD,wBAAgB,YAAY,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAInD;AAED,wBAAgB,YAAY,CAAC,MAAM,CAAC,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,CAI/D"}
|
|
@@ -2,6 +2,30 @@ import path from "node:path";
|
|
|
2
2
|
import { getKbPlPathOverride } from "../../env.js";
|
|
3
3
|
import { resolveKbPlPath } from "../../prolog.js";
|
|
4
4
|
import { escapeAtom } from "../../prolog/codec.js";
|
|
5
|
+
/**
|
|
6
|
+
* A JSON operation result is transported through Prolog's answer printer and
|
|
7
|
+
* then through the engine frame. Keep decode failures typed and bounded: the
|
|
8
|
+
* raw binding may contain project-authored data and must never be copied into
|
|
9
|
+
* diagnostics wholesale.
|
|
10
|
+
*/
|
|
11
|
+
export class OperationJsonDecodeError extends Error {
|
|
12
|
+
code = "engine_result_invalid_json";
|
|
13
|
+
stage;
|
|
14
|
+
rawLength;
|
|
15
|
+
prefixCodePoints;
|
|
16
|
+
constructor(errorLabel, stage, rawJson, cause) {
|
|
17
|
+
const rawText = typeof rawJson === "string" ? rawJson : "";
|
|
18
|
+
const bindingType = typeof rawJson;
|
|
19
|
+
const message = cause instanceof Error ? cause.message : String(cause);
|
|
20
|
+
super(`${errorLabel} returned invalid JSON binding (stage=${stage}, bindingType=${bindingType}, length=${rawText.length}, prefixCodePoints=${JSON.stringify([...rawText].slice(0, 8).map((character) => character.codePointAt(0) ?? 0))}): ${message}`);
|
|
21
|
+
this.name = "OperationJsonDecodeError";
|
|
22
|
+
this.stage = stage;
|
|
23
|
+
this.rawLength = rawText.length;
|
|
24
|
+
this.prefixCodePoints = Object.freeze([...rawText]
|
|
25
|
+
.slice(0, 8)
|
|
26
|
+
.map((character) => character.codePointAt(0) ?? 0));
|
|
27
|
+
}
|
|
28
|
+
}
|
|
5
29
|
function resolveCoreModulePath(fileName) {
|
|
6
30
|
const genericOverride = getKbPlPathOverride();
|
|
7
31
|
return path.join(path.dirname(genericOverride ?? resolveKbPlPath()), fileName);
|
|
@@ -13,9 +37,10 @@ export async function runOperationJsonQuery(prolog, fileName, goal, errorLabel)
|
|
|
13
37
|
// use two serialized requests for production and retain the combined goal
|
|
14
38
|
// only for the repository's Bun-based one-shot tests.
|
|
15
39
|
const longLivedEngine = typeof prolog.storageStatus === "function";
|
|
16
|
-
const oneShotMode =
|
|
17
|
-
|
|
18
|
-
|
|
40
|
+
const oneShotMode = prolog.oneShotMode === true ||
|
|
41
|
+
(!longLivedEngine &&
|
|
42
|
+
process.env.NODE_ENV === "test" &&
|
|
43
|
+
typeof globalThis.Bun !== "undefined");
|
|
19
44
|
const typedStatusQuery = prolog.queryStatusJson;
|
|
20
45
|
const result = fileName === "status.pl" && typeof typedStatusQuery === "function"
|
|
21
46
|
? await typedStatusQuery.call(prolog)
|
|
@@ -29,9 +54,23 @@ export async function runOperationJsonQuery(prolog, fileName, goal, errorLabel)
|
|
|
29
54
|
if (rawJson === undefined) {
|
|
30
55
|
throw new Error(`${errorLabel} query returned no JsonString binding`);
|
|
31
56
|
}
|
|
32
|
-
|
|
57
|
+
if (typeof rawJson !== "string") {
|
|
58
|
+
throw new OperationJsonDecodeError(errorLabel, "outer", rawJson, new TypeError("JsonString binding is not a string"));
|
|
59
|
+
}
|
|
60
|
+
let parsed;
|
|
61
|
+
try {
|
|
62
|
+
parsed = JSON.parse(rawJson);
|
|
63
|
+
}
|
|
64
|
+
catch (error) {
|
|
65
|
+
throw new OperationJsonDecodeError(errorLabel, "outer", rawJson, error);
|
|
66
|
+
}
|
|
33
67
|
if (typeof parsed === "string") {
|
|
34
|
-
|
|
68
|
+
try {
|
|
69
|
+
parsed = JSON.parse(parsed);
|
|
70
|
+
}
|
|
71
|
+
catch (error) {
|
|
72
|
+
throw new OperationJsonDecodeError(errorLabel, "inner", parsed, error);
|
|
73
|
+
}
|
|
35
74
|
}
|
|
36
75
|
return parsed;
|
|
37
76
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"repair-plan.d.ts","sourceRoot":"","sources":["../../../src/public/operations/repair-plan.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,mBAAmB,EAAG,qBAA8B,CAAC;AAElE,KAAK,qBAAqB,GAAG;IAC3B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,aAAa,EAAE,SAAS,MAAM,EAAE,CAAC;IAC1C,QAAQ,CAAC,eAAe,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5C,QAAQ,CAAC,WAAW,EAChB,iCAAiC,GACjC,+BAA+B,GAC/B,mBAAmB,GACnB,6BAA6B,GAC7B,mBAAmB,GACnB,kBAAkB,CAAC;CACxB,CAAC;AAEF,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4KiD,CAAC;AAErE,KAAK,WAAW,GAAG,MAAM,OAAO,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"repair-plan.d.ts","sourceRoot":"","sources":["../../../src/public/operations/repair-plan.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,mBAAmB,EAAG,qBAA8B,CAAC;AAElE,KAAK,qBAAqB,GAAG;IAC3B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ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KAC9C,CAAC;IACF,QAAQ,CAAC,OAAO,EAAE;QAChB,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;QAClC,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;QAC5B,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAC;QACjC,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;KACpC,CAAC;IACF,QAAQ,CAAC,OAAO,EAAE,SAAS,eAAe,EAAE,CAAC;IAC7C,QAAQ,CAAC,WAAW,EAAE,SAAS,MAAM,EAAE,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,QAAQ,CAAC,EAAE,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,CAAC;IACxC,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAClC,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,KAAK,qBAAqB,GAAG;IAC3B,QAAQ,CAAC,OAAO,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACpD,QAAQ,CAAC,IAAI,CAAC,EAAE,SAAS,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EAAE,CAAC;CAC9D,CAAC;AA2IF,wBAAgB,eAAe,CAC7B,OAAO,EAAE,qBAAqB,EAC9B,KAAK,EAAE,eAAe,EACtB,YAAY,EAAE,MAAM,GACnB,UAAU,GAAG,SAAS,CA4FxB"}
|
|
@@ -203,6 +203,7 @@ const GAP_STAGE = {
|
|
|
203
203
|
stale_verification_receipt: "passing_e2e",
|
|
204
204
|
failed_verification_receipt: "passing_e2e",
|
|
205
205
|
invalid_verification_receipt: "passing_e2e",
|
|
206
|
+
verification_contract_mismatch: "passing_e2e",
|
|
206
207
|
verification_snapshot_unavailable: "passing_e2e",
|
|
207
208
|
missing_executable_test_symbol: "executable_symbols",
|
|
208
209
|
missing_production_symbol: "production_symbols",
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { KibiResult, OperationEffect, OperationName } from "./types.js";
|
|
2
|
+
export declare const KIBI_PROTOCOL_VERSION: 1;
|
|
3
|
+
export declare function resultVersion(spec: {
|
|
4
|
+
readonly name: OperationName | string;
|
|
5
|
+
readonly resultVersion?: string;
|
|
6
|
+
}): string;
|
|
7
|
+
export declare function toKibiResult<T>(spec: {
|
|
8
|
+
readonly name: OperationName | string;
|
|
9
|
+
readonly effects: readonly OperationEffect[];
|
|
10
|
+
readonly resultVersion?: string;
|
|
11
|
+
}, data: T, options?: Partial<Pick<KibiResult<T>, "status" | "diagnostics" | "nextActions" | "error">>): KibiResult<T>;
|
|
12
|
+
export declare function operationData(value: unknown): unknown;
|
|
13
|
+
//# sourceMappingURL=result-envelope.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"result-envelope.d.ts","sourceRoot":"","sources":["../../../src/public/operations/result-envelope.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE7E,eAAO,MAAM,qBAAqB,EAAG,CAAU,CAAC;AAwFhD,wBAAgB,aAAa,CAAC,IAAI,EAAE;IAClC,QAAQ,CAAC,IAAI,EAAE,aAAa,GAAG,MAAM,CAAC;IACtC,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;CACjC,GAAG,MAAM,CAET;AAED,wBAAgB,YAAY,CAAC,CAAC,EAC5B,IAAI,EAAE;IACJ,QAAQ,CAAC,IAAI,EAAE,aAAa,GAAG,MAAM,CAAC;IACtC,QAAQ,CAAC,OAAO,EAAE,SAAS,eAAe,EAAE,CAAC;IAC7C,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;CACjC,EACD,IAAI,EAAE,CAAC,EACP,OAAO,GAAE,OAAO,CACd,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,QAAQ,GAAG,aAAa,GAAG,aAAa,GAAG,OAAO,CAAC,CACnE,GACL,UAAU,CAAC,CAAC,CAAC,CAqBf;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAKrD"}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
export const KIBI_PROTOCOL_VERSION = 1;
|
|
2
|
+
function record(value) {
|
|
3
|
+
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
4
|
+
}
|
|
5
|
+
function diagnostics(value) {
|
|
6
|
+
if (!Array.isArray(value))
|
|
7
|
+
return [];
|
|
8
|
+
return value.flatMap((entry) => {
|
|
9
|
+
if (typeof entry === "string")
|
|
10
|
+
return [{ message: entry, severity: "warning" }];
|
|
11
|
+
if (!record(entry) || typeof entry.message !== "string")
|
|
12
|
+
return [];
|
|
13
|
+
return [entry];
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
function nextActions(value) {
|
|
17
|
+
if (!Array.isArray(value))
|
|
18
|
+
return [];
|
|
19
|
+
return value.flatMap((entry) => {
|
|
20
|
+
if (!record(entry) ||
|
|
21
|
+
typeof entry.operation !== "string" ||
|
|
22
|
+
typeof entry.reason !== "string")
|
|
23
|
+
return [];
|
|
24
|
+
return [
|
|
25
|
+
{
|
|
26
|
+
operation: entry.operation,
|
|
27
|
+
input: entry.input,
|
|
28
|
+
reason: entry.reason,
|
|
29
|
+
required: entry.required === true,
|
|
30
|
+
},
|
|
31
|
+
];
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
function effectStatus(effect, data) {
|
|
35
|
+
const failures = data?.effectFailures;
|
|
36
|
+
if (Array.isArray(failures)) {
|
|
37
|
+
const failure = failures.find((entry) => record(entry) && entry.kind === effect);
|
|
38
|
+
if (record(failure)) {
|
|
39
|
+
return {
|
|
40
|
+
kind: effect,
|
|
41
|
+
status: "failed",
|
|
42
|
+
detail: failure.detail,
|
|
43
|
+
...(typeof failure.errorCode === "string"
|
|
44
|
+
? { errorCode: failure.errorCode }
|
|
45
|
+
: {}),
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
return { kind: effect, status: "completed" };
|
|
50
|
+
}
|
|
51
|
+
function extraFailedEffects(declared, data) {
|
|
52
|
+
const failures = data?.effectFailures;
|
|
53
|
+
if (!Array.isArray(failures))
|
|
54
|
+
return [];
|
|
55
|
+
const seen = new Set(declared);
|
|
56
|
+
return failures.flatMap((entry) => {
|
|
57
|
+
if (!record(entry) ||
|
|
58
|
+
typeof entry.kind !== "string" ||
|
|
59
|
+
seen.has(entry.kind)) {
|
|
60
|
+
return [];
|
|
61
|
+
}
|
|
62
|
+
seen.add(entry.kind);
|
|
63
|
+
return [
|
|
64
|
+
{
|
|
65
|
+
kind: entry.kind,
|
|
66
|
+
status: "failed",
|
|
67
|
+
detail: entry.detail,
|
|
68
|
+
...(typeof entry.errorCode === "string"
|
|
69
|
+
? { errorCode: entry.errorCode }
|
|
70
|
+
: {}),
|
|
71
|
+
},
|
|
72
|
+
];
|
|
73
|
+
});
|
|
74
|
+
}
|
|
75
|
+
export function resultVersion(spec) {
|
|
76
|
+
return spec.resultVersion ?? `kibi.${spec.name}.v1`;
|
|
77
|
+
}
|
|
78
|
+
export function toKibiResult(spec, data, options = {}) {
|
|
79
|
+
const row = record(data) ? data : undefined;
|
|
80
|
+
const status = options.status ??
|
|
81
|
+
(row?.status === "committed_with_repairs"
|
|
82
|
+
? "committed_with_repairs"
|
|
83
|
+
: "success");
|
|
84
|
+
return {
|
|
85
|
+
kibiProtocol: KIBI_PROTOCOL_VERSION,
|
|
86
|
+
operation: spec.name,
|
|
87
|
+
resultVersion: resultVersion(spec),
|
|
88
|
+
status,
|
|
89
|
+
data,
|
|
90
|
+
effects: [
|
|
91
|
+
...spec.effects.map((effect) => effectStatus(effect, row)),
|
|
92
|
+
...extraFailedEffects(spec.effects, row),
|
|
93
|
+
],
|
|
94
|
+
diagnostics: options.diagnostics ?? diagnostics(row?.diagnostics),
|
|
95
|
+
nextActions: options.nextActions ?? nextActions(row?.nextActions),
|
|
96
|
+
...(options.error ? { error: options.error } : {}),
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
export function operationData(value) {
|
|
100
|
+
if (record(value) && "structuredContent" in value) {
|
|
101
|
+
return value.structuredContent;
|
|
102
|
+
}
|
|
103
|
+
return value;
|
|
104
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { BranchAttachment } from "../../utils/branch-resolver.js";
|
|
1
2
|
import type { OperationEffect } from "./types.js";
|
|
2
3
|
export type { OperationEffect } from "./types.js";
|
|
3
4
|
export type PrologQueryResult = {
|
|
@@ -28,15 +29,78 @@ export type PrologSearchQueryResult = Readonly<{
|
|
|
28
29
|
entities: readonly Record<string, unknown>[];
|
|
29
30
|
count: number;
|
|
30
31
|
}>;
|
|
32
|
+
/** Goal-free, versioned commands accepted by the journaled engine. */
|
|
33
|
+
export type EngineCommandV1 = Readonly<{
|
|
34
|
+
version: 1;
|
|
35
|
+
kind: "status";
|
|
36
|
+
}> | Readonly<{
|
|
37
|
+
version: 1;
|
|
38
|
+
kind: "entities";
|
|
39
|
+
type?: string;
|
|
40
|
+
id?: string;
|
|
41
|
+
tags?: readonly string[];
|
|
42
|
+
sourceFile?: string;
|
|
43
|
+
limit: number;
|
|
44
|
+
offset: number;
|
|
45
|
+
}> | Readonly<{
|
|
46
|
+
version: 1;
|
|
47
|
+
kind: "search";
|
|
48
|
+
query: string;
|
|
49
|
+
type?: string;
|
|
50
|
+
limit: number;
|
|
51
|
+
offset: number;
|
|
52
|
+
}> | Readonly<{
|
|
53
|
+
version: 1;
|
|
54
|
+
kind: "checkpoint";
|
|
55
|
+
}> | Readonly<{
|
|
56
|
+
version: 1;
|
|
57
|
+
kind: "compact";
|
|
58
|
+
}> | Readonly<{
|
|
59
|
+
version: 1;
|
|
60
|
+
kind: "save";
|
|
61
|
+
}> | Readonly<{
|
|
62
|
+
version: 1;
|
|
63
|
+
kind: "check";
|
|
64
|
+
rule?: string;
|
|
65
|
+
}> | Readonly<{
|
|
66
|
+
version: 1;
|
|
67
|
+
kind: "relationship";
|
|
68
|
+
action: "assert" | "retract";
|
|
69
|
+
type: string;
|
|
70
|
+
from: string;
|
|
71
|
+
to: string;
|
|
72
|
+
}> | Readonly<{
|
|
73
|
+
version: 1;
|
|
74
|
+
kind: "persistence";
|
|
75
|
+
action: "checkpoint" | "compact" | "save" | "export";
|
|
76
|
+
targetDirectory?: string;
|
|
77
|
+
}> | Readonly<{
|
|
78
|
+
version: 1;
|
|
79
|
+
kind: "lifecycle";
|
|
80
|
+
action: "stop" | "cancel";
|
|
81
|
+
requestId?: number;
|
|
82
|
+
}> | Readonly<{
|
|
83
|
+
version: 1;
|
|
84
|
+
kind: "stop";
|
|
85
|
+
}> | Readonly<{
|
|
86
|
+
version: 1;
|
|
87
|
+
kind: "cancel";
|
|
88
|
+
requestId: number;
|
|
89
|
+
}>;
|
|
90
|
+
export interface EnginePort {
|
|
91
|
+
execute<T = PrologQueryResult>(command: EngineCommandV1, signal?: AbortSignal): Promise<T>;
|
|
92
|
+
}
|
|
31
93
|
export interface PrologPort {
|
|
32
|
-
query(goal: string): Promise<PrologQueryResult>;
|
|
94
|
+
query(goal: string, signal?: AbortSignal): Promise<PrologQueryResult>;
|
|
95
|
+
/** True when each query is isolated and must include its module load. */
|
|
96
|
+
oneShotMode?: boolean;
|
|
33
97
|
/** Optional index-backed page query supplied by the journaled engine. */
|
|
34
|
-
queryEntities?(input: PrologEntityQueryInput): Promise<PrologEntityQueryResult>;
|
|
98
|
+
queryEntities?(input: PrologEntityQueryInput, signal?: AbortSignal): Promise<PrologEntityQueryResult>;
|
|
35
99
|
/** Optional normalized-token candidate lookup supplied by the engine. */
|
|
36
|
-
searchEntities?(input: PrologSearchQueryInput): Promise<PrologSearchQueryResult>;
|
|
100
|
+
searchEntities?(input: PrologSearchQueryInput, signal?: AbortSignal): Promise<PrologSearchQueryResult>;
|
|
37
101
|
nextSolution(): Promise<PrologQueryResult | null>;
|
|
38
102
|
invalidateCache?(): void;
|
|
39
|
-
save(): Promise<PrologQueryResult>;
|
|
103
|
+
save(signal?: AbortSignal): Promise<PrologQueryResult>;
|
|
40
104
|
/** Present on the journaled engine; used to distinguish a persistent port from one-shot SWI. */
|
|
41
105
|
storageStatus?(): Promise<PrologQueryResult>;
|
|
42
106
|
/** Typed public freshness query; avoids exposing module loading over RPC. */
|
|
@@ -49,19 +113,37 @@ export type FilesystemStat = {
|
|
|
49
113
|
export interface FilesystemPort {
|
|
50
114
|
readFile(path: string): Promise<string>;
|
|
51
115
|
writeFile(path: string, data: string): Promise<void>;
|
|
116
|
+
/** Optional workspace globbing used by source-posture classifiers. */
|
|
117
|
+
glob?(patterns: readonly string[], options: {
|
|
118
|
+
readonly cwd: string;
|
|
119
|
+
readonly includeIgnored?: boolean;
|
|
120
|
+
}): Promise<readonly string[]>;
|
|
121
|
+
/** Replace a file atomically when the host filesystem supports it. */
|
|
122
|
+
rename?(from: string, to: string): Promise<void>;
|
|
52
123
|
mkdir(path: string): Promise<void>;
|
|
53
124
|
stat(path: string): Promise<FilesystemStat>;
|
|
125
|
+
/** Optional destructive primitive used only to roll back newly-created files. */
|
|
126
|
+
unlink?(path: string): Promise<void>;
|
|
54
127
|
}
|
|
55
128
|
export interface GitPort {
|
|
56
|
-
|
|
57
|
-
|
|
129
|
+
/** Optional low-level Git probes; the journaled runtime may provide them. */
|
|
130
|
+
revParse?(...args: readonly string[]): Promise<string>;
|
|
131
|
+
showToplevel?(): Promise<string>;
|
|
58
132
|
workspaceSnapshot?(workspaceRoot: string): Promise<WorkspaceSnapshot>;
|
|
59
133
|
}
|
|
60
134
|
export type WorkspaceSnapshot = Readonly<{
|
|
61
|
-
version: "kibi.workspace-snapshot.
|
|
135
|
+
version: "kibi.workspace-snapshot.v2";
|
|
62
136
|
hash: string;
|
|
137
|
+
/** True only when at least one change can alter the verification snapshot. */
|
|
63
138
|
dirty: boolean;
|
|
64
139
|
fileCount: number;
|
|
140
|
+
readonly changes?: readonly {
|
|
141
|
+
readonly path: string;
|
|
142
|
+
readonly status: string;
|
|
143
|
+
readonly snapshotRelevant: boolean;
|
|
144
|
+
}[];
|
|
145
|
+
readonly changeCount?: number;
|
|
146
|
+
readonly changesTruncated?: boolean;
|
|
65
147
|
}>;
|
|
66
148
|
export interface NetworkPort {
|
|
67
149
|
fetch(input: string | URL, init?: RequestInit): Promise<Response>;
|
|
@@ -81,9 +163,17 @@ export type OperationContext = {
|
|
|
81
163
|
readonly signal: AbortSignal;
|
|
82
164
|
readonly clock: Clock;
|
|
83
165
|
readonly prolog?: PrologPort;
|
|
166
|
+
readonly engine?: EnginePort;
|
|
167
|
+
/** Lazily acquire the branch engine for operations that may start without Prolog. */
|
|
168
|
+
readonly ensureProlog?: () => Promise<PrologPort>;
|
|
84
169
|
readonly fs?: FilesystemPort;
|
|
170
|
+
/** Whether filesystem-capable mutations must author tracked source files. */
|
|
171
|
+
readonly sourceFirst?: boolean;
|
|
172
|
+
/** Internal apply-plan capability: source bytes were already approved/published. */
|
|
173
|
+
readonly sourcePlanApplication?: boolean;
|
|
85
174
|
readonly git?: GitPort;
|
|
86
175
|
readonly net?: NetworkPort;
|
|
176
|
+
readonly branchAttachment?: BranchAttachment;
|
|
87
177
|
};
|
|
88
178
|
export interface RuntimeOperationSpec<TInput = unknown, TResult = unknown> {
|
|
89
179
|
readonly name: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime-types.d.ts","sourceRoot":"","sources":["../../../src/public/operations/runtime-types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,YAAY,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,iBAAi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KAAK,EAAE,OAAO,CAAA;CAAE,CAAC;AAG1D,MAAM,WAAW,gBAAgB;IAC/B,IAAI,CACF,IAAI,EAAE,oBAAoB,CAAC,OAAO,EAAE,OAAO,CAAC,EAC5C,IAAI,CAAC,EAAE,cAAc,GACpB,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAC7B,YAAY,CACV,IAAI,EAAE,oBAAoB,CAAC,OAAO,EAAE,OAAO,CAAC,EAC5C,OAAO,EAAE,gBAAgB,GACxB,OAAO,CAAC,IAAI,CAAC,CAAC;IACjB,KAAK,CAAC,OAAO,EAAE,gBAAgB,EAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC5E;AAGD,wBAAsB,gBAAgB,CAAC,MAAM,EAAE,OAAO,EACpD,OAAO,EAAE,gBAAgB,EACzB,IAAI,EAAE,oBAAoB,CAAC,MAAM,EAAE,OAAO,CAAC,EAC3C,KAAK,EAAE,MAAM,EACb,IAAI,CAAC,EAAE,cAAc,GACpB,OAAO,CAAC,OAAO,CAAC,CAclB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { Violation } from "../check-types.js";
|
|
2
|
+
import type { PrologPort } from "./runtime-types.js";
|
|
3
|
+
export type RelationshipParityRecord = Readonly<{
|
|
4
|
+
type: string;
|
|
5
|
+
from: string;
|
|
6
|
+
to: string;
|
|
7
|
+
source?: string;
|
|
8
|
+
ownership?: "authored" | "runtime";
|
|
9
|
+
}>;
|
|
10
|
+
export declare function compareRelationshipParity(authored: readonly RelationshipParityRecord[], compiled: readonly RelationshipParityRecord[]): Violation[];
|
|
11
|
+
export declare function parseCompiledRelationshipRows(type: string, rows: string): RelationshipParityRecord[];
|
|
12
|
+
export declare function collectSourceRelationshipParityViolations(workspaceRoot: string, prolog: PrologPort): Promise<Violation[]>;
|
|
13
|
+
//# sourceMappingURL=source-relationship-parity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"source-relationship-parity.d.ts","sourceRoot":"","sources":["../../../src/public/operations/source-relationship-parity.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,MAAM,wBAAwB,GAAG,QAAQ,CAAC;IAC9C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC;CACpC,CAAC,CAAC;AAaH,wBAAgB,yBAAyB,CACvC,QAAQ,EAAE,SAAS,wBAAwB,EAAE,EAC7C,QAAQ,EAAE,SAAS,wBAAwB,EAAE,GAC5C,SAAS,EAAE,CAwDb;AAuCD,wBAAgB,6BAA6B,CAC3C,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,GACX,wBAAwB,EAAE,CAmB5B;AAaD,wBAAsB,yCAAyC,CAC7D,aAAa,EAAE,MAAM,EACrB,MAAM,EAAE,UAAU,GACjB,OAAO,CAAC,SAAS,EAAE,CAAC,CA2DtB"}
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import { execFileSync } from "node:child_process";
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
import { discoverSourceFiles } from "../../commands/sync/discovery.js";
|
|
4
|
+
import { processExtractions } from "../../commands/sync/extraction.js";
|
|
5
|
+
import { RELATIONSHIP_TYPES } from "../../operations/mutation/relationships.js";
|
|
6
|
+
import { parseListOfLists, parsePrologValue } from "../../prolog/codec.js";
|
|
7
|
+
import { readAllShards } from "../../relationships/shards.js";
|
|
8
|
+
function relationshipKey(relationship) {
|
|
9
|
+
return `${relationship.type}\u0000${relationship.from}\u0000${relationship.to}`;
|
|
10
|
+
}
|
|
11
|
+
function relationshipLabel(relationship) {
|
|
12
|
+
return `${relationship.type} ${relationship.from}->${relationship.to}`;
|
|
13
|
+
}
|
|
14
|
+
// implements REQ-kibi-source-relationship-parity
|
|
15
|
+
export function compareRelationshipParity(authored, compiled) {
|
|
16
|
+
const authoredByKey = new Map();
|
|
17
|
+
const compiledByKey = new Map();
|
|
18
|
+
for (const relationship of authored) {
|
|
19
|
+
authoredByKey.set(relationshipKey(relationship), relationship);
|
|
20
|
+
}
|
|
21
|
+
for (const relationship of compiled) {
|
|
22
|
+
compiledByKey.set(relationshipKey(relationship), relationship);
|
|
23
|
+
}
|
|
24
|
+
const violations = [];
|
|
25
|
+
for (const [key, relationship] of authoredByKey) {
|
|
26
|
+
if (compiledByKey.has(key))
|
|
27
|
+
continue;
|
|
28
|
+
violations.push({
|
|
29
|
+
rule: "source-relationship-parity",
|
|
30
|
+
entityId: relationship.from,
|
|
31
|
+
description: `Authored relationship is missing from the compiled KB: ${relationshipLabel(relationship)}`,
|
|
32
|
+
suggestion: "Run kibi sync after resolving semantic/source errors; do not delete authored links merely to make the compiled snapshot pass.",
|
|
33
|
+
...(relationship.source !== undefined
|
|
34
|
+
? { source: relationship.source }
|
|
35
|
+
: {}),
|
|
36
|
+
evidence: {
|
|
37
|
+
direction: "authored_to_compiled",
|
|
38
|
+
relationship: {
|
|
39
|
+
type: relationship.type,
|
|
40
|
+
from: relationship.from,
|
|
41
|
+
to: relationship.to,
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
for (const [key, relationship] of compiledByKey) {
|
|
47
|
+
if (authoredByKey.has(key))
|
|
48
|
+
continue;
|
|
49
|
+
if (relationship.ownership === "runtime")
|
|
50
|
+
continue;
|
|
51
|
+
violations.push({
|
|
52
|
+
rule: "source-relationship-parity",
|
|
53
|
+
entityId: relationship.from,
|
|
54
|
+
description: `Compiled relationship has no authored Markdown or relationship-shard source: ${relationshipLabel(relationship)}`,
|
|
55
|
+
suggestion: "Restore the canonical authored relationship through kb_upsert, or remove the stale compiled edge through kb_delete after dependency review.",
|
|
56
|
+
evidence: {
|
|
57
|
+
direction: "compiled_to_authored",
|
|
58
|
+
relationship: {
|
|
59
|
+
type: relationship.type,
|
|
60
|
+
from: relationship.from,
|
|
61
|
+
to: relationship.to,
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
return violations.sort((left, right) => `${left.entityId}\u0000${left.description}`.localeCompare(`${right.entityId}\u0000${right.description}`));
|
|
67
|
+
}
|
|
68
|
+
function isGitWorkspace(workspaceRoot) {
|
|
69
|
+
try {
|
|
70
|
+
return (execFileSync("git", ["-C", workspaceRoot, "rev-parse", "--is-inside-work-tree"], {
|
|
71
|
+
encoding: "utf8",
|
|
72
|
+
stdio: ["ignore", "pipe", "ignore"],
|
|
73
|
+
}).trim() === "true");
|
|
74
|
+
}
|
|
75
|
+
catch {
|
|
76
|
+
return false;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
async function compiledRelationships(prolog) {
|
|
80
|
+
const relationships = [];
|
|
81
|
+
for (const type of RELATIONSHIP_TYPES) {
|
|
82
|
+
const result = await prolog.query(`findall([From,To,Source], (kb_relationship(${type}, From, To), (kb_entity(From, _, Props), memberchk(source=RawSource, Props) -> normalize_term_atom(RawSource, Source) ; Source='')), Rows)`);
|
|
83
|
+
if (!result.success) {
|
|
84
|
+
throw new Error(`Unable to inspect compiled ${type} relationships: ${result.error ?? "query failed"}`);
|
|
85
|
+
}
|
|
86
|
+
relationships.push(...parseCompiledRelationshipRows(type, result.bindings.Rows ?? "[]"));
|
|
87
|
+
}
|
|
88
|
+
return relationships;
|
|
89
|
+
}
|
|
90
|
+
export function parseCompiledRelationshipRows(type, rows) {
|
|
91
|
+
return parseListOfLists(rows).flatMap(([rawFrom, rawTo, rawSource]) => {
|
|
92
|
+
const from = String(parsePrologValue(rawFrom ?? ""));
|
|
93
|
+
const to = String(parsePrologValue(rawTo ?? ""));
|
|
94
|
+
const source = String(parsePrologValue(rawSource ?? ""));
|
|
95
|
+
if (!from || !to)
|
|
96
|
+
return [];
|
|
97
|
+
return [
|
|
98
|
+
{
|
|
99
|
+
type,
|
|
100
|
+
from,
|
|
101
|
+
to,
|
|
102
|
+
...(source ? { source } : {}),
|
|
103
|
+
ownership: source && /^[a-z][a-z0-9+.-]*:\/\//i.test(source)
|
|
104
|
+
? "runtime"
|
|
105
|
+
: "authored",
|
|
106
|
+
},
|
|
107
|
+
];
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
function authoredRelationship(relationship, source) {
|
|
111
|
+
return {
|
|
112
|
+
...relationship,
|
|
113
|
+
source: source.replaceAll("\\", "/"),
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
// implements REQ-kibi-source-relationship-parity
|
|
117
|
+
export async function collectSourceRelationshipParityViolations(workspaceRoot, prolog) {
|
|
118
|
+
if (!isGitWorkspace(workspaceRoot))
|
|
119
|
+
return [];
|
|
120
|
+
let discovery;
|
|
121
|
+
try {
|
|
122
|
+
discovery = await discoverSourceFiles(workspaceRoot, {
|
|
123
|
+
trackedOnly: true,
|
|
124
|
+
consumeTrackedPendingReceipts: false,
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
catch (error) {
|
|
128
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
129
|
+
return [
|
|
130
|
+
{
|
|
131
|
+
rule: "source-relationship-parity",
|
|
132
|
+
entityId: "source-discovery",
|
|
133
|
+
description: `Authored relationship parity could not establish a complete source view: ${message}`,
|
|
134
|
+
suggestion: "Repair the pending-source receipt through Kibi recovery, then rerun kb_check; do not ignore missing authored inputs.",
|
|
135
|
+
evidence: {
|
|
136
|
+
direction: "source_discovery",
|
|
137
|
+
message,
|
|
138
|
+
},
|
|
139
|
+
},
|
|
140
|
+
];
|
|
141
|
+
}
|
|
142
|
+
const extraction = await processExtractions(discovery.markdownFiles, discovery.manifestFiles, true, workspaceRoot);
|
|
143
|
+
if (extraction.errors.length > 0) {
|
|
144
|
+
return extraction.errors.map(({ file, message }) => ({
|
|
145
|
+
rule: "source-relationship-parity",
|
|
146
|
+
entityId: path.relative(workspaceRoot, file).replaceAll(path.sep, "/"),
|
|
147
|
+
source: path.relative(workspaceRoot, file).replaceAll(path.sep, "/"),
|
|
148
|
+
description: `Authored relationship parity could not inspect source: ${message}`,
|
|
149
|
+
suggestion: "Repair the authored source, then rerun kb_check.",
|
|
150
|
+
}));
|
|
151
|
+
}
|
|
152
|
+
const authored = extraction.results.flatMap(({ entity, relationships }) => relationships.map((relationship) => authoredRelationship(relationship, entity.source)));
|
|
153
|
+
for (const relationship of readAllShards(path.join(workspaceRoot, ".kb"))) {
|
|
154
|
+
authored.push({
|
|
155
|
+
type: relationship.type,
|
|
156
|
+
from: relationship.from,
|
|
157
|
+
to: relationship.to,
|
|
158
|
+
source: ".kb/relationships",
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
return compareRelationshipParity(authored, await compiledRelationships(prolog));
|
|
162
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export type {
|
|
3
|
-
export {
|
|
4
|
-
export declare const
|
|
5
|
-
readonly name: "
|
|
6
|
-
readonly cliName: "
|
|
7
|
-
readonly description: "Generate
|
|
1
|
+
import { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
|
|
2
|
+
export type { BootstrapContext, PlanBootstrapArgs, PlanBootstrapResult, } from "../../../operations/bootstrap/types.js";
|
|
3
|
+
export { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
|
|
4
|
+
export declare const planBootstrapSpec: {
|
|
5
|
+
readonly name: "kb_plan_bootstrap";
|
|
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.";
|
|
8
8
|
readonly businessInputSchema: {
|
|
9
9
|
readonly type: "object";
|
|
10
10
|
readonly properties: {
|
|
@@ -77,6 +77,6 @@ export declare const autopilotGenerateSpec: {
|
|
|
77
77
|
};
|
|
78
78
|
readonly requiresProlog: false;
|
|
79
79
|
readonly effects: readonly ["workspace-read"];
|
|
80
|
-
readonly execute: typeof
|
|
80
|
+
readonly execute: typeof executePlanBootstrap;
|
|
81
81
|
};
|
|
82
|
-
//# sourceMappingURL=
|
|
82
|
+
//# sourceMappingURL=bootstrap.d.ts.map
|
|
@@ -0,0 +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,9 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
|
|
2
|
+
export { executePlanBootstrap } from "../../../operations/bootstrap/generate.js";
|
|
3
|
+
// implements REQ-KIBI-BOOTSTRAP-PLAN
|
|
4
|
+
export const planBootstrapSpec = {
|
|
5
|
+
name: "kb_plan_bootstrap",
|
|
6
|
+
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.",
|
|
7
8
|
businessInputSchema: {
|
|
8
9
|
type: "object",
|
|
9
10
|
properties: {
|
|
@@ -68,5 +69,5 @@ export const autopilotGenerateSpec = {
|
|
|
68
69
|
},
|
|
69
70
|
requiresProlog: false,
|
|
70
71
|
effects: ["workspace-read"],
|
|
71
|
-
execute:
|
|
72
|
+
execute: executePlanBootstrap,
|
|
72
73
|
};
|