prizmkit 1.1.57 → 1.1.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/bin/create-prizmkit.js +8 -6
  2. package/bundled/VERSION.json +3 -3
  3. package/bundled/adapters/codex/agent-adapter.js +38 -0
  4. package/bundled/adapters/codex/paths.js +27 -0
  5. package/bundled/adapters/codex/rules-adapter.js +30 -0
  6. package/bundled/adapters/codex/settings-adapter.js +27 -0
  7. package/bundled/adapters/codex/skill-adapter.js +65 -0
  8. package/bundled/adapters/codex/team-adapter.js +37 -0
  9. package/bundled/dev-pipeline/.env.example +2 -1
  10. package/bundled/dev-pipeline/README.md +10 -7
  11. package/bundled/dev-pipeline/lib/common.sh +278 -37
  12. package/bundled/dev-pipeline/run-bugfix.sh +10 -61
  13. package/bundled/dev-pipeline/run-feature.sh +10 -78
  14. package/bundled/dev-pipeline/run-recovery.sh +10 -46
  15. package/bundled/dev-pipeline/run-refactor.sh +10 -61
  16. package/bundled/dev-pipeline/scripts/generate-bootstrap-prompt.py +17 -7
  17. package/bundled/dev-pipeline/scripts/generate-bugfix-prompt.py +9 -3
  18. package/bundled/dev-pipeline/scripts/generate-refactor-prompt.py +9 -3
  19. package/bundled/dev-pipeline/scripts/utils.py +6 -4
  20. package/bundled/dev-pipeline-windows/.env.example +28 -0
  21. package/bundled/dev-pipeline-windows/README.md +30 -0
  22. package/bundled/dev-pipeline-windows/SCHEMA_ANALYSIS.md +525 -0
  23. package/bundled/dev-pipeline-windows/assets/feature-list-example.json +146 -0
  24. package/bundled/dev-pipeline-windows/assets/prizm-dev-team-integration.md +138 -0
  25. package/bundled/dev-pipeline-windows/launch-bugfix-daemon.ps1 +9 -0
  26. package/bundled/dev-pipeline-windows/launch-feature-daemon.ps1 +9 -0
  27. package/bundled/dev-pipeline-windows/launch-refactor-daemon.ps1 +9 -0
  28. package/bundled/dev-pipeline-windows/lib/common.ps1 +432 -0
  29. package/bundled/dev-pipeline-windows/lib/daemon.ps1 +140 -0
  30. package/bundled/dev-pipeline-windows/lib/pipeline.ps1 +446 -0
  31. package/bundled/dev-pipeline-windows/lib/reset.ps1 +87 -0
  32. package/bundled/dev-pipeline-windows/reset-bug.ps1 +9 -0
  33. package/bundled/dev-pipeline-windows/reset-feature.ps1 +9 -0
  34. package/bundled/dev-pipeline-windows/reset-refactor.ps1 +9 -0
  35. package/bundled/dev-pipeline-windows/run-bugfix.ps1 +9 -0
  36. package/bundled/dev-pipeline-windows/run-feature.ps1 +9 -0
  37. package/bundled/dev-pipeline-windows/run-recovery.ps1 +76 -0
  38. package/bundled/dev-pipeline-windows/run-refactor.ps1 +9 -0
  39. package/bundled/dev-pipeline-windows/scripts/check-session-status.py +228 -0
  40. package/bundled/dev-pipeline-windows/scripts/cleanup-logs.py +192 -0
  41. package/bundled/dev-pipeline-windows/scripts/detect-stuck.py +530 -0
  42. package/bundled/dev-pipeline-windows/scripts/generate-bootstrap-prompt.py +1737 -0
  43. package/bundled/dev-pipeline-windows/scripts/generate-bugfix-prompt.py +685 -0
  44. package/bundled/dev-pipeline-windows/scripts/generate-recovery-prompt.py +805 -0
  45. package/bundled/dev-pipeline-windows/scripts/generate-refactor-prompt.py +763 -0
  46. package/bundled/dev-pipeline-windows/scripts/init-bugfix-pipeline.py +316 -0
  47. package/bundled/dev-pipeline-windows/scripts/init-dev-team.py +134 -0
  48. package/bundled/dev-pipeline-windows/scripts/init-pipeline.py +380 -0
  49. package/bundled/dev-pipeline-windows/scripts/init-refactor-pipeline.py +399 -0
  50. package/bundled/dev-pipeline-windows/scripts/parse-stream-progress.py +388 -0
  51. package/bundled/dev-pipeline-windows/scripts/patch-completion-notes.py +191 -0
  52. package/bundled/dev-pipeline-windows/scripts/update-bug-status.py +864 -0
  53. package/bundled/dev-pipeline-windows/scripts/update-checkpoint.py +173 -0
  54. package/bundled/dev-pipeline-windows/scripts/update-feature-status.py +1501 -0
  55. package/bundled/dev-pipeline-windows/scripts/update-refactor-status.py +1073 -0
  56. package/bundled/dev-pipeline-windows/scripts/utils.py +542 -0
  57. package/bundled/dev-pipeline-windows/templates/agent-prompts/critic-plan-challenge.md +7 -0
  58. package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-fix.md +7 -0
  59. package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-implement.md +30 -0
  60. package/bundled/dev-pipeline-windows/templates/agent-prompts/dev-resume.md +5 -0
  61. package/bundled/dev-pipeline-windows/templates/agent-prompts/reviewer-review.md +7 -0
  62. package/bundled/dev-pipeline-windows/templates/bootstrap-prompt.md +46 -0
  63. package/bundled/dev-pipeline-windows/templates/bootstrap-tier1.md +43 -0
  64. package/bundled/dev-pipeline-windows/templates/bootstrap-tier2.md +43 -0
  65. package/bundled/dev-pipeline-windows/templates/bootstrap-tier3.md +43 -0
  66. package/bundled/dev-pipeline-windows/templates/bug-fix-list-schema.json +263 -0
  67. package/bundled/dev-pipeline-windows/templates/bugfix-bootstrap-prompt.md +320 -0
  68. package/bundled/dev-pipeline-windows/templates/feature-list-schema.json +237 -0
  69. package/bundled/dev-pipeline-windows/templates/refactor-bootstrap-prompt.md +331 -0
  70. package/bundled/dev-pipeline-windows/templates/refactor-list-schema.json +270 -0
  71. package/bundled/dev-pipeline-windows/templates/sections/ac-verification-checklist.md +13 -0
  72. package/bundled/dev-pipeline-windows/templates/sections/checkpoint-system.md +91 -0
  73. package/bundled/dev-pipeline-windows/templates/sections/context-budget-rules.md +33 -0
  74. package/bundled/dev-pipeline-windows/templates/sections/critical-paths-agent.md +10 -0
  75. package/bundled/dev-pipeline-windows/templates/sections/critical-paths-full.md +12 -0
  76. package/bundled/dev-pipeline-windows/templates/sections/critical-paths-lite.md +7 -0
  77. package/bundled/dev-pipeline-windows/templates/sections/directory-convention-agent.md +8 -0
  78. package/bundled/dev-pipeline-windows/templates/sections/directory-convention-full.md +9 -0
  79. package/bundled/dev-pipeline-windows/templates/sections/directory-convention-lite.md +6 -0
  80. package/bundled/dev-pipeline-windows/templates/sections/failure-capture.md +21 -0
  81. package/bundled/dev-pipeline-windows/templates/sections/feature-context.md +31 -0
  82. package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification-auto.md +72 -0
  83. package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification-opencli.md +63 -0
  84. package/bundled/dev-pipeline-windows/templates/sections/phase-browser-verification.md +62 -0
  85. package/bundled/dev-pipeline-windows/templates/sections/phase-commit-full.md +71 -0
  86. package/bundled/dev-pipeline-windows/templates/sections/phase-commit.md +64 -0
  87. package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-agent-suffix.md +23 -0
  88. package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-base.md +24 -0
  89. package/bundled/dev-pipeline-windows/templates/sections/phase-context-snapshot-lite-suffix.md +12 -0
  90. package/bundled/dev-pipeline-windows/templates/sections/phase-critic-plan-full.md +53 -0
  91. package/bundled/dev-pipeline-windows/templates/sections/phase-critic-plan.md +32 -0
  92. package/bundled/dev-pipeline-windows/templates/sections/phase-implement-agent.md +37 -0
  93. package/bundled/dev-pipeline-windows/templates/sections/phase-implement-full.md +50 -0
  94. package/bundled/dev-pipeline-windows/templates/sections/phase-implement-lite.md +52 -0
  95. package/bundled/dev-pipeline-windows/templates/sections/phase-plan-agent.md +27 -0
  96. package/bundled/dev-pipeline-windows/templates/sections/phase-plan-lite.md +27 -0
  97. package/bundled/dev-pipeline-windows/templates/sections/phase-review-agent.md +27 -0
  98. package/bundled/dev-pipeline-windows/templates/sections/phase-review-full.md +29 -0
  99. package/bundled/dev-pipeline-windows/templates/sections/phase-specify-plan-full.md +77 -0
  100. package/bundled/dev-pipeline-windows/templates/sections/phase0-init.md +13 -0
  101. package/bundled/dev-pipeline-windows/templates/sections/phase0-test-baseline.md +23 -0
  102. package/bundled/dev-pipeline-windows/templates/sections/session-context.md +5 -0
  103. package/bundled/dev-pipeline-windows/templates/sections/subagent-timeout-recovery.md +6 -0
  104. package/bundled/dev-pipeline-windows/templates/sections/test-failure-recovery-agent.md +67 -0
  105. package/bundled/dev-pipeline-windows/templates/sections/test-failure-recovery-lite.md +58 -0
  106. package/bundled/dev-pipeline-windows/templates/session-status-schema.json +83 -0
  107. package/bundled/skills/_metadata.json +1 -1
  108. package/bundled/skills/app-planner/SKILL.md +26 -18
  109. package/bundled/skills/app-planner/references/architecture-decisions.md +9 -5
  110. package/bundled/skills/app-planner/references/frontend-design-guide.md +1 -1
  111. package/bundled/skills/feature-planner/SKILL.md +9 -2
  112. package/bundled/skills/prizmkit-init/SKILL.md +7 -6
  113. package/bundled/skills/recovery-workflow/scripts/detect-recovery-state.py +2 -0
  114. package/bundled/skills-windows/app-planner/SKILL.md +639 -0
  115. package/bundled/skills-windows/app-planner/assets/app-design-guide.md +101 -0
  116. package/bundled/skills-windows/app-planner/references/architecture-decisions.md +52 -0
  117. package/bundled/skills-windows/app-planner/references/brainstorm-guide.md +101 -0
  118. package/bundled/skills-windows/app-planner/references/frontend-design-guide.md +71 -0
  119. package/bundled/skills-windows/app-planner/references/project-brief-guide.md +82 -0
  120. package/bundled/skills-windows/app-planner/references/red-team-checklist.md +40 -0
  121. package/bundled/skills-windows/app-planner/references/rules/backend/derivation-rules.md +609 -0
  122. package/bundled/skills-windows/app-planner/references/rules/backend/fixed-rules.md +285 -0
  123. package/bundled/skills-windows/app-planner/references/rules/backend/question-bank.md +249 -0
  124. package/bundled/skills-windows/app-planner/references/rules/backend/template.md +173 -0
  125. package/bundled/skills-windows/app-planner/references/rules/database/derivation-rules.md +373 -0
  126. package/bundled/skills-windows/app-planner/references/rules/database/fixed-rules.md +211 -0
  127. package/bundled/skills-windows/app-planner/references/rules/database/question-bank.md +184 -0
  128. package/bundled/skills-windows/app-planner/references/rules/database/template.md +158 -0
  129. package/bundled/skills-windows/app-planner/references/rules/frontend/derivation-rules.md +810 -0
  130. package/bundled/skills-windows/app-planner/references/rules/frontend/fixed-rules.md +188 -0
  131. package/bundled/skills-windows/app-planner/references/rules/frontend/question-bank.md +302 -0
  132. package/bundled/skills-windows/app-planner/references/rules/frontend/template.md +320 -0
  133. package/bundled/skills-windows/app-planner/references/rules/mobile/derivation-rules.md +639 -0
  134. package/bundled/skills-windows/app-planner/references/rules/mobile/fixed-rules.md +290 -0
  135. package/bundled/skills-windows/app-planner/references/rules/mobile/question-bank.md +232 -0
  136. package/bundled/skills-windows/app-planner/references/rules/mobile/template.md +175 -0
  137. package/bundled/skills-windows/bug-fix-workflow/SKILL.md +415 -0
  138. package/bundled/skills-windows/bug-planner/SKILL.md +395 -0
  139. package/bundled/skills-windows/bug-planner/assets/bug-confirmation-template.md +43 -0
  140. package/bundled/skills-windows/bug-planner/references/critic-and-verification.md +44 -0
  141. package/bundled/skills-windows/bug-planner/references/error-recovery.md +73 -0
  142. package/bundled/skills-windows/bug-planner/references/input-formats.md +53 -0
  143. package/bundled/skills-windows/bug-planner/references/schema-validation.md +25 -0
  144. package/bundled/skills-windows/bug-planner/references/severity-rules.md +16 -0
  145. package/bundled/skills-windows/bug-planner/scripts/validate-bug-list.py +322 -0
  146. package/bundled/skills-windows/bugfix-pipeline-launcher/SKILL.md +380 -0
  147. package/bundled/skills-windows/feature-pipeline-launcher/SKILL.md +441 -0
  148. package/bundled/skills-windows/feature-pipeline-launcher/scripts/preflight-check.py +462 -0
  149. package/bundled/skills-windows/feature-planner/SKILL.md +401 -0
  150. package/bundled/skills-windows/feature-planner/assets/evaluation-guide.md +64 -0
  151. package/bundled/skills-windows/feature-planner/assets/planning-guide.md +214 -0
  152. package/bundled/skills-windows/feature-planner/references/browser-interaction.md +59 -0
  153. package/bundled/skills-windows/feature-planner/references/completeness-review.md +57 -0
  154. package/bundled/skills-windows/feature-planner/references/decomposition-patterns.md +75 -0
  155. package/bundled/skills-windows/feature-planner/references/error-recovery.md +90 -0
  156. package/bundled/skills-windows/feature-planner/references/incremental-feature-planning.md +112 -0
  157. package/bundled/skills-windows/feature-planner/references/new-project-planning.md +85 -0
  158. package/bundled/skills-windows/feature-planner/scripts/validate-and-generate.py +1029 -0
  159. package/bundled/skills-windows/feature-workflow/SKILL.md +531 -0
  160. package/bundled/skills-windows/prizmkit-init/SKILL.md +356 -0
  161. package/bundled/skills-windows/prizmkit-init/assets/project-brief-template.md +82 -0
  162. package/bundled/skills-windows/prizmkit-init/references/config-schema.md +68 -0
  163. package/bundled/skills-windows/prizmkit-init/references/rules/layer-detection.md +41 -0
  164. package/bundled/skills-windows/prizmkit-init/references/tech-stack-catalog.md +13 -0
  165. package/bundled/skills-windows/prizmkit-init/references/update-supplement.md +9 -0
  166. package/bundled/skills-windows/recovery-workflow/SKILL.md +456 -0
  167. package/bundled/skills-windows/recovery-workflow/evals/evals.json +46 -0
  168. package/bundled/skills-windows/recovery-workflow/scripts/detect-recovery-state.py +544 -0
  169. package/bundled/skills-windows/refactor-pipeline-launcher/SKILL.md +406 -0
  170. package/bundled/skills-windows/refactor-planner/SKILL.md +540 -0
  171. package/bundled/skills-windows/refactor-planner/assets/planning-guide.md +292 -0
  172. package/bundled/skills-windows/refactor-planner/references/behavior-preservation.md +301 -0
  173. package/bundled/skills-windows/refactor-planner/references/refactor-scoping-guide.md +221 -0
  174. package/bundled/skills-windows/refactor-planner/scripts/validate-and-generate-refactor.py +858 -0
  175. package/bundled/skills-windows/refactor-workflow/SKILL.md +503 -0
  176. package/package.json +3 -2
  177. package/src/clean.js +73 -2
  178. package/src/config.js +159 -50
  179. package/src/detect-platform.js +16 -8
  180. package/src/external-skills.js +26 -19
  181. package/src/index.js +31 -9
  182. package/src/manifest.js +6 -2
  183. package/src/metadata.js +43 -5
  184. package/src/platforms.js +36 -0
  185. package/src/prompts.js +31 -6
  186. package/src/runtimes.js +20 -0
  187. package/src/scaffold.js +314 -110
  188. package/src/upgrade.js +81 -41
@@ -0,0 +1,395 @@
1
+ ---
2
+ name: "bug-planner"
3
+ description: "Interactive bug planning that produces .prizmkit/plans/bug-fix-list.json for the Bug Fix Pipeline. Supports multiple input formats: error logs, stack traces, user reports, failed tests, monitoring alerts. Use this skill whenever the user has bugs to report, errors to parse, or test failures to organize. Trigger on: 'plan bug fixes', 'report bugs', 'I have some bugs', 'these tests are failing', 'here is an error log', 'parse these errors', 'generate bug list'."
4
+ ---
5
+
6
+ # Bug Planner
7
+
8
+ Interactive skill that collects bug information from various input formats and generates a standardized `.prizmkit/plans/bug-fix-list.json` for the Bug Fix Pipeline.
9
+
10
+ ## Invocation Commitment (Hard Rule)
11
+
12
+ When the user invokes `/bug-planner`, you MUST execute the bug-planner workflow. You must NEVER:
13
+ - Decide on the user's behalf that the task "doesn't need bug-planner"
14
+ - Skip bug-planner to jump directly to implementation or any other skill
15
+ - Bypass the interactive phases because you judge the task to be "simple"
16
+
17
+ If you believe the task is better suited for a different workflow, you MUST:
18
+ 1. Explain why you think a different path is more appropriate
19
+ 2. Ask the user explicitly whether they want to switch or continue with bug-planner
20
+ 3. Only switch if the user confirms
21
+
22
+ The user chose this skill intentionally. Respect that choice.
23
+
24
+ ## Scope Boundary (Hard Rule)
25
+
26
+ This skill is PLANNING ONLY. You must NEVER:
27
+ - Create, modify, or delete source code files (*.js, *.ts, *.py, *.go, *.html, *.css, etc.)
28
+ - Run build/install/test commands
29
+ - Execute any bug fix action
30
+ - Execute any implementation action beyond writing `.prizmkit/plans/bug-fix-list.json`
31
+
32
+ Your ONLY writable outputs are:
33
+ 1. `.prizmkit/plans/bug-fix-list.json`
34
+ 2. Draft backups in `.prizmkit/plans/` (e.g., `bug-fix-list.draft.json`)
35
+
36
+ After planning is complete, you MUST:
37
+ 1. Present the summary and recommended next step (invoking `bugfix-pipeline-launcher`)
38
+ 2. Ask the user explicitly whether they want to proceed to execution
39
+ 3. If the user wants to adjust → continue refining the bug list
40
+ 4. NEVER auto-execute the pipeline, launcher, or any fix step
41
+
42
+ ## User-Provided Content Priority (Hard Rule)
43
+
44
+ When the user provides detailed specifications, rules, or implementation requirements:
45
+
46
+ 1. **Verbatim preservation**: The user's exact wording MUST be preserved in `description` and `acceptance_criteria` fields. Do NOT paraphrase, summarize, abstract, or simplify.
47
+ 2. **No autonomous simplification**: A 200-word user specification must NOT become a 30-word description. Match the detail level of the user's input.
48
+ 3. **Clarify, don't assume**: If any user-provided rule is ambiguous or potentially conflicts with another, ASK the user to clarify. No limit on clarification rounds. Do NOT proceed with unresolved ambiguities.
49
+ 4. **Populate `user_context`**: ALL user-provided materials (supplementary content, rules, file path references) MUST be written into the `user_context` array of each bug in the generated `.prizmkit/plans/bug-fix-list.json`. Format:
50
+ - Supplementary content or rules → store as-is (verbatim text)
51
+ - File references → store as path string, e.g. `src/auth/login.ts:42-78` or `src/utils/validate.ts — focus on validateEmail function`
52
+
53
+ ## When to Use
54
+ - "plan bug fixes", "report bugs", "create bug list"
55
+ - "generate bug list", "I have some bugs to fix"
56
+ - "these tests are failing", "here's an error log", "parse these errors"
57
+ - After receiving bug reports, error logs, or failed test output
58
+
59
+ **Do NOT use when:**
60
+ - User wants to start fixing bugs now → use `bugfix-pipeline-launcher`
61
+ - User wants to fix a single bug interactively → use `bug-fix-workflow`
62
+ - User wants to plan features → use `feature-planner`
63
+
64
+ ## Intent Routing
65
+
66
+ This skill handles multiple operations. Determine the user's intent and execute the matching operation:
67
+
68
+ | User Intent | Operation | Trigger Phrases |
69
+ |---|---|---|
70
+ | Plan bugs interactively | **Interactive Planning** | "plan bug fixes", "report bugs" |
71
+ | Parse error logs into bugs | **From Log** | "parse this error log", "here's a stack trace", "parse these errors" |
72
+ | Parse test failures into bugs | **From Tests** | "these tests are failing", "parse test output" |
73
+ | Validate existing bug list | **Validate** | "validate bug list", "check .prizmkit/plans/bug-fix-list.json" |
74
+ | Summarize bug list | **Summary** | "bug summary", "show bug list", "list bugs" |
75
+
76
+ ## PowerShell Python Helper
77
+
78
+ Define this helper once in the active PowerShell session before running PrizmKit validation scripts:
79
+
80
+ ```powershell
81
+ function Invoke-PrizmPython {
82
+ param([Parameter(ValueFromRemainingArguments = $true)][string[]]$Arguments)
83
+ $python = Get-Command python -ErrorAction SilentlyContinue
84
+ if ($python) {
85
+ & $python.Source -c 'import sys; raise SystemExit(0 if sys.version_info[0] == 3 else 1)' *> $null
86
+ if ($LASTEXITCODE -eq 0) {
87
+ & $python.Source @Arguments
88
+ return
89
+ }
90
+ }
91
+ $py = Get-Command py -ErrorAction SilentlyContinue
92
+ if ($py) {
93
+ & $py.Source -3 -c 'import sys; raise SystemExit(0 if sys.version_info[0] == 3 else 1)' *> $null
94
+ if ($LASTEXITCODE -eq 0) {
95
+ & $py.Source -3 @Arguments
96
+ return
97
+ }
98
+ }
99
+ throw "Python 3 is required. Install Python and ensure python or py is in PATH."
100
+ }
101
+ ```
102
+
103
+ ## Scenario Routing
104
+
105
+ Classify user intent first:
106
+
107
+ ### Route A: New Bug List (No Existing Plan)
108
+
109
+ Use when no `.prizmkit/plans/bug-fix-list.json` exists.
110
+
111
+ Actions:
112
+ 1. Run full Interactive Planning (Phase 1-5)
113
+ 2. Generate initial `.prizmkit/plans/bug-fix-list.json`
114
+
115
+ ### Route B: Append to Existing Bug List
116
+
117
+ Use when `.prizmkit/plans/bug-fix-list.json` already exists and user wants to add more bugs.
118
+
119
+ Actions:
120
+ 1. Read existing `.prizmkit/plans/bug-fix-list.json` first (if missing, ask whether to start new plan)
121
+ 2. Continue with next sequential `B-NNN` IDs
122
+ 3. Preserve existing entries, append new bugs
123
+ 4. Re-run validation on the merged list
124
+
125
+ ---
126
+
127
+ ## Operation: Interactive Planning
128
+
129
+ Launch the interactive bug planning process through 5 phases.
130
+
131
+ ### Phase 1: Project Context
132
+
133
+ Gather project metadata from the project's own configuration and documentation — bug-planner is independent of feature-planner, so it reads project-level sources directly rather than depending on feature-list.json.
134
+
135
+ 1. **Identify project**: Read project name and description from these sources (first match wins):
136
+ - `.prizmkit/config.json` (`project_name`, `description` fields)
137
+ - `.prizmkit/prizm-docs/root.prizm` (project overview section)
138
+ - `CLAUDE.md` or `CODEBUDDY.md` (project instructions)
139
+ - `package.json` / `pyproject.toml` / `Cargo.toml` (name + description fields)
140
+ - If none found, ask the user
141
+ 2. **Identify tech stack**: Read from these sources (first match wins):
142
+ - `.prizmkit/config.json` `tech_stack` (preferred — contains language, frameworks, DB, etc.)
143
+ - `.prizmkit/prizm-docs/root.prizm` (architecture section)
144
+ - Auto-detect from project files (`package.json`, `requirements.txt`, `go.mod`, etc.)
145
+ - If none found, ask the user
146
+ 3. **Identify testing framework**: Read from `.prizmkit/config.json` `tech_stack.testing`, or auto-detect from package.json/requirements.txt/etc., or ask user
147
+ 4. **Clarify context** — if the project context, affected systems, or bug scope is unclear, ask questions one at a time (cite the unclear point, give a recommended answer with rationale) until you fully understand the environment. No limit on rounds or number of questions.
148
+ 5. **Collect reference materials** — **Upfront Material Detection (Hard Rule)**: If the user has already provided materials (file paths, URLs, rules, specifications, code snippets) in the same message that invoked this skill: (a) Acknowledge what was received: "I received the following materials: [list]"; (b) Read/fetch all provided materials immediately; (c) You MUST still ask: "Are there any additional materials you'd like to provide?"; (d) NEVER skip this collection step just because the user already provided some materials.
149
+
150
+ If the user has NOT provided any materials upfront, explicitly ask whether they have any supplementary materials for you to review before proceeding to bug collection:
151
+ > "Do you have any reference materials I should review to better understand these bugs? This can include:
152
+ > - **Code paths** — files or directories where the bugs likely originate
153
+ > - **Documents** — related design docs, API specs, or architecture docs for the affected area
154
+ > - **Error screenshots** — UI screenshots, console output images, or monitoring dashboards
155
+ > - **Web links** — related issue tracker links, Stack Overflow threads, or documentation pages
156
+ > - **Log files** — error log paths or monitoring tool URLs
157
+ >
158
+ > If none, we'll proceed with bug collection."
159
+
160
+ If the user provides materials, read/fetch them all before proceeding to Phase 2. For web links, use web fetch to retrieve and analyze the content. For images, read and analyze them visually. This context significantly improves bug diagnosis accuracy and description quality.
161
+
162
+ Output: `project_name`, `project_description`, `global_context` fields populated.
163
+
164
+ **Gate → CP-BP-1**: Tech stack and project info confirmed before proceeding.
165
+
166
+ ### Phase 2: Bug Collection
167
+
168
+ Accept bug information in ANY of these formats (auto-detect):
169
+
170
+ #### Severity & Input Format References
171
+
172
+ When classifying severity, read `${SKILL_DIR}/references/severity-rules.md` for the auto-classification table (critical/high/medium/low indicators and special cases).
173
+
174
+ When parsing user input, auto-detect the format and read `${SKILL_DIR}/references/input-formats.md` for extraction patterns. Supported formats: stack traces, user reports, failed tests, log patterns, monitoring alerts.
175
+
176
+ **For each bug collected**, interactively confirm or fill in:
177
+ - Title (auto-suggest from error message, user can edit)
178
+ - Description (auto-generate expected vs actual, user can edit)
179
+ - Severity (auto-suggest based on error type, user can override)
180
+ - Environment (ask or auto-detect from logs)
181
+ - Verification type (suggest `automated` by default, ask user)
182
+ - Acceptance criteria (auto-suggest based on description, user can edit)
183
+ - Model override (optional; if specified, overrides $MODEL env var for this bug fix)
184
+
185
+ **Per-bug clarification** — if the bug's root cause, reproduction steps, expected behavior, or scope is unclear from the provided information, ask focused questions one at a time (cite the unclear point, give a recommended answer with rationale) until the bug is fully understood. Do not finalize a bug entry with ambiguous details. No limit on the number of questions per bug.
186
+
187
+ **Per-bug confirmation (mandatory)** — after extracting and clarifying each bug, present a structured summary using the template in `${SKILL_DIR}/assets/bug-confirmation-template.md`, then ask the three confirmation questions defined there.
188
+
189
+ The acceptance criteria are critical — they directly determine how the bugfix pipeline judges success or failure. Vague criteria like "login works" lead to shallow fixes; prefer specific, verifiable conditions like "POST /api/login with valid credentials returns 200 and a JWT token in the response body."
190
+
191
+ Only finalize the bug entry after user confirms all three points.
192
+
193
+ **Multiple bugs per session**: After each bug, ask "Any more bugs to add? (yes/no)"
194
+
195
+ **Gate → CP-BP-2**: All bugs extracted and confirmed by user.
196
+
197
+ ### Phase 3: Prioritization & Review
198
+
199
+ 1. **Auto-assign priorities**: Based on severity, adjustable by user
200
+
201
+ **Severity → Priority Mapping**:
202
+ - `critical` severity → `high` priority (treated with highest urgency)
203
+ - `high` severity → `high` priority
204
+ - `medium` severity → `medium` priority
205
+ - `low` severity → `low` priority
206
+
207
+ Note: Severity has 4 levels (critical, high, medium, low) but Priority has 3 levels (high, medium, low). Both critical and high severity bugs map to high priority.
208
+ 2. **Display summary table**:
209
+ ```
210
+ ID | Title | Severity | Priority | Verification
211
+ B-001 | Login null reference crash | critical | high | automated
212
+ B-002 | CSV export Chinese encoding | medium | medium | hybrid
213
+ B-003 | Slow dashboard loading | low | low | manual
214
+ ```
215
+ 3. **Ask for adjustments**: "Want to reorder priorities, change severity, or remove any bugs?"
216
+ 4. **Detect potential duplicates**: If two bugs have similar error messages or affected modules, warn user
217
+
218
+ **Gate → CP-BP-3**: Severity/priority assigned, duplicates resolved.
219
+
220
+ ### Phase 4: Pre-Generation Completeness Review
221
+
222
+ Before generating `.prizmkit/plans/bug-fix-list.json`, perform a holistic scan across all collected bugs. The bugfix pipeline runs autonomously — any ambiguity left here becomes a wrong assumption later.
223
+
224
+ **Step 1 — Description adequacy scan (Headless Execution Readiness)**: The bugfix pipeline runs each bug through an autonomous AI session with NO human interaction. Every description must be unambiguous enough for headless execution. For each bug, check:
225
+ - Description clearly states **expected** vs **actual** behavior (not just "X doesn't work")
226
+ - Reproduction path is specific enough for the pipeline AI to locate the relevant code
227
+ - If the bug involves user interaction, the trigger action is described (not just the symptom)
228
+ - **Code location hints**: Where in the codebase should the AI look? (file paths, module names, function names)
229
+ - **Verification method**: How should the AI verify the fix? (run specific test, check specific behavior)
230
+ - Bad: "Login is broken" — too vague, AI will search the entire codebase
231
+ - Good: "Login form at /login returns 500 when password field is empty. Expected: validation error 400. Root cause likely in src/api/auth.ts POST /api/auth/login handler — missing null check on password field."
232
+
233
+ **Step 2 — Acceptance criteria specificity check**: For each bug, verify each acceptance criterion passes the "pipeline autonomy test" — could an AI session, without asking a human, determine whether this criterion is met? Flag criteria that are subjective ("works correctly"), lack measurable conditions ("performs better"), or don't specify the verification method.
234
+
235
+ **Step 3 — Cross-bug analysis**: Check for:
236
+ - **Root cause overlap**: Multiple bugs in the same module may share a root cause — flag for user to confirm whether they should be merged or kept separate
237
+ - **Missing dependencies**: If fixing B-002 requires B-001 to be fixed first, flag the dependency
238
+ - **Scope gaps**: If bugs describe symptoms but the underlying cause likely affects more areas, suggest additional bugs
239
+
240
+ **Step 4 — Present review table**: Display the completeness assessment using the template in `${SKILL_DIR}/assets/bug-confirmation-template.md` (§Completeness Review Template).
241
+
242
+ For any items that need attention, ask targeted questions to fill gaps. Iterate until the user confirms all bugs are adequately described. Present bilingual prompt:
243
+
244
+ > "以上是完整性审查结果。需要补充的项目是否逐一补充?还是先跳过,之后再完善?"
245
+ > "Above is the completeness review. Items needing more detail — address them now, or proceed and refine later?"
246
+
247
+ Only proceed to Phase 5 after user confirms.
248
+
249
+ **Gate → CP-BP-4**: All bugs pass headless execution readiness check.
250
+
251
+ ### Phase 5: Generate & Validate
252
+
253
+ 1. **Write draft JSON**: Write a draft `.prizmkit/plans/bug-fix-list.draft.json` with all collected bug data. Conform to `.prizmkit/dev-pipeline/templates/bug-fix-list-schema.json`.
254
+ 2. **Generate and validate**: Run the generate script to validate and produce the final file:
255
+ ```powershell
256
+ Invoke-PrizmPython ${SKILL_DIR}/scripts/validate-bug-list.py generate --input .prizmkit/plans/bug-fix-list.draft.json --output .prizmkit/plans/bug-fix-list.json
257
+ ```
258
+ The script fills in defaults (`$schema`, `created_at`, `created_by`), validates all fields, and writes the final file only if validation passes.
259
+ 3. **If validation fails**: Fix the draft and retry (max 3 attempts). If the script is unavailable, use the checklist in `${SKILL_DIR}/references/schema-validation.md`.
260
+ 4. **Output**: File path, summary, and next steps
261
+
262
+ **Gate → CP-BP-5**: `bug-fix-list.json` passes validation script with zero errors.
263
+
264
+ #### Success Output
265
+
266
+ ```
267
+ .prizmkit/plans/bug-fix-list.json generated with 3 bugs (1 critical, 1 medium, 1 low)
268
+
269
+ Next steps:
270
+ - Review: Get-Content .prizmkit/plans/bug-fix-list.json
271
+ - Start fixing: say "start fixing" to launch the bugfix pipeline via bugfix-pipeline-launcher
272
+ ```
273
+
274
+ ### Checkpoints (Mandatory Gates)
275
+
276
+ Checkpoints catch cascading errors early — skipping one means the next phase builds on unvalidated assumptions.
277
+
278
+ | Checkpoint | Artifact/State | Criteria | Phase |
279
+ |-----------|----------------|----------|-------|
280
+ | **CP-BP-1** | Project Context | Tech stack and project info confirmed | 1 |
281
+ | **CP-BP-2** | Bugs Collected | All bugs extracted and confirmed by user | 2 |
282
+ | **CP-BP-3** | Priorities Set | Severity/priority assigned, duplicates resolved | 3 |
283
+ | **CP-BP-4** | Completeness Passed | All bugs pass headless execution readiness check | 4 |
284
+ | **CP-BP-5** | File Generated | `bug-fix-list.json` passes validation script | 5 |
285
+
286
+ **Resume Detection**: If existing `.prizmkit/plans/bug-fix-list.json` or draft found, read `${SKILL_DIR}/references/error-recovery.md` §Resume Support for checkpoint-based resumption.
287
+
288
+ ---
289
+
290
+ ## Operation: From Log
291
+
292
+ Batch-parse error logs to generate bug entries without interactive prompts:
293
+
294
+ 1. Accept log file path or piped content
295
+ 2. Parse all unique errors (deduplicate by error message pattern)
296
+ 3. Auto-generate bug entries with:
297
+ - Title: first line of error message
298
+ - Description: full error context
299
+ - Severity: use `${SKILL_DIR}/references/severity-rules.md`
300
+ - error_source: populated from log content
301
+ - verification_type: default to `automated`
302
+ - acceptance_criteria: auto-generate "Error no longer occurs in [scenario]"
303
+ 4. Write draft to `.prizmkit/plans/bug-fix-list.draft.json` for user review
304
+ 5. Ask: "Review and confirm? You can edit individual entries."
305
+ 6. After user confirms, call the generate script:
306
+ ```powershell
307
+ Invoke-PrizmPython ${SKILL_DIR}/scripts/validate-bug-list.py generate --input .prizmkit/plans/bug-fix-list.draft.json --output .prizmkit/plans/bug-fix-list.json
308
+ ```
309
+
310
+ ## Operation: From Tests
311
+
312
+ Batch-parse failed test output:
313
+
314
+ 1. Accept test runner output (Jest, pytest, Go test, etc.)
315
+ 2. Parse each failed test case as a separate bug entry
316
+ 3. Auto-populate `failed_test_path`, `error_message`
317
+ 4. Set verification_type to `automated` (test already exists)
318
+ 5. Write draft to `.prizmkit/plans/bug-fix-list.draft.json`
319
+ 6. After user confirms, call the generate script:
320
+ ```powershell
321
+ Invoke-PrizmPython ${SKILL_DIR}/scripts/validate-bug-list.py generate --input .prizmkit/plans/bug-fix-list.draft.json --output .prizmkit/plans/bug-fix-list.json
322
+ ```
323
+
324
+ ## Operation: Validate
325
+
326
+ Validate existing `.prizmkit/plans/bug-fix-list.json`:
327
+
328
+ 1. Check JSON syntax
329
+ 2. Validate against `.prizmkit/dev-pipeline/templates/bug-fix-list-schema.json`
330
+ 3. Check for:
331
+ - Duplicate IDs
332
+ - Missing required fields
333
+ - Invalid status values
334
+ - Invalid priority values (must be 'high', 'medium', or 'low')
335
+ 4. Output: validation result with specific errors/warnings
336
+
337
+ ## Operation: Summary
338
+
339
+ Print human-readable summary:
340
+
341
+ ```
342
+ Bug Fix List Summary: my-web-app
343
+
344
+ Total: 3 bugs
345
+ By Severity: critical=1, high=0, medium=1, low=1
346
+ By Status: pending=3
347
+
348
+ Bug List (by priority):
349
+ 1. [B-001] Login null reference crash (CRITICAL) — automated
350
+ 2. [B-002] CSV export Chinese encoding (MEDIUM) — hybrid
351
+ 3. [B-003] Slow dashboard loading (LOW) — manual
352
+ ```
353
+
354
+ ---
355
+
356
+ ## Adversarial Critic & Browser Verification
357
+
358
+ When configuring critic settings or browser verification for bugs, read `${SKILL_DIR}/references/critic-and-verification.md` for default behavior tables and verification type guidance.
359
+
360
+ Key points:
361
+ - Critic is enabled by default for critical/high severity, disabled for medium/low
362
+ - Users can override critic settings per-bug during Phase 2 or Phase 3
363
+ - Browser verification is feature-pipeline only — bug fixes use `verification_type` field (automated/manual/hybrid)
364
+
365
+ ---
366
+
367
+ ## Next-Step Execution Policy
368
+
369
+ Recommend invoking `bugfix-pipeline-launcher` to configure and launch the pipeline. Do NOT recommend running shell scripts directly — that is the launcher's responsibility.
370
+
371
+ After `.prizmkit/plans/bug-fix-list.json` is generated, present:
372
+ 1. Summary of generated bugs (count, severity breakdown)
373
+ 2. Recommend: "Say 'start fixing' to launch the bugfix pipeline via `bugfix-pipeline-launcher`"
374
+ 3. Alternative: fix a single bug interactively via `bug-fix-workflow`
375
+
376
+ ## Error Handling
377
+
378
+ If validation fails or a session is interrupted, read `${SKILL_DIR}/references/error-recovery.md` for the full error type table, retry logic, and checkpoint-based resume support.
379
+
380
+ Common errors handled inline:
381
+
382
+ | Error | Action |
383
+ |-------|--------|
384
+ | Cannot parse error log format | Ask user to specify format or provide raw text |
385
+ | Ambiguous severity classification | Present options, ask user to choose |
386
+ | Duplicate bug detected | Warn user, suggest merging or keeping separate |
387
+ | No bugs provided | Prompt with examples of supported input formats |
388
+ | Invalid feature reference | Warn and ask user to correct or remove reference |
389
+ | Schema validation failure | Show specific errors, offer to fix interactively |
390
+
391
+ ## Output
392
+
393
+ - `.prizmkit/plans/bug-fix-list.json` conforming to `.prizmkit/dev-pipeline/templates/bug-fix-list-schema.json`
394
+ - Validation report (if validation run)
395
+ - Summary report (if summary run)
@@ -0,0 +1,43 @@
1
+ # Bug Confirmation Templates
2
+
3
+ ## Per-Bug Confirmation Template
4
+
5
+ Present this after extracting and clarifying each bug:
6
+
7
+ ```
8
+ ┌─ Bug Confirmation: B-NNN ─────────────────────────────
9
+ │ Title: <auto-suggested title>
10
+ │ Description: <expected vs actual behavior>
11
+ │ Severity: <auto-classified> | Verification: <type>
12
+
13
+ │ Reproduction: <steps if available, or "not provided">
14
+ │ Affected: <module/feature or "unknown">
15
+
16
+ │ Acceptance Criteria (fix verified when):
17
+ │ 1. <criterion — specific enough for automated pipeline to verify>
18
+ │ 2. <criterion>
19
+
20
+ │ Open Questions:
21
+ │ - <any unclear points, or "None">
22
+ └────────────────────────────────────────────────────────
23
+ ```
24
+
25
+ Then ask three confirmation questions:
26
+ 1. "描述是否准确?是否需要修改?" / "Is the description accurate? Any corrections?"
27
+ 2. "是否需要补充更多细节?(复现步骤、环境信息、相关代码位置等)" / "Need to add more details? (reproduction steps, environment, related code locations, etc.)"
28
+ 3. "验证条件是否具体到 pipeline 可以自主判断修复成功?" / "Are the acceptance criteria specific enough that the pipeline can autonomously verify the fix?"
29
+
30
+ Only finalize the bug entry after user confirms all three points.
31
+
32
+ ## Completeness Review Template
33
+
34
+ Display during Phase 4 pre-generation review:
35
+
36
+ ```
37
+ ┌─ Completeness Review ─────────────────────────────────────────────────
38
+ │ Bug │ Description │ Criteria │ Reproducible │ Notes
39
+ │ B-001 │ ✓ Clear │ ✓ Specific │ ✓ Yes │ —
40
+ │ B-002 │ ⚠ Vague │ ⚠ Subjective│ ✓ Yes │ "encoding works" → needs specific test case
41
+ │ B-003 │ ✓ Clear │ ⚠ No metric│ ⚠ No steps │ needs perf threshold + reproduction steps
42
+ └────────────────────────────────────────────────────────────────────────
43
+ ```
@@ -0,0 +1,44 @@
1
+ # Adversarial Critic Review & Browser Verification
2
+
3
+ ## Adversarial Critic Review (Testing Defaults)
4
+
5
+ All bug fixes support optional critic review for additional quality assurance. The critic mechanism is disabled by default but can be enabled per-bug based on severity and complexity.
6
+
7
+ ### Default Critic Behavior
8
+
9
+ | Severity | `critic` | `critic_count` | Rationale |
10
+ |----------|----------|----------------|-----------|
11
+ | critical | `true` | `1` | Single critic review for critical bugs |
12
+ | high | `true` | `1` | Single critic review for high-severity bugs |
13
+ | medium | `false` | (omitted) | Skip critic for medium-severity bugs |
14
+ | low | `false` | (omitted) | Skip critic for low-severity bugs |
15
+
16
+ - `critic: true` — Enable adversarial review after fix implementation
17
+ - `critic_count: 1` — Single critic agent reviews the fix
18
+ - Critic verifies: fix addresses root cause, no regressions introduced, acceptance criteria met
19
+
20
+ **User Override**: During Phase 2 or Phase 3, users can opt to enable/disable critic on a per-bug basis.
21
+
22
+ ## Browser Verification
23
+
24
+ **Browser verification is a feature-pipeline capability only.** Bug fixes use the `verification_type` field instead:
25
+
26
+ - `verification_type: automated` — Use unit/integration tests to verify the fix
27
+ - `verification_type: manual` — Describe manual testing steps in acceptance criteria (including any browser verification steps)
28
+ - `verification_type: hybrid` — Combine automated tests with manual browser verification steps
29
+
30
+ For UI-related bugs that require visual verification (e.g., "Button doesn't show error message"), describe the verification steps in acceptance criteria.
31
+
32
+ ### Example
33
+
34
+ ```
35
+ Bug Title: Login error message not displaying
36
+ Verification Type: manual
37
+ Acceptance Criteria:
38
+ 1. Navigate to /login with invalid credentials
39
+ 2. Verify error message "Invalid email or password" appears below the email field
40
+ 3. Verify error message is red (#FF0000)
41
+ 4. Verify form fields are still enabled and can be re-submitted
42
+ ```
43
+
44
+ The bugfix pipeline AI will use these criteria during manual verification.
@@ -0,0 +1,73 @@
1
+ # Error Recovery & Resume Support
2
+
3
+ Reference document for bug-planner error handling and session recovery. Load this when validation fails, a session is interrupted, or existing artifacts are detected.
4
+
5
+ ## Validation Failure Handling
6
+
7
+ ### Warnings Only
8
+
9
+ If `validate-bug-list.py` returns warnings but no errors:
10
+ 1. Present warnings to user
11
+ 2. Ask: "Proceed with these warnings, or fix them first?"
12
+ 3. If user approves → write file and continue
13
+ 4. If user wants fixes → address each warning, re-validate
14
+
15
+ ### Errors Found
16
+
17
+ If validation returns errors:
18
+ 1. Group errors by type (missing fields, invalid values, duplicate IDs, broken references)
19
+ 2. Auto-fix where possible:
20
+ - Missing `status` → set to `pending`
21
+ - Duplicate IDs → re-number with next sequential B-NNN
22
+ - Invalid `priority` → re-derive from severity using the mapping table
23
+ 3. Present fixes to user for confirmation
24
+ 4. Re-validate after fixes
25
+ 5. Maximum 3 total validation attempts — if still failing after 3 rounds, present the raw errors and ask user for guidance
26
+
27
+ ### JSON Parse Failure
28
+
29
+ If the generated JSON is malformed:
30
+ 1. Do not write the file
31
+ 2. Regenerate from the collected bug data (Phase 2-3 state)
32
+ 3. Re-validate before writing
33
+
34
+ ## Resume Support
35
+
36
+ ### Checkpoint-Based Resumption
37
+
38
+ When bug-planner detects existing artifacts, determine the last completed checkpoint and offer to resume:
39
+
40
+ | Existing Artifact | Last Checkpoint | Resume From |
41
+ |---|---|---|
42
+ | `.prizmkit/plans/bug-fix-list.json` (valid) | CP-BP-5 | Offer: "Valid bug list exists. Append new bugs (Route B) or regenerate?" |
43
+ | `.prizmkit/plans/bug-fix-list.json` (invalid) | CP-BP-4 | Re-run Phase 5 validation and fix |
44
+ | `.prizmkit/plans/bug-fix-list.draft.json` | CP-BP-2 or CP-BP-3 | Load draft, determine phase from content completeness, resume |
45
+ | `.prizmkit/config.json` with tech_stack | CP-BP-1 (partial) | Skip project context questions, start at Phase 2 |
46
+ | No artifacts | — | Start from Phase 1 |
47
+
48
+ ### Resume Detection Flow
49
+
50
+ 1. Check for `.prizmkit/plans/bug-fix-list.json`
51
+ - If exists and valid → offer Route B (append) or full regeneration
52
+ - If exists but invalid → offer to fix and re-validate (resume from CP-BP-4)
53
+ 2. Check for `.prizmkit/plans/bug-fix-list.draft.json`
54
+ - If exists → load draft, count bugs with/without confirmation, resume from appropriate phase
55
+ 3. Check for `.prizmkit/config.json`
56
+ - If exists with tech_stack → skip Phase 1 context gathering
57
+ 4. If no artifacts → start fresh (Route A)
58
+
59
+ ### Session Interruption Recovery
60
+
61
+ If a bug-planner session is interrupted mid-planning:
62
+
63
+ 1. On next invocation, run the Resume Detection Flow above
64
+ 2. If a draft exists, present: "Found a draft with N bugs from a previous session. Resume from where you left off, or start fresh?"
65
+ 3. If user resumes → load draft state, skip completed phases
66
+ 4. If user starts fresh → archive draft as `bug-fix-list.draft.TIMESTAMP.json`, begin Phase 1
67
+
68
+ ## Draft Management
69
+
70
+ - Save drafts to `.prizmkit/plans/bug-fix-list.draft.json` after each completed phase (CP-BP-1 through CP-BP-4)
71
+ - Drafts use the same schema as the final file but may have incomplete fields
72
+ - Delete draft after successful generation of the final `bug-fix-list.json`
73
+ - Keep at most 1 draft — overwrite on each phase completion
@@ -0,0 +1,53 @@
1
+ # Bug Input Format Detection & Extraction
2
+
3
+ Auto-detect the user's input format and extract structured bug information accordingly.
4
+
5
+ ## Format A: Stack Trace / Error Log
6
+
7
+ ```
8
+ TypeError: Cannot read property 'token' of null
9
+ at AuthService.handleLogin (src/services/auth.ts:42)
10
+ at LoginPage.onSubmit (src/pages/login.tsx:28)
11
+ ```
12
+
13
+ Extract: `error_source.type="stack_trace"`, `error_message`, `stack_trace`, `affected_modules`
14
+
15
+ ## Format B: Natural Language User Report
16
+
17
+ ```
18
+ When I click the login button with correct credentials, the page turns white.
19
+ Expected: redirect to home page.
20
+ Actual: white screen with no error message visible.
21
+ ```
22
+
23
+ Extract: `error_source.type="user_report"`, `reproduction_steps`, `description` (expected vs actual)
24
+
25
+ ## Format C: Failed Test Output
26
+
27
+ ```
28
+ FAIL src/services/__tests__/auth.test.ts
29
+ ● AuthService > handleLogin > should return token on success
30
+ Expected: "abc123"
31
+ Received: null
32
+ ```
33
+
34
+ Extract: `error_source.type="failed_test"`, `failed_test_path`, `error_message`
35
+
36
+ ## Format D: Log Pattern
37
+
38
+ ```
39
+ [2026-03-07 10:23:45] ERROR [auth-service] Connection timeout after 30000ms
40
+ [2026-03-07 10:23:45] ERROR [auth-service] Failed to authenticate user: ETIMEDOUT
41
+ [2026-03-07 10:23:46] ERROR [auth-service] Connection timeout after 30000ms
42
+ ```
43
+
44
+ Extract: `error_source.type="log_pattern"`, `log_snippet`, `affected_modules`
45
+
46
+ ## Format E: Monitoring Alert
47
+
48
+ ```
49
+ ALERT: CPU usage > 95% for auth-service pod (5min avg)
50
+ ALERT: Error rate spike: 500 errors/min on /api/login endpoint
51
+ ```
52
+
53
+ Extract: `error_source.type="monitoring_alert"`, `error_message`, `affected_modules`
@@ -0,0 +1,25 @@
1
+ # Schema Validation Checklist
2
+
3
+ Use this checklist for manual validation when `validate-bug-list.py` is not available. The script is the source of truth — this checklist mirrors its logic.
4
+
5
+ ## Required Top-Level Fields
6
+
7
+ - [ ] `$schema`: must be `"dev-pipeline-bug-fix-list-v1"`
8
+ - [ ] `project_name`: non-empty string
9
+ - [ ] `bugs`: non-empty array
10
+
11
+ ## Per-Bug Required Fields
12
+
13
+ - [ ] `id`: matches pattern `B-NNN` (e.g., `B-001`)
14
+ - [ ] `title`: non-empty string
15
+ - [ ] `description`: non-empty string
16
+ - [ ] `severity`: one of `critical`, `high`, `medium`, `low`
17
+ - [ ] `error_source.type`: one of `stack_trace`, `user_report`, `failed_test`, `log_pattern`, `monitoring_alert`
18
+ - [ ] `verification_type`: one of `automated`, `manual`, `hybrid`
19
+ - [ ] `acceptance_criteria`: non-empty array of strings
20
+ - [ ] `status`: must be `pending` for new bugs
21
+
22
+ ## Consistency Checks
23
+
24
+ - [ ] No duplicate bug IDs
25
+ - [ ] If `priority` is set, must be one of `high`, `medium`, `low`
@@ -0,0 +1,16 @@
1
+ # Severity Auto-Classification Rules
2
+
3
+ When extracting bugs, apply these rules to auto-suggest severity:
4
+
5
+ | Severity | Indicators | Examples |
6
+ |----------|------------|----------|
7
+ | **critical** | System crash, data loss, security breach, OOM, unrecoverable error | `Segmentation fault`, `OutOfMemoryError`, `SQL injection vulnerability`, `Database corrupted` |
8
+ | **high** | Core feature broken, authentication failure, data integrity issue, timeout | `Auth token invalid`, `Payment failed`, `Connection timeout`, `500 Internal Server Error` |
9
+ | **medium** | Feature partially broken, workaround exists, incorrect output | `CSV encoding issue`, `Pagination not working`, `Wrong date format`, `Missing validation` |
10
+ | **low** | Cosmetic issue, minor inconvenience, edge case | `UI misalignment`, `Typo in error message`, `Slow loading (non-critical page)`, `Non-breaking warning` |
11
+
12
+ ## Special Cases
13
+
14
+ - Failed test → medium (unless test covers critical path, then high)
15
+ - User report with "cannot use app" → high
16
+ - User report with "annoying but works" → low