prizmkit 1.1.100 → 1.1.102
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/bin/create-prizmkit.js +4 -4
- package/bundled/VERSION.json +3 -3
- package/bundled/dev-pipeline/.env.example +3 -3
- package/bundled/dev-pipeline/README.md +110 -90
- package/bundled/dev-pipeline/assets/prizm-dev-team-integration.md +1 -1
- package/bundled/dev-pipeline/cli.py +27 -0
- package/bundled/dev-pipeline/prizmkit_runtime/__init__.py +13 -0
- package/bundled/dev-pipeline/prizmkit_runtime/__main__.py +9 -0
- package/bundled/dev-pipeline/prizmkit_runtime/cli.py +193 -0
- package/bundled/dev-pipeline/prizmkit_runtime/commands.py +313 -0
- package/bundled/dev-pipeline/prizmkit_runtime/compat.py +32 -0
- package/bundled/dev-pipeline/prizmkit_runtime/config.py +410 -0
- package/bundled/dev-pipeline/prizmkit_runtime/daemon.py +478 -0
- package/bundled/dev-pipeline/prizmkit_runtime/gitops.py +734 -0
- package/bundled/dev-pipeline/prizmkit_runtime/heartbeat.py +256 -0
- package/bundled/dev-pipeline/prizmkit_runtime/interoperability.py +109 -0
- package/bundled/dev-pipeline/prizmkit_runtime/paths.py +110 -0
- package/bundled/dev-pipeline/prizmkit_runtime/processes.py +373 -0
- package/bundled/dev-pipeline/prizmkit_runtime/reset.py +389 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_bookkeeping.py +51 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_classification.py +179 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_models.py +355 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_prompts.py +118 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_recovery.py +187 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_status.py +153 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runners.py +425 -0
- package/bundled/dev-pipeline/prizmkit_runtime/sessions.py +560 -0
- package/bundled/dev-pipeline/prizmkit_runtime/status.py +71 -0
- package/bundled/dev-pipeline/scripts/generate-bootstrap-prompt.py +51 -36
- package/bundled/dev-pipeline/scripts/generate-bugfix-prompt.py +20 -5
- package/bundled/dev-pipeline/scripts/generate-recovery-prompt.py +2 -2
- package/bundled/dev-pipeline/scripts/parse-stream-progress.py +39 -0
- package/bundled/dev-pipeline/templates/agent-prompts/dev-implement.md +8 -2
- package/bundled/dev-pipeline/templates/agent-prompts/reviewer-review.md +1 -1
- package/bundled/dev-pipeline/templates/bootstrap-prompt.md +6 -2
- package/bundled/dev-pipeline/templates/bootstrap-tier1.md +14 -6
- package/bundled/dev-pipeline/templates/bootstrap-tier2.md +14 -4
- package/bundled/dev-pipeline/templates/bootstrap-tier3.md +14 -4
- package/bundled/dev-pipeline/templates/sections/context-budget-rules.md +2 -0
- package/bundled/dev-pipeline/templates/sections/log-size-awareness.md +9 -30
- package/bundled/dev-pipeline/templates/sections/phase-context-snapshot-agent-suffix.md +15 -7
- package/bundled/dev-pipeline/templates/sections/phase-implement-agent.md +42 -29
- package/bundled/dev-pipeline/templates/sections/phase-implement-full.md +41 -39
- package/bundled/dev-pipeline/templates/sections/phase-implement-lite.md +8 -17
- package/bundled/dev-pipeline/templates/sections/phase-prizmkit-test.md +2 -2
- package/bundled/dev-pipeline/templates/sections/phase-review-agent.md +1 -3
- package/bundled/dev-pipeline/templates/sections/phase-review-full.md +1 -3
- package/bundled/dev-pipeline/templates/sections/phase0-test-baseline.md +3 -8
- package/bundled/dev-pipeline/templates/sections/test-failure-recovery-agent.md +6 -2
- package/bundled/dev-pipeline/templates/sections/test-failure-recovery-lite.md +5 -1
- package/bundled/dev-pipeline/tests/test_auto_skip.py +436 -14
- package/bundled/dev-pipeline/tests/test_generate_bootstrap_prompt.py +115 -7
- package/bundled/dev-pipeline/tests/test_generate_bugfix_prompt.py +40 -0
- package/bundled/dev-pipeline/tests/test_python_runner_parity.py +1226 -0
- package/bundled/dev-pipeline/tests/test_unified_cli.py +1045 -0
- package/bundled/skills/_metadata.json +1 -1
- package/bundled/skills/bugfix-pipeline-launcher/SKILL.md +29 -34
- package/bundled/skills/bugfix-pipeline-launcher/references/configuration.md +6 -5
- package/bundled/skills/feature-pipeline-launcher/SKILL.md +29 -35
- package/bundled/skills/feature-pipeline-launcher/references/configuration.md +7 -6
- package/bundled/skills/feature-workflow/SKILL.md +3 -6
- package/bundled/skills/recovery-workflow/SKILL.md +23 -32
- package/bundled/skills/refactor-pipeline-launcher/SKILL.md +29 -35
- package/bundled/skills/refactor-pipeline-launcher/references/configuration.md +7 -6
- package/bundled/skills/refactor-workflow/SKILL.md +3 -6
- package/bundled/templates/hooks/commit-intent.json +2 -2
- package/bundled/templates/hooks/diff-prizm-docs.py +226 -0
- package/bundled/templates/hooks/prizm-pre-commit.py +45 -0
- package/bundled/templates/hooks/validate-prizm-docs.py +240 -0
- package/package.json +1 -1
- package/src/config.js +42 -19
- package/src/external-skills.js +14 -14
- package/src/index.js +3 -6
- package/src/manifest.js +11 -5
- package/src/metadata.js +7 -18
- package/src/platforms.js +25 -0
- package/src/prompts.js +0 -12
- package/src/runtimes.js +18 -11
- package/src/scaffold.js +144 -122
- package/src/upgrade.js +12 -3
- package/bundled/dev-pipeline/launch-bugfix-daemon.sh +0 -500
- package/bundled/dev-pipeline/launch-feature-daemon.sh +0 -657
- package/bundled/dev-pipeline/launch-refactor-daemon.sh +0 -502
- package/bundled/dev-pipeline/lib/branch.sh +0 -326
- package/bundled/dev-pipeline/lib/common.sh +0 -1476
- package/bundled/dev-pipeline/lib/heartbeat.sh +0 -469
- package/bundled/dev-pipeline/reset-bug.sh +0 -425
- package/bundled/dev-pipeline/reset-feature.sh +0 -436
- package/bundled/dev-pipeline/reset-refactor.sh +0 -423
- package/bundled/dev-pipeline/run-bugfix.sh +0 -1430
- package/bundled/dev-pipeline/run-feature.sh +0 -1718
- package/bundled/dev-pipeline/run-recovery.sh +0 -648
- package/bundled/dev-pipeline/run-refactor.sh +0 -1463
- package/bundled/dev-pipeline/tests/test-path-resolution.sh +0 -100
- package/bundled/dev-pipeline-windows/.env.example +0 -36
- package/bundled/dev-pipeline-windows/README.md +0 -30
- package/bundled/dev-pipeline-windows/SCHEMA_ANALYSIS.md +0 -533
- package/bundled/dev-pipeline-windows/assets/feature-list-example.json +0 -146
- package/bundled/dev-pipeline-windows/assets/prizm-dev-team-integration.md +0 -137
- package/bundled/dev-pipeline-windows/launch-bugfix-daemon.ps1 +0 -9
- package/bundled/dev-pipeline-windows/launch-feature-daemon.ps1 +0 -9
- package/bundled/dev-pipeline-windows/launch-refactor-daemon.ps1 +0 -9
- package/bundled/dev-pipeline-windows/lib/branch.ps1 +0 -235
- package/bundled/dev-pipeline-windows/lib/common.ps1 +0 -991
- package/bundled/dev-pipeline-windows/lib/daemon.ps1 +0 -140
- package/bundled/dev-pipeline-windows/lib/pipeline.ps1 +0 -1051
- package/bundled/dev-pipeline-windows/lib/reset.ps1 +0 -121
- package/bundled/dev-pipeline-windows/reset-bug.ps1 +0 -10
- package/bundled/dev-pipeline-windows/reset-feature.ps1 +0 -10
- package/bundled/dev-pipeline-windows/reset-refactor.ps1 +0 -10
- package/bundled/dev-pipeline-windows/run-bugfix.ps1 +0 -9
- package/bundled/dev-pipeline-windows/run-feature.ps1 +0 -9
- package/bundled/dev-pipeline-windows/run-recovery.ps1 +0 -179
- package/bundled/dev-pipeline-windows/run-refactor.ps1 +0 -9
- package/bundled/dev-pipeline-windows/scripts/check-session-status.py +0 -301
- package/bundled/dev-pipeline-windows/scripts/continuation.py +0 -374
- package/bundled/dev-pipeline-windows/scripts/detect-stuck.py +0 -530
- package/bundled/dev-pipeline-windows/scripts/generate-bootstrap-prompt.py +0 -2279
- package/bundled/dev-pipeline-windows/scripts/generate-bugfix-prompt.py +0 -763
- package/bundled/dev-pipeline-windows/scripts/generate-recovery-prompt.py +0 -805
- package/bundled/dev-pipeline-windows/scripts/generate-refactor-prompt.py +0 -841
- package/bundled/dev-pipeline-windows/scripts/init-bugfix-pipeline.py +0 -316
- package/bundled/dev-pipeline-windows/scripts/init-dev-team.py +0 -134
- package/bundled/dev-pipeline-windows/scripts/init-pipeline.py +0 -382
- package/bundled/dev-pipeline-windows/scripts/init-refactor-pipeline.py +0 -399
- package/bundled/dev-pipeline-windows/scripts/parse-stream-progress.py +0 -1362
- package/bundled/dev-pipeline-windows/scripts/patch-completion-notes.py +0 -191
- package/bundled/dev-pipeline-windows/scripts/prizmkit-test-gate.py +0 -446
- package/bundled/dev-pipeline-windows/scripts/update-bug-status.py +0 -1121
- package/bundled/dev-pipeline-windows/scripts/update-checkpoint.py +0 -173
- package/bundled/dev-pipeline-windows/scripts/update-feature-status.py +0 -1789
- package/bundled/dev-pipeline-windows/scripts/update-refactor-status.py +0 -1327
- package/bundled/dev-pipeline-windows/scripts/utils.py +0 -542
- package/bundled/dev-pipeline-windows/templates/agent-prompts/critic-plan-challenge.md +0 -7
- package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-fix.md +0 -7
- package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-implement.md +0 -65
- package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-resume.md +0 -5
- package/bundled/dev-pipeline-windows/templates/agent-prompts/reviewer-review.md +0 -7
- package/bundled/dev-pipeline-windows/templates/bootstrap-prompt.md +0 -73
- package/bundled/dev-pipeline-windows/templates/bootstrap-tier1.md +0 -589
- package/bundled/dev-pipeline-windows/templates/bootstrap-tier2.md +0 -710
- package/bundled/dev-pipeline-windows/templates/bootstrap-tier3.md +0 -791
- package/bundled/dev-pipeline-windows/templates/bug-fix-list-schema.json +0 -263
- package/bundled/dev-pipeline-windows/templates/bugfix-bootstrap-prompt.md +0 -326
- package/bundled/dev-pipeline-windows/templates/feature-list-schema.json +0 -237
- package/bundled/dev-pipeline-windows/templates/refactor-bootstrap-prompt.md +0 -340
- package/bundled/dev-pipeline-windows/templates/refactor-list-schema.json +0 -270
- package/bundled/dev-pipeline-windows/templates/sections/ac-verification-checklist.md +0 -7
- package/bundled/dev-pipeline-windows/templates/sections/checkpoint-system.md +0 -91
- package/bundled/dev-pipeline-windows/templates/sections/context-budget-rules.md +0 -34
- package/bundled/dev-pipeline-windows/templates/sections/critical-paths-agent.md +0 -10
- package/bundled/dev-pipeline-windows/templates/sections/critical-paths-full.md +0 -12
- package/bundled/dev-pipeline-windows/templates/sections/critical-paths-lite.md +0 -7
- package/bundled/dev-pipeline-windows/templates/sections/directory-convention-agent.md +0 -8
- package/bundled/dev-pipeline-windows/templates/sections/directory-convention-full.md +0 -9
- package/bundled/dev-pipeline-windows/templates/sections/directory-convention-lite.md +0 -6
- package/bundled/dev-pipeline-windows/templates/sections/failure-capture.md +0 -21
- package/bundled/dev-pipeline-windows/templates/sections/feature-context.md +0 -21
- package/bundled/dev-pipeline-windows/templates/sections/log-size-awareness.md +0 -41
- package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification-auto.md +0 -283
- package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification-opencli.md +0 -112
- package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification.md +0 -168
- package/bundled/dev-pipeline-windows/templates/sections/phase-commit-full.md +0 -82
- package/bundled/dev-pipeline-windows/templates/sections/phase-commit.md +0 -75
- package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-agent-suffix.md +0 -23
- package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-base.md +0 -14
- package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-lite-suffix.md +0 -19
- package/bundled/dev-pipeline-windows/templates/sections/phase-critic-plan-full.md +0 -63
- package/bundled/dev-pipeline-windows/templates/sections/phase-critic-plan.md +0 -42
- package/bundled/dev-pipeline-windows/templates/sections/phase-implement-agent.md +0 -44
- package/bundled/dev-pipeline-windows/templates/sections/phase-implement-full.md +0 -59
- package/bundled/dev-pipeline-windows/templates/sections/phase-implement-lite.md +0 -39
- package/bundled/dev-pipeline-windows/templates/sections/phase-plan-agent.md +0 -27
- package/bundled/dev-pipeline-windows/templates/sections/phase-plan-lite.md +0 -27
- package/bundled/dev-pipeline-windows/templates/sections/phase-prizmkit-test.md +0 -39
- package/bundled/dev-pipeline-windows/templates/sections/phase-review-agent.md +0 -35
- package/bundled/dev-pipeline-windows/templates/sections/phase-review-full.md +0 -35
- package/bundled/dev-pipeline-windows/templates/sections/phase-specify-plan-full.md +0 -73
- package/bundled/dev-pipeline-windows/templates/sections/phase0-init.md +0 -13
- package/bundled/dev-pipeline-windows/templates/sections/phase0-test-baseline.md +0 -21
- package/bundled/dev-pipeline-windows/templates/sections/session-context.md +0 -5
- package/bundled/dev-pipeline-windows/templates/sections/subagent-timeout-recovery.md +0 -6
- package/bundled/dev-pipeline-windows/templates/sections/task-contract.md +0 -34
- package/bundled/dev-pipeline-windows/templates/sections/test-failure-recovery-agent.md +0 -48
- package/bundled/dev-pipeline-windows/templates/sections/test-failure-recovery-lite.md +0 -48
- package/bundled/dev-pipeline-windows/templates/session-status-schema.json +0 -83
- package/bundled/skills-windows/app-planner/SKILL.md +0 -296
- package/bundled/skills-windows/app-planner/assets/app-design-guide.md +0 -101
- package/bundled/skills-windows/app-planner/references/architecture-decisions.md +0 -52
- package/bundled/skills-windows/app-planner/references/brainstorm-guide.md +0 -101
- package/bundled/skills-windows/app-planner/references/frontend-design-guide.md +0 -71
- package/bundled/skills-windows/app-planner/references/infrastructure-convention-discovery.md +0 -108
- package/bundled/skills-windows/app-planner/references/project-brief-guide.md +0 -82
- package/bundled/skills-windows/app-planner/references/project-conventions-discovery.md +0 -59
- package/bundled/skills-windows/app-planner/references/project-state-detection.md +0 -90
- package/bundled/skills-windows/app-planner/references/red-team-checklist.md +0 -40
- package/bundled/skills-windows/app-planner/references/rules/backend/derivation-rules.md +0 -619
- package/bundled/skills-windows/app-planner/references/rules/backend/fixed-rules.md +0 -285
- package/bundled/skills-windows/app-planner/references/rules/backend/question-bank.md +0 -249
- package/bundled/skills-windows/app-planner/references/rules/backend/question-manifest.json +0 -46
- package/bundled/skills-windows/app-planner/references/rules/backend/template.md +0 -173
- package/bundled/skills-windows/app-planner/references/rules/database/derivation-rules.md +0 -382
- package/bundled/skills-windows/app-planner/references/rules/database/fixed-rules.md +0 -211
- package/bundled/skills-windows/app-planner/references/rules/database/question-bank.md +0 -184
- package/bundled/skills-windows/app-planner/references/rules/database/question-manifest.json +0 -39
- package/bundled/skills-windows/app-planner/references/rules/database/template.md +0 -158
- package/bundled/skills-windows/app-planner/references/rules/frontend/derivation-rules.md +0 -820
- package/bundled/skills-windows/app-planner/references/rules/frontend/fixed-rules.md +0 -188
- package/bundled/skills-windows/app-planner/references/rules/frontend/question-bank.md +0 -319
- package/bundled/skills-windows/app-planner/references/rules/frontend/question-manifest.json +0 -51
- package/bundled/skills-windows/app-planner/references/rules/frontend/template.md +0 -339
- package/bundled/skills-windows/app-planner/references/rules/mobile/derivation-rules.md +0 -649
- package/bundled/skills-windows/app-planner/references/rules/mobile/fixed-rules.md +0 -290
- package/bundled/skills-windows/app-planner/references/rules/mobile/question-bank.md +0 -232
- package/bundled/skills-windows/app-planner/references/rules/mobile/question-manifest.json +0 -47
- package/bundled/skills-windows/app-planner/references/rules/mobile/template.md +0 -175
- package/bundled/skills-windows/app-planner/references/rules-configuration.md +0 -46
- package/bundled/skills-windows/bug-fix-workflow/SKILL.md +0 -379
- package/bundled/skills-windows/bug-fix-workflow/references/bug-diagnosis.md +0 -41
- package/bundled/skills-windows/bug-planner/SKILL.md +0 -402
- package/bundled/skills-windows/bug-planner/assets/bug-confirmation-template.md +0 -43
- package/bundled/skills-windows/bug-planner/references/critic-and-verification.md +0 -44
- package/bundled/skills-windows/bug-planner/references/error-recovery.md +0 -73
- package/bundled/skills-windows/bug-planner/references/input-formats.md +0 -53
- package/bundled/skills-windows/bug-planner/references/schema-validation.md +0 -25
- package/bundled/skills-windows/bug-planner/references/severity-rules.md +0 -16
- package/bundled/skills-windows/bug-planner/scripts/validate-bug-list.py +0 -322
- package/bundled/skills-windows/bugfix-pipeline-launcher/SKILL.md +0 -304
- package/bundled/skills-windows/bugfix-pipeline-launcher/references/configuration.md +0 -84
- package/bundled/skills-windows/feature-pipeline-launcher/SKILL.md +0 -381
- package/bundled/skills-windows/feature-pipeline-launcher/references/configuration.md +0 -67
- package/bundled/skills-windows/feature-pipeline-launcher/scripts/preflight-check.py +0 -462
- package/bundled/skills-windows/feature-planner/SKILL.md +0 -397
- package/bundled/skills-windows/feature-planner/assets/evaluation-guide.md +0 -64
- package/bundled/skills-windows/feature-planner/assets/planning-guide.md +0 -214
- package/bundled/skills-windows/feature-planner/references/browser-interaction.md +0 -59
- package/bundled/skills-windows/feature-planner/references/completeness-review.md +0 -57
- package/bundled/skills-windows/feature-planner/references/decomposition-patterns.md +0 -75
- package/bundled/skills-windows/feature-planner/references/error-recovery.md +0 -90
- package/bundled/skills-windows/feature-planner/references/incremental-feature-planning.md +0 -112
- package/bundled/skills-windows/feature-planner/references/new-project-planning.md +0 -85
- package/bundled/skills-windows/feature-planner/scripts/validate-and-generate.py +0 -1020
- package/bundled/skills-windows/feature-workflow/SKILL.md +0 -374
- package/bundled/skills-windows/feature-workflow/references/brainstorm-guide.md +0 -137
- package/bundled/skills-windows/prizm-kit/SKILL.md +0 -93
- package/bundled/skills-windows/prizmkit-code-review/SKILL.md +0 -161
- package/bundled/skills-windows/prizmkit-code-review/references/dev-agent-prompt.md +0 -30
- package/bundled/skills-windows/prizmkit-code-review/references/review-report-template.md +0 -31
- package/bundled/skills-windows/prizmkit-code-review/references/reviewer-agent-prompt.md +0 -66
- package/bundled/skills-windows/prizmkit-code-review/scripts/check_loop.py +0 -186
- package/bundled/skills-windows/prizmkit-committer/SKILL.md +0 -89
- package/bundled/skills-windows/prizmkit-deploy/SKILL.md +0 -444
- package/bundled/skills-windows/prizmkit-deploy/references/ci-cd-workflows.md +0 -115
- package/bundled/skills-windows/prizmkit-deploy/references/cloud-platform-deploy.md +0 -93
- package/bundled/skills-windows/prizmkit-deploy/references/data-safety-examples.md +0 -120
- package/bundled/skills-windows/prizmkit-deploy/references/database-setup.md +0 -46
- package/bundled/skills-windows/prizmkit-deploy/references/deploy-config-schema.md +0 -148
- package/bundled/skills-windows/prizmkit-deploy/references/deploy-history-schema.md +0 -62
- package/bundled/skills-windows/prizmkit-deploy/references/deployment-modes.md +0 -50
- package/bundled/skills-windows/prizmkit-deploy/references/direct-upload.md +0 -26
- package/bundled/skills-windows/prizmkit-deploy/references/dns-setup.md +0 -42
- package/bundled/skills-windows/prizmkit-deploy/references/docker-deploy.md +0 -31
- package/bundled/skills-windows/prizmkit-deploy/references/firewall-setup.md +0 -37
- package/bundled/skills-windows/prizmkit-deploy/references/live-validation-notes.md +0 -21
- package/bundled/skills-windows/prizmkit-deploy/references/nginx-blue-green.md +0 -59
- package/bundled/skills-windows/prizmkit-deploy/references/ssh-bootstrap-flow.md +0 -49
- package/bundled/skills-windows/prizmkit-deploy/references/ssh-execution-flow.md +0 -41
- package/bundled/skills-windows/prizmkit-deploy/references/ssh-takeover.md +0 -20
- package/bundled/skills-windows/prizmkit-deploy/references/ssl-setup.md +0 -56
- package/bundled/skills-windows/prizmkit-implement/SKILL.md +0 -71
- package/bundled/skills-windows/prizmkit-init/SKILL.md +0 -356
- package/bundled/skills-windows/prizmkit-init/assets/project-brief-template.md +0 -82
- package/bundled/skills-windows/prizmkit-init/references/config-schema.md +0 -70
- package/bundled/skills-windows/prizmkit-init/references/rules/layer-detection.md +0 -41
- package/bundled/skills-windows/prizmkit-init/references/tech-stack-catalog.md +0 -13
- package/bundled/skills-windows/prizmkit-init/references/update-supplement.md +0 -9
- package/bundled/skills-windows/prizmkit-plan/SKILL.md +0 -102
- package/bundled/skills-windows/prizmkit-plan/assets/plan-template.md +0 -115
- package/bundled/skills-windows/prizmkit-plan/assets/spec-template.md +0 -73
- package/bundled/skills-windows/prizmkit-plan/references/clarify-guide.md +0 -67
- package/bundled/skills-windows/prizmkit-plan/references/examples.md +0 -85
- package/bundled/skills-windows/prizmkit-plan/references/verification-checklist.md +0 -60
- package/bundled/skills-windows/prizmkit-prizm-docs/SKILL.md +0 -129
- package/bundled/skills-windows/prizmkit-prizm-docs/assets/prizm-docs-format.md +0 -613
- package/bundled/skills-windows/prizmkit-prizm-docs/references/op-init.md +0 -45
- package/bundled/skills-windows/prizmkit-prizm-docs/references/op-rebuild.md +0 -15
- package/bundled/skills-windows/prizmkit-prizm-docs/references/op-status.md +0 -14
- package/bundled/skills-windows/prizmkit-prizm-docs/references/op-update.md +0 -19
- package/bundled/skills-windows/prizmkit-prizm-docs/references/op-validate.md +0 -17
- package/bundled/skills-windows/prizmkit-retrospective/SKILL.md +0 -87
- package/bundled/skills-windows/prizmkit-retrospective/references/knowledge-injection-steps.md +0 -50
- package/bundled/skills-windows/prizmkit-retrospective/references/structural-sync-steps.md +0 -43
- package/bundled/skills-windows/prizmkit-test/SKILL.md +0 -227
- package/bundled/skills-windows/prizmkit-test/references/boundary-coverage-protocol.md +0 -220
- package/bundled/skills-windows/prizmkit-test/references/examples.md +0 -143
- package/bundled/skills-windows/prizmkit-test/references/service-boundary-test-catalog.md +0 -225
- package/bundled/skills-windows/prizmkit-test/references/test-generation-steps.md +0 -109
- package/bundled/skills-windows/prizmkit-test/references/test-report-template.md +0 -111
- package/bundled/skills-windows/prizmkit-test/scripts/validate_boundary_report.py +0 -347
- package/bundled/skills-windows/recovery-workflow/SKILL.md +0 -355
- package/bundled/skills-windows/recovery-workflow/evals/evals.json +0 -46
- package/bundled/skills-windows/recovery-workflow/references/detection.md +0 -58
- package/bundled/skills-windows/recovery-workflow/scripts/detect-recovery-state.py +0 -544
- package/bundled/skills-windows/refactor-pipeline-launcher/SKILL.md +0 -346
- package/bundled/skills-windows/refactor-pipeline-launcher/references/configuration.md +0 -72
- package/bundled/skills-windows/refactor-planner/SKILL.md +0 -398
- package/bundled/skills-windows/refactor-planner/assets/planning-guide.md +0 -292
- package/bundled/skills-windows/refactor-planner/references/behavior-preservation.md +0 -301
- package/bundled/skills-windows/refactor-planner/references/fast-path.md +0 -59
- package/bundled/skills-windows/refactor-planner/references/planning-phases.md +0 -135
- package/bundled/skills-windows/refactor-planner/references/refactor-scoping-guide.md +0 -221
- package/bundled/skills-windows/refactor-planner/scripts/validate-and-generate-refactor.py +0 -858
- package/bundled/skills-windows/refactor-workflow/SKILL.md +0 -343
- package/bundled/skills-windows/refactor-workflow/references/brainstorm-guide.md +0 -116
- package/bundled/templates/hooks/diff-prizm-docs.sh +0 -158
- package/bundled/templates/hooks/prizm-pre-commit.sh +0 -108
- package/bundled/templates/hooks/validate-prizm-docs.sh +0 -139
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
### Architecture Sync & Commit (SINGLE COMMIT)
|
|
2
|
-
|
|
3
|
-
**a.** Run `/prizmkit-retrospective` — maintains `.prizmkit/prizm-docs/` (architecture index):
|
|
4
|
-
1. **Structural sync**: Use `git diff --cached --name-status` to locate changed modules, update KEY_FILES/INTERFACES/DEPENDENCIES/file counts in affected `.prizmkit/prizm-docs/` files
|
|
5
|
-
2. **Architecture knowledge** (feature sessions only): Extract TRAPS/RULES/DECISIONS from completed work into `.prizmkit/prizm-docs/`
|
|
6
|
-
3. **L2 coverage check**: For any module/sub-module with source files created or significantly modified in this session but no L2 `.prizm` doc — evaluate whether L2 is warranted and create if so. The current session has the best context for accurate KEY_FILES, TRAPS, and DECISIONS.
|
|
7
|
-
4. Stage doc changes: `git add .prizmkit/prizm-docs/`
|
|
8
|
-
⚠️ Do NOT commit here. Only stage.
|
|
9
|
-
|
|
10
|
-
**b.** Stage all feature code explicitly (NEVER use `git add -A` or `git add .`):
|
|
11
|
-
```powershell
|
|
12
|
-
git add <specific-files-created-or-modified>
|
|
13
|
-
git add .prizmkit/prizm-docs/
|
|
14
|
-
```
|
|
15
|
-
|
|
16
|
-
**c.** Run `/prizmkit-committer` → THE ONLY commit for this feature:
|
|
17
|
-
`feat({{FEATURE_ID}}): {{FEATURE_TITLE}}`
|
|
18
|
-
This single commit includes: feature code + tests + .prizmkit/prizm-docs/ updates. Do NOT push.
|
|
19
|
-
- MANDATORY: commit must be done via `/prizmkit-committer` skill. Do NOT run manual `git add`/`git commit` as a substitute.
|
|
20
|
-
- Do NOT run `update-feature-status.py` here — the pipeline runner handles feature-list.json updates automatically after session exit.
|
|
21
|
-
|
|
22
|
-
**d.** Final verification:
|
|
23
|
-
```powershell
|
|
24
|
-
git status --short
|
|
25
|
-
```
|
|
26
|
-
Working tree MUST be clean after this step. If any feature-related files remain, stage them into the SAME commit via `git add <file>; if ($LASTEXITCODE -eq 0) { git commit --amend --no-edit }`, do NOT create a separate commit.
|
|
27
|
-
|
|
28
|
-
**e.** Write completion summary for downstream dependency context:
|
|
29
|
-
|
|
30
|
-
Write `.prizmkit/specs/{{FEATURE_SLUG}}/completion-summary.json` with the key changes from this session. This file is NOT committed to git — the pipeline runner reads it to propagate context to dependent features.
|
|
31
|
-
|
|
32
|
-
```json
|
|
33
|
-
{
|
|
34
|
-
"completion_notes": [
|
|
35
|
-
"<each item: one key change, API, model, or integration point that downstream features may need>",
|
|
36
|
-
"Example: Added User model (id, email, password_hash, display_name) in prisma/schema.prisma",
|
|
37
|
-
"Example: POST /api/auth/register and POST /api/auth/login endpoints in src/api/auth.ts",
|
|
38
|
-
"Example: Auth middleware in src/middleware/auth.ts — validates JWT on protected routes"
|
|
39
|
-
]
|
|
40
|
-
}
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
Rules for writing completion notes:
|
|
44
|
-
- Focus on **what downstream features need to know**: new APIs, models, exported functions, key file paths
|
|
45
|
-
- Each note should be self-contained and concise (one line, under 120 characters preferred)
|
|
46
|
-
- Include 3-8 notes covering the most important changes
|
|
47
|
-
- Do NOT include test files, config changes, or internal implementation details unless they affect other features
|
|
48
|
-
- If this feature has no downstream dependents, still write the summary (it serves as documentation)
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
**Checkpoint update**: After `/prizmkit-retrospective` completes, run the update script to set step `prizmkit-retrospective` to `"completed"`:
|
|
52
|
-
```powershell
|
|
53
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
54
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
55
|
-
--step prizmkit-retrospective `
|
|
56
|
-
--status completed
|
|
57
|
-
```
|
|
58
|
-
After `/prizmkit-committer` completes, set step `prizmkit-committer` to `"completed"`:
|
|
59
|
-
```powershell
|
|
60
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
61
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
62
|
-
--step prizmkit-committer `
|
|
63
|
-
--status completed
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
### TERMINAL STOP — Commit Completed
|
|
67
|
-
|
|
68
|
-
After all of the following are true, the session is **TERMINAL**:
|
|
69
|
-
|
|
70
|
-
- `/prizmkit-committer` has completed
|
|
71
|
-
- `git status --short` is clean (except ignored/local-only pipeline artifacts)
|
|
72
|
-
- `.prizmkit/specs/{{FEATURE_SLUG}}/completion-summary.json` is written
|
|
73
|
-
- the `prizmkit-committer` checkpoint is marked `completed`
|
|
74
|
-
|
|
75
|
-
At that point, stop immediately. Do **not** process delayed teammate/reviewer findings, do **not** edit files, do **not** amend the commit, and do **not** start any new tool calls. Any findings that arrive after S09 is completed are follow-up work for a later session, not part of this feature commit.
|
package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-agent-suffix.md
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
- **Section 3 — Key TRAPS & RULES**: extract only relevant TRAPS/RULES from prizm-docs. Do NOT copy full L0/L1/L2 content — the orchestrator already loaded them.
|
|
2
|
-
- **Section 4 — File Manifest**: For each file relevant to this feature, list: file path, why it's needed (modify/reference/test), key interface signatures (function names + params + return types). Do NOT include full file content — agents read files on-demand. Format:
|
|
3
|
-
### Files to Modify
|
|
4
|
-
| File | Why Needed | Key Interfaces |
|
|
5
|
-
|------|-----------|----------------|
|
|
6
|
-
| `<source-dir>/config.js` | Add runtime config layer | `config` (Zod object), `configSchema` |
|
|
7
|
-
|
|
8
|
-
### Files for Reference
|
|
9
|
-
| File | Why Needed | Key Interfaces |
|
|
10
|
-
|------|-----------|----------------|
|
|
11
|
-
| `<source-dir>/security/permission-guard.js` | Permission check integration | `checkCommandPermission(userId, cmd)` |
|
|
12
|
-
|
|
13
|
-
### Known TRAPS (from .prizmkit/prizm-docs/)
|
|
14
|
-
- <trap entries extracted from L1/L2 docs>
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
**Checkpoint update**: Run the update script to set step `context-snapshot` to `"completed"`:
|
|
18
|
-
```powershell
|
|
19
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
20
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
21
|
-
--step context-snapshot `
|
|
22
|
-
--status completed
|
|
23
|
-
```
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
### Build Context Snapshot
|
|
2
|
-
|
|
3
|
-
```powershell
|
|
4
|
-
if (Test-Path .prizmkit\specs\{{FEATURE_SLUG}}\context-snapshot.md) { "EXISTS" } else { "MISSING" }
|
|
5
|
-
```
|
|
6
|
-
|
|
7
|
-
If MISSING — build it now:
|
|
8
|
-
1. Read `.prizmkit/prizm-docs/root.prizm` and relevant L1/L2 prizm docs
|
|
9
|
-
2. Read source files listed in the feature's scope (use prizm-docs KEY_FILES for guidance)
|
|
10
|
-
3. Write `.prizmkit/specs/{{FEATURE_SLUG}}/context-snapshot.md`:
|
|
11
|
-
- **Section 1 — Feature Brief**: 2-3 line feature description from Task Contract
|
|
12
|
-
- **Section 2 — Verification Gates**: gate checklist from Task Contract
|
|
13
|
-
- **Section 3 — Key TRAPS & RULES**: extract only relevant TRAPS/RULES from prizm-docs that apply to files in this scope. Do NOT copy full L0/L1/L2 content.
|
|
14
|
-
- **Section 4 — File Manifest**: file path, why needed, key interfaces. Format: Files to Modify | Files for Reference tables.
|
package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-lite-suffix.md
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
- **Section 3 — Key TRAPS & RULES**: extract only relevant TRAPS/RULES from prizm-docs that apply to files in this scope. Do NOT copy full L0/L1/L2 content.
|
|
2
|
-
- **Section 4 — File Manifest**: For each relevant file, list path, why needed, key interface signatures. Use table format:
|
|
3
|
-
|
|
4
|
-
### Files to Modify
|
|
5
|
-
| File | Why Needed | Key Interfaces |
|
|
6
|
-
|------|-----------|----------------|
|
|
7
|
-
|
|
8
|
-
### Files for Reference
|
|
9
|
-
| File | Why Needed | Key Interfaces |
|
|
10
|
-
|------|-----------|----------------|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
**Checkpoint update**: Run the update script to set step `context-snapshot` to `"completed"`:
|
|
14
|
-
```powershell
|
|
15
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
16
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
17
|
-
--step context-snapshot `
|
|
18
|
-
--status completed
|
|
19
|
-
```
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
### Plan Challenge — Critic Agent(s)
|
|
2
|
-
|
|
3
|
-
**Guard**: Verify critic agent file exists before spawning:
|
|
4
|
-
```powershell
|
|
5
|
-
if (Test-Path -LiteralPath "{{CRITIC_SUBAGENT_PATH}}") { "CRITIC:READY" } else { "CRITIC:MISSING" }
|
|
6
|
-
```
|
|
7
|
-
If CRITIC:MISSING — skip this phase entirely and proceed. Log: "Critic agent not installed — skipping Plan Challenge."
|
|
8
|
-
|
|
9
|
-
**Choose ONE path based on `{{CRITIC_COUNT}}`:**
|
|
10
|
-
|
|
11
|
-
**Agent spawn failure policy**:
|
|
12
|
-
- If spawning Critic fails with team/config/lock errors, retry at most once.
|
|
13
|
-
- If the second attempt fails, do not keep spawning variants. Either create the required team once (when team tooling is available) or perform the plan challenge inline and write the required challenge report yourself.
|
|
14
|
-
- Record the fallback in the report; do not burn multiple minutes on repeated identical spawn failures.
|
|
15
|
-
|
|
16
|
-
**No silent report polling**:
|
|
17
|
-
- Do NOT run a long no-output loop waiting for `challenge-report*.md`.
|
|
18
|
-
- If you need to wait for a report file, use a short bounded check (≤120s) that prints elapsed time and reports present on every iteration.
|
|
19
|
-
- If reports are still missing after the bounded check, request one status update; if still missing, perform the missing challenge lens inline and continue.
|
|
20
|
-
|
|
21
|
-
**If {{CRITIC_COUNT}} = 1 → Single Critic** (skip to CP-2.5 after this):
|
|
22
|
-
|
|
23
|
-
**Spawn Agent**:
|
|
24
|
-
| Parameter | Value |
|
|
25
|
-
|-----------|-------|
|
|
26
|
-
| subagent_type | prizm-dev-team-critic |
|
|
27
|
-
| mode | plan |
|
|
28
|
-
| run_in_background | false |
|
|
29
|
-
|
|
30
|
-
**Prompt**:
|
|
31
|
-
> {{AGENT_PROMPT_CRITIC_PLAN_CHALLENGE}}
|
|
32
|
-
|
|
33
|
-
**If {{CRITIC_COUNT}} = 3 → Multi-Critic Voting** (skip Single Critic above):
|
|
34
|
-
|
|
35
|
-
Spawn 3 Critic agents in PARALLEL (issue all 3 Agent tool calls in the SAME message turn). Do NOT wait for one before spawning the next. Each with mode="plan", run_in_background=false:
|
|
36
|
-
|
|
37
|
-
Critic-A prompt (append to base prompt above):
|
|
38
|
-
> "**Focus Lens: Architecture & Scalability.** Prioritize: architectural pattern fit, scalability implications, over-engineering risks, component boundary design.
|
|
39
|
-
> Write `.prizmkit/specs/{{FEATURE_SLUG}}/challenge-report-A.md`."
|
|
40
|
-
|
|
41
|
-
Critic-B prompt (append to base prompt above):
|
|
42
|
-
> "**Focus Lens: Data Model & Edge Cases.** Prioritize: data model design fit, entity relationships, edge cases in business logic, missing boundary conditions.
|
|
43
|
-
> Write `.prizmkit/specs/{{FEATURE_SLUG}}/challenge-report-B.md`."
|
|
44
|
-
|
|
45
|
-
Critic-C prompt (append to base prompt above):
|
|
46
|
-
> "**Focus Lens: Security & Performance.** Prioritize: security attack surface, authentication/authorization gaps, performance bottlenecks, resource leaks.
|
|
47
|
-
> Write `.prizmkit/specs/{{FEATURE_SLUG}}/challenge-report-C.md`."
|
|
48
|
-
|
|
49
|
-
After all critics return, read all 3 reports:
|
|
50
|
-
- Challenge raised by **2/3 or more** critics → **must respond** (adjust plan or justify why not)
|
|
51
|
-
- Challenge raised by **1/3 only** → logged in context-snapshot but not blocking
|
|
52
|
-
- Max 1 plan revision round.
|
|
53
|
-
|
|
54
|
-
**CP-2.5**: Plan challenges reviewed and resolved.
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
**Checkpoint update**: Run the update script to set step `critic-plan-review` to `"completed"`:
|
|
58
|
-
```powershell
|
|
59
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
60
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
61
|
-
--step critic-plan-review `
|
|
62
|
-
--status completed
|
|
63
|
-
```
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
### Plan Challenge — Critic Agent
|
|
2
|
-
|
|
3
|
-
**Guard**: Verify critic agent file exists before spawning:
|
|
4
|
-
```powershell
|
|
5
|
-
if (Test-Path -LiteralPath "{{CRITIC_SUBAGENT_PATH}}") { "CRITIC:READY" } else { "CRITIC:MISSING" }
|
|
6
|
-
```
|
|
7
|
-
If CRITIC:MISSING — skip this phase entirely and proceed. Log: "Critic agent not installed — skipping Plan Challenge."
|
|
8
|
-
|
|
9
|
-
**Spawn Agent**:
|
|
10
|
-
| Parameter | Value |
|
|
11
|
-
|-----------|-------|
|
|
12
|
-
| subagent_type | prizm-dev-team-critic |
|
|
13
|
-
| mode | plan |
|
|
14
|
-
| run_in_background | false |
|
|
15
|
-
|
|
16
|
-
**Prompt**:
|
|
17
|
-
> {{AGENT_PROMPT_CRITIC_PLAN_CHALLENGE}}
|
|
18
|
-
|
|
19
|
-
**Agent spawn failure policy**:
|
|
20
|
-
- If spawning Critic fails with team/config/lock errors, retry at most once.
|
|
21
|
-
- If the second attempt fails, do not keep spawning variants. Either create the required team once (when team tooling is available) or perform the plan challenge inline and write `challenge-report.md` yourself.
|
|
22
|
-
- Record the fallback in the report; do not burn multiple minutes on repeated identical spawn failures.
|
|
23
|
-
|
|
24
|
-
**No silent report polling**:
|
|
25
|
-
- Do NOT run a long no-output loop waiting for `challenge-report.md`.
|
|
26
|
-
- If you need to wait for the report file, use a short bounded check (≤120s) that prints elapsed time and whether the report exists on every iteration.
|
|
27
|
-
- If the report is still missing after the bounded check, request one status update; if still missing, perform the challenge inline and continue.
|
|
28
|
-
|
|
29
|
-
Wait for Critic to return.
|
|
30
|
-
- Read challenge-report.md. For items marked CRITICAL/HIGH: decide whether to adjust plan.md or document why the plan stands.
|
|
31
|
-
- Max 1 plan revision round.
|
|
32
|
-
|
|
33
|
-
**CP-2.5**: Plan challenges reviewed and resolved.
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
**Checkpoint update**: Run the update script to set step `critic-plan-review` to `"completed"`:
|
|
37
|
-
```powershell
|
|
38
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
39
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
40
|
-
--step critic-plan-review `
|
|
41
|
-
--status completed
|
|
42
|
-
```
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
### Implement — Dev Subagent
|
|
2
|
-
|
|
3
|
-
**Protocol handoff to Dev**: The Dev prompt already carries the required subset of Context Budget Rules, the Test Failure Recovery Protocol, and Task Contract / Verification Gate constraints. Do not duplicate those rules here; verify Dev output against the gates below.
|
|
4
|
-
|
|
5
|
-
**Spawn Agent**:
|
|
6
|
-
| Parameter | Value |
|
|
7
|
-
|-----------|-------|
|
|
8
|
-
| subagent_type | prizm-dev-team-dev |
|
|
9
|
-
| run_in_background | false |
|
|
10
|
-
| isolation | Leave empty — Dev works directly in the repo, no worktree |
|
|
11
|
-
|
|
12
|
-
**Agent spawn failure policy**:
|
|
13
|
-
- If spawning Dev fails with team/config/lock errors, retry at most once.
|
|
14
|
-
- If the second attempt fails, do not enter Implementation Log polling or repeated recovery spawn loops.
|
|
15
|
-
- Use the documented inline/recovery fallback: write `failure-log.md` with the spawn error and last observable state, then either complete remaining tasks directly in the orchestrator or stop with a clear failure for recovery.
|
|
16
|
-
- Apply the same cap to Dev re-spawns for Implementation Log repair or resume prompts; do not burn multiple minutes on identical team/config/lock failures.
|
|
17
|
-
|
|
18
|
-
**Prompt**:
|
|
19
|
-
> {{AGENT_PROMPT_DEV_IMPLEMENT}}
|
|
20
|
-
|
|
21
|
-
Wait for Dev to return. Implementation may proceed only when tasks are complete and the Test Failure Recovery Protocol's Success Rule is satisfied.
|
|
22
|
-
|
|
23
|
-
**No silent artifact polling**:
|
|
24
|
-
- Do NOT run a long no-output loop that only waits for `## Implementation Log` or any other file marker.
|
|
25
|
-
- If you must wait for Dev after spawning or sending a status request, use short bounded checks (≤120s) that print a heartbeat line each iteration with: elapsed time, remaining unchecked task count, whether `## Implementation Log` exists, and whether `git diff --stat` changed.
|
|
26
|
-
- If Dev has no transcript/file/diff progress for one bounded check, send one status request. If there is still no progress on the next bounded check, stop waiting, write `failure-log.md` with the last observable state, and follow Subagent Timeout Recovery.
|
|
27
|
-
- Prefer the Agent tool's completion notification or Dev's `COMPLETION_SIGNAL`; file presence alone is not a liveness signal.
|
|
28
|
-
|
|
29
|
-
**Gate Check — Implementation Log**:
|
|
30
|
-
After Dev agent returns, verify the Implementation Log was written:
|
|
31
|
-
```powershell
|
|
32
|
-
$contextSnapshot = '.prizmkit\specs\{{FEATURE_SLUG}}\context-snapshot.md'
|
|
33
|
-
if ((Test-Path $contextSnapshot) -and (Select-String -Path $contextSnapshot -Pattern '## Implementation Log' -Quiet)) { "GATE:PASS" } else { "GATE:MISSING" }
|
|
34
|
-
```
|
|
35
|
-
If GATE:MISSING — send message to Dev (re-spawn if needed): "Write the '## Implementation Log' section to context-snapshot.md before I can proceed to review. Include: files changed/created, key decisions, deviations from plan, notable discoveries."
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-implement` to `"completed"`:
|
|
39
|
-
```powershell
|
|
40
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
41
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
42
|
-
--step prizmkit-implement `
|
|
43
|
-
--status completed
|
|
44
|
-
```
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
### Implement — Dev Agent
|
|
2
|
-
|
|
3
|
-
**Protocol handoff to Dev**: The Dev prompt already carries the required subset of Context Budget Rules, the Test Failure Recovery Protocol, and Task Contract / Verification Gate constraints. Do not duplicate those rules here; verify Dev output against the gates below.
|
|
4
|
-
|
|
5
|
-
Before spawning Dev, check plan.md Tasks section:
|
|
6
|
-
```powershell
|
|
7
|
-
if (Test-Path -LiteralPath ".prizmkit/specs/{{FEATURE_SLUG}}/plan.md") {
|
|
8
|
-
(Select-String -Path ".prizmkit/specs/{{FEATURE_SLUG}}/plan.md" -Pattern '^- \[ \]' -ErrorAction SilentlyContinue).Count
|
|
9
|
-
} else {
|
|
10
|
-
0
|
|
11
|
-
}
|
|
12
|
-
```
|
|
13
|
-
- If result is `0` (all tasks already `[x]`) → **SKIP this phase**, go directly to Review. Do NOT spawn Dev.
|
|
14
|
-
- If result is non-zero → spawn Dev agent below.
|
|
15
|
-
|
|
16
|
-
**Spawn Agent**:
|
|
17
|
-
| Parameter | Value |
|
|
18
|
-
|-----------|-------|
|
|
19
|
-
| subagent_type | prizm-dev-team-dev |
|
|
20
|
-
| run_in_background | false |
|
|
21
|
-
|
|
22
|
-
**Agent spawn failure policy**:
|
|
23
|
-
- If spawning Dev fails with team/config/lock errors, retry at most once.
|
|
24
|
-
- If the second attempt fails, do not enter Implementation Log polling or repeated recovery spawn loops.
|
|
25
|
-
- Use the documented inline/recovery fallback: write `failure-log.md` with the spawn error and last observable state, then either complete remaining tasks directly in the orchestrator or stop with a clear failure for recovery.
|
|
26
|
-
- Apply the same cap to Dev re-spawns for Implementation Log repair or resume prompts; do not burn multiple minutes on identical team/config/lock failures.
|
|
27
|
-
|
|
28
|
-
**Prompt**:
|
|
29
|
-
> {{AGENT_PROMPT_DEV_IMPLEMENT}}
|
|
30
|
-
|
|
31
|
-
**No silent artifact polling**:
|
|
32
|
-
- Do NOT run a long no-output loop that only waits for `## Implementation Log` or any other file marker.
|
|
33
|
-
- If you must wait for Dev after spawning or sending a status request, use short bounded checks (≤120s) that print a heartbeat line each iteration with: elapsed time, remaining unchecked task count, whether `## Implementation Log` exists, and whether `git diff --stat` changed.
|
|
34
|
-
- If Dev has no transcript/file/diff progress for one bounded check, send one status request. If there is still no progress on the next bounded check, stop waiting, write `failure-log.md` with the last observable state, and follow Subagent Timeout Recovery.
|
|
35
|
-
- Prefer the Agent tool's completion notification or Dev's `COMPLETION_SIGNAL`; file presence alone is not a liveness signal.
|
|
36
|
-
|
|
37
|
-
**Gate Check — Implementation Log**:
|
|
38
|
-
After Dev agent returns, verify the Implementation Log was written:
|
|
39
|
-
```powershell
|
|
40
|
-
if (Select-String -Path ".prizmkit/specs/{{FEATURE_SLUG}}/context-snapshot.md" -Pattern "## Implementation Log" -Quiet -ErrorAction SilentlyContinue) { "GATE:PASS" } else { "GATE:MISSING" }
|
|
41
|
-
```
|
|
42
|
-
If GATE:MISSING — send message to Dev (re-spawn if needed): "Write the '## Implementation Log' section to context-snapshot.md before I can proceed to review. Include: files changed/created, key decisions, deviations from plan, notable discoveries."
|
|
43
|
-
|
|
44
|
-
Wait for Dev to return. **If Dev times out before all tasks are `[x]`**:
|
|
45
|
-
1. Check progress: `(Select-String -Path ".prizmkit/specs/{{FEATURE_SLUG}}/plan.md" -Pattern '^- \[ \]' -ErrorAction SilentlyContinue).Count`
|
|
46
|
-
2. If any tasks remain: re-spawn Dev with this recovery prompt:
|
|
47
|
-
> {{AGENT_PROMPT_DEV_RESUME}}
|
|
48
|
-
3. Max 2 recovery retries. After 2 failures, orchestrator implements remaining tasks directly.
|
|
49
|
-
|
|
50
|
-
Implementation phase is complete only when all tasks are `[x]` and the Test Failure Recovery Protocol's Success Rule is satisfied.
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-implement` to `"completed"`:
|
|
54
|
-
```powershell
|
|
55
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
56
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
57
|
-
--step prizmkit-implement `
|
|
58
|
-
--status completed
|
|
59
|
-
```
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
### Implement + Test
|
|
2
|
-
|
|
3
|
-
**Protocol references**:
|
|
4
|
-
- Follow Context Budget Rules §8 for scaffold/generated files.
|
|
5
|
-
- Follow Context Budget Rules §9 before package install/build commands that resolve dependencies.
|
|
6
|
-
- Follow Context Budget Rules §10 after build/compile commands.
|
|
7
|
-
|
|
8
|
-
**3a.** Detect test commands and record baseline:
|
|
9
|
-
|
|
10
|
-
You know this project's tech stack. Identify ALL test commands that apply (e.g., `go test ./...`, `npm test`, `cargo test`, `pytest`, `make test`, etc.). Record them as `TEST_CMDS`. Then record baseline:
|
|
11
|
-
```powershell
|
|
12
|
-
# Run each test command, capture output
|
|
13
|
-
& { {{TEST_CMD}} } 2>&1 | Tee-Object (Join-Path $env:TEMP "test-baseline.txt") | Select-Object -Last 20
|
|
14
|
-
```
|
|
15
|
-
|
|
16
|
-
**3b.** Run `/prizmkit-implement` — this handles the full implementation cycle:
|
|
17
|
-
- Reads plan.md Tasks section from `.prizmkit/specs/{{FEATURE_SLUG}}/`
|
|
18
|
-
- Reads context from `context-snapshot.md` (Prizm docs, TRAPS, file manifest)
|
|
19
|
-
- Implements task-by-task with TDD, marking each `[x]` immediately
|
|
20
|
-
- Creates/updates L2 `.prizm` docs when creating new modules or significantly modifying existing ones — AI selectively decides the modules that warrant L2 based on complexity and importance
|
|
21
|
-
- Runs tests using `TEST_CMD` after each task
|
|
22
|
-
- Writes '## Implementation Log' to `context-snapshot.md`
|
|
23
|
-
|
|
24
|
-
**3c.** After implement completes, verify:
|
|
25
|
-
1. All tasks in plan.md are `[x]`
|
|
26
|
-
2. Run the full test suite to ensure no new regressions remain
|
|
27
|
-
3. Verify each Verification Gate from the Task Contract — check mentally, do NOT re-read files you already wrote
|
|
28
|
-
4. If any gate is unmet or blocked, follow the Test Failure Recovery Protocol
|
|
29
|
-
|
|
30
|
-
**CP-2**: Implementation may proceed only when all tasks are `[x]` and the Test Failure Recovery Protocol's Success Rule is satisfied. Blocked gates must be documented in `failure-log.md` and are not success.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-implement` to `"completed"`:
|
|
34
|
-
```powershell
|
|
35
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
36
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
37
|
-
--step prizmkit-implement `
|
|
38
|
-
--status completed
|
|
39
|
-
```
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
### Plan & Tasks
|
|
2
|
-
|
|
3
|
-
```powershell
|
|
4
|
-
Test-Path -LiteralPath ".prizmkit/specs/{{FEATURE_SLUG}}/plan.md"
|
|
5
|
-
```
|
|
6
|
-
|
|
7
|
-
If missing, run `/prizmkit-plan` with `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/` to generate `plan.md`:
|
|
8
|
-
- The plan.md should include: architecture — components, interfaces, data flow, files to create/modify, testing approach, and a Tasks section with `[ ]` checkboxes ordered by dependency.
|
|
9
|
-
- Resolve any `[NEEDS CLARIFICATION]` markers using the feature description — do NOT pause for interactive input.
|
|
10
|
-
|
|
11
|
-
**Database Design Gate** (if feature involves data persistence — new tables, schema changes, new entities):
|
|
12
|
-
Before proceeding past CP-1, verify:
|
|
13
|
-
1. Plan.md Data Model section references existing schema/model files (scan for `*.prisma`, `*.sql`, `migrations/`, `models/`, `*.entity.*` files; read them if not already in context-snapshot)
|
|
14
|
-
2. All new tables/fields follow existing naming conventions, ID strategy, timestamp patterns, and constraint style
|
|
15
|
-
3. No `[NEEDS CLARIFICATION]` remains in Data Model section — resolve by reading existing code and making a conservative choice that matches existing patterns. Document the resolution in plan.md.
|
|
16
|
-
4. If a DB design decision genuinely cannot be resolved from existing code alone, document the assumption made and flag it in the Implementation Log for user review.
|
|
17
|
-
|
|
18
|
-
**CP-1**: plan.md exists with Tasks section.
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-plan` to `"completed"`:
|
|
22
|
-
```powershell
|
|
23
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
24
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
25
|
-
--step prizmkit-plan `
|
|
26
|
-
--status completed
|
|
27
|
-
```
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
### Plan & Tasks
|
|
2
|
-
|
|
3
|
-
```powershell
|
|
4
|
-
Get-ChildItem -LiteralPath ".prizmkit/specs/{{FEATURE_SLUG}}/" -ErrorAction SilentlyContinue
|
|
5
|
-
```
|
|
6
|
-
|
|
7
|
-
If plan.md missing, run `/prizmkit-plan` with `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/`:
|
|
8
|
-
- Pass the Objective and Verification Gates from the Task Contract as input
|
|
9
|
-
- The plan.md should include: key components, data flow, files to create/modify, and a Tasks section with `[ ]` checkboxes (each task = one implementable unit). Keep under 80 lines.
|
|
10
|
-
- Resolve any `[NEEDS CLARIFICATION]` markers using the feature description — do NOT pause for interactive input.
|
|
11
|
-
|
|
12
|
-
**Database Design Gate** (if feature involves data persistence — new tables, schema changes, new entities):
|
|
13
|
-
Before proceeding past CP-1:
|
|
14
|
-
1. Scan for existing schema files (`*.prisma`, `*.sql`, `migrations/`, `models/`, `*.entity.*`) and read them
|
|
15
|
-
2. Ensure new tables/fields follow existing naming conventions and constraint patterns
|
|
16
|
-
3. Resolve all uncertain DB design decisions before writing Tasks — document choices in plan.md
|
|
17
|
-
|
|
18
|
-
**CP-1**: plan.md exists with Tasks section.
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-plan` to `"completed"`:
|
|
22
|
-
```powershell
|
|
23
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
24
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
25
|
-
--step prizmkit-plan `
|
|
26
|
-
--status completed
|
|
27
|
-
```
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
### Scoped Feature Test Gate — PrizmKit Test
|
|
2
|
-
|
|
3
|
-
**Goal**: Generate and verify tests for this feature's changed scope before code review without embedding the full gate implementation in this prompt.
|
|
4
|
-
|
|
5
|
-
Create a start marker immediately before invoking the skill so the gate can reject stale reports from older sessions:
|
|
6
|
-
|
|
7
|
-
```powershell
|
|
8
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\prizmkit-test-gate.py start `
|
|
9
|
-
--feature-slug "{{FEATURE_SLUG}}"
|
|
10
|
-
```
|
|
11
|
-
|
|
12
|
-
Run `/prizmkit-test` with the feature artifact directory:
|
|
13
|
-
|
|
14
|
-
```text
|
|
15
|
-
/prizmkit-test scope=this-change artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
Rules:
|
|
19
|
-
- This gate is feature-pipeline only. Do NOT use `.prizmkit/bugfix/` or `.prizmkit/refactor/` artifact directories here.
|
|
20
|
-
- Generate or update tests only for this feature's changed files, changed public interfaces, and acceptance criteria.
|
|
21
|
-
- Record unrelated historical coverage gaps under `Out of Scope Gaps`; do not generate tests for them and do not fail this feature because of them.
|
|
22
|
-
- If generated tests fail because implementation is wrong, fix implementation within this feature scope and rerun the affected tests.
|
|
23
|
-
- If failures are baseline or unrelated to this feature, document them in the report and continue only when no in-scope failure remains unexplained.
|
|
24
|
-
|
|
25
|
-
**Gate Check — Test Report**:
|
|
26
|
-
After `/prizmkit-test` returns, run the gate script to locate the newest current-run report, validate scope/freshness/boundary coverage, write `test-report-path.txt`, and mark the `prizmkit-test` checkpoint completed only on `GATE:PASS`:
|
|
27
|
-
|
|
28
|
-
```powershell
|
|
29
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\prizmkit-test-gate.py check `
|
|
30
|
-
--feature-slug "{{FEATURE_SLUG}}" `
|
|
31
|
-
--artifact-dir ".prizmkit/specs/{{FEATURE_SLUG}}/" `
|
|
32
|
-
--checkpoint-path "{{CHECKPOINT_PATH}}"
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
Gate outcomes:
|
|
36
|
-
- `GATE:PASS` → append the report path and a 3-5 bullet summary to `context-snapshot.md` under `## PrizmKit Test Gate`, then proceed to the next checkpoint step. The gate script already wrote `test-report-path.txt` and marked `prizmkit-test` completed.
|
|
37
|
-
- `GATE:FAIL` with `NEEDS_FIXES` → read the report's `In-Scope Failures`, fix the feature implementation or generated tests within this feature scope, rerun `/prizmkit-test`, and repeat the gate check. Do not proceed to code review while the verdict is not `PASS`.
|
|
38
|
-
- `GATE:FAIL` with `BLOCKED`, wrong mode, wrong artifact dir, unreadable report, stale scope, boundary failure, validator failure, or checkpoint update failure → write `.prizmkit/specs/{{FEATURE_SLUG}}/failure-log.md` with the scoped test failure and stop for recovery.
|
|
39
|
-
- `GATE:MISSING` → perform one bounded status check: inspect `/prizmkit-test` output and `.prizmkit/test/` for a report directory. If no current-run report exists, write `failure-log.md` and stop for recovery.
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
### Review — Code Review
|
|
2
|
-
|
|
3
|
-
Precondition: the `prizmkit-test` checkpoint is completed and `.prizmkit/specs/{{FEATURE_SLUG}}/test-report-path.txt` points to the scoped test report.
|
|
4
|
-
|
|
5
|
-
Before invoking review, read `.prizmkit/specs/{{FEATURE_SLUG}}/test-report-path.txt`, read the referenced `/prizmkit-test` report, and confirm the summary in `context-snapshot.md` under `## PrizmKit Test Gate` matches it. The code-review skill must receive this context through `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/` and the Reviewer must assess generated/updated test quality, `In-Scope Failures`, `Baseline Failures`, `Out of Scope Gaps`, boundary coverage if present, and the scoped report verdict.
|
|
6
|
-
|
|
7
|
-
Run `/prizmkit-code-review` with `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/`.
|
|
8
|
-
|
|
9
|
-
The skill runs an internal review-fix loop (Reviewer Agent → filter → Dev Agent fix, max 3 rounds) and writes `review-report.md` to the artifact directory.
|
|
10
|
-
|
|
11
|
-
**Gate Check — Review Report**:
|
|
12
|
-
After `/prizmkit-code-review` returns, verify the review report:
|
|
13
|
-
```powershell
|
|
14
|
-
if (Select-String -Path ".prizmkit/specs/{{FEATURE_SLUG}}/review-report.md" -Pattern "## Verdict" -Quiet -ErrorAction SilentlyContinue) { "GATE:PASS" } else { "GATE:MISSING" }
|
|
15
|
-
```
|
|
16
|
-
If GATE:MISSING:
|
|
17
|
-
- Do not re-run `/prizmkit-code-review` in an unbounded report-repair loop.
|
|
18
|
-
- Perform one bounded status check; retry at most once: inspect the skill output, `review-report.md` path, and any Reviewer/Dev spawn messages.
|
|
19
|
-
- If the missing report is caused by team/config/lock errors from the internal Reviewer/Dev agent spawn, retry `/prizmkit-code-review` at most once only if it appears transient.
|
|
20
|
-
- If the report is still missing after that single check/retry, write `failure-log.md` with the spawn/skill error and last observable state, then either perform a safe inline fallback review (spec/plan/diff/tests → write `review-report.md` with `## Verdict`) or stop with a clear recovery failure.
|
|
21
|
-
|
|
22
|
-
Read `review-report.md` and check the Verdict:
|
|
23
|
-
- `PASS` → proceed to next phase
|
|
24
|
-
- `NEEDS_FIXES` → the skill exhausted its max rounds; log the remaining findings and proceed (do not retry externally)
|
|
25
|
-
|
|
26
|
-
**CP-3**: Review complete, report written.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-code-review` to `"completed"`:
|
|
30
|
-
```powershell
|
|
31
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
32
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
33
|
-
--step prizmkit-code-review `
|
|
34
|
-
--status completed
|
|
35
|
-
```
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
### Review — Code Review
|
|
2
|
-
|
|
3
|
-
Precondition: the `prizmkit-test` checkpoint is completed and `.prizmkit/specs/{{FEATURE_SLUG}}/test-report-path.txt` points to the scoped test report.
|
|
4
|
-
|
|
5
|
-
Before invoking review, read `.prizmkit/specs/{{FEATURE_SLUG}}/test-report-path.txt`, read the referenced `/prizmkit-test` report, and confirm the summary in `context-snapshot.md` under `## PrizmKit Test Gate` matches it. The code-review skill must receive this context through `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/` and the Reviewer must assess generated/updated test quality, `In-Scope Failures`, `Baseline Failures`, `Out of Scope Gaps`, boundary coverage if present, and the scoped report verdict.
|
|
6
|
-
|
|
7
|
-
Run `/prizmkit-code-review` with `artifact_dir=.prizmkit/specs/{{FEATURE_SLUG}}/`.
|
|
8
|
-
|
|
9
|
-
The skill runs an internal review-fix loop (Reviewer Agent → filter → Dev Agent fix, max 3 rounds) and writes `review-report.md` to the artifact directory.
|
|
10
|
-
|
|
11
|
-
**Gate Check — Review Report**:
|
|
12
|
-
After `/prizmkit-code-review` returns, verify the review report:
|
|
13
|
-
```powershell
|
|
14
|
-
if (Select-String -Path ".prizmkit/specs/{{FEATURE_SLUG}}/review-report.md" -Pattern "## Verdict" -Quiet -ErrorAction SilentlyContinue) { "GATE:PASS" } else { "GATE:MISSING" }
|
|
15
|
-
```
|
|
16
|
-
If GATE:MISSING:
|
|
17
|
-
- Do not re-run `/prizmkit-code-review` in an unbounded report-repair loop.
|
|
18
|
-
- Perform one bounded status check; retry at most once: inspect the skill output, `review-report.md` path, and any Reviewer/Dev spawn messages.
|
|
19
|
-
- If the missing report is caused by team/config/lock errors from the internal Reviewer/Dev agent spawn, retry `/prizmkit-code-review` at most once only if it appears transient.
|
|
20
|
-
- If the report is still missing after that single check/retry, write `failure-log.md` with the spawn/skill error and last observable state, then either perform a safe inline fallback review (spec/plan/diff/tests → write `review-report.md` with `## Verdict`) or stop with a clear recovery failure.
|
|
21
|
-
|
|
22
|
-
Read `review-report.md` and check the Verdict:
|
|
23
|
-
- `PASS` → proceed to next phase
|
|
24
|
-
- `NEEDS_FIXES` → the skill exhausted its max rounds; log the remaining findings and proceed (do not retry externally)
|
|
25
|
-
|
|
26
|
-
**CP-3**: Review complete, report written.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
**Checkpoint update**: Run the update script to set step `prizmkit-code-review` to `"completed"`:
|
|
30
|
-
```powershell
|
|
31
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
32
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
33
|
-
--step prizmkit-code-review `
|
|
34
|
-
--status completed
|
|
35
|
-
```
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
### Specify + Plan (Full Workflow)
|
|
2
|
-
|
|
3
|
-
Check existing artifacts first:
|
|
4
|
-
```powershell
|
|
5
|
-
if (Test-Path .prizmkit\specs\{{FEATURE_SLUG}}) { Get-ChildItem .prizmkit\specs\{{FEATURE_SLUG}} | Select-Object -ExpandProperty Name } else { "MISSING" }
|
|
6
|
-
```
|
|
7
|
-
|
|
8
|
-
- Both (spec.md, plan.md) exist → **SKIP to CP-1**
|
|
9
|
-
- `context-snapshot.md` exists → use it directly, skip context snapshot building
|
|
10
|
-
- Some missing → generate only missing files
|
|
11
|
-
|
|
12
|
-
**Step A — Build Context Snapshot** (skip if `context-snapshot.md` already exists):
|
|
13
|
-
|
|
14
|
-
1. Read `.prizmkit/prizm-docs/root.prizm` and relevant L1/L2 prizm docs
|
|
15
|
-
2. Detect source code directories: read KEY_FILES and STRUCTURE sections from `root.prizm` to identify where source code lives (e.g. `src/`, `app/`, `lib/`, `cmd/`, `packages/`, or project root). If `root.prizm` is missing, scan the project tree:
|
|
16
|
-
```powershell
|
|
17
|
-
Get-ChildItem -Path . -File -Recurse -Depth 2 -Include *.js,*.ts,*.py,*.go,*.java,*.rb,*.rs -ErrorAction SilentlyContinue |
|
|
18
|
-
Where-Object { $_.FullName -notmatch '\\(node_modules|\.git|dist|build|vendor)(\\|$)' } |
|
|
19
|
-
Select-Object -First 30 -ExpandProperty FullName
|
|
20
|
-
```
|
|
21
|
-
Identify the top-level source directories from the results.
|
|
22
|
-
3. Scan the detected source directories for files related to this feature; read each one
|
|
23
|
-
4. Write `.prizmkit/specs/{{FEATURE_SLUG}}/context-snapshot.md`:
|
|
24
|
-
- **Section 1 — Feature Brief**: feature description (copy from Task Contract above, 2-3 lines only)
|
|
25
|
-
- **Section 2 — Verification Gates**: copy the gate checklist from the Task Contract above
|
|
26
|
-
- **Section 3 — Key TRAPS & RULES**: extract TRAPS and RULES entries from loaded prizm-docs that apply to files in this feature's scope. Do NOT copy full L0/L1/L2 content — only the specific TRAPS/RULES lines relevant to the files listed in Section 4.
|
|
27
|
-
- **Section 4 — File Manifest**: For each file relevant to this feature, list path, why needed (modify/reference/test), key interface signatures. Do NOT include full file content. Format:
|
|
28
|
-
### Files to Modify
|
|
29
|
-
| File | Why Needed | Key Interfaces |
|
|
30
|
-
|------|-----------|----------------|
|
|
31
|
-
| `<source-dir>/config.js` | Add runtime config layer | `config` (Zod object), `configSchema` |
|
|
32
|
-
|
|
33
|
-
### Files for Reference
|
|
34
|
-
| File | Why Needed | Key Interfaces |
|
|
35
|
-
|------|-----------|----------------|
|
|
36
|
-
| `<source-dir>/security/permission-guard.js` | Permission check integration | `checkCommandPermission(userId, cmd)` |
|
|
37
|
-
|
|
38
|
-
### Known TRAPS (from .prizmkit/prizm-docs/)
|
|
39
|
-
- <trap entries extracted from L1/L2 docs>
|
|
40
|
-
5. Confirm with PowerShell: `if (Test-Path .prizmkit\specs\{{FEATURE_SLUG}}\context-snapshot.md) { "EXISTS" } else { "MISSING" }`
|
|
41
|
-
|
|
42
|
-
**After Step A**: Use context-snapshot.md Section 4 File Manifest to guide targeted file reads. Do NOT scan directories or read unrelated files.
|
|
43
|
-
|
|
44
|
-
**Step B — Planning Artifacts** (generate only missing files):
|
|
45
|
-
|
|
46
|
-
```powershell
|
|
47
|
-
@('.prizmkit\specs\{{FEATURE_SLUG}}\spec.md', '.prizmkit\specs\{{FEATURE_SLUG}}\plan.md') | ForEach-Object {
|
|
48
|
-
if (Test-Path $_) { $_ }
|
|
49
|
-
}
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
- spec.md missing: Run `/prizmkit-plan` → generate spec.md. Resolve any `[NEEDS CLARIFICATION]` markers using the task description — do NOT pause for interactive input.
|
|
53
|
-
- plan.md missing: Run `/prizmkit-plan` → generate plan.md (change approach, components, interface design, data model, testing strategy, risk assessment, and Tasks section with `[ ]` checkboxes)
|
|
54
|
-
|
|
55
|
-
> All files go under `.prizmkit/specs/{{FEATURE_SLUG}}/`. Confirm each with `Test-Path` after writing.
|
|
56
|
-
|
|
57
|
-
**Database Design Gate** (if feature involves data persistence — new tables, schema changes, new entities):
|
|
58
|
-
Before proceeding past CP-1, verify:
|
|
59
|
-
1. Plan.md Data Model section references existing schema/model files (scan for `*.prisma`, `*.sql`, `migrations/`, `models/`, `*.entity.*` files; read them if not already in context-snapshot)
|
|
60
|
-
2. All new tables/fields follow existing naming conventions, ID strategy, timestamp patterns, and constraint style
|
|
61
|
-
3. No `[NEEDS CLARIFICATION]` remains in Data Model section — resolve by reading existing code and making a conservative choice that matches existing patterns. Document the resolution in plan.md.
|
|
62
|
-
4. If a DB design decision genuinely cannot be resolved from existing code alone, document the assumption made and flag it in the Implementation Log for user review.
|
|
63
|
-
|
|
64
|
-
**CP-1**: Both spec.md and plan.md exist.
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
**Checkpoint update**: Run the update script to set step `context-snapshot-and-plan` to `"completed"`:
|
|
68
|
-
```powershell
|
|
69
|
-
Invoke-PrizmPython {{PIPELINE_DIR}}\scripts\update-checkpoint.py `
|
|
70
|
-
--checkpoint-path {{CHECKPOINT_PATH}} `
|
|
71
|
-
--step context-snapshot-and-plan `
|
|
72
|
-
--status completed
|
|
73
|
-
```
|