sequant 1.17.0 → 1.18.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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +14 -2
- package/dist/marketplace/external_plugins/sequant/.claude-plugin/plugin.json +21 -0
- package/dist/marketplace/external_plugins/sequant/README.md +38 -0
- package/dist/marketplace/external_plugins/sequant/hooks/post-tool.sh +292 -0
- package/dist/marketplace/external_plugins/sequant/hooks/pre-tool.sh +463 -0
- package/dist/marketplace/external_plugins/sequant/skills/_shared/references/prompt-templates.md +350 -0
- package/dist/marketplace/external_plugins/sequant/skills/_shared/references/subagent-types.md +131 -0
- package/dist/marketplace/external_plugins/sequant/skills/assess/SKILL.md +474 -0
- package/dist/marketplace/external_plugins/sequant/skills/clean/SKILL.md +211 -0
- package/dist/marketplace/external_plugins/sequant/skills/docs/SKILL.md +337 -0
- package/dist/marketplace/external_plugins/sequant/skills/exec/SKILL.md +807 -0
- package/dist/marketplace/external_plugins/sequant/skills/fullsolve/SKILL.md +678 -0
- package/dist/marketplace/external_plugins/sequant/skills/improve/SKILL.md +668 -0
- package/dist/marketplace/external_plugins/sequant/skills/loop/SKILL.md +374 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/SKILL.md +570 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/references/code-quality-exemplars.md +107 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/references/code-review-checklist.md +65 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/references/quality-gates.md +179 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/references/semgrep-rules.md +207 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/references/testing-requirements.md +109 -0
- package/dist/marketplace/external_plugins/sequant/skills/qa/scripts/quality-checks.sh +622 -0
- package/dist/marketplace/external_plugins/sequant/skills/reflect/SKILL.md +175 -0
- package/dist/marketplace/external_plugins/sequant/skills/reflect/references/documentation-tiers.md +70 -0
- package/dist/marketplace/external_plugins/sequant/skills/reflect/references/phase-reflection.md +95 -0
- package/dist/marketplace/external_plugins/sequant/skills/security-review/SKILL.md +358 -0
- package/dist/marketplace/external_plugins/sequant/skills/security-review/references/security-checklists.md +432 -0
- package/dist/marketplace/external_plugins/sequant/skills/solve/SKILL.md +697 -0
- package/dist/marketplace/external_plugins/sequant/skills/spec/SKILL.md +754 -0
- package/dist/marketplace/external_plugins/sequant/skills/spec/references/parallel-groups.md +72 -0
- package/dist/marketplace/external_plugins/sequant/skills/spec/references/recommended-workflow.md +92 -0
- package/dist/marketplace/external_plugins/sequant/skills/spec/references/verification-criteria.md +104 -0
- package/dist/marketplace/external_plugins/sequant/skills/test/SKILL.md +600 -0
- package/dist/marketplace/external_plugins/sequant/skills/testgen/SKILL.md +576 -0
- package/dist/marketplace/external_plugins/sequant/skills/verify/SKILL.md +281 -0
- package/dist/src/commands/run.d.ts +13 -280
- package/dist/src/commands/run.js +23 -1956
- package/dist/src/commands/sync.js +3 -0
- package/dist/src/commands/update.js +3 -0
- package/dist/src/lib/plugin-version-sync.d.ts +2 -1
- package/dist/src/lib/plugin-version-sync.js +28 -7
- package/dist/src/lib/solve-comment-parser.d.ts +26 -0
- package/dist/src/lib/solve-comment-parser.js +63 -7
- package/dist/src/lib/workflow/batch-executor.d.ts +117 -0
- package/dist/src/lib/workflow/batch-executor.js +574 -0
- package/dist/src/lib/workflow/phase-executor.d.ts +40 -0
- package/dist/src/lib/workflow/phase-executor.js +381 -0
- package/dist/src/lib/workflow/phase-mapper.d.ts +65 -0
- package/dist/src/lib/workflow/phase-mapper.js +147 -0
- package/dist/src/lib/workflow/pr-operations.d.ts +86 -0
- package/dist/src/lib/workflow/pr-operations.js +326 -0
- package/dist/src/lib/workflow/pr-status.d.ts +9 -7
- package/dist/src/lib/workflow/pr-status.js +13 -11
- package/dist/src/lib/workflow/run-summary.d.ts +36 -0
- package/dist/src/lib/workflow/run-summary.js +142 -0
- package/dist/src/lib/workflow/worktree-manager.d.ts +205 -0
- package/dist/src/lib/workflow/worktree-manager.js +918 -0
- package/package.json +3 -1
- package/templates/skills/fullsolve/SKILL.md +11 -1
- package/templates/skills/qa/SKILL.md +41 -1
- package/templates/skills/solve/SKILL.md +86 -0
- package/templates/skills/spec/SKILL.md +53 -0
- package/templates/skills/test/SKILL.md +10 -0
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: docs
|
|
3
|
+
description: "Phase 4 - Generate admin-facing documentation for implemented features before merging."
|
|
4
|
+
license: MIT
|
|
5
|
+
metadata:
|
|
6
|
+
author: sequant
|
|
7
|
+
version: "1.0"
|
|
8
|
+
allowed-tools:
|
|
9
|
+
- Read
|
|
10
|
+
- Write
|
|
11
|
+
- Glob
|
|
12
|
+
- Grep
|
|
13
|
+
- Bash(git diff:*)
|
|
14
|
+
- Bash(git status:*)
|
|
15
|
+
- Bash(gh issue view:*)
|
|
16
|
+
- Bash(gh issue comment:*)
|
|
17
|
+
- Bash(gh pr view:*)
|
|
18
|
+
- Bash(gh pr diff:*)
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
# Documentation Generator
|
|
22
|
+
|
|
23
|
+
You are the Phase 4 "Documentation Agent" for the current repository.
|
|
24
|
+
|
|
25
|
+
## Purpose
|
|
26
|
+
|
|
27
|
+
When invoked as `/docs`, your job is to:
|
|
28
|
+
|
|
29
|
+
1. Analyze the implemented feature (from PR diff or git diff).
|
|
30
|
+
2. Generate operational documentation (how to use, not how it works).
|
|
31
|
+
3. Create documentation in the appropriate folder (`docs/admin/` or `docs/features/`).
|
|
32
|
+
4. Post a summary comment to the GitHub issue.
|
|
33
|
+
|
|
34
|
+
## Behavior
|
|
35
|
+
|
|
36
|
+
Invocation:
|
|
37
|
+
|
|
38
|
+
- `/docs 123`:
|
|
39
|
+
- Treat `123` as the GitHub issue number.
|
|
40
|
+
- Analyze the implementation to understand what was built.
|
|
41
|
+
- Generate admin-facing or user-facing documentation.
|
|
42
|
+
|
|
43
|
+
### 1. Gather Context
|
|
44
|
+
|
|
45
|
+
**Step 1:** Read the GitHub issue and comments for feature context:
|
|
46
|
+
```bash
|
|
47
|
+
gh issue view <issue-number> --json title,body,labels
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
**Step 2:** Check for existing PR:
|
|
51
|
+
```bash
|
|
52
|
+
gh pr list --search "head:feature/<issue-number>" --json number,headRefName
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
**Step 3:** Analyze the implementation diff:
|
|
56
|
+
```bash
|
|
57
|
+
# If PR exists:
|
|
58
|
+
gh pr diff <pr-number>
|
|
59
|
+
|
|
60
|
+
# If no PR, use git diff from feature branch:
|
|
61
|
+
git diff main...HEAD --name-only
|
|
62
|
+
git diff main...HEAD
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### 2. Auto-Detect Documentation Type
|
|
66
|
+
|
|
67
|
+
Determine documentation type based on changed files:
|
|
68
|
+
|
|
69
|
+
**Admin Documentation** (`docs/admin/`):
|
|
70
|
+
- Files in `app/admin/`
|
|
71
|
+
- Files in `components/admin/`
|
|
72
|
+
- Files in `lib/admin/`
|
|
73
|
+
- Admin-related API routes
|
|
74
|
+
|
|
75
|
+
**User-Facing Documentation** (`docs/features/`):
|
|
76
|
+
- Files in `app/[city]/`
|
|
77
|
+
- Files in `components/` (non-admin)
|
|
78
|
+
- Public-facing pages or features
|
|
79
|
+
|
|
80
|
+
**Decision Logic:**
|
|
81
|
+
```
|
|
82
|
+
IF any file path contains "/admin/" THEN
|
|
83
|
+
type = "admin"
|
|
84
|
+
output_dir = "docs/admin/"
|
|
85
|
+
ELSE
|
|
86
|
+
type = "feature"
|
|
87
|
+
output_dir = "docs/features/"
|
|
88
|
+
END IF
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
### 3. Documentation Template
|
|
92
|
+
|
|
93
|
+
Generate documentation using this template:
|
|
94
|
+
|
|
95
|
+
```markdown
|
|
96
|
+
# [Feature Name]
|
|
97
|
+
|
|
98
|
+
**Quick Start:** [1-2 sentence summary of what this feature does and why to use it]
|
|
99
|
+
|
|
100
|
+
## Access
|
|
101
|
+
|
|
102
|
+
- **URL:** `/admin/[route]` or `/[route]`
|
|
103
|
+
- **Menu:** Admin → [Section] → [Feature]
|
|
104
|
+
- **Permissions:** [Required role or access level]
|
|
105
|
+
|
|
106
|
+
## Usage
|
|
107
|
+
|
|
108
|
+
### [Primary Action]
|
|
109
|
+
|
|
110
|
+
1. Navigate to [location]
|
|
111
|
+
2. [Step 2...]
|
|
112
|
+
3. [Step 3...]
|
|
113
|
+
|
|
114
|
+
### [Secondary Action] (if applicable)
|
|
115
|
+
|
|
116
|
+
1. [Steps...]
|
|
117
|
+
|
|
118
|
+
## Options & Settings
|
|
119
|
+
|
|
120
|
+
| Option | Description | Default |
|
|
121
|
+
|--------|-------------|---------|
|
|
122
|
+
| [Option 1] | [What it does] | [Default value] |
|
|
123
|
+
| [Option 2] | [What it does] | [Default value] |
|
|
124
|
+
|
|
125
|
+
## Common Workflows
|
|
126
|
+
|
|
127
|
+
### [Workflow 1: e.g., "Review and Approve Items"]
|
|
128
|
+
|
|
129
|
+
1. [Step 1]
|
|
130
|
+
2. [Step 2]
|
|
131
|
+
3. [Step 3]
|
|
132
|
+
|
|
133
|
+
### [Workflow 2: e.g., "Bulk Edit Multiple Items"]
|
|
134
|
+
|
|
135
|
+
1. [Step 1]
|
|
136
|
+
2. [Step 2]
|
|
137
|
+
|
|
138
|
+
## Troubleshooting
|
|
139
|
+
|
|
140
|
+
### [Common Issue 1]
|
|
141
|
+
|
|
142
|
+
**Symptoms:** [What the user sees]
|
|
143
|
+
|
|
144
|
+
**Solution:** [How to fix it]
|
|
145
|
+
|
|
146
|
+
### [Common Issue 2]
|
|
147
|
+
|
|
148
|
+
**Symptoms:** [What the user sees]
|
|
149
|
+
|
|
150
|
+
**Solution:** [How to fix it]
|
|
151
|
+
|
|
152
|
+
---
|
|
153
|
+
|
|
154
|
+
*Generated for Issue #[number] on [date]*
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
### 4. Content Guidelines
|
|
158
|
+
|
|
159
|
+
**Focus on operational usage, not technical implementation:**
|
|
160
|
+
|
|
161
|
+
- "Click the 'Approve' button to publish the item"
|
|
162
|
+
- NOT: "The `approveItem` function updates the database"
|
|
163
|
+
|
|
164
|
+
- "Wait for the green success message"
|
|
165
|
+
- NOT: "The API returns a 200 status code"
|
|
166
|
+
|
|
167
|
+
**Be specific and actionable:**
|
|
168
|
+
|
|
169
|
+
- "Navigate to Admin → Items → Review Queue"
|
|
170
|
+
- NOT: "Go to the review page"
|
|
171
|
+
|
|
172
|
+
**Include visual cues when relevant:**
|
|
173
|
+
|
|
174
|
+
- "Look for the blue 'Edit' icon next to each row"
|
|
175
|
+
- NOT: "Click the edit button"
|
|
176
|
+
|
|
177
|
+
**Document common workflows end-to-end:**
|
|
178
|
+
|
|
179
|
+
- "To approve an item: 1. Open Review Queue, 2. Click item name, 3. Review details, 4. Click Approve"
|
|
180
|
+
- NOT: "Use the approve button"
|
|
181
|
+
|
|
182
|
+
### 5. File Naming Convention
|
|
183
|
+
|
|
184
|
+
Generate filename from feature name:
|
|
185
|
+
- Use lowercase with hyphens
|
|
186
|
+
- Be descriptive but concise
|
|
187
|
+
- Match the primary feature purpose
|
|
188
|
+
|
|
189
|
+
Examples:
|
|
190
|
+
- `review-queue.md` - For review admin page
|
|
191
|
+
- `bulk-edit-operations.md` - For bulk editing feature
|
|
192
|
+
- `settings-configuration.md` - For settings admin
|
|
193
|
+
- `feature-gallery.md` - For gallery feature
|
|
194
|
+
|
|
195
|
+
### 6. Output and Summary
|
|
196
|
+
|
|
197
|
+
After generating documentation:
|
|
198
|
+
|
|
199
|
+
1. **Create the documentation file:**
|
|
200
|
+
- Write to `docs/admin/[feature-name].md` or `docs/features/[feature-name].md`
|
|
201
|
+
- Ensure directory exists (create with `.gitkeep` if needed)
|
|
202
|
+
|
|
203
|
+
2. **Post summary comment to GitHub issue:**
|
|
204
|
+
```bash
|
|
205
|
+
gh issue comment <issue-number> --body "$(cat <<'EOF'
|
|
206
|
+
## Documentation Generated
|
|
207
|
+
|
|
208
|
+
**File:** `docs/[admin|features]/[filename].md`
|
|
209
|
+
|
|
210
|
+
### Sections Included:
|
|
211
|
+
- Quick Start
|
|
212
|
+
- Access (URL, menu, permissions)
|
|
213
|
+
- Usage (step-by-step workflows)
|
|
214
|
+
- Options & Settings
|
|
215
|
+
- Common Workflows
|
|
216
|
+
- Troubleshooting
|
|
217
|
+
|
|
218
|
+
### Next Steps:
|
|
219
|
+
1. Review generated documentation for accuracy
|
|
220
|
+
2. Add screenshots if helpful (optional)
|
|
221
|
+
3. Merge PR to deploy documentation
|
|
222
|
+
|
|
223
|
+
---
|
|
224
|
+
Ready to merge!
|
|
225
|
+
EOF
|
|
226
|
+
)"
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
### 7. Quality Checklist
|
|
230
|
+
|
|
231
|
+
Before completing, verify:
|
|
232
|
+
|
|
233
|
+
- [ ] Documentation is operational (how to use, not how it works)
|
|
234
|
+
- [ ] All user-facing actions are documented
|
|
235
|
+
- [ ] Steps are numbered and specific
|
|
236
|
+
- [ ] Options/settings are in table format
|
|
237
|
+
- [ ] At least 1-2 troubleshooting items included
|
|
238
|
+
- [ ] Filename follows naming convention
|
|
239
|
+
- [ ] Correct folder (`docs/admin/` vs `docs/features/`)
|
|
240
|
+
- [ ] Summary comment posted to issue
|
|
241
|
+
|
|
242
|
+
## Workflow Integration
|
|
243
|
+
|
|
244
|
+
The `/docs` command is the final step before merging:
|
|
245
|
+
|
|
246
|
+
```
|
|
247
|
+
/spec → /exec → /test (optional) → /qa → /docs
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
**After /qa passes:**
|
|
251
|
+
- Run `/docs <issue>` to generate feature documentation
|
|
252
|
+
- Review generated docs for accuracy
|
|
253
|
+
- Add screenshots if helpful
|
|
254
|
+
- Merge PR
|
|
255
|
+
|
|
256
|
+
## Example Output
|
|
257
|
+
|
|
258
|
+
For Issue #180 (City Configuration UI):
|
|
259
|
+
|
|
260
|
+
**File:** `docs/admin/city-configuration.md`
|
|
261
|
+
|
|
262
|
+
```markdown
|
|
263
|
+
# City Configuration
|
|
264
|
+
|
|
265
|
+
**Quick Start:** Add and manage cities through the Admin CMS. Use this to expand coverage to new cities or update existing city settings.
|
|
266
|
+
|
|
267
|
+
## Access
|
|
268
|
+
|
|
269
|
+
- **URL:** `/admin/cities`
|
|
270
|
+
- **Menu:** Admin → Cities
|
|
271
|
+
- **Permissions:** Admin access required
|
|
272
|
+
|
|
273
|
+
## Usage
|
|
274
|
+
|
|
275
|
+
### Adding a New Item
|
|
276
|
+
|
|
277
|
+
1. Navigate to Admin → Items
|
|
278
|
+
2. Click the "Add Item" button (top right)
|
|
279
|
+
3. Complete the form:
|
|
280
|
+
- **Basic Info:** Enter name, description, and select status
|
|
281
|
+
- **Settings:** Configure item-specific options
|
|
282
|
+
- **Review:** Confirm all settings
|
|
283
|
+
4. Click "Create" to save
|
|
284
|
+
|
|
285
|
+
### Editing an Existing Item
|
|
286
|
+
|
|
287
|
+
1. Navigate to Admin → Items
|
|
288
|
+
2. Click on the item to open details
|
|
289
|
+
3. Click "Edit" in the details panel
|
|
290
|
+
4. Update settings as needed
|
|
291
|
+
5. Click "Save Changes"
|
|
292
|
+
|
|
293
|
+
## Options & Settings
|
|
294
|
+
|
|
295
|
+
| Option | Description | Default |
|
|
296
|
+
|--------|-------------|---------|
|
|
297
|
+
| Status | Item visibility (active, draft, archived) | draft |
|
|
298
|
+
| Category | Item categorization | None |
|
|
299
|
+
| Priority | Display order priority | Normal |
|
|
300
|
+
|
|
301
|
+
## Common Workflows
|
|
302
|
+
|
|
303
|
+
### Publish an Item
|
|
304
|
+
|
|
305
|
+
1. Add item via form (status: draft)
|
|
306
|
+
2. Review and approve in Review Queue
|
|
307
|
+
3. Change status to "active"
|
|
308
|
+
4. Item appears on public pages
|
|
309
|
+
|
|
310
|
+
## Troubleshooting
|
|
311
|
+
|
|
312
|
+
### Item doesn't appear on page
|
|
313
|
+
|
|
314
|
+
**Symptoms:** Item was added but doesn't show
|
|
315
|
+
|
|
316
|
+
**Solution:** Check item status is set to "active" in Admin → Items → [Item] → Settings
|
|
317
|
+
|
|
318
|
+
---
|
|
319
|
+
|
|
320
|
+
*Generated for Issue #180 on 2025-11-25*
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
---
|
|
324
|
+
|
|
325
|
+
## Output Verification
|
|
326
|
+
|
|
327
|
+
**Before responding, verify your output includes ALL of these:**
|
|
328
|
+
|
|
329
|
+
- [ ] **Documentation File** - Created in correct directory (docs/admin/ or docs/features/)
|
|
330
|
+
- [ ] **Quick Start Section** - 1-2 sentence summary
|
|
331
|
+
- [ ] **Access Section** - URL, menu path, permissions
|
|
332
|
+
- [ ] **Usage Section** - Step-by-step workflows
|
|
333
|
+
- [ ] **Options Table** - Settings with descriptions and defaults
|
|
334
|
+
- [ ] **Troubleshooting** - At least 1-2 common issues
|
|
335
|
+
- [ ] **GitHub Comment** - Summary posted to issue
|
|
336
|
+
|
|
337
|
+
**DO NOT respond until all items are verified.**
|