@unbrained/pm-cli 2026.8.12 → 2026.8.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (218) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/CHANGELOG.md +162 -111
  3. package/dist/cli/error-guidance.js +4 -8
  4. package/dist/cli/main.js +40 -3
  5. package/dist/cli/register-assurance.js +28 -17
  6. package/dist/cli-bundle/bundle-manifest.json +141 -173
  7. package/dist/cli-bundle/chunks/chunk-BBOFSVAK.js +197 -0
  8. package/dist/cli-bundle/chunks/chunk-BFALV3YP.js +5 -0
  9. package/dist/cli-bundle/chunks/{chunk-WLAHPSOX.js → chunk-FIW4P64F.js} +2 -2
  10. package/dist/cli-bundle/chunks/{chunk-BM5YJ2UW.js → chunk-G5JUB66K.js} +52 -52
  11. package/dist/cli-bundle/chunks/chunk-SBRKH6OR.js +2 -0
  12. package/dist/cli-bundle/chunks/chunk-TMJ7URWS.js +13 -0
  13. package/dist/cli-bundle/chunks/chunk-TXMEUUUY.js +8 -0
  14. package/dist/cli-bundle/chunks/{chunk-KOQMGCTA.js → chunk-XAVMOK6B.js} +50 -50
  15. package/dist/cli-bundle/chunks/chunk-YAMTJL6Y.js +34 -0
  16. package/dist/cli-bundle/chunks/chunk-YSVSMJ2B.js +2 -0
  17. package/dist/cli-bundle/chunks/{register-list-query-XPCJRUUD.js → register-list-query-T3EHHNNV.js} +2 -2
  18. package/dist/cli-bundle/chunks/{register-mutation-4RJCBKRS.js → register-mutation-E27WCLSZ.js} +2 -2
  19. package/dist/cli-bundle/chunks/register-operations-4R6I7CPY.js +2 -0
  20. package/dist/cli-bundle/chunks/{register-setup-LLHAKP2V.js → register-setup-3YXZ444E.js} +2 -2
  21. package/dist/cli-bundle/focused-chunks/{chunk-JAFRIWVF.js → chunk-4DQ2YERC.js} +4 -4
  22. package/dist/cli-bundle/focused-chunks/chunk-F43TT2QQ.js +8 -0
  23. package/dist/cli-bundle/focused-chunks/chunk-K7RWWOAG.js +4 -0
  24. package/dist/cli-bundle/focused-chunks/chunk-KFSZ3BP6.js +16 -0
  25. package/dist/cli-bundle/focused-chunks/{chunk-KHM2CS2C.js → chunk-KSEDUWVZ.js} +2 -2
  26. package/dist/cli-bundle/focused-chunks/chunk-KYUQGTSB.js +2 -0
  27. package/dist/cli-bundle/focused-chunks/{chunk-ZMGWAYH7.js → chunk-LZ4MV3RH.js} +2 -2
  28. package/dist/cli-bundle/focused-chunks/chunk-PGXJQLCT.js +155 -0
  29. package/dist/cli-bundle/focused-chunks/{chunk-RWPAWUOT.js → chunk-PPFGQDSI.js} +2 -2
  30. package/dist/cli-bundle/focused-chunks/chunk-Q4YY3XNF.js +2 -0
  31. package/dist/cli-bundle/focused-chunks/chunk-QK753U3U.js +46 -0
  32. package/dist/cli-bundle/focused-chunks/chunk-QUMB2J27.js +2 -0
  33. package/dist/cli-bundle/focused-chunks/chunk-SM7MTG27.js +2 -0
  34. package/dist/cli-bundle/focused-chunks/{chunk-GQW4BPUT.js → chunk-WCVE2NIG.js} +2 -2
  35. package/dist/cli-bundle/focused-chunks/chunk-XDNAW5OI.js +18 -0
  36. package/dist/cli-bundle/focused-chunks/{chunk-YIAXMC3T.js → chunk-YOOI3UZX.js} +2 -2
  37. package/dist/cli-bundle/focused-chunks/chunk-ZM6TZVHC.js +2 -0
  38. package/dist/cli-bundle/main.js +13 -13
  39. package/dist/cli-bundle/sdk-authoring.js +1 -1
  40. package/dist/cli-bundle/sdk-contracts.js +1 -1
  41. package/dist/cli-bundle/sdk-core.js +45 -41
  42. package/dist/cli-bundle/sdk-governance.js +1 -1
  43. package/dist/cli-bundle/sdk-graph.js +1 -1
  44. package/dist/cli-bundle/sdk-merge.js +109 -1
  45. package/dist/cli-bundle/sdk-query.js +1 -1
  46. package/dist/cli-bundle/sdk-runtime.js +1 -1
  47. package/dist/cli-bundle/sdk-testing.js +1 -1
  48. package/dist/cli-bundle/sdk.js +2 -2
  49. package/dist/core/checkpoint/checkpoint-gc.js +7 -12
  50. package/dist/core/extensions/activation-summary-markdown.js +5 -4
  51. package/dist/core/extensions/activation-summary.d.ts +2 -0
  52. package/dist/core/extensions/activation-summary.js +6 -2
  53. package/dist/core/extensions/capability-usage.d.ts +1 -1
  54. package/dist/core/extensions/capability-usage.js +4 -3
  55. package/dist/core/extensions/contribution-inventory.d.ts +1 -0
  56. package/dist/core/extensions/contribution-inventory.js +6 -2
  57. package/dist/core/extensions/extension-registries.js +3 -2
  58. package/dist/core/extensions/extension-types.d.ts +83 -1
  59. package/dist/core/extensions/extension-types.js +3 -2
  60. package/dist/core/extensions/loader.d.ts +2 -8
  61. package/dist/core/extensions/loader.js +53 -144
  62. package/dist/core/extensions/registration-values.d.ts +43 -0
  63. package/dist/core/extensions/registration-values.js +210 -0
  64. package/dist/core/extensions/runtime-registrations.d.ts +3 -1
  65. package/dist/core/extensions/runtime-registrations.js +12 -2
  66. package/dist/core/fs/fs-utils.d.ts +2 -0
  67. package/dist/core/fs/fs-utils.js +7 -3
  68. package/dist/core/history/drift-cache.js +4 -3
  69. package/dist/core/history/drift-scan.d.ts +6 -0
  70. package/dist/core/history/drift-scan.js +76 -58
  71. package/dist/core/history/workspace-history.d.ts +59 -0
  72. package/dist/core/history/workspace-history.js +197 -10
  73. package/dist/core/lock/lock-gc.js +8 -13
  74. package/dist/core/lock/lock.js +5 -4
  75. package/dist/core/output/output.js +12 -4
  76. package/dist/core/search/vector-stores.js +6 -11
  77. package/dist/core/store/item-metadata-cache.js +4 -4
  78. package/dist/core/telemetry/runtime.d.ts +6 -0
  79. package/dist/core/telemetry/runtime.js +101 -30
  80. package/dist/sdk/agent/command-recovery.d.ts +2 -0
  81. package/dist/sdk/agent/command-recovery.js +10 -2
  82. package/dist/sdk/annotations.js +4 -4
  83. package/dist/sdk/cli-contracts/completeness.js +9 -3
  84. package/dist/sdk/cli-contracts/enum-contracts.d.ts +1 -1
  85. package/dist/sdk/cli-contracts/flag-contracts.js +6 -3
  86. package/dist/sdk/cli-contracts/runtime-contracts.d.ts +6 -1
  87. package/dist/sdk/cli-contracts/runtime-contracts.js +155 -60
  88. package/dist/sdk/cli-contracts/schemas/assurance-definition.d.ts +32 -0
  89. package/dist/sdk/cli-contracts/schemas/assurance-definition.js +25 -2
  90. package/dist/sdk/cli-contracts/tool-parameter-tables.js +35 -5
  91. package/dist/sdk/cli-contracts/tool-schema.js +17 -2
  92. package/dist/sdk/cli-program.js +3 -3
  93. package/dist/sdk/comments.js +4 -3
  94. package/dist/sdk/compile-cache.js +4 -3
  95. package/dist/sdk/compose.d.ts +3 -1
  96. package/dist/sdk/compose.js +16 -2
  97. package/dist/sdk/context-relevance.js +12 -4
  98. package/dist/sdk/context-signal-store.js +4 -3
  99. package/dist/sdk/extension/install-runtime.js +4 -4
  100. package/dist/sdk/extension/managed-state.js +4 -3
  101. package/dist/sdk/extension-contracts.d.ts +1 -1
  102. package/dist/sdk/flag-invocation-contracts.js +5 -6
  103. package/dist/sdk/generated/generated-error-code-catalog-part-1.js +14 -2
  104. package/dist/sdk/governance/assurance-action.d.ts +27 -3
  105. package/dist/sdk/governance/assurance-action.js +112 -28
  106. package/dist/sdk/governance/assurance-mutation-error.d.ts +7 -0
  107. package/dist/sdk/governance/assurance-mutation-error.js +25 -2
  108. package/dist/sdk/governance/assurance-presets.d.ts +54 -0
  109. package/dist/sdk/governance/assurance-presets.js +136 -0
  110. package/dist/sdk/governance/assurance-runtime.d.ts +4 -0
  111. package/dist/sdk/governance/assurance-runtime.js +109 -8
  112. package/dist/sdk/governance/assurance.d.ts +39 -0
  113. package/dist/sdk/governance/assurance.js +145 -6
  114. package/dist/sdk/governance/gc.js +5 -11
  115. package/dist/sdk/governance/health.js +18 -6
  116. package/dist/sdk/governance/validate-history-drift.d.ts +7 -0
  117. package/dist/sdk/governance/validate-history-drift.js +68 -0
  118. package/dist/sdk/governance/validate.js +6 -48
  119. package/dist/sdk/graph/assembly.d.ts +23 -0
  120. package/dist/sdk/graph/assembly.js +54 -2
  121. package/dist/sdk/graph/durable-cache.js +91 -3
  122. package/dist/sdk/graph/governance-contracts.d.ts +12 -0
  123. package/dist/sdk/graph/governance-contracts.js +29 -0
  124. package/dist/sdk/graph/governance.d.ts +51 -3
  125. package/dist/sdk/graph/governance.js +216 -35
  126. package/dist/sdk/graph/index.d.ts +2 -2
  127. package/dist/sdk/graph/index.js +4 -4
  128. package/dist/sdk/graph/mutation-advisory.js +15 -7
  129. package/dist/sdk/graph/remediation.js +12 -2
  130. package/dist/sdk/guide.js +4 -4
  131. package/dist/sdk/history-read.d.ts +8 -0
  132. package/dist/sdk/history-read.js +2 -2
  133. package/dist/sdk/index.d.ts +3 -2
  134. package/dist/sdk/index.js +5 -4
  135. package/dist/sdk/linked-artifacts.d.ts +2 -0
  136. package/dist/sdk/linked-artifacts.js +29 -4
  137. package/dist/sdk/merge/install.js +5 -4
  138. package/dist/sdk/query/activity.js +4 -3
  139. package/dist/sdk/query/history.js +20 -3
  140. package/dist/sdk/read-output-budget.d.ts +2 -0
  141. package/dist/sdk/read-output-budget.js +12 -5
  142. package/dist/sdk/read-output-contracts.d.ts +61 -5
  143. package/dist/sdk/read-output-contracts.js +210 -28
  144. package/dist/sdk/read-output-rows.d.ts +11 -0
  145. package/dist/sdk/read-output-rows.js +47 -2
  146. package/dist/sdk/relationship-history.js +5 -5
  147. package/dist/sdk/runtime-primitives.d.ts +1 -1
  148. package/dist/sdk/runtime-primitives.js +3 -3
  149. package/dist/sdk/runtime.js +5 -3
  150. package/dist/sdk/schema-migration.js +4 -4
  151. package/dist/sdk/test/execution.js +4 -4
  152. package/dist/sdk/workspace-memory.js +4 -4
  153. package/dist/sdk/workspace-snapshot.js +8 -14
  154. package/dist/sdk/workspace-transaction-gc.js +4 -9
  155. package/dist/sdk/workspace-transaction.js +4 -4
  156. package/dist/sdk/workspace.js +4 -3
  157. package/docs/ASSURANCE.md +163 -3
  158. package/docs/COMMANDS.md +31 -2
  159. package/docs/CONFIGURATION.md +2 -0
  160. package/docs/EXTENSIONS.md +11 -12
  161. package/docs/READ_OUTPUT_CONTRACTS.md +44 -8
  162. package/docs/RELATIONSHIP_GRAPH.md +34 -4
  163. package/docs/SDK.md +29 -8
  164. package/docs/SDK_CONTEXT_INTEGRITY.md +32 -1
  165. package/docs/TESTING.md +47 -16
  166. package/docs/performance/sdk-entrypoint-import-costs.md +20 -13
  167. package/marketplace.json +2 -2
  168. package/package.json +6 -6
  169. package/packages/pm-beads/extensions/beads/index.ts +1 -0
  170. package/packages/pm-beads/package.json +1 -1
  171. package/packages/pm-calendar/extensions/calendar/index.ts +1 -0
  172. package/packages/pm-calendar/package.json +1 -1
  173. package/packages/pm-command-kit/package.json +1 -1
  174. package/packages/pm-digital-twin/extensions/digital-twin/index.ts +7 -0
  175. package/packages/pm-digital-twin/package.json +1 -1
  176. package/packages/pm-governance-audit/extensions/governance-audit/index.ts +4 -0
  177. package/packages/pm-governance-audit/package.json +1 -1
  178. package/packages/pm-guide-shell/extensions/guide-shell/index.ts +5 -0
  179. package/packages/pm-guide-shell/package.json +1 -1
  180. package/packages/pm-kanban/package.json +1 -1
  181. package/packages/pm-lifecycle-hooks/package.json +1 -1
  182. package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/index.ts +6 -0
  183. package/packages/pm-linked-test-adapters/package.json +1 -1
  184. package/packages/pm-search-advanced/extensions/search-advanced/index.ts +2 -0
  185. package/packages/pm-search-advanced/package.json +1 -1
  186. package/packages/pm-templates/extensions/templates/index.ts +4 -0
  187. package/packages/pm-templates/package.json +1 -1
  188. package/packages/pm-todos/extensions/todos/index.ts +2 -0
  189. package/packages/pm-todos/package.json +1 -1
  190. package/packages/pm-vcs/extensions/vcs/index.ts +7 -0
  191. package/packages/pm-vcs/package.json +1 -1
  192. package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
  193. package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
  194. package/scripts/bundle-cli.mjs +17 -4
  195. package/sdk/public-surface.json +390 -60
  196. package/dist/cli-bundle/chunks/chunk-3PS7X6GS.js +0 -8
  197. package/dist/cli-bundle/chunks/chunk-7KL6KMWF.js +0 -13
  198. package/dist/cli-bundle/chunks/chunk-D55A5AEN.js +0 -33
  199. package/dist/cli-bundle/chunks/chunk-KIKDWECH.js +0 -196
  200. package/dist/cli-bundle/chunks/chunk-R76342NV.js +0 -2
  201. package/dist/cli-bundle/chunks/chunk-RBTK5EZV.js +0 -5
  202. package/dist/cli-bundle/chunks/chunk-VLUQOIDT.js +0 -2
  203. package/dist/cli-bundle/chunks/register-operations-2OGISOVR.js +0 -2
  204. package/dist/cli-bundle/focused-chunks/chunk-2DALMVF7.js +0 -5
  205. package/dist/cli-bundle/focused-chunks/chunk-5OQIMELN.js +0 -155
  206. package/dist/cli-bundle/focused-chunks/chunk-5TAGTDRE.js +0 -2
  207. package/dist/cli-bundle/focused-chunks/chunk-ECADZMVC.js +0 -18
  208. package/dist/cli-bundle/focused-chunks/chunk-EJGXRA6B.js +0 -2
  209. package/dist/cli-bundle/focused-chunks/chunk-FFGSZCPK.js +0 -16
  210. package/dist/cli-bundle/focused-chunks/chunk-ISKOBJCM.js +0 -2
  211. package/dist/cli-bundle/focused-chunks/chunk-KPSXVBDV.js +0 -2
  212. package/dist/cli-bundle/focused-chunks/chunk-KTLOKKCQ.js +0 -2
  213. package/dist/cli-bundle/focused-chunks/chunk-LGYK3NUF.js +0 -8
  214. package/dist/cli-bundle/focused-chunks/chunk-NBLUKITQ.js +0 -4
  215. package/dist/cli-bundle/focused-chunks/chunk-NYLOUPOB.js +0 -2
  216. package/dist/cli-bundle/focused-chunks/chunk-Q4T463SD.js +0 -31
  217. package/dist/cli-bundle/focused-chunks/chunk-QVZVY53N.js +0 -2
  218. package/dist/cli-bundle/focused-chunks/chunk-UTEWXDEQ.js +0 -17
