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,14 +0,0 @@
|
|
|
1
|
-
# Operation: Status — Detailed Steps
|
|
2
|
-
|
|
3
|
-
Check freshness of all .prizm docs.
|
|
4
|
-
|
|
5
|
-
PRECONDITION: .prizmkit/prizm-docs/ exists with root.prizm.
|
|
6
|
-
|
|
7
|
-
STEPS:
|
|
8
|
-
1. Get last git modification time of root.prizm via `git log -1 --format="%ai" -- .prizmkit/prizm-docs/root.prizm`.
|
|
9
|
-
2. Count commits since that time via `git log --since="<timestamp>" --oneline | wc -l`.
|
|
10
|
-
3. For each L1/L2 doc, compare git modification time of the .prizm file (`git log -1 --format="%ai" -- <prizm-file>`) against latest git modification of source files in that module (`git log -1 --format="%ai" -- <module-path>/`).
|
|
11
|
-
4. Classify each doc as: FRESH (prizm file updated after latest source change), STALE (source changed more recently than prizm file), MISSING (module exists but no .prizm doc).
|
|
12
|
-
5. Flag any docs exceeding size limits.
|
|
13
|
-
|
|
14
|
-
OUTPUT: Freshness report table with columns: DOC_PATH | LEVEL | STATUS | PRIZM_LAST_MOD | SOURCE_LAST_MOD.
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
# Operation: Update — Detailed Steps
|
|
2
|
-
|
|
3
|
-
Update .prizmkit/prizm-docs/ to reflect recent code changes.
|
|
4
|
-
|
|
5
|
-
PRECONDITION: .prizmkit/prizm-docs/ exists with root.prizm.
|
|
6
|
-
|
|
7
|
-
STEPS:
|
|
8
|
-
1. Get changed files via `git diff --cached --name-status`. If nothing staged, use `git diff --name-status`. If no git changes at all, do full rescan comparing code against existing docs — this includes checking for modules that have source files but no L2 doc.
|
|
9
|
-
2. Map changed files to modules by matching against MODULE_INDEX or MODULE_GROUPS in root.prizm. Group changes by module.
|
|
10
|
-
3. Classify each change: A (added) -> new KEY_FILES entries. D (deleted) -> remove entries, update counts. M (modified) -> check dependency changes. R (renamed) -> update all path references.
|
|
11
|
-
4. Update affected docs: L2 first (KEY_FILES, INTERFACES, DATA_FLOW, DEPENDENCIES, TRAPS, DECISIONS), then L1 (FILES count, KEY_FILES, DEPENDENCIES — L1 does NOT contain INTERFACES/DATA_FLOW/TRAPS/DECISIONS), then L0 (MODULE_INDEX or MODULE_GROUPS counts, CROSS_CUTTING) only if structural change. Do not write CHANGELOG sections/files, UPDATED/date metadata, feature/bug/refactor/task/session/run/pipeline/workflow IDs, branch names, absolute worktree paths, or `.prizmkit/specs` / `.prizmkit/dev-pipeline` artifact paths — git tracks history. **Preserve** any `PROJECT_BRIEF:` line in root.prizm — it is managed by prizmkit-init, not by this skill.
|
|
12
|
-
5. Skip updates if: only internal implementation changed (no interface/dependency change), only comments/whitespace/formatting, only .prizm files changed. DO NOT skip test file changes or bug fixes — they may reveal TRAPS worth capturing in L2.
|
|
13
|
-
6. If new directory qualifies as a module (per MODULE_DISCOVERY_CRITERIA) and matches no existing module: create L1 immediately, add to MODULE_INDEX. If the current diff includes Added or Modified source files in this module → also create L2 immediately with sections: MODULE, FILES, RESPONSIBILITY, INTERFACES, DATA_FLOW, KEY_FILES, DEPENDENCIES, RULES, TRAPS, DECISIONS. Otherwise defer L2.
|
|
14
|
-
6a. **L2 gap check** (runs during full rescan mode only — when no git changes detected): For each existing module in MODULE_INDEX, check if L2 doc exists. If L2 is missing and the module has source files with meaningful logic (not trivial config/wrapper) → create L2 with sections: MODULE, FILES, RESPONSIBILITY, INTERFACES, DATA_FLOW, KEY_FILES, DEPENDENCIES, RULES, TRAPS, DECISIONS. This ensures Update fills documentation gaps left by previous sessions.
|
|
15
|
-
7. Enforce size limits: L0 > 4KB -> consolidate. L1 > 4KB -> trim KEY_FILES descriptions, ensure RULES <= 3 entries. L2 > 5KB -> trim non-essential derived detail or split oversized cross-cutting detail.
|
|
16
|
-
7a. Validate memory hygiene: no CHANGELOG/UPDATED fields, no workflow metadata, no L1 behavioral sections.
|
|
17
|
-
8. Stage updated .prizm files via `git add .prizmkit/prizm-docs/`
|
|
18
|
-
|
|
19
|
-
OUTPUT: List of updated/created/skipped docs with reasons.
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
# Operation: Validate — Detailed Steps
|
|
2
|
-
|
|
3
|
-
Check format compliance and consistency of all .prizm docs.
|
|
4
|
-
|
|
5
|
-
PRECONDITION: .prizmkit/prizm-docs/ exists.
|
|
6
|
-
|
|
7
|
-
STEPS:
|
|
8
|
-
1. FORMAT CHECK: Verify all .prizm files use KEY: value format. Flag any prose paragraphs, code blocks (```), markdown headers (##), emoji, ASCII art, or horizontal rules. Flag TRAPS entries missing severity prefix ([CRITICAL], [HIGH], or [LOW]). Flag CHANGELOG sections/files, UPDATED/date metadata, feature/bug/refactor/task/session/run/pipeline/workflow IDs, branch names, absolute worktree paths, and `.prizmkit/specs` / `.prizmkit/dev-pipeline` artifact paths as auxiliary noise. Note: [REVIEW] preceding severity (e.g., `[REVIEW][HIGH]`) is a valid temporary staleness marker, not a format violation.
|
|
9
|
-
2. SIZE CHECK: Verify size limits: L0 <= 4KB, L1 <= 4KB, L2 <= 5KB. Report files exceeding limits with current size.
|
|
10
|
-
3. POINTER CHECK: Verify all arrow (->) references resolve to existing .prizm files. Report broken pointers.
|
|
11
|
-
4. STALENESS CHECK: Compare git modification time of each .prizm file against source directory. Flag docs where source was modified more recently.
|
|
12
|
-
5. COMPLETENESS CHECK: Verify root.prizm has all required fields (PRIZM_VERSION, PROJECT, LANG, MODULE_INDEX or MODULE_GROUPS). Verify L1 docs have MODULE, FILES, RESPONSIBILITY, DEPENDENCIES (no INTERFACES/TRAPS/DECISIONS). Verify L2 docs have MODULE, FILES, KEY_FILES, DEPENDENCIES, INTERFACES, TRAPS.
|
|
13
|
-
6. ANTI-PATTERN CHECK: Flag duplicate information across levels, implementation details in L0/L1, TODO items, session-specific context, changelog/history sections, and workflow metadata.
|
|
14
|
-
7. RULES HIERARCHY CHECK: Verify L1/L2 RULES do not contradict root.prizm RULES. L1/L2 may only supplement with module-specific exceptions.
|
|
15
|
-
8. TRAPS STALENESS CHECK: For each L2 doc where TRAPS section has more than 8 entries, verify that TRAPS include staleness metadata (`STALE_IF:` or `REF:` fields). Flag TRAPS without any staleness metadata as `NEEDS_METADATA` — these are not auto-removed, but flagged for the next `/prizmkit-retrospective` to enrich with `STALE_IF:` globs or `REF:` hashes.
|
|
16
|
-
|
|
17
|
-
OUTPUT: Validation report with PASS/FAIL per check, list of issues with file paths and suggested fixes.
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: "prizmkit-retrospective"
|
|
3
|
-
description: "Incremental .prizmkit/prizm-docs/ maintainer. Performs two jobs: (1) structural sync — update .prizmkit/prizm-docs/ KEY_FILES/INTERFACES/DEPENDENCIES, (2) architecture knowledge — inject TRAPS/RULES/DECISIONS into .prizmkit/prizm-docs/. All project knowledge lives in .prizmkit/prizm-docs/ . Run after code review passes and before committing. Trigger on: 'retrospective', 'retro', 'update docs', 'sync docs', 'wrap up', 'done with feature', 'feature complete'. (project)"
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# PrizmKit Retrospective
|
|
7
|
-
|
|
8
|
-
| Store | Location | Content | Purpose |
|
|
9
|
-
|-------|----------|---------|---------|
|
|
10
|
-
| **Architecture Index** | `.prizmkit/prizm-docs/` | MODULE, FILES, INTERFACES, DEPENDENCIES, TRAPS, RULES, DECISIONS | AI quickly locates code structure, interfaces, known pitfalls, and key design decisions |
|
|
11
|
-
|
|
12
|
-
**This skill handles both structural sync and knowledge injection in one pass:**
|
|
13
|
-
|
|
14
|
-
1. **Structural Sync** — reflect what changed in code → `.prizmkit/prizm-docs/` (KEY_FILES, INTERFACES, DEPENDENCIES, file counts)
|
|
15
|
-
2. **Architecture Knowledge** — inject TRAPS, RULES, and DECISIONS → `.prizmkit/prizm-docs/`
|
|
16
|
-
|
|
17
|
-
For initial doc setup, validation, or migration, use `/prizmkit-prizm-docs` instead.
|
|
18
|
-
|
|
19
|
-
## When to Use
|
|
20
|
-
|
|
21
|
-
- **Before every commit** (mandatory in pipeline) — ensures docs and code are in sync
|
|
22
|
-
- After completing a feature, refactoring, or bug fix
|
|
23
|
-
- After code review passes
|
|
24
|
-
- User says "retrospective", "retro", "update docs", "sync docs", "wrap up"
|
|
25
|
-
|
|
26
|
-
## Input
|
|
27
|
-
|
|
28
|
-
| Parameter | Required | Description |
|
|
29
|
-
|-----------|----------|-------------|
|
|
30
|
-
| `artifact_dir` | No | Directory containing spec.md, plan.md, review-report.md. If omitted, scan `.prizmkit/` subdirectories for the most recently modified directory with a `plan.md`. When invoked as a handoff step, reuse the caller's `artifact_dir` rather than re-detecting. If no artifact directory found, run in standalone mode (structural sync only from `git diff`). |
|
|
31
|
-
|
|
32
|
-
## When NOT to Use
|
|
33
|
-
|
|
34
|
-
- Only comments, whitespace, or formatting changed — no structural/knowledge change
|
|
35
|
-
- Only test files changed — no module-level impact
|
|
36
|
-
- Only .prizm files changed — avoid circular updates
|
|
37
|
-
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
### Job 1: Structural Sync (always runs)
|
|
41
|
-
Synchronize `.prizmkit/prizm-docs/` structure with actual codebase changes from this session.
|
|
42
|
-
→ Read `${SKILL_DIR}/references/structural-sync-steps.md` for the detailed procedure.
|
|
43
|
-
|
|
44
|
-
**Key outputs**: Synced L1 file counts, L2 INTERFACES/DATA_FLOW, DEPENDENCIES, and stale TRAPS cleanup.
|
|
45
|
-
|
|
46
|
-
**Memory hygiene**: `.prizmkit/prizm-docs/` must not contain CHANGELOG sections/files, UPDATED/date metadata, feature/bug/refactor/task/session/run/pipeline/workflow IDs, branch names, absolute worktree paths, or `.prizmkit/specs` / `.prizmkit/dev-pipeline` artifact paths. Convert artifact-scoped wording into durable product/domain language before writing.
|
|
47
|
-
|
|
48
|
-
---
|
|
49
|
-
|
|
50
|
-
### Job 2: Knowledge Injection (conditional)
|
|
51
|
-
Inject newly discovered project knowledge (TRAPS, RULES, DECISIONS) into architecture docs.
|
|
52
|
-
→ Read `${SKILL_DIR}/references/knowledge-injection-steps.md` for the detailed procedure.
|
|
53
|
-
|
|
54
|
-
**Review gate**: Before running Job 2, check `review-report.md` in the artifact directory for the `## Verdict:` line:
|
|
55
|
-
- Verdict is `PASS` → proceed
|
|
56
|
-
- Verdict is `NEEDS_FIXES` → **skip Job 2** — do not inject knowledge for code that hasn't passed review. Output warning: "Review report has unresolved findings. Skipping knowledge injection."
|
|
57
|
-
- No `review-report.md` found → proceed with warning
|
|
58
|
-
- No artifact directory (standalone mode) → skip Job 2, only Job 1 runs
|
|
59
|
-
|
|
60
|
-
**Skip for**: pure refactors (no behavioral change).
|
|
61
|
-
|
|
62
|
-
**Bug Fix Documentation Policy**:
|
|
63
|
-
- DEFAULT for bug fixes: Run Job 1 (structural sync) only. Skip Job 2 (knowledge injection).
|
|
64
|
-
- RUN Job 2 when the bug fix causes any of:
|
|
65
|
-
• Interface signature changes
|
|
66
|
-
• Dependency additions/removals
|
|
67
|
-
• Observable behavior changes to existing features
|
|
68
|
-
• Newly discovered TRAPs (gotchas/pitfalls)
|
|
69
|
-
- When any of the above apply, run full retrospective (Job 1 + Job 2).
|
|
70
|
-
|
|
71
|
-
**Key outputs**: New TRAPS entries, RULES updates, DECISIONS records in relevant L1/L2 docs and root.prizm.
|
|
72
|
-
|
|
73
|
-
---
|
|
74
|
-
|
|
75
|
-
## Final: Stage
|
|
76
|
-
|
|
77
|
-
**3a.** Stage all doc changes:
|
|
78
|
-
```powershell
|
|
79
|
-
git add .prizmkit/prizm-docs/
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
**HANDOFF:** `/prizmkit-committer`
|
|
83
|
-
|
|
84
|
-
## Output
|
|
85
|
-
|
|
86
|
-
- `.prizmkit/prizm-docs/*.prizm` — Structurally synced + TRAPS/RULES/DECISIONS enriched
|
|
87
|
-
- All `.prizmkit/prizm-docs/` changes staged via `git add`
|
package/bundled/skills-windows/prizmkit-retrospective/references/knowledge-injection-steps.md
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
# Knowledge Injection — Detailed Steps (2a–2c)
|
|
2
|
-
|
|
3
|
-
**2a.** Gather context — read the **actual code that was changed** plus any available artifacts:
|
|
4
|
-
|
|
5
|
-
- `git diff HEAD` — the real source of truth for what happened
|
|
6
|
-
- `review-report.md` in the artifact directory — read the findings and fix instructions. If this file exists, use it as a source for pre-categorized decisions and findings.
|
|
7
|
-
- `plan.md` in the artifact directory — read planned vs actual
|
|
8
|
-
- Any companion documents in the artifact directory (e.g., `refactor-analysis.md`, `fix-report.md`) — read what was discovered
|
|
9
|
-
- The relevant `.prizmkit/prizm-docs/` L1/L2 docs for affected modules
|
|
10
|
-
|
|
11
|
-
**2b.** Extract knowledge from what was **observed in code**, not invented:
|
|
12
|
-
|
|
13
|
-
**TRAPS** (highest priority) — things that look safe but break:
|
|
14
|
-
- Minimal format: `- [SEVERITY] <description> | FIX: <approach>`
|
|
15
|
-
- Full format: `- [SEVERITY] <description> | FIX: <approach> | REF: <hash> | STALE_IF: <glob>`
|
|
16
|
-
- Source: actual bugs hit, surprising behavior discovered in code, non-obvious coupling
|
|
17
|
-
|
|
18
|
-
**TRAPS severity classification**:
|
|
19
|
-
- `[CRITICAL]`: data loss, security, financial error, system crash
|
|
20
|
-
- `[HIGH]`: functional failure, silent error, interface incompatibility
|
|
21
|
-
- `[LOW]`: misleading naming, non-intuitive API, minor performance issue
|
|
22
|
-
|
|
23
|
-
When writing TRAPS:
|
|
24
|
-
- Severity prefix is MANDATORY (e.g., `[CRITICAL]`, `[HIGH]`, `[LOW]`)
|
|
25
|
-
- OPTIONAL: append `| REF: <7-char-hash>` when you know the relevant commit (for traceability)
|
|
26
|
-
- OPTIONAL: append `| STALE_IF: <glob>` when the TRAP is tightly coupled to specific files (for auto-expiry detection)
|
|
27
|
-
|
|
28
|
-
**Consuming [REVIEW] markers** (from staleness check 1g):
|
|
29
|
-
- If you encounter a TRAP prefixed with `[REVIEW]` (e.g., `[REVIEW][HIGH] ...`), verify whether the trap is still valid by checking the current code. If still valid: remove the `[REVIEW]` prefix, keeping the severity. If no longer relevant: delete the TRAP entry.
|
|
30
|
-
|
|
31
|
-
**RULES** — conventions established or constraints discovered:
|
|
32
|
-
- Format: `- MUST/NEVER/PREFER: <rule>`
|
|
33
|
-
- Source: patterns that proved necessary during implementation
|
|
34
|
-
|
|
35
|
-
**DECISIONS** — key design choices that affect future development:
|
|
36
|
-
- Format: `- <what was decided> — <rationale>`
|
|
37
|
-
- Source: non-obvious design choices, interface conventions, cross-module contracts
|
|
38
|
-
- Only record decisions that a future AI session would benefit from knowing
|
|
39
|
-
- Do NOT record obvious implementation details that can be derived by reading the code
|
|
40
|
-
|
|
41
|
-
**QUALITY GATE**: Every item must answer: "If a new AI session reads only `.prizmkit/prizm-docs/` and this entry, does it gain actionable understanding?" If not, discard. Do not record trivially observable code patterns — the AI can read the code directly.
|
|
42
|
-
|
|
43
|
-
**MEMORY HYGIENE GATE**: Before writing any `.prizmkit/prizm-docs/` entry, remove or translate workflow metadata. Never write CHANGELOG sections/files, UPDATED/date metadata, feature/bug/refactor/task/session/run/pipeline/workflow IDs, branch names, absolute worktree paths, or `.prizmkit/specs` / `.prizmkit/dev-pipeline` artifact paths. If source artifacts say "fixed in B-001" or "implemented in F-003", write only the durable product/domain fact.
|
|
44
|
-
|
|
45
|
-
**2c.** Inject into the correct `.prizmkit/prizm-docs/` file:
|
|
46
|
-
- Module-level TRAPS/RULES/DECISIONS → the affected **L2** `.prizm` file. If the target L2 does not exist, create it first using the L2 GENERATION TEMPLATE before injecting knowledge. (TRAPS/DECISIONS/RULES belong in L2, not L1.)
|
|
47
|
-
- Project-level RULES/PATTERNS → `root.prizm` (respect the current format — MODULE_INDEX or MODULE_GROUPS — do not convert between them during injection)
|
|
48
|
-
- Cross-module concerns spanning 2+ modules → `root.prizm` CROSS_CUTTING section
|
|
49
|
-
|
|
50
|
-
**RULE**: Only add genuinely new information. Never duplicate existing entries. Never rewrite entire files.
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
# Structural Sync — Detailed Steps
|
|
2
|
-
|
|
3
|
-
**1a.** Get changed files (staged + unstaged vs HEAD):
|
|
4
|
-
```powershell
|
|
5
|
-
git diff HEAD --name-status
|
|
6
|
-
```
|
|
7
|
-
|
|
8
|
-
**1b.** Read `.prizmkit/prizm-docs/root.prizm` to get MODULE_INDEX (or MODULE_GROUPS). Map each changed file to its module.
|
|
9
|
-
|
|
10
|
-
**1c.** Classify changes:
|
|
11
|
-
- `A` (added) → add to KEY_FILES, check for new INTERFACES
|
|
12
|
-
- `D` (deleted) → remove from KEY_FILES, update FILE count
|
|
13
|
-
- `M` (modified) → check if public interfaces or dependencies changed
|
|
14
|
-
- `R` (renamed) → update all path references
|
|
15
|
-
|
|
16
|
-
**1d.** Update affected docs (bottom-up: L2 → L1 → L0):
|
|
17
|
-
|
|
18
|
-
- **L2**: If L2 exists → update **only the sections affected by the diff files in this module**. For example, if only `api.js` changed: update its KEY_FILES entry, its INTERFACES (if exports changed), its DEPENDENCIES (if imports changed). Do NOT re-scan unchanged files in the module. If L2 does NOT exist AND the module has Added or Modified source files in the current diff with meaningful logic (not trivial config) → create L2 with these sections: MODULE, FILES, RESPONSIBILITY, INTERFACES, DATA_FLOW, KEY_FILES, DEPENDENCIES, RULES, TRAPS, DECISIONS. Populate **only from the diff files** (the Added/Modified files in this module from step 1a), not from the entire module directory.
|
|
19
|
-
- **L1**: Update FILES count, KEY_FILES (if major files added/removed), DEPENDENCIES (if module-level deps changed). **L1 does NOT contain INTERFACES, DATA_FLOW, TRAPS, or DECISIONS** — those belong in L2 only.
|
|
20
|
-
- **L0 root.prizm**: Update MODULE_INDEX file counts only if counts changed. Update CROSS_CUTTING if cross-module concerns changed. Update only if structural change (module added/removed). **Preserve** any `PROJECT_BRIEF:` line — it is managed by prizmkit-init.
|
|
21
|
-
|
|
22
|
-
**Memory hygiene**: During L0/L1/L2 updates, do not write CHANGELOG sections/files, UPDATED/date metadata, feature/bug/refactor/task/session/run/pipeline/workflow IDs, branch names, absolute worktree paths, or `.prizmkit/specs` / `.prizmkit/dev-pipeline` artifact paths. Update durable sections in place; git history is the change log.
|
|
23
|
-
|
|
24
|
-
**1e.** If new directory qualifies as a module and matches no existing module:
|
|
25
|
-
- A directory qualifies as a module if any of: contains source files forming a logical unit, contains entry/config/interface files, contains qualifying sub-modules, or is referenced by multiple modules as dependency.
|
|
26
|
-
- Create L1 doc immediately, add to MODULE_INDEX.
|
|
27
|
-
- If the current diff includes Added or Modified source files with meaningful logic → create L2 immediately. Otherwise defer L2.
|
|
28
|
-
|
|
29
|
-
**1f.** Enforce size limits:
|
|
30
|
-
- L0 > 4KB → if using MODULE_INDEX with > 15 entries, convert to MODULE_GROUPS format (group by functional domain). Otherwise, consolidate MODULE_INDEX descriptions.
|
|
31
|
-
- L1 > 4KB → trim KEY_FILES descriptions, ensure RULES <= 3 entries
|
|
32
|
-
- L2 > 5KB → trim non-essential detail, split oversized cross-cutting detail, or move derived context back to source references
|
|
33
|
-
|
|
34
|
-
**SKIP structural sync if**: only internal implementation changed (no interface/dependency impact), only comments/whitespace, only .prizm files. **DO NOT skip** test file changes or bug fixes — they may reveal TRAPS worth capturing in L2.
|
|
35
|
-
|
|
36
|
-
**1g. TRAPS staleness check** (only when an L2 doc's TRAPS section has > 10 entries):
|
|
37
|
-
|
|
38
|
-
Perform a quick staleness scan on existing TRAPS to prevent unbounded accumulation:
|
|
39
|
-
1. If a TRAP has `STALE_IF:` and the glob-matched files no longer exist (verified via `ls`) → delete the TRAP entry
|
|
40
|
-
2. If a TRAP has `REF:` → check if the referenced file still exists and the REF commit is less than 180 days old (via `git log --since="180 days ago" <hash> 2>$null`). If the file is deleted OR the REF commit is older than 180 days → prepend `[REVIEW]` to the severity, signaling it needs verification during the next retrospective Job 2
|
|
41
|
-
3. Process at most 5 of the oldest TRAPS per L2 doc per session (to bound context cost)
|
|
42
|
-
|
|
43
|
-
This step is lightweight — it only triggers when TRAPS exceed 10 entries, and processes at most 5 per run.
|
|
@@ -1,227 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: "prizmkit-test"
|
|
3
|
-
description: "Full-stack test generation and orchestration. Detects architecture, discovers/runs existing tests, analyzes coverage gaps, generates missing unit/integration/E2E tests including business-specific boundary cases, validates every interface with a required boundary coverage matrix, and outputs a unified report. Use after completing development to verify quality before deploy. Trigger on: 'test', 'run tests', 'check quality', 'verify code', 'generate tests', 'test coverage', 'fill test gaps', 'boundary tests', 'edge cases', 'quality check', 'add tests'. (project)"
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# PrizmKit Test
|
|
7
|
-
|
|
8
|
-
A comprehensive test generation and orchestration skill. Discovers existing tests, runs them, compares coverage against spec acceptance criteria and module interfaces, generates missing tests at three levels (unit → integration → E2E), verifies business-specific boundary coverage for every in-scope interface, and produces a unified report.
|
|
9
|
-
|
|
10
|
-
### When to Use
|
|
11
|
-
- After completing one or more features/refactors/bugfixes
|
|
12
|
-
- As a quality gate before deploy
|
|
13
|
-
- Project has a test framework installed but zero tests written (first-time test generation)
|
|
14
|
-
- User says "test", "run tests", "verify", "check quality", "add tests"
|
|
15
|
-
|
|
16
|
-
### When NOT to Use
|
|
17
|
-
- Project has no test framework AND no code to test
|
|
18
|
-
- Trivial single-line config changes
|
|
19
|
-
|
|
20
|
-
## Precondition
|
|
21
|
-
|
|
22
|
-
| Required State | Check | If Missing |
|
|
23
|
-
|---|---|---|
|
|
24
|
-
| `.prizmkit/prizm-docs/root.prizm` exists | File exists | Run `/prizmkit-init` first |
|
|
25
|
-
| Test framework installed | Dependency in package.json or equivalent | Offer to skip or let user install one manually |
|
|
26
|
-
|
|
27
|
-
If `.prizmkit/prizm-docs/` exists but may be stale (no retrospective run after recent changes), warn user: "Prizm docs may be out of date. Gap analysis accuracy depends on current docs. Continue anyway?"
|
|
28
|
-
|
|
29
|
-
## Context Loading
|
|
30
|
-
|
|
31
|
-
Before execution, load context once:
|
|
32
|
-
|
|
33
|
-
1. **Architecture context**: Read `.prizmkit/prizm-docs/root.prizm` (L0 — project overview, module index, tech stack, conventions) and relevant L1 docs for modules in scope. If scope includes specific modules, also load relevant L2 docs for INTERFACES, DATA_FLOW, TRAPS, and DECISIONS.
|
|
34
|
-
2. **Project config**: Read `.prizmkit/config.json` (tech stack, AI CLI config).
|
|
35
|
-
3. **Dependencies**: Read `package.json` or equivalent to detect test framework and project type.
|
|
36
|
-
|
|
37
|
-
For `scope=this-change`, load only:
|
|
38
|
-
- `.prizmkit/prizm-docs/root.prizm`
|
|
39
|
-
- relevant L1/L2 docs inferred from in-scope changed files
|
|
40
|
-
- `artifact_dir/spec.md`
|
|
41
|
-
- `artifact_dir/plan.md`
|
|
42
|
-
- `artifact_dir/context-snapshot.md` if present
|
|
43
|
-
- `artifact_dir/review-report.md` if present
|
|
44
|
-
- changed source files and directly related existing tests
|
|
45
|
-
|
|
46
|
-
Do not load all modules or all specs merely because they exist.
|
|
47
|
-
|
|
48
|
-
## Input
|
|
49
|
-
|
|
50
|
-
| Parameter | Required | Description |
|
|
51
|
-
|-----------|----------|-------------|
|
|
52
|
-
| `scope` | No | `full-project`, `module:<name>`, `feature:<slug>`, or `this-change`. In headless mode, defaults to `this-change` only when `artifact_dir` points to `.prizmkit/specs/<FEATURE_SLUG>/`; otherwise defaults to full project. |
|
|
53
|
-
| `artifact_dir` | No | Feature artifact directory. For `scope=this-change`, must be `.prizmkit/specs/<FEATURE_SLUG>/`. Do not infer this-change scope from `.prizmkit/bugfix/` or `.prizmkit/refactor/`. |
|
|
54
|
-
| `diff_base` | No | Git ref used to compute changed files for this feature. |
|
|
55
|
-
| `changed_files` | No | Explicit caller-provided changed file list. Takes precedence over `diff_base`. |
|
|
56
|
-
| `generation_policy` | No | Defaults to `in-scope-only` for `scope=this-change`. Out-of-scope gaps are reported but not generated. |
|
|
57
|
-
|
|
58
|
-
## Execution
|
|
59
|
-
|
|
60
|
-
### Phase 0: Architecture Detection
|
|
61
|
-
|
|
62
|
-
1. From context already loaded, classify project type:
|
|
63
|
-
|
|
64
|
-
| Signal | Classification |
|
|
65
|
-
|--------|---------------|
|
|
66
|
-
| react/vue/angular/next in deps, no backend framework | Frontend |
|
|
67
|
-
| express/fastify/django/flask in deps, no frontend framework | Backend |
|
|
68
|
-
| Both present | Fullstack |
|
|
69
|
-
| Neither clear | Ask user (headless: mark as "unknown", skip E2E) |
|
|
70
|
-
|
|
71
|
-
2. Detect test framework by scanning dependencies:
|
|
72
|
-
- Jest → `npx jest` or `npm test`
|
|
73
|
-
- Vitest → `npx vitest run`
|
|
74
|
-
- pytest → `python -m pytest`
|
|
75
|
-
- Go testing → `go test ./...`
|
|
76
|
-
- Multiple frameworks found → use the one with the most test files; list all in report
|
|
77
|
-
- Custom `npm test` script → use `npm test`
|
|
78
|
-
|
|
79
|
-
3. **Interactive mode**: Show "Detected: {type}, test framework: {name}. Correct?"
|
|
80
|
-
**Headless mode**: Auto-proceed with detected values, note assumptions in report.
|
|
81
|
-
|
|
82
|
-
### Phase 1: Scope Selection
|
|
83
|
-
|
|
84
|
-
**Interactive mode** — present three options:
|
|
85
|
-
|
|
86
|
-
1. **Full project** — all modules, all specs in `.prizmkit/specs/`
|
|
87
|
-
2. **Single module** — pick from L1 doc module names (e.g., "auth", "payment")
|
|
88
|
-
3. **Single feature** — pick from `.prizmkit/specs/###-*/` directories
|
|
89
|
-
|
|
90
|
-
**Headless mode**:
|
|
91
|
-
1. If `scope=this-change`, require `artifact_dir=.prizmkit/specs/<FEATURE_SLUG>/` and run in feature-scoped mode.
|
|
92
|
-
2. If `artifact_dir=.prizmkit/specs/<FEATURE_SLUG>/` is provided without `scope`, treat it as `scope=this-change`.
|
|
93
|
-
3. If `scope=full-project` is explicitly provided, run full-project mode even if an artifact directory exists.
|
|
94
|
-
4. If `artifact_dir` points to `.prizmkit/bugfix/` or `.prizmkit/refactor/`, do not infer `scope=this-change`.
|
|
95
|
-
5. If neither `scope` nor feature `artifact_dir` is provided, default to full project.
|
|
96
|
-
|
|
97
|
-
`scope=this-change` is feature-only. It is valid only when `artifact_dir` is under `.prizmkit/specs/<FEATURE_SLUG>/`. Do not automatically apply `scope=this-change` to `.prizmkit/bugfix/<BUG_ID>/` or `.prizmkit/refactor/<REFACTOR_ID>/`. If the caller passes `scope=this-change` with a bugfix/refactor artifact directory, stop and report that this mode is unsupported for that artifact type. Bugfix and refactor workflows keep their existing reproduction-test and behavior-preservation test gates.
|
|
98
|
-
|
|
99
|
-
### Phase 2: Run Existing Tests
|
|
100
|
-
|
|
101
|
-
1. Find test directories matching common patterns: `tests/`, `__tests__/`, `*.test.*`, `*.spec.*`. If no test files exist at all, note this and skip to Phase 3 (all coverage is "missing").
|
|
102
|
-
|
|
103
|
-
2. Run the detected test command in scope. Capture:
|
|
104
|
-
- Pass/fail counts and failed test details
|
|
105
|
-
- Which test files exist (for gap analysis)
|
|
106
|
-
- Raw output (saved to report directory)
|
|
107
|
-
|
|
108
|
-
3. Classify existing test failures before continuing:
|
|
109
|
-
- For `scope=this-change`, failures in changed tests, tests mapped to in-scope source files, or tests directly covering feature acceptance criteria are `In-Scope Failures` unless a captured pre-feature baseline proves they already failed before this feature.
|
|
110
|
-
- For `scope=this-change`, unrelated failures are `Baseline Failures`; record them without failing the scoped verdict.
|
|
111
|
-
- For other scopes, record failures as existing test failures and do not assume they are caused by this test-generation pass.
|
|
112
|
-
|
|
113
|
-
4. If `scope=this-change` has any unexplained `In-Scope Failures`, the final report verdict must be `NEEDS_FIXES` or `BLOCKED`, not `PASS`. Do not hide them as baseline failures.
|
|
114
|
-
|
|
115
|
-
### Phase 3: Coverage Gap Analysis
|
|
116
|
-
|
|
117
|
-
Staleness of `.prizmkit/prizm-docs/` was already checked during Context Loading (see Precondition). Gap analysis proceeds with the available data.
|
|
118
|
-
|
|
119
|
-
For `scope=this-change`:
|
|
120
|
-
|
|
121
|
-
1. Build the in-scope source set using this priority:
|
|
122
|
-
- `changed_files` parameter
|
|
123
|
-
- `git diff --name-only <diff_base>`
|
|
124
|
-
- files/tasks listed in `artifact_dir/plan.md`
|
|
125
|
-
- File Manifest in `artifact_dir/context-snapshot.md`
|
|
126
|
-
- direct file/module mapping from `artifact_dir/spec.md` acceptance criteria
|
|
127
|
-
2. Build the in-scope test set:
|
|
128
|
-
- tests already changed in this feature
|
|
129
|
-
- tests matching in-scope source files by project naming convention
|
|
130
|
-
- directly affected integration/E2E tests for feature acceptance criteria
|
|
131
|
-
3. Analyze only:
|
|
132
|
-
- changed/new public interfaces
|
|
133
|
-
- feature acceptance criteria from `artifact_dir/spec.md`
|
|
134
|
-
- integration boundaries directly affected by in-scope files
|
|
135
|
-
- UI/E2E flows directly affected by this feature
|
|
136
|
-
4. For unrelated historical gaps, record them under `Out of Scope Gaps`; do not generate tests and do not fail the feature verdict because of them.
|
|
137
|
-
|
|
138
|
-
For other scopes, compare what exists against what should exist, across three levels:
|
|
139
|
-
|
|
140
|
-
**Unit test gaps** — for each module in scope:
|
|
141
|
-
- Read the corresponding L2 `.prizm` doc INTERFACES section to get exported functions/classes. If no L2 doc exists for a module, analyze source files directly to identify exported functions/classes.
|
|
142
|
-
- Check if each has a corresponding test file (match project's test naming: `foo.test.ts`, `foo.spec.ts`, `test_foo.py`)
|
|
143
|
-
- Flag uncovered interfaces
|
|
144
|
-
|
|
145
|
-
**Integration test gaps** (skip if project has no API/DB layer — pure library/CLI tool):
|
|
146
|
-
- Read L1 doc DEPENDENCIES section for cross-module interactions
|
|
147
|
-
- Check if tests exist covering module boundaries, API endpoints, DB operations
|
|
148
|
-
- Flag missing integration coverage
|
|
149
|
-
|
|
150
|
-
**E2E test gaps** (skip if project has no UI):
|
|
151
|
-
- Collect acceptance criteria from all spec.md files in scope
|
|
152
|
-
- Check existing E2E test files against these criteria
|
|
153
|
-
- Flag uncovered criteria
|
|
154
|
-
|
|
155
|
-
### Phase 4: Boundary Coverage Matrix
|
|
156
|
-
|
|
157
|
-
Phase 3 answers "which interfaces are missing tests?" Phase 4 answers "which business boundaries are missing for each interface?" Build this matrix before generating tests so the run does not mistake broad happy-path coverage for real safety coverage.
|
|
158
|
-
|
|
159
|
-
A path, method, function, or class is not considered covered merely because a happy-path test exists; happy path proves the interface works once, while boundary tests prove it behaves safely under realistic invalid, unauthorized, edge, and failure states.
|
|
160
|
-
|
|
161
|
-
Read `${SKILL_DIR}/references/boundary-coverage-protocol.md` for the required matrix format, category definitions, and completion gate. For every in-scope interface and API endpoint, classify applicable categories such as request validation, auth/permission/ownership, domain invariants, collection/pagination, date/time boundaries, state transitions, dependency failures, and response contract checks. In `scope=this-change`, build this matrix only for the in-scope feature interfaces/endpoints; unrelated interfaces belong in `Out of Scope Gaps`.
|
|
162
|
-
|
|
163
|
-
For each category, mark one of:
|
|
164
|
-
- `covered` — an existing test already asserts the boundary behavior
|
|
165
|
-
- `generated` — this run generated and passed the test
|
|
166
|
-
- `needs-review` — a valid generated test found behavior mismatch
|
|
167
|
-
- `skipped` — not applicable, with a concrete reason
|
|
168
|
-
|
|
169
|
-
If an interface has only happy-path coverage, mark it `boundary-missing` and generate applicable boundary tests in Phase 5. Do not mark happy-path-only coverage as `covered`.
|
|
170
|
-
|
|
171
|
-
### Phase 5: Generate Missing and Boundary Tests
|
|
172
|
-
|
|
173
|
-
Read `${SKILL_DIR}/references/test-generation-steps.md` for the detailed generation procedure — boundary-matrix-driven workflow, priority order (unit → integration → E2E), failure handling rules, and generation patterns for each test level.
|
|
174
|
-
|
|
175
|
-
When generating unit tests for service-like functions or API/integration tests for endpoints with business-specific behavior, use `${SKILL_DIR}/references/service-boundary-test-catalog.md` via the generation procedure so boundary cases reflect the interface's business responsibility, not only generic null/empty inputs.
|
|
176
|
-
|
|
177
|
-
For `scope=this-change`:
|
|
178
|
-
- Generate or update tests only for the in-scope source/test set.
|
|
179
|
-
- Check for equivalent existing tests before writing new tests.
|
|
180
|
-
- Do not create tests for unrelated modules just because coverage is missing.
|
|
181
|
-
- Do not refactor unrelated tests.
|
|
182
|
-
- Do not modify unrelated production code.
|
|
183
|
-
- Do not expand to full-project coverage unless the user explicitly requested `scope=full-project`.
|
|
184
|
-
- Generated tests must assert real behavior, boundaries, or integration contracts; do not add empty assertions or mock-success-only tests.
|
|
185
|
-
|
|
186
|
-
### Phase 6: Unified Report and Boundary Validation
|
|
187
|
-
|
|
188
|
-
Create `.prizmkit/test/{YYYY_MM_DD_HH_MM_SS}_testresult/` directory. Read `${SKILL_DIR}/references/test-report-template.md` for the full report format and artifact list.
|
|
189
|
-
|
|
190
|
-
For `scope=this-change`, the report must include:
|
|
191
|
-
- `## Scope` with mode, artifact dir, diff base, changed-files source, generation policy, in-scope source files, and in-scope test files
|
|
192
|
-
- `## Existing Tests Run`
|
|
193
|
-
- `## Generated / Updated Tests`
|
|
194
|
-
- `## In-Scope Failures`
|
|
195
|
-
- `## Baseline Failures`
|
|
196
|
-
- `## Out of Scope Gaps`
|
|
197
|
-
- `## Verdict` with `PASS`, `NEEDS_FIXES`, or `BLOCKED`
|
|
198
|
-
|
|
199
|
-
`Out of Scope Gaps` are informational only for `scope=this-change`: they must not trigger generated tests and must not fail the verdict.
|
|
200
|
-
|
|
201
|
-
After writing the report, run the deterministic boundary-report validator when the project has an OpenAPI file or the report contains a Boundary Matrix:
|
|
202
|
-
|
|
203
|
-
```bash
|
|
204
|
-
python3 ${SKILL_DIR}/scripts/validate_boundary_report.py \
|
|
205
|
-
--report .prizmkit/test/{timestamp}_testresult/test-report.md \
|
|
206
|
-
--openapi openapi.yaml
|
|
207
|
-
```
|
|
208
|
-
|
|
209
|
-
If the project has no OpenAPI file, omit `--openapi`. If validation fails, keep the report but do not claim the run is complete; report that tests may pass while boundary coverage remains incomplete.
|
|
210
|
-
|
|
211
|
-
## Output
|
|
212
|
-
|
|
213
|
-
- Test report: `.prizmkit/test/{timestamp}_testresult/test-report.md`
|
|
214
|
-
- Generated test files written to project test directories
|
|
215
|
-
- Existing test output, generated test copies, E2E artifacts, and boundary validation output in the report directory
|
|
216
|
-
|
|
217
|
-
## Recovery
|
|
218
|
-
|
|
219
|
-
If the session is interrupted:
|
|
220
|
-
- Check `.prizmkit/test/` for the most recent report directory — it contains what was completed before interruption
|
|
221
|
-
- Re-run `/prizmkit-test` — it starts fresh, but Phase 2 will skip tests that already pass, and Phase 3/4 will re-evaluate gaps and boundary coverage
|
|
222
|
-
|
|
223
|
-
## Examples
|
|
224
|
-
|
|
225
|
-
Read `${SKILL_DIR}/references/examples.md` for worked examples of full-project, single-feature, and happy-path-only remediation runs.
|
|
226
|
-
|
|
227
|
-
**HANDOFF:** Independent skill — no handoff. User may proceed to `/prizmkit-committer` only if tests pass and the boundary completion gate passes. If tests are marked `needs-review` or boundary validation fails, fix issues manually or run another targeted `/prizmkit-test` pass.
|