gspec 1.16.0 → 1.17.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 +33 -6
- package/bin/gspec.js +214 -33
- package/commands/gspec.analyze.md +9 -0
- package/commands/gspec.audit.md +84 -9
- package/commands/gspec.feature.md +10 -0
- package/commands/gspec.implement.md +19 -8
- package/commands/gspec.tasks.md +150 -0
- package/dist/antigravity/gspec-analyze/SKILL.md +9 -0
- package/dist/antigravity/gspec-audit/SKILL.md +85 -10
- package/dist/antigravity/gspec-feature/SKILL.md +10 -0
- package/dist/antigravity/gspec-implement/SKILL.md +19 -8
- package/dist/antigravity/gspec-tasks/SKILL.md +154 -0
- package/dist/claude/gspec-analyze/SKILL.md +9 -0
- package/dist/claude/gspec-audit/SKILL.md +85 -10
- package/dist/claude/gspec-feature/SKILL.md +10 -0
- package/dist/claude/gspec-implement/SKILL.md +19 -8
- package/dist/claude/gspec-tasks/SKILL.md +155 -0
- package/dist/codex/gspec-analyze/SKILL.md +9 -0
- package/dist/codex/gspec-audit/SKILL.md +85 -10
- package/dist/codex/gspec-feature/SKILL.md +10 -0
- package/dist/codex/gspec-implement/SKILL.md +19 -8
- package/dist/codex/gspec-tasks/SKILL.md +154 -0
- package/dist/cursor/gspec-analyze.mdc +9 -0
- package/dist/cursor/gspec-audit.mdc +85 -10
- package/dist/cursor/gspec-feature.mdc +10 -0
- package/dist/cursor/gspec-implement.mdc +19 -8
- package/dist/cursor/gspec-tasks.mdc +153 -0
- package/dist/opencode/gspec-analyze/SKILL.md +9 -0
- package/dist/opencode/gspec-audit/SKILL.md +85 -10
- package/dist/opencode/gspec-feature/SKILL.md +10 -0
- package/dist/opencode/gspec-implement/SKILL.md +19 -8
- package/dist/opencode/gspec-tasks/SKILL.md +154 -0
- package/package.json +1 -1
- package/templates/spec-sync.md +2 -1
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: gspec-tasks
|
|
3
|
+
description: Decompose a feature PRD in gspec/features/ into an ordered, dependency-aware task plan with parallel-execution markers, written to gspec/features/<feature>.tasks.md. TRIGGER when the user wants to plan execution order, break a feature into tasks, identify what can run in parallel, sequence implementation work, or produce a build plan from a PRD — e.g. "break this feature into tasks", "what order should I build this in", "plan the implementation order", "make a task list for X", "what can run in parallel", "decompose feature Y", "ordered task plan". Run this AFTER gspec-feature and BEFORE gspec-implement when a feature is large or has non-obvious ordering. Prefer this skill over ad-hoc task lists.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are a Senior Engineering Lead at a high-performing software company.
|
|
7
|
+
|
|
8
|
+
Your task is to take a **feature PRD** from `gspec/features/` and decompose it into an **ordered, dependency-aware task plan** with parallel-execution markers. The output is a separate sibling file at `gspec/features/<feature>.tasks.md` that `gspec-implement` consumes during its planning phase.
|
|
9
|
+
|
|
10
|
+
The PRD answers *what* and *why*. The tasks file answers *how* and *in what order*.
|
|
11
|
+
|
|
12
|
+
## When to Run This Skill
|
|
13
|
+
|
|
14
|
+
Run after `gspec-feature` and before `gspec-implement` when:
|
|
15
|
+
|
|
16
|
+
- The feature is large enough that build order matters (more than 3-4 capabilities, or non-trivial cross-capability dependencies)
|
|
17
|
+
- Work could be parallelized and you want that surfaced explicitly
|
|
18
|
+
- You want a reviewable execution plan before code is written
|
|
19
|
+
|
|
20
|
+
Skip this skill for trivial features — `gspec-implement`'s checkbox-driven planning is sufficient there.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Inputs
|
|
25
|
+
|
|
26
|
+
- **Required**: a feature PRD at `gspec/features/<feature>.md` (the user names the feature; if ambiguous, ask)
|
|
27
|
+
- **Supporting context** (read but don't quote): `gspec/architecture.md`, `gspec/stack.md`. Use these only to inform task granularity and ordering — never to embed project-specific technology choices into the tasks file
|
|
28
|
+
- **Existing tasks file** (if any) at `gspec/features/<feature>.tasks.md` — if present and non-empty, treat it as authoritative state and refuse to overwrite without explicit user confirmation
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Workflow
|
|
33
|
+
|
|
34
|
+
### Phase 1: Discovery
|
|
35
|
+
|
|
36
|
+
1. Read the target feature PRD in full. Extract every capability and its acceptance criteria.
|
|
37
|
+
2. Read `gspec/architecture.md` and `gspec/stack.md` for ordering signals (e.g., schema must exist before API; API before UI).
|
|
38
|
+
3. If a tasks file already exists for this feature, read it. Decide whether the user wants to (a) regenerate from scratch, (b) add tasks for newly added capabilities only, or (c) abort. Ask before proceeding.
|
|
39
|
+
|
|
40
|
+
### Phase 2: Decompose
|
|
41
|
+
|
|
42
|
+
For each unchecked PRD capability:
|
|
43
|
+
|
|
44
|
+
1. Propose **1–N tasks** that, taken together, satisfy the capability's acceptance criteria.
|
|
45
|
+
2. Tasks should be small enough that a single implementation pass can complete and verify each one (typically 1-3 files, 1-3 acceptance criteria worth of work).
|
|
46
|
+
3. Carry the capability's priority (`P0`/`P1`/`P2`) onto each task.
|
|
47
|
+
4. Record the **`covers:` line** verbatim — quote the capability text from the PRD so the trace is unambiguous. A single task may cover multiple capabilities; a single capability may be covered by multiple tasks.
|
|
48
|
+
|
|
49
|
+
### Phase 3: Order & Mark Parallelism
|
|
50
|
+
|
|
51
|
+
1. Identify dependencies. A task depends on another when:
|
|
52
|
+
- It writes files the other reads or extends
|
|
53
|
+
- It uses APIs/types/schemas the other introduces
|
|
54
|
+
- It tests behavior the other implements
|
|
55
|
+
2. Emit a **topological ordering**: list tasks in an order where every `deps:` reference points strictly backwards.
|
|
56
|
+
3. Mark a task `[P]` (parallel-safe) only when it satisfies **both** conditions:
|
|
57
|
+
- Its `deps:` are all already complete (i.e., earlier in the list and not currently in flight beside it)
|
|
58
|
+
- It does not write to the same files as another `[P]`-marked sibling at the same level
|
|
59
|
+
When in doubt, leave `[P]` off. False parallelism causes more pain than missed parallelism.
|
|
60
|
+
|
|
61
|
+
### Phase 4: Plan-Mode Confirmation
|
|
62
|
+
|
|
63
|
+
Enter plan mode and present the proposed tasks file content to the user. Show:
|
|
64
|
+
|
|
65
|
+
- Total task count and how many `[P]`-marked
|
|
66
|
+
- The full proposed file body
|
|
67
|
+
- Any capabilities you could not decompose (explain why)
|
|
68
|
+
- Any cross-feature dependencies you noticed (the user may want to address them in another feature's tasks file)
|
|
69
|
+
|
|
70
|
+
Wait for approval. The user may edit individual tasks, change ordering, drop or add `[P]` markers, or split/merge tasks.
|
|
71
|
+
|
|
72
|
+
### Phase 5: Write
|
|
73
|
+
|
|
74
|
+
After approval, write `gspec/features/<feature>.tasks.md`. Never overwrite a non-empty existing file without explicit user confirmation in Phase 1.
|
|
75
|
+
|
|
76
|
+
When writing, preserve any existing `spec-version` frontmatter from the prior tasks file. New files use `spec-version: v1`.
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
## Output Format
|
|
81
|
+
|
|
82
|
+
The tasks file has YAML frontmatter and a single `## Tasks` section.
|
|
83
|
+
|
|
84
|
+
```markdown
|
|
85
|
+
---
|
|
86
|
+
spec-version: v1
|
|
87
|
+
feature: <feature-slug>
|
|
88
|
+
---
|
|
89
|
+
|
|
90
|
+
# Tasks: <Feature Name>
|
|
91
|
+
|
|
92
|
+
## Tasks
|
|
93
|
+
|
|
94
|
+
- [ ] **T1** [P] **P0** scaffold the Astro page route at `src/pages/index.astro`
|
|
95
|
+
- deps: —
|
|
96
|
+
- covers: "Page displays a clear tagline and one-line value proposition that communicates what gspec does"
|
|
97
|
+
- [ ] **T2** **P0** wire CTA copy-to-clipboard interaction
|
|
98
|
+
- deps: T1
|
|
99
|
+
- covers: "Page displays a prominent install CTA with the install command"
|
|
100
|
+
- [ ] **T3** [P] **P1** add the workflow diagram component
|
|
101
|
+
- deps: T1
|
|
102
|
+
- covers: "Page explains the gspec workflow in three or fewer steps"
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### Field rules
|
|
106
|
+
|
|
107
|
+
- **ID**: `T<n>`, monotonically increasing from `T1`. IDs are stable — never renumber existing tasks during a regenerate; append new ones with the next free number.
|
|
108
|
+
- **`[P]`**: optional parallel marker. Place between the ID and the priority.
|
|
109
|
+
- **Priority**: `P0`, `P1`, or `P2`, matching the source capability.
|
|
110
|
+
- **Description**: one short imperative sentence. Concrete files or modules where useful, but no implementation code.
|
|
111
|
+
- **`deps:`**: comma-separated task IDs. Use `—` (em dash) when there are no dependencies.
|
|
112
|
+
- **`covers:`**: capability text from the PRD, quoted. For tasks covering multiple capabilities, separate quoted strings with `; `.
|
|
113
|
+
|
|
114
|
+
### What NOT to write
|
|
115
|
+
|
|
116
|
+
- ❌ No code blocks or pseudocode — that belongs in the implementation step.
|
|
117
|
+
- ❌ No technology choices not already in `stack.md` or `architecture.md`.
|
|
118
|
+
- ❌ No timeline estimates (hours, days, sprints) — see `gspec-feature` for the same rule.
|
|
119
|
+
- ❌ No tasks for capabilities that are already `- [x]` in the PRD, unless the user explicitly requests re-implementation.
|
|
120
|
+
- ❌ No "review" or "documentation" tasks unless the PRD's acceptance criteria explicitly require them.
|
|
121
|
+
|
|
122
|
+
---
|
|
123
|
+
|
|
124
|
+
## Relationship to PRD Checkboxes
|
|
125
|
+
|
|
126
|
+
The tasks file and the PRD use **separate checkboxes**:
|
|
127
|
+
|
|
128
|
+
- **Task checkboxes** (`- [ ]` / `- [x]` in the tasks file) track *execution state* — flip when the task is done.
|
|
129
|
+
- **Capability checkboxes** (`- [ ]` / `- [x]` in the PRD) track *delivery state* — only flip when **every** task whose `covers:` references that capability is complete.
|
|
130
|
+
|
|
131
|
+
`gspec-implement` is responsible for keeping both in sync. This skill only writes the initial unchecked tasks file.
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## Output Rules
|
|
136
|
+
|
|
137
|
+
- **Use plan mode** in Phase 4. Never write the tasks file before the user approves.
|
|
138
|
+
- One tasks file per feature. Co-located with the PRD as `gspec/features/<feature>.tasks.md`.
|
|
139
|
+
- Begin each file with the YAML frontmatter shown above.
|
|
140
|
+
- Preserve existing frontmatter and existing task IDs when regenerating — append new tasks rather than renumbering.
|
|
141
|
+
- If you discover the PRD itself is ambiguous (a capability has no clear acceptance criteria), pause and recommend the user run `gspec-feature` to refine the PRD before continuing. Do not invent acceptance criteria.
|
|
142
|
+
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
## Tone & Style
|
|
146
|
+
|
|
147
|
+
- Decisive — pick an ordering and defend it; don't list options.
|
|
148
|
+
- Tight — every task line earns its place.
|
|
149
|
+
- Honest about dependencies — it's better to be slightly conservative on `[P]` than to claim parallelism that doesn't hold.
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
## Input Feature
|
|
154
|
+
|
package/package.json
CHANGED
package/templates/spec-sync.md
CHANGED
|
@@ -13,6 +13,7 @@ Use this mapping whenever the user's intent matches:
|
|
|
13
13
|
- **Building, implementing, coding, scaffolding, shipping, or "making it real"** — invoke `gspec-implement`. This is the most commonly-missed skill. If the user asks you to write code for anything the specs describe (or a new capability that should be specced), route through `gspec-implement` rather than editing files directly. Generic prompts like "build it", "go", "keep going", "continue", or "do the next phase" should also invoke it when recent conversation has been about specs or planning.
|
|
14
14
|
- **Defining the product, users, or vision** — invoke `gspec-profile`.
|
|
15
15
|
- **Planning or writing a new feature / PRD** — invoke `gspec-feature`.
|
|
16
|
+
- **Producing an ordered task plan from a feature PRD (with explicit dependencies and parallel-execution markers)** — invoke `gspec-tasks`. Run before `gspec-implement` for non-trivial features.
|
|
16
17
|
- **Choosing or revising the tech stack** — invoke `gspec-stack`.
|
|
17
18
|
- **Defining visual design, tokens, or theme** — invoke `gspec-style`.
|
|
18
19
|
- **Setting coding standards, testing, or workflow conventions** — invoke `gspec-practices`.
|
|
@@ -30,7 +31,7 @@ If the user explicitly asks you to skip the skill and just do the work, honor th
|
|
|
30
31
|
|
|
31
32
|
2. **Spec before you build** — If the user asks for a feature or capability that isn't covered by an existing feature PRD in `gspec/features/`, run the `gspec-feature` command to create a new feature PRD before implementing it. Every feature should be specified before it's built — don't skip straight to code.
|
|
32
33
|
|
|
33
|
-
3. **Update feature checkboxes** — When you implement a capability defined in a feature PRD (`gspec/features/*.md`), change its checkbox from `- [ ]` to `- [x]`.
|
|
34
|
+
3. **Update feature checkboxes** — When you implement a capability defined in a feature PRD (`gspec/features/*.md`), change its checkbox from `- [ ]` to `- [x]`. **If a tasks file exists** at `gspec/features/<feature>.tasks.md`, also flip the checkbox of each completed task in that file. Only flip the PRD capability checkbox once every task whose `covers:` references it is checked.
|
|
34
35
|
|
|
35
36
|
4. **Update specs that your changes contradict** — If your code change makes a spec statement incorrect (e.g., you changed the data model, switched a dependency, altered a UI pattern, or added a new API endpoint), update the spec to reflect reality. Common candidates:
|
|
36
37
|
- `gspec/architecture.md` — project structure, data model, API routes, component hierarchy
|