gsd-pi 2.76.0 → 2.77.0-dev.1d17f366c
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/README.md +32 -30
- package/dist/claude-cli-check.js +32 -3
- package/dist/cli-web-branch.d.ts +1 -0
- package/dist/cli-web-branch.js +3 -0
- package/dist/cli.js +38 -2
- package/dist/extension-discovery.d.ts +6 -0
- package/dist/extension-discovery.js +37 -0
- package/dist/extension-registry.d.ts +3 -0
- package/dist/extension-sort.d.ts +18 -0
- package/dist/extension-sort.js +114 -0
- package/dist/extension-validator.d.ts +47 -0
- package/dist/extension-validator.js +127 -0
- package/dist/loader.js +35 -7
- package/dist/mcp-server.d.ts +7 -0
- package/dist/mcp-server.js +35 -1
- package/dist/onboarding.js +45 -0
- package/dist/provider-migrations.d.ts +18 -0
- package/dist/provider-migrations.js +14 -0
- package/dist/resource-loader.d.ts +1 -1
- package/dist/resource-loader.js +2 -8
- package/dist/resources/agents/researcher.md +1 -1
- package/dist/resources/extensions/claude-code-cli/readiness.js +31 -8
- package/dist/resources/extensions/claude-code-cli/stream-adapter.js +144 -63
- package/dist/resources/extensions/cmux/index.js +20 -0
- package/dist/resources/extensions/github-sync/templates.js +103 -0
- package/dist/resources/extensions/google-search/extension-manifest.json +5 -4
- package/dist/resources/extensions/google-search/index.js +3 -375
- package/dist/resources/extensions/gsd/abandon-detect.js +44 -0
- package/dist/resources/extensions/gsd/auto/loop.js +90 -2
- package/dist/resources/extensions/gsd/auto/phases.js +145 -28
- package/dist/resources/extensions/gsd/auto/resolve.js +24 -0
- package/dist/resources/extensions/gsd/auto/run-unit.js +48 -4
- package/dist/resources/extensions/gsd/auto/session.js +22 -1
- package/dist/resources/extensions/gsd/auto/turn-epoch.js +95 -0
- package/dist/resources/extensions/gsd/auto-dispatch.js +115 -17
- package/dist/resources/extensions/gsd/auto-loop.js +1 -1
- package/dist/resources/extensions/gsd/auto-model-selection.js +53 -16
- package/dist/resources/extensions/gsd/auto-post-unit.js +90 -2
- package/dist/resources/extensions/gsd/auto-prompts.js +14 -0
- package/dist/resources/extensions/gsd/auto-recovery.js +46 -1
- package/dist/resources/extensions/gsd/auto-start.js +84 -60
- package/dist/resources/extensions/gsd/auto-timeout-recovery.js +11 -5
- package/dist/resources/extensions/gsd/auto-unit-closeout.js +11 -2
- package/dist/resources/extensions/gsd/auto-verification.js +33 -0
- package/dist/resources/extensions/gsd/auto-worktree.js +109 -61
- package/dist/resources/extensions/gsd/auto.js +107 -38
- package/dist/resources/extensions/gsd/blocked-models.js +68 -0
- package/dist/resources/extensions/gsd/bootstrap/agent-end-recovery.js +103 -1
- package/dist/resources/extensions/gsd/bootstrap/db-tools.js +39 -9
- package/dist/resources/extensions/gsd/bootstrap/exec-tools.js +93 -0
- package/dist/resources/extensions/gsd/bootstrap/memory-tools.js +3 -0
- package/dist/resources/extensions/gsd/bootstrap/provider-error-resume.js +4 -2
- package/dist/resources/extensions/gsd/bootstrap/register-extension.js +23 -0
- package/dist/resources/extensions/gsd/bootstrap/register-hooks.js +52 -6
- package/dist/resources/extensions/gsd/bootstrap/system-context.js +95 -29
- package/dist/resources/extensions/gsd/bootstrap/write-gate.js +34 -2
- package/dist/resources/extensions/gsd/clean-root-preflight.js +93 -0
- package/dist/resources/extensions/gsd/commands/handlers/workflow.js +31 -4
- package/dist/resources/extensions/gsd/commands-cmux.js +9 -6
- package/dist/resources/extensions/gsd/commands-extensions.js +634 -43
- package/dist/resources/extensions/gsd/commands-extract-learnings.js +54 -89
- package/dist/resources/extensions/gsd/commands-prefs-wizard.js +968 -23
- package/dist/resources/extensions/gsd/compaction-snapshot.js +121 -0
- package/dist/resources/extensions/gsd/complexity-classifier.js +5 -3
- package/dist/resources/extensions/gsd/db-writer.js +88 -16
- package/dist/resources/extensions/gsd/dispatch-guard.js +29 -3
- package/dist/resources/extensions/gsd/doctor-git-checks.js +23 -29
- package/dist/resources/extensions/gsd/doctor-providers.js +51 -5
- package/dist/resources/extensions/gsd/ecosystem/gsd-extension-api.js +1 -0
- package/dist/resources/extensions/gsd/error-classifier.js +31 -3
- package/dist/resources/extensions/gsd/exec-history.js +120 -0
- package/dist/resources/extensions/gsd/exec-sandbox.js +258 -0
- package/dist/resources/extensions/gsd/file-lock.js +49 -9
- package/dist/resources/extensions/gsd/git-service.js +1 -0
- package/dist/resources/extensions/gsd/gitignore.js +2 -0
- package/dist/resources/extensions/gsd/gsd-db.js +168 -23
- package/dist/resources/extensions/gsd/guided-flow-queue.js +4 -1
- package/dist/resources/extensions/gsd/guided-flow.js +212 -9
- package/dist/resources/extensions/gsd/health-widget.js +4 -1
- package/dist/resources/extensions/gsd/hook-emitter.js +108 -0
- package/dist/resources/extensions/gsd/init-wizard.js +15 -1
- package/dist/resources/extensions/gsd/journal.js +17 -2
- package/dist/resources/extensions/gsd/key-manager.js +28 -0
- package/dist/resources/extensions/gsd/memory-backfill.js +126 -0
- package/dist/resources/extensions/gsd/memory-store.js +19 -0
- package/dist/resources/extensions/gsd/milestone-actions.js +15 -0
- package/dist/resources/extensions/gsd/milestone-summary-classifier.js +37 -0
- package/dist/resources/extensions/gsd/model-router.js +36 -3
- package/dist/resources/extensions/gsd/notifications.js +30 -16
- package/dist/resources/extensions/gsd/pre-execution-checks.js +44 -9
- package/dist/resources/extensions/gsd/preferences-types.js +9 -0
- package/dist/resources/extensions/gsd/preferences-validation.js +83 -0
- package/dist/resources/extensions/gsd/preferences.js +17 -17
- package/dist/resources/extensions/gsd/prompt-loader.js +22 -7
- package/dist/resources/extensions/gsd/prompts/complete-milestone.md +1 -1
- package/dist/resources/extensions/gsd/prompts/complete-slice.md +2 -2
- package/dist/resources/extensions/gsd/prompts/debug-diagnose.md +2 -0
- package/dist/resources/extensions/gsd/prompts/discuss-headless.md +29 -2
- package/dist/resources/extensions/gsd/prompts/discuss.md +29 -2
- package/dist/resources/extensions/gsd/prompts/doctor-heal.md +5 -4
- package/dist/resources/extensions/gsd/prompts/execute-task.md +3 -2
- package/dist/resources/extensions/gsd/prompts/parallel-research-slices.md +5 -2
- package/dist/resources/extensions/gsd/prompts/plan-slice.md +1 -0
- package/dist/resources/extensions/gsd/prompts/research-slice.md +1 -0
- package/dist/resources/extensions/gsd/prompts/system.md +1 -0
- package/dist/resources/extensions/gsd/reports.js +5 -4
- package/dist/resources/extensions/gsd/safety/evidence-collector.js +96 -0
- package/dist/resources/extensions/gsd/safety/file-change-validator.js +13 -5
- package/dist/resources/extensions/gsd/safety/safety-harness.js +5 -1
- package/dist/resources/extensions/gsd/state-transition-matrix.js +118 -0
- package/dist/resources/extensions/gsd/state.js +68 -29
- package/dist/resources/extensions/gsd/token-counter.js +22 -5
- package/dist/resources/extensions/gsd/tools/complete-milestone.js +16 -10
- package/dist/resources/extensions/gsd/tools/complete-slice.js +21 -0
- package/dist/resources/extensions/gsd/tools/complete-task.js +31 -0
- package/dist/resources/extensions/gsd/tools/exec-search-tool.js +59 -0
- package/dist/resources/extensions/gsd/tools/exec-tool.js +126 -0
- package/dist/resources/extensions/gsd/tools/memory-tools.js +26 -1
- package/dist/resources/extensions/gsd/tools/resume-tool.js +23 -0
- package/dist/resources/extensions/gsd/uok/audit.js +18 -2
- package/dist/resources/extensions/gsd/uok/dispatch-envelope.js +33 -0
- package/dist/resources/extensions/gsd/uok/execution-graph.js +10 -0
- package/dist/resources/extensions/gsd/uok/gitops.js +2 -1
- package/dist/resources/extensions/gsd/uok/loop-adapter.js +37 -10
- package/dist/resources/extensions/gsd/uok/parity-report.js +58 -0
- package/dist/resources/extensions/gsd/uok/plan-v2.js +30 -7
- package/dist/resources/extensions/gsd/uok/writer.js +82 -0
- package/dist/resources/extensions/gsd/workflow-logger.js +10 -2
- package/dist/resources/extensions/gsd/workflow-mcp.js +3 -0
- package/dist/resources/extensions/gsd/workflow-templates/spike.md +6 -0
- package/dist/resources/extensions/gsd/worktree-manager.js +1 -0
- package/dist/resources/extensions/gsd/worktree-resolver.js +50 -10
- package/dist/resources/extensions/mcp-client/auth.js +10 -1
- package/dist/resources/extensions/mcp-client/index.js +118 -9
- package/dist/resources/extensions/search-the-web/command-search-provider.js +5 -4
- package/dist/resources/extensions/search-the-web/native-search.js +45 -13
- package/dist/resources/extensions/shared/cmux-events.js +12 -0
- package/dist/resources/extensions/shared/rtk-session-stats.js +1 -2
- package/dist/resources/skills/api-design/SKILL.md +190 -0
- package/dist/resources/skills/create-mcp-server/SKILL.md +121 -0
- package/dist/resources/skills/create-skill/SKILL.md +2 -2
- package/dist/resources/skills/create-skill/references/gsd-skill-ecosystem.md +4 -4
- package/dist/resources/skills/create-skill/workflows/audit-skill.md +4 -4
- package/dist/resources/skills/create-skill/workflows/create-new-skill.md +5 -5
- package/dist/resources/skills/decompose-into-slices/SKILL.md +139 -0
- package/dist/resources/skills/dependency-upgrade/SKILL.md +158 -0
- package/dist/resources/skills/design-an-interface/SKILL.md +102 -0
- package/dist/resources/skills/forensics/SKILL.md +153 -0
- package/dist/resources/skills/grill-me/SKILL.md +93 -0
- package/dist/resources/skills/handoff/SKILL.md +121 -0
- package/dist/resources/skills/observability/SKILL.md +174 -0
- package/dist/resources/skills/security-review/SKILL.md +181 -0
- package/dist/resources/skills/spike-wrap-up/SKILL.md +138 -0
- package/dist/resources/skills/tdd/SKILL.md +112 -0
- package/dist/resources/skills/verify-before-complete/SKILL.md +98 -0
- package/dist/resources/skills/write-docs/SKILL.md +82 -0
- package/dist/resources/skills/write-milestone-brief/SKILL.md +135 -0
- package/dist/tsconfig.extensions.tsbuildinfo +1 -1
- package/dist/web/standalone/.next/BUILD_ID +1 -1
- package/dist/web/standalone/.next/app-path-routes-manifest.json +13 -13
- package/dist/web/standalone/.next/build-manifest.json +4 -4
- package/dist/web/standalone/.next/prerender-manifest.json +3 -3
- package/dist/web/standalone/.next/react-loadable-manifest.json +1 -1
- package/dist/web/standalone/.next/required-server-files.json +4 -4
- package/dist/web/standalone/.next/server/app/_global-error/page.js +3 -3
- package/dist/web/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.html +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found/page.js +2 -2
- package/dist/web/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.html +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/api/boot/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/boot/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/boot/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/input/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/input/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/input/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/resize/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/resize/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/resize/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/stream/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/stream/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/stream/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/browse-directories/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/browse-directories/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/captures/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/captures/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/captures/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/cleanup/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/cleanup/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/cleanup/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/dev-mode/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/dev-mode/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/doctor/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/doctor/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/doctor/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/experimental/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/experimental/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/export-data/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/export-data/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/export-data/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/files/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/files/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/files/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/forensics/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/forensics/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/forensics/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/git/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/git/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/git/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/history/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/history/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/history/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/hooks/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/hooks/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/hooks/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/inspect/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/inspect/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/inspect/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/knowledge/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/knowledge/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/knowledge/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/live-state/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/live-state/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/live-state/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/notifications/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/notifications/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/notifications/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/onboarding/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/onboarding/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/onboarding/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/preferences/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/preferences/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/projects/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/projects/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/recovery/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/recovery/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/recovery/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/remote-questions/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/remote-questions/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/browser/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/browser/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/session/browser/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/command/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/command/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/session/command/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/events/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/session/events/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/session/events/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/manage/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/manage/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/session/manage/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/settings-data/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/settings-data/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/settings-data/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/shutdown/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/shutdown/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/skill-health/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/skill-health/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/skill-health/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/steer/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/steer/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/steer/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/switch-root/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/switch-root/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/switch-root/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/input/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/input/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/resize/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/resize/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/sessions/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/sessions/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/sessions/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/stream/route.js +4 -4
- package/dist/web/standalone/.next/server/app/api/terminal/stream/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/stream/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/upload/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/upload/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/undo/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/undo/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/undo/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/update/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/update/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/visualizer/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/visualizer/route.js.nft.json +1 -1
- package/dist/web/standalone/.next/server/app/api/visualizer/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/index.html +1 -1
- package/dist/web/standalone/.next/server/app/index.rsc +4 -4
- package/dist/web/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/dist/web/standalone/.next/server/app/index.segments/_full.segment.rsc +4 -4
- package/dist/web/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/index.segments/_index.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/page.js +2 -2
- package/dist/web/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app-paths-manifest.json +13 -13
- package/dist/web/standalone/.next/server/chunks/1926.js +1 -0
- package/dist/web/standalone/.next/server/chunks/63.js +3 -3
- package/dist/web/standalone/.next/server/chunks/6897.js +3 -3
- package/dist/web/standalone/.next/server/middleware-build-manifest.js +1 -1
- package/dist/web/standalone/.next/server/middleware-manifest.json +5 -5
- package/dist/web/standalone/.next/server/middleware-react-loadable-manifest.js +1 -1
- package/dist/web/standalone/.next/server/middleware.js +2 -2
- package/dist/web/standalone/.next/server/next-font-manifest.js +1 -1
- package/dist/web/standalone/.next/server/next-font-manifest.json +1 -1
- package/dist/web/standalone/.next/server/pages/404.html +1 -1
- package/dist/web/standalone/.next/server/pages/500.html +1 -1
- package/dist/web/standalone/.next/server/server-reference-manifest.json +1 -1
- package/dist/web/standalone/.next/static/chunks/2826.e9f5195e91f9cad2.js +11 -0
- package/dist/web/standalone/.next/static/chunks/app/_not-found/{page-2f24283c162b6ab3.js → page-f2a7482d42a5614b.js} +1 -1
- package/dist/web/standalone/.next/static/chunks/app/{layout-9ecfd95f343793f0.js → layout-a16c7a7ecdf0c2cf.js} +1 -1
- package/dist/web/standalone/.next/static/chunks/app/page-5b113fd32bc2a1c3.js +1 -0
- package/dist/web/standalone/.next/static/chunks/main-app-fdab67f7802d7832.js +1 -0
- package/dist/web/standalone/.next/static/chunks/next/dist/client/components/builtin/global-error-459824ffb8c323dd.js +1 -0
- package/dist/web/standalone/.next/static/chunks/{webpack-5fc74f13a25fa1bb.js → webpack-2e68521d7c82f7c2.js} +1 -1
- package/dist/web/standalone/node_modules/node-pty/build/Makefile +2 -2
- package/dist/web/standalone/node_modules/node-pty/build/Release/pty.node +0 -0
- package/dist/web/standalone/node_modules/node-pty/build/pty.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api_except.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api_maybe.target.mk +14 -14
- package/dist/web/standalone/server.js +1 -1
- package/dist/welcome-screen.js +6 -1
- package/dist/wizard.js +2 -0
- package/package.json +16 -14
- package/packages/daemon/package.json +2 -2
- package/packages/mcp-server/README.md +3 -3
- package/packages/mcp-server/dist/env-writer.d.ts +1 -0
- package/packages/mcp-server/dist/env-writer.d.ts.map +1 -1
- package/packages/mcp-server/dist/env-writer.js +74 -6
- package/packages/mcp-server/dist/env-writer.js.map +1 -1
- package/packages/mcp-server/dist/remote-questions.d.ts +45 -0
- package/packages/mcp-server/dist/remote-questions.d.ts.map +1 -0
- package/packages/mcp-server/dist/remote-questions.js +732 -0
- package/packages/mcp-server/dist/remote-questions.js.map +1 -0
- package/packages/mcp-server/dist/server.d.ts +7 -0
- package/packages/mcp-server/dist/server.d.ts.map +1 -1
- package/packages/mcp-server/dist/server.js +95 -10
- package/packages/mcp-server/dist/server.js.map +1 -1
- package/packages/mcp-server/dist/session-manager.d.ts +14 -0
- package/packages/mcp-server/dist/session-manager.d.ts.map +1 -1
- package/packages/mcp-server/dist/session-manager.js +49 -1
- package/packages/mcp-server/dist/session-manager.js.map +1 -1
- package/packages/mcp-server/dist/workflow-tools.d.ts +1 -1
- package/packages/mcp-server/dist/workflow-tools.d.ts.map +1 -1
- package/packages/mcp-server/dist/workflow-tools.js +178 -31
- package/packages/mcp-server/dist/workflow-tools.js.map +1 -1
- package/packages/mcp-server/package.json +9 -3
- package/packages/mcp-server/src/env-writer.test.ts +79 -1
- package/packages/mcp-server/src/env-writer.ts +76 -6
- package/packages/mcp-server/src/mcp-server.test.ts +67 -0
- package/packages/mcp-server/src/readers/readers.test.ts +5 -1
- package/packages/mcp-server/src/remote-questions.test.ts +294 -0
- package/packages/mcp-server/src/remote-questions.ts +916 -0
- package/packages/mcp-server/src/server.ts +118 -16
- package/packages/mcp-server/src/session-manager.ts +43 -1
- package/packages/mcp-server/src/workflow-tools.test.ts +190 -1
- package/packages/mcp-server/src/workflow-tools.ts +234 -49
- package/packages/mcp-server/tsconfig.test.json +19 -0
- package/packages/mcp-server/tsconfig.tsbuildinfo +1 -1
- package/packages/native/package.json +6 -1
- package/packages/native/src/__tests__/clipboard.test.mjs +69 -23
- package/packages/native/tsconfig.tsbuildinfo +1 -1
- package/packages/pi-agent-core/dist/agent-loop.js +12 -0
- package/packages/pi-agent-core/dist/agent-loop.js.map +1 -1
- package/packages/pi-agent-core/dist/types.d.ts +30 -0
- package/packages/pi-agent-core/dist/types.d.ts.map +1 -1
- package/packages/pi-agent-core/dist/types.js.map +1 -1
- package/packages/pi-agent-core/package.json +6 -1
- package/packages/pi-agent-core/src/agent-loop.test.ts +220 -15
- package/packages/pi-agent-core/src/agent-loop.ts +14 -0
- package/packages/pi-agent-core/src/types.ts +34 -0
- package/packages/pi-agent-core/tsconfig.tsbuildinfo +1 -1
- package/packages/pi-ai/dist/models/custom.d.ts +38 -0
- package/packages/pi-ai/dist/models/custom.d.ts.map +1 -1
- package/packages/pi-ai/dist/models/custom.js +41 -0
- package/packages/pi-ai/dist/models/custom.js.map +1 -1
- package/packages/pi-ai/dist/providers/anthropic-auth.test.js +1 -1
- package/packages/pi-ai/dist/providers/anthropic-auth.test.js.map +1 -1
- package/packages/pi-ai/dist/providers/anthropic-bearer-auth.test.d.ts +2 -0
- package/packages/pi-ai/dist/providers/anthropic-bearer-auth.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/providers/anthropic-bearer-auth.test.js +13 -0
- package/packages/pi-ai/dist/providers/anthropic-bearer-auth.test.js.map +1 -0
- package/packages/pi-ai/dist/providers/anthropic-shared.d.ts.map +1 -1
- package/packages/pi-ai/dist/providers/anthropic-shared.js +27 -4
- package/packages/pi-ai/dist/providers/anthropic-shared.js.map +1 -1
- package/packages/pi-ai/dist/providers/anthropic.d.ts.map +1 -1
- package/packages/pi-ai/dist/providers/anthropic.js +13 -4
- package/packages/pi-ai/dist/providers/anthropic.js.map +1 -1
- package/packages/pi-ai/dist/providers/minimax-tool-name.test.d.ts +2 -0
- package/packages/pi-ai/dist/providers/minimax-tool-name.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/providers/minimax-tool-name.test.js +80 -0
- package/packages/pi-ai/dist/providers/minimax-tool-name.test.js.map +1 -0
- package/packages/pi-ai/dist/providers/openai-completions.d.ts.map +1 -1
- package/packages/pi-ai/dist/providers/openai-completions.js +60 -15
- package/packages/pi-ai/dist/providers/openai-completions.js.map +1 -1
- package/packages/pi-ai/dist/providers/simple-options.d.ts +10 -0
- package/packages/pi-ai/dist/providers/simple-options.d.ts.map +1 -1
- package/packages/pi-ai/dist/providers/simple-options.js +16 -1
- package/packages/pi-ai/dist/providers/simple-options.js.map +1 -1
- package/packages/pi-ai/dist/providers/think-tag-parser.d.ts +17 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.d.ts.map +1 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.js +75 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.js.map +1 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.test.d.ts +2 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.test.js +41 -0
- package/packages/pi-ai/dist/providers/think-tag-parser.test.js.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/github-copilot.d.ts.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/github-copilot.js +12 -2
- package/packages/pi-ai/dist/utils/oauth/github-copilot.js.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/github-copilot.test.js +164 -14
- package/packages/pi-ai/dist/utils/oauth/github-copilot.test.js.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.d.ts.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.js +15 -3
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.js.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.test.d.ts +2 -0
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.test.js +67 -0
- package/packages/pi-ai/dist/utils/oauth/google-antigravity.test.js.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.d.ts.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.js +16 -3
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.js.map +1 -1
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.test.d.ts +2 -0
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.test.js +67 -0
- package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.test.js.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/oauth-providers.test.d.ts +2 -0
- package/packages/pi-ai/dist/utils/oauth/oauth-providers.test.d.ts.map +1 -0
- package/packages/pi-ai/dist/utils/oauth/oauth-providers.test.js +289 -0
- package/packages/pi-ai/dist/utils/oauth/oauth-providers.test.js.map +1 -0
- package/packages/pi-ai/package.json +6 -1
- package/packages/pi-ai/src/models/custom.ts +42 -0
- package/packages/pi-ai/src/providers/anthropic-auth.test.ts +1 -1
- package/packages/pi-ai/src/providers/anthropic-bearer-auth.test.ts +26 -0
- package/packages/pi-ai/src/providers/anthropic-shared.ts +26 -5
- package/packages/pi-ai/src/providers/anthropic.ts +15 -4
- package/packages/pi-ai/src/providers/minimax-tool-name.test.ts +98 -0
- package/packages/pi-ai/src/providers/openai-completions.ts +57 -16
- package/packages/pi-ai/src/providers/simple-options.ts +17 -1
- package/packages/pi-ai/src/providers/think-tag-parser.test.ts +44 -0
- package/packages/pi-ai/src/providers/think-tag-parser.ts +94 -0
- package/packages/pi-ai/src/utils/oauth/github-copilot.test.ts +200 -23
- package/packages/pi-ai/src/utils/oauth/github-copilot.ts +12 -2
- package/packages/pi-ai/src/utils/oauth/google-antigravity.test.ts +84 -0
- package/packages/pi-ai/src/utils/oauth/google-antigravity.ts +15 -5
- package/packages/pi-ai/src/utils/oauth/google-gemini-cli.test.ts +84 -0
- package/packages/pi-ai/src/utils/oauth/google-gemini-cli.ts +16 -5
- package/packages/pi-ai/src/utils/oauth/oauth-providers.test.ts +363 -0
- package/packages/pi-ai/tsconfig.tsbuildinfo +1 -1
- package/packages/pi-coding-agent/dist/core/agent-session-abort-order.test.js +3 -2
- package/packages/pi-coding-agent/dist/core/agent-session-abort-order.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/agent-session.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/agent-session.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/agent-session.js +32 -2
- package/packages/pi-coding-agent/dist/core/agent-session.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction/compaction.d.ts +25 -0
- package/packages/pi-coding-agent/dist/core/compaction/compaction.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction/compaction.js +105 -6
- package/packages/pi-coding-agent/dist/core/compaction/compaction.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction/compaction.test.js +230 -28
- package/packages/pi-coding-agent/dist/core/compaction/compaction.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction/utils.d.ts +30 -2
- package/packages/pi-coding-agent/dist/core/compaction/utils.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction/utils.js +113 -12
- package/packages/pi-coding-agent/dist/core/compaction/utils.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.d.ts +1 -0
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.js +29 -18
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.test.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.test.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.test.js +130 -0
- package/packages/pi-coding-agent/dist/core/compaction-orchestrator.test.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/compaction-utils.test.js +56 -1
- package/packages/pi-coding-agent/dist/core/compaction-utils.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/discovery-cache.test.js +8 -15
- package/packages/pi-coding-agent/dist/core/discovery-cache.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/extension-discovery.d.ts +25 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-discovery.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-discovery.js +109 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-discovery.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-registry.d.ts +67 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-registry.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-registry.js +167 -0
- package/packages/pi-coding-agent/dist/core/extensions/extension-registry.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/extensions/index.d.ts +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/index.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/index.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/loader.d.ts +3 -2
- package/packages/pi-coding-agent/dist/core/extensions/loader.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/loader.js +28 -8
- package/packages/pi-coding-agent/dist/core/extensions/loader.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts +35 -2
- package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/runner.js +233 -0
- package/packages/pi-coding-agent/dist/core/extensions/runner.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/types.d.ts +212 -2
- package/packages/pi-coding-agent/dist/core/extensions/types.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/extensions/types.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/hooks-runner.d.ts +53 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.js +337 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.test.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.test.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.test.js +234 -0
- package/packages/pi-coding-agent/dist/core/hooks-runner.test.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/index.d.ts +1 -0
- package/packages/pi-coding-agent/dist/core/index.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/index.js +1 -0
- package/packages/pi-coding-agent/dist/core/index.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/lsp/lsp-integration.test.js +11 -0
- package/packages/pi-coding-agent/dist/core/lsp/lsp-integration.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-discovery.d.ts +3 -1
- package/packages/pi-coding-agent/dist/core/model-discovery.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-discovery.js +92 -12
- package/packages/pi-coding-agent/dist/core/model-discovery.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-discovery.test.js +16 -1
- package/packages/pi-coding-agent/dist/core/model-discovery.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-registry-auth-header.test.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/model-registry-auth-header.test.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/model-registry-auth-header.test.js +40 -0
- package/packages/pi-coding-agent/dist/core/model-registry-auth-header.test.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/model-registry-auth-mode.test.js +2 -2
- package/packages/pi-coding-agent/dist/core/model-registry-auth-mode.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-registry-custom-caps.test.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/model-registry-custom-caps.test.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/model-registry-custom-caps.test.js +203 -0
- package/packages/pi-coding-agent/dist/core/model-registry-custom-caps.test.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/model-registry-discovery.test.js +61 -1
- package/packages/pi-coding-agent/dist/core/model-registry-discovery.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-registry.d.ts +5 -0
- package/packages/pi-coding-agent/dist/core/model-registry.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/model-registry.js +90 -10
- package/packages/pi-coding-agent/dist/core/model-registry.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/redact-secrets.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.js +49 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.test.d.ts +2 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.test.d.ts.map +1 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.test.js +67 -0
- package/packages/pi-coding-agent/dist/core/redact-secrets.test.js.map +1 -0
- package/packages/pi-coding-agent/dist/core/resource-loader.js +1 -1
- package/packages/pi-coding-agent/dist/core/resource-loader.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/sdk.d.ts +1 -0
- package/packages/pi-coding-agent/dist/core/sdk.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/sdk.js +4 -1
- package/packages/pi-coding-agent/dist/core/sdk.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/sdk.test.js +19 -1
- package/packages/pi-coding-agent/dist/core/sdk.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/session-manager.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/session-manager.js +10 -6
- package/packages/pi-coding-agent/dist/core/session-manager.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/session-manager.test.js +45 -1
- package/packages/pi-coding-agent/dist/core/session-manager.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/settings-manager.d.ts +55 -0
- package/packages/pi-coding-agent/dist/core/settings-manager.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/core/settings-manager.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/system-prompt.js +3 -3
- package/packages/pi-coding-agent/dist/core/system-prompt.js.map +1 -1
- package/packages/pi-coding-agent/dist/core/tools/path-utils.test.js +2 -1
- package/packages/pi-coding-agent/dist/core/tools/path-utils.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/index.d.ts +1 -1
- package/packages/pi-coding-agent/dist/index.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/index.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/__tests__/provider-display-name.test.js +15 -6
- package/packages/pi-coding-agent/dist/modes/interactive/components/__tests__/provider-display-name.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/chat-frame.d.ts +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/chat-frame.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/chat-frame.js +5 -4
- package/packages/pi-coding-agent/dist/modes/interactive/components/chat-frame.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/footer.js +14 -5
- package/packages/pi-coding-agent/dist/modes/interactive/components/footer.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts +7 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/model-selector.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/model-selector.js +31 -9
- package/packages/pi-coding-agent/dist/modes/interactive/components/model-selector.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/provider-manager.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/provider-manager.js +13 -7
- package/packages/pi-coding-agent/dist/modes/interactive/components/provider-manager.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts +7 -6
- package/packages/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js +29 -21
- package/packages/pi-coding-agent/dist/modes/interactive/components/skill-invocation-message.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/controllers/input-controller.test.js +14 -0
- package/packages/pi-coding-agent/dist/modes/interactive/controllers/input-controller.test.js.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/packages/pi-coding-agent/dist/modes/interactive/interactive-mode.js +13 -1
- package/packages/pi-coding-agent/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/packages/pi-coding-agent/package.json +6 -1
- package/packages/pi-coding-agent/src/core/agent-session-abort-order.test.ts +3 -2
- package/packages/pi-coding-agent/src/core/agent-session.ts +38 -2
- package/packages/pi-coding-agent/src/core/compaction/compaction.test.ts +368 -28
- package/packages/pi-coding-agent/src/core/compaction/compaction.ts +122 -6
- package/packages/pi-coding-agent/src/core/compaction/utils.ts +111 -13
- package/packages/pi-coding-agent/src/core/compaction-orchestrator.test.ts +154 -0
- package/packages/pi-coding-agent/src/core/compaction-orchestrator.ts +32 -18
- package/packages/pi-coding-agent/src/core/compaction-utils.test.ts +68 -1
- package/packages/pi-coding-agent/src/core/discovery-cache.test.ts +9 -18
- package/packages/pi-coding-agent/src/core/extensions/extension-discovery.ts +119 -0
- package/packages/pi-coding-agent/src/core/extensions/extension-registry.ts +222 -0
- package/packages/pi-coding-agent/src/core/extensions/index.ts +16 -0
- package/packages/pi-coding-agent/src/core/extensions/loader.ts +29 -11
- package/packages/pi-coding-agent/src/core/extensions/runner.ts +351 -0
- package/packages/pi-coding-agent/src/core/extensions/types.ts +266 -0
- package/packages/pi-coding-agent/src/core/hooks-runner.test.ts +269 -0
- package/packages/pi-coding-agent/src/core/hooks-runner.ts +460 -0
- package/packages/pi-coding-agent/src/core/index.ts +10 -0
- package/packages/pi-coding-agent/src/core/lsp/lsp-integration.test.ts +13 -0
- package/packages/pi-coding-agent/src/core/model-discovery.test.ts +19 -0
- package/packages/pi-coding-agent/src/core/model-discovery.ts +99 -12
- package/packages/pi-coding-agent/src/core/model-registry-auth-header.test.ts +44 -0
- package/packages/pi-coding-agent/src/core/model-registry-auth-mode.test.ts +2 -2
- package/packages/pi-coding-agent/src/core/model-registry-custom-caps.test.ts +245 -0
- package/packages/pi-coding-agent/src/core/model-registry-discovery.test.ts +75 -0
- package/packages/pi-coding-agent/src/core/model-registry.ts +102 -10
- package/packages/pi-coding-agent/src/core/redact-secrets.test.ts +86 -0
- package/packages/pi-coding-agent/src/core/redact-secrets.ts +58 -0
- package/packages/pi-coding-agent/src/core/resource-loader.ts +1 -1
- package/packages/pi-coding-agent/src/core/sdk.test.ts +25 -1
- package/packages/pi-coding-agent/src/core/sdk.ts +10 -3
- package/packages/pi-coding-agent/src/core/session-manager.test.ts +65 -1
- package/packages/pi-coding-agent/src/core/session-manager.ts +10 -6
- package/packages/pi-coding-agent/src/core/settings-manager.ts +57 -0
- package/packages/pi-coding-agent/src/core/system-prompt.ts +3 -3
- package/packages/pi-coding-agent/src/core/tools/path-utils.test.ts +2 -1
- package/packages/pi-coding-agent/src/index.ts +16 -0
- package/packages/pi-coding-agent/src/modes/interactive/components/__tests__/provider-display-name.test.ts +17 -7
- package/packages/pi-coding-agent/src/modes/interactive/components/chat-frame.ts +6 -6
- package/packages/pi-coding-agent/src/modes/interactive/components/footer.ts +14 -5
- package/packages/pi-coding-agent/src/modes/interactive/components/model-selector.ts +45 -11
- package/packages/pi-coding-agent/src/modes/interactive/components/provider-manager.ts +16 -7
- package/packages/pi-coding-agent/src/modes/interactive/components/skill-invocation-message.ts +36 -22
- package/packages/pi-coding-agent/src/modes/interactive/controllers/input-controller.test.ts +14 -0
- package/packages/pi-coding-agent/src/modes/interactive/interactive-mode.ts +13 -1
- package/packages/pi-coding-agent/tsconfig.tsbuildinfo +1 -1
- package/packages/pi-tui/dist/__tests__/autocomplete.test.js +12 -5
- package/packages/pi-tui/dist/__tests__/autocomplete.test.js.map +1 -1
- package/packages/pi-tui/dist/__tests__/stdin-buffer.test.js +21 -0
- package/packages/pi-tui/dist/__tests__/stdin-buffer.test.js.map +1 -1
- package/packages/pi-tui/dist/stdin-buffer.d.ts +7 -0
- package/packages/pi-tui/dist/stdin-buffer.d.ts.map +1 -1
- package/packages/pi-tui/dist/stdin-buffer.js +20 -0
- package/packages/pi-tui/dist/stdin-buffer.js.map +1 -1
- package/packages/pi-tui/package.json +6 -1
- package/packages/pi-tui/src/__tests__/autocomplete.test.ts +20 -5
- package/packages/pi-tui/src/__tests__/stdin-buffer.test.ts +27 -0
- package/packages/pi-tui/src/stdin-buffer.ts +26 -0
- package/packages/pi-tui/tsconfig.tsbuildinfo +1 -1
- package/packages/rpc-client/package.json +6 -1
- package/pkg/package.json +1 -1
- package/scripts/install.js +512 -0
- package/scripts/lib/workspace-manifest.cjs +86 -0
- package/scripts/link-workspace-packages.cjs +5 -16
- package/scripts/postinstall.js +9 -178
- package/src/resources/agents/researcher.md +1 -1
- package/src/resources/extensions/claude-code-cli/readiness.ts +32 -8
- package/src/resources/extensions/claude-code-cli/stream-adapter.ts +158 -67
- package/src/resources/extensions/claude-code-cli/tests/stream-adapter.test.ts +251 -14
- package/src/resources/extensions/cmux/index.ts +35 -10
- package/src/resources/extensions/github-sync/templates.ts +151 -0
- package/src/resources/extensions/github-sync/tests/templates.test.ts +59 -0
- package/src/resources/extensions/google-search/extension-manifest.json +5 -4
- package/src/resources/extensions/google-search/index.ts +9 -470
- package/src/resources/extensions/gsd/abandon-detect.ts +62 -0
- package/src/resources/extensions/gsd/auto/loop-deps.ts +15 -1
- package/src/resources/extensions/gsd/auto/loop.ts +104 -2
- package/src/resources/extensions/gsd/auto/phases.ts +176 -27
- package/src/resources/extensions/gsd/auto/resolve.ts +29 -0
- package/src/resources/extensions/gsd/auto/run-unit.ts +56 -4
- package/src/resources/extensions/gsd/auto/session.ts +35 -2
- package/src/resources/extensions/gsd/auto/turn-epoch.ts +108 -0
- package/src/resources/extensions/gsd/auto/types.ts +1 -1
- package/src/resources/extensions/gsd/auto-dispatch.ts +117 -16
- package/src/resources/extensions/gsd/auto-loop.ts +1 -1
- package/src/resources/extensions/gsd/auto-model-selection.ts +71 -15
- package/src/resources/extensions/gsd/auto-post-unit.ts +92 -3
- package/src/resources/extensions/gsd/auto-prompts.ts +28 -1
- package/src/resources/extensions/gsd/auto-recovery.ts +40 -1
- package/src/resources/extensions/gsd/auto-start.ts +88 -74
- package/src/resources/extensions/gsd/auto-timeout-recovery.ts +12 -5
- package/src/resources/extensions/gsd/auto-unit-closeout.ts +14 -3
- package/src/resources/extensions/gsd/auto-verification.ts +33 -0
- package/src/resources/extensions/gsd/auto-worktree.ts +122 -68
- package/src/resources/extensions/gsd/auto.ts +115 -42
- package/src/resources/extensions/gsd/blocked-models.ts +98 -0
- package/src/resources/extensions/gsd/bootstrap/agent-end-recovery.ts +131 -1
- package/src/resources/extensions/gsd/bootstrap/db-tools.ts +40 -9
- package/src/resources/extensions/gsd/bootstrap/exec-tools.ts +109 -0
- package/src/resources/extensions/gsd/bootstrap/memory-tools.ts +5 -0
- package/src/resources/extensions/gsd/bootstrap/provider-error-resume.ts +6 -2
- package/src/resources/extensions/gsd/bootstrap/register-extension.ts +26 -0
- package/src/resources/extensions/gsd/bootstrap/register-hooks.ts +54 -6
- package/src/resources/extensions/gsd/bootstrap/system-context.ts +102 -35
- package/src/resources/extensions/gsd/bootstrap/write-gate.ts +35 -2
- package/src/resources/extensions/gsd/clean-root-preflight.ts +111 -0
- package/src/resources/extensions/gsd/commands/handlers/workflow.ts +27 -8
- package/src/resources/extensions/gsd/commands-cmux.ts +10 -6
- package/src/resources/extensions/gsd/commands-extensions.ts +747 -41
- package/src/resources/extensions/gsd/commands-extract-learnings.ts +55 -90
- package/src/resources/extensions/gsd/commands-prefs-wizard.ts +898 -32
- package/src/resources/extensions/gsd/compaction-snapshot.ts +165 -0
- package/src/resources/extensions/gsd/complexity-classifier.ts +5 -3
- package/src/resources/extensions/gsd/db-writer.ts +88 -17
- package/src/resources/extensions/gsd/dispatch-guard.ts +26 -2
- package/src/resources/extensions/gsd/doctor-git-checks.ts +23 -27
- package/src/resources/extensions/gsd/doctor-providers.ts +59 -6
- package/src/resources/extensions/gsd/ecosystem/gsd-extension-api.ts +2 -0
- package/src/resources/extensions/gsd/error-classifier.ts +36 -3
- package/src/resources/extensions/gsd/exec-history.ts +153 -0
- package/src/resources/extensions/gsd/exec-sandbox.ts +326 -0
- package/src/resources/extensions/gsd/file-lock.ts +84 -11
- package/src/resources/extensions/gsd/git-service.ts +1 -0
- package/src/resources/extensions/gsd/gitignore.ts +2 -1
- package/src/resources/extensions/gsd/gsd-db.ts +186 -23
- package/src/resources/extensions/gsd/guided-flow-queue.ts +4 -1
- package/src/resources/extensions/gsd/guided-flow.ts +259 -10
- package/src/resources/extensions/gsd/health-widget.ts +3 -1
- package/src/resources/extensions/gsd/hook-emitter.ts +188 -0
- package/src/resources/extensions/gsd/init-wizard.ts +15 -1
- package/src/resources/extensions/gsd/journal.ts +29 -3
- package/src/resources/extensions/gsd/key-manager.ts +28 -0
- package/src/resources/extensions/gsd/memory-backfill.ts +140 -0
- package/src/resources/extensions/gsd/memory-store.ts +26 -0
- package/src/resources/extensions/gsd/milestone-actions.ts +18 -0
- package/src/resources/extensions/gsd/milestone-summary-classifier.ts +42 -0
- package/src/resources/extensions/gsd/model-router.ts +42 -1
- package/src/resources/extensions/gsd/notifications.ts +27 -15
- package/src/resources/extensions/gsd/pre-execution-checks.ts +46 -10
- package/src/resources/extensions/gsd/preferences-types.ts +46 -0
- package/src/resources/extensions/gsd/preferences-validation.ts +79 -0
- package/src/resources/extensions/gsd/preferences.ts +17 -17
- package/src/resources/extensions/gsd/prompt-loader.ts +30 -7
- package/src/resources/extensions/gsd/prompts/complete-milestone.md +1 -1
- package/src/resources/extensions/gsd/prompts/complete-slice.md +2 -2
- package/src/resources/extensions/gsd/prompts/debug-diagnose.md +2 -0
- package/src/resources/extensions/gsd/prompts/discuss-headless.md +29 -2
- package/src/resources/extensions/gsd/prompts/discuss.md +29 -2
- package/src/resources/extensions/gsd/prompts/doctor-heal.md +5 -4
- package/src/resources/extensions/gsd/prompts/execute-task.md +3 -2
- package/src/resources/extensions/gsd/prompts/parallel-research-slices.md +5 -2
- package/src/resources/extensions/gsd/prompts/plan-slice.md +1 -0
- package/src/resources/extensions/gsd/prompts/research-slice.md +1 -0
- package/src/resources/extensions/gsd/prompts/system.md +1 -0
- package/src/resources/extensions/gsd/reports.ts +5 -4
- package/src/resources/extensions/gsd/safety/evidence-collector.ts +119 -0
- package/src/resources/extensions/gsd/safety/file-change-validator.ts +17 -4
- package/src/resources/extensions/gsd/safety/safety-harness.ts +9 -0
- package/src/resources/extensions/gsd/state-transition-matrix.ts +152 -0
- package/src/resources/extensions/gsd/state.ts +80 -34
- package/src/resources/extensions/gsd/tests/auto-loop.test.ts +238 -4
- package/src/resources/extensions/gsd/tests/auto-mode-guards.test.ts +79 -0
- package/src/resources/extensions/gsd/tests/auto-model-selection.test.ts +95 -1
- package/src/resources/extensions/gsd/tests/auto-paused-session-validation.test.ts +12 -0
- package/src/resources/extensions/gsd/tests/auto-recovery.test.ts +122 -0
- package/src/resources/extensions/gsd/tests/auto-start-bootstrap-await-3420.test.ts +141 -0
- package/src/resources/extensions/gsd/tests/auto-start-clean-runtime-db-gated.test.ts +63 -0
- package/src/resources/extensions/gsd/tests/auto-start-model-capture.test.ts +33 -3
- package/src/resources/extensions/gsd/tests/auto-thinking-restore.test.ts +38 -0
- package/src/resources/extensions/gsd/tests/auto-wrapup-inflight-guard.test.ts +23 -0
- package/src/resources/extensions/gsd/tests/blocked-models.test.ts +98 -0
- package/src/resources/extensions/gsd/tests/bundled-skill-triggers.test.ts +54 -0
- package/src/resources/extensions/gsd/tests/clean-root-preflight.test.ts +186 -0
- package/src/resources/extensions/gsd/tests/cmux.test.ts +5 -9
- package/src/resources/extensions/gsd/tests/commands-extract-learnings.test.ts +68 -66
- package/src/resources/extensions/gsd/tests/compaction-snapshot.test.ts +123 -0
- package/src/resources/extensions/gsd/tests/complete-milestone-false-merge.test.ts +15 -0
- package/src/resources/extensions/gsd/tests/complete-milestone.test.ts +61 -1
- package/src/resources/extensions/gsd/tests/complete-slice.test.ts +2 -2
- package/src/resources/extensions/gsd/tests/complete-task.test.ts +2 -2
- package/src/resources/extensions/gsd/tests/complexity-classifier.test.ts +3 -3
- package/src/resources/extensions/gsd/tests/custom-engine-loop-integration.test.ts +161 -0
- package/src/resources/extensions/gsd/tests/db-access-guardrails.test.ts +1 -0
- package/src/resources/extensions/gsd/tests/derive-state-db.test.ts +42 -0
- package/src/resources/extensions/gsd/tests/derive-state-helpers.test.ts +8 -4
- package/src/resources/extensions/gsd/tests/derive-state.test.ts +1 -2
- package/src/resources/extensions/gsd/tests/dispatch-complete-milestone-guard.test.ts +14 -9
- package/src/resources/extensions/gsd/tests/dispatch-guard-summary-db-mismatch.test.ts +77 -0
- package/src/resources/extensions/gsd/tests/dispatch-guard.test.ts +25 -0
- package/src/resources/extensions/gsd/tests/dispatch-missing-task-plans.test.ts +14 -0
- package/src/resources/extensions/gsd/tests/doctor-providers.test.ts +148 -3
- package/src/resources/extensions/gsd/tests/double-merge-guard.test.ts +1 -1
- package/src/resources/extensions/gsd/tests/ensure-db-open.test.ts +306 -1
- package/src/resources/extensions/gsd/tests/escalation.test.ts +1 -1
- package/src/resources/extensions/gsd/tests/exec-history.test.ts +237 -0
- package/src/resources/extensions/gsd/tests/exec-sandbox.test.ts +210 -0
- package/src/resources/extensions/gsd/tests/execution-entry-missing-context-4671.test.ts +173 -0
- package/src/resources/extensions/gsd/tests/file-change-validator.test.ts +58 -0
- package/src/resources/extensions/gsd/tests/file-lock.test.ts +86 -12
- package/src/resources/extensions/gsd/tests/flat-rate-routing-guard.test.ts +40 -9
- package/src/resources/extensions/gsd/tests/freeform-decisions.test.ts +62 -0
- package/src/resources/extensions/gsd/tests/google-search-stub.test.ts +131 -0
- package/src/resources/extensions/gsd/tests/gsd-db.test.ts +447 -1
- package/src/resources/extensions/gsd/tests/headless-milestone-parity.test.ts +117 -0
- package/src/resources/extensions/gsd/tests/init-wizard.test.ts +27 -0
- package/src/resources/extensions/gsd/tests/integration/auto-worktree-milestone-merge.test.ts +30 -0
- package/src/resources/extensions/gsd/tests/integration/doctor-git-symlink-cwd.test.ts +11 -0
- package/src/resources/extensions/gsd/tests/integration/doctor-git.test.ts +78 -0
- package/src/resources/extensions/gsd/tests/integration/git-service.test.ts +4 -2
- package/src/resources/extensions/gsd/tests/integration/gitignore-tracked-gsd.test.ts +1 -0
- package/src/resources/extensions/gsd/tests/integration/idle-recovery.test.ts +30 -0
- package/src/resources/extensions/gsd/tests/integration/worktree-e2e.test.ts +11 -0
- package/src/resources/extensions/gsd/tests/interactive-routing-bypass.test.ts +1 -1
- package/src/resources/extensions/gsd/tests/isolation-none-branch-guard.test.ts +1 -1
- package/src/resources/extensions/gsd/tests/issue-4540-regressions.test.ts +288 -0
- package/src/resources/extensions/gsd/tests/journal-integration.test.ts +101 -0
- package/src/resources/extensions/gsd/tests/key-manager.test.ts +9 -0
- package/src/resources/extensions/gsd/tests/load-memory-block.test.ts +36 -0
- package/src/resources/extensions/gsd/tests/mcp-client-security.test.ts +76 -0
- package/src/resources/extensions/gsd/tests/md-importer.test.ts +1 -1
- package/src/resources/extensions/gsd/tests/memory-pressure-stuck-state.test.ts +12 -0
- package/src/resources/extensions/gsd/tests/memory-store.test.ts +2 -2
- package/src/resources/extensions/gsd/tests/milestone-status-authoritative.test.ts +3 -3
- package/src/resources/extensions/gsd/tests/milestone-summary-classifier.test.ts +30 -0
- package/src/resources/extensions/gsd/tests/milestone-transition-state-rebuild.test.ts +4 -2
- package/src/resources/extensions/gsd/tests/parallel-commit-scope.test.ts +5 -0
- package/src/resources/extensions/gsd/tests/parallel-research-dispatch.test.ts +19 -0
- package/src/resources/extensions/gsd/tests/parallel-skill-prompt-integration.test.ts +150 -0
- package/src/resources/extensions/gsd/tests/plan-gate-failed-doctor-heal-hint.test.ts +37 -0
- package/src/resources/extensions/gsd/tests/pre-exec-backtick-strip.test.ts +14 -0
- package/src/resources/extensions/gsd/tests/pre-exec-gate-loop.test.ts +272 -0
- package/src/resources/extensions/gsd/tests/pre-execution-checks.test.ts +356 -0
- package/src/resources/extensions/gsd/tests/preferences.test.ts +110 -0
- package/src/resources/extensions/gsd/tests/prefs-wizard-coverage.test.ts +44 -0
- package/src/resources/extensions/gsd/tests/prompt-loader-extension-dir.test.ts +49 -0
- package/src/resources/extensions/gsd/tests/provider-errors.test.ts +142 -29
- package/src/resources/extensions/gsd/tests/queue-auto-guard.test.ts +181 -0
- package/src/resources/extensions/gsd/tests/quick-auto-guard.test.ts +13 -7
- package/src/resources/extensions/gsd/tests/ready-phrase-no-files-4573.test.ts +388 -0
- package/src/resources/extensions/gsd/tests/require-slice-discussion-dispatch.test.ts +170 -0
- package/src/resources/extensions/gsd/tests/restore-tools-after-discuss.test.ts +9 -3
- package/src/resources/extensions/gsd/tests/resume-dispatch-worktree.test.ts +230 -0
- package/src/resources/extensions/gsd/tests/rewrite-docs-abandon-detect.test.ts +195 -0
- package/src/resources/extensions/gsd/tests/safety-harness-false-positives.test.ts +205 -0
- package/src/resources/extensions/gsd/tests/save-gate-result-render.test.ts +95 -0
- package/src/resources/extensions/gsd/tests/schema-v21-sequence.test.ts +413 -0
- package/src/resources/extensions/gsd/tests/session-start-footer.test.ts +32 -40
- package/src/resources/extensions/gsd/tests/stale-dirlistcache-4648.test.ts +112 -0
- package/src/resources/extensions/gsd/tests/stash-queued-context-files.test.ts +56 -0
- package/src/resources/extensions/gsd/tests/state-machine-full-walkthrough.test.ts +24 -0
- package/src/resources/extensions/gsd/tests/state-transition-matrix.test.ts +44 -0
- package/src/resources/extensions/gsd/tests/stuck-detection-coverage.test.ts +2 -2
- package/src/resources/extensions/gsd/tests/token-counter.test.ts +105 -1
- package/src/resources/extensions/gsd/tests/tool-compatibility.test.ts +107 -0
- package/src/resources/extensions/gsd/tests/triage-resolution.test.ts +50 -2
- package/src/resources/extensions/gsd/tests/turn-epoch.test.ts +162 -0
- package/src/resources/extensions/gsd/tests/uok-contracts.test.ts +51 -0
- package/src/resources/extensions/gsd/tests/uok-execution-graph.test.ts +16 -0
- package/src/resources/extensions/gsd/tests/uok-loop-adapter-writer.test.ts +65 -0
- package/src/resources/extensions/gsd/tests/uok-parity-report.test.ts +42 -0
- package/src/resources/extensions/gsd/tests/uok-plan-v2-wiring.test.ts +42 -2
- package/src/resources/extensions/gsd/tests/uok-writer.test.ts +75 -0
- package/src/resources/extensions/gsd/tests/validate-extension-package.test.ts +168 -0
- package/src/resources/extensions/gsd/tests/validate-milestone.test.ts +147 -8
- package/src/resources/extensions/gsd/tests/workflow-mcp.test.ts +25 -2
- package/src/resources/extensions/gsd/tests/workflow-tool-executors.test.ts +65 -2
- package/src/resources/extensions/gsd/tests/worktree-db.test.ts +35 -0
- package/src/resources/extensions/gsd/tests/worktree-journal-events.test.ts +6 -1
- package/src/resources/extensions/gsd/tests/worktree-resolver.test.ts +78 -5
- package/src/resources/extensions/gsd/tests/write-gate.test.ts +64 -0
- package/src/resources/extensions/gsd/tests/zombie-gsd-state.test.ts +3 -1
- package/src/resources/extensions/gsd/token-counter.ts +22 -5
- package/src/resources/extensions/gsd/tools/complete-milestone.ts +15 -9
- package/src/resources/extensions/gsd/tools/complete-slice.ts +38 -0
- package/src/resources/extensions/gsd/tools/complete-task.ts +49 -0
- package/src/resources/extensions/gsd/tools/exec-search-tool.ts +81 -0
- package/src/resources/extensions/gsd/tools/exec-tool.ts +183 -0
- package/src/resources/extensions/gsd/tools/memory-tools.ts +31 -1
- package/src/resources/extensions/gsd/tools/resume-tool.ts +40 -0
- package/src/resources/extensions/gsd/uok/audit.ts +20 -2
- package/src/resources/extensions/gsd/uok/contracts.ts +65 -0
- package/src/resources/extensions/gsd/uok/dispatch-envelope.ts +56 -0
- package/src/resources/extensions/gsd/uok/execution-graph.ts +22 -0
- package/src/resources/extensions/gsd/uok/gitops.ts +6 -1
- package/src/resources/extensions/gsd/uok/loop-adapter.ts +45 -10
- package/src/resources/extensions/gsd/uok/parity-report.ts +84 -0
- package/src/resources/extensions/gsd/uok/plan-v2.ts +39 -8
- package/src/resources/extensions/gsd/uok/writer.ts +113 -0
- package/src/resources/extensions/gsd/workflow-logger.ts +25 -3
- package/src/resources/extensions/gsd/workflow-mcp.ts +3 -0
- package/src/resources/extensions/gsd/workflow-templates/spike.md +6 -0
- package/src/resources/extensions/gsd/worktree-manager.ts +1 -0
- package/src/resources/extensions/gsd/worktree-resolver.ts +54 -9
- package/src/resources/extensions/mcp-client/auth.ts +12 -1
- package/src/resources/extensions/mcp-client/index.ts +129 -10
- package/src/resources/extensions/search-the-web/command-search-provider.ts +5 -4
- package/src/resources/extensions/search-the-web/native-search.ts +48 -12
- package/src/resources/extensions/shared/cmux-events.ts +59 -0
- package/src/resources/extensions/shared/rtk-session-stats.ts +1 -2
- package/src/resources/skills/api-design/SKILL.md +190 -0
- package/src/resources/skills/create-mcp-server/SKILL.md +121 -0
- package/src/resources/skills/create-skill/SKILL.md +2 -2
- package/src/resources/skills/create-skill/references/gsd-skill-ecosystem.md +4 -4
- package/src/resources/skills/create-skill/workflows/audit-skill.md +4 -4
- package/src/resources/skills/create-skill/workflows/create-new-skill.md +5 -5
- package/src/resources/skills/decompose-into-slices/SKILL.md +139 -0
- package/src/resources/skills/dependency-upgrade/SKILL.md +158 -0
- package/src/resources/skills/design-an-interface/SKILL.md +102 -0
- package/src/resources/skills/forensics/SKILL.md +153 -0
- package/src/resources/skills/grill-me/SKILL.md +93 -0
- package/src/resources/skills/handoff/SKILL.md +121 -0
- package/src/resources/skills/observability/SKILL.md +174 -0
- package/src/resources/skills/security-review/SKILL.md +181 -0
- package/src/resources/skills/spike-wrap-up/SKILL.md +138 -0
- package/src/resources/skills/tdd/SKILL.md +112 -0
- package/src/resources/skills/verify-before-complete/SKILL.md +98 -0
- package/src/resources/skills/write-docs/SKILL.md +82 -0
- package/src/resources/skills/write-milestone-brief/SKILL.md +135 -0
- package/dist/web/standalone/.next/server/chunks/7461.js +0 -1
- package/dist/web/standalone/.next/static/chunks/2826.e59e8578e2e28639.js +0 -9
- package/dist/web/standalone/.next/static/chunks/app/page-151349214571e2b6.js +0 -1
- package/dist/web/standalone/.next/static/chunks/main-app-d3d4c336195465f9.js +0 -1
- package/dist/web/standalone/.next/static/chunks/next/dist/client/components/builtin/global-error-ab5a8926e07ec673.js +0 -1
- /package/dist/web/standalone/.next/static/{ssX7BLv3Dw9Fb4CtrCGeR → vidAVJkURvTJ0_V2-64ro}/_buildManifest.js +0 -0
- /package/dist/web/standalone/.next/static/{ssX7BLv3Dw9Fb4CtrCGeR → vidAVJkURvTJ0_V2-64ro}/_ssgManifest.js +0 -0
|
@@ -34,6 +34,144 @@ function tryParsePercentage(val) {
|
|
|
34
34
|
const n = Number(val);
|
|
35
35
|
return !isNaN(n) && n >= 0 && n <= 100 ? n : null;
|
|
36
36
|
}
|
|
37
|
+
// ─── Prompt helpers (reduce boilerplate across configure* functions) ─────────
|
|
38
|
+
/** Ask for a boolean; returns the chosen value, or undefined if user kept current/escaped. */
|
|
39
|
+
async function promptBoolean(ctx, label, current, defaultVal) {
|
|
40
|
+
const currentStr = typeof current === "boolean" ? String(current) : "";
|
|
41
|
+
const suffix = currentStr
|
|
42
|
+
? ` (current: ${currentStr})`
|
|
43
|
+
: defaultVal !== undefined ? ` (default: ${defaultVal})` : "";
|
|
44
|
+
const choice = await ctx.ui.select(`${label}${suffix}:`, ["true", "false", "(keep current)"]);
|
|
45
|
+
if (!choice || choice === "(keep current)")
|
|
46
|
+
return undefined;
|
|
47
|
+
return choice === "true";
|
|
48
|
+
}
|
|
49
|
+
/** Ask for an enum-style value; returns the chosen string, or undefined if kept. */
|
|
50
|
+
async function promptEnum(ctx, label, current, values, defaultVal) {
|
|
51
|
+
const currentStr = typeof current === "string" ? current : "";
|
|
52
|
+
const suffix = currentStr
|
|
53
|
+
? ` (current: ${currentStr})`
|
|
54
|
+
: defaultVal ? ` (default: ${defaultVal})` : "";
|
|
55
|
+
const options = [...values, "(keep current)"];
|
|
56
|
+
const choice = await ctx.ui.select(`${label}${suffix}:`, options);
|
|
57
|
+
if (!choice || typeof choice !== "string" || choice === "(keep current)")
|
|
58
|
+
return undefined;
|
|
59
|
+
return choice;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Ask for a non-negative integer.
|
|
63
|
+
* Returns parsed number on success; "clear" when the user explicitly cleared an existing value;
|
|
64
|
+
* undefined on escape, empty-with-no-existing-value, or invalid input (warning emitted in the invalid case).
|
|
65
|
+
*/
|
|
66
|
+
async function promptInteger(ctx, label, current, defaultVal) {
|
|
67
|
+
const hadValue = current !== undefined && current !== null;
|
|
68
|
+
const currentStr = hadValue ? String(current) : "";
|
|
69
|
+
const suffix = currentStr ? ` (current: ${currentStr})` : defaultVal ? ` (default: ${defaultVal})` : "";
|
|
70
|
+
const input = await ctx.ui.input(`${label}${suffix}:`, currentStr || (defaultVal ?? ""));
|
|
71
|
+
if (input === null || input === undefined)
|
|
72
|
+
return undefined;
|
|
73
|
+
const val = input.trim();
|
|
74
|
+
if (!val)
|
|
75
|
+
return hadValue ? "clear" : undefined;
|
|
76
|
+
const parsed = tryParseInteger(val);
|
|
77
|
+
if (parsed === null) {
|
|
78
|
+
ctx.ui.notify(`Invalid value "${val}" for ${label} — must be a whole number. Keeping previous value.`, "warning");
|
|
79
|
+
return undefined;
|
|
80
|
+
}
|
|
81
|
+
return parsed;
|
|
82
|
+
}
|
|
83
|
+
/** Ask for a finite number. See promptInteger for return semantics. */
|
|
84
|
+
async function promptNumber(ctx, label, current, defaultVal) {
|
|
85
|
+
const hadValue = current !== undefined && current !== null;
|
|
86
|
+
const currentStr = hadValue ? String(current) : "";
|
|
87
|
+
const suffix = currentStr ? ` (current: ${currentStr})` : defaultVal ? ` (default: ${defaultVal})` : "";
|
|
88
|
+
const input = await ctx.ui.input(`${label}${suffix}:`, currentStr || (defaultVal ?? ""));
|
|
89
|
+
if (input === null || input === undefined)
|
|
90
|
+
return undefined;
|
|
91
|
+
const val = input.trim();
|
|
92
|
+
if (!val)
|
|
93
|
+
return hadValue ? "clear" : undefined;
|
|
94
|
+
const parsed = tryParseNumber(val);
|
|
95
|
+
if (parsed === null) {
|
|
96
|
+
ctx.ui.notify(`Invalid value "${val}" for ${label} — must be a number. Keeping previous value.`, "warning");
|
|
97
|
+
return undefined;
|
|
98
|
+
}
|
|
99
|
+
return parsed;
|
|
100
|
+
}
|
|
101
|
+
/** Apply a promptInteger/promptNumber result to a prefs dict. */
|
|
102
|
+
function applyNumber(prefs, key, result) {
|
|
103
|
+
if (result === undefined)
|
|
104
|
+
return;
|
|
105
|
+
if (result === "clear")
|
|
106
|
+
delete prefs[key];
|
|
107
|
+
else
|
|
108
|
+
prefs[key] = result;
|
|
109
|
+
}
|
|
110
|
+
/** Ask for a free-form string; returns the trimmed value, empty string to clear, or undefined if escaped. */
|
|
111
|
+
async function promptString(ctx, label, current, defaultVal) {
|
|
112
|
+
const currentStr = typeof current === "string" ? current : "";
|
|
113
|
+
const suffix = currentStr ? ` (current: ${currentStr})` : defaultVal ? ` (default: ${defaultVal})` : "";
|
|
114
|
+
const input = await ctx.ui.input(`${label}${suffix}:`, currentStr || (defaultVal ?? ""));
|
|
115
|
+
if (input === null || input === undefined)
|
|
116
|
+
return undefined;
|
|
117
|
+
return input.trim();
|
|
118
|
+
}
|
|
119
|
+
/** Parse comma- or newline-separated input into a deduplicated string array. */
|
|
120
|
+
function parseStringList(input) {
|
|
121
|
+
return input
|
|
122
|
+
.split(/[,\n]/)
|
|
123
|
+
.map(s => s.trim())
|
|
124
|
+
.filter(s => s.length > 0);
|
|
125
|
+
}
|
|
126
|
+
/** Sub-menu to edit a string list field (add / remove / clear / done). Mutates the parent prefs object. */
|
|
127
|
+
async function editStringListField(ctx, prefs, key, label) {
|
|
128
|
+
const current = Array.isArray(prefs[key]) ? [...prefs[key]] : [];
|
|
129
|
+
let list = current;
|
|
130
|
+
while (true) {
|
|
131
|
+
const summary = list.length === 0 ? "(empty)" : `${list.length} item(s): ${list.slice(0, 3).join(", ")}${list.length > 3 ? "…" : ""}`;
|
|
132
|
+
const choice = await ctx.ui.select(`${label} — ${summary}`, ["Add entries", "Remove entry", "Clear all", "Done"]);
|
|
133
|
+
const pick = typeof choice === "string" ? choice : "";
|
|
134
|
+
if (!pick || pick === "Done")
|
|
135
|
+
break;
|
|
136
|
+
if (pick === "Add entries") {
|
|
137
|
+
const input = await ctx.ui.input(`Add to ${label} (comma- or newline-separated):`, "");
|
|
138
|
+
if (input) {
|
|
139
|
+
for (const item of parseStringList(input)) {
|
|
140
|
+
if (!list.includes(item))
|
|
141
|
+
list.push(item);
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
else if (pick === "Remove entry") {
|
|
146
|
+
if (list.length === 0)
|
|
147
|
+
continue;
|
|
148
|
+
const removeChoice = await ctx.ui.select(`Remove which entry?`, [...list, "(cancel)"]);
|
|
149
|
+
const removeStr = typeof removeChoice === "string" ? removeChoice : "";
|
|
150
|
+
if (removeStr && removeStr !== "(cancel)") {
|
|
151
|
+
list = list.filter(x => x !== removeStr);
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
else if (pick === "Clear all") {
|
|
155
|
+
list = [];
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
if (list.length > 0) {
|
|
159
|
+
prefs[key] = list;
|
|
160
|
+
}
|
|
161
|
+
else if (prefs[key] !== undefined) {
|
|
162
|
+
delete prefs[key];
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
/** Set a nested object key, creating the parent object if needed, and deleting on undefined/empty. */
|
|
166
|
+
function setNested(parent, parentKey, childKey, value) {
|
|
167
|
+
let child = parent[parentKey];
|
|
168
|
+
if (!child || typeof child !== "object")
|
|
169
|
+
child = {};
|
|
170
|
+
if (value === undefined)
|
|
171
|
+
return;
|
|
172
|
+
child[childKey] = value;
|
|
173
|
+
parent[parentKey] = child;
|
|
174
|
+
}
|
|
37
175
|
export async function handlePrefs(args, ctx) {
|
|
38
176
|
const trimmed = args.trim();
|
|
39
177
|
if (trimmed === "" || trimmed === "global" || trimmed === "wizard" || trimmed === "setup"
|
|
@@ -135,10 +273,26 @@ export function buildCategorySummaries(prefs) {
|
|
|
135
273
|
const modeSummary = mode ?? "(not set)";
|
|
136
274
|
// Models
|
|
137
275
|
const models = prefs.models;
|
|
276
|
+
const tokenProfile = prefs.token_profile;
|
|
277
|
+
const serviceTier = prefs.service_tier;
|
|
278
|
+
const flatRate = Array.isArray(prefs.flat_rate_providers) ? prefs.flat_rate_providers.length : 0;
|
|
279
|
+
const dynRouting = prefs.dynamic_routing;
|
|
138
280
|
let modelsSummary = "(not configured)";
|
|
139
|
-
|
|
140
|
-
const parts =
|
|
141
|
-
|
|
281
|
+
{
|
|
282
|
+
const parts = [];
|
|
283
|
+
if (models && Object.keys(models).length > 0) {
|
|
284
|
+
parts.push(`${Object.keys(models).length} phase(s)`);
|
|
285
|
+
}
|
|
286
|
+
if (tokenProfile)
|
|
287
|
+
parts.push(`profile: ${tokenProfile}`);
|
|
288
|
+
if (serviceTier)
|
|
289
|
+
parts.push(`tier: ${serviceTier}`);
|
|
290
|
+
if (flatRate)
|
|
291
|
+
parts.push(`flat-rate: ${flatRate}`);
|
|
292
|
+
if (dynRouting?.enabled)
|
|
293
|
+
parts.push("routing: on");
|
|
294
|
+
if (parts.length > 0)
|
|
295
|
+
modelsSummary = parts.join(", ");
|
|
142
296
|
}
|
|
143
297
|
// Timeouts
|
|
144
298
|
const autoSup = prefs.auto_supervisor;
|
|
@@ -173,14 +327,32 @@ export function buildCategorySummaries(prefs) {
|
|
|
173
327
|
// Skills
|
|
174
328
|
const discovery = prefs.skill_discovery;
|
|
175
329
|
const uat = prefs.uat_dispatch;
|
|
330
|
+
const alwaysUse = Array.isArray(prefs.always_use_skills) ? prefs.always_use_skills.length : 0;
|
|
331
|
+
const preferS = Array.isArray(prefs.prefer_skills) ? prefs.prefer_skills.length : 0;
|
|
332
|
+
const avoidS = Array.isArray(prefs.avoid_skills) ? prefs.avoid_skills.length : 0;
|
|
333
|
+
const rulesCount = Array.isArray(prefs.skill_rules) ? prefs.skill_rules.length : 0;
|
|
334
|
+
const customInstr = Array.isArray(prefs.custom_instructions) ? prefs.custom_instructions.length : 0;
|
|
176
335
|
let skillsSummary = "(not configured)";
|
|
177
|
-
|
|
336
|
+
{
|
|
178
337
|
const parts = [];
|
|
179
338
|
if (discovery)
|
|
180
339
|
parts.push(`discovery: ${discovery}`);
|
|
181
340
|
if (uat !== undefined)
|
|
182
341
|
parts.push(`uat: ${uat}`);
|
|
183
|
-
|
|
342
|
+
if (alwaysUse)
|
|
343
|
+
parts.push(`always: ${alwaysUse}`);
|
|
344
|
+
if (preferS)
|
|
345
|
+
parts.push(`prefer: ${preferS}`);
|
|
346
|
+
if (avoidS)
|
|
347
|
+
parts.push(`avoid: ${avoidS}`);
|
|
348
|
+
if (rulesCount)
|
|
349
|
+
parts.push(`rules: ${rulesCount}`);
|
|
350
|
+
if (customInstr)
|
|
351
|
+
parts.push(`custom: ${customInstr}`);
|
|
352
|
+
if (prefs.skill_staleness_days !== undefined)
|
|
353
|
+
parts.push(`stale: ${prefs.skill_staleness_days}d`);
|
|
354
|
+
if (parts.length > 0)
|
|
355
|
+
skillsSummary = parts.join(", ");
|
|
184
356
|
}
|
|
185
357
|
// Budget
|
|
186
358
|
const ceiling = prefs.budget_ceiling;
|
|
@@ -204,9 +376,145 @@ export function buildCategorySummaries(prefs) {
|
|
|
204
376
|
}
|
|
205
377
|
// Advanced
|
|
206
378
|
const uniqueIds = prefs.unique_milestone_ids;
|
|
379
|
+
const experimentalRtk = prefs.experimental?.rtk;
|
|
207
380
|
let advancedSummary = "(defaults)";
|
|
208
|
-
|
|
209
|
-
|
|
381
|
+
{
|
|
382
|
+
const parts = [];
|
|
383
|
+
if (uniqueIds !== undefined)
|
|
384
|
+
parts.push(`unique: ${uniqueIds ? "on" : "off"}`);
|
|
385
|
+
if (prefs.auto_visualize !== undefined)
|
|
386
|
+
parts.push(`viz: ${prefs.auto_visualize ? "on" : "off"}`);
|
|
387
|
+
if (prefs.auto_report !== undefined)
|
|
388
|
+
parts.push(`report: ${prefs.auto_report ? "on" : "off"}`);
|
|
389
|
+
if (prefs.show_token_cost)
|
|
390
|
+
parts.push("cost-display");
|
|
391
|
+
if (prefs.forensics_dedup)
|
|
392
|
+
parts.push("forensics-dedup");
|
|
393
|
+
if (prefs.widget_mode)
|
|
394
|
+
parts.push(`widget: ${prefs.widget_mode}`);
|
|
395
|
+
if (experimentalRtk)
|
|
396
|
+
parts.push("rtk");
|
|
397
|
+
if (parts.length > 0)
|
|
398
|
+
advancedSummary = parts.join(", ");
|
|
399
|
+
}
|
|
400
|
+
// Phases
|
|
401
|
+
const phases = prefs.phases;
|
|
402
|
+
let phasesSummary = "(defaults)";
|
|
403
|
+
if (phases && Object.keys(phases).length > 0) {
|
|
404
|
+
const activeFlags = Object.entries(phases).filter(([, v]) => v === true).map(([k]) => k);
|
|
405
|
+
phasesSummary = activeFlags.length === 0 ? "(no flags)" : `${activeFlags.length} flag(s): ${activeFlags.slice(0, 2).join(", ")}${activeFlags.length > 2 ? "…" : ""}`;
|
|
406
|
+
}
|
|
407
|
+
// Parallelism
|
|
408
|
+
const parallel = prefs.parallel;
|
|
409
|
+
const sliceParallel = prefs.slice_parallel;
|
|
410
|
+
let parallelismSummary = "(defaults)";
|
|
411
|
+
{
|
|
412
|
+
const parts = [];
|
|
413
|
+
if (parallel?.enabled)
|
|
414
|
+
parts.push(`milestone: ${parallel.max_workers ?? 2}w`);
|
|
415
|
+
if (sliceParallel?.enabled)
|
|
416
|
+
parts.push(`slice: ${sliceParallel.max_workers ?? 2}w`);
|
|
417
|
+
if (parts.length > 0)
|
|
418
|
+
parallelismSummary = parts.join(", ");
|
|
419
|
+
}
|
|
420
|
+
// Verification
|
|
421
|
+
const verifyCmds = Array.isArray(prefs.verification_commands) ? prefs.verification_commands.length : 0;
|
|
422
|
+
const safety = prefs.safety_harness;
|
|
423
|
+
let verificationSummary = "(defaults)";
|
|
424
|
+
{
|
|
425
|
+
const parts = [];
|
|
426
|
+
if (verifyCmds)
|
|
427
|
+
parts.push(`${verifyCmds} cmd(s)`);
|
|
428
|
+
if (prefs.verification_auto_fix)
|
|
429
|
+
parts.push("auto-fix");
|
|
430
|
+
if (prefs.enhanced_verification === false)
|
|
431
|
+
parts.push("enhanced: off");
|
|
432
|
+
if (prefs.enhanced_verification_strict)
|
|
433
|
+
parts.push("strict");
|
|
434
|
+
if (safety?.enabled === false)
|
|
435
|
+
parts.push("harness: off");
|
|
436
|
+
else if (safety && Object.keys(safety).length > 0)
|
|
437
|
+
parts.push("harness: custom");
|
|
438
|
+
if (parts.length > 0)
|
|
439
|
+
verificationSummary = parts.join(", ");
|
|
440
|
+
}
|
|
441
|
+
// Discuss
|
|
442
|
+
let discussSummary = "(defaults)";
|
|
443
|
+
{
|
|
444
|
+
const parts = [];
|
|
445
|
+
if (prefs.discuss_preparation === false)
|
|
446
|
+
parts.push("prep: off");
|
|
447
|
+
if (prefs.discuss_web_research === false)
|
|
448
|
+
parts.push("web: off");
|
|
449
|
+
if (prefs.discuss_depth)
|
|
450
|
+
parts.push(`depth: ${prefs.discuss_depth}`);
|
|
451
|
+
if (parts.length > 0)
|
|
452
|
+
discussSummary = parts.join(", ");
|
|
453
|
+
}
|
|
454
|
+
// Context & Codebase
|
|
455
|
+
const ctxMgmt = prefs.context_management;
|
|
456
|
+
const codebase = prefs.codebase;
|
|
457
|
+
let contextSummary = "(defaults)";
|
|
458
|
+
{
|
|
459
|
+
const parts = [];
|
|
460
|
+
if (prefs.context_selection)
|
|
461
|
+
parts.push(`selection: ${prefs.context_selection}`);
|
|
462
|
+
if (ctxMgmt && Object.keys(ctxMgmt).length > 0)
|
|
463
|
+
parts.push(`mgmt: ${Object.keys(ctxMgmt).length} field(s)`);
|
|
464
|
+
if (prefs.context_window_override !== undefined)
|
|
465
|
+
parts.push(`override: ${prefs.context_window_override}`);
|
|
466
|
+
if (codebase && Object.keys(codebase).length > 0)
|
|
467
|
+
parts.push("codebase: custom");
|
|
468
|
+
if (parts.length > 0)
|
|
469
|
+
contextSummary = parts.join(", ");
|
|
470
|
+
}
|
|
471
|
+
// Hooks & Reactive
|
|
472
|
+
const reactive = prefs.reactive_execution;
|
|
473
|
+
const gateEval = prefs.gate_evaluation;
|
|
474
|
+
const postHooks = Array.isArray(prefs.post_unit_hooks) ? prefs.post_unit_hooks.length : 0;
|
|
475
|
+
const preHooks = Array.isArray(prefs.pre_dispatch_hooks) ? prefs.pre_dispatch_hooks.length : 0;
|
|
476
|
+
let hooksSummary = "(defaults)";
|
|
477
|
+
{
|
|
478
|
+
const parts = [];
|
|
479
|
+
if (postHooks)
|
|
480
|
+
parts.push(`post: ${postHooks}`);
|
|
481
|
+
if (preHooks)
|
|
482
|
+
parts.push(`pre: ${preHooks}`);
|
|
483
|
+
if (reactive?.enabled)
|
|
484
|
+
parts.push("reactive: on");
|
|
485
|
+
if (gateEval?.enabled)
|
|
486
|
+
parts.push("gate-eval: on");
|
|
487
|
+
if (parts.length > 0)
|
|
488
|
+
hooksSummary = parts.join(", ");
|
|
489
|
+
}
|
|
490
|
+
// UoK
|
|
491
|
+
const uok = prefs.uok;
|
|
492
|
+
let uokSummary = "(defaults)";
|
|
493
|
+
if (uok && Object.keys(uok).length > 0) {
|
|
494
|
+
if (uok.enabled === false)
|
|
495
|
+
uokSummary = "off";
|
|
496
|
+
else
|
|
497
|
+
uokSummary = `${Object.keys(uok).length} setting(s)`;
|
|
498
|
+
}
|
|
499
|
+
// Integrations
|
|
500
|
+
const cmux = prefs.cmux;
|
|
501
|
+
const remote = prefs.remote_questions;
|
|
502
|
+
const github = prefs.github;
|
|
503
|
+
let integrationsSummary = "(defaults)";
|
|
504
|
+
{
|
|
505
|
+
const parts = [];
|
|
506
|
+
if (prefs.language)
|
|
507
|
+
parts.push(`lang: ${prefs.language}`);
|
|
508
|
+
if (prefs.search_provider)
|
|
509
|
+
parts.push(`search: ${prefs.search_provider}`);
|
|
510
|
+
if (cmux?.enabled)
|
|
511
|
+
parts.push("cmux");
|
|
512
|
+
if (remote?.channel)
|
|
513
|
+
parts.push(`remote: ${remote.channel}`);
|
|
514
|
+
if (github?.enabled)
|
|
515
|
+
parts.push("github");
|
|
516
|
+
if (parts.length > 0)
|
|
517
|
+
integrationsSummary = parts.join(", ");
|
|
210
518
|
}
|
|
211
519
|
return {
|
|
212
520
|
mode: modeSummary,
|
|
@@ -217,6 +525,14 @@ export function buildCategorySummaries(prefs) {
|
|
|
217
525
|
budget: budgetSummary,
|
|
218
526
|
notifications: notifSummary,
|
|
219
527
|
advanced: advancedSummary,
|
|
528
|
+
phases: phasesSummary,
|
|
529
|
+
parallelism: parallelismSummary,
|
|
530
|
+
verification: verificationSummary,
|
|
531
|
+
discuss: discussSummary,
|
|
532
|
+
context: contextSummary,
|
|
533
|
+
hooks: hooksSummary,
|
|
534
|
+
uok: uokSummary,
|
|
535
|
+
integrations: integrationsSummary,
|
|
220
536
|
};
|
|
221
537
|
}
|
|
222
538
|
// ─── Category configuration functions ────────────────────────────────────────
|
|
@@ -342,6 +658,62 @@ async function configureModels(ctx, prefs) {
|
|
|
342
658
|
else {
|
|
343
659
|
delete prefs.models;
|
|
344
660
|
}
|
|
661
|
+
// ─── Extra routing-level model preferences ────────────────────────────────
|
|
662
|
+
const tokenProfile = await promptEnum(ctx, "Token profile (cost/quality tradeoff)", prefs.token_profile, ["budget", "balanced", "quality", "burn-max"]);
|
|
663
|
+
if (tokenProfile !== undefined)
|
|
664
|
+
prefs.token_profile = tokenProfile;
|
|
665
|
+
const serviceTier = await promptEnum(ctx, "OpenAI service tier (gpt-5.4 only)", prefs.service_tier, ["priority", "flex"]);
|
|
666
|
+
if (serviceTier !== undefined)
|
|
667
|
+
prefs.service_tier = serviceTier;
|
|
668
|
+
await editStringListField(ctx, prefs, "flat_rate_providers", "Flat-rate providers (suppress dynamic routing)");
|
|
669
|
+
await configureDynamicRouting(ctx, prefs);
|
|
670
|
+
}
|
|
671
|
+
async function configureDynamicRouting(ctx, prefs) {
|
|
672
|
+
const dr = prefs.dynamic_routing ?? {};
|
|
673
|
+
const enabled = await promptBoolean(ctx, "Enable dynamic routing (tier-based model selection)", dr.enabled);
|
|
674
|
+
if (enabled !== undefined)
|
|
675
|
+
dr.enabled = enabled;
|
|
676
|
+
if (dr.enabled !== true) {
|
|
677
|
+
// If routing is disabled / kept-off, still let the user configure sub-fields (they may enable later).
|
|
678
|
+
}
|
|
679
|
+
const cap = await promptBoolean(ctx, "Capability-aware routing", dr.capability_routing, false);
|
|
680
|
+
if (cap !== undefined)
|
|
681
|
+
dr.capability_routing = cap;
|
|
682
|
+
const escalate = await promptBoolean(ctx, "Escalate to heavier tier on failure", dr.escalate_on_failure, true);
|
|
683
|
+
if (escalate !== undefined)
|
|
684
|
+
dr.escalate_on_failure = escalate;
|
|
685
|
+
const pressure = await promptBoolean(ctx, "Downgrade under budget pressure", dr.budget_pressure, true);
|
|
686
|
+
if (pressure !== undefined)
|
|
687
|
+
dr.budget_pressure = pressure;
|
|
688
|
+
const cross = await promptBoolean(ctx, "Cross-provider routing", dr.cross_provider, true);
|
|
689
|
+
if (cross !== undefined)
|
|
690
|
+
dr.cross_provider = cross;
|
|
691
|
+
const hooks = await promptBoolean(ctx, "Route hook sessions dynamically", dr.hooks, true);
|
|
692
|
+
if (hooks !== undefined)
|
|
693
|
+
dr.hooks = hooks;
|
|
694
|
+
const flatRate = await promptBoolean(ctx, "Allow dynamic routing for flat-rate providers", dr.allow_flat_rate_providers, false);
|
|
695
|
+
if (flatRate !== undefined)
|
|
696
|
+
dr.allow_flat_rate_providers = flatRate;
|
|
697
|
+
// tier_models.light / standard / heavy — optional model IDs
|
|
698
|
+
const tierModels = dr.tier_models ?? {};
|
|
699
|
+
for (const tier of ["light", "standard", "heavy"]) {
|
|
700
|
+
const current = typeof tierModels[tier] === "string" ? tierModels[tier] : "";
|
|
701
|
+
const input = await promptString(ctx, `Model for ${tier} tier (e.g. claude-haiku-4-5)`, current);
|
|
702
|
+
if (input === undefined)
|
|
703
|
+
continue;
|
|
704
|
+
if (input)
|
|
705
|
+
tierModels[tier] = input;
|
|
706
|
+
else if (current)
|
|
707
|
+
delete tierModels[tier];
|
|
708
|
+
}
|
|
709
|
+
if (Object.keys(tierModels).length > 0)
|
|
710
|
+
dr.tier_models = tierModels;
|
|
711
|
+
else
|
|
712
|
+
delete dr.tier_models;
|
|
713
|
+
if (Object.keys(dr).length > 0)
|
|
714
|
+
prefs.dynamic_routing = dr;
|
|
715
|
+
else if (prefs.dynamic_routing !== undefined)
|
|
716
|
+
delete prefs.dynamic_routing;
|
|
345
717
|
}
|
|
346
718
|
async function configureTimeouts(ctx, prefs) {
|
|
347
719
|
const autoSup = prefs.auto_supervisor ?? {};
|
|
@@ -477,17 +849,90 @@ async function configureGit(ctx, prefs) {
|
|
|
477
849
|
}
|
|
478
850
|
async function configureSkills(ctx, prefs) {
|
|
479
851
|
// Skill discovery mode
|
|
480
|
-
const
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
prefs.skill_discovery = discoveryChoice;
|
|
484
|
-
}
|
|
852
|
+
const discovery = await promptEnum(ctx, "Skill discovery mode", prefs.skill_discovery, ["auto", "suggest", "off"]);
|
|
853
|
+
if (discovery !== undefined)
|
|
854
|
+
prefs.skill_discovery = discovery;
|
|
485
855
|
// UAT dispatch
|
|
486
|
-
const
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
856
|
+
const uat = await promptBoolean(ctx, "UAT dispatch mode", prefs.uat_dispatch, false);
|
|
857
|
+
if (uat !== undefined)
|
|
858
|
+
prefs.uat_dispatch = uat;
|
|
859
|
+
// Skill lists — edit via sub-menus
|
|
860
|
+
await editStringListField(ctx, prefs, "always_use_skills", "Always-use skills");
|
|
861
|
+
await editStringListField(ctx, prefs, "prefer_skills", "Preferred skills");
|
|
862
|
+
await editStringListField(ctx, prefs, "avoid_skills", "Avoided skills");
|
|
863
|
+
await editStringListField(ctx, prefs, "custom_instructions", "Custom instructions");
|
|
864
|
+
// Skill rules (array of {when, use?, prefer?, avoid?})
|
|
865
|
+
await configureSkillRules(ctx, prefs);
|
|
866
|
+
// Skill staleness days
|
|
867
|
+
const staleness = await promptInteger(ctx, "Skill staleness days (0 to disable)", prefs.skill_staleness_days, "60");
|
|
868
|
+
applyNumber(prefs, "skill_staleness_days", staleness);
|
|
869
|
+
}
|
|
870
|
+
async function configureSkillRules(ctx, prefs) {
|
|
871
|
+
let rules = Array.isArray(prefs.skill_rules) ? [...prefs.skill_rules] : [];
|
|
872
|
+
while (true) {
|
|
873
|
+
const summary = rules.length === 0
|
|
874
|
+
? "(no rules)"
|
|
875
|
+
: `${rules.length} rule(s)`;
|
|
876
|
+
const listLabels = rules.map((r, i) => `#${i + 1} when: ${r.when}`);
|
|
877
|
+
const options = [...listLabels, "Add rule", "Done"];
|
|
878
|
+
const choice = await ctx.ui.select(`Skill rules — ${summary}`, options);
|
|
879
|
+
const pick = typeof choice === "string" ? choice : "";
|
|
880
|
+
if (!pick || pick === "Done")
|
|
881
|
+
break;
|
|
882
|
+
if (pick === "Add rule") {
|
|
883
|
+
const whenInput = await ctx.ui.input("Rule condition (free text, e.g. 'frontend tasks'):", "");
|
|
884
|
+
const when = typeof whenInput === "string" ? whenInput.trim() : "";
|
|
885
|
+
if (!when)
|
|
886
|
+
continue;
|
|
887
|
+
const rule = { when };
|
|
888
|
+
for (const field of ["use", "prefer", "avoid"]) {
|
|
889
|
+
const listInput = await ctx.ui.input(`Skills to ${field} (comma- or newline-separated, blank to skip):`, "");
|
|
890
|
+
if (listInput) {
|
|
891
|
+
const parsed = parseStringList(listInput);
|
|
892
|
+
if (parsed.length > 0)
|
|
893
|
+
rule[field] = parsed;
|
|
894
|
+
}
|
|
895
|
+
}
|
|
896
|
+
if (rule.use || rule.prefer || rule.avoid)
|
|
897
|
+
rules.push(rule);
|
|
898
|
+
else
|
|
899
|
+
ctx.ui.notify("Rule discarded — must have at least one of use/prefer/avoid.", "warning");
|
|
900
|
+
}
|
|
901
|
+
else if (pick.startsWith("#")) {
|
|
902
|
+
const idx = Number(pick.slice(1, pick.indexOf(" "))) - 1;
|
|
903
|
+
if (idx < 0 || idx >= rules.length)
|
|
904
|
+
continue;
|
|
905
|
+
const editChoice = await ctx.ui.select(`Rule #${idx + 1}`, ["Edit condition", "Edit use list", "Edit prefer list", "Edit avoid list", "Delete rule", "Cancel"]);
|
|
906
|
+
const ec = typeof editChoice === "string" ? editChoice : "";
|
|
907
|
+
if (!ec || ec === "Cancel")
|
|
908
|
+
continue;
|
|
909
|
+
if (ec === "Delete rule") {
|
|
910
|
+
rules = rules.filter((_, i) => i !== idx);
|
|
911
|
+
continue;
|
|
912
|
+
}
|
|
913
|
+
if (ec === "Edit condition") {
|
|
914
|
+
const newWhen = await promptString(ctx, "Rule condition", rules[idx].when);
|
|
915
|
+
if (newWhen !== undefined && newWhen !== "")
|
|
916
|
+
rules[idx].when = newWhen;
|
|
917
|
+
}
|
|
918
|
+
else {
|
|
919
|
+
const fieldKey = ec === "Edit use list" ? "use" : ec === "Edit prefer list" ? "prefer" : "avoid";
|
|
920
|
+
const currentList = rules[idx][fieldKey] ?? [];
|
|
921
|
+
const listInput = await ctx.ui.input(`${fieldKey} list (comma- or newline-separated, blank to clear):`, currentList.join(", "));
|
|
922
|
+
if (listInput === null || listInput === undefined)
|
|
923
|
+
continue;
|
|
924
|
+
const parsed = parseStringList(listInput);
|
|
925
|
+
if (parsed.length > 0)
|
|
926
|
+
rules[idx][fieldKey] = parsed;
|
|
927
|
+
else
|
|
928
|
+
delete rules[idx][fieldKey];
|
|
929
|
+
}
|
|
930
|
+
}
|
|
490
931
|
}
|
|
932
|
+
if (rules.length > 0)
|
|
933
|
+
prefs.skill_rules = rules;
|
|
934
|
+
else if (prefs.skill_rules !== undefined)
|
|
935
|
+
delete prefs.skill_rules;
|
|
491
936
|
}
|
|
492
937
|
async function configureBudget(ctx, prefs) {
|
|
493
938
|
const currentCeiling = prefs.budget_ceiling;
|
|
@@ -552,6 +997,451 @@ async function configureNotifications(ctx, prefs) {
|
|
|
552
997
|
prefs.notifications = notif;
|
|
553
998
|
}
|
|
554
999
|
}
|
|
1000
|
+
async function configurePhases(ctx, prefs) {
|
|
1001
|
+
const phases = prefs.phases ?? {};
|
|
1002
|
+
const fields = [
|
|
1003
|
+
{ key: "skip_research", label: "Skip research phase" },
|
|
1004
|
+
{ key: "skip_reassess", label: "Skip roadmap reassessment" },
|
|
1005
|
+
{ key: "skip_slice_research", label: "Skip slice-level research" },
|
|
1006
|
+
{ key: "skip_milestone_validation", label: "Skip milestone validation" },
|
|
1007
|
+
{ key: "reassess_after_slice", label: "Reassess roadmap after each slice" },
|
|
1008
|
+
{ key: "require_slice_discussion", label: "Pause for discussion before each slice" },
|
|
1009
|
+
{ key: "mid_execution_escalation", label: "Allow mid-execution escalation (ADR-011 P2)" },
|
|
1010
|
+
{ key: "progressive_planning", label: "Progressive planning (S01 full, S02+ sketches)" },
|
|
1011
|
+
];
|
|
1012
|
+
for (const field of fields) {
|
|
1013
|
+
const val = await promptBoolean(ctx, field.label, phases[field.key]);
|
|
1014
|
+
if (val !== undefined)
|
|
1015
|
+
phases[field.key] = val;
|
|
1016
|
+
}
|
|
1017
|
+
if (Object.keys(phases).length > 0)
|
|
1018
|
+
prefs.phases = phases;
|
|
1019
|
+
else if (prefs.phases !== undefined)
|
|
1020
|
+
delete prefs.phases;
|
|
1021
|
+
}
|
|
1022
|
+
async function configureParallelism(ctx, prefs) {
|
|
1023
|
+
// parallel: milestone-level
|
|
1024
|
+
const parallel = prefs.parallel ?? {};
|
|
1025
|
+
const pEnabled = await promptBoolean(ctx, "Parallel milestone execution", parallel.enabled, false);
|
|
1026
|
+
if (pEnabled !== undefined)
|
|
1027
|
+
parallel.enabled = pEnabled;
|
|
1028
|
+
const pWorkers = await promptInteger(ctx, "Max parallel workers (1–4)", parallel.max_workers, "2");
|
|
1029
|
+
if (pWorkers !== undefined && pWorkers !== "clear")
|
|
1030
|
+
parallel.max_workers = Math.max(1, Math.min(4, pWorkers));
|
|
1031
|
+
else if (pWorkers === "clear")
|
|
1032
|
+
delete parallel.max_workers;
|
|
1033
|
+
const pBudget = await promptNumber(ctx, "Per-worker budget ceiling (USD, blank = no limit)", parallel.budget_ceiling);
|
|
1034
|
+
if (pBudget !== undefined && pBudget !== "clear")
|
|
1035
|
+
parallel.budget_ceiling = pBudget;
|
|
1036
|
+
else if (pBudget === "clear")
|
|
1037
|
+
delete parallel.budget_ceiling;
|
|
1038
|
+
const pMerge = await promptEnum(ctx, "Parallel merge strategy", parallel.merge_strategy, ["per-slice", "per-milestone"]);
|
|
1039
|
+
if (pMerge !== undefined)
|
|
1040
|
+
parallel.merge_strategy = pMerge;
|
|
1041
|
+
const pAuto = await promptEnum(ctx, "Auto-merge mode", parallel.auto_merge, ["auto", "confirm", "manual"]);
|
|
1042
|
+
if (pAuto !== undefined)
|
|
1043
|
+
parallel.auto_merge = pAuto;
|
|
1044
|
+
const pWorkerModel = await promptString(ctx, "Worker model override (e.g. claude-haiku-4-5)", parallel.worker_model);
|
|
1045
|
+
if (pWorkerModel !== undefined) {
|
|
1046
|
+
if (pWorkerModel)
|
|
1047
|
+
parallel.worker_model = pWorkerModel;
|
|
1048
|
+
else
|
|
1049
|
+
delete parallel.worker_model;
|
|
1050
|
+
}
|
|
1051
|
+
if (Object.keys(parallel).length > 0)
|
|
1052
|
+
prefs.parallel = parallel;
|
|
1053
|
+
else if (prefs.parallel !== undefined)
|
|
1054
|
+
delete prefs.parallel;
|
|
1055
|
+
// slice_parallel: slice-level
|
|
1056
|
+
const sp = prefs.slice_parallel ?? {};
|
|
1057
|
+
const spEnabled = await promptBoolean(ctx, "Slice-level parallel execution", sp.enabled, false);
|
|
1058
|
+
if (spEnabled !== undefined)
|
|
1059
|
+
sp.enabled = spEnabled;
|
|
1060
|
+
const spWorkers = await promptInteger(ctx, "Slice max workers", sp.max_workers, "2");
|
|
1061
|
+
if (spWorkers !== undefined && spWorkers !== "clear")
|
|
1062
|
+
sp.max_workers = spWorkers;
|
|
1063
|
+
else if (spWorkers === "clear")
|
|
1064
|
+
delete sp.max_workers;
|
|
1065
|
+
if (Object.keys(sp).length > 0)
|
|
1066
|
+
prefs.slice_parallel = sp;
|
|
1067
|
+
else if (prefs.slice_parallel !== undefined)
|
|
1068
|
+
delete prefs.slice_parallel;
|
|
1069
|
+
}
|
|
1070
|
+
async function configureVerification(ctx, prefs) {
|
|
1071
|
+
await editStringListField(ctx, prefs, "verification_commands", "Verification commands");
|
|
1072
|
+
const autoFix = await promptBoolean(ctx, "Auto-fix on verification failure", prefs.verification_auto_fix);
|
|
1073
|
+
if (autoFix !== undefined)
|
|
1074
|
+
prefs.verification_auto_fix = autoFix;
|
|
1075
|
+
const maxRetries = await promptInteger(ctx, "Verification max retries", prefs.verification_max_retries, "2");
|
|
1076
|
+
applyNumber(prefs, "verification_max_retries", maxRetries);
|
|
1077
|
+
const ev = await promptBoolean(ctx, "Enhanced verification (master toggle)", prefs.enhanced_verification, true);
|
|
1078
|
+
if (ev !== undefined)
|
|
1079
|
+
prefs.enhanced_verification = ev;
|
|
1080
|
+
const evPre = await promptBoolean(ctx, "Enhanced verification — pre-execution checks", prefs.enhanced_verification_pre, true);
|
|
1081
|
+
if (evPre !== undefined)
|
|
1082
|
+
prefs.enhanced_verification_pre = evPre;
|
|
1083
|
+
const evPost = await promptBoolean(ctx, "Enhanced verification — post-execution checks", prefs.enhanced_verification_post, true);
|
|
1084
|
+
if (evPost !== undefined)
|
|
1085
|
+
prefs.enhanced_verification_post = evPost;
|
|
1086
|
+
const evStrict = await promptBoolean(ctx, "Enhanced verification — strict mode (fail on any issue)", prefs.enhanced_verification_strict, false);
|
|
1087
|
+
if (evStrict !== undefined)
|
|
1088
|
+
prefs.enhanced_verification_strict = evStrict;
|
|
1089
|
+
// safety_harness
|
|
1090
|
+
const sh = prefs.safety_harness ?? {};
|
|
1091
|
+
const shFields = [
|
|
1092
|
+
{ key: "enabled", label: "Safety harness enabled" },
|
|
1093
|
+
{ key: "evidence_collection", label: "Collect tool evidence" },
|
|
1094
|
+
{ key: "file_change_validation", label: "Validate file change descriptions" },
|
|
1095
|
+
{ key: "evidence_cross_reference", label: "Cross-reference evidence across tools" },
|
|
1096
|
+
{ key: "destructive_command_warnings", label: "Warn on destructive commands" },
|
|
1097
|
+
{ key: "content_validation", label: "Validate written content" },
|
|
1098
|
+
{ key: "checkpoints", label: "Create safety checkpoints" },
|
|
1099
|
+
{ key: "auto_rollback", label: "Auto-rollback on safety violation" },
|
|
1100
|
+
];
|
|
1101
|
+
for (const field of shFields) {
|
|
1102
|
+
const val = await promptBoolean(ctx, `Safety harness — ${field.label}`, sh[field.key]);
|
|
1103
|
+
if (val !== undefined)
|
|
1104
|
+
sh[field.key] = val;
|
|
1105
|
+
}
|
|
1106
|
+
const cap = await promptNumber(ctx, "Safety harness timeout scale cap", sh.timeout_scale_cap);
|
|
1107
|
+
if (cap !== undefined && cap !== "clear")
|
|
1108
|
+
sh.timeout_scale_cap = cap;
|
|
1109
|
+
else if (cap === "clear")
|
|
1110
|
+
delete sh.timeout_scale_cap;
|
|
1111
|
+
if (Object.keys(sh).length > 0)
|
|
1112
|
+
prefs.safety_harness = sh;
|
|
1113
|
+
else if (prefs.safety_harness !== undefined)
|
|
1114
|
+
delete prefs.safety_harness;
|
|
1115
|
+
}
|
|
1116
|
+
async function configureDiscuss(ctx, prefs) {
|
|
1117
|
+
const prep = await promptBoolean(ctx, "Discuss — run preparation phase", prefs.discuss_preparation, true);
|
|
1118
|
+
if (prep !== undefined)
|
|
1119
|
+
prefs.discuss_preparation = prep;
|
|
1120
|
+
const web = await promptBoolean(ctx, "Discuss — web research during preparation", prefs.discuss_web_research, true);
|
|
1121
|
+
if (web !== undefined)
|
|
1122
|
+
prefs.discuss_web_research = web;
|
|
1123
|
+
const depth = await promptEnum(ctx, "Discuss preparation depth", prefs.discuss_depth, ["quick", "standard", "thorough"], "standard");
|
|
1124
|
+
if (depth !== undefined)
|
|
1125
|
+
prefs.discuss_depth = depth;
|
|
1126
|
+
}
|
|
1127
|
+
async function configureContextCodebase(ctx, prefs) {
|
|
1128
|
+
const sel = await promptEnum(ctx, "Context selection mode", prefs.context_selection, ["full", "smart"]);
|
|
1129
|
+
if (sel !== undefined)
|
|
1130
|
+
prefs.context_selection = sel;
|
|
1131
|
+
// context_management nested
|
|
1132
|
+
const cm = prefs.context_management ?? {};
|
|
1133
|
+
const mask = await promptBoolean(ctx, "Observation masking (hide stale tool outputs)", cm.observation_masking, true);
|
|
1134
|
+
if (mask !== undefined)
|
|
1135
|
+
cm.observation_masking = mask;
|
|
1136
|
+
const maskTurns = await promptInteger(ctx, "Observation mask turns (1–50)", cm.observation_mask_turns, "8");
|
|
1137
|
+
if (maskTurns !== undefined && maskTurns !== "clear")
|
|
1138
|
+
cm.observation_mask_turns = maskTurns;
|
|
1139
|
+
else if (maskTurns === "clear")
|
|
1140
|
+
delete cm.observation_mask_turns;
|
|
1141
|
+
const thresh = await promptNumber(ctx, "Compaction threshold percent (0.5–0.95)", cm.compaction_threshold_percent, "0.70");
|
|
1142
|
+
if (thresh !== undefined && thresh !== "clear")
|
|
1143
|
+
cm.compaction_threshold_percent = thresh;
|
|
1144
|
+
else if (thresh === "clear")
|
|
1145
|
+
delete cm.compaction_threshold_percent;
|
|
1146
|
+
const toolMax = await promptInteger(ctx, "Tool result max chars (200–10000)", cm.tool_result_max_chars, "800");
|
|
1147
|
+
if (toolMax !== undefined && toolMax !== "clear")
|
|
1148
|
+
cm.tool_result_max_chars = toolMax;
|
|
1149
|
+
else if (toolMax === "clear")
|
|
1150
|
+
delete cm.tool_result_max_chars;
|
|
1151
|
+
if (Object.keys(cm).length > 0)
|
|
1152
|
+
prefs.context_management = cm;
|
|
1153
|
+
else if (prefs.context_management !== undefined)
|
|
1154
|
+
delete prefs.context_management;
|
|
1155
|
+
const override = await promptInteger(ctx, "Context window override (tokens, blank = use model default)", prefs.context_window_override);
|
|
1156
|
+
applyNumber(prefs, "context_window_override", override);
|
|
1157
|
+
// codebase map
|
|
1158
|
+
const cb = prefs.codebase ?? {};
|
|
1159
|
+
const currentExcludes = Array.isArray(cb.exclude_patterns) ? cb.exclude_patterns : [];
|
|
1160
|
+
const excludesInput = await ctx.ui.input(`Codebase map — extra exclude patterns (comma- or newline-separated, blank to keep)${currentExcludes.length ? ` (current: ${currentExcludes.join(", ")})` : ""}:`, currentExcludes.join(", "));
|
|
1161
|
+
if (excludesInput !== null && excludesInput !== undefined) {
|
|
1162
|
+
const parsed = parseStringList(excludesInput);
|
|
1163
|
+
if (parsed.length > 0)
|
|
1164
|
+
cb.exclude_patterns = parsed;
|
|
1165
|
+
else if (currentExcludes.length > 0 && excludesInput.trim() === "")
|
|
1166
|
+
delete cb.exclude_patterns;
|
|
1167
|
+
}
|
|
1168
|
+
const maxFiles = await promptInteger(ctx, "Codebase map — max files", cb.max_files, "500");
|
|
1169
|
+
if (maxFiles !== undefined && maxFiles !== "clear")
|
|
1170
|
+
cb.max_files = maxFiles;
|
|
1171
|
+
else if (maxFiles === "clear")
|
|
1172
|
+
delete cb.max_files;
|
|
1173
|
+
const collapse = await promptInteger(ctx, "Codebase map — collapse threshold", cb.collapse_threshold, "20");
|
|
1174
|
+
if (collapse !== undefined && collapse !== "clear")
|
|
1175
|
+
cb.collapse_threshold = collapse;
|
|
1176
|
+
else if (collapse === "clear")
|
|
1177
|
+
delete cb.collapse_threshold;
|
|
1178
|
+
if (Object.keys(cb).length > 0)
|
|
1179
|
+
prefs.codebase = cb;
|
|
1180
|
+
else if (prefs.codebase !== undefined)
|
|
1181
|
+
delete prefs.codebase;
|
|
1182
|
+
}
|
|
1183
|
+
async function configureHooks(ctx, prefs) {
|
|
1184
|
+
// reactive_execution
|
|
1185
|
+
const re = prefs.reactive_execution ?? {};
|
|
1186
|
+
const reEnabled = await promptBoolean(ctx, "Reactive (graph-parallel) task execution", re.enabled, false);
|
|
1187
|
+
if (reEnabled !== undefined)
|
|
1188
|
+
re.enabled = reEnabled;
|
|
1189
|
+
const reMax = await promptInteger(ctx, "Reactive max parallel (1–8)", re.max_parallel, "3");
|
|
1190
|
+
if (reMax !== undefined && reMax !== "clear")
|
|
1191
|
+
re.max_parallel = Math.max(1, Math.min(8, reMax));
|
|
1192
|
+
else if (reMax === "clear")
|
|
1193
|
+
delete re.max_parallel;
|
|
1194
|
+
const reModel = await promptString(ctx, "Reactive subagent model override", re.subagent_model);
|
|
1195
|
+
if (reModel !== undefined) {
|
|
1196
|
+
if (reModel)
|
|
1197
|
+
re.subagent_model = reModel;
|
|
1198
|
+
else
|
|
1199
|
+
delete re.subagent_model;
|
|
1200
|
+
}
|
|
1201
|
+
if (Object.keys(re).length > 0) {
|
|
1202
|
+
// isolation_mode is currently only "same-tree"; set it when enabled to satisfy the schema.
|
|
1203
|
+
if (re.enabled === true && !re.isolation_mode)
|
|
1204
|
+
re.isolation_mode = "same-tree";
|
|
1205
|
+
prefs.reactive_execution = re;
|
|
1206
|
+
}
|
|
1207
|
+
else if (prefs.reactive_execution !== undefined) {
|
|
1208
|
+
delete prefs.reactive_execution;
|
|
1209
|
+
}
|
|
1210
|
+
// gate_evaluation
|
|
1211
|
+
const ge = prefs.gate_evaluation ?? {};
|
|
1212
|
+
const geEnabled = await promptBoolean(ctx, "Parallel gate evaluation during planning", ge.enabled, false);
|
|
1213
|
+
if (geEnabled !== undefined)
|
|
1214
|
+
ge.enabled = geEnabled;
|
|
1215
|
+
const currentSliceGates = Array.isArray(ge.slice_gates) ? ge.slice_gates : [];
|
|
1216
|
+
const sgInput = await ctx.ui.input(`Slice gates to evaluate (comma-separated, blank keeps)${currentSliceGates.length ? ` (current: ${currentSliceGates.join(", ")})` : " (default: Q3,Q4)"}:`, currentSliceGates.join(", "));
|
|
1217
|
+
if (sgInput !== null && sgInput !== undefined) {
|
|
1218
|
+
const parsed = parseStringList(sgInput);
|
|
1219
|
+
if (parsed.length > 0)
|
|
1220
|
+
ge.slice_gates = parsed;
|
|
1221
|
+
else if (currentSliceGates.length > 0 && sgInput.trim() === "")
|
|
1222
|
+
delete ge.slice_gates;
|
|
1223
|
+
}
|
|
1224
|
+
const geTask = await promptBoolean(ctx, "Evaluate task-level gates (Q5/Q6/Q7)", ge.task_gates, true);
|
|
1225
|
+
if (geTask !== undefined)
|
|
1226
|
+
ge.task_gates = geTask;
|
|
1227
|
+
if (Object.keys(ge).length > 0)
|
|
1228
|
+
prefs.gate_evaluation = ge;
|
|
1229
|
+
else if (prefs.gate_evaluation !== undefined)
|
|
1230
|
+
delete prefs.gate_evaluation;
|
|
1231
|
+
// post_unit_hooks[]
|
|
1232
|
+
await configureHookList(ctx, prefs, "post_unit_hooks", "Post-unit hooks", "after");
|
|
1233
|
+
// pre_dispatch_hooks[]
|
|
1234
|
+
await configureHookList(ctx, prefs, "pre_dispatch_hooks", "Pre-dispatch hooks", "before");
|
|
1235
|
+
}
|
|
1236
|
+
async function configureHookList(ctx, prefs, key, label, triggerField) {
|
|
1237
|
+
let hooks = Array.isArray(prefs[key]) ? [...prefs[key]] : [];
|
|
1238
|
+
while (true) {
|
|
1239
|
+
const summary = hooks.length === 0 ? "(none)" : `${hooks.length} hook(s)`;
|
|
1240
|
+
const labels = hooks.map((h, i) => `#${i + 1} ${h.name ?? "(unnamed)"}${h.enabled === false ? " [disabled]" : ""}`);
|
|
1241
|
+
const choice = await ctx.ui.select(`${label} — ${summary}`, [...labels, "Add hook", "Done"]);
|
|
1242
|
+
const pick = typeof choice === "string" ? choice : "";
|
|
1243
|
+
if (!pick || pick === "Done")
|
|
1244
|
+
break;
|
|
1245
|
+
if (pick === "Add hook") {
|
|
1246
|
+
const nameInput = await ctx.ui.input("Hook name (unique identifier):", "");
|
|
1247
|
+
const name = typeof nameInput === "string" ? nameInput.trim() : "";
|
|
1248
|
+
if (!name)
|
|
1249
|
+
continue;
|
|
1250
|
+
const triggerInput = await ctx.ui.input(`Unit types this hook ${triggerField === "after" ? "runs after" : "intercepts before"} (comma-separated, e.g. execute-task):`, "");
|
|
1251
|
+
const triggers = triggerInput ? parseStringList(triggerInput) : [];
|
|
1252
|
+
if (triggers.length === 0) {
|
|
1253
|
+
ctx.ui.notify("Hook discarded — trigger list cannot be empty.", "warning");
|
|
1254
|
+
continue;
|
|
1255
|
+
}
|
|
1256
|
+
const hook = { name, [triggerField]: triggers, enabled: true };
|
|
1257
|
+
if (key === "post_unit_hooks") {
|
|
1258
|
+
const promptInput = await ctx.ui.input("Hook prompt (sent to LLM; supports {milestoneId}, {sliceId}, {taskId}):", "");
|
|
1259
|
+
if (promptInput)
|
|
1260
|
+
hook.prompt = promptInput;
|
|
1261
|
+
}
|
|
1262
|
+
else {
|
|
1263
|
+
const actionChoice = await ctx.ui.select("Action:", ["modify", "skip", "replace"]);
|
|
1264
|
+
if (actionChoice)
|
|
1265
|
+
hook.action = actionChoice;
|
|
1266
|
+
}
|
|
1267
|
+
hooks.push(hook);
|
|
1268
|
+
}
|
|
1269
|
+
else if (pick.startsWith("#")) {
|
|
1270
|
+
const idx = Number(pick.slice(1, pick.indexOf(" "))) - 1;
|
|
1271
|
+
if (idx < 0 || idx >= hooks.length)
|
|
1272
|
+
continue;
|
|
1273
|
+
const editChoice = await ctx.ui.select(`Hook #${idx + 1}: ${hooks[idx].name ?? ""}`, ["Toggle enabled", "Edit prompt/action", "Edit model override", "Delete hook", "Cancel"]);
|
|
1274
|
+
const ec = typeof editChoice === "string" ? editChoice : "";
|
|
1275
|
+
if (!ec || ec === "Cancel")
|
|
1276
|
+
continue;
|
|
1277
|
+
if (ec === "Delete hook") {
|
|
1278
|
+
hooks = hooks.filter((_, i) => i !== idx);
|
|
1279
|
+
}
|
|
1280
|
+
else if (ec === "Toggle enabled") {
|
|
1281
|
+
hooks[idx].enabled = hooks[idx].enabled === false;
|
|
1282
|
+
}
|
|
1283
|
+
else if (ec === "Edit prompt/action") {
|
|
1284
|
+
if (key === "post_unit_hooks") {
|
|
1285
|
+
const newPrompt = await promptString(ctx, "Prompt", hooks[idx].prompt);
|
|
1286
|
+
if (newPrompt !== undefined && newPrompt)
|
|
1287
|
+
hooks[idx].prompt = newPrompt;
|
|
1288
|
+
}
|
|
1289
|
+
else {
|
|
1290
|
+
const newAction = await promptEnum(ctx, "Action", hooks[idx].action, ["modify", "skip", "replace"]);
|
|
1291
|
+
if (newAction !== undefined)
|
|
1292
|
+
hooks[idx].action = newAction;
|
|
1293
|
+
}
|
|
1294
|
+
}
|
|
1295
|
+
else if (ec === "Edit model override") {
|
|
1296
|
+
const m = await promptString(ctx, "Model override (blank to clear)", hooks[idx].model);
|
|
1297
|
+
if (m !== undefined) {
|
|
1298
|
+
if (m)
|
|
1299
|
+
hooks[idx].model = m;
|
|
1300
|
+
else
|
|
1301
|
+
delete hooks[idx].model;
|
|
1302
|
+
}
|
|
1303
|
+
}
|
|
1304
|
+
}
|
|
1305
|
+
}
|
|
1306
|
+
if (hooks.length > 0)
|
|
1307
|
+
prefs[key] = hooks;
|
|
1308
|
+
else if (prefs[key] !== undefined)
|
|
1309
|
+
delete prefs[key];
|
|
1310
|
+
}
|
|
1311
|
+
async function configureUoK(ctx, prefs) {
|
|
1312
|
+
const uok = prefs.uok ?? {};
|
|
1313
|
+
const enabled = await promptBoolean(ctx, "UoK (Unified Orchestration Kernel) enabled", uok.enabled);
|
|
1314
|
+
if (enabled !== undefined)
|
|
1315
|
+
uok.enabled = enabled;
|
|
1316
|
+
const subsections = ["legacy_fallback", "gates", "model_policy", "execution_graph", "audit_unified", "plan_v2"];
|
|
1317
|
+
for (const sub of subsections) {
|
|
1318
|
+
const existing = uok[sub] ?? {};
|
|
1319
|
+
const val = await promptBoolean(ctx, `UoK — ${sub.replace(/_/g, " ")} enabled`, existing.enabled);
|
|
1320
|
+
if (val !== undefined) {
|
|
1321
|
+
existing.enabled = val;
|
|
1322
|
+
uok[sub] = existing;
|
|
1323
|
+
}
|
|
1324
|
+
else if (Object.keys(existing).length > 0) {
|
|
1325
|
+
uok[sub] = existing;
|
|
1326
|
+
}
|
|
1327
|
+
}
|
|
1328
|
+
// gitops has extra fields
|
|
1329
|
+
const gitops = uok.gitops ?? {};
|
|
1330
|
+
const gitopsEnabled = await promptBoolean(ctx, "UoK — gitops enabled", gitops.enabled);
|
|
1331
|
+
if (gitopsEnabled !== undefined)
|
|
1332
|
+
gitops.enabled = gitopsEnabled;
|
|
1333
|
+
const turnAction = await promptEnum(ctx, "UoK gitops — turn action", gitops.turn_action, ["commit", "snapshot", "status-only"]);
|
|
1334
|
+
if (turnAction !== undefined)
|
|
1335
|
+
gitops.turn_action = turnAction;
|
|
1336
|
+
const turnPush = await promptBoolean(ctx, "UoK gitops — turn push", gitops.turn_push);
|
|
1337
|
+
if (turnPush !== undefined)
|
|
1338
|
+
gitops.turn_push = turnPush;
|
|
1339
|
+
if (Object.keys(gitops).length > 0)
|
|
1340
|
+
uok.gitops = gitops;
|
|
1341
|
+
if (Object.keys(uok).length > 0)
|
|
1342
|
+
prefs.uok = uok;
|
|
1343
|
+
else if (prefs.uok !== undefined)
|
|
1344
|
+
delete prefs.uok;
|
|
1345
|
+
}
|
|
1346
|
+
async function configureIntegrations(ctx, prefs) {
|
|
1347
|
+
// Language
|
|
1348
|
+
const lang = await promptString(ctx, "Response language (e.g. Chinese, zh, German — blank to clear)", prefs.language);
|
|
1349
|
+
if (lang !== undefined) {
|
|
1350
|
+
if (lang)
|
|
1351
|
+
prefs.language = lang;
|
|
1352
|
+
else
|
|
1353
|
+
delete prefs.language;
|
|
1354
|
+
}
|
|
1355
|
+
// Search provider
|
|
1356
|
+
const search = await promptEnum(ctx, "Search provider", prefs.search_provider, ["auto", "brave", "tavily", "ollama", "native"], "auto");
|
|
1357
|
+
if (search !== undefined)
|
|
1358
|
+
prefs.search_provider = search;
|
|
1359
|
+
// cmux
|
|
1360
|
+
const cmux = prefs.cmux ?? {};
|
|
1361
|
+
for (const field of ["enabled", "notifications", "sidebar", "splits", "browser"]) {
|
|
1362
|
+
const val = await promptBoolean(ctx, `cmux — ${field}`, cmux[field]);
|
|
1363
|
+
if (val !== undefined)
|
|
1364
|
+
cmux[field] = val;
|
|
1365
|
+
}
|
|
1366
|
+
if (Object.keys(cmux).length > 0)
|
|
1367
|
+
prefs.cmux = cmux;
|
|
1368
|
+
else if (prefs.cmux !== undefined)
|
|
1369
|
+
delete prefs.cmux;
|
|
1370
|
+
// remote_questions
|
|
1371
|
+
await configureRemoteQuestions(ctx, prefs);
|
|
1372
|
+
// github sync
|
|
1373
|
+
await configureGitHubSync(ctx, prefs);
|
|
1374
|
+
}
|
|
1375
|
+
async function configureRemoteQuestions(ctx, prefs) {
|
|
1376
|
+
const existing = prefs.remote_questions ?? {};
|
|
1377
|
+
const channel = await promptEnum(ctx, "Remote questions channel", existing.channel, ["slack", "discord", "telegram"]);
|
|
1378
|
+
const channelId = await promptString(ctx, "Remote questions channel_id", existing.channel_id);
|
|
1379
|
+
const timeout = await promptInteger(ctx, "Remote questions timeout (minutes, 1–30)", existing.timeout_minutes, "10");
|
|
1380
|
+
const poll = await promptInteger(ctx, "Remote questions poll interval (seconds, 2–30)", existing.poll_interval_seconds, "5");
|
|
1381
|
+
if (channel !== undefined)
|
|
1382
|
+
existing.channel = channel;
|
|
1383
|
+
if (channelId !== undefined) {
|
|
1384
|
+
if (channelId)
|
|
1385
|
+
existing.channel_id = channelId;
|
|
1386
|
+
else
|
|
1387
|
+
delete existing.channel_id;
|
|
1388
|
+
}
|
|
1389
|
+
applyNumber(existing, "timeout_minutes", timeout);
|
|
1390
|
+
applyNumber(existing, "poll_interval_seconds", poll);
|
|
1391
|
+
// Required pair: channel + channel_id. If either is missing, keep whatever existed unchanged.
|
|
1392
|
+
if (existing.channel && existing.channel_id) {
|
|
1393
|
+
prefs.remote_questions = existing;
|
|
1394
|
+
}
|
|
1395
|
+
else if (!existing.channel && !existing.channel_id) {
|
|
1396
|
+
if (prefs.remote_questions !== undefined)
|
|
1397
|
+
delete prefs.remote_questions;
|
|
1398
|
+
}
|
|
1399
|
+
else {
|
|
1400
|
+
// Partial config — hold it so user can finish, but warn.
|
|
1401
|
+
ctx.ui.notify("remote_questions requires both channel and channel_id; keeping partial config.", "warning");
|
|
1402
|
+
prefs.remote_questions = existing;
|
|
1403
|
+
}
|
|
1404
|
+
}
|
|
1405
|
+
async function configureGitHubSync(ctx, prefs) {
|
|
1406
|
+
const gh = prefs.github ?? {};
|
|
1407
|
+
const enabled = await promptBoolean(ctx, "GitHub sync enabled", gh.enabled, false);
|
|
1408
|
+
if (enabled !== undefined)
|
|
1409
|
+
gh.enabled = enabled;
|
|
1410
|
+
const repo = await promptString(ctx, "GitHub repo (owner/repo, blank = auto-detect from git remote)", gh.repo);
|
|
1411
|
+
if (repo !== undefined) {
|
|
1412
|
+
if (repo)
|
|
1413
|
+
gh.repo = repo;
|
|
1414
|
+
else
|
|
1415
|
+
delete gh.repo;
|
|
1416
|
+
}
|
|
1417
|
+
const project = await promptInteger(ctx, "GitHub Projects v2 number (blank = none)", gh.project);
|
|
1418
|
+
if (project !== undefined && project !== "clear")
|
|
1419
|
+
gh.project = project;
|
|
1420
|
+
else if (project === "clear")
|
|
1421
|
+
delete gh.project;
|
|
1422
|
+
// labels
|
|
1423
|
+
const currentLabels = Array.isArray(gh.labels) ? gh.labels : [];
|
|
1424
|
+
const labelsInput = await ctx.ui.input(`GitHub default labels (comma-separated)${currentLabels.length ? ` (current: ${currentLabels.join(", ")})` : ""}:`, currentLabels.join(", "));
|
|
1425
|
+
if (labelsInput !== null && labelsInput !== undefined) {
|
|
1426
|
+
const parsed = parseStringList(labelsInput);
|
|
1427
|
+
if (parsed.length > 0)
|
|
1428
|
+
gh.labels = parsed;
|
|
1429
|
+
else if (currentLabels.length > 0 && labelsInput.trim() === "")
|
|
1430
|
+
delete gh.labels;
|
|
1431
|
+
}
|
|
1432
|
+
const autoLink = await promptBoolean(ctx, "GitHub — auto-link commits with Resolves #N", gh.auto_link_commits, true);
|
|
1433
|
+
if (autoLink !== undefined)
|
|
1434
|
+
gh.auto_link_commits = autoLink;
|
|
1435
|
+
const slicePrs = await promptBoolean(ctx, "GitHub — create per-slice draft PRs", gh.slice_prs, true);
|
|
1436
|
+
if (slicePrs !== undefined)
|
|
1437
|
+
gh.slice_prs = slicePrs;
|
|
1438
|
+
if (gh.enabled === true || Object.keys(gh).length > 1)
|
|
1439
|
+
prefs.github = gh;
|
|
1440
|
+
else if (prefs.github !== undefined && Object.keys(gh).length === 0)
|
|
1441
|
+
delete prefs.github;
|
|
1442
|
+
else if (Object.keys(gh).length > 0)
|
|
1443
|
+
prefs.github = gh;
|
|
1444
|
+
}
|
|
555
1445
|
export async function configureMode(ctx, prefs) {
|
|
556
1446
|
const currentMode = prefs.mode;
|
|
557
1447
|
const modeChoice = await ctx.ui.select(`Workflow mode${currentMode ? ` (current: ${currentMode})` : ""}:`, [
|
|
@@ -576,11 +1466,32 @@ export async function configureMode(ctx, prefs) {
|
|
|
576
1466
|
}
|
|
577
1467
|
}
|
|
578
1468
|
async function configureAdvanced(ctx, prefs) {
|
|
579
|
-
const
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
1469
|
+
const unique = await promptBoolean(ctx, "Unique milestone IDs", prefs.unique_milestone_ids);
|
|
1470
|
+
if (unique !== undefined)
|
|
1471
|
+
prefs.unique_milestone_ids = unique;
|
|
1472
|
+
const autoViz = await promptBoolean(ctx, "Auto-visualize milestones (open HTML visualizer)", prefs.auto_visualize);
|
|
1473
|
+
if (autoViz !== undefined)
|
|
1474
|
+
prefs.auto_visualize = autoViz;
|
|
1475
|
+
const autoReport = await promptBoolean(ctx, "Auto-generate milestone HTML report", prefs.auto_report, true);
|
|
1476
|
+
if (autoReport !== undefined)
|
|
1477
|
+
prefs.auto_report = autoReport;
|
|
1478
|
+
const forensics = await promptBoolean(ctx, "Forensics dedup (search GitHub before filing)", prefs.forensics_dedup, false);
|
|
1479
|
+
if (forensics !== undefined)
|
|
1480
|
+
prefs.forensics_dedup = forensics;
|
|
1481
|
+
const tokenCost = await promptBoolean(ctx, "Show token cost in footer", prefs.show_token_cost, false);
|
|
1482
|
+
if (tokenCost !== undefined)
|
|
1483
|
+
prefs.show_token_cost = tokenCost;
|
|
1484
|
+
const widget = await promptEnum(ctx, "Auto-mode widget display", prefs.widget_mode, ["full", "small", "min", "off"], "full");
|
|
1485
|
+
if (widget !== undefined)
|
|
1486
|
+
prefs.widget_mode = widget;
|
|
1487
|
+
const experimental = prefs.experimental ?? {};
|
|
1488
|
+
const rtk = await promptBoolean(ctx, "Experimental: RTK shell-command compression", experimental.rtk, false);
|
|
1489
|
+
if (rtk !== undefined)
|
|
1490
|
+
experimental.rtk = rtk;
|
|
1491
|
+
if (Object.keys(experimental).length > 0)
|
|
1492
|
+
prefs.experimental = experimental;
|
|
1493
|
+
else if (prefs.experimental !== undefined)
|
|
1494
|
+
delete prefs.experimental;
|
|
584
1495
|
}
|
|
585
1496
|
// ─── Main wizard with category menu ─────────────────────────────────────────
|
|
586
1497
|
export async function handlePrefsWizard(ctx, scope, prefill, opts) {
|
|
@@ -608,6 +1519,14 @@ export async function handlePrefsWizard(ctx, scope, prefill, opts) {
|
|
|
608
1519
|
`Skills ${summaries.skills}`,
|
|
609
1520
|
`Budget ${summaries.budget}`,
|
|
610
1521
|
`Notifications ${summaries.notifications}`,
|
|
1522
|
+
`Phases ${summaries.phases}`,
|
|
1523
|
+
`Parallelism ${summaries.parallelism}`,
|
|
1524
|
+
`Verification ${summaries.verification}`,
|
|
1525
|
+
`Discuss ${summaries.discuss}`,
|
|
1526
|
+
`Context ${summaries.context}`,
|
|
1527
|
+
`Hooks ${summaries.hooks}`,
|
|
1528
|
+
`UoK ${summaries.uok}`,
|
|
1529
|
+
`Integrations ${summaries.integrations}`,
|
|
611
1530
|
`Advanced ${summaries.advanced}`,
|
|
612
1531
|
`── Save & Exit ──`,
|
|
613
1532
|
];
|
|
@@ -629,6 +1548,22 @@ export async function handlePrefsWizard(ctx, scope, prefill, opts) {
|
|
|
629
1548
|
await configureBudget(ctx, prefs);
|
|
630
1549
|
else if (choice.startsWith("Notifications"))
|
|
631
1550
|
await configureNotifications(ctx, prefs);
|
|
1551
|
+
else if (choice.startsWith("Phases"))
|
|
1552
|
+
await configurePhases(ctx, prefs);
|
|
1553
|
+
else if (choice.startsWith("Parallelism"))
|
|
1554
|
+
await configureParallelism(ctx, prefs);
|
|
1555
|
+
else if (choice.startsWith("Verification"))
|
|
1556
|
+
await configureVerification(ctx, prefs);
|
|
1557
|
+
else if (choice.startsWith("Discuss"))
|
|
1558
|
+
await configureDiscuss(ctx, prefs);
|
|
1559
|
+
else if (choice.startsWith("Context"))
|
|
1560
|
+
await configureContextCodebase(ctx, prefs);
|
|
1561
|
+
else if (choice.startsWith("Hooks"))
|
|
1562
|
+
await configureHooks(ctx, prefs);
|
|
1563
|
+
else if (choice.startsWith("UoK"))
|
|
1564
|
+
await configureUoK(ctx, prefs);
|
|
1565
|
+
else if (choice.startsWith("Integrations"))
|
|
1566
|
+
await configureIntegrations(ctx, prefs);
|
|
632
1567
|
else if (choice.startsWith("Advanced"))
|
|
633
1568
|
await configureAdvanced(ctx, prefs);
|
|
634
1569
|
}
|
|
@@ -732,11 +1667,21 @@ export function serializePreferencesToFrontmatter(prefs) {
|
|
|
732
1667
|
"skill_staleness_days", "auto_supervisor", "uat_dispatch", "unique_milestone_ids",
|
|
733
1668
|
"budget_ceiling", "budget_enforcement", "context_pause_threshold",
|
|
734
1669
|
"notifications", "cmux", "remote_questions", "git",
|
|
1670
|
+
"stale_commit_threshold_minutes",
|
|
735
1671
|
"post_unit_hooks", "pre_dispatch_hooks",
|
|
736
|
-
"dynamic_routing", "uok", "token_profile", "
|
|
1672
|
+
"dynamic_routing", "uok", "token_profile", "service_tier", "flat_rate_providers",
|
|
1673
|
+
"phases", "parallel", "slice_parallel",
|
|
1674
|
+
"reactive_execution", "gate_evaluation",
|
|
737
1675
|
"auto_visualize", "auto_report",
|
|
738
1676
|
"verification_commands", "verification_auto_fix", "verification_max_retries",
|
|
739
|
-
"
|
|
1677
|
+
"enhanced_verification", "enhanced_verification_pre",
|
|
1678
|
+
"enhanced_verification_post", "enhanced_verification_strict",
|
|
1679
|
+
"safety_harness",
|
|
1680
|
+
"discuss_preparation", "discuss_web_research", "discuss_depth",
|
|
1681
|
+
"search_provider", "context_selection", "context_management", "context_window_override",
|
|
1682
|
+
"codebase", "widget_mode", "forensics_dedup", "show_token_cost",
|
|
1683
|
+
"github", "experimental",
|
|
1684
|
+
"language",
|
|
740
1685
|
];
|
|
741
1686
|
const seen = new Set();
|
|
742
1687
|
for (const key of orderedKeys) {
|