@@ -4,7 +4,7 @@
4
4
  * Implements the pm contracts command surface and its agent-facing runtime behavior.
5
5
  */
6
6
 
7
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="651d4904-cae5-503b-8418-93bc44a413ad")}catch(e){}}();
7
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="c0995490-5838-5c91-af77-9ce387e41a1f")}catch(e){}}();
8
8
  import { EXIT_CODE, SETTINGS_DEFAULTS, PmCliError, activateExtensions, getActiveExtensionRegistrations, loadExtensions, pathExists, commandOptionFlagLabel, resolveCommandOptionPolicyState, resolveItemTypeRegistry, resolveRuntimeFieldRegistry, resolveRuntimeStatusRegistry, getSettingsPath, resolvePmRoot, readSettings, } from "../runtime-primitives.js";
9
9
  import { buildMcpToolContracts, } from "../../mcp/tool-definitions.js";
10
10
  import { ACTIVITY_COMMANDER_STRING_OPTION_CONTRACTS, ACTIVITY_FLAG_CONTRACTS, AGGREGATE_FLAG_CONTRACTS, ASSURANCE_FLAG_CONTRACTS, APPEND_FLAG_CONTRACTS, CALENDAR_COMMANDER_STRING_OPTION_CONTRACTS, CALENDAR_FLAG_CONTRACTS, CLAIM_FLAG_CONTRACTS, CLOSE_TASK_FLAG_CONTRACTS, COMMENTS_FLAG_CONTRACTS, CLOSE_FLAG_CONTRACTS, CLOSE_MANY_FLAG_CONTRACTS, COMPLETION_FLAG_CONTRACTS, CONFIG_FLAG_CONTRACTS, CONTRACTS_FLAG_CONTRACTS, COPY_FLAG_CONTRACTS, CONTEXT_COMMANDER_STRING_OPTION_CONTRACTS, CONTEXT_FLAG_CONTRACTS, CREATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, CREATE_COMMANDER_STRING_OPTION_CONTRACTS, CREATE_FLAG_CONTRACTS, DELETE_FLAG_CONTRACTS, DEPS_FLAG_CONTRACTS, GRAPH_FLAG_CONTRACTS, DOCS_FLAG_CONTRACTS, EXTENSION_ACTIVATE_FLAG_CONTRACTS, EXTENSION_ADOPT_ALL_FLAG_CONTRACTS, EXTENSION_ADOPT_FLAG_CONTRACTS, EXTENSION_CATALOG_FLAG_CONTRACTS, EXTENSION_DEACTIVATE_FLAG_CONTRACTS, EXTENSION_DESCRIBE_FLAG_CONTRACTS, EXTENSION_DOCTOR_FLAG_CONTRACTS, EXTENSION_EXPLORE_FLAG_CONTRACTS, EXTENSION_FLAG_CONTRACTS, EXTENSION_INIT_FLAG_CONTRACTS, EXTENSION_INSTALL_FLAG_CONTRACTS, EXTENSION_MANAGE_FLAG_CONTRACTS, EXTENSION_MIGRATE_FLAG_CONTRACTS, EXTENSION_RELOAD_FLAG_CONTRACTS, EXTENSION_UNINSTALL_FLAG_CONTRACTS, FILES_FLAG_CONTRACTS, FOCUS_FLAG_CONTRACTS, GC_FLAG_CONTRACTS, GET_FLAG_CONTRACTS, GUIDE_FLAG_CONTRACTS, GLOBAL_FLAG_CONTRACTS, HEALTH_FLAG_CONTRACTS, HISTORY_FLAG_CONTRACTS, HISTORY_COMPACT_FLAG_CONTRACTS, HISTORY_REDACT_FLAG_CONTRACTS, HISTORY_REPAIR_FLAG_CONTRACTS, HISTORY_AUTHOR_ACKNOWLEDGE_FLAG_CONTRACTS, INSTALL_FLAG_CONTRACTS, INIT_FLAG_CONTRACTS, ITEM_COMPLETE_FLAG_CONTRACTS, ITEM_MUTATE_FLAG_CONTRACTS, LEARNINGS_FLAG_CONTRACTS, LIST_COMMANDER_STRING_OPTION_CONTRACTS, LIST_FILTER_FLAG_CONTRACTS, MERGE_FLAG_CONTRACTS, NOTES_FLAG_CONTRACTS, PACKAGE_FLAG_CONTRACTS, PACKAGE_INIT_FLAG_CONTRACTS, PM_EXTENSION_CAPABILITY_CONTRACTS, PM_EXTENSION_POLICY_MODE_CONTRACTS, PM_EXTENSION_POLICY_SURFACE_CONTRACTS, PM_EXTENSION_SANDBOX_PROFILE_CONTRACTS, PM_EXTENSION_SERVICE_NAME_CONTRACTS, PM_EXTENSION_TRUST_MODE_CONTRACTS, PM_OUTPUT_DEGRADATION_STEPS, PLAN_FLAG_CONTRACTS, PM_CORE_COMMAND_NAMES, PM_TOOL_ACTIONS, PM_TOOL_PARAMETERS_SCHEMA, REINDEX_FLAG_CONTRACTS, RELEASE_FLAG_CONTRACTS, RESTORE_FLAG_CONTRACTS, SCHEMA_FLAG_CONTRACTS, PROFILE_FLAG_CONTRACTS, SEARCH_COMMANDER_STRING_OPTION_CONTRACTS, EVAL_FLAG_CONTRACTS, WORKSPACE_FLAG_CONTRACTS, NEXT_FLAG_CONTRACTS, SEARCH_FLAG_CONTRACTS, STATS_FLAG_CONTRACTS, DUPLICATES_FLAG_CONTRACTS, START_TASK_FLAG_CONTRACTS, PAUSE_TASK_FLAG_CONTRACTS, TELEMETRY_FLAG_CONTRACTS, TEST_ALL_FLAG_CONTRACTS, TEST_FLAG_CONTRACTS, TEST_RUNS_FLAG_CONTRACTS, UPDATE_COMMANDER_REPEATABLE_OPTION_CONTRACTS, UPDATE_COMMANDER_STRING_OPTION_CONTRACTS, UPDATE_FLAG_CONTRACTS, UPDATE_MANY_FLAG_CONTRACTS, UPGRADE_FLAG_CONTRACTS, VALIDATE_FLAG_CONTRACTS, compactFlagAliasContracts, resolvePmCommandOutputBudget, } from "../cli-contracts.js";
