@rpamis/comet 0.1.7 → 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.
- package/README.md +45 -13
- package/assets/manifest.json +2 -0
- package/assets/skills/comet/SKILL.md +214 -219
- package/assets/skills/comet/scripts/comet-archive.sh +8 -2
- package/assets/skills/comet/scripts/comet-guard.sh +32 -22
- package/assets/skills/comet/scripts/comet-state.sh +496 -0
- package/assets/skills/comet-archive/SKILL.md +6 -19
- package/assets/skills/comet-build/SKILL.md +16 -23
- package/assets/skills/comet-design/SKILL.md +7 -23
- package/assets/skills/comet-hotfix/SKILL.md +136 -167
- package/assets/skills/comet-open/SKILL.md +9 -31
- package/assets/skills/comet-tweak/SKILL.md +122 -154
- package/assets/skills/comet-verify/SKILL.md +11 -33
- package/assets/skills-zh/comet/SKILL.md +87 -92
- package/assets/skills-zh/comet-archive/SKILL.md +63 -76
- package/assets/skills-zh/comet-build/SKILL.md +153 -160
- package/assets/skills-zh/comet-design/SKILL.md +91 -107
- package/assets/skills-zh/comet-hotfix/SKILL.md +18 -49
- package/assets/skills-zh/comet-open/SKILL.md +70 -92
- package/assets/skills-zh/comet-tweak/SKILL.md +19 -51
- package/assets/skills-zh/comet-verify/SKILL.md +114 -136
- package/dist/cli/index.js +28 -1
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/doctor.d.ts +6 -0
- package/dist/commands/doctor.d.ts.map +1 -0
- package/dist/commands/doctor.js +168 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/init.d.ts +9 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +183 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/status.d.ts +6 -0
- package/dist/commands/status.d.ts.map +1 -0
- package/dist/commands/status.js +89 -0
- package/dist/commands/status.js.map +1 -0
- package/dist/commands/update.d.ts +8 -0
- package/dist/commands/update.d.ts.map +1 -0
- package/dist/commands/update.js +47 -0
- package/dist/commands/update.js.map +1 -0
- package/dist/core/detect.d.ts +8 -0
- package/dist/core/detect.d.ts.map +1 -0
- package/dist/core/detect.js +73 -0
- package/dist/core/detect.js.map +1 -0
- package/dist/core/openspec.d.ts +5 -0
- package/dist/core/openspec.d.ts.map +1 -0
- package/dist/core/openspec.js +58 -0
- package/dist/core/openspec.js.map +1 -0
- package/dist/core/platforms.d.ts.map +1 -1
- package/dist/core/platforms.js +6 -1
- package/dist/core/platforms.js.map +1 -1
- package/dist/core/skills.d.ts +22 -0
- package/dist/core/skills.d.ts.map +1 -0
- package/dist/core/skills.js +59 -0
- package/dist/core/skills.js.map +1 -0
- package/dist/core/superpowers.d.ts +5 -0
- package/dist/core/superpowers.d.ts.map +1 -0
- package/dist/core/superpowers.js +60 -0
- package/dist/core/superpowers.js.map +1 -0
- package/dist/core/types.d.ts +2 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +2 -0
- package/dist/core/types.js.map +1 -0
- package/package.json +61 -50
- package/dist/core/init.d.ts +0 -14
- package/dist/core/init.d.ts.map +0 -1
- package/dist/core/init.js +0 -492
- package/dist/core/init.js.map +0 -1
|
@@ -14,30 +14,14 @@ description: "Comet Phase 2: Deep Design. Invoke with /comet-design. Produce Des
|
|
|
14
14
|
|
|
15
15
|
### 0. Entry State Verification (Entry Check)
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
3. `workflow` field value is `"full"`
|
|
23
|
-
4. `design_doc` field is `null` or empty
|
|
24
|
-
5. `openspec/changes/<name>/proposal.md` exists and is non-empty
|
|
25
|
-
6. `openspec/changes/<name>/design.md` exists and is non-empty
|
|
26
|
-
7. `openspec/changes/<name>/tasks.md` exists and is non-empty
|
|
27
|
-
|
|
28
|
-
**Verification method:**
|
|
29
|
-
- `cat openspec/changes/<name>/.comet.yaml` to read all fields
|
|
30
|
-
- Check checklist items one by one
|
|
31
|
-
|
|
32
|
-
**Failure output:**
|
|
33
|
-
```
|
|
34
|
-
[HARD STOP] Entry check failed for comet-design
|
|
35
|
-
Expected: phase=design, design_doc=<empty/null>, workflow=full
|
|
36
|
-
Actual: phase=<actual-value>, design_doc=<actual-value>, workflow=<actual-value>
|
|
37
|
-
Suggestion: Run comet-open first, or check if .comet.yaml was modified out of sequence.
|
|
17
|
+
Execute entry verification:
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
|
|
21
|
+
bash "$COMET_STATE" check <name> design
|
|
38
22
|
```
|
|
39
23
|
|
|
40
|
-
Proceed to Step 1
|
|
24
|
+
Proceed to Step 1 after verification passes. The script outputs specific failure reasons when verification fails.
|
|
41
25
|
|
|
42
26
|
### 1a. Read Existing Context
|
|
43
27
|
|
|
@@ -70,7 +54,7 @@ Record design_doc path, then run guard to auto-transition:
|
|
|
70
54
|
|
|
71
55
|
```bash
|
|
72
56
|
# Record design_doc path
|
|
73
|
-
|
|
57
|
+
bash "$COMET_STATE" set <name> design_doc docs/superpowers/specs/YYYY-MM-DD-topic-design.md
|
|
74
58
|
|
|
75
59
|
# Auto-transition to next phase
|
|
76
60
|
bash $COMET_GUARD <change-name> design --apply
|
|
@@ -1,167 +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
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
## Continuous Execution Mode
|
|
138
|
-
|
|
139
|
-
<IMPORTANT>
|
|
140
|
-
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).
|
|
141
|
-
|
|
142
|
-
Execution order: quick open → direct build → verification → archive → complete
|
|
143
|
-
|
|
144
|
-
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.
|
|
145
|
-
</IMPORTANT>
|
|
146
|
-
|
|
147
|
-
---
|
|
148
|
-
|
|
149
|
-
## Upgrade Conditions
|
|
150
|
-
|
|
151
|
-
When the following situations occur during fix process, stop hotfix workflow, upgrade to full `/comet`:
|
|
152
|
-
|
|
153
|
-
1. Root cause discovered involves architecture defects
|
|
154
|
-
2. Fix requires new interfaces or components
|
|
155
|
-
3. Impact scope expands to > 10 files
|
|
156
|
-
4. Needs new capability spec
|
|
157
|
-
|
|
158
|
-
Upgrade method: On current change basis, supplement Design Doc (execute `/comet-design`), then proceed normally with full workflow.
|
|
159
|
-
|
|
160
|
-
---
|
|
161
|
-
|
|
162
|
-
## Exit Conditions
|
|
163
|
-
|
|
164
|
-
- Bug fixed, tests pass
|
|
165
|
-
- Change archived
|
|
166
|
-
- If spec changes, synced to main spec
|
|
167
|
-
- **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`
|
|
@@ -13,28 +13,14 @@ description: "Comet Phase 1: Open. Invoke with /comet-open. Explore ideas throug
|
|
|
13
13
|
|
|
14
14
|
### 0. Entry State Verification (Entry Check)
|
|
15
15
|
|
|
16
|
-
|
|
16
|
+
Execute entry verification:
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
3. `openspec/changes/<name>/proposal.md` exists and is non-empty
|
|
22
|
-
4. `openspec/changes/<name>/design.md` exists and is non-empty
|
|
23
|
-
5. `openspec/changes/<name>/tasks.md` exists and is non-empty
|
|
24
|
-
|
|
25
|
-
**Verification method:**
|
|
26
|
-
- Read the above paths to confirm existence/non-existence
|
|
27
|
-
- If `.comet.yaml` already exists, read its `phase` field: if phase is not empty, output `[HARD STOP]` and prompt that there may already be an active change
|
|
28
|
-
|
|
29
|
-
**Failure output:**
|
|
30
|
-
```
|
|
31
|
-
[HARD STOP] Entry check failed for comet-open
|
|
32
|
-
Expected: .comet.yaml does not exist, proposal.md + design.md + tasks.md exist
|
|
33
|
-
Actual: phase=<actual-value>, design_doc=<actual-value> (or file does not exist)
|
|
34
|
-
Suggestion: Check if another change with the same name is already active.
|
|
18
|
+
```bash
|
|
19
|
+
COMET_STATE="${COMET_STATE:-$(find . -path '*/comet/scripts/comet-state.sh' -type f -print -quit)}"
|
|
20
|
+
bash "$COMET_STATE" check <name> open
|
|
35
21
|
```
|
|
36
22
|
|
|
37
|
-
Proceed to Step 1
|
|
23
|
+
Proceed to Step 1 after verification passes. The script outputs specific failure reasons when verification fails.
|
|
38
24
|
|
|
39
25
|
### 1. Explore Idea
|
|
40
26
|
|
|
@@ -59,18 +45,10 @@ openspec/changes/<name>/
|
|
|
59
45
|
|
|
60
46
|
### 3. Initialize Comet State
|
|
61
47
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
phase: design
|
|
67
|
-
design_doc: null
|
|
68
|
-
plan: null
|
|
69
|
-
build_mode: null
|
|
70
|
-
verify_mode: null
|
|
71
|
-
verify_result: pending
|
|
72
|
-
verified_at: null
|
|
73
|
-
archived: false
|
|
48
|
+
Initialize Comet state file:
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
bash "$COMET_STATE" init <name> full
|
|
74
52
|
```
|
|
75
53
|
|
|
76
54
|
### 4. Content Completeness Check
|