@rpamis/comet 0.1.8 → 0.2.0

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 (65) hide show
  1. package/README.md +25 -5
  2. package/assets/manifest.json +2 -0
  3. package/assets/skills/comet/SKILL.md +214 -219
  4. package/assets/skills/comet/scripts/comet-state.sh +1 -0
  5. package/assets/skills/comet-archive/SKILL.md +2 -2
  6. package/assets/skills/comet-build/SKILL.md +1 -1
  7. package/assets/skills/comet-design/SKILL.md +1 -1
  8. package/assets/skills/comet-hotfix/SKILL.md +136 -133
  9. package/assets/skills/comet-open/SKILL.md +1 -1
  10. package/assets/skills/comet-tweak/SKILL.md +122 -120
  11. package/assets/skills/comet-verify/SKILL.md +2 -4
  12. package/assets/skills-zh/comet/SKILL.md +87 -98
  13. package/assets/skills-zh/comet-archive/SKILL.md +63 -63
  14. package/assets/skills-zh/comet-build/SKILL.md +153 -153
  15. package/assets/skills-zh/comet-design/SKILL.md +91 -91
  16. package/assets/skills-zh/comet-hotfix/SKILL.md +10 -7
  17. package/assets/skills-zh/comet-open/SKILL.md +70 -70
  18. package/assets/skills-zh/comet-tweak/SKILL.md +11 -9
  19. package/assets/skills-zh/comet-verify/SKILL.md +114 -116
  20. package/dist/cli/index.js +28 -1
  21. package/dist/cli/index.js.map +1 -1
  22. package/dist/commands/doctor.d.ts +6 -0
  23. package/dist/commands/doctor.d.ts.map +1 -0
  24. package/dist/commands/doctor.js +168 -0
  25. package/dist/commands/doctor.js.map +1 -0
  26. package/dist/commands/init.d.ts +9 -0
  27. package/dist/commands/init.d.ts.map +1 -0
  28. package/dist/commands/init.js +183 -0
  29. package/dist/commands/init.js.map +1 -0
  30. package/dist/commands/status.d.ts +6 -0
  31. package/dist/commands/status.d.ts.map +1 -0
  32. package/dist/commands/status.js +89 -0
  33. package/dist/commands/status.js.map +1 -0
  34. package/dist/commands/update.d.ts +8 -0
  35. package/dist/commands/update.d.ts.map +1 -0
  36. package/dist/commands/update.js +47 -0
  37. package/dist/commands/update.js.map +1 -0
  38. package/dist/core/detect.d.ts +8 -0
  39. package/dist/core/detect.d.ts.map +1 -0
  40. package/dist/core/detect.js +73 -0
  41. package/dist/core/detect.js.map +1 -0
  42. package/dist/core/openspec.d.ts +5 -0
  43. package/dist/core/openspec.d.ts.map +1 -0
  44. package/dist/core/openspec.js +58 -0
  45. package/dist/core/openspec.js.map +1 -0
  46. package/dist/core/platforms.d.ts.map +1 -1
  47. package/dist/core/platforms.js +6 -1
  48. package/dist/core/platforms.js.map +1 -1
  49. package/dist/core/skills.d.ts +22 -0
  50. package/dist/core/skills.d.ts.map +1 -0
  51. package/dist/core/skills.js +59 -0
  52. package/dist/core/skills.js.map +1 -0
  53. package/dist/core/superpowers.d.ts +5 -0
  54. package/dist/core/superpowers.d.ts.map +1 -0
  55. package/dist/core/superpowers.js +60 -0
  56. package/dist/core/superpowers.js.map +1 -0
  57. package/dist/core/types.d.ts +2 -0
  58. package/dist/core/types.d.ts.map +1 -0
  59. package/dist/core/types.js +2 -0
  60. package/dist/core/types.js.map +1 -0
  61. package/package.json +61 -50
  62. package/dist/core/init.d.ts +0 -14
  63. package/dist/core/init.d.ts.map +0 -1
  64. package/dist/core/init.js +0 -492
  65. package/dist/core/init.js.map +0 -1
@@ -1,133 +1,136 @@
1
- ---
2
- name: comet-hotfix
3
- description: "Comet preset path: Bug fix / hotfix. Skip brainstorming, directly open → build → verify → archive. Applicable for behavior fixes, scenarios not involving new capability design."
4
- ---
5
-
6
- # Comet Preset Path: Hotfix
7
-
8
- Hotfix is a preset workflow of Comet's five-phase capabilities, not a separate parallel process. It reuses open, build, verify, archive capabilities, only skipping brainstorming and full plan.
9
-
10
- Applicable for bug fixes, hotfixes, small-scale behavior corrections. Does not involve new capability design, does not require deep brainstorming.
11
-
12
- **Applicable conditions** (all must be met):
13
- 1. Fix bugs in existing functionality, no new capability
14
- 2. No interface changes or architecture adjustments
15
- 3. Change scope is predictable (usually < 5 files)
16
-
17
- **Not applicable**: If fix process discovers need for architecture adjustments, should upgrade to full `/comet` workflow.
18
-
19
- ---
20
-
21
- ## Process (preset workflow, 4 phases)
22
-
23
- ### 0. Entry State Verification (Entry Check)
24
-
25
- Execute entry verification:
26
-
27
- ```bash
28
- COMET_STATE=$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)
29
- bash "$COMET_STATE" check <name> open
30
- ```
31
-
32
- Proceed to process steps after verification passes. The script outputs specific failure reasons when verification fails.
33
-
34
- Execution chain: open → build → verify → archive. Hotfix provides default decisions for each phase: streamlined open, direct build, scale-based verification, archive after verification passes.
35
-
36
- ### 1. Quick Open (preset open)
37
-
38
- Reuse Comet open capability to create change, but use hotfix defaults: do not execute `openspec-explore` long exploration, directly enter streamlined change creation.
39
-
40
- **Immediately execute:** Use the Skill tool to load the `openspec-new-change` skill. Skipping this step is prohibited.
41
-
42
- After the skill loads, follow its guidance to create streamlined artifacts:
43
- - `proposal.md` — problem description + root cause analysis + fix goal (no solution comparison needed)
44
- - `design.md` — fix solution (one is enough, no multi-solution comparison needed)
45
- - `tasks.md` — fix task list
46
- - **No delta spec needed** (unless fix changes existing spec acceptance scenarios)
47
-
48
- Initialize Comet state file:
49
-
50
- ```bash
51
- bash "$COMET_STATE" init <name> hotfix
52
- ```
53
-
54
- ### 2. Direct Build (preset build)
55
-
56
- Use hotfix defaults: `build_mode: direct`. Skip `superpowers:brainstorming` and `superpowers:writing-plans` (unless tasks > 3; if exceeds 3 tasks, transfer to `/comet-build`'s plan and execution method selection).
57
-
58
- **Immediately execute:** Execute tasks one by one according to tasks.md:
59
-
60
- 1. Read `openspec/changes/<name>/tasks.md`, get incomplete task list
61
- 2. For each incomplete task:
62
- - Modify code according to task description
63
- - Run `mvn spotless:apply` to format
64
- - Run related tests to confirm pass
65
- - Check corresponding `- [ ]` to `- [x]` in tasks.md
66
- - Commit code, commit message format: `fix: <brief fix description>`
67
- 3. After all tasks complete, enter verification
68
-
69
- **If fix affects existing spec acceptance scenarios**:
70
- - Create delta spec in `openspec/changes/<name>/specs/<capability>/spec.md`
71
- - Only include `## MODIFIED Requirements` section
72
-
73
- ### 3. Verification (preset verify)
74
-
75
- Reuse `/comet-verify`, with comet-verify's scale assessment deciding lightweight or full verification.
76
-
77
- **Immediately execute:** Use the Skill tool to load the `comet-verify` skill. Skipping this step is prohibited.
78
-
79
- Small-scale hotfixes without delta spec usually meet lightweight verification conditions (≤ 3 tasks, ≤ 5 files), comet-verify's scale assessment will select lightweight verification path (5 quick checks). If hotfix created delta spec, enter full verification path according to comet-verify's scale assessment rules.
80
-
81
- **Additional Hotfix-Exclusive Checks** (execute after comet-verify lightweight verification passes):
82
-
83
- 1. **Root cause elimination**: Compare proposal.md's root cause analysis, confirm problem code eliminated
84
- - Read bug description and root cause in proposal.md
85
- - Search and verify problem code no longer exists
86
- - If root cause not eliminated, return to Step 2 to continue fix
87
-
88
- **Verification phase upgrade conditions**:
89
- - Regression testing reveals deep architecture issues → Stop hotfix, upgrade to `/comet`
90
- - Fix requires additional interface changes → Stop hotfix, upgrade to `/comet`
91
-
92
- After verification passes, record `.comet.yaml` `verify_result` as `pass` according to `/comet-verify` rules, must not skip this status before archiving.
93
-
94
- ### 4. Archive (preset archive)
95
-
96
- Reuse `/comet-archive`. Must satisfy `verify_result: pass` in `.comet.yaml` before archiving.
97
-
98
- **Immediately execute:** Use the Skill tool to load the `comet-archive` skill to archive. Skipping this step is prohibited.
99
- If there is delta spec, sync to main spec according to comet-archive rules, and handle associated Design Doc and Plan archiving annotations.
100
-
101
- ---
102
-
103
- ## Continuous Execution Mode
104
-
105
- <IMPORTANT>
106
- Hotfix workflow is **one-time continuous execution**. After invoking `/comet-hotfix`, agent must automatically complete all 4 phases, without pausing to wait for user input mid-way (unless encountering upgrade conditions requiring user confirmation).
107
-
108
- Execution order: quick open → direct build → verification → archive → complete
109
-
110
- After each phase completes, immediately enter next phase, no need for user input again. Within each phase, must still call corresponding Comet/OpenSpec/Superpowers skill according to above requirements.
111
- </IMPORTANT>
112
-
113
- ---
114
-
115
- ## Upgrade Conditions
116
-
117
- When the following situations occur during fix process, stop hotfix workflow, upgrade to full `/comet`:
118
-
119
- 1. Root cause discovered involves architecture defects
120
- 2. Fix requires new interfaces or components
121
- 3. Impact scope expands to > 10 files
122
- 4. Needs new capability spec
123
-
124
- Upgrade method: On current change basis, supplement Design Doc (execute `/comet-design`), then proceed normally with full workflow.
125
-
126
- ---
127
-
128
- ## Exit Conditions
129
-
130
- - Bug fixed, tests pass
131
- - Change archived
132
- - If spec changes, synced to main spec
133
- - **Phase guard**: Before build → verify run `bash $COMET_GUARD <change-name> build`, before verify → archive run `bash $COMET_GUARD <change-name> verify`
1
+ ---
2
+ name: comet-hotfix
3
+ description: "Comet preset path: Bug fix / hotfix. Skip brainstorming, directly open → build → verify → archive. Applicable for behavior fixes, scenarios not involving new capability design."
4
+ ---
5
+
6
+ # Comet Preset Path: Hotfix
7
+
8
+ Hotfix is a preset workflow of Comet's five-phase capabilities, not a separate parallel process. It reuses open, build, verify, archive capabilities, only skipping brainstorming and full plan.
9
+
10
+ Applicable for bug fixes, hotfixes, small-scale behavior corrections. Does not involve new capability design, does not require deep brainstorming.
11
+
12
+ **Applicable conditions** (all must be met):
13
+ 1. Fix bugs in existing functionality, no new capability
14
+ 2. No interface changes or architecture adjustments
15
+ 3. Change scope is predictable (usually < 5 files)
16
+
17
+ **Not applicable**: If fix process discovers need for architecture adjustments, should upgrade to full `/comet` workflow.
18
+
19
+ ---
20
+
21
+ ## Process (preset workflow, 4 phases)
22
+
23
+ ### 0. Entry State Verification (Entry Check)
24
+
25
+ Execute entry verification:
26
+
27
+ ```bash
28
+ COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
29
+ bash "$COMET_STATE" check <name> open
30
+ ```
31
+
32
+ Proceed to process steps after verification passes. The script outputs specific failure reasons when verification fails.
33
+
34
+ Execution chain: open → build → verify → archive. Hotfix provides default decisions for each phase: streamlined open, direct build, scale-based verification, archive after verification passes.
35
+
36
+ ### 1. Quick Open (preset open)
37
+
38
+ Reuse Comet open capability to create change, but use hotfix defaults: do not execute `openspec-explore` long exploration, directly enter streamlined change creation.
39
+
40
+ **Immediately execute:** Use the Skill tool to load the `openspec-new-change` skill. Skipping this step is prohibited.
41
+
42
+ After the skill loads, follow its guidance to create streamlined artifacts:
43
+ - `proposal.md` — problem description + root cause analysis + fix goal (no solution comparison needed)
44
+ - `design.md` — fix solution (one is enough, no multi-solution comparison needed)
45
+ - `tasks.md` — fix task list
46
+ - **No delta spec needed** (unless fix changes existing spec acceptance scenarios)
47
+
48
+ Initialize Comet state file:
49
+
50
+ ```bash
51
+ bash "$COMET_STATE" init <name> hotfix
52
+ ```
53
+
54
+ ### 2. Direct Build (preset build)
55
+
56
+ Use hotfix defaults: `build_mode: direct`. Skip `superpowers:brainstorming` and `superpowers:writing-plans` (unless tasks > 3; if exceeds 3 tasks, transfer to `/comet-build`'s plan and execution method selection).
57
+
58
+ **Immediately execute:** Execute tasks one by one according to tasks.md:
59
+
60
+ 1. Read `openspec/changes/<name>/tasks.md`, get incomplete task list
61
+ 2. For each incomplete task:
62
+ - Modify code according to task description
63
+ - Run project formatter (e.g., `mvn spotless:apply`, `npm run format`)
64
+ - Run related tests to confirm pass
65
+ - Check corresponding `- [ ]` to `- [x]` in tasks.md
66
+ - Commit code, commit message format: `fix: <brief fix description>`
67
+ 3. After all tasks complete, enter verification
68
+
69
+ **If fix affects existing spec acceptance scenarios**:
70
+ - Create delta spec in `openspec/changes/<name>/specs/<capability>/spec.md`
71
+ - Only include `## MODIFIED Requirements` section
72
+
73
+ ### 3. Verification (preset verify)
74
+
75
+ Reuse `/comet-verify`, with comet-verify's scale assessment deciding lightweight or full verification.
76
+
77
+ **Immediately execute:** Use the Skill tool to load the `comet-verify` skill. Skipping this step is prohibited.
78
+
79
+ Small-scale hotfixes without delta spec usually meet lightweight verification conditions (≤ 3 tasks, ≤ 5 files), comet-verify's scale assessment will select lightweight verification path (5 quick checks). If hotfix created delta spec, enter full verification path according to comet-verify's scale assessment rules.
80
+
81
+ **Additional Hotfix-Exclusive Checks** (execute after comet-verify lightweight verification passes):
82
+
83
+ 1. **Root cause elimination**: Compare proposal.md's root cause analysis, confirm problem code eliminated
84
+ - Read bug description and root cause in proposal.md
85
+ - Search and verify problem code no longer exists
86
+ - If root cause not eliminated, return to Step 2 to continue fix
87
+
88
+ **Verification phase upgrade conditions**:
89
+ - Regression testing reveals deep architecture issues → Stop hotfix, upgrade to `/comet`
90
+ - Fix requires additional interface changes → Stop hotfix, upgrade to `/comet`
91
+
92
+ After verification passes, record `.comet.yaml` `verify_result` as `pass` according to `/comet-verify` rules, must not skip this status before archiving.
93
+
94
+ ### 4. Archive (preset archive)
95
+
96
+ Reuse `/comet-archive`. Must satisfy `verify_result: pass` in `.comet.yaml` before archiving.
97
+
98
+ **Immediately execute:** Use the Skill tool to load the `comet-archive` skill to archive. Skipping this step is prohibited.
99
+ If there is delta spec, sync to main spec according to comet-archive rules, and handle associated Design Doc and Plan archiving annotations.
100
+
101
+ ---
102
+
103
+ ## Continuous Execution Mode
104
+
105
+ <IMPORTANT>
106
+ Hotfix workflow is **one-time continuous execution**. After invoking `/comet-hotfix`, agent must automatically complete all 4 phases, without pausing to wait for user input mid-way (unless encountering upgrade conditions requiring user confirmation).
107
+
108
+ Execution order: quick open → direct build → verification → archive → complete
109
+
110
+ After each phase completes, immediately enter next phase, no need for user input again. Within each phase, must still call corresponding Comet/OpenSpec/Superpowers skill according to above requirements.
111
+ </IMPORTANT>
112
+
113
+ ---
114
+
115
+ ## Upgrade Conditions
116
+
117
+ Upgrade to full `/comet` when **any** of the following conditions are met:
118
+
119
+ | Condition | Explanation |
120
+ |-----------|-------------|
121
+ | Change involves **3+ files** | Exceeds single-point fix scope |
122
+ | Architecture changes | New modules, new interfaces, new dependencies |
123
+ | Database schema changes | Structural adjustments |
124
+ | Introduces new public API | Fix creates new external interface |
125
+ | Fix scope exceeds single function/module | Requires coordinated changes |
126
+
127
+ Upgrade method: On current change basis, supplement Design Doc (execute `/comet-design`), then proceed normally with full workflow.
128
+
129
+ ---
130
+
131
+ ## Exit Conditions
132
+
133
+ - Bug fixed, tests pass
134
+ - Change archived
135
+ - If spec changes, synced to main spec
136
+ - **Phase guard**: Before build → verify run `bash $COMET_GUARD <change-name> build`, before verify → archive run `bash $COMET_GUARD <change-name> verify`
@@ -16,7 +16,7 @@ description: "Comet Phase 1: Open. Invoke with /comet-open. Explore ideas throug
16
16
  Execute entry verification:
17
17
 
18
18
  ```bash
19
- COMET_STATE=$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)
19
+ COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
20
20
  bash "$COMET_STATE" check <name> open
21
21
  ```
22
22
 
@@ -1,120 +1,122 @@
1
- ---
2
- name: comet-tweak
3
- description: "Comet preset path: Non-bug small changes (tweak). Skip brainstorming and full plan, directly open → lightweight build → light verify → archive. Applicable for copy, configuration, documentation or prompt local optimization."
4
- ---
5
-
6
- # Comet Preset Path: Tweak
7
-
8
- Tweak is a preset workflow of Comet's five-phase capabilities, not a separate parallel process. It reuses open, build, verify, archive capabilities, only skipping brainstorming and full plan.
9
-
10
- Applicable for small-scale non-bug changes, such as copy adjustments, configuration adjustments, documentation or prompt local optimization.
11
-
12
- **Applicable conditions** (all must be met):
13
- 1. No new capability
14
- 2. No architecture changes
15
- 3. No interface changes involved
16
- 4. Usually not exceeding 3 tasks, 5 files
17
-
18
- **Not applicable**: If change process discovers need for capability, architecture, or interface adjustments, should upgrade to full `/comet` workflow.
19
-
20
- ---
21
-
22
- ## Process (preset workflow, 4 phases)
23
-
24
- ### 0. Entry State Verification (Entry Check)
25
-
26
- Execute entry verification:
27
-
28
- ```bash
29
- COMET_STATE=$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)
30
- bash "$COMET_STATE" check <name> open
31
- ```
32
-
33
- Proceed to process steps after verification passes. The script outputs specific failure reasons when verification fails.
34
-
35
- Execution chain: open → lightweight build → light verify → archive. Tweak provides default decisions for each phase: streamlined open, lightweight build, lightweight verification, archive after verification passes.
36
-
37
- ### 1. Quick Open (preset open)
38
-
39
- Reuse Comet open capability to create change, but use tweak defaults: do not execute `openspec-explore` long exploration, directly enter streamlined change creation.
40
-
41
- **Immediately execute:** Use the Skill tool to load the `openspec-new-change` skill. Skipping this step is prohibited.
42
-
43
- After the skill loads, follow its guidance to create streamlined artifacts:
44
- - `proposal.md` — change motivation + goals + scope
45
- - `design.md` — brief implementation description (no solution comparison needed)
46
- - `tasks.md` — not exceeding 3 tasks
47
- - **No delta spec needed** (unless change changes existing spec acceptance scenarios; once delta spec needed, upgrade to full `/comet`)
48
-
49
- Initialize Comet state file:
50
-
51
- ```bash
52
- bash "$COMET_STATE" init <name> tweak
53
- ```
54
-
55
- ### 2. Lightweight Build (preset build)
56
-
57
- Use tweak defaults: `build_mode: direct`. Skip `superpowers:brainstorming` and `superpowers:writing-plans`.
58
-
59
- **Immediately execute:** Execute tasks one by one according to tasks.md:
60
-
61
- 1. Read `openspec/changes/<name>/tasks.md`, get incomplete task list
62
- 2. For each incomplete task:
63
- - Modify target file according to task description
64
- - Run `mvn spotless:apply` to format
65
- - Run related tests to confirm pass
66
- - Check corresponding `- [ ]` to `- [x]` in tasks.md
67
- - Commit code, commit message format: `tweak: <brief change description>`
68
- 3. After all tasks complete, enter verification
69
-
70
- ### 3. Lightweight Verification (preset verify)
71
-
72
- Reuse `/comet-verify`. Tweak must maintain lightweight verification conditions: ≤ 3 tasks, ≤ 5 files, no delta spec, no new capability.
73
-
74
- **Immediately execute:** Use the Skill tool to load the `comet-verify` skill. Skipping this step is prohibited.
75
-
76
- If scale assessment enters full verification path, stop tweak, upgrade to full `/comet`.
77
-
78
- After verification passes, record `.comet.yaml` `verify_result` as `pass` according to `/comet-verify` rules, must not skip this status before archiving.
79
-
80
- ### 4. Archive (preset archive)
81
-
82
- Reuse `/comet-archive`. Must satisfy `verify_result: pass` in `.comet.yaml` before archiving.
83
-
84
- **Immediately execute:** Use the Skill tool to load the `comet-archive` skill to archive. Skipping this step is prohibited.
85
-
86
- ---
87
-
88
- ## Continuous Execution Mode
89
-
90
- <IMPORTANT>
91
- Tweak workflow is **one-time continuous execution**. After invoking `/comet-tweak`, agent must automatically complete all 4 phases, without pausing to wait for user input mid-way (unless encountering upgrade conditions requiring user confirmation).
92
-
93
- Execution order: quick open → lightweight build → lightweight verification → archive → complete
94
-
95
- After each phase completes, immediately enter next phase, no need for user input again. Within each phase, must still call corresponding Comet/OpenSpec/Superpowers skill according to above requirements.
96
- </IMPORTANT>
97
-
98
- ---
99
-
100
- ## Upgrade Conditions
101
-
102
- When the following situations occur during execution, stop tweak workflow, upgrade to full `/comet`:
103
-
104
- 1. Need new capability
105
- 2. Need architecture adjustments
106
- 3. Need interface changes
107
- 4. Impact scope expands to > 5 files
108
- 5. Task count exceeds 3
109
- 6. Need delta spec
110
-
111
- Upgrade method: On current change basis, supplement Design Doc (execute `/comet-design`), then proceed normally with full workflow.
112
-
113
- ---
114
-
115
- ## Exit Conditions
116
-
117
- - Small change completed, tests pass
118
- - Change archived
119
- - No new capability, architecture adjustments, or interface changes
120
- - **Phase guard**: Before build → verify run `bash $COMET_GUARD <change-name> build`, before verify → archive run `bash $COMET_GUARD <change-name> verify`
1
+ ---
2
+ name: comet-tweak
3
+ description: "Comet preset path: Non-bug small changes (tweak). Skip brainstorming and full plan, directly open → lightweight build → light verify → archive. Applicable for copy, configuration, documentation or prompt local optimization."
4
+ ---
5
+
6
+ # Comet Preset Path: Tweak
7
+
8
+ Tweak is a preset workflow of Comet's five-phase capabilities, not a separate parallel process. It reuses open, build, verify, archive capabilities, only skipping brainstorming and full plan.
9
+
10
+ Applicable for small-scale non-bug changes, such as copy adjustments, configuration adjustments, documentation or prompt local optimization.
11
+
12
+ **Applicable conditions** (all must be met):
13
+ 1. No new capability
14
+ 2. No architecture changes
15
+ 3. No interface changes involved
16
+ 4. Usually not exceeding 3 tasks, 5 files
17
+
18
+ **Not applicable**: If change process discovers need for capability, architecture, or interface adjustments, should upgrade to full `/comet` workflow.
19
+
20
+ ---
21
+
22
+ ## Process (preset workflow, 4 phases)
23
+
24
+ ### 0. Entry State Verification (Entry Check)
25
+
26
+ Execute entry verification:
27
+
28
+ ```bash
29
+ COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
30
+ bash "$COMET_STATE" check <name> open
31
+ ```
32
+
33
+ Proceed to process steps after verification passes. The script outputs specific failure reasons when verification fails.
34
+
35
+ Execution chain: open → lightweight build → light verify → archive. Tweak provides default decisions for each phase: streamlined open, lightweight build, lightweight verification, archive after verification passes.
36
+
37
+ ### 1. Quick Open (preset open)
38
+
39
+ Reuse Comet open capability to create change, but use tweak defaults: do not execute `openspec-explore` long exploration, directly enter streamlined change creation.
40
+
41
+ **Immediately execute:** Use the Skill tool to load the `openspec-new-change` skill. Skipping this step is prohibited.
42
+
43
+ After the skill loads, follow its guidance to create streamlined artifacts:
44
+ - `proposal.md` — change motivation + goals + scope
45
+ - `design.md` — brief implementation description (no solution comparison needed)
46
+ - `tasks.md` — not exceeding 3 tasks
47
+ - **No delta spec needed** (unless change changes existing spec acceptance scenarios; once delta spec needed, upgrade to full `/comet`)
48
+
49
+ Initialize Comet state file:
50
+
51
+ ```bash
52
+ bash "$COMET_STATE" init <name> tweak
53
+ ```
54
+
55
+ ### 2. Lightweight Build (preset build)
56
+
57
+ Use tweak defaults: `build_mode: direct`. Skip `superpowers:brainstorming` and `superpowers:writing-plans`.
58
+
59
+ **Immediately execute:** Execute tasks one by one according to tasks.md:
60
+
61
+ 1. Read `openspec/changes/<name>/tasks.md`, get incomplete task list
62
+ 2. For each incomplete task:
63
+ - Modify target file according to task description
64
+ - Run project formatter (e.g., `mvn spotless:apply`, `npm run format`)
65
+ - Run related tests to confirm pass
66
+ - Check corresponding `- [ ]` to `- [x]` in tasks.md
67
+ - Commit code, commit message format: `tweak: <brief change description>`
68
+ 3. After all tasks complete, enter verification
69
+
70
+ ### 3. Lightweight Verification (preset verify)
71
+
72
+ Reuse `/comet-verify`. Tweak must maintain lightweight verification conditions: ≤ 3 tasks, ≤ 5 files, no delta spec, no new capability.
73
+
74
+ **Immediately execute:** Use the Skill tool to load the `comet-verify` skill. Skipping this step is prohibited.
75
+
76
+ If scale assessment enters full verification path, stop tweak, upgrade to full `/comet`.
77
+
78
+ After verification passes, record `.comet.yaml` `verify_result` as `pass` according to `/comet-verify` rules, must not skip this status before archiving.
79
+
80
+ ### 4. Archive (preset archive)
81
+
82
+ Reuse `/comet-archive`. Must satisfy `verify_result: pass` in `.comet.yaml` before archiving.
83
+
84
+ **Immediately execute:** Use the Skill tool to load the `comet-archive` skill to archive. Skipping this step is prohibited.
85
+
86
+ ---
87
+
88
+ ## Continuous Execution Mode
89
+
90
+ <IMPORTANT>
91
+ Tweak workflow is **one-time continuous execution**. After invoking `/comet-tweak`, agent must automatically complete all 4 phases, without pausing to wait for user input mid-way (unless encountering upgrade conditions requiring user confirmation).
92
+
93
+ Execution order: quick open → lightweight build → lightweight verification → archive → complete
94
+
95
+ After each phase completes, immediately enter next phase, no need for user input again. Within each phase, must still call corresponding Comet/OpenSpec/Superpowers skill according to above requirements.
96
+ </IMPORTANT>
97
+
98
+ ---
99
+
100
+ ## Upgrade Conditions
101
+
102
+ Upgrade to full `/comet` when **any** of the following conditions are met:
103
+
104
+ | Condition | Explanation |
105
+ |-----------|-------------|
106
+ | Change involves **5+ files** | Exceeds small change scope |
107
+ | Cross-module coordination required | Needs coordination across components |
108
+ | **5+** new test cases needed | Change complexity increasing |
109
+ | Config item additions or deletions | Non-value config changes |
110
+ | New capability needed | Exceeds local optimization |
111
+ | Delta spec needed | Affects existing specifications |
112
+
113
+ Upgrade method: On current change basis, supplement Design Doc (execute `/comet-design`), then proceed normally with full workflow.
114
+
115
+ ---
116
+
117
+ ## Exit Conditions
118
+
119
+ - Small change completed, tests pass
120
+ - Change archived
121
+ - No new capability, architecture adjustments, or interface changes
122
+ - **Phase guard**: Before build → verify run `bash $COMET_GUARD <change-name> build`, before verify → archive run `bash $COMET_GUARD <change-name> verify`
@@ -17,7 +17,7 @@ description: "Comet Phase 4: Verify and Complete. Invoke with /comet-verify. Ver
17
17
  Execute entry verification:
18
18
 
19
19
  ```bash
20
- COMET_STATE=$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)
20
+ COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
21
21
  bash "$COMET_STATE" check <name> verify
22
22
  ```
23
23
 
@@ -39,7 +39,7 @@ When scale assessment result is "small", skip `openspec-verify-change`, directly
39
39
 
40
40
  1. All tasks in tasks.md completed `[x]`
41
41
  2. Changed files consistent with tasks.md description (`git diff --stat`对照 tasks content)
42
- 3. Build passes (for Maven projects, first execute `mvn spotless:apply`, then execute `mvn compile` or equivalent command)
42
+ 3. Build passes (run project-appropriate build command, e.g., `npm run build`, `mvn compile`, `cargo build`)
43
43
  4. Related tests pass
44
44
  5. No obvious security issues (no hardcoded secrets, no new unsafe operations)
45
45
 
@@ -89,9 +89,7 @@ After the skill loads, follow its guidance to complete. Branch handling options:
89
89
  4. Discard work
90
90
 
91
91
  **Confirmation items**:
92
- - Maven test or build commands have executed `mvn spotless:apply`
93
92
  - All tests pass
94
- - No remaining spotless formatting issues
95
93
  - No hardcoded secrets or security issues
96
94
 
97
95
  ## Exit Conditions