@@ -224,19 +224,33 @@ const COMMAND_INTENTS = new Map([
224
224
  ["activity", "Read activity."],
225
225
  ["aggregate", "Group counts."],
226
226
  ["append", "Append body."],
227
+ ["assurance", "Evaluate assurance."],
228
+ ["beads", "Manage Beads interoperability."],
229
+ ["cal", "Manage calendar integration."],
230
+ ["calendar", "Manage calendar integration."],
231
+ ["changelog", "Generate changelog output."],
227
232
  ["claim", "Claim work."],
228
233
  ["close", "Close work."],
234
+ ["close-many", "Close matching work."],
235
+ ["close-task", "Close task work."],
236
+ ["command-kit", "Inspect command authoring primitives."],
229
237
  ["comments", "Manage comments."],
238
+ ["comments-audit", "Audit comment governance."],
230
239
  ["completion", "Generate shell completions."],
231
240
  ["config", "Manage settings."],
232
241
  ["context", "Build context."],
233
242
  ["contracts", "Inspect contracts."],
234
243
  ["copy", "Copy work."],
235
244
  ["create", "Create work."],
245
+ ["dedupe-audit", "Audit duplicate work."],
246
+ ["dedupe-merge", "Merge duplicate work."],
236
247
  ["delete", "Delete work."],
237
248
  ["deps", "Manage deps."],
238
249
  ["duplicates", "Find duplicate clusters."],
239
250
  ["docs", "Link docs."],
251
+ ["eval", "Run evaluations."],
252
+ ["event", "Manage events."],
253
+ ["events", "Read events."],
240
254
  ["files", "Link files."],
241
255
  ["focus", "Manage focus."],
242
256
  ["gc", "Clean caches."],
@@ -248,26 +262,53 @@ const COMMAND_INTENTS = new Map([
248
262
  ["history", "Inspect history."],
249
263
  ["init", "Initialize workspace."],
250
264
  ["install", "Install packages."],
265
+ ["item", "Mutate work through typed operations."],
251
266
  ["learnings", "Manage learnings."],
252
267
  ["list", "List work."],
268
+ ["list-all", "List work across every status."],
269
+ ["list-blocked", "List blocked work."],
270
+ ["list-canceled", "List canceled work."],
271
+ ["list-closed", "List closed work."],
272
+ ["list-draft", "List draft work."],
273
+ ["list-in-progress", "List in-progress work."],
274
+ ["list-open", "List open work."],
275
+ ["meet", "Record meeting context."],
276
+ ["merge", "Manage tracker merges."],
253
277
  ["next", "Pick next work."],
254
278
  ["notes", "Manage notes."],
279
+ ["normalize", "Normalize tracker data."],
255
280
  ["ops", "Run operations."],
256
281
  ["package", "Manage packages."],
282
+ ["packages", "Manage packages."],
283
+ ["pause-task", "Pause task work."],
257
284
  ["plan", "Manage plans."],
258
285
  ["profile", "Manage profiles."],
259
286
  ["reindex", "Refresh search index."],
260
287
  ["release", "Release claim."],
288
+ ["remind", "Manage reminders."],
261
289
  ["restore", "Restore history."],
262
290
  ["schema", "Customize schema."],
263
291
  ["search", "Search work."],
292
+ ["search-advanced", "Run advanced search."],
293
+ ["start-task", "Start task work."],
264
294
  ["stats", "Show stats."],
265
295
  ["telemetry", "Manage telemetry."],
296
+ ["templates", "Manage work templates."],
266
297
  ["test", "Run linked tests."],
298
+ ["test-all", "Run all linked tests."],
299
+ ["test-runs", "Inspect background test runs."],
300
+ ["todos", "Manage source-code todos."],
301
+ ["twin", "Manage repository twins."],
267
302
  ["update", "Update work."],
303
+ ["update-many", "Update matching work."],
268
304
  ["upgrade", "Upgrade packages."],
269
305
  ["validate", "Validate data."],
306
+ ["vcs", "Inspect version-control context."],
270
307
  ["workspace", "Manage portable workspace primitives."],
308
+ ["history-author-acknowledge", "Acknowledge reviewed history authors."],
309
+ ["history-compact", "Compact history."],
310
+ ["history-redact", "Redact sensitive history values."],
311
+ ["history-repair", "Repair history integrity."],
271
312
  ]);
272
313
  // Lifecycle subcommand flag contracts for `pm extension`. Only `init` differs
273
314
  // between extension and package: `pm package init` / `pm packages init`
@@ -701,29 +742,29 @@ function collectExtensionCommandContracts(runtimeProbe) {
701
742
  const contracts = [];
702
743
  for (const command of [...extensionCommands].sort((left, right) => left.localeCompare(right))) {
703
744
  const definition = definitionsByCommand.get(command);
704
- if (definition) {
705
- contracts.push({
706
- ...definition,
707
- flags: definition.flags.length > 0
708
- ? definition.flags
709
- : (flagsByCommand.get(command)?.flags ?? []),
710
- });
711
- continue;
712
- }
713
- contracts.push({
714
- command,
715
- action: normalizeActionNameFromCommand(command),
716
- source: null,
717
- description: null,
718
- intent: null,
719
- arguments: [],
720
- flags: flagsByCommand.get(command)?.flags ?? [],
721
- examples: [],
722
- failure_hints: [],
723
- });
745
+ contracts.push(buildCollectedExtensionCommandContract(command, definition, flagsByCommand.get(command)?.flags ?? []));
724
746
  }
725
747
  return contracts;
726
748
  }
749
+ function buildCollectedExtensionCommandContract(command, definition, registeredFlags) {
750
+ if (definition) {
751
+ return {
752
+ ...definition,
753
+ flags: definition.flags.length > 0 ? definition.flags : registeredFlags,
754
+ };
755
+ }
756
+ return {
757
+ command,
758
+ action: normalizeActionNameFromCommand(command),
759
+ source: null,
760
+ description: null,
761
+ intent: null,
762
+ arguments: [],
763
+ flags: registeredFlags,
764
+ examples: [],
765
+ failure_hints: [],
766
+ };
767
+ }
727
768
  function extensionSchemaPropertyNameFromFlag(flag) {
728
769
  const normalized = flag.flag.replace(/^-+/, "").trim();
729
770
  if (normalized.length === 0) {
@@ -1564,55 +1605,109 @@ function resolveContractsCommands(selection, actionContext) {
1564
1605
  function resolveOutputCommands(_selection, commands) {
1565
1606
  return commands;
1566
1607
  }
1567
- function summarizeCommandIntent(command) {
1568
- const rootCommand = command.split(" ")[0];
1569
- return (COMMAND_INTENTS.get(command) ??
1570
- COMMAND_INTENTS.get(rootCommand) ??
1571
- "Inspect flags.");
1572
- }
1573
1608
  function canonicalSummaryCommand(command) {
1574
1609
  const rootCommand = command.split(" ")[0];
1575
- if (rootCommand.startsWith("list-")) {
1610
+ if (rootCommand.startsWith("list-"))
1576
1611
  return "list";
1577
- }
1578
- if (rootCommand.startsWith("history-")) {
1612
+ if (rootCommand.startsWith("history-"))
1579
1613
  return "history";
1580
- }
1581
- if (rootCommand === "ctx") {
1582
- return "context";
1583
- }
1584
- if (rootCommand === "packages") {
1585
- return "package";
1586
- }
1587
1614
  return COMMAND_ALIAS_TO_CANONICAL.get(rootCommand) ?? rootCommand;
1588
1615
  }
1589
- function buildCommandSummarySurface(commands) {
1590
- const rootsByCanonical = new Map();
1591
- for (const command of commands) {
1592
- const root = command.split(" ")[0];
1593
- const canonical = canonicalSummaryCommand(root);
1594
- const roots = rootsByCanonical.get(canonical) ?? new Set();
1595
- roots.add(root);
1596
- rootsByCanonical.set(canonical, roots);
1616
+ const COMMAND_OPERATION_INTENTS = new Map([
1617
+ ["activate", "Activate"],
1618
+ ["adopt", "Adopt"],
1619
+ ["adopt-all", "Adopt all"],
1620
+ ["catalog", "Catalog"],
1621
+ ["complete", "Complete"],
1622
+ ["create", "Create"],
1623
+ ["deactivate", "Deactivate"],
1624
+ ["delete", "Delete"],
1625
+ ["describe", "Describe"],
1626
+ ["doctor", "Diagnose"],
1627
+ ["explore", "Explore"],
1628
+ ["init", "Initialize"],
1629
+ ["inspect", "Inspect"],
1630
+ ["install", "Install"],
1631
+ ["list", "List"],
1632
+ ["manage", "Manage"],
1633
+ ["migrate", "Migrate"],
1634
+ ["mutate", "Mutate"],
1635
+ ["reload", "Reload"],
1636
+ ["restore", "Restore"],
1637
+ ["run", "Run"],
1638
+ ["snapshot", "Manage snapshots for"],
1639
+ ["uninstall", "Uninstall"],
1640
+ ]);
1641
+ const COMMAND_INTENT_SUBJECT_OVERRIDES = new Map([
1642
+ ["extension adopt-all", "extensions"],
1643
+ ["package adopt-all", "packages"],
1644
+ ["workspace snapshot list", "workspace snapshots"],
1645
+ ]);
1646
+ function summarizeCommandIntent(command, extensionContracts) {
1647
+ const declared = COMMAND_INTENTS.get(command) ??
1648
+ (command.includes(" ")
1649
+ ? undefined
1650
+ : COMMAND_INTENTS.get(canonicalSummaryCommand(command)));
1651
+ if (declared !== undefined) {
1652
+ return { intent: declared, intent_source: "command" };
1653
+ }
1654
+ const extensionContract = extensionContracts.find((contract) => splitCommandPathAliases(contract.command).includes(command));
1655
+ if (extensionContract?.intent !== null &&
1656
+ extensionContract?.intent !== undefined) {
1657
+ return { intent: extensionContract.intent, intent_source: "command" };
1658
+ }
1659
+ if (extensionContract?.description !== null &&
1660
+ extensionContract?.description !== undefined) {
1661
+ return {
1662
+ intent: extensionContract.description,
1663
+ intent_source: "description",
1664
+ };
1597
1665
  }
1598
- const rootCommands = [...rootsByCanonical.keys()]
1666
+ const tokens = command.split(" ");
1667
+ const operation = tokens.at(-1);
1668
+ const subject = tokens.slice(0, -1).join(" ");
1669
+ const verb = COMMAND_OPERATION_INTENTS.get(operation);
1670
+ const intentSubject = COMMAND_INTENT_SUBJECT_OVERRIDES.get(command) ?? subject;
1671
+ return {
1672
+ intent: verb === undefined || subject.length === 0
1673
+ ? `Run ${command}.`
1674
+ : `${verb} ${intentSubject}.`,
1675
+ intent_source: "generated",
1676
+ };
1677
+ }
1678
+ function buildCommandSummarySurface(commands, extensionContracts = []) {
1679
+ return [...new Set(commands.map(normalizeCommandPath))]
1599
1680
  .filter((command) => command.length > 0)
1600
- .sort((left, right) => left.localeCompare(right));
1601
- return rootCommands.map((command) => {
1681
+ .sort((left, right) => left.localeCompare(right))
1682
+ .map((command) => {
1602
1683
  const budget = resolvePmCommandOutputBudget(command, {
1603
1684
  generateFallback: true,
1604
1685
  });
1605
- const availableFlags = new Set(resolveCoreCommandFlags(command).map((contract) => contract.flag));
1606
- const flags = (AGENT_BOOTSTRAP_FLAGS.get(command) ?? AGENT_BOUNDED_FLAG_PRIORITY).filter((flag) => availableFlags.has(flag));
1607
- const aliases = [...rootsByCanonical.get(command)]
1608
- .filter((root) => root !== command)
1609
- .sort((left, right) => left.localeCompare(right));
1686
+ const rootCommand = command.split(" ")[0];
1687
+ const canonicalRoot = COMMAND_ALIAS_TO_CANONICAL.get(rootCommand) ??
1688
+ (rootCommand.startsWith("list-")
1689
+ ? "list"
1690
+ : rootCommand.startsWith("history-")
1691
+ ? "history"
1692
+ : rootCommand);
1693
+ const availableFlags = new Set([
1694
+ ...resolveCoreCommandFlags(command).map((contract) => contract.flag),
1695
+ ...extensionContracts
1696
+ .filter((contract) => splitCommandPathAliases(contract.command).includes(command))
1697
+ .flatMap((contract) => contract.flags.map((flag) => flag.flag)),
1698
+ ]);
1699
+ const flags = (AGENT_BOOTSTRAP_FLAGS.get(command) ??
1700
+ AGENT_BOOTSTRAP_FLAGS.get(canonicalRoot) ??
1701
+ AGENT_BOUNDED_FLAG_PRIORITY).filter((flag) => availableFlags.has(flag));
1702
+ const intent = summarizeCommandIntent(command, extensionContracts);
1610
1703
  return {
1611
1704
  command,
1612
- ...(aliases.length > 0 ? { aliases } : {}),
1613
- intent: summarizeCommandIntent(command),
1705
+ ...intent,
1614
1706
  ...(flags.length > 0 ? { flags } : {}),
1615
1707
  default_max_estimated_tokens: budget.default_max_estimated_tokens,
1708
+ default_max_estimated_tokens_by_format: {
1709
+ ...budget.default_max_estimated_tokens_by_format,
1710
+ },
1616
1711
  };
1617
1712
  });
1618
1713
  }
@@ -1785,8 +1880,8 @@ function attachCommanderAliasContractsResult(result, selection) {
1785
1880
  result.commander_aliases_omitted_reason = "unfiltered_default_brief";
1786
1881
  }
1787
1882
  /** Attach the compact agent-facing command semantics shared by summary and full projections. */
1788
- function attachAgentCommandContractsResult(result, outputCommands) {
1789
- result.command_summaries = buildCommandSummarySurface(outputCommands);
1883
+ function attachAgentCommandContractsResult(result, outputCommands, extensionCommandContracts) {
1884
+ result.command_summaries = buildCommandSummarySurface(outputCommands, extensionCommandContracts);
1790
1885
  result.output_policy = {
1791
1886
  token_estimate: "ceil(utf8_bytes / 4)",
1792
1887
  degradation_ladder: [...PM_OUTPUT_DEGRADATION_STEPS],
@@ -1804,14 +1899,14 @@ export async function runContracts(options, global) {
1804
1899
  const commands = resolveContractsCommands(selection, actionContext);
1805
1900
  const outputCommands = resolveOutputCommands(selection, commands);
1806
1901
  const result = createContractsResult(selection, schemaContext, actionContext, outputCommands);
1902
+ const extensionCommandContracts = resolveExtensionCommandContracts(selection, runtime, outputCommands);
1807
1903
  if (selection.summary || selection.fullOutput) {
1808
- attachAgentCommandContractsResult(result, outputCommands);
1904
+ attachAgentCommandContractsResult(result, outputCommands, extensionCommandContracts);
1809
1905
  }
1810
1906
  if (selection.summary) {
1811
1907
  return result;
1812
1908
  }
1813
1909
  const commandAliases = buildCommandAliasSurface(commands);
1814
- const extensionCommandContracts = resolveExtensionCommandContracts(selection, runtime, outputCommands);
1815
1910
  if (!(selection.flagsOnly && !selection.fullOutput)) {
1816
1911
  attachRuntimeContractsResult(result, runtime);
1817
1912
  }
@@ -1872,4 +1967,4 @@ export const _testOnlyContractsCommand = {
1872
1967
  toRuntimeShortFlagToken,
1873
1968
  };
1874
1969
  //# sourceMappingURL=runtime-contracts.js.map
1875
- //# debugId=651d4904-cae5-503b-8418-93bc44a413ad
1970
+ //# debugId=c0995490-5838-5c91-af77-9ce387e41a1f
@@ -303,6 +303,7 @@ export declare const ASSURANCE_DEFINITION_SCHEMA: {
303
303
  negative_control?: undefined;
304
304
  assertion_ids?: undefined;
305
305
  triggers?: undefined;
306
+ provider_policy?: undefined;
306
307
  };
307
308
  oneOf?: undefined;
308
309
  allOf?: undefined;
@@ -463,6 +464,7 @@ export declare const ASSURANCE_DEFINITION_SCHEMA: {
463
464
  source?: undefined;
464
465
  assertion_ids?: undefined;
465
466
  triggers?: undefined;
467
+ provider_policy?: undefined;
466
468
  };
467
469
  } | {
468
470
  type: string;
@@ -491,6 +493,36 @@ export declare const ASSURANCE_DEFINITION_SCHEMA: {
491
493
  enum: string[];
492
494
  };
493
495
  };
496
+ provider_policy: {
497
+ type: string;
498
+ additionalProperties: boolean;
499
+ required: string[];
500
+ properties: {
501
+ allowed_providers: {
502
+ type: string;
503
+ items: {
504
+ type: string;
505
+ minLength: number;
506
+ };
507
+ };
508
+ triggers: {
509
+ type: string;
510
+ additionalProperties: {
511
+ type: string;
512
+ additionalProperties: boolean;
513
+ required: string[];
514
+ properties: {
515
+ max_cost_class: {
516
+ enum: string[];
517
+ };
518
+ allow_network: {
519
+ type: string;
520
+ };
521
+ };
522
+ };
523
+ };
524
+ };
525
+ };
494
526
  max_cost?: undefined;
495
527
  source?: undefined;
496
528
  measurement_id?: undefined;
@@ -4,7 +4,7 @@
4
4
  * Defines the strict JSON Schema accepted by assurance definition mutations.
5
5
  */
6
6
 
7
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="2d81fb20-890a-553b-b761-d60caf56b502")}catch(e){}}();
7
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="19a97f60-3b6e-5653-a652-02aebaf5afdd")}catch(e){}}();
8
8
  const ASSURANCE_VALUE_SCHEMA = {
9
9
  oneOf: [{ type: "number" }, { type: "array", items: { type: "string" } }],
10
10
  };
@@ -244,9 +244,32 @@ export const ASSURANCE_DEFINITION_SCHEMA = {
244
244
  ],
245
245
  },
246
246
  },
247
+ provider_policy: {
248
+ type: "object",
249
+ additionalProperties: false,
250
+ required: ["allowed_providers", "triggers"],
251
+ properties: {
252
+ allowed_providers: {
253
+ type: "array",
254
+ items: { type: "string", minLength: 1 },
255
+ },
256
+ triggers: {
257
+ type: "object",
258
+ additionalProperties: {
259
+ type: "object",
260
+ additionalProperties: false,
261
+ required: ["max_cost_class", "allow_network"],
262
+ properties: {
263
+ max_cost_class: { enum: ["low", "medium", "high"] },
264
+ allow_network: { type: "boolean" },
265
+ },
266
+ },
267
+ },
268
+ },
269
+ },
247
270
  },
248
271
  },
249
272
  ],
250
273
  };
251
274
  //# sourceMappingURL=assurance-definition.js.map
252
- //# debugId=2d81fb20-890a-553b-b761-d60caf56b502
275
+ //# debugId=19a97f60-3b6e-5653-a652-02aebaf5afdd
@@ -4,7 +4,7 @@
4
4
  * Defines SDK command-contract metadata for Tool Parameter Tables.
5
5
  */
6
6
 
7
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="6cdf1fd1-7328-5bae-9238-d317f6efba8a")}catch(e){}}();
7
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="9a679120-6f16-5588-b4d4-91c90a2fe385")}catch(e){}}();
8
8
  import { PLAN_HARNESS_VALUES, PLAN_MODE_VALUES, PLAN_STEP_LINK_KIND_VALUES, PLAN_STEP_STATUS_VALUES, } from "../../types/index.js";
9
9
  import { PM_READ_OUTPUT_SESSION_MAX_SEEN_ITEM_IDS } from "../read-output-session.js";
10
10
  import { ASSURANCE_DEFINITION_SCHEMA } from "./schemas/assurance-definition.js";
@@ -219,6 +219,8 @@ export const PM_TOOL_PARAMETER_PROPERTIES = {
219
219
  acceptanceCriteria: { type: "string" },
220
220
  author: { type: "string" },
221
221
  message: { type: "string" },
222
+ owner: { type: "string" },
223
+ enforcement: { type: "string" },
222
224
  assignee: { type: "string" },
223
225
  assigneeFilter: { type: "string", enum: ["assigned", "unassigned"] },
224
226
  parent: { type: "string" },
@@ -646,8 +648,24 @@ export const PM_TOOL_ACTION_SCOPED_PARAMETER_PROPERTIES = {
646
648
  },
647
649
  subcommand: {
648
650
  type: "string",
649
- enum: ["list", "show", "put", "remove", "run", "verdicts"],
651
+ enum: [
652
+ "list",
653
+ "show",
654
+ "put",
655
+ "remove",
656
+ "run",
657
+ "verdicts",
658
+ "presets",
659
+ "apply",
660
+ "derive",
661
+ "promote",
662
+ ],
663
+ },
664
+ preset: {
665
+ type: "string",
666
+ enum: ["software-delivery", "research", "agent-evaluation", "operations"],
650
667
  },
668
+ enforcement: { type: "string", enum: ["warn", "block"] },
651
669
  limit: { type: "integer", minimum: 1, maximum: 1000 },
652
670
  },
653
671
  activity: {
@@ -970,6 +988,14 @@ export const PM_TOOL_PARAMETER_METADATA = {
970
988
  description: "Stable assurance gate id used to filter durable verdict history.",
971
989
  examples: ["release-readiness"],
972
990
  },
991
+ owner: {
992
+ description: "pm item that owns preset or observation-derived assurance assertions.",
993
+ examples: ["pm-a1b2"],
994
+ },
995
+ enforcement: {
996
+ description: "Explicit next assurance enforcement level.",
997
+ examples: ["warn", "block"],
998
+ },
973
999
  runId: {
974
1000
  description: "Background test run identifier.",
975
1001
  examples: ["tr-kq9x3f-93acde"],
@@ -1850,8 +1876,8 @@ export const PM_TOOL_PARAMETER_METADATA = {
1850
1876
  export const PM_TOOL_ACTION_SCOPED_PARAMETER_METADATA = {
1851
1877
  assurance: {
1852
1878
  subcommand: {
1853
- description: "Assurance operation: list, show, put, remove, run, or verdicts.",
1854
- examples: ["list", "run", "verdicts"],
1879
+ description: "Assurance operation: list, show, put, remove, run, verdicts, presets, apply, derive, or promote.",
1880
+ examples: ["list", "run", "derive", "promote"],
1855
1881
  },
1856
1882
  kind: {
1857
1883
  description: "Assurance declaration kind for registry operations: measurement, assertion, or gate.",
@@ -1865,6 +1891,10 @@ export const PM_TOOL_ACTION_SCOPED_PARAMETER_METADATA = {
1865
1891
  description: "Maximum number of newest assurance verdicts returned.",
1866
1892
  examples: [10, 25],
1867
1893
  },
1894
+ preset: {
1895
+ description: "Built-in assurance project shape to preview or apply.",
1896
+ examples: ["software-delivery", "agent-evaluation"],
1897
+ },
1868
1898
  },
1869
1899
  update: {
1870
1900
  acceptanceCriteria: {
@@ -2019,4 +2049,4 @@ export const PM_TOOL_ACTION_SCOPED_PARAMETER_METADATA = {
2019
2049
  },
2020
2050
  };
2021
2051
  //# sourceMappingURL=tool-parameter-tables.js.map
2022
- //# debugId=6cdf1fd1-7328-5bae-9238-d317f6efba8a
2052
+ //# debugId=9a679120-6f16-5588-b4d4-91c90a2fe385
@@ -7,7 +7,7 @@
7
7
  * consumers from a single source of truth.
8
8
  */
9
9
 
10
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="5a184f36-a305-59f1-8c68-ef53cea1df1e")}catch(e){}}();
10
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="d4550d60-3907-528e-b984-c8ca90b7a4e8")}catch(e){}}();
11
11
  import { normalizeUniqueStringList } from "./string-lists.js";
12
12
  import { PM_TOOL_ACTIONS } from "./enum-contracts.js";
13
13
  import { TOOL_CREATE_OPTION_CONTRACTS, TOOL_SHARED_CREATE_UPDATE_OPTION_CONTRACTS, TOOL_UPDATE_OPTION_CONTRACTS, TOOL_UPDATE_MANY_FILTER_OPTION_CONTRACTS, TOOL_CONTEXT_OPTION_CONTRACTS, TOOL_ACTIVITY_OPTION_CONTRACTS, TOOL_LIST_FILTER_OPTION_CONTRACTS, TOOL_AGGREGATE_OPTION_CONTRACTS, TOOL_SEARCH_FILTER_OPTION_CONTRACTS, TOOL_CLOSE_MANY_FILTER_OPTION_CONTRACTS, } from "./tool-option-contracts.js";
@@ -1119,6 +1119,10 @@ const PM_TOOL_ACTION_SCHEMA_CONTRACTS = {
1119
1119
  "dryRun",
1120
1120
  "author",
1121
1121
  "message",
1122
+ "preset",
1123
+ "owner",
1124
+ "apply",
1125
+ "enforcement",
1122
1126
  ],
1123
1127
  conditionalRequired: [
1124
1128
  { property: "subcommand", value: "list", required: ["kind"] },
@@ -1130,6 +1134,17 @@ const PM_TOOL_ACTION_SCHEMA_CONTRACTS = {
1130
1134
  },
1131
1135
  { property: "subcommand", value: "remove", required: ["kind", "id"] },
1132
1136
  { property: "subcommand", value: "run", required: ["id", "trigger"] },
1137
+ {
1138
+ property: "subcommand",
1139
+ value: "apply",
1140
+ required: ["preset", "owner"],
1141
+ },
1142
+ { property: "subcommand", value: "derive", required: ["owner"] },
1143
+ {
1144
+ property: "subcommand",
1145
+ value: "promote",
1146
+ required: ["id", "enforcement"],
1147
+ },
1133
1148
  ],
1134
1149
  },
1135
1150
  gc: { optional: ["dryRun", "gcScope"] },
@@ -1558,4 +1573,4 @@ export const _testOnlyCliContracts = {
1558
1573
  withFlagAliasMetadata,
1559
1574
  };
1560
1575
  //# sourceMappingURL=tool-schema.js.map
1561
- //# debugId=5a184f36-a305-59f1-8c68-ef53cea1df1e
1576
+ //# debugId=d4550d60-3907-528e-b984-c8ca90b7a4e8
@@ -4,7 +4,7 @@
4
4
  * Builds the reusable Commander root that embeds pm's universal global contracts.
5
5
  */
6
6
 
7
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="b799c7c2-21b8-5c19-8565-7166e6f06a90")}catch(e){}}();
7
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="304d0901-79d3-593d-a789-410e28d59948")}catch(e){}}();
8
8
  import { Command } from "commander";
9
9
  import { writeStdout } from "../core/output/output.js";
10
10
  /** Create a fresh pm root program suitable for one-shot CLI or embedded hosts. */
@@ -27,7 +27,7 @@ export function createPmCliProgram(version) {
27
27
  .option("--token-accounting", "Attach a bounded per-section token-cost receipt to command output")
28
28
  .option("--output-include <fields>", "Retain comma-separated fields or sections in read output")
29
29
  .option("--output-limit <count>", "Bound rows in read output")
30
- .option("--output-budget <tokens>", "Bound estimated tokens in read output")
30
+ .option("--output-budget <tokens|unbounded>", "Bound estimated tokens in read output or explicitly disable the default ceiling")
31
31
  .option("--output-format <toon|json>", "Select the read-output encoding")
32
32
  .option("--output-session <state>", "Carry a JSON session budget and served-item ledger across read calls")
33
33
  .option("--output-row-contract", "Include the machine-readable row selector and TOON encoding contract")
@@ -45,4 +45,4 @@ export function createPmCliProgram(version) {
45
45
  .exitOverride();
46
46
  }
47
47
  //# sourceMappingURL=cli-program.js.map
48
- //# debugId=b799c7c2-21b8-5c19-8565-7166e6f06a90
48
+ //# debugId=304d0901-79d3-593d-a789-410e28d59948
@@ -4,7 +4,8 @@
4
4
  * Implements the pm comments command surface and its agent-facing runtime behavior.
5
5
  */
6
6
 
7
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="667218ac-866c-59b1-8309-18ad92434fca")}catch(e){}}();
7
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="a7687052-a04e-536e-ace5-a665ebd477e3")}catch(e){}}();
8
+ import { isFileAbsentError } from "../core/fs/fs-utils.js";
8
9
  import { readFile } from "node:fs/promises";
9
10
  import { EXIT_CODE, PmCliError, createStdinTokenResolver, } from "./runtime-primitives.js";
10
11
  import { isErrnoError, parseAnnotationTextInput, runAnnotationCommand, } from "./annotations.js";
@@ -36,7 +37,7 @@ async function resolveCommentTextSource(options, stdinResolver) {
36
37
  return { value: fileInput, emptyFlag: "--file" };
37
38
  }
38
39
  catch (error) {
39
- if (isErrnoError(error) && error.code === "ENOENT") {
40
+ if (isErrnoError(error) && isFileAbsentError(error)) {
40
41
  throw new PmCliError(`--file path not found: ${filePath}`, EXIT_CODE.USAGE);
41
42
  }
42
43
  const detail = error instanceof Error ? error.message : String(error);
@@ -122,4 +123,4 @@ export async function runComments(id, options, global) {
122
123
  });
123
124
  }
124
125
  //# sourceMappingURL=comments.js.map
125
- //# debugId=667218ac-866c-59b1-8309-18ad92434fca
126
+ //# debugId=a7687052-a04e-536e-ace5-a665ebd477e3
@@ -5,7 +5,8 @@
5
5
  * compile-cache generations.
6
6
  */
7
7
 
8
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="6748a283-bc93-5783-98c1-d1a7f2fdce4e")}catch(e){}}();
8
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="611e9aba-d08e-5c1a-89c9-c7fda0cc9bc9")}catch(e){}}();
9
+ import { isFileMissingError } from "../core/fs/fs-utils.js";
9
10
  import fs from "node:fs";
10
11
  import path from "node:path";
11
12
  const COMPILE_CACHE_CONCURRENT_GRACE_MS = 5 * 60 * 1000;
@@ -44,7 +45,7 @@ export function pruneCompileCacheGenerations(cacheRoot, currentGeneration) {
44
45
  catch (error) {
45
46
  if (error instanceof Error &&
46
47
  "code" in error &&
47
- error.code === "ENOENT") {
48
+ isFileMissingError(error)) {
48
49
  return [];
49
50
  }
50
51
  throw error;
@@ -70,4 +71,4 @@ export function pruneCompileCacheGenerations(cacheRoot, currentGeneration) {
70
71
  return { retained: normalizedGeneration, removed };
71
72
  }
72
73
  //# sourceMappingURL=compile-cache.js.map
73
- //# debugId=6748a283-bc93-5783-98c1-d1a7f2fdce4e
74
+ //# debugId=611e9aba-d08e-5c1a-89c9-c7fda0cc9bc9
@@ -25,7 +25,7 @@
25
25
  * declarative (`composeExtension`) authoring styles live together. Both are
26
26
  * re-exported from the SDK barrel, so the public API is unchanged.
27
27
  */
28
- import type { AfterCommandHook, BeforeCommandHook, BeforeMutationHook, CommandDefinition, CommandOverride, ExtensionApi, ExtensionCapability, ExtensionManifest, ExtensionServiceName, Exporter, FlagDefinition, ImportExportRegistrationOptions, Importer, OnIndexHook, OnReadHook, OnWriteHook, OutputRendererFormat, ParserOverride, PreflightOverride, ScopedPreflightOverrideDefinition, RendererOverride, ScopedRendererOverrideDefinition, SchemaFieldDefinition, SchemaItemTypeDefinition, SchemaMigrationDefinition, SearchProviderDefinition, ServiceOverride, VectorStoreAdapterDefinition } from "../core/extensions/loader.js";
28
+ import type { AfterCommandHook, BeforeCommandHook, BeforeMutationHook, CommandDefinition, CommandOverride, ExtensionApi, ExtensionCapability, ExtensionManifest, ExtensionServiceName, Exporter, FlagDefinition, ImportExportRegistrationOptions, Importer, OnIndexHook, OnReadHook, OnWriteHook, OutputRendererFormat, ParserOverride, PreflightOverride, ScopedPreflightOverrideDefinition, RendererOverride, ScopedRendererOverrideDefinition, SchemaFieldDefinition, SchemaItemTypeDefinition, SchemaMigrationDefinition, SearchProviderDefinition, ServiceOverride, VectorStoreAdapterDefinition, AssuranceMeasurementProviderDefinition } from "../core/extensions/loader.js";
29
29
  import type { ExtensionActivationSummary } from "../core/extensions/activation-summary.js";
30
30
  import type { ProjectProfileRegistrationInput } from "../core/profile/profile-presets.js";
31
31
  import type { PmMaxVersionExceededMode } from "../core/extensions/extension-types.js";
@@ -152,6 +152,8 @@ export interface ExtensionBlueprint {
152
152
  searchProviders?: SearchProviderDefinition[];
153
153
  /** Vector store adapters registered via `api.registerVectorStoreAdapter(adapter)`. */
154
154
  vectorStoreAdapters?: VectorStoreAdapterDefinition[];
155
+ /** Assurance measurement providers registered via `api.registerAssuranceMeasurementProvider(provider)`. */
156
+ assuranceProviders?: AssuranceMeasurementProviderDefinition[];
155
157
  /** Importers registered via `api.registerImporter(name, importer, options?)`. */
156
158
  importers?: ExtensionBlueprintImporter[];
157
159
  /** Exporters registered via `api.registerExporter(name, exporter, options?)`. */