@unbrained/pm-cli 2026.11.9 → 2026.11.10
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/.claude-plugin/marketplace.json +1 -1
- package/CHANGELOG.md +16 -0
- package/dist/cli/error-guidance.js +4 -4
- package/dist/cli/main.js +1 -1
- package/dist/cli/public.d.ts +1 -1
- package/dist/cli/register-history-maintenance.js +2 -2
- package/dist/cli/register-setup.js +1 -1
- package/dist/cli-bundle/bundle-manifest.json +1 -1
- package/dist/cli-bundle/chunks/{chunk-G6Q4VQSI.js → chunk-4AASUCHO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-EZRLW4R6.js → chunk-4FLAKTZW.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-5CAMQHEW.js +3 -0
- package/dist/cli-bundle/chunks/{chunk-3BMIAI4P.js → chunk-7NAAW5EX.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-BSJSGDA3.js +3 -0
- package/dist/cli-bundle/chunks/{chunk-XKY4LUXN.js → chunk-CZETQYKO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ASJZMYKM.js → chunk-D727C4RO.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-6V4PGJBZ.js → chunk-EHDGHFMJ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GZVOOHTO.js → chunk-F6FBGLR7.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-O2M3TNFY.js → chunk-F7P2NZEG.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-YK5GAWOT.js → chunk-FYD6LSJA.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-L4WWG2H6.js +6 -0
- package/dist/cli-bundle/chunks/{chunk-YV5ALMG2.js → chunk-NNE63MSM.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-Z3QEEOAM.js → chunk-NZAFLDSH.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-MSJ7IHMJ.js → chunk-OJ2KEDUX.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ELNWRSGZ.js → chunk-T2MNRM3S.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-VATZTJE3.js → chunk-TBBWPEF5.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GDQ2T2OR.js → chunk-U7LILCUN.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-BLUCQ4T4.js → chunk-UFPLZ6LZ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-JK7O7MFO.js → chunk-UL64P6MR.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-GCPP37N6.js → chunk-WNEUWDUE.js} +46 -46
- package/dist/cli-bundle/chunks/{chunk-5VRJPPUC.js → chunk-X7NM5HVQ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-IGT252ES.js → chunk-YSWD2NXB.js} +2 -2
- package/dist/cli-bundle/chunks/{item-revision-Y5CE3EIN.js → item-revision-M7KXLQXF.js} +2 -2
- package/dist/cli-bundle/chunks/item-transaction-4N5P34GO.js +2 -0
- package/dist/cli-bundle/chunks/{mutation-admission-TAQN2AKK.js → mutation-admission-374UR7NI.js} +2 -2
- package/dist/cli-bundle/chunks/{register-list-query-XMQYFUFI.js → register-list-query-GSB7PP5P.js} +2 -2
- package/dist/cli-bundle/chunks/{register-mutation-OBVCFLDK.js → register-mutation-ZBF6ITYK.js} +2 -2
- package/dist/cli-bundle/chunks/{register-operations-CGNFZ6DR.js → register-operations-PWF6GOHE.js} +2 -2
- package/dist/cli-bundle/chunks/{register-setup-LFB5ERXH.js → register-setup-QDZ2Y3CI.js} +2 -2
- package/dist/cli-bundle/chunks/{stage-NQHF6JPC.js → stage-67WGPKPH.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-HNFY3XLC.js → chunk-2Y4H4LIX.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-UIKLNSW3.js → chunk-3DWNH72D.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-3K2MYE7R.js +26 -0
- package/dist/cli-bundle/focused-chunks/{chunk-CUGJ2DY2.js → chunk-56MIAFEN.js} +3 -3
- package/dist/cli-bundle/focused-chunks/{chunk-Q45LDP7P.js → chunk-67M7E2Z3.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-XLSTFUXM.js → chunk-BE2GK2G7.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-C3DO4ZGZ.js → chunk-HTMQDNVC.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-QWUWNFQO.js → chunk-LY3JXL25.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-IS5FLEZW.js → chunk-PAGW6A2X.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-4FWMXQN3.js → chunk-QCHCEFTO.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-AH5IST3V.js → chunk-QHGGO7SY.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-QK7FX4O5.js +44 -0
- package/dist/cli-bundle/focused-chunks/{chunk-RNZUORGI.js → chunk-RFMKS7VD.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-MYBKRV5R.js → chunk-U7HWWEJ2.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-UIZVD36C.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-J7PWHKZK.js → chunk-WJHDUON5.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-LDMBNTOG.js → chunk-WK773UVA.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-ZBOCYFBE.js +82 -0
- package/dist/cli-bundle/focused-chunks/{item-revision-M6FOLME2.js → item-revision-XC4ZJ7MY.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{item-transaction-H6VA5JGB.js → item-transaction-CVGK4RJP.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{mutation-admission-PRTQWQK6.js → mutation-admission-N27D5H64.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{stage-7T77PSJD.js → stage-KPK2UHVO.js} +2 -2
- package/dist/cli-bundle/main.js +26 -26
- package/dist/cli-bundle/sdk-authoring.js +1 -1
- package/dist/cli-bundle/sdk-contracts.js +1 -1
- package/dist/cli-bundle/sdk-core.js +1 -1
- package/dist/cli-bundle/sdk-governance.js +1 -1
- package/dist/cli-bundle/sdk-graph.js +1 -1
- package/dist/cli-bundle/sdk-merge.js +51 -51
- package/dist/cli-bundle/sdk-query.js +1 -1
- package/dist/cli-bundle/sdk-runtime.js +1 -1
- package/dist/cli-bundle/sdk-testing.js +1 -1
- package/dist/cli-bundle/sdk.js +1 -1
- package/dist/core/checkpoint/mutation-checkpoint.d.ts +12 -20
- package/dist/core/config/nested-settings.d.ts +14 -45
- package/dist/core/config/nested-settings.js +1 -1
- package/dist/core/config/positional-value.d.ts +11 -14
- package/dist/core/config/positional-value.js +1 -1
- package/dist/core/extensions/activation-summary-markdown.d.ts +4 -5
- package/dist/core/extensions/activation-summary.d.ts +7 -15
- package/dist/core/extensions/capability-usage.d.ts +7 -23
- package/dist/core/extensions/command-hook-context.d.ts +4 -7
- package/dist/core/extensions/command-metadata-contract.d.ts +2 -2
- package/dist/core/extensions/contribution-inventory.d.ts +3 -25
- package/dist/core/extensions/extension-capability-aliases.d.ts +7 -10
- package/dist/core/extensions/extension-hook-runtime.d.ts +2 -2
- package/dist/core/extensions/extension-policy.d.ts +12 -47
- package/dist/core/extensions/extension-registries.d.ts +2 -2
- package/dist/core/extensions/extension-types.d.ts +332 -545
- package/dist/core/extensions/flag-definition-validation.d.ts +11 -13
- package/dist/core/extensions/flag-value-types.d.ts +11 -13
- package/dist/core/extensions/index.d.ts +15 -20
- package/dist/core/extensions/item-field-types.d.ts +5 -5
- package/dist/core/extensions/item-fields.d.ts +4 -7
- package/dist/core/extensions/loader.d.ts +5 -69
- package/dist/core/extensions/manifest-parser.d.ts +3 -3
- package/dist/core/extensions/manifest-schema.d.ts +10 -13
- package/dist/core/extensions/registration-contracts.d.ts +2 -4
- package/dist/core/extensions/registration-validation.d.ts +1 -1
- package/dist/core/extensions/registration-values.d.ts +5 -7
- package/dist/core/extensions/runtime-registrations.d.ts +6 -6
- package/dist/core/extensions/version-compat.d.ts +9 -10
- package/dist/core/fs/fs-utils.d.ts +4 -6
- package/dist/core/fs/host-environment-errors.d.ts +8 -10
- package/dist/core/governance/content-fields.d.ts +10 -14
- package/dist/core/governance/issue-codes.d.ts +12 -18
- package/dist/core/governance/metadata-coverage.d.ts +24 -34
- package/dist/core/history/digest.d.ts +3 -3
- package/dist/core/history/event-classification.d.ts +5 -5
- package/dist/core/history/event-index.d.ts +14 -35
- package/dist/core/history/history-compact-bulk.d.ts +10 -13
- package/dist/core/history/history-diff.d.ts +6 -11
- package/dist/core/history/history-rewrite.d.ts +24 -40
- package/dist/core/history/history-storage-stats.d.ts +9 -17
- package/dist/core/history/history-stream-policy.d.ts +8 -11
- package/dist/core/history/history.d.ts +10 -44
- package/dist/core/history/identity.d.ts +4 -5
- package/dist/core/history/operation-contract.d.ts +5 -15
- package/dist/core/history/projection.d.ts +10 -14
- package/dist/core/history/read.d.ts +6 -7
- package/dist/core/history/replay.d.ts +16 -37
- package/dist/core/history/workspace-history.d.ts +27 -60
- package/dist/core/io/body-file.d.ts +2 -2
- package/dist/core/io/bulk-ids-input.d.ts +7 -8
- package/dist/core/item/actionability.d.ts +16 -22
- package/dist/core/item/dependency-reference.d.ts +2 -2
- package/dist/core/item/id.d.ts +5 -9
- package/dist/core/item/item-format-version.d.ts +11 -13
- package/dist/core/item/item-format.d.ts +11 -59
- package/dist/core/item/item-record.d.ts +2 -2
- package/dist/core/item/literal-mutation-input.d.ts +2 -2
- package/dist/core/item/parent-reference-policy.d.ts +4 -7
- package/dist/core/item/parse.d.ts +10 -26
- package/dist/core/item/plan-lifecycle.d.ts +3 -3
- package/dist/core/item/priority.d.ts +2 -2
- package/dist/core/item/sprint-release-format.d.ts +3 -7
- package/dist/core/item/status-filter.d.ts +5 -7
- package/dist/core/item/status.d.ts +3 -4
- package/dist/core/item/type-registry.d.ts +17 -24
- package/dist/core/item/type-synonyms.d.ts +1 -1
- package/dist/core/lock/lock-owner.d.ts +8 -10
- package/dist/core/lock/lock.d.ts +19 -67
- package/dist/core/output/output-control.d.ts +5 -6
- package/dist/core/output/output.d.ts +10 -19
- package/dist/core/output/tabular.d.ts +2 -2
- package/dist/core/packages/manifest.d.ts +13 -17
- package/dist/core/packages/root.d.ts +3 -3
- package/dist/core/policy/workflow-policy-schema.d.ts +2 -310
- package/dist/core/policy/workflow-policy-store.d.ts +5 -14
- package/dist/core/policy/workflow-policy.d.ts +25 -52
- package/dist/core/profile/profile-describe.d.ts +8 -11
- package/dist/core/profile/profile-lint.d.ts +11 -13
- package/dist/core/profile/profile-plan.d.ts +30 -49
- package/dist/core/profile/profile-presets.d.ts +25 -36
- package/dist/core/reproducibility/context.d.ts +6 -7
- package/dist/core/schema/fields-file.d.ts +14 -21
- package/dist/core/schema/item-types-file.d.ts +16 -22
- package/dist/core/schema/runtime-field-filters.d.ts +2 -2
- package/dist/core/schema/runtime-field-values.d.ts +6 -13
- package/dist/core/schema/runtime-schema.d.ts +19 -31
- package/dist/core/schema/status-defs-file.d.ts +15 -25
- package/dist/core/schema/status-token.d.ts +1 -1
- package/dist/core/schema/type-inference.d.ts +6 -8
- package/dist/core/schema/type-presets.d.ts +5 -5
- package/dist/core/schema/type-workflows.d.ts +11 -16
- package/dist/core/search/background-refresh.d.ts +6 -12
- package/dist/core/search/bm25.d.ts +11 -19
- package/dist/core/search/cache.d.ts +19 -41
- package/dist/core/search/corpus.d.ts +16 -19
- package/dist/core/search/embedding-batches.d.ts +12 -17
- package/dist/core/search/eval-thresholds.d.ts +3 -3
- package/dist/core/search/eval.d.ts +16 -34
- package/dist/core/search/http-client.d.ts +14 -18
- package/dist/core/search/providers.d.ts +22 -39
- package/dist/core/search/relevance.d.ts +14 -19
- package/dist/core/search/semantic-defaults.d.ts +4 -5
- package/dist/core/search/vector-stores.d.ts +35 -57
- package/dist/core/search/vectorization-metadata.d.ts +9 -11
- package/dist/core/sentry/helpers.d.ts +6 -31
- package/dist/core/sentry/instrument.d.ts +6 -59
- package/dist/core/session/session-state.d.ts +12 -32
- package/dist/core/shared/agent-session-context.d.ts +10 -17
- package/dist/core/shared/author.d.ts +48 -69
- package/dist/core/shared/command-line.d.ts +3 -3
- package/dist/core/shared/command-types.d.ts +3 -4
- package/dist/core/shared/constants.d.ts +14 -32
- package/dist/core/shared/error-details.d.ts +5 -18
- package/dist/core/shared/errors.d.ts +42 -83
- package/dist/core/shared/html-entity-decode.d.ts +1 -1
- package/dist/core/shared/item-metadata-contract.d.ts +2 -2
- package/dist/core/shared/lazy-module.d.ts +1 -1
- package/dist/core/shared/levenshtein.d.ts +1 -1
- package/dist/core/shared/numeric-parsers.d.ts +1 -1
- package/dist/core/shared/option-alias-visibility.d.ts +2 -2
- package/dist/core/shared/output-unicode.d.ts +1 -1
- package/dist/core/shared/primitives.d.ts +10 -10
- package/dist/core/shared/secret-rules.d.ts +7 -93
- package/dist/core/shared/serial-queue.d.ts +7 -9
- package/dist/core/shared/serialization.d.ts +1 -1
- package/dist/core/shared/split-comma-list.d.ts +4 -5
- package/dist/core/shared/text-normalization.d.ts +1 -1
- package/dist/core/shared/time.d.ts +6 -20
- package/dist/core/store/item-format-migration.d.ts +4 -5
- package/dist/core/store/item-metadata-cache.d.ts +22 -27
- package/dist/core/store/item-metadata-query-index.d.ts +20 -61
- package/dist/core/store/item-metadata-read-work.d.ts +3 -7
- package/dist/core/store/item-mutation-precondition.d.ts +19 -35
- package/dist/core/store/item-store.d.ts +18 -141
- package/dist/core/store/paths.d.ts +5 -10
- package/dist/core/store/settings-read-cache.d.ts +7 -9
- package/dist/core/store/settings-sections.d.ts +15 -19
- package/dist/core/store/settings-validator.d.ts +27 -143
- package/dist/core/store/settings-validator.js +1 -1
- package/dist/core/store/settings.d.ts +19 -94
- package/dist/core/store/sqlite-runtime.d.ts +3 -3
- package/dist/core/store/tracker-preflight.d.ts +2 -2
- package/dist/core/telemetry/consent.d.ts +2 -2
- package/dist/core/telemetry/observability.d.ts +8 -19
- package/dist/core/telemetry/policy.d.ts +8 -23
- package/dist/core/telemetry/runtime.d.ts +44 -254
- package/dist/core/test/background-runs.d.ts +35 -79
- package/dist/core/test/run-selectors.d.ts +10 -12
- package/dist/core/validate/fix-planning.d.ts +19 -28
- package/dist/core/validate/missing-by-type.d.ts +3 -4
- package/dist/core/validate/missing-link-owners.d.ts +12 -16
- package/dist/core/validate/stale-file-classification.d.ts +5 -6
- package/dist/mcp/tool-definitions.d.ts +7 -30
- package/dist/sdk/actionability.d.ts +1 -1
- package/dist/sdk/agent/closed-domain-contracts.d.ts +4 -5
- package/dist/sdk/agent/command-recovery.d.ts +9 -13
- package/dist/sdk/agent/command-suggestions.d.ts +2 -2
- package/dist/sdk/agent/create-option-policy.d.ts +2 -2
- package/dist/sdk/agent/identity-config.d.ts +13 -18
- package/dist/sdk/agent/item-addressing.d.ts +4 -5
- package/dist/sdk/agent/linked-resource-recovery.d.ts +3 -4
- package/dist/sdk/agent/refusal-closure-census.d.ts +13 -25
- package/dist/sdk/agent/refusal-closure.d.ts +8 -11
- package/dist/sdk/agent/refusal-corpus-contracts.d.ts +15 -21
- package/dist/sdk/agent/refusal-reachability.d.ts +38 -52
- package/dist/sdk/agent/subcommand-recovery.d.ts +7 -15
- package/dist/sdk/agent/task-transcript-contracts.d.ts +12 -15
- package/dist/sdk/agent/tracker-preflight-contracts.d.ts +13 -17
- package/dist/sdk/agent-capability-contracts.d.ts +19 -32
- package/dist/sdk/agent-session-context.d.ts +1 -1
- package/dist/sdk/annotations.d.ts +32 -68
- package/dist/sdk/author-attribution.d.ts +22 -33
- package/dist/sdk/authoring.d.ts +1 -19
- package/dist/sdk/cli-bootstrap.d.ts +22 -59
- package/dist/sdk/cli-contracts/agent-output-contracts.d.ts +31 -57
- package/dist/sdk/cli-contracts/command-aliases.d.ts +7 -8
- package/dist/sdk/cli-contracts/command-exit-contracts.d.ts +19 -65
- package/dist/sdk/cli-contracts/commander-mutation-options.d.ts +2 -2
- package/dist/sdk/cli-contracts/commander-types.d.ts +6 -11
- package/dist/sdk/cli-contracts/completeness.d.ts +11 -15
- package/dist/sdk/cli-contracts/enum-contracts.d.ts +25 -37
- package/dist/sdk/cli-contracts/flag-contracts.d.ts +16 -20
- package/dist/sdk/cli-contracts/flag-lexicon-contracts.d.ts +14 -19
- package/dist/sdk/cli-contracts/grammar-contracts.d.ts +29 -47
- package/dist/sdk/cli-contracts/runtime-contracts.d.ts +44 -265
- package/dist/sdk/cli-contracts/tool-option-contracts.d.ts +11 -564
- package/dist/sdk/cli-contracts/tool-schema.d.ts +18 -51
- package/dist/sdk/cli-contracts/typed-action-inputs.d.ts +18 -37
- package/dist/sdk/cli-contracts.d.ts +1 -16
- package/dist/sdk/cli-program.d.ts +2 -2
- package/dist/sdk/command-line.d.ts +3 -4
- package/dist/sdk/comments.d.ts +6 -10
- package/dist/sdk/compile-cache.d.ts +4 -5
- package/dist/sdk/completion/bash.d.ts +2 -2
- package/dist/sdk/completion/fish.d.ts +2 -2
- package/dist/sdk/completion/shared.d.ts +10 -77
- package/dist/sdk/completion/shared.js +1 -1
- package/dist/sdk/completion/zsh.d.ts +2 -2
- package/dist/sdk/completion.d.ts +2 -6
- package/dist/sdk/compose.d.ts +49 -74
- package/dist/sdk/config.d.ts +18 -94
- package/dist/sdk/config.js +1 -1
- package/dist/sdk/context/recency.d.ts +2 -2
- package/dist/sdk/context/semantic-session-attribution.d.ts +6 -25
- package/dist/sdk/context/usage-ledger.d.ts +9 -21
- package/dist/sdk/context-intent-contracts.d.ts +24 -35
- package/dist/sdk/context-intent-runtime.d.ts +7 -9
- package/dist/sdk/context-packing.d.ts +16 -34
- package/dist/sdk/context-relevance.d.ts +58 -93
- package/dist/sdk/context-signal-store.d.ts +29 -60
- package/dist/sdk/context-usage.d.ts +22 -69
- package/dist/sdk/contracts.d.ts +1 -24
- package/dist/sdk/core-governance.d.ts +1 -5
- package/dist/sdk/core.d.ts +1 -27
- package/dist/sdk/corpus-shape.d.ts +16 -28
- package/dist/sdk/define.d.ts +10 -14
- package/dist/sdk/dependencies.d.ts +32 -50
- package/dist/sdk/dependency-provenance.d.ts +19 -23
- package/dist/sdk/docs.d.ts +6 -10
- package/dist/sdk/duplicates.d.ts +8 -15
- package/dist/sdk/environment/agent-environment.d.ts +60 -101
- package/dist/sdk/environment/host-environment-errors.d.ts +1 -1
- package/dist/sdk/environment/project-runtime-compatibility.d.ts +15 -29
- package/dist/sdk/environment/source-context.d.ts +6 -7
- package/dist/sdk/environment/tracker-preflight.d.ts +1 -1
- package/dist/sdk/error-code-catalog.d.ts +9 -26
- package/dist/sdk/error-runtime.d.ts +6 -8
- package/dist/sdk/errors.d.ts +10 -17
- package/dist/sdk/eval.d.ts +11 -21
- package/dist/sdk/extension/command-options.d.ts +14 -26
- package/dist/sdk/extension/describe.d.ts +14 -19
- package/dist/sdk/extension/doctor.d.ts +8 -48
- package/dist/sdk/extension/install-plan.d.ts +12 -26
- package/dist/sdk/extension/install-runtime.d.ts +10 -11
- package/dist/sdk/extension/install-sources.d.ts +22 -104
- package/dist/sdk/extension/managed-state.d.ts +13 -18
- package/dist/sdk/extension/migrations.d.ts +22 -37
- package/dist/sdk/extension/output-ownership.d.ts +3 -30
- package/dist/sdk/extension/shared.d.ts +9 -15
- package/dist/sdk/extension/source-resolution.d.ts +13 -18
- package/dist/sdk/extension/static-inventory.d.ts +17 -21
- package/dist/sdk/extension/update-check.d.ts +7 -11
- package/dist/sdk/extension-command-context.d.ts +2 -3
- package/dist/sdk/extension-contracts.d.ts +11 -14
- package/dist/sdk/extension.d.ts +31 -192
- package/dist/sdk/files.d.ts +27 -68
- package/dist/sdk/flag-invocation-contracts.d.ts +13 -17
- package/dist/sdk/generated/generated-error-code-catalog-part-1.js +1 -1
- package/dist/sdk/generated-error-code-catalog.d.ts +1 -1
- package/dist/sdk/governance/artifact-ledgers.d.ts +9 -16
- package/dist/sdk/governance/assurance-action-contracts.d.ts +1 -1
- package/dist/sdk/governance/assurance-action.d.ts +13 -45
- package/dist/sdk/governance/assurance-mutation-error.d.ts +12 -17
- package/dist/sdk/governance/assurance-presets.d.ts +10 -21
- package/dist/sdk/governance/assurance-runtime.d.ts +5 -6
- package/dist/sdk/governance/assurance.d.ts +97 -154
- package/dist/sdk/governance/boundary-fixtures.d.ts +17 -23
- package/dist/sdk/governance/closure-timestamps.d.ts +5 -15
- package/dist/sdk/governance/coverage-assurance.d.ts +5 -6
- package/dist/sdk/governance/defect-recurrence-coverage.d.ts +13 -23
- package/dist/sdk/governance/defect-recurrence-graph.d.ts +9 -13
- package/dist/sdk/governance/defect-recurrence.d.ts +43 -67
- package/dist/sdk/governance/extension-host-version.d.ts +8 -10
- package/dist/sdk/governance/gc.d.ts +12 -20
- package/dist/sdk/governance/health/projection.d.ts +8 -23
- package/dist/sdk/governance/health.d.ts +23 -167
- package/dist/sdk/governance/hierarchy-validation.d.ts +2 -18
- package/dist/sdk/governance/linked-file-report.d.ts +6 -10
- package/dist/sdk/governance/merge-receipt-history.d.ts +12 -16
- package/dist/sdk/governance/provenance-health.d.ts +17 -23
- package/dist/sdk/governance/reindex.d.ts +13 -116
- package/dist/sdk/governance/reliability.d.ts +13 -17
- package/dist/sdk/governance/stale-work.d.ts +8 -11
- package/dist/sdk/governance/status-role-diagnostics.d.ts +4 -6
- package/dist/sdk/governance/storage-integrity.d.ts +16 -23
- package/dist/sdk/governance/upgrade.d.ts +17 -57
- package/dist/sdk/governance/validate-item-reader.d.ts +3 -11
- package/dist/sdk/governance/validate-normalization.d.ts +2 -2
- package/dist/sdk/governance/validate.d.ts +29 -175
- package/dist/sdk/governance/workflow-completeness.d.ts +5 -17
- package/dist/sdk/governance/workflow-policy.d.ts +8 -16
- package/dist/sdk/governance/workspace-position.d.ts +12 -43
- package/dist/sdk/governance.d.ts +1 -39
- package/dist/sdk/graph/adapter.d.ts +23 -41
- package/dist/sdk/graph/analytics.d.ts +20 -31
- package/dist/sdk/graph/assembly.d.ts +24 -35
- package/dist/sdk/graph/cache.d.ts +13 -25
- package/dist/sdk/graph/cardinality-integrity.d.ts +4 -6
- package/dist/sdk/graph/centrality.d.ts +14 -20
- package/dist/sdk/graph/conformance.d.ts +12 -19
- package/dist/sdk/graph/deadline-scheduling.d.ts +14 -20
- package/dist/sdk/graph/durable-cache.d.ts +11 -14
- package/dist/sdk/graph/governance-contracts.d.ts +2 -2
- package/dist/sdk/graph/governance.d.ts +22 -36
- package/dist/sdk/graph/hierarchy-integrity.d.ts +18 -26
- package/dist/sdk/graph/index.d.ts +1 -17
- package/dist/sdk/graph/lifecycle-coverage.d.ts +8 -12
- package/dist/sdk/graph/mutation-advisory.d.ts +5 -16
- package/dist/sdk/graph/query-contracts.d.ts +1 -2
- package/dist/sdk/graph/remediation.d.ts +11 -18
- package/dist/sdk/graph/run.d.ts +73 -115
- package/dist/sdk/graph/scheduling.d.ts +8 -15
- package/dist/sdk/graph/traversal.d.ts +9 -15
- package/dist/sdk/graph/workspace-relationship-kind-registry.d.ts +2 -2
- package/dist/sdk/graph.d.ts +1 -12
- package/dist/sdk/guide-topics.d.ts +7 -10
- package/dist/sdk/guide.d.ts +21 -43
- package/dist/sdk/history/attestation-command.d.ts +7 -10
- package/dist/sdk/history/attestation-contract.d.ts +19 -34
- package/dist/sdk/history/attestation.d.ts +2 -3
- package/dist/sdk/history/maintenance.d.ts +17 -27
- package/dist/sdk/history/salvage.d.ts +5 -22
- package/dist/sdk/history/subject.d.ts +5 -11
- package/dist/sdk/history-analytics.d.ts +28 -59
- package/dist/sdk/history-compact.d.ts +25 -66
- package/dist/sdk/history-provenance.d.ts +16 -33
- package/dist/sdk/history-read.d.ts +9 -16
- package/dist/sdk/history-redact.d.ts +19 -74
- package/dist/sdk/history-redact.js +1 -1
- package/dist/sdk/history-repair.d.ts +26 -71
- package/dist/sdk/improvement-ledger-validation.d.ts +2 -2
- package/dist/sdk/improvement-ledger.d.ts +20 -39
- package/dist/sdk/index.d.ts +1 -268
- package/dist/sdk/init-agent-guidance.d.ts +13 -68
- package/dist/sdk/init.d.ts +24 -94
- package/dist/sdk/invocation-author.d.ts +1 -1
- package/dist/sdk/item-children.d.ts +10 -13
- package/dist/sdk/item-metadata-index.d.ts +1 -2
- package/dist/sdk/item-schedule.d.ts +8 -9
- package/dist/sdk/item-transaction.d.ts +46 -90
- package/dist/sdk/learnings.d.ts +6 -10
- package/dist/sdk/lifecycle/append.d.ts +7 -9
- package/dist/sdk/lifecycle/claim.d.ts +26 -42
- package/dist/sdk/lifecycle/cli-input.d.ts +1 -1
- package/dist/sdk/lifecycle/close-many.d.ts +14 -65
- package/dist/sdk/lifecycle/close.d.ts +10 -26
- package/dist/sdk/lifecycle/copy.d.ts +6 -10
- package/dist/sdk/lifecycle/create.d.ts +15 -83
- package/dist/sdk/lifecycle/delete.d.ts +7 -9
- package/dist/sdk/lifecycle/focus.d.ts +9 -11
- package/dist/sdk/lifecycle/item-revision.d.ts +25 -45
- package/dist/sdk/lifecycle/lifecycle-transitions.d.ts +4 -5
- package/dist/sdk/lifecycle/mutation-command-options.d.ts +6 -9
- package/dist/sdk/lifecycle/plan-mutation-receipt.d.ts +5 -13
- package/dist/sdk/lifecycle/plan.d.ts +34 -74
- package/dist/sdk/lifecycle/reopen.d.ts +8 -14
- package/dist/sdk/lifecycle/restore.d.ts +9 -38
- package/dist/sdk/lifecycle/shared-unset-fields.d.ts +23 -614
- package/dist/sdk/lifecycle/start-blockers.d.ts +7 -27
- package/dist/sdk/lifecycle/structured-mutation-plan.d.ts +8 -16
- package/dist/sdk/lifecycle/task-composition.d.ts +6 -14
- package/dist/sdk/lifecycle/update-many.d.ts +15 -65
- package/dist/sdk/lifecycle/update.d.ts +21 -104
- package/dist/sdk/lifecycle/workflow-transition.d.ts +2 -11
- package/dist/sdk/lifecycle-completion.d.ts +11 -14
- package/dist/sdk/lifecycle-policy.d.ts +23 -32
- package/dist/sdk/linked-artifacts.d.ts +31 -41
- package/dist/sdk/mcp/apps.d.ts +12 -27
- package/dist/sdk/mcp/authorization.d.ts +30 -63
- package/dist/sdk/mcp/discovery.d.ts +23 -52
- package/dist/sdk/mcp/executable.d.ts +3 -10
- package/dist/sdk/mcp/interactions.d.ts +25 -47
- package/dist/sdk/mcp/protocol.d.ts +32 -64
- package/dist/sdk/mcp/skills.d.ts +21 -71
- package/dist/sdk/mcp/subscriptions.d.ts +14 -28
- package/dist/sdk/mcp/tasks.d.ts +21 -55
- package/dist/sdk/mcp/transport.d.ts +7 -15
- package/dist/sdk/merge/driver.d.ts +13 -37
- package/dist/sdk/merge/index.d.ts +1 -6
- package/dist/sdk/merge/install.d.ts +27 -55
- package/dist/sdk/merge/receipt-operation.d.ts +5 -6
- package/dist/sdk/merge/receipt-schema.d.ts +6 -9
- package/dist/sdk/merge/receipts.d.ts +29 -79
- package/dist/sdk/merge/reconcile.d.ts +9 -18
- package/dist/sdk/merge/three-way.d.ts +21 -30
- package/dist/sdk/merge.d.ts +1 -5
- package/dist/sdk/mutation-events.d.ts +21 -53
- package/dist/sdk/mutation-guard.d.ts +15 -135
- package/dist/sdk/notes.d.ts +6 -10
- package/dist/sdk/output/fit-envelope.d.ts +21 -28
- package/dist/sdk/output/list-envelope.d.ts +1 -1
- package/dist/sdk/output/table-rows.d.ts +8 -12
- package/dist/sdk/output-contracts.d.ts +11 -14
- package/dist/sdk/output-projection.d.ts +18 -130
- package/dist/sdk/output-token-accounting.d.ts +8 -15
- package/dist/sdk/output.d.ts +10 -15
- package/dist/sdk/ownership-source.d.ts +4 -5
- package/dist/sdk/package-import-adapters.d.ts +27 -37
- package/dist/sdk/package-migrations.d.ts +2 -2
- package/dist/sdk/package-runtime-options.d.ts +3 -3
- package/dist/sdk/pagination.d.ts +12 -24
- package/dist/sdk/profile.d.ts +25 -42
- package/dist/sdk/provenance.d.ts +21 -32
- package/dist/sdk/query/activity.d.ts +24 -77
- package/dist/sdk/query/aggregate.d.ts +20 -95
- package/dist/sdk/query/calendar.d.ts +26 -74
- package/dist/sdk/query/complete-list.d.ts +19 -35
- package/dist/sdk/query/context.d.ts +69 -240
- package/dist/sdk/query/declared-blockers.d.ts +2 -9
- package/dist/sdk/query/duplicate-candidates.d.ts +3 -5
- package/dist/sdk/query/get.d.ts +13 -55
- package/dist/sdk/query/history.d.ts +18 -29
- package/dist/sdk/query/item-filter-options.d.ts +7 -12
- package/dist/sdk/query/list-filter-shared.d.ts +4 -8
- package/dist/sdk/query/list.d.ts +44 -168
- package/dist/sdk/query/multi-value-filters.d.ts +7 -9
- package/dist/sdk/query/next-ranking-policy.d.ts +4 -10
- package/dist/sdk/query/next-ready-budget.d.ts +4 -5
- package/dist/sdk/query/next.d.ts +27 -86
- package/dist/sdk/query/parsers.d.ts +4 -6
- package/dist/sdk/query/projection-contracts.d.ts +12 -21
- package/dist/sdk/query/search/corpus.d.ts +5 -20
- package/dist/sdk/query/search/filters.d.ts +5 -17
- package/dist/sdk/query/search/input.d.ts +4 -9
- package/dist/sdk/query/search/lexical.d.ts +5 -9
- package/dist/sdk/query/search/response.d.ts +5 -22
- package/dist/sdk/query/search/semantic.d.ts +24 -170
- package/dist/sdk/query/search/types.d.ts +19 -73
- package/dist/sdk/query/search-contracts.d.ts +24 -34
- package/dist/sdk/query/search-pagination.d.ts +5 -24
- package/dist/sdk/query/search-rendering.d.ts +8 -32
- package/dist/sdk/query/search.d.ts +3 -63
- package/dist/sdk/query/workspace-contracts.d.ts +2 -2
- package/dist/sdk/query.d.ts +1 -43
- package/dist/sdk/read-output/continuation.d.ts +5 -6
- package/dist/sdk/read-output/options.d.ts +3 -8
- package/dist/sdk/read-output/session-result.d.ts +2 -33
- package/dist/sdk/read-output/tail-retention.d.ts +6 -8
- package/dist/sdk/read-output-budget.d.ts +14 -16
- package/dist/sdk/read-output-contracts.d.ts +59 -103
- package/dist/sdk/read-output-rows.d.ts +5 -9
- package/dist/sdk/read-output-session.d.ts +11 -14
- package/dist/sdk/relationship-analytics.d.ts +17 -37
- package/dist/sdk/relationship-context.d.ts +15 -33
- package/dist/sdk/relationship-history.d.ts +29 -50
- package/dist/sdk/relationship-kinds/contract.d.ts +11 -12
- package/dist/sdk/relationship-migration.d.ts +6 -10
- package/dist/sdk/relationships.d.ts +22 -34
- package/dist/sdk/reproducibility/process.d.ts +7 -11
- package/dist/sdk/runtime/context.d.ts +6 -22
- package/dist/sdk/runtime/schema-preview.d.ts +1 -1
- package/dist/sdk/runtime-input.d.ts +9 -20
- package/dist/sdk/runtime-primitives.d.ts +3 -82
- package/dist/sdk/runtime-public-contracts.d.ts +30 -50
- package/dist/sdk/runtime.d.ts +77 -302
- package/dist/sdk/scheduling-shortcuts.d.ts +8 -12
- package/dist/sdk/schema-migration.d.ts +18 -80
- package/dist/sdk/schema.d.ts +89 -192
- package/dist/sdk/search-refresh-worker.d.ts +1 -1
- package/dist/sdk/similarity-scoring.d.ts +6 -8
- package/dist/sdk/similarity.d.ts +33 -64
- package/dist/sdk/start-task-status.d.ts +2 -2
- package/dist/sdk/stats.d.ts +13 -48
- package/dist/sdk/structured-mutations.d.ts +18 -26
- package/dist/sdk/telemetry-flush.d.ts +1 -1
- package/dist/sdk/telemetry.d.ts +14 -20
- package/dist/sdk/templates.d.ts +14 -35
- package/dist/sdk/test/batch.d.ts +10 -25
- package/dist/sdk/test/execution.d.ts +44 -209
- package/dist/sdk/test/json-path.d.ts +2 -5
- package/dist/sdk/test/linked-command-detection.d.ts +10 -25
- package/dist/sdk/test/measurements.d.ts +10 -13
- package/dist/sdk/test/parsers.d.ts +16 -20
- package/dist/sdk/test/prerequisites.d.ts +2 -3
- package/dist/sdk/test/runs.d.ts +19 -52
- package/dist/sdk/test/trust.d.ts +8 -12
- package/dist/sdk/test/update.d.ts +9 -25
- package/dist/sdk/testing.d.ts +97 -206
- package/dist/sdk/traceability/source-traceability.d.ts +25 -56
- package/dist/sdk/tracker-root-discovery.d.ts +1 -1
- package/dist/sdk/workspace-contracts-cache.d.ts +2 -2
- package/dist/sdk/workspace-contracts.d.ts +8 -14
- package/dist/sdk/workspace-memory.d.ts +24 -42
- package/dist/sdk/workspace-recipe.d.ts +10 -14
- package/dist/sdk/workspace-snapshot.d.ts +26 -53
- package/dist/sdk/workspace-transaction-gc.d.ts +12 -16
- package/dist/sdk/workspace-transaction.d.ts +26 -40
- package/dist/sdk/workspace.d.ts +8 -10
- package/dist/types/index.d.ts +1 -1
- package/dist/types.d.ts +210 -353
- package/docs/COMMANDS.md +8 -0
- package/docs/CONFIGURATION.md +17 -0
- package/docs/DIAGNOSTIC_OUTPUT_CONTRACTS.md +28 -9
- package/docs/RELEASING.md +25 -0
- package/docs/SDK.md +17 -2
- package/docs/TESTING.md +11 -0
- package/marketplace.json +1 -1
- package/package.json +1 -1
- package/packages/pm-beads/package.json +1 -1
- package/packages/pm-calendar/package.json +1 -1
- package/packages/pm-command-kit/package.json +1 -1
- package/packages/pm-digital-twin/package.json +1 -1
- package/packages/pm-governance-audit/package.json +1 -1
- package/packages/pm-guide-shell/package.json +1 -1
- package/packages/pm-kanban/package.json +1 -1
- package/packages/pm-lifecycle-hooks/package.json +1 -1
- package/packages/pm-linked-test-adapters/package.json +1 -1
- package/packages/pm-search-advanced/package.json +1 -1
- package/packages/pm-templates/package.json +1 -1
- package/packages/pm-todos/package.json +1 -1
- package/packages/pm-vcs/package.json +1 -1
- package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
- package/plugins/pm-claude/package.json +1 -1
- package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
- package/plugins/pm-codex/package.json +1 -1
- package/plugins/pm-codex/plugin.json +1 -1
- package/runtime-dependencies.json +1 -1
- package/scripts/finalize-build.mjs +41 -4
- package/dist/cli-bundle/chunks/chunk-JYQXIC6C.js +0 -3
- package/dist/cli-bundle/chunks/chunk-LVDFPGD7.js +0 -3
- package/dist/cli-bundle/chunks/chunk-UFIM5ZC5.js +0 -6
- package/dist/cli-bundle/chunks/item-transaction-XBIN4KYM.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-HLQOGAWG.js +0 -26
- package/dist/cli-bundle/focused-chunks/chunk-IB6TCE7N.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-JU62TKJP.js +0 -82
- package/dist/cli-bundle/focused-chunks/chunk-NUFO3OR6.js +0 -44
|
@@ -4,56 +4,41 @@
|
|
|
4
4
|
* Declares and applies one output-bounding vocabulary to every built-in read
|
|
5
5
|
* surface without coupling package authors to command-specific option names.
|
|
6
6
|
*/
|
|
7
|
-
import {
|
|
8
|
-
export { resolveReadOutputRecoveryBudget } from "./read-output-budget.js";
|
|
9
|
-
export type { PmReadOutputRecoveryBudget,PmReadOutputRecoveryBudgetInput,} from "./read-output-budget.js";
|
|
10
|
-
export { decodeReadOutputContinuationCursor,encodeReadOutputContinuationCursor,PM_READ_OUTPUT_CONTINUATION_FINGERPRINT_POLICIES,readOutputCollectionFingerprint,} from "./read-output/continuation.js";
|
|
11
|
-
export { PM_READ_OUTPUT_TAIL_RETENTION_POLICIES,readOutputRetainsTail,} from "./read-output/tail-retention.js";
|
|
12
|
-
export type { PmReadOutputContinuationFingerprintPolicy } from "./read-output/continuation.js";
|
|
13
|
-
export type { PmReadOutputDeliveredRowCounter,PmReadOutputTailRetentionPolicy,} from "./read-output/tail-retention.js";
|
|
14
|
-
import { type PmReadOutputSessionReceipt,type PmReadOutputSessionState } from "./read-output-session.js";
|
|
15
|
-
import type { PmReadOutputProducerContinuation } from "./context-intent-contracts.js";
|
|
16
|
-
import type { PmReadOutputSessionResult } from "./read-output/session-result.js";
|
|
17
|
-
import type { OutputOmissionReceipt } from "./output-projection.js";
|
|
18
|
-
export type { PmReadOutputSessionResult } from "./read-output/session-result.js";
|
|
19
|
-
export type { PmReadOutputProducerContinuation } from "./context-intent-contracts.js";
|
|
7
|
+
import{PM_READ_OUTPUT_SURFACES}from "./read-output/options.js";export{resolveReadOutputRecoveryBudget}from "./read-output-budget.js";export type{PmReadOutputRecoveryBudget,PmReadOutputRecoveryBudgetInput,}from "./read-output-budget.js";export{decodeReadOutputContinuationCursor,encodeReadOutputContinuationCursor,PM_READ_OUTPUT_CONTINUATION_FINGERPRINT_POLICIES,readOutputCollectionFingerprint,}from "./read-output/continuation.js";export{PM_READ_OUTPUT_TAIL_RETENTION_POLICIES,readOutputRetainsTail,}from "./read-output/tail-retention.js";export type{PmReadOutputContinuationFingerprintPolicy}from "./read-output/continuation.js";export type{PmReadOutputDeliveredRowCounter,PmReadOutputTailRetentionPolicy,}from "./read-output/tail-retention.js";import{type PmReadOutputSessionReceipt,type PmReadOutputSessionState}from "./read-output-session.js";import type{PmReadOutputProducerContinuation}from "./context-intent-contracts.js";import type{PmReadOutputSessionResult}from "./read-output/session-result.js";import type{OutputOmissionReceipt}from "./output-projection.js";export type{PmReadOutputSessionResult}from "./read-output/session-result.js";export type{PmReadOutputProducerContinuation}from "./context-intent-contracts.js";
|
|
20
8
|
/** Stable output dimensions shared by every read surface. */
|
|
21
|
-
export declare const PM_READ_OUTPUT_DIMENSIONS:readonly
|
|
9
|
+
export declare const PM_READ_OUTPUT_DIMENSIONS:readonly["include","amount","cost","encoding"];
|
|
22
10
|
/** One member of the universal read-output dimension set. */
|
|
23
|
-
export type PmReadOutputDimension
|
|
24
|
-
export { PM_READ_OUTPUT_SURFACES } from "./read-output/options.js";
|
|
11
|
+
export type PmReadOutputDimension=(typeof PM_READ_OUTPUT_DIMENSIONS)[number];export{PM_READ_OUTPUT_SURFACES}from "./read-output/options.js";
|
|
25
12
|
/** Native or package read identity supported by the universal output contract. */
|
|
26
|
-
export type PmReadOutputSurface
|
|
13
|
+
export type PmReadOutputSurface=(typeof PM_READ_OUTPUT_SURFACES)[number]|`extension:${string}`;
|
|
27
14
|
/** Canonical output controls accepted by every built-in read action. */
|
|
28
|
-
export interface PmReadOutputOptions
|
|
15
|
+
export interface PmReadOutputOptions{
|
|
29
16
|
/** Comma-separated fields or sections retained in the result. */
|
|
30
|
-
outputInclude?:string
|
|
17
|
+
outputInclude?:string|string[];
|
|
31
18
|
/** Maximum rows retained, or `unbounded` to disable the shared row ceiling. */
|
|
32
|
-
outputLimit?:string
|
|
19
|
+
outputLimit?:string|number|"unbounded";
|
|
33
20
|
/** Maximum estimated result tokens, or `unbounded` to disable the default ceiling. */
|
|
34
|
-
outputBudget?:string
|
|
21
|
+
outputBudget?:string|number|"unbounded";
|
|
35
22
|
/** Requested static renderer encoding; streaming remains a command behavior. */
|
|
36
|
-
outputFormat?:"json"
|
|
23
|
+
outputFormat?:"json"|"toon";
|
|
37
24
|
/** Caller-carried cross-call budget and served-fact state. */
|
|
38
|
-
outputSession?:string
|
|
25
|
+
outputSession?:string|PmReadOutputSessionState;
|
|
39
26
|
/** Opaque continuation returned after a budget-compacted declared row path. */
|
|
40
27
|
outputCursor?:string;
|
|
41
28
|
/** Include row selector and encoding discovery metadata. */
|
|
42
|
-
outputRowContract?:boolean;
|
|
43
|
-
}
|
|
29
|
+
outputRowContract?:boolean;}
|
|
44
30
|
/** Compatibility spelling retained for a command-specific output control. */
|
|
45
|
-
export interface PmReadOutputLegacyAlias
|
|
31
|
+
export interface PmReadOutputLegacyAlias{
|
|
46
32
|
/** Historical CLI spelling. */
|
|
47
33
|
flag:string;
|
|
48
34
|
/** Strength of the migration promise carried by this alias. */
|
|
49
|
-
semantics?:"replacement"
|
|
35
|
+
semantics?:"replacement"|"behavior_preserving";
|
|
50
36
|
/** One-line migration instruction for agents and help generators. */
|
|
51
37
|
migration_hint:string;
|
|
52
38
|
/** Compatibility aliases are accepted but omitted from the canonical vocabulary. */
|
|
53
|
-
visibility:"hidden_alias";
|
|
54
|
-
}
|
|
39
|
+
visibility:"hidden_alias";}
|
|
55
40
|
/** Contract for one output dimension on one read surface. */
|
|
56
|
-
export interface PmReadOutputDimensionContract
|
|
41
|
+
export interface PmReadOutputDimensionContract{
|
|
57
42
|
/** Stable dimension name. */
|
|
58
43
|
dimension:PmReadOutputDimension;
|
|
59
44
|
/** Canonical cross-command CLI option. */
|
|
@@ -61,47 +46,44 @@ canonical_option:string;
|
|
|
61
46
|
/** Whether the dimension has executable behavior on this surface. */
|
|
62
47
|
applicable:boolean;
|
|
63
48
|
/** Explanation used only when the dimension cannot apply. */
|
|
64
|
-
inapplicable_reason:string
|
|
49
|
+
inapplicable_reason:string|null;
|
|
65
50
|
/** Historical command-local options mapped into this dimension. */
|
|
66
|
-
legacy_aliases:PmReadOutputLegacyAlias[];
|
|
67
|
-
}
|
|
51
|
+
legacy_aliases:PmReadOutputLegacyAlias[];}
|
|
68
52
|
/** Complete four-dimension contract for one read surface. */
|
|
69
|
-
export interface PmReadOutputSurfaceContract
|
|
53
|
+
export interface PmReadOutputSurfaceContract{
|
|
70
54
|
/** Canonical command root. */
|
|
71
55
|
command:PmReadOutputSurface;
|
|
72
56
|
/** Identical dimension keys shared by every read surface. */
|
|
73
57
|
dimensions:Record<PmReadOutputDimension,PmReadOutputDimensionContract>;
|
|
74
58
|
/** Deterministic precedence from strongest caller declaration to fallback. */
|
|
75
|
-
precedence:readonly
|
|
59
|
+
precedence:readonly["canonical","legacy","intent","default"];
|
|
76
60
|
/**
|
|
77
61
|
* Stable policy used before budget compaction selects retained rows:
|
|
78
62
|
* `ordered_suffix` surfaces keep their newest (last) rows and page backwards.
|
|
79
63
|
*/
|
|
80
|
-
budget_retention_policy:"ordered_prefix"
|
|
64
|
+
budget_retention_policy:"ordered_prefix"|"ordered_suffix"|"verdict_priority";
|
|
81
65
|
/** Exact command-local whole-result modes accepted by `outputInclude`. */
|
|
82
|
-
projection_modes?:readonly string[];
|
|
83
|
-
}
|
|
66
|
+
projection_modes?:readonly string[];}
|
|
84
67
|
/** Source that selected an effective output dimension. */
|
|
85
|
-
export type PmReadOutputDimensionSource
|
|
68
|
+
export type PmReadOutputDimensionSource="canonical"|"legacy"|"intent"|"default";
|
|
86
69
|
/** Resolved value and provenance for one dimension. */
|
|
87
|
-
export interface PmResolvedReadOutputDimension<T>
|
|
70
|
+
export interface PmResolvedReadOutputDimension<T>{
|
|
88
71
|
/** Effective value after precedence resolution. */
|
|
89
72
|
value:T;
|
|
90
73
|
/** Layer that supplied the effective value. */
|
|
91
|
-
source:PmReadOutputDimensionSource;
|
|
92
|
-
}
|
|
74
|
+
source:PmReadOutputDimensionSource;}
|
|
93
75
|
/** Fully resolved output controls for one invocation. */
|
|
94
|
-
export interface PmResolvedReadOutputDimensions
|
|
76
|
+
export interface PmResolvedReadOutputDimensions{
|
|
95
77
|
/** Canonical read surface. */
|
|
96
78
|
command:PmReadOutputSurface;
|
|
97
79
|
/** Requested field or section selectors. */
|
|
98
80
|
include?:PmResolvedReadOutputDimension<string[]>;
|
|
99
81
|
/** Requested row ceiling. */
|
|
100
|
-
amount?:PmResolvedReadOutputDimension<number
|
|
82
|
+
amount?:PmResolvedReadOutputDimension<number|"unbounded">;
|
|
101
83
|
/** Requested estimated-token ceiling or explicit opt-out. */
|
|
102
|
-
cost?:PmResolvedReadOutputDimension<number
|
|
84
|
+
cost?:PmResolvedReadOutputDimension<number|"unbounded">;
|
|
103
85
|
/** Requested static encoding or a retained legacy streaming behavior. */
|
|
104
|
-
encoding?:PmResolvedReadOutputDimension<"json"
|
|
86
|
+
encoding?:PmResolvedReadOutputDimension<"json"|"toon"|"stream">;
|
|
105
87
|
/** Canonical CLI options observed on the invocation. */
|
|
106
88
|
canonical_options_used?:string[];
|
|
107
89
|
/** Compatibility flags observed on the invocation. */
|
|
@@ -109,10 +91,9 @@ legacy_aliases_used:string[];
|
|
|
109
91
|
/** One-line migration instructions for observed compatibility flags. */
|
|
110
92
|
migration_hints:string[];
|
|
111
93
|
/** Deterministic precedence applied to every dimension. */
|
|
112
|
-
precedence:readonly
|
|
113
|
-
}
|
|
94
|
+
precedence:readonly["canonical","legacy","intent","default"];}
|
|
114
95
|
/** Machine-readable proof of output dimensions applied to one read. */
|
|
115
|
-
export interface PmReadOutputReceipt
|
|
96
|
+
export interface PmReadOutputReceipt{
|
|
116
97
|
/** Contract format version. */
|
|
117
98
|
contract_version:1;
|
|
118
99
|
/** Canonical read surface. */
|
|
@@ -120,11 +101,11 @@ command:PmReadOutputSurface;
|
|
|
120
101
|
/** Dimensions explicitly or compatibly requested by the invocation. */
|
|
121
102
|
requested_dimensions:PmReadOutputDimension[];
|
|
122
103
|
/** Layer supplying a default ceiling or the context compatibility ceiling. */
|
|
123
|
-
budget_source?:"default"
|
|
104
|
+
budget_source?:"default"|"legacy";
|
|
124
105
|
/** Applied default or context compatibility ceiling; canonical/session budgets already disclose their value. */
|
|
125
106
|
budget_tokens?:number;
|
|
126
107
|
/** Deterministic precedence used during resolution. */
|
|
127
|
-
precedence:readonly
|
|
108
|
+
precedence:readonly["canonical","legacy","intent","default"];
|
|
128
109
|
/** Canonical CLI options observed on the invocation. */
|
|
129
110
|
canonical_options_used?:string[];
|
|
130
111
|
/** Compatibility options observed on the invocation. */
|
|
@@ -148,14 +129,13 @@ omitted_result_estimated_tokens?:number;
|
|
|
148
129
|
/** Detail depth selected before destructive string or row compaction. */
|
|
149
130
|
applied_depth?:"brief";
|
|
150
131
|
/** Binding constraint that selected the smaller detail projection. */
|
|
151
|
-
degradation_reason?:"output_budget_reached";
|
|
152
|
-
}
|
|
132
|
+
degradation_reason?:"output_budget_reached";}
|
|
153
133
|
/** Machine-readable explanation of budget-driven row degradation. */
|
|
154
|
-
export interface PmReadOutputTruncationDisclosure
|
|
134
|
+
export interface PmReadOutputTruncationDisclosure{
|
|
155
135
|
/** Stable reason for dropping rows. */
|
|
156
136
|
reason:"output_budget_reached";
|
|
157
137
|
/** Layer that supplied the binding ceiling. */
|
|
158
|
-
budget_source:PmReadOutputDimensionSource
|
|
138
|
+
budget_source:PmReadOutputDimensionSource|"session";
|
|
159
139
|
/** Binding estimated-token ceiling. */
|
|
160
140
|
budget_tokens:number;
|
|
161
141
|
/** Explicit dimensions whose unbounded request was overridden by the ceiling. */
|
|
@@ -167,7 +147,7 @@ continuation_cursor_rebased:boolean;
|
|
|
167
147
|
/** Whether at least one declared row collection can be resumed within the budget. */
|
|
168
148
|
continuation_available:boolean;
|
|
169
149
|
/** Maximum next-page useful-result budget relative to the current budget. */
|
|
170
|
-
recovery_budget_multiplier:number
|
|
150
|
+
recovery_budget_multiplier:number|null;
|
|
171
151
|
/** Bounded continuation instructions for every compacted declared row path. */
|
|
172
152
|
continuations:PmReadOutputContinuation[];
|
|
173
153
|
/** Retry guidance, or `recovery` to require the adjacent cursor and transport bindings. */
|
|
@@ -181,19 +161,9 @@ cli:"--output-cursor";
|
|
|
181
161
|
/** SDK option field accepting cursor. */
|
|
182
162
|
sdk:"outputCursor";
|
|
183
163
|
/** MCP input field accepting cursor. */
|
|
184
|
-
mcp:"outputCursor";
|
|
185
|
-
} | {
|
|
186
|
-
cli:string;
|
|
187
|
-
sdk:{
|
|
188
|
-
outputBudget:number | "unbounded";
|
|
189
|
-
};
|
|
190
|
-
mcp:{
|
|
191
|
-
outputBudget:number | "unbounded";
|
|
192
|
-
};
|
|
193
|
-
};
|
|
194
|
-
}
|
|
164
|
+
mcp:"outputCursor";}|{cli:string;sdk:{outputBudget:number|"unbounded";};mcp:{outputBudget:number|"unbounded";};};}
|
|
195
165
|
/** One resumable declared-row collection withheld by budget compaction. */
|
|
196
|
-
export interface PmReadOutputContinuation
|
|
166
|
+
export interface PmReadOutputContinuation{
|
|
197
167
|
/** Dot-delimited declared row path being resumed. */
|
|
198
168
|
path:string;
|
|
199
169
|
/** Opaque cursor accepted by CLI, SDK, and MCP outputCursor inputs. */
|
|
@@ -203,10 +173,9 @@ retained_rows:number;
|
|
|
203
173
|
/** Rows remaining after the current response. */
|
|
204
174
|
remaining_rows:number;
|
|
205
175
|
/** Total rows in the stable collection snapshot. */
|
|
206
|
-
total_rows:number;
|
|
207
|
-
}
|
|
176
|
+
total_rows:number;}
|
|
208
177
|
/** Versioned, command-bound cursor payload for one stable declared row collection. */
|
|
209
|
-
export interface PmReadOutputCursorEnvelope
|
|
178
|
+
export interface PmReadOutputCursorEnvelope{
|
|
210
179
|
/** Serialized cursor format version. */
|
|
211
180
|
version:1;
|
|
212
181
|
/** Canonical read surface that produced the cursor. */
|
|
@@ -223,10 +192,9 @@ total_rows:number;
|
|
|
223
192
|
/** Stable identity fingerprint used to refuse stale continuation. */
|
|
224
193
|
fingerprint:string;
|
|
225
194
|
/** `backward` for a newest-tail collection whose next page holds older rows; absent means forward. */
|
|
226
|
-
direction?:"backward";
|
|
227
|
-
}
|
|
195
|
+
direction?:"backward";}
|
|
228
196
|
/** Result returned when the requested cost ceiling cannot fit useful content. */
|
|
229
|
-
export interface PmReadOutputBudgetExceeded
|
|
197
|
+
export interface PmReadOutputBudgetExceeded{
|
|
230
198
|
/** Stable omission marker and recovery instruction. */
|
|
231
199
|
output_budget_exceeded:{
|
|
232
200
|
/** Confirms that the useful result was deliberately omitted. */
|
|
@@ -236,15 +204,11 @@ reason:"requested_budget_infeasible";
|
|
|
236
204
|
/** Human- and agent-readable recovery instruction. */
|
|
237
205
|
restore_with:string;
|
|
238
206
|
/** Transport-specific machine recovery options. */
|
|
239
|
-
recovery:{
|
|
240
|
-
outputBudget:"unbounded";
|
|
241
|
-
};
|
|
242
|
-
};
|
|
207
|
+
recovery:{outputBudget:"unbounded";};};
|
|
243
208
|
/** Exact receipt for the bounded omission envelope. */
|
|
244
|
-
read_output:PmReadOutputReceipt;
|
|
245
|
-
}
|
|
209
|
+
read_output:PmReadOutputReceipt;}
|
|
246
210
|
/** Shared receipts on finalized first-page reads; raw query builders may not have attached them yet. */
|
|
247
|
-
export interface PmReadOutputMetadata
|
|
211
|
+
export interface PmReadOutputMetadata{
|
|
248
212
|
/** Field groups withheld by the active projection and how to restore them. */
|
|
249
213
|
omission_receipt:OutputOmissionReceipt;
|
|
250
214
|
/** Optional accounting when output shaping or a default ceiling requires a receipt. */
|
|
@@ -252,33 +216,28 @@ read_output?:PmReadOutputReceipt;
|
|
|
252
216
|
/** Optional caller-carried session accounting. */
|
|
253
217
|
read_session?:PmReadOutputSessionReceipt;
|
|
254
218
|
/** Optional recovery when a budget withholds rows. */
|
|
255
|
-
output_budget_truncation?:PmReadOutputTruncationDisclosure;
|
|
256
|
-
}
|
|
257
|
-
type ReadOutputEnvelope<Result> = (Result & Partial<PmReadOutputMetadata>) | (PmReadOutputBudgetExceeded & {
|
|
258
|
-
read_session?:PmReadOutputSessionReceipt;
|
|
259
|
-
});
|
|
219
|
+
output_budget_truncation?:PmReadOutputTruncationDisclosure;}
|
|
220
|
+
type ReadOutputEnvelope<Result>=(Result&Partial<PmReadOutputMetadata>)|(PmReadOutputBudgetExceeded&{read_session?:PmReadOutputSessionReceipt;});
|
|
260
221
|
/** Read result admitting session reference rows and a discriminated budget omission. */
|
|
261
|
-
export type PmReadOutputResult<Result
|
|
222
|
+
export type PmReadOutputResult<Result>=ReadOutputEnvelope<Result|PmReadOutputSessionResult<Result>>;
|
|
262
223
|
/** Preserve first-page results while admitting sparse pages for a possible producer cursor. */
|
|
263
|
-
type ProducerResultFor<Result,Options
|
|
224
|
+
type ProducerResultFor<Result,Options>="after" extends keyof Options ?[Options["after"]]extends[undefined]? Result:Result|PmReadOutputProducerContinuation<Result>:Result;
|
|
264
225
|
/** Distribute over option variants so every possible budget omission and sparse page remains visible. */
|
|
265
|
-
export type PmReadOutputResultFor<Result,Options
|
|
226
|
+
export type PmReadOutputResultFor<Result,Options>=Options extends unknown ? "outputSession" extends keyof Options ?[Options["outputSession"]]extends[undefined]? ReadOutputEnvelope<ProducerResultFor<Result,Options>>:PmReadOutputResult<ProducerResultFor<Result,Options>>:"outputBudget" extends keyof Options ? ReadOutputEnvelope<ProducerResultFor<Result,Options>>:"outputCursor" extends keyof Options ? ReadOutputEnvelope<ProducerResultFor<Result,Options>>:ProducerResultFor<Result,Options>:never;
|
|
266
227
|
/** Infer possible session values from either spelling accepted by the direct helper. */
|
|
267
|
-
type ReadOutputSessionOption<Options
|
|
228
|
+
type ReadOutputSessionOption<Options>=("outputSession" extends keyof Options ? Options["outputSession"]:never)|("output_session" extends keyof Options ? Options["output_session"]:never);
|
|
268
229
|
/** Keep universal budget omissions while adding references only for possible sessions. */
|
|
269
|
-
export type ReadOutputResultForSession<Result,Options
|
|
270
|
-
outputSession:ReadOutputSessionOption<Options>;
|
|
271
|
-
}> :never;
|
|
230
|
+
export type ReadOutputResultForSession<Result,Options>=Options extends unknown ? PmReadOutputResultFor<Result,{outputSession:ReadOutputSessionOption<Options>;}>:never;
|
|
272
231
|
/** Canonical CLI flags that opt a read invocation into universal output shaping. */
|
|
273
232
|
export declare const PM_READ_OUTPUT_OPTION_FLAGS:readonly string[];
|
|
274
233
|
/** Canonical control that composes the four per-call dimensions across reads. */
|
|
275
|
-
export declare const PM_READ_OUTPUT_COMPOSITION_OPTION_FLAGS:readonly
|
|
234
|
+
export declare const PM_READ_OUTPUT_COMPOSITION_OPTION_FLAGS:readonly["--output-session","--output-cursor","--output-row-contract"];
|
|
276
235
|
/** Universal output contract for every built-in read surface. */
|
|
277
236
|
export declare const PM_READ_OUTPUT_SURFACE_CONTRACTS:readonly PmReadOutputSurfaceContract[];
|
|
278
237
|
/** Resolve a command or list/context alias to its canonical read-output surface. */
|
|
279
|
-
export declare function resolveReadOutputSurface(command:string,options?:Record<string,unknown>):PmReadOutputSurface
|
|
238
|
+
export declare function resolveReadOutputSurface(command:string,options?:Record<string,unknown>):PmReadOutputSurface|undefined;
|
|
280
239
|
/** Stable code of the refusal for a hybrid read-and-mutate command given universal output controls (pm-rrwh2o). */
|
|
281
|
-
export declare const READ_OUTPUT_MUTATION_CONFLICT_CODE
|
|
240
|
+
export declare const READ_OUTPUT_MUTATION_CONFLICT_CODE="read_output_mutation_conflict";
|
|
282
241
|
/** CLI flags of the universal output controls that shape a read, which a mutation retry must drop. */
|
|
283
242
|
export declare const READ_OUTPUT_SHAPING_CONTROL_FLAGS:readonly string[];
|
|
284
243
|
/** Reject malformed or mutation-scoped universal output controls before command execution. */
|
|
@@ -300,10 +259,7 @@ export declare function readOutputIncludeModeOptions(command:string):ReadonlyMap
|
|
|
300
259
|
* identical to the legacy flag it replaces, and return the field selectors that
|
|
301
260
|
* remain for post-execution projection.
|
|
302
261
|
*/
|
|
303
|
-
export declare function applyReadOutputIncludeModes(command:string,includeValue:unknown,commandOptions:Record<string,unknown>):{
|
|
304
|
-
selectors:string[];
|
|
305
|
-
modes:string[];
|
|
306
|
-
};
|
|
262
|
+
export declare function applyReadOutputIncludeModes(command:string,includeValue:unknown,commandOptions:Record<string,unknown>):{selectors:string[];modes:string[];};
|
|
307
263
|
/**
|
|
308
264
|
* Resolve canonical include modes against one combined options bag, rewriting
|
|
309
265
|
* the include value in place to the selectors that remain.
|
|
@@ -314,11 +270,11 @@ modes:string[];
|
|
|
314
270
|
*/
|
|
315
271
|
export declare function normalizeReadOutputIncludeModeOptions(command:string,options:Record<string,unknown>):void;
|
|
316
272
|
/** Resolve canonical and compatibility controls into the universal dimension set. */
|
|
317
|
-
export declare function resolveReadOutputDimensions(command:string,options:Record<string,unknown>):PmResolvedReadOutputDimensions
|
|
273
|
+
export declare function resolveReadOutputDimensions(command:string,options:Record<string,unknown>):PmResolvedReadOutputDimensions|undefined;
|
|
318
274
|
/** Recompute read and optional session receipts after a final envelope projection. */
|
|
319
275
|
export declare function stabilizeReadOutputReceiptEstimates(result:Record<string,unknown>,options:Record<string,unknown>):Record<string,unknown>;
|
|
320
276
|
/** Apply universal field, row, and token bounds and attach an exact receipt. */
|
|
321
|
-
export declare function applyReadOutputDimensions<Result extends Record<string,unknown>,Options extends Record<string,unknown
|
|
277
|
+
export declare function applyReadOutputDimensions<Result extends Record<string,unknown>,Options extends Record<string,unknown>=Record<string,unknown>>(command:string,options:Options,result:Result):ReadOutputResultForSession<Result,Options>;
|
|
322
278
|
/**
|
|
323
279
|
* Whether a read envelope withheld its requested result for a budget: the
|
|
324
280
|
* shared `output_budget_exceeded` branch or an omitted read-intent result.
|
|
@@ -328,4 +284,4 @@ export declare function isReadResultOmittedForBudget(result:unknown):boolean;
|
|
|
328
284
|
/** Narrow a universal read result to its budget-omission branch. */
|
|
329
285
|
export declare function isReadOutputBudgetExceeded(result:unknown):result is PmReadOutputBudgetExceeded;
|
|
330
286
|
/** Resolve only the canonical renderer override for shared CLI output code. */
|
|
331
|
-
export declare function resolveReadOutputEncoding(command:string,options:Record<string,unknown>):"json"
|
|
287
|
+
export declare function resolveReadOutputEncoding(command:string,options:Record<string,unknown>):"json"|"toon"|undefined;
|
|
@@ -5,12 +5,11 @@
|
|
|
5
5
|
* envelopes, including dot-delimited nested paths used by graph projections.
|
|
6
6
|
*/
|
|
7
7
|
/** One declared array or object-map row collection in a read envelope. */
|
|
8
|
-
export interface PmReadOutputRowCollection
|
|
8
|
+
export interface PmReadOutputRowCollection{
|
|
9
9
|
/** Dot-delimited path published by the envelope row contract. */
|
|
10
10
|
path:string;
|
|
11
11
|
/** Array rows or a keyed row map stored at {@link path}. */
|
|
12
|
-
value:unknown[]
|
|
13
|
-
}
|
|
12
|
+
value:unknown[]|Record<string,unknown>;}
|
|
14
13
|
/** Replace one declared row collection with a suffix beginning at an offset. */
|
|
15
14
|
export declare function sliceReadOutputRowCollection(result:Record<string,unknown>,rowPath:string,offset:number,end?:number):Record<string,unknown>;
|
|
16
15
|
/** Resolve declared row paths, falling back to top-level array properties. */
|
|
@@ -38,17 +37,14 @@ export declare function countReadOutputRows(result:Record<string,unknown>):numbe
|
|
|
38
37
|
* Transform every declared row while preserving collection keys and cloning
|
|
39
38
|
* only the owner objects along paths that changed.
|
|
40
39
|
*/
|
|
41
|
-
export declare function mapReadOutputRows(result:Record<string,unknown>,transform:(row:unknown,path:string,index:number)
|
|
40
|
+
export declare function mapReadOutputRows(result:Record<string,unknown>,transform:(row:unknown,path:string,index:number)=> unknown):Record<string,unknown>;
|
|
42
41
|
/**
|
|
43
42
|
* Bound every declared row collection independently and report truncation.
|
|
44
43
|
* A path named by `retainsTail` keeps its newest (last) rows instead of its
|
|
45
44
|
* first rows, matching the producer's own latest-N `--limit`.
|
|
46
45
|
*/
|
|
47
|
-
export declare function boundReadOutputRows(result:Record<string,unknown>,amount:number,retainsTail?:(path:string)
|
|
48
|
-
result:Record<string,unknown>;
|
|
49
|
-
truncated:boolean;
|
|
50
|
-
};
|
|
46
|
+
export declare function boundReadOutputRows(result:Record<string,unknown>,amount:number,retainsTail?:(path:string)=> boolean):{result:Record<string,unknown>;truncated:boolean;};
|
|
51
47
|
/** Retain compact producer classifications across serialized projection boundaries. */
|
|
52
48
|
export declare function rememberReadOutputFocusRows(result:Record<string,unknown>,rows:readonly Record<string,unknown>[]):void;
|
|
53
49
|
/** Refresh delivered counters, preserving full-match totals and hidden classifications. */
|
|
54
|
-
export declare function refreshReadOutputDeliveredCounts(result:Record<string,unknown>,source?:Record<string,unknown>):void;
|
|
50
|
+
export declare function refreshReadOutputDeliveredCounts(result:Record<string,unknown>,source?:Record<string,unknown>):void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Versioned state supplied to a sequence of related read invocations. */
|
|
2
|
-
export interface PmReadOutputSessionState
|
|
2
|
+
export interface PmReadOutputSessionState{
|
|
3
3
|
/** Session-state schema version. */
|
|
4
4
|
version:1;
|
|
5
5
|
/** Caller-selected request-group identity. */
|
|
@@ -9,19 +9,17 @@ token_budget:number;
|
|
|
9
9
|
/** Tokens already spent by earlier invocations. */
|
|
10
10
|
spent_tokens:number;
|
|
11
11
|
/** Item facts already serialized in full during this session. */
|
|
12
|
-
seen_item_ids:string[];
|
|
13
|
-
}
|
|
12
|
+
seen_item_ids:string[];}
|
|
14
13
|
/** Lightweight row emitted instead of repeating a previously served item. */
|
|
15
|
-
export interface PmReadOutputSessionReference
|
|
14
|
+
export interface PmReadOutputSessionReference{
|
|
16
15
|
/** Stable item identity retained for joins and follow-up reads. */
|
|
17
16
|
id:string;
|
|
18
17
|
/** Resolvable reference to the session fact already in caller context. */
|
|
19
|
-
context_ref:string;
|
|
20
|
-
}
|
|
18
|
+
context_ref:string;}
|
|
21
19
|
/** Narrow a delivered reference before accessing the original row's fields. */
|
|
22
20
|
export declare function isReadOutputSessionReference(value:unknown):value is PmReadOutputSessionReference;
|
|
23
21
|
/** Receipt proving cross-call suppression and budget accounting. */
|
|
24
|
-
export interface PmReadOutputSessionReceipt
|
|
22
|
+
export interface PmReadOutputSessionReceipt{
|
|
25
23
|
/** Session-receipt schema version. */
|
|
26
24
|
contract_version:1;
|
|
27
25
|
/** Caller-selected request-group identity. */
|
|
@@ -57,17 +55,16 @@ reference_format:"session:<session-id>:<item-id>";
|
|
|
57
55
|
/** Command that restores a referenced item when prior context is unavailable. */
|
|
58
56
|
restore_reference_with:"pm get <item-id> --depth brief";
|
|
59
57
|
/** Caller-carried state for the next read in the same request group. */
|
|
60
|
-
next_state:PmReadOutputSessionState;
|
|
61
|
-
}
|
|
58
|
+
next_state:PmReadOutputSessionState;}
|
|
62
59
|
/** Smallest session ceiling that can carry a useful result and both receipts. */
|
|
63
|
-
export declare const PM_READ_OUTPUT_SESSION_MIN_TOKENS
|
|
60
|
+
export declare const PM_READ_OUTPUT_SESSION_MIN_TOKENS=256;
|
|
64
61
|
/** Maximum caller-carried served-item identities accepted in one session state. */
|
|
65
|
-
export declare const PM_READ_OUTPUT_SESSION_MAX_SEEN_ITEM_IDS
|
|
62
|
+
export declare const PM_READ_OUTPUT_SESSION_MAX_SEEN_ITEM_IDS=10000;
|
|
66
63
|
/** Parse and strictly validate a JSON string or typed session-state object. */
|
|
67
|
-
export declare function parseReadOutputSession(value:unknown):PmReadOutputSessionState
|
|
64
|
+
export declare function parseReadOutputSession(value:unknown):PmReadOutputSessionState|undefined;
|
|
68
65
|
/** Replace previously served item rows with compact, resolvable references. */
|
|
69
66
|
export declare function applyReadOutputSessionReferences(result:Record<string,unknown>,state:PmReadOutputSessionState):Record<string,unknown>;
|
|
70
67
|
/** Attach a fixed-point session receipt and return the exact charged tokens. */
|
|
71
|
-
export declare function attachReadOutputSessionReceipt(result:Record<string,unknown>,state:PmReadOutputSessionState,format?:"json"
|
|
68
|
+
export declare function attachReadOutputSessionReceipt(result:Record<string,unknown>,state:PmReadOutputSessionState,format?:"json"|"toon"):Record<string,unknown>;
|
|
72
69
|
/** Return the unspent group budget available to the current invocation. */
|
|
73
|
-
export declare function readOutputSessionRemainingTokens(state:PmReadOutputSessionState):number;
|
|
70
|
+
export declare function readOutputSessionRemainingTokens(state:PmReadOutputSessionState):number;
|
|
@@ -4,10 +4,9 @@
|
|
|
4
4
|
* Provides exact, deterministic graph analytics with explicit semantics and
|
|
5
5
|
* provenance suitable for planning, impact analysis, and context selection.
|
|
6
6
|
*/
|
|
7
|
-
import type
|
|
8
|
-
import { RelationshipGraph,RelationshipKindRegistry,type RelationshipEdge,type RelationshipQueryOptions } from "./relationships.js";
|
|
7
|
+
import type{RelationshipSnapshot}from "./relationship-history.js";import{RelationshipGraph,RelationshipKindRegistry,type RelationshipEdge,type RelationshipQueryOptions}from "./relationships.js";
|
|
9
8
|
/** Exact execution-graph analysis over registered ordering kinds. */
|
|
10
|
-
export interface RelationshipExecutionAnalysis
|
|
9
|
+
export interface RelationshipExecutionAnalysis{
|
|
11
10
|
/** Whether the result is exact rather than sampled or approximate. */
|
|
12
11
|
exact:true;
|
|
13
12
|
/** Whether the order-bearing graph is acyclic. */
|
|
@@ -27,22 +26,17 @@ criticalPathLength:number;
|
|
|
27
26
|
/** Strongly connected order-bearing components that represent cycles. */
|
|
28
27
|
cycles:string[][];
|
|
29
28
|
/** Semantic provenance for the analysis. */
|
|
30
|
-
provenance:{
|
|
31
|
-
algorithm:"kahn-longest-path";
|
|
32
|
-
edgeFamily:"ordering";
|
|
33
|
-
};
|
|
34
|
-
}
|
|
29
|
+
provenance:{algorithm:"kahn-longest-path";edgeFamily:"ordering";};}
|
|
35
30
|
/** One affected node with its exact shortest explanation path. */
|
|
36
|
-
export interface RelationshipImpactRow
|
|
31
|
+
export interface RelationshipImpactRow{
|
|
37
32
|
/** Affected node identifier. */
|
|
38
33
|
id:string;
|
|
39
34
|
/** Shortest relationship distance from the root. */
|
|
40
35
|
distance:number;
|
|
41
36
|
/** Exact path explaining why the node is affected. */
|
|
42
|
-
path:string[];
|
|
43
|
-
}
|
|
37
|
+
path:string[];}
|
|
44
38
|
/** Bounded reverse- or forward-impact result. */
|
|
45
|
-
export interface RelationshipImpactAnalysis
|
|
39
|
+
export interface RelationshipImpactAnalysis{
|
|
46
40
|
/** Impact origin. */
|
|
47
41
|
root:string;
|
|
48
42
|
/** Deterministic affected-node rows. */
|
|
@@ -54,13 +48,9 @@ truncated:boolean;
|
|
|
54
48
|
/** Cursor resuming after the final returned impact row. */
|
|
55
49
|
nextCursor?:string;
|
|
56
50
|
/** Query work retained for performance and explainability. */
|
|
57
|
-
cost:{
|
|
58
|
-
visitedNodes:number;
|
|
59
|
-
inspectedEdges:number;
|
|
60
|
-
};
|
|
61
|
-
}
|
|
51
|
+
cost:{visitedNodes:number;inspectedEdges:number;};}
|
|
62
52
|
/** Exact structural summary of the complete graph snapshot. */
|
|
63
|
-
export interface RelationshipKnowledgeAnalysis
|
|
53
|
+
export interface RelationshipKnowledgeAnalysis{
|
|
64
54
|
/** Weakly connected components, largest then lexicographic. */
|
|
65
55
|
components:string[][];
|
|
66
56
|
/** Strongly connected components over directed stored edges. */
|
|
@@ -68,20 +58,13 @@ stronglyConnected:string[][];
|
|
|
68
58
|
/** Nodes with no relationship edges. */
|
|
69
59
|
orphans:string[];
|
|
70
60
|
/** Maximum-degree nodes and their unique-neighbor degree. */
|
|
71
|
-
hubs:{
|
|
72
|
-
id:string;
|
|
73
|
-
degree:number;
|
|
74
|
-
}[];
|
|
61
|
+
hubs:{id:string;degree:number;}[];
|
|
75
62
|
/** Whether the result is exact. */
|
|
76
63
|
exact:true;
|
|
77
64
|
/** Semantic provenance for the analysis. */
|
|
78
|
-
provenance:{
|
|
79
|
-
algorithm:"component-degree";
|
|
80
|
-
edgeFamily:"all";
|
|
81
|
-
};
|
|
82
|
-
}
|
|
65
|
+
provenance:{algorithm:"component-degree";edgeFamily:"all";};}
|
|
83
66
|
/** Edge-level delta between two immutable snapshots. */
|
|
84
|
-
export interface RelationshipSnapshotComparison
|
|
67
|
+
export interface RelationshipSnapshotComparison{
|
|
85
68
|
/** Earlier snapshot version. */
|
|
86
69
|
fromVersion:number;
|
|
87
70
|
/** Later snapshot version. */
|
|
@@ -93,18 +76,15 @@ removed:RelationshipEdge[];
|
|
|
93
76
|
/** Number of byte-equivalent edges retained. */
|
|
94
77
|
unchangedCount:number;
|
|
95
78
|
/** Whether the comparison is exact. */
|
|
96
|
-
exact:true;
|
|
97
|
-
}
|
|
79
|
+
exact:true;}
|
|
98
80
|
/** Registry override for custom domain semantics. */
|
|
99
|
-
export interface RelationshipAnalyticsOptions
|
|
81
|
+
export interface RelationshipAnalyticsOptions{
|
|
100
82
|
/** Registry used to interpret ordering direction and custom kinds. */
|
|
101
|
-
registry?:RelationshipKindRegistry;
|
|
102
|
-
}
|
|
83
|
+
registry?:RelationshipKindRegistry;}
|
|
103
84
|
/** Impact-specific pagination layered onto the shared graph query controls. */
|
|
104
|
-
export interface RelationshipImpactOptions extends RelationshipQueryOptions
|
|
85
|
+
export interface RelationshipImpactOptions extends RelationshipQueryOptions{
|
|
105
86
|
/** Resume emission from an opaque cursor bound to the traversal semantics. */
|
|
106
|
-
after?:string;
|
|
107
|
-
}
|
|
87
|
+
after?:string;}
|
|
108
88
|
/** Analyze registered order-bearing relationships without treating associative cycles as blockers. */
|
|
109
89
|
export declare function analyzeRelationshipExecution(graph:RelationshipGraph,options?:RelationshipAnalyticsOptions):RelationshipExecutionAnalysis;
|
|
110
90
|
/** Compute bounded impact rows and exact shortest explanation paths. */
|
|
@@ -112,4 +92,4 @@ export declare function analyzeGraphImpact(graph:RelationshipGraph,root:string,o
|
|
|
112
92
|
/** Analyze weak/strong components, isolates, and exact unique-neighbor hubs. */
|
|
113
93
|
export declare function analyzeKnowledgeGraph(graph:RelationshipGraph):RelationshipKnowledgeAnalysis;
|
|
114
94
|
/** Compare two immutable relationship snapshots by full normalized edge value. */
|
|
115
|
-
export declare function compareRelationshipSnapshots(before:RelationshipSnapshot,after:RelationshipSnapshot):RelationshipSnapshotComparison;
|
|
95
|
+
export declare function compareRelationshipSnapshots(before:RelationshipSnapshot,after:RelationshipSnapshot):RelationshipSnapshotComparison;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{RelationshipGraph,RelationshipKindRegistry,type RelationshipEdge,type RelationshipTraversalDirection}from "./relationships.js";
|
|
2
2
|
/** Canonical default shared by the kernel and rendered-budget recovery. */
|
|
3
|
-
export declare const DEFAULT_RELATIONSHIP_CONTEXT_TOKEN_BUDGET
|
|
3
|
+
export declare const DEFAULT_RELATIONSHIP_CONTEXT_TOKEN_BUDGET=1200;
|
|
4
4
|
/** Semantic family explaining why a node or edge participates in graph context. */
|
|
5
|
-
export type RelationshipContextRole
|
|
5
|
+
export type RelationshipContextRole="prerequisite"|"dependent"|"ancestor"|"descendant"|"provenance"|"related";
|
|
6
6
|
/**
|
|
7
7
|
* Completeness marker for one graph-context packet.
|
|
8
8
|
*
|
|
@@ -10,9 +10,9 @@ export type RelationshipContextRole = "prerequisite" | "dependent" | "ancestor"
|
|
|
10
10
|
* the remaining values are reserved so index-backed, sampled, or policy-redacted
|
|
11
11
|
* providers can report their result quality through the same contract.
|
|
12
12
|
*/
|
|
13
|
-
export type RelationshipContextCompleteness
|
|
13
|
+
export type RelationshipContextCompleteness="complete"|"truncated"|"sampled"|"approximate"|"stale_index"|"redacted";
|
|
14
14
|
/** Caller-owned compact node details joined into graph context. */
|
|
15
|
-
export interface RelationshipContextNodeDetails
|
|
15
|
+
export interface RelationshipContextNodeDetails{
|
|
16
16
|
/** Stable graph node identifier. */
|
|
17
17
|
id:string;
|
|
18
18
|
/** Optional display title. */
|
|
@@ -20,10 +20,9 @@ title?:string;
|
|
|
20
20
|
/** Optional lifecycle status. */
|
|
21
21
|
status?:string;
|
|
22
22
|
/** Optional evidence pointers such as files, tests, or history ids. */
|
|
23
|
-
evidence?:readonly string[];
|
|
24
|
-
}
|
|
23
|
+
evidence?:readonly string[];}
|
|
25
24
|
/** One selected graph-context node with explainable inclusion. */
|
|
26
|
-
export interface RelationshipContextNode extends RelationshipContextNodeDetails
|
|
25
|
+
export interface RelationshipContextNode extends RelationshipContextNodeDetails{
|
|
27
26
|
/** Shortest bounded distance from the root. */
|
|
28
27
|
distance:number;
|
|
29
28
|
/** Semantic family of this node relative to its discovery counterpart. */
|
|
@@ -31,10 +30,9 @@ role:RelationshipContextRole;
|
|
|
31
30
|
/** Node through which bounded traversal first discovered this node. */
|
|
32
31
|
via:string;
|
|
33
32
|
/** Concise deterministic reasons the node was selected. */
|
|
34
|
-
reasons:string[];
|
|
35
|
-
}
|
|
33
|
+
reasons:string[];}
|
|
36
34
|
/** Counts-first packet overview served before any row payload. */
|
|
37
|
-
export interface RelationshipContextSummary
|
|
35
|
+
export interface RelationshipContextSummary{
|
|
38
36
|
/** Root node identifier. */
|
|
39
37
|
rootId:string;
|
|
40
38
|
/** Root lifecycle status when the caller supplied node details. */
|
|
@@ -56,10 +54,9 @@ omittedEdges:number;
|
|
|
56
54
|
/** Root evidence pointers promoted into the packet. */
|
|
57
55
|
evidenceCount:number;
|
|
58
56
|
/** Whether a continuation cursor is available. */
|
|
59
|
-
hasMore:boolean;
|
|
60
|
-
}
|
|
57
|
+
hasMore:boolean;}
|
|
61
58
|
/** Controls for bounded graph-context assembly. */
|
|
62
|
-
export interface RelationshipContextOptions
|
|
59
|
+
export interface RelationshipContextOptions{
|
|
63
60
|
/** Traversal direction relative to each visited node. */
|
|
64
61
|
direction?:RelationshipTraversalDirection;
|
|
65
62
|
/** Optional registered kind filter. */
|
|
@@ -77,10 +74,9 @@ cursor?:string;
|
|
|
77
74
|
/** Registry used to explain custom relationship semantics. */
|
|
78
75
|
registry?:RelationshipKindRegistry;
|
|
79
76
|
/** Abort signal checked during traversal. */
|
|
80
|
-
signal?:AbortSignal;
|
|
81
|
-
}
|
|
77
|
+
signal?:AbortSignal;}
|
|
82
78
|
/** Explainable graph context packet. */
|
|
83
|
-
export interface RelationshipContextResult
|
|
79
|
+
export interface RelationshipContextResult{
|
|
84
80
|
/** Root node details. */
|
|
85
81
|
root:RelationshipContextNodeDetails;
|
|
86
82
|
/** Counts-first overview of the packet. */
|
|
@@ -92,20 +88,6 @@ edges:RelationshipEdge[];
|
|
|
92
88
|
/** Root evidence pointers promoted for immediate consumption. */
|
|
93
89
|
evidence:string[];
|
|
94
90
|
/** Completeness, continuation, and cost envelope. */
|
|
95
|
-
meta:{
|
|
96
|
-
exact:true;
|
|
97
|
-
truncated:boolean;
|
|
98
|
-
completeness:RelationshipContextCompleteness;
|
|
99
|
-
nodeLimit:number;
|
|
100
|
-
edgeLimit:number;
|
|
101
|
-
tokenBudget:number;
|
|
102
|
-
usedTokens:number;
|
|
103
|
-
visitedNodes:number;
|
|
104
|
-
inspectedEdges:number;
|
|
105
|
-
omittedNodes:number;
|
|
106
|
-
omittedEdges:number;
|
|
107
|
-
nextCursor?:string;
|
|
108
|
-
};
|
|
109
|
-
}
|
|
91
|
+
meta:{exact:true;truncated:boolean;completeness:RelationshipContextCompleteness;nodeLimit:number;edgeLimit:number;tokenBudget:number;usedTokens:number;visitedNodes:number;inspectedEdges:number;omittedNodes:number;omittedEdges:number;nextCursor?:string;};}
|
|
110
92
|
/** Build one deterministic bounded graph-context packet with continuation. */
|
|
111
|
-
export declare function buildRelationshipContext(graph:RelationshipGraph,rootId:string,details:readonly RelationshipContextNodeDetails[],options?:RelationshipContextOptions):RelationshipContextResult;
|
|
93
|
+
export declare function buildRelationshipContext(graph:RelationshipGraph,rootId:string,details:readonly RelationshipContextNodeDetails[],options?:RelationshipContextOptions):RelationshipContextResult;
|