@unbrained/pm-cli 2026.5.12 → 2026.5.18
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 +4 -4
- package/AGENTS.md +78 -457
- package/CHANGELOG.md +22 -0
- package/CONTRIBUTING.md +1 -0
- package/PRD.md +7 -28
- package/README.md +8 -14
- package/dist/cli/argv-utils.js +4 -1
- package/dist/cli/argv-utils.js.map +1 -1
- package/dist/cli/bootstrap-args.js +4 -1
- package/dist/cli/bootstrap-args.js.map +1 -1
- package/dist/cli/commander-usage.js +32 -1
- package/dist/cli/commander-usage.js.map +1 -1
- package/dist/cli/commands/activity.js +23 -5
- package/dist/cli/commands/activity.js.map +1 -1
- package/dist/cli/commands/aggregate.js +5 -2
- package/dist/cli/commands/aggregate.js.map +1 -1
- package/dist/cli/commands/append.js +4 -1
- package/dist/cli/commands/append.js.map +1 -1
- package/dist/cli/commands/calendar.js +9 -3
- package/dist/cli/commands/calendar.js.map +1 -1
- package/dist/cli/commands/claim.d.ts +3 -0
- package/dist/cli/commands/claim.js +19 -3
- package/dist/cli/commands/claim.js.map +1 -1
- package/dist/cli/commands/close.js +4 -1
- package/dist/cli/commands/close.js.map +1 -1
- package/dist/cli/commands/comments-audit.js +4 -1
- package/dist/cli/commands/comments-audit.js.map +1 -1
- package/dist/cli/commands/comments.js +4 -1
- package/dist/cli/commands/comments.js.map +1 -1
- package/dist/cli/commands/completion.js +98 -2
- package/dist/cli/commands/completion.js.map +1 -1
- package/dist/cli/commands/config.js +4 -1
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/cli/commands/context.js +19 -5
- package/dist/cli/commands/context.js.map +1 -1
- package/dist/cli/commands/contracts.d.ts +9 -0
- package/dist/cli/commands/contracts.js +205 -49
- package/dist/cli/commands/contracts.js.map +1 -1
- package/dist/cli/commands/create.js +88 -9
- package/dist/cli/commands/create.js.map +1 -1
- package/dist/cli/commands/dedupe-audit.js +4 -1
- package/dist/cli/commands/dedupe-audit.js.map +1 -1
- package/dist/cli/commands/delete.js +4 -1
- package/dist/cli/commands/delete.js.map +1 -1
- package/dist/cli/commands/deps.js +4 -1
- package/dist/cli/commands/deps.js.map +1 -1
- package/dist/cli/commands/docs.js +4 -1
- package/dist/cli/commands/docs.js.map +1 -1
- package/dist/cli/commands/extension.d.ts +7 -2
- package/dist/cli/commands/extension.js +360 -64
- package/dist/cli/commands/extension.js.map +1 -1
- package/dist/cli/commands/files.js +4 -1
- package/dist/cli/commands/files.js.map +1 -1
- package/dist/cli/commands/gc.js +4 -1
- package/dist/cli/commands/gc.js.map +1 -1
- package/dist/cli/commands/get.d.ts +7 -3
- package/dist/cli/commands/get.js +91 -18
- package/dist/cli/commands/get.js.map +1 -1
- package/dist/cli/commands/guide.js +6 -8
- package/dist/cli/commands/guide.js.map +1 -1
- package/dist/cli/commands/health.d.ts +4 -0
- package/dist/cli/commands/health.js +31 -8
- package/dist/cli/commands/health.js.map +1 -1
- package/dist/cli/commands/history-redact.d.ts +42 -0
- package/dist/cli/commands/history-redact.js +559 -0
- package/dist/cli/commands/history-redact.js.map +1 -0
- package/dist/cli/commands/history.d.ts +4 -0
- package/dist/cli/commands/history.js +14 -3
- package/dist/cli/commands/history.js.map +1 -1
- package/dist/cli/commands/index.d.ts +2 -8
- package/dist/cli/commands/index.js +6 -9
- package/dist/cli/commands/index.js.map +1 -1
- package/dist/cli/commands/init-agent-guidance.d.ts +31 -0
- package/dist/cli/commands/init-agent-guidance.js +336 -0
- package/dist/cli/commands/init-agent-guidance.js.map +1 -0
- package/dist/cli/commands/init.d.ts +14 -0
- package/dist/cli/commands/init.js +75 -1
- package/dist/cli/commands/init.js.map +1 -1
- package/dist/cli/commands/learnings.js +4 -1
- package/dist/cli/commands/learnings.js.map +1 -1
- package/dist/cli/commands/list.d.ts +1 -0
- package/dist/cli/commands/list.js +42 -18
- package/dist/cli/commands/list.js.map +1 -1
- package/dist/cli/commands/metadata-normalizers.js +4 -1
- package/dist/cli/commands/metadata-normalizers.js.map +1 -1
- package/dist/cli/commands/normalize.js +4 -1
- package/dist/cli/commands/normalize.js.map +1 -1
- package/dist/cli/commands/notes.js +4 -1
- package/dist/cli/commands/notes.js.map +1 -1
- package/dist/cli/commands/plan.d.ts +118 -0
- package/dist/cli/commands/plan.js +975 -0
- package/dist/cli/commands/plan.js.map +1 -0
- package/dist/cli/commands/reindex.d.ts +8 -0
- package/dist/cli/commands/reindex.js +100 -24
- package/dist/cli/commands/reindex.js.map +1 -1
- package/dist/cli/commands/restore.js +4 -1
- package/dist/cli/commands/restore.js.map +1 -1
- package/dist/cli/commands/search.js +58 -27
- package/dist/cli/commands/search.js.map +1 -1
- package/dist/cli/commands/stats.js +4 -1
- package/dist/cli/commands/stats.js.map +1 -1
- package/dist/cli/commands/templates.js +4 -1
- package/dist/cli/commands/templates.js.map +1 -1
- package/dist/cli/commands/test-all.js +4 -1
- package/dist/cli/commands/test-all.js.map +1 -1
- package/dist/cli/commands/test-runs.js +4 -1
- package/dist/cli/commands/test-runs.js.map +1 -1
- package/dist/cli/commands/test.js +4 -1
- package/dist/cli/commands/test.js.map +1 -1
- package/dist/cli/commands/update-many.js +4 -1
- package/dist/cli/commands/update-many.js.map +1 -1
- package/dist/cli/commands/update.js +114 -71
- package/dist/cli/commands/update.js.map +1 -1
- package/dist/cli/commands/upgrade.js +6 -3
- package/dist/cli/commands/upgrade.js.map +1 -1
- package/dist/cli/commands/validate.js +32 -4
- package/dist/cli/commands/validate.js.map +1 -1
- package/dist/cli/error-guidance.js +5 -2
- package/dist/cli/error-guidance.js.map +1 -1
- package/dist/cli/extension-command-help.js +4 -1
- package/dist/cli/extension-command-help.js.map +1 -1
- package/dist/cli/extension-command-options.js +4 -1
- package/dist/cli/extension-command-options.js.map +1 -1
- package/dist/cli/guide-topics.js +4 -1
- package/dist/cli/guide-topics.js.map +1 -1
- package/dist/cli/help-content.js +52 -33
- package/dist/cli/help-content.js.map +1 -1
- package/dist/cli/help-json-payload.js +4 -1
- package/dist/cli/help-json-payload.js.map +1 -1
- package/dist/cli/main.js +276 -32
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/migration-gates.js +4 -1
- package/dist/cli/migration-gates.js.map +1 -1
- package/dist/cli/register-list-query.js +55 -150
- package/dist/cli/register-list-query.js.map +1 -1
- package/dist/cli/register-mutation.js +277 -261
- package/dist/cli/register-mutation.js.map +1 -1
- package/dist/cli/register-operations.js +62 -199
- package/dist/cli/register-operations.js.map +1 -1
- package/dist/cli/register-setup.js +55 -146
- package/dist/cli/register-setup.js.map +1 -1
- package/dist/cli/registration-helpers.d.ts +2 -2
- package/dist/cli/registration-helpers.js +11 -21
- package/dist/cli/registration-helpers.js.map +1 -1
- package/dist/cli/shared-parsers.js +4 -1
- package/dist/cli/shared-parsers.js.map +1 -1
- package/dist/cli/telemetry-flush.js +4 -1
- package/dist/cli/telemetry-flush.js.map +1 -1
- package/dist/cli.js +45 -3
- package/dist/cli.js.map +1 -1
- package/dist/core/extensions/extension-types.js +4 -1
- package/dist/core/extensions/extension-types.js.map +1 -1
- package/dist/core/extensions/index.js +4 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/item-fields.js +4 -1
- package/dist/core/extensions/item-fields.js.map +1 -1
- package/dist/core/extensions/loader.js +84 -54
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/extensions/runtime-registrations.js +4 -1
- package/dist/core/extensions/runtime-registrations.js.map +1 -1
- package/dist/core/fs/fs-utils.js +4 -1
- package/dist/core/fs/fs-utils.js.map +1 -1
- package/dist/core/fs/index.js +4 -1
- package/dist/core/fs/index.js.map +1 -1
- package/dist/core/history/history-stream-policy.js +4 -1
- package/dist/core/history/history-stream-policy.js.map +1 -1
- package/dist/core/history/history.js +4 -1
- package/dist/core/history/history.js.map +1 -1
- package/dist/core/history/index.js +4 -1
- package/dist/core/history/index.js.map +1 -1
- package/dist/core/item/id.js +4 -1
- package/dist/core/item/id.js.map +1 -1
- package/dist/core/item/index.js +4 -1
- package/dist/core/item/index.js.map +1 -1
- package/dist/core/item/item-format.js +241 -2
- package/dist/core/item/item-format.js.map +1 -1
- package/dist/core/item/parent-reference-policy.js +4 -1
- package/dist/core/item/parent-reference-policy.js.map +1 -1
- package/dist/core/item/parse.js +33 -3
- package/dist/core/item/parse.js.map +1 -1
- package/dist/core/item/sprint-release-format.js +4 -1
- package/dist/core/item/sprint-release-format.js.map +1 -1
- package/dist/core/item/status.js +4 -1
- package/dist/core/item/status.js.map +1 -1
- package/dist/core/item/type-registry.js +4 -1
- package/dist/core/item/type-registry.js.map +1 -1
- package/dist/core/lock/index.js +4 -1
- package/dist/core/lock/index.js.map +1 -1
- package/dist/core/lock/lock.js +4 -1
- package/dist/core/lock/lock.js.map +1 -1
- package/dist/core/output/command-aware.js +4 -1
- package/dist/core/output/command-aware.js.map +1 -1
- package/dist/core/output/output.d.ts +4 -0
- package/dist/core/output/output.js +47 -6
- package/dist/core/output/output.js.map +1 -1
- package/dist/core/packages/manifest.d.ts +27 -1
- package/dist/core/packages/manifest.js +87 -1
- package/dist/core/packages/manifest.js.map +1 -1
- package/dist/core/packages/root.d.ts +3 -0
- package/dist/core/packages/root.js +51 -0
- package/dist/core/packages/root.js.map +1 -0
- package/dist/core/schema/runtime-field-filters.js +4 -1
- package/dist/core/schema/runtime-field-filters.js.map +1 -1
- package/dist/core/schema/runtime-field-values.js +4 -1
- package/dist/core/schema/runtime-field-values.js.map +1 -1
- package/dist/core/schema/runtime-schema.js +4 -1
- package/dist/core/schema/runtime-schema.js.map +1 -1
- package/dist/core/search/cache.js +7 -2
- package/dist/core/search/cache.js.map +1 -1
- package/dist/core/search/corpus.d.ts +2 -0
- package/dist/core/search/corpus.js +77 -2
- package/dist/core/search/corpus.js.map +1 -1
- package/dist/core/search/embedding-batches.d.ts +13 -1
- package/dist/core/search/embedding-batches.js +40 -8
- package/dist/core/search/embedding-batches.js.map +1 -1
- package/dist/core/search/http-client.js +4 -1
- package/dist/core/search/http-client.js.map +1 -1
- package/dist/core/search/providers.js +4 -1
- package/dist/core/search/providers.js.map +1 -1
- package/dist/core/search/semantic-defaults.js +11 -2
- package/dist/core/search/semantic-defaults.js.map +1 -1
- package/dist/core/search/vector-stores.js +4 -1
- package/dist/core/search/vector-stores.js.map +1 -1
- package/dist/core/sentry/helpers.js +4 -1
- package/dist/core/sentry/helpers.js.map +1 -1
- package/dist/core/sentry/instrument.js +10 -13
- package/dist/core/sentry/instrument.js.map +1 -1
- package/dist/core/shared/command-types.js +4 -1
- package/dist/core/shared/command-types.js.map +1 -1
- package/dist/core/shared/conflict-markers.js +4 -1
- package/dist/core/shared/conflict-markers.js.map +1 -1
- package/dist/core/shared/constants.d.ts +2 -2
- package/dist/core/shared/constants.js +24 -1
- package/dist/core/shared/constants.js.map +1 -1
- package/dist/core/shared/errors.js +4 -1
- package/dist/core/shared/errors.js.map +1 -1
- package/dist/core/shared/index.js +4 -1
- package/dist/core/shared/index.js.map +1 -1
- package/dist/core/shared/levenshtein.js +4 -1
- package/dist/core/shared/levenshtein.js.map +1 -1
- package/dist/core/shared/primitives.js +4 -1
- package/dist/core/shared/primitives.js.map +1 -1
- package/dist/core/shared/serialization.js +4 -1
- package/dist/core/shared/serialization.js.map +1 -1
- package/dist/core/shared/text-normalization.js +4 -1
- package/dist/core/shared/text-normalization.js.map +1 -1
- package/dist/core/shared/time.js +4 -1
- package/dist/core/shared/time.js.map +1 -1
- package/dist/core/store/front-matter-cache.d.ts +8 -1
- package/dist/core/store/front-matter-cache.js +28 -14
- package/dist/core/store/front-matter-cache.js.map +1 -1
- package/dist/core/store/index.js +4 -1
- package/dist/core/store/index.js.map +1 -1
- package/dist/core/store/item-format-migration.js +4 -1
- package/dist/core/store/item-format-migration.js.map +1 -1
- package/dist/core/store/item-store.d.ts +2 -0
- package/dist/core/store/item-store.js +66 -3
- package/dist/core/store/item-store.js.map +1 -1
- package/dist/core/store/paths.js +4 -1
- package/dist/core/store/paths.js.map +1 -1
- package/dist/core/store/settings.js +39 -1
- package/dist/core/store/settings.js.map +1 -1
- package/dist/core/telemetry/consent.js +4 -1
- package/dist/core/telemetry/consent.js.map +1 -1
- package/dist/core/telemetry/observability.d.ts +1 -1
- package/dist/core/telemetry/observability.js +11 -2
- package/dist/core/telemetry/observability.js.map +1 -1
- package/dist/core/telemetry/runtime.js +31 -5
- package/dist/core/telemetry/runtime.js.map +1 -1
- package/dist/core/test/background-runs.js +4 -1
- package/dist/core/test/background-runs.js.map +1 -1
- package/dist/core/test/item-test-run-tracking.js +4 -1
- package/dist/core/test/item-test-run-tracking.js.map +1 -1
- package/dist/mcp/server.d.ts +8 -0
- package/dist/mcp/server.js +212 -53
- package/dist/mcp/server.js.map +1 -1
- package/dist/sdk/cli-contracts/commander-mutation-options.d.ts +7 -0
- package/dist/sdk/cli-contracts/commander-mutation-options.js +484 -0
- package/dist/sdk/cli-contracts/commander-mutation-options.js.map +1 -0
- package/dist/sdk/cli-contracts/commander-types.d.ts +21 -0
- package/dist/sdk/cli-contracts/commander-types.js +95 -0
- package/dist/sdk/cli-contracts/commander-types.js.map +1 -0
- package/dist/sdk/cli-contracts.d.ts +10 -17
- package/dist/sdk/cli-contracts.js +232 -282
- package/dist/sdk/cli-contracts.js.map +1 -1
- package/dist/sdk/index.d.ts +2 -1
- package/dist/sdk/index.js +5 -1
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/runtime.d.ts +29 -0
- package/dist/sdk/runtime.js +31 -0
- package/dist/sdk/runtime.js.map +1 -0
- package/dist/types/index.js +4 -1
- package/dist/types/index.js.map +1 -1
- package/dist/types.d.ts +86 -2
- package/dist/types.js +34 -1
- package/dist/types.js.map +1 -1
- package/docs/AGENT_GUIDE.md +16 -6
- package/docs/CLAUDE_CODE_PLUGIN.md +10 -10
- package/docs/CODEX_PLUGIN.md +2 -2
- package/docs/COMMANDS.md +83 -8
- package/docs/CONFIGURATION.md +4 -1
- package/docs/EXTENSIONS.md +176 -807
- package/docs/QUICKSTART.md +12 -5
- package/docs/README.md +7 -6
- package/docs/RELEASING.md +6 -4
- package/docs/SDK.md +78 -441
- package/docs/TESTING.md +2 -2
- package/marketplace.json +3 -3
- package/package.json +7 -4
- package/packages/pm-beads/extensions/beads/index.js +90 -101
- package/packages/pm-beads/extensions/beads/index.ts +2 -2
- package/packages/pm-beads/extensions/beads/runtime.js +2 -17
- package/packages/pm-beads/extensions/beads/runtime.ts +41 -18
- package/packages/pm-beads/package.json +34 -1
- package/packages/pm-calendar/README.md +13 -0
- package/packages/pm-calendar/extensions/calendar/index.js +56 -0
- package/packages/pm-calendar/extensions/calendar/index.ts +62 -0
- package/packages/pm-calendar/extensions/calendar/manifest.json +7 -0
- package/packages/pm-calendar/extensions/calendar/runtime.js +114 -0
- package/packages/pm-calendar/extensions/calendar/runtime.ts +123 -0
- package/packages/pm-calendar/package.json +51 -0
- package/packages/pm-governance-audit/README.md +23 -0
- package/packages/pm-governance-audit/extensions/governance-audit/index.js +117 -0
- package/packages/pm-governance-audit/extensions/governance-audit/index.ts +118 -0
- package/packages/pm-governance-audit/extensions/governance-audit/manifest.json +7 -0
- package/packages/pm-governance-audit/extensions/governance-audit/runtime.js +159 -0
- package/packages/pm-governance-audit/extensions/governance-audit/runtime.ts +176 -0
- package/packages/pm-governance-audit/package.json +52 -0
- package/packages/pm-guide-shell/README.md +23 -0
- package/packages/pm-guide-shell/extensions/guide-shell/index.js +76 -0
- package/packages/pm-guide-shell/extensions/guide-shell/index.ts +81 -0
- package/packages/pm-guide-shell/extensions/guide-shell/manifest.json +7 -0
- package/packages/pm-guide-shell/extensions/guide-shell/runtime.js +263 -0
- package/packages/pm-guide-shell/extensions/guide-shell/runtime.ts +327 -0
- package/packages/pm-guide-shell/package.json +52 -0
- package/packages/pm-linked-test-adapters/README.md +24 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/index.js +101 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/index.ts +102 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/manifest.json +7 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/runtime.js +142 -0
- package/packages/pm-linked-test-adapters/extensions/linked-test-adapters/runtime.ts +173 -0
- package/packages/pm-linked-test-adapters/package.json +53 -0
- package/packages/pm-search-advanced/README.md +27 -0
- package/packages/pm-search-advanced/extensions/search-advanced/index.js +93 -0
- package/packages/pm-search-advanced/extensions/search-advanced/index.ts +94 -0
- package/packages/pm-search-advanced/extensions/search-advanced/manifest.json +7 -0
- package/packages/pm-search-advanced/extensions/search-advanced/runtime.js +120 -0
- package/packages/pm-search-advanced/extensions/search-advanced/runtime.ts +144 -0
- package/packages/pm-search-advanced/package.json +54 -0
- package/packages/pm-templates/README.md +20 -0
- package/packages/pm-templates/extensions/templates/index.js +101 -0
- package/packages/pm-templates/extensions/templates/index.ts +109 -0
- package/packages/pm-templates/extensions/templates/manifest.json +7 -0
- package/packages/pm-templates/extensions/templates/runtime.js +226 -0
- package/packages/pm-templates/extensions/templates/runtime.ts +283 -0
- package/packages/pm-templates/package.json +50 -0
- package/packages/pm-todos/extensions/todos/index.js +105 -116
- package/packages/pm-todos/extensions/todos/index.ts +3 -2
- package/packages/pm-todos/extensions/todos/runtime.js +2 -17
- package/packages/pm-todos/extensions/todos/runtime.ts +40 -18
- package/packages/pm-todos/package.json +35 -1
- package/plugins/{pm-cli-claude → pm-claude}/.claude-plugin/plugin.json +2 -2
- package/plugins/{pm-cli-claude → pm-claude}/.mcp.json +1 -1
- package/plugins/{pm-cli-claude → pm-claude}/README.md +4 -4
- package/plugins/{pm-cli-claude → pm-claude}/agents/pm-coordinator.md +1 -1
- package/plugins/{pm-cli-claude → pm-claude}/commands/pm-init.md +10 -1
- package/plugins/{pm-cli-claude → pm-claude}/commands/pm-planner.md +18 -0
- package/plugins/{pm-cli-claude → pm-claude}/scripts/pm-mcp-server.mjs +4 -2
- package/plugins/{pm-cli-claude → pm-claude}/skills/pm-planner/SKILL.md +46 -1
- package/plugins/{pm-cli-codex → pm-codex}/.codex-plugin/plugin.json +3 -3
- package/plugins/{pm-cli-codex → pm-codex}/.mcp.json +1 -1
- package/plugins/{pm-cli-codex → pm-codex}/README.md +7 -4
- package/plugins/{pm-cli-codex → pm-codex}/scripts/pm-mcp-server.mjs +4 -2
- package/plugins/pm-codex/skills/pm-native/SKILL.md +81 -0
- package/scripts/finalize-build.mjs +28 -0
- package/scripts/prepare-build-cache.mjs +37 -0
- package/plugins/pm-cli-codex/skills/pm-native/SKILL.md +0 -57
- /package/plugins/{pm-cli-claude → pm-claude}/agents/pm-delivery-chain.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/agents/pm-triage-agent.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/agents/pm-verification-agent.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-audit.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-calendar.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-close-task.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-developer.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-list.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-new.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-release.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-search.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-start-task.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-status.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-triage.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/commands/pm-workflow.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/hooks/hooks.json +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/hooks/session-start.mjs +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/skills/pm-audit/SKILL.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/skills/pm-developer/SKILL.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/skills/pm-release/SKILL.md +0 -0
- /package/plugins/{pm-cli-claude → pm-claude}/skills/pm-workflow/SKILL.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/assets/pm-cli-small.svg +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/commands/pm-audit.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/commands/pm-close-task.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/commands/pm-start-task.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/skills/pm-auditor/SKILL.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/skills/pm-auditor/agents/openai.yaml +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/skills/pm-native/agents/openai.yaml +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/skills/pm-release/SKILL.md +0 -0
- /package/plugins/{pm-cli-codex → pm-codex}/skills/pm-release/agents/openai.yaml +0 -0
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { pathToFileURL } from "node:url";
|
|
3
|
+
|
|
4
|
+
const PM_PACKAGE_ROOT_ENV = "PM_CLI_PACKAGE_ROOT";
|
|
5
|
+
let runtimeBundle = null;
|
|
6
|
+
let runtimeBundlePromise = null;
|
|
7
|
+
|
|
8
|
+
async function ensureRuntimeBundle() {
|
|
9
|
+
if (runtimeBundle) {
|
|
10
|
+
return runtimeBundle;
|
|
11
|
+
}
|
|
12
|
+
if (!runtimeBundlePromise) {
|
|
13
|
+
runtimeBundlePromise = loadRuntimeBundle();
|
|
14
|
+
}
|
|
15
|
+
runtimeBundle = await runtimeBundlePromise;
|
|
16
|
+
return runtimeBundle;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
async function loadRuntimeBundle() {
|
|
20
|
+
const envRoot = process.env[PM_PACKAGE_ROOT_ENV];
|
|
21
|
+
if (typeof envRoot !== "string" || envRoot.trim().length === 0) {
|
|
22
|
+
throw new Error(
|
|
23
|
+
`builtin-linked-test-adapters requires ${PM_PACKAGE_ROOT_ENV} to locate core SDK runtime exports.`,
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
const modulePath = path.join(path.resolve(envRoot.trim()), "dist", "sdk", "runtime.js");
|
|
27
|
+
try {
|
|
28
|
+
const sdkLoaded = await import(pathToFileURL(modulePath).href);
|
|
29
|
+
if (
|
|
30
|
+
typeof sdkLoaded.runTestRunsList === "function" &&
|
|
31
|
+
typeof sdkLoaded.runTestRunsStatus === "function" &&
|
|
32
|
+
typeof sdkLoaded.runTestRunsLogs === "function" &&
|
|
33
|
+
typeof sdkLoaded.runTestRunsStop === "function" &&
|
|
34
|
+
typeof sdkLoaded.runTestRunsResume === "function" &&
|
|
35
|
+
typeof sdkLoaded.PmCliError === "function" &&
|
|
36
|
+
typeof sdkLoaded.EXIT_CODE === "object" &&
|
|
37
|
+
sdkLoaded.EXIT_CODE !== null
|
|
38
|
+
) {
|
|
39
|
+
return {
|
|
40
|
+
sdk: sdkLoaded,
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
} catch {
|
|
44
|
+
// Fall through to deterministic failure message below.
|
|
45
|
+
}
|
|
46
|
+
throw new Error(
|
|
47
|
+
`builtin-linked-test-adapters failed to load test-runs SDK runtime exports from ${modulePath}.`,
|
|
48
|
+
);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
function readStringOption(options, key, aliases = []) {
|
|
52
|
+
const keys = [key, ...aliases];
|
|
53
|
+
for (const candidate of keys) {
|
|
54
|
+
const value = options[candidate];
|
|
55
|
+
if (typeof value === "string" && value.trim().length > 0) {
|
|
56
|
+
return value;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
return undefined;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
function readBooleanOption(options, key, aliases = []) {
|
|
63
|
+
const keys = [key, ...aliases];
|
|
64
|
+
for (const candidate of keys) {
|
|
65
|
+
const value = options[candidate];
|
|
66
|
+
if (value === undefined) {
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
if (typeof value === "boolean") {
|
|
70
|
+
return value;
|
|
71
|
+
}
|
|
72
|
+
if (typeof value === "string") {
|
|
73
|
+
const normalized = value.trim().toLowerCase();
|
|
74
|
+
if (normalized === "true" || normalized === "1" || normalized === "yes" || normalized === "on") {
|
|
75
|
+
return true;
|
|
76
|
+
}
|
|
77
|
+
if (normalized === "false" || normalized === "0" || normalized === "no" || normalized === "off") {
|
|
78
|
+
return false;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
return undefined;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
function requireRunId(bundle, commandName, args) {
|
|
86
|
+
const runId = args[0];
|
|
87
|
+
if (typeof runId === "string" && runId.trim().length > 0) {
|
|
88
|
+
return runId.trim();
|
|
89
|
+
}
|
|
90
|
+
throw new bundle.sdk.PmCliError(`${commandName} requires a runId argument.`, bundle.sdk.EXIT_CODE.USAGE);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export async function runTestRunsListPackage(options, global) {
|
|
94
|
+
const bundle = await ensureRuntimeBundle();
|
|
95
|
+
return bundle.sdk.runTestRunsList(
|
|
96
|
+
{
|
|
97
|
+
status: readStringOption(options, "status"),
|
|
98
|
+
limit: readStringOption(options, "limit"),
|
|
99
|
+
},
|
|
100
|
+
global,
|
|
101
|
+
);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export async function runTestRunsStatusPackage(args, global) {
|
|
105
|
+
const bundle = await ensureRuntimeBundle();
|
|
106
|
+
return bundle.sdk.runTestRunsStatus(requireRunId(bundle, "test-runs status", args), global);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export async function runTestRunsLogsPackage(args, options, global) {
|
|
110
|
+
const bundle = await ensureRuntimeBundle();
|
|
111
|
+
return bundle.sdk.runTestRunsLogs(
|
|
112
|
+
requireRunId(bundle, "test-runs logs", args),
|
|
113
|
+
{
|
|
114
|
+
stream: readStringOption(options, "stream"),
|
|
115
|
+
tail: readStringOption(options, "tail"),
|
|
116
|
+
},
|
|
117
|
+
global,
|
|
118
|
+
);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export async function runTestRunsStopPackage(args, options, global) {
|
|
122
|
+
const bundle = await ensureRuntimeBundle();
|
|
123
|
+
return bundle.sdk.runTestRunsStop(
|
|
124
|
+
requireRunId(bundle, "test-runs stop", args),
|
|
125
|
+
{
|
|
126
|
+
force: readBooleanOption(options, "force") === true,
|
|
127
|
+
},
|
|
128
|
+
global,
|
|
129
|
+
);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export async function runTestRunsResumePackage(args, options, global) {
|
|
133
|
+
const bundle = await ensureRuntimeBundle();
|
|
134
|
+
return bundle.sdk.runTestRunsResume(
|
|
135
|
+
requireRunId(bundle, "test-runs resume", args),
|
|
136
|
+
{
|
|
137
|
+
author: readStringOption(options, "author"),
|
|
138
|
+
noExtensions: global.noExtensions === true,
|
|
139
|
+
},
|
|
140
|
+
global,
|
|
141
|
+
);
|
|
142
|
+
}
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { pathToFileURL } from "node:url";
|
|
3
|
+
import type { GlobalOptions } from "../../../../src/sdk/index.js";
|
|
4
|
+
|
|
5
|
+
const PM_PACKAGE_ROOT_ENV = "PM_CLI_PACKAGE_ROOT";
|
|
6
|
+
|
|
7
|
+
interface RuntimeSdkModule {
|
|
8
|
+
EXIT_CODE: { USAGE: number };
|
|
9
|
+
PmCliError: new (message: string, exitCode?: number) => Error;
|
|
10
|
+
runTestRunsList: (options: Record<string, unknown>, global: GlobalOptions) => Promise<unknown>;
|
|
11
|
+
runTestRunsStatus: (runId: string, global: GlobalOptions) => Promise<unknown>;
|
|
12
|
+
runTestRunsLogs: (runId: string, options: Record<string, unknown>, global: GlobalOptions) => Promise<unknown>;
|
|
13
|
+
runTestRunsStop: (runId: string, options: Record<string, unknown>, global: GlobalOptions) => Promise<unknown>;
|
|
14
|
+
runTestRunsResume: (runId: string, options: Record<string, unknown>, global: GlobalOptions) => Promise<unknown>;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
interface RuntimeBundle {
|
|
18
|
+
sdk: RuntimeSdkModule;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
let runtimeBundle: RuntimeBundle | null = null;
|
|
22
|
+
let runtimeBundlePromise: Promise<RuntimeBundle> | null = null;
|
|
23
|
+
|
|
24
|
+
async function ensureRuntimeBundle(): Promise<RuntimeBundle> {
|
|
25
|
+
if (runtimeBundle) {
|
|
26
|
+
return runtimeBundle;
|
|
27
|
+
}
|
|
28
|
+
if (!runtimeBundlePromise) {
|
|
29
|
+
runtimeBundlePromise = loadRuntimeBundle();
|
|
30
|
+
}
|
|
31
|
+
runtimeBundle = await runtimeBundlePromise;
|
|
32
|
+
return runtimeBundle;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
async function loadRuntimeBundle(): Promise<RuntimeBundle> {
|
|
36
|
+
const envRoot = process.env[PM_PACKAGE_ROOT_ENV];
|
|
37
|
+
if (typeof envRoot !== "string" || envRoot.trim().length === 0) {
|
|
38
|
+
throw new Error(
|
|
39
|
+
`builtin-linked-test-adapters requires ${PM_PACKAGE_ROOT_ENV} to locate core SDK runtime exports.`,
|
|
40
|
+
);
|
|
41
|
+
}
|
|
42
|
+
const modulePath = path.join(path.resolve(envRoot.trim()), "dist", "sdk", "runtime.js");
|
|
43
|
+
try {
|
|
44
|
+
const sdkLoaded = (await import(pathToFileURL(modulePath).href)) as Partial<RuntimeSdkModule>;
|
|
45
|
+
if (
|
|
46
|
+
typeof sdkLoaded.runTestRunsList === "function" &&
|
|
47
|
+
typeof sdkLoaded.runTestRunsStatus === "function" &&
|
|
48
|
+
typeof sdkLoaded.runTestRunsLogs === "function" &&
|
|
49
|
+
typeof sdkLoaded.runTestRunsStop === "function" &&
|
|
50
|
+
typeof sdkLoaded.runTestRunsResume === "function" &&
|
|
51
|
+
typeof sdkLoaded.PmCliError === "function" &&
|
|
52
|
+
typeof sdkLoaded.EXIT_CODE === "object" &&
|
|
53
|
+
sdkLoaded.EXIT_CODE !== null
|
|
54
|
+
) {
|
|
55
|
+
return {
|
|
56
|
+
sdk: sdkLoaded as RuntimeSdkModule,
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
} catch {
|
|
60
|
+
// Fall through to deterministic failure message below.
|
|
61
|
+
}
|
|
62
|
+
throw new Error(
|
|
63
|
+
`builtin-linked-test-adapters failed to load test-runs SDK runtime exports from ${modulePath}.`,
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
function readStringOption(options: Record<string, unknown>, key: string, aliases: string[] = []): string | undefined {
|
|
68
|
+
const keys = [key, ...aliases];
|
|
69
|
+
for (const candidate of keys) {
|
|
70
|
+
const value = options[candidate];
|
|
71
|
+
if (typeof value === "string" && value.trim().length > 0) {
|
|
72
|
+
return value;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
return undefined;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
function readBooleanOption(options: Record<string, unknown>, key: string, aliases: string[] = []): boolean | undefined {
|
|
79
|
+
const keys = [key, ...aliases];
|
|
80
|
+
for (const candidate of keys) {
|
|
81
|
+
const value = options[candidate];
|
|
82
|
+
if (value === undefined) {
|
|
83
|
+
continue;
|
|
84
|
+
}
|
|
85
|
+
if (typeof value === "boolean") {
|
|
86
|
+
return value;
|
|
87
|
+
}
|
|
88
|
+
if (typeof value === "string") {
|
|
89
|
+
const normalized = value.trim().toLowerCase();
|
|
90
|
+
if (normalized === "true" || normalized === "1" || normalized === "yes" || normalized === "on") {
|
|
91
|
+
return true;
|
|
92
|
+
}
|
|
93
|
+
if (normalized === "false" || normalized === "0" || normalized === "no" || normalized === "off") {
|
|
94
|
+
return false;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
return undefined;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
function requireRunId(bundle: RuntimeBundle, commandName: string, args: string[]): string {
|
|
102
|
+
const runId = args[0];
|
|
103
|
+
if (typeof runId === "string" && runId.trim().length > 0) {
|
|
104
|
+
return runId.trim();
|
|
105
|
+
}
|
|
106
|
+
throw new bundle.sdk.PmCliError(`${commandName} requires a runId argument.`, bundle.sdk.EXIT_CODE.USAGE);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export async function runTestRunsListPackage(
|
|
110
|
+
options: Record<string, unknown>,
|
|
111
|
+
global: GlobalOptions,
|
|
112
|
+
): Promise<unknown> {
|
|
113
|
+
const bundle = await ensureRuntimeBundle();
|
|
114
|
+
return bundle.sdk.runTestRunsList(
|
|
115
|
+
{
|
|
116
|
+
status: readStringOption(options, "status"),
|
|
117
|
+
limit: readStringOption(options, "limit"),
|
|
118
|
+
},
|
|
119
|
+
global,
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export async function runTestRunsStatusPackage(args: string[], global: GlobalOptions): Promise<unknown> {
|
|
124
|
+
const bundle = await ensureRuntimeBundle();
|
|
125
|
+
return bundle.sdk.runTestRunsStatus(requireRunId(bundle, "test-runs status", args), global);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export async function runTestRunsLogsPackage(
|
|
129
|
+
args: string[],
|
|
130
|
+
options: Record<string, unknown>,
|
|
131
|
+
global: GlobalOptions,
|
|
132
|
+
): Promise<unknown> {
|
|
133
|
+
const bundle = await ensureRuntimeBundle();
|
|
134
|
+
return bundle.sdk.runTestRunsLogs(
|
|
135
|
+
requireRunId(bundle, "test-runs logs", args),
|
|
136
|
+
{
|
|
137
|
+
stream: readStringOption(options, "stream"),
|
|
138
|
+
tail: readStringOption(options, "tail"),
|
|
139
|
+
},
|
|
140
|
+
global,
|
|
141
|
+
);
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
export async function runTestRunsStopPackage(
|
|
145
|
+
args: string[],
|
|
146
|
+
options: Record<string, unknown>,
|
|
147
|
+
global: GlobalOptions,
|
|
148
|
+
): Promise<unknown> {
|
|
149
|
+
const bundle = await ensureRuntimeBundle();
|
|
150
|
+
return bundle.sdk.runTestRunsStop(
|
|
151
|
+
requireRunId(bundle, "test-runs stop", args),
|
|
152
|
+
{
|
|
153
|
+
force: readBooleanOption(options, "force") === true,
|
|
154
|
+
},
|
|
155
|
+
global,
|
|
156
|
+
);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
export async function runTestRunsResumePackage(
|
|
160
|
+
args: string[],
|
|
161
|
+
options: Record<string, unknown>,
|
|
162
|
+
global: GlobalOptions,
|
|
163
|
+
): Promise<unknown> {
|
|
164
|
+
const bundle = await ensureRuntimeBundle();
|
|
165
|
+
return bundle.sdk.runTestRunsResume(
|
|
166
|
+
requireRunId(bundle, "test-runs resume", args),
|
|
167
|
+
{
|
|
168
|
+
author: readStringOption(options, "author"),
|
|
169
|
+
noExtensions: global.noExtensions === true,
|
|
170
|
+
},
|
|
171
|
+
global,
|
|
172
|
+
);
|
|
173
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@unbrained/pm-linked-test-adapters",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"description": "First-party pm package for optional linked-test run management adapters and reporters.",
|
|
7
|
+
"homepage": "https://github.com/unbraind/pm-cli/tree/main/packages/pm-linked-test-adapters#readme",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/unbraind/pm-cli.git",
|
|
11
|
+
"directory": "packages/pm-linked-test-adapters"
|
|
12
|
+
},
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/unbraind/pm-cli/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"pm-package",
|
|
18
|
+
"project-management",
|
|
19
|
+
"linked-tests",
|
|
20
|
+
"background-runs",
|
|
21
|
+
"test-runs"
|
|
22
|
+
],
|
|
23
|
+
"pm": {
|
|
24
|
+
"aliases": [
|
|
25
|
+
"linked-test-adapters"
|
|
26
|
+
],
|
|
27
|
+
"extensions": [
|
|
28
|
+
"extensions/linked-test-adapters"
|
|
29
|
+
],
|
|
30
|
+
"catalog": {
|
|
31
|
+
"display_name": "Linked Test Adapters",
|
|
32
|
+
"category": "testing",
|
|
33
|
+
"summary": "Restore optional linked-test run management/reporting command surfaces.",
|
|
34
|
+
"tags": [
|
|
35
|
+
"tests",
|
|
36
|
+
"linked-tests",
|
|
37
|
+
"background",
|
|
38
|
+
"reporting"
|
|
39
|
+
],
|
|
40
|
+
"links": {
|
|
41
|
+
"docs": "https://github.com/unbraind/pm-cli/tree/main/packages/pm-linked-test-adapters#readme",
|
|
42
|
+
"repository": "https://github.com/unbraind/pm-cli/tree/main/packages/pm-linked-test-adapters",
|
|
43
|
+
"report": "https://github.com/unbraind/pm-cli/issues"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"docs": [
|
|
47
|
+
"README.md"
|
|
48
|
+
],
|
|
49
|
+
"examples": [
|
|
50
|
+
"README.md"
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# pm-search-advanced
|
|
2
|
+
|
|
3
|
+
First-party package that restores optional advanced search surfaces in bare-core `pm`.
|
|
4
|
+
|
|
5
|
+
## Commands and behavior
|
|
6
|
+
|
|
7
|
+
- Adds `pm search-advanced` with:
|
|
8
|
+
- `--mode keyword|semantic|hybrid`
|
|
9
|
+
- `--include-linked`
|
|
10
|
+
- `--title-exact`
|
|
11
|
+
- `--phrase-exact`
|
|
12
|
+
- Adds `pm reindex` with:
|
|
13
|
+
- `--mode keyword|semantic|hybrid`
|
|
14
|
+
- `--progress`
|
|
15
|
+
|
|
16
|
+
## Install
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
pm install search-advanced --project
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## Verify
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
pm search-advanced "vector cache" --mode hybrid --limit 5 --json
|
|
26
|
+
pm reindex --mode hybrid --progress --json
|
|
27
|
+
```
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { runAdvancedReindexPackage, runAdvancedSearchPackage } from "./runtime.js";
|
|
2
|
+
|
|
3
|
+
export const manifest = {
|
|
4
|
+
name: "builtin-search-advanced",
|
|
5
|
+
version: "0.1.0",
|
|
6
|
+
entry: "./index.js",
|
|
7
|
+
priority: 0,
|
|
8
|
+
capabilities: ["commands"],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
const searchAdvancedFlags = [
|
|
12
|
+
{
|
|
13
|
+
long: "--mode",
|
|
14
|
+
value_name: "value",
|
|
15
|
+
value_type: "string",
|
|
16
|
+
description: "Search mode override: keyword|semantic|hybrid.",
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
long: "--include-linked",
|
|
20
|
+
value_type: "boolean",
|
|
21
|
+
description: "Include linked docs/files/tests corpus in lexical scoring.",
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
long: "--include_linked",
|
|
25
|
+
value_type: "boolean",
|
|
26
|
+
description: "Alias for --include-linked.",
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
long: "--title-exact",
|
|
30
|
+
value_type: "boolean",
|
|
31
|
+
description: "Require exact title phrase matching before scoring.",
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
long: "--title_exact",
|
|
35
|
+
value_type: "boolean",
|
|
36
|
+
description: "Alias for --title-exact.",
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
long: "--phrase-exact",
|
|
40
|
+
value_type: "boolean",
|
|
41
|
+
description: "Require exact phrase match across searchable document fields.",
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
long: "--phrase_exact",
|
|
45
|
+
value_type: "boolean",
|
|
46
|
+
description: "Alias for --phrase-exact.",
|
|
47
|
+
},
|
|
48
|
+
];
|
|
49
|
+
|
|
50
|
+
const reindexFlags = [
|
|
51
|
+
{
|
|
52
|
+
long: "--mode",
|
|
53
|
+
value_name: "value",
|
|
54
|
+
value_type: "string",
|
|
55
|
+
description: "Reindex mode: keyword|semantic|hybrid.",
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
long: "--progress",
|
|
59
|
+
value_type: "boolean",
|
|
60
|
+
description: "Emit non-interactive progress lines to stderr.",
|
|
61
|
+
},
|
|
62
|
+
];
|
|
63
|
+
|
|
64
|
+
function searchAdvancedCommand() {
|
|
65
|
+
return {
|
|
66
|
+
name: "search-advanced",
|
|
67
|
+
action: "search-advanced",
|
|
68
|
+
description: "Enable optional semantic and hybrid search modes via package runtime.",
|
|
69
|
+
arguments: [{ name: "keywords", required: true, variadic: true, description: "Query tokens." }],
|
|
70
|
+
run: async (context) => runAdvancedSearchPackage(context.args, context.options, context.global),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function reindexCommand() {
|
|
75
|
+
return {
|
|
76
|
+
name: "reindex",
|
|
77
|
+
action: "reindex",
|
|
78
|
+
description: "Rebuild search artifacts for keyword, semantic, and hybrid modes.",
|
|
79
|
+
flags: [...reindexFlags],
|
|
80
|
+
run: async (context) => runAdvancedReindexPackage(context.options, context.global),
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export function activate(api) {
|
|
85
|
+
api.registerFlags("search-advanced", [...searchAdvancedFlags]);
|
|
86
|
+
api.registerCommand(searchAdvancedCommand());
|
|
87
|
+
api.registerCommand(reindexCommand());
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export default {
|
|
91
|
+
manifest,
|
|
92
|
+
activate,
|
|
93
|
+
};
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import type { CommandDefinition, ExtensionApi } from "../../../../src/sdk/index.js";
|
|
2
|
+
import { runAdvancedReindexPackage, runAdvancedSearchPackage } from "./runtime.js";
|
|
3
|
+
|
|
4
|
+
export const manifest = {
|
|
5
|
+
name: "builtin-search-advanced",
|
|
6
|
+
version: "0.1.0",
|
|
7
|
+
entry: "./index.js",
|
|
8
|
+
priority: 0,
|
|
9
|
+
capabilities: ["commands", "schema"],
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
const searchAdvancedFlags = [
|
|
13
|
+
{
|
|
14
|
+
long: "--mode",
|
|
15
|
+
value_name: "value",
|
|
16
|
+
value_type: "string",
|
|
17
|
+
description: "Search mode override: keyword|semantic|hybrid.",
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
long: "--include-linked",
|
|
21
|
+
value_type: "boolean",
|
|
22
|
+
description: "Include linked docs/files/tests corpus in lexical scoring.",
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
long: "--include_linked",
|
|
26
|
+
value_type: "boolean",
|
|
27
|
+
description: "Alias for --include-linked.",
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
long: "--title-exact",
|
|
31
|
+
value_type: "boolean",
|
|
32
|
+
description: "Require exact title phrase matching before scoring.",
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
long: "--title_exact",
|
|
36
|
+
value_type: "boolean",
|
|
37
|
+
description: "Alias for --title-exact.",
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
long: "--phrase-exact",
|
|
41
|
+
value_type: "boolean",
|
|
42
|
+
description: "Require exact phrase match across searchable document fields.",
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
long: "--phrase_exact",
|
|
46
|
+
value_type: "boolean",
|
|
47
|
+
description: "Alias for --phrase-exact.",
|
|
48
|
+
},
|
|
49
|
+
] as const;
|
|
50
|
+
|
|
51
|
+
const reindexFlags = [
|
|
52
|
+
{
|
|
53
|
+
long: "--mode",
|
|
54
|
+
value_name: "value",
|
|
55
|
+
value_type: "string",
|
|
56
|
+
description: "Reindex mode: keyword|semantic|hybrid.",
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
long: "--progress",
|
|
60
|
+
value_type: "boolean",
|
|
61
|
+
description: "Emit non-interactive progress lines to stderr.",
|
|
62
|
+
},
|
|
63
|
+
] as const;
|
|
64
|
+
|
|
65
|
+
function searchAdvancedCommand(): CommandDefinition {
|
|
66
|
+
return {
|
|
67
|
+
name: "search-advanced",
|
|
68
|
+
action: "search-advanced",
|
|
69
|
+
description: "Enable optional semantic and hybrid search modes via package runtime.",
|
|
70
|
+
arguments: [{ name: "keywords", required: true, variadic: true, description: "Query tokens." }],
|
|
71
|
+
run: async (context) => runAdvancedSearchPackage(context.args, context.options, context.global),
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function reindexCommand(): CommandDefinition {
|
|
76
|
+
return {
|
|
77
|
+
name: "reindex",
|
|
78
|
+
action: "reindex",
|
|
79
|
+
description: "Rebuild search artifacts for keyword, semantic, and hybrid modes.",
|
|
80
|
+
flags: [...reindexFlags],
|
|
81
|
+
run: async (context) => runAdvancedReindexPackage(context.options, context.global),
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function activate(api: ExtensionApi): void {
|
|
86
|
+
api.registerFlags("search-advanced", [...searchAdvancedFlags]);
|
|
87
|
+
api.registerCommand(searchAdvancedCommand());
|
|
88
|
+
api.registerCommand(reindexCommand());
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export default {
|
|
92
|
+
manifest,
|
|
93
|
+
activate,
|
|
94
|
+
};
|