catalyst-os 1.3.1 → 2.0.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 (30) hide show
  1. package/.catalyst/bin/install.js +1 -1
  2. package/.catalyst/main/project-config.yaml +1 -1
  3. package/.catalyst/spec-structure.yaml +5 -5
  4. package/.claude/agents/arbiter.md +1 -1
  5. package/.claude/agents/forge-master.md +1 -1
  6. package/.claude/commands/archive-spec.md +30 -0
  7. package/.claude/commands/{review-spec.md → audit-spec.md} +6 -2
  8. package/.claude/commands/discard-spec.md +10 -10
  9. package/.claude/commands/{build-spec-worktree.md → forge-spec-worktree.md} +5 -3
  10. package/.claude/commands/{build-spec.md → forge-spec.md} +4 -2
  11. package/.claude/commands/primer-spec.md +3 -4
  12. package/.claude/commands/roadmap.md +38 -31
  13. package/.claude/commands/seal-spec.md +20 -0
  14. package/.claude/commands/status-spec.md +4 -4
  15. package/.claude/commands/sync-project.md +28 -0
  16. package/.claude/skills/build-orchestration/SKILL.md +3 -3
  17. package/.claude/skills/project-sync/SKILL.md +114 -0
  18. package/.claude/skills/spec-approval/SKILL.md +5 -5
  19. package/.claude/skills/spec-archival/SKILL.md +77 -0
  20. package/.claude/skills/spec-shaping/SKILL.md +3 -4
  21. package/.claude/skills/spec-update/SKILL.md +2 -2
  22. package/.claude/skills/spec-validation/SKILL.md +18 -9
  23. package/.claude/skills/using-skills/SKILL.md +5 -5
  24. package/README.md +18 -28
  25. package/package.json +1 -1
  26. package/.claude/commands/build-task.md +0 -16
  27. package/.claude/commands/commit-spec.md +0 -20
  28. package/.claude/commands/iterate-spec.md +0 -28
  29. package/.claude/skills/spec-iteration/SKILL.md +0 -135
  30. package/.claude/skills/task-building/SKILL.md +0 -96
@@ -162,7 +162,7 @@ function install() {
162
162
  ${yellow}Next steps:${reset}
163
163
  1. Run ${cyan}/catalyze-project${reset} to initialize your project
164
164
  2. Run ${cyan}/catalyze-spec${reset} to create your first specification
165
- 3. Run ${cyan}/build-spec${reset} to implement it
165
+ 3. Run ${cyan}/forge-spec${reset} to implement it
166
166
 
167
167
  ${dim}Documentation: https://github.com/Ealikadioglu/catalyst-os${reset}
168
168
  `);
@@ -25,7 +25,7 @@ git:
25
25
  - "main"
26
26
  - "master"
27
27
 
28
- # Path for git worktrees (relative to repo root, used by /build-spec-worktree)
28
+ # Path for git worktrees (relative to repo root, used by /forge-spec-worktree)
29
29
  worktree_path: ".catalyst/worktrees"
30
30
 
31
31
  # Commit message templates
@@ -25,7 +25,7 @@ files:
25
25
  tasks.md:
26
26
  owner: forger
27
27
  purpose: DAG + progress + decisions + session context (THE living doc)
28
- created: build-spec
28
+ created: forge-spec
29
29
  updated_by: [forger, forge-master, builders]
30
30
  pattern: living
31
31
  note: |
@@ -35,7 +35,7 @@ files:
35
35
  handoff.md:
36
36
  owner: scribe
37
37
  purpose: Human-readable summary (colleague walkthrough)
38
- created: build-spec (started), review-spec (finalized)
38
+ created: forge-spec (started), audit-spec (finalized)
39
39
  updated_by: [scribe, arbiter]
40
40
  pattern: narrative
41
41
  note: |
@@ -45,7 +45,7 @@ files:
45
45
  validation.md:
46
46
  owner: arbiter
47
47
  purpose: Test results, quality checks
48
- created: review-spec
48
+ created: audit-spec
49
49
  updated_by: [arbiter, enforcer, sentinel, inquisitor, watcher]
50
50
 
51
51
  assets/:
@@ -289,7 +289,7 @@ build_dag:
289
289
  library:
290
290
  root: "library/"
291
291
  description: "Reusable patterns extracted from completed specs"
292
- created_by: "/commit-spec (optional)"
292
+ created_by: "/seal-spec (optional)"
293
293
 
294
294
  # Auto-detect patterns by keywords
295
295
  pattern_detection:
@@ -316,4 +316,4 @@ library:
316
316
 
317
317
  completed:
318
318
  location: "completed/"
319
- description: "Specs moved here after /commit-spec"
319
+ description: "Specs moved here after /seal-spec"
@@ -2,7 +2,7 @@
2
2
  name: arbiter
3
3
  description: >
4
4
  PROACTIVELY DELEGATE validation orchestration to this agent. MUST BE USED when:
5
- - /review-spec command is invoked
5
+ - /audit-spec command is invoked
6
6
  - Implementation is complete and needs quality checks
7
7
  - Production readiness needs to be verified
8
8
 
@@ -2,7 +2,7 @@
2
2
  name: forge-master
3
3
  description: >
4
4
  PROACTIVELY DELEGATE build orchestration to this agent. MUST BE USED when:
5
- - /build-spec command is invoked
5
+ - /forge-spec command is invoked
6
6
  - A specification needs to be implemented
7
7
  - TDD workflow needs to be coordinated
8
8
 
@@ -0,0 +1,30 @@
1
+ # /archive-spec
2
+
3
+ Archive a spec without git ceremony. Marks as COMPLETE, moves to completed folder, and checks for library patterns.
4
+
5
+ > **Use when:** You want to close out a spec without branch management or push suggestions.
6
+ > **For full ceremony:** Use `/seal-spec` instead.
7
+ >
8
+ > **Flow:** `/catalyze-spec` → `/forge-spec` → `/audit-spec` → **`/archive-spec`** (lightweight) or **`/seal-spec`** (full)
9
+
10
+ ## Usage
11
+
12
+ ```
13
+ /archive-spec @2025-11-29-stripe-integration
14
+ /archive-spec @2025-11-29-stripe-integration "closing out"
15
+ ```
16
+
17
+ ## Pre-computed Context
18
+
19
+ ```bash
20
+ # Spec state for archival
21
+ echo "=== SPEC FILES ===" && ls .catalyst/specs/*$ARGUMENTS*/ 2>/dev/null || echo "No spec found for: $ARGUMENTS"
22
+ echo "=== SPEC STATUS ===" && head -20 .catalyst/specs/*$ARGUMENTS*/spec.md 2>/dev/null || echo "No spec.md"
23
+ echo "=== TASKS.MD ===" && cat .catalyst/specs/*$ARGUMENTS*/tasks.md 2>/dev/null | head -40 || echo "No tasks.md"
24
+ ```
25
+
26
+ ---
27
+
28
+ **Invoke skill:** `spec-archival`
29
+
30
+ **Process skills used:** `verification-before-completion`
@@ -1,11 +1,15 @@
1
- # /review-spec
1
+ # /audit-spec
2
2
 
3
3
  Run validation checks and code simplification on a completed implementation.
4
4
 
5
+ > **Lifecycle position:** `/catalyze-spec` → `/forge-spec` → **`/audit-spec`** → `/seal-spec`
6
+ >
7
+ > **Note:** This audits the CODE implementation (quality, security, tests) — not the spec document.
8
+
5
9
  ## Usage
6
10
 
7
11
  ```
8
- /review-spec @2025-11-29-stripe-integration
12
+ /audit-spec @2025-11-29-stripe-integration
9
13
  ```
10
14
 
11
15
  ## Pre-computed Context
@@ -20,7 +20,7 @@ Request changes to the implementation.
20
20
  /discard-spec @spec-name "TDD not followed - tests written after code"
21
21
  ```
22
22
 
23
- This routes directly back to `/build-spec` with instructions to follow TDD.
23
+ This routes directly back to `/forge-spec` with instructions to follow TDD.
24
24
 
25
25
  ---
26
26
 
@@ -50,12 +50,12 @@ Based on rejection reason:
50
50
 
51
51
  | Issue Type | Route To | Command |
52
52
  |------------|----------|---------|
53
- | **TDD not followed** | Enforcer -> Builders | `/build-spec` (restart) |
54
- | Missing tests | Enforcer | `/build-spec` |
55
- | Test failures | Enforcer + Builders | `/build-spec` |
56
- | UI/UX issues | Shaper | `/build-spec` |
57
- | API issues | Smith | `/build-spec` |
58
- | Quality issues | Inquisitor | `/review-spec` |
53
+ | **TDD not followed** | Enforcer -> Builders | `/forge-spec` (restart) |
54
+ | Missing tests | Enforcer | `/forge-spec` |
55
+ | Test failures | Enforcer + Builders | `/forge-spec` |
56
+ | UI/UX issues | Shaper | `/forge-spec` |
57
+ | API issues | Smith | `/forge-spec` |
58
+ | Quality issues | Inquisitor | `/audit-spec` |
59
59
  | Security issues | Watcher | IMMEDIATE FIX |
60
60
 
61
61
  ### Phase 3: Update Status
@@ -89,8 +89,8 @@ Changes needed:
89
89
 
90
90
  Updated: .catalyst/specs/{slug}/validation.md
91
91
 
92
- Next: Fix issues and run /build-spec @2025-11-29-stripe-integration
93
- Then /review-spec @2025-11-29-stripe-integration
92
+ Next: Fix issues and run /forge-spec @2025-11-29-stripe-integration
93
+ Then /audit-spec @2025-11-29-stripe-integration
94
94
  ```
95
95
 
96
96
  ### TDD Violation Rejection
@@ -108,7 +108,7 @@ Required process:
108
108
  3. Builders implement features
109
109
  4. Verify all tests PASS (green phase)
110
110
 
111
- Next: Run /build-spec @2025-11-29-stripe-integration
111
+ Next: Run /forge-spec @2025-11-29-stripe-integration
112
112
  Follow TDD process strictly.
113
113
  ```
114
114
 
@@ -1,13 +1,15 @@
1
- # /build-spec-worktree
1
+ # /forge-spec-worktree
2
2
 
3
3
  Implement a specification using **strict TDD** in an isolated git worktree.
4
4
 
5
- Use this instead of `/build-spec` when you need worktree isolation — e.g., working on a second spec while another is in progress, or wanting a clean working directory.
5
+ Use this instead of `/forge-spec` when you need worktree isolation — e.g., working on a second spec while another is in progress, or wanting a clean working directory.
6
+
7
+ > **Lifecycle position:** `/catalyze-spec` → **`/forge-spec-worktree`** → `/audit-spec` → `/seal-spec`
6
8
 
7
9
  ## Usage
8
10
 
9
11
  ```
10
- /build-spec-worktree @2025-11-29-stripe-integration
12
+ /forge-spec-worktree @2025-11-29-stripe-integration
11
13
  ```
12
14
 
13
15
  ---
@@ -1,11 +1,13 @@
1
- # /build-spec
1
+ # /forge-spec
2
2
 
3
3
  Implement a specification using **strict TDD**.
4
4
 
5
+ > **Lifecycle position:** `/catalyze-spec` → **`/forge-spec`** → `/audit-spec` → `/seal-spec`
6
+
5
7
  ## Usage
6
8
 
7
9
  ```
8
- /build-spec @2025-11-29-stripe-integration
10
+ /forge-spec @2025-11-29-stripe-integration
9
11
  ```
10
12
 
11
13
  ## Pre-computed Context
@@ -155,8 +155,7 @@ Ready to continue. What would you like to work on?
155
155
  | Situation | Command |
156
156
  |-----------|---------|
157
157
  | Context full, need to continue building | `/primer-spec` |
158
- | Want to add improvement mid-build | `/iterate-spec` |
159
- | Need full validation | `/review-spec` |
158
+ | Need full validation | `/audit-spec` |
160
159
  | Check status without loading context | `/status-spec` |
161
160
 
162
161
  ---
@@ -164,5 +163,5 @@ Ready to continue. What would you like to work on?
164
163
  ## Tips
165
164
 
166
165
  - Run this FIRST in a new conversation before doing any work
167
- - After primer, you can run `/iterate-spec` or continue with `/build-spec`
168
- - If tasks.md doesn't exist, the spec hasn't been built yet - run `/build-spec`
166
+ - After primer, continue with `/forge-spec`
167
+ - If tasks.md doesn't exist, the spec hasn't been built yet - run `/forge-spec`
@@ -1,6 +1,6 @@
1
1
  # /roadmap
2
2
 
3
- Create or update the project roadmap.
3
+ Create or update the project roadmap with spec-grouped entries and actionable next commands.
4
4
 
5
5
  ## Usage
6
6
 
@@ -13,50 +13,57 @@ Create or update the project roadmap.
13
13
 
14
14
  1. **Read** `.catalyst/main/mission.md` for context
15
15
  2. **Read existing** `.catalyst/main/roadmap.md` if present
16
- 3. **Analyze** codebase for current feature state
17
- 4. **Ask** about priorities and timeline:
16
+ 3. **Scan specs** in `.catalyst/specs/` to determine current state of each spec
17
+ 4. **Analyze** codebase for current feature state
18
+ 5. **Ask** about priorities and timeline:
18
19
  - What's most important right now?
19
20
  - What's blocking progress?
20
21
  - What's the target timeline?
21
- 5. **Create/Update** the roadmap
22
+ 6. **Resolve commands** for each spec entry (see Command Resolution below)
23
+ 7. **Create/Update** the roadmap using the template at `.catalyst/main/temp/temp-roadmap.md`
22
24
 
23
- ## Output Format
25
+ ## Command Resolution
24
26
 
25
- `.catalyst/main/roadmap.md`:
27
+ The canonical spec workflow is: `/catalyze-spec` → `/forge-spec` → `/audit-spec` → `/seal-spec`
26
28
 
27
- ```markdown
28
- # Project Roadmap
29
+ For each spec entry in the roadmap, determine the next action based on its state:
29
30
 
30
- ## Current State
31
- [Brief assessment of where the project is now]
31
+ | Spec State | How to Detect | Next Command |
32
+ |------------|---------------|--------------|
33
+ | Not yet created | Only exists in roadmap, no spec folder | `!/catalyze-spec "{seed prompt}"` |
34
+ | DRAFT | `spec.md` exists, no `tasks.md` | `!/forge-spec @{slug}` or `!/forge-spec-worktree @{slug}` |
35
+ | IN_PROGRESS | `tasks.md` exists, build ongoing | `!/audit-spec @{slug}` |
36
+ | VALIDATING | `validation.md` exists | `!/seal-spec @{slug}` |
37
+ | COMPLETE | `handoff.md` exists with sealed status | No command (show checkmark) |
32
38
 
33
- ## Phase 1: Foundation (Now - 1 month)
34
- ### Goals
35
- - [Specific, measurable goal]
36
- - [Another goal]
39
+ > **Worktree tip:** Use `!/forge-spec-worktree` when another spec is already in progress on the current branch, or when file scopes might collide between concurrent specs.
37
40
 
38
- ### Key Features
39
- - [ ] Feature 1 - Description
40
- - [ ] Feature 2 - Description
41
+ ### Detection Logic
41
42
 
42
- ## Phase 2: Growth (1-3 months)
43
- ### Goals
44
- - [Goal]
43
+ For each spec entry, check `.catalyst/specs/{slug}/`:
45
44
 
46
- ### Key Features
47
- - [ ] Feature
45
+ ```
46
+ IF no folder exists for this entry:
47
+ → Status: Planned | Command: !/catalyze-spec "{seed prompt}"
48
48
 
49
- ## Phase 3: Scale (3-6 months)
50
- ### Goals
51
- - [Goal]
49
+ ELSE IF spec.md exists BUT tasks.md does NOT:
50
+ Status: DRAFT | Command: !/forge-spec @{slug} (or !/forge-spec-worktree @{slug})
52
51
 
53
- ### Key Features
54
- - [ ] Feature
52
+ ELSE IF tasks.md exists BUT validation.md does NOT:
53
+ Status: IN_PROGRESS | Command: !/audit-spec @{slug}
55
54
 
56
- ## Long-term Vision
57
- [Where this is heading in 6-12 months]
55
+ ELSE IF validation.md exists BUT not sealed:
56
+ Status: VALIDATING | Command: !/seal-spec @{slug}
58
57
 
59
- ---
60
- *Last updated: YYYY-MM-DD*
58
+ ELSE (sealed):
59
+ Status: COMPLETE | Command: (none)
61
60
  ```
62
61
 
62
+ ## Output Format
63
+
64
+ `.catalyst/main/roadmap.md` — uses the structure defined in `.catalyst/main/temp/temp-roadmap.md`
65
+
66
+ Specs are grouped within time-horizon sections:
67
+ - **Short-Term (1-3 months)** — immediate priorities
68
+ - **Medium-Term (3-6 months)** — next wave of work
69
+ - **Long-Term Vision (6+ months)** — strategic goals, not yet ready for specs
@@ -0,0 +1,20 @@
1
+ # /seal-spec
2
+
3
+ Commit, archive, and propagate learnings from a **fully built and audited** implementation.
4
+
5
+ > **Lifecycle position:** This is the FINAL step. Only use after `/forge-spec` and `/audit-spec` have completed successfully.
6
+ >
7
+ > **Flow:** `/catalyze-spec` → `/forge-spec` → `/audit-spec` → **`/seal-spec`**
8
+
9
+ ## Usage
10
+
11
+ ```
12
+ /seal-spec @2025-11-29-stripe-integration
13
+ /seal-spec @2025-11-29-stripe-integration "Great work!"
14
+ ```
15
+
16
+ ---
17
+
18
+ **Invoke skill:** `spec-approval`
19
+
20
+ **Process skills used:** `verification-before-completion`, `agent-delegation`
@@ -174,7 +174,7 @@ Tests: N/A
174
174
 
175
175
  NEXT STEPS
176
176
  ----------
177
- 1. Run /build-spec to start implementation
177
+ 1. Run /forge-spec to start implementation
178
178
  2. Forger will create task breakdown
179
179
  3. Enforcer will write tests first (TDD)
180
180
  ```
@@ -242,9 +242,9 @@ VALIDATION STATUS
242
242
 
243
243
  NEXT STEPS
244
244
  ----------
245
- 1. Complete validation: /review-spec @slug
245
+ 1. Complete validation: /audit-spec @slug
246
246
  2. Review handoff.md when ready
247
- 3. Commit: /commit-spec @slug
247
+ 3. Commit: /seal-spec @slug
248
248
  ```
249
249
 
250
250
  ---
@@ -262,7 +262,7 @@ tasks.md not found - implementation hasn't started.
262
262
 
263
263
  NEXT STEPS
264
264
  ----------
265
- Run /build-spec @2025-11-29-stripe-integration to begin.
265
+ Run /forge-spec @2025-11-29-stripe-integration to begin.
266
266
  ```
267
267
 
268
268
  ### Uncommitted Work Not Matching Any Task
@@ -0,0 +1,28 @@
1
+ # /sync-project
2
+
3
+ Sync all spec statuses with reality. Scans active specs, detects completed work, updates tasks.md, and archives finished specs.
4
+
5
+ > **Use when:** You forgot to `/audit-spec` and `/seal-spec` for one or more specs, or want to catch up on housekeeping.
6
+
7
+ ## Usage
8
+
9
+ ```
10
+ /sync-project # Sync all active specs
11
+ /sync-project "focus on auth" # Sync with specific focus
12
+ ```
13
+
14
+ ## Pre-computed Context
15
+
16
+ ```bash
17
+ # List all active specs
18
+ echo "=== ACTIVE SPECS ===" && ls -d .catalyst/specs/*/ 2>/dev/null || echo "No active specs"
19
+ echo "=== COMPLETED SPECS ===" && ls -d .catalyst/specs/completed/*/ 2>/dev/null || echo "No completed specs"
20
+ echo "=== GIT STATUS ===" && git status --short
21
+ echo "=== RECENT COMMITS ===" && git log --oneline -15
22
+ ```
23
+
24
+ ---
25
+
26
+ **Invoke skill:** `project-sync`
27
+
28
+ **Process skills used:** `verification-before-completion`
@@ -1,7 +1,7 @@
1
1
  # Build Orchestration
2
2
 
3
3
  > **When to invoke:** When implementing a specification using strict TDD.
4
- > **Invoked by:** `/build-spec` or `/build-spec-worktree` command.
4
+ > **Invoked by:** `/forge-spec` or `/forge-spec-worktree` command.
5
5
  > **Orchestrator:** Forge-Master agent.
6
6
 
7
7
  ## Purpose
@@ -28,7 +28,7 @@ Orchestrate the full build workflow: task breakdown, test writing, foundation, c
28
28
  ├── spec.md # Already exists from /catalyze-spec
29
29
  ├── research.md # Already exists from /catalyze-spec
30
30
  ├── tasks.md # Forger creates (this phase)
31
- ├── validation.md # Arbiter creates (in /review-spec)
31
+ ├── validation.md # Arbiter creates (in /audit-spec)
32
32
  ├── handoff.md # Updated throughout
33
33
  └── assets/
34
34
  ```
@@ -112,7 +112,7 @@ Phase 6: Integration (Enforcer — cross-boundary tests)
112
112
  ### Phase 0: Git Setup
113
113
 
114
114
  1. Read `project-config.yaml` for `development_branch`, `branch_prefix`, and `worktree_path`
115
- 2. IF `--worktree` flag (from `/build-spec-worktree`):
115
+ 2. IF `--worktree` flag (from `/forge-spec-worktree`):
116
116
  - `mkdir -p {worktree_path}` (default: `.catalyst/worktrees`)
117
117
  - `git worktree add {worktree_path}/{spec-slug} -b {branch_prefix}/{spec-slug} {development_branch}`
118
118
  - `cd {worktree_path}/{spec-slug}` — all subsequent work happens here
@@ -0,0 +1,114 @@
1
+ # Project Sync
2
+
3
+ > **When to invoke:** When syncing spec statuses with reality across the project.
4
+ > **Invoked by:** `/sync-project` command.
5
+
6
+ ## Purpose
7
+
8
+ Scan all active specs, detect which ones are actually complete, update their tasks.md, and move finished specs to the completed folder. This is a housekeeping command for catching up when `/audit-spec` and `/seal-spec` were skipped.
9
+
10
+ ## Skills Referenced
11
+
12
+ - `verification-before-completion` — Verify actual state before marking complete
13
+
14
+ ## Workflow
15
+
16
+ ### Phase 1: Scan Active Specs
17
+
18
+ 1. List all folders in `.catalyst/specs/` (excluding `completed/`)
19
+ 2. For each spec, read:
20
+ - `spec.md` — status and requirements
21
+ - `tasks.md` — task progress (if exists)
22
+ - `validation.md` — validation results (if exists)
23
+
24
+ ### Phase 2: Detect Actual State
25
+
26
+ For each spec, determine real status by checking:
27
+
28
+ 1. **Git history** — Are there commits referencing this spec?
29
+ 2. **Test results** — Do tests pass for this spec's scope?
30
+ 3. **File existence** — Are the expected implementation files present?
31
+ 4. **tasks.md progress** — Are tasks marked complete?
32
+
33
+ Classify each spec:
34
+
35
+ | Detected State | Criteria |
36
+ |---------------|----------|
37
+ | **Stale/Abandoned** | No commits in 30+ days, incomplete tasks |
38
+ | **Complete (unarchived)** | All tasks done, tests pass, but still in active specs |
39
+ | **In Progress** | Some tasks done, recent activity |
40
+ | **Draft** | spec.md exists but no tasks.md or implementation |
41
+
42
+ ### Phase 3: Present Findings
43
+
44
+ Show the user a summary:
45
+
46
+ ```
47
+ PROJECT SYNC REPORT
48
+ ===================
49
+
50
+ SPECS READY TO ARCHIVE (complete but not moved):
51
+ ✅ 2026-01-11-user-auth — All 8 tasks done, tests passing
52
+ ✅ 2026-02-15-stripe-integration — All 6 tasks done, tests passing
53
+
54
+ SPECS IN PROGRESS:
55
+ 🚧 2026-03-01-notifications — 4/7 tasks done
56
+ 🚧 2026-03-15-search — 2/5 tasks done
57
+
58
+ STALE SPECS (no activity in 30+ days):
59
+ ⚠️ 2026-01-05-legacy-migration — 0/3 tasks done, last commit 45 days ago
60
+
61
+ DRAFTS (not yet built):
62
+ 📋 2026-04-01-admin-dashboard — spec.md only, no tasks.md
63
+ ```
64
+
65
+ Ask user: "Which specs should I archive?"
66
+
67
+ ### Phase 4: Archive Confirmed Specs
68
+
69
+ For each spec the user confirms:
70
+
71
+ 1. Update `tasks.md`:
72
+ - Mark remaining in-progress tasks as complete (if work is done)
73
+ - Add sync note:
74
+ ```markdown
75
+ ## Synced
76
+ **Date:** YYYY-MM-DD
77
+ **Method:** /sync-project (batch archive)
78
+ ```
79
+
80
+ 2. Update `spec.md` status to `complete`
81
+
82
+ 3. Move to completed:
83
+ ```
84
+ .catalyst/specs/{slug}/ → .catalyst/specs/completed/{slug}/
85
+ ```
86
+
87
+ 4. Check for library extraction (same keyword matching as `/archive-spec`)
88
+
89
+ ### Phase 5: Update Roadmap (Optional)
90
+
91
+ If `.catalyst/main/roadmap.md` exists:
92
+ 1. Update status of archived specs to COMPLETE
93
+ 2. Update command sections for completed specs
94
+
95
+ ## Output
96
+
97
+ ```
98
+ Project synced!
99
+
100
+ Archived: 2 specs
101
+ ├── 2026-01-11-user-auth → .catalyst/specs/completed/
102
+ └── 2026-02-15-stripe-integration → .catalyst/specs/completed/
103
+
104
+ Skipped: 2 specs (still in progress)
105
+ ├── 2026-03-01-notifications (4/7 tasks)
106
+ └── 2026-03-15-search (2/5 tasks)
107
+
108
+ Flagged: 1 stale spec
109
+ └── 2026-01-05-legacy-migration (no activity 45 days)
110
+
111
+ Library: Added authentication.md, payment-integration.md
112
+
113
+ Roadmap: Updated .catalyst/main/roadmap.md
114
+ ```
@@ -1,7 +1,7 @@
1
1
  # Spec Approval
2
2
 
3
3
  > **When to invoke:** When accepting an implementation and archiving the spec.
4
- > **Invoked by:** `/commit-spec` command.
4
+ > **Invoked by:** `/seal-spec` command.
5
5
 
6
6
  ## Purpose
7
7
 
@@ -15,12 +15,12 @@ Final verification, git commit, spec archival, self-documentation (propagate lea
15
15
  ## Prerequisites — HARD GATES
16
16
 
17
17
  > **This skill is the FINAL step in the spec lifecycle.** It runs ONLY after build and validation are complete.
18
- > **Flow:** `/catalyze-spec` → `/build-spec` → `/review-spec` → **`/commit-spec`** (you are here)
18
+ > **Flow:** `/catalyze-spec` → `/forge-spec` → `/audit-spec` → **`/seal-spec`** (you are here)
19
19
  >
20
- > If the spec has not been built yet, STOP and tell the user to run `/build-spec` first.
21
- > If the spec has not been validated yet, STOP and tell the user to run `/review-spec` first.
20
+ > If the spec has not been built yet, STOP and tell the user to run `/forge-spec` first.
21
+ > If the spec has not been validated yet, STOP and tell the user to run `/audit-spec` first.
22
22
 
23
- - `/build-spec` must have been completed (tasks.md exists with completed tasks)
23
+ - `/forge-spec` must have been completed (tasks.md exists with completed tasks)
24
24
  - Validation must be complete (`validation.md` must show all checks passed)
25
25
  - `handoff.md` must exist
26
26
  - TDD compliance verified
@@ -0,0 +1,77 @@
1
+ # Spec Archival
2
+
3
+ > **When to invoke:** When archiving a spec without git ceremony.
4
+ > **Invoked by:** `/archive-spec` command.
5
+
6
+ ## Purpose
7
+
8
+ Lightweight spec completion: move to completed folder, check for library patterns, update status. No TDD verification, no git branch checks, no commit creation, no push suggestions.
9
+
10
+ > **For full ceremony with git management:** Use `/seal-spec` instead.
11
+ >
12
+ > **Flow:** `/catalyze-spec` → `/forge-spec` → `/audit-spec` → **`/archive-spec`** (you are here)
13
+
14
+ ## Skills Referenced
15
+
16
+ - `verification-before-completion` — Verify spec folder exists before archiving
17
+
18
+ ## Workflow
19
+
20
+ ### Phase 1: Read Spec and Verify
21
+
22
+ 1. Read spec.md to understand what's being archived
23
+ 2. Read tasks.md to understand current progress (if exists)
24
+ 3. Verify spec folder exists in `.catalyst/specs/`
25
+ - IF NOT FOUND → STOP: "Spec not found: @{slug}"
26
+
27
+ 4. Check spec readiness:
28
+ - **DRAFT** (no tasks.md): Ask user — "This spec was never built. Archive a draft?"
29
+ - **IN_PROGRESS** (tasks incomplete): Ask user — "Some tasks are incomplete. Archive anyway?"
30
+ - **VALIDATING or later**: Proceed without confirmation
31
+
32
+ ### Phase 2: Update tasks.md
33
+
34
+ 1. Mark tasks that are actually done as complete (check git history, file existence, test results)
35
+ 2. Leave incomplete tasks as-is — they stay open for visibility
36
+
37
+ ### Phase 3: Library Extraction (Optional)
38
+
39
+ Auto-detect reusable patterns from spec name/content using keyword matching:
40
+
41
+ | Pattern Keywords | Suggested Library Item |
42
+ |-----------------|----------------------|
43
+ | stripe, payment | payment-integration.md |
44
+ | auth, oauth, login | authentication.md |
45
+ | upload, s3, storage | file-storage.md |
46
+ | websocket, realtime | real-time-communication.md |
47
+ | email, notification | notifications.md |
48
+ | search, elasticsearch | search-implementation.md |
49
+ | cache, redis | caching-strategy.md |
50
+ | queue, job, worker | background-jobs.md |
51
+
52
+ Ask user if spec should be added to pattern library. If yes, delegate to Scribe for extraction to `.catalyst/library/`.
53
+
54
+ ### Phase 4: Archive
55
+
56
+ 1. Move spec folder:
57
+ ```
58
+ .catalyst/specs/{slug}/ → .catalyst/specs/completed/{slug}/
59
+ ```
60
+ 2. Update spec.md frontmatter status to `complete`
61
+ 3. Add completion date to frontmatter
62
+
63
+ ## Output
64
+
65
+ ```
66
+ Spec archived!
67
+
68
+ Spec: {slug}
69
+ Status: COMPLETE
70
+
71
+ Archived to: .catalyst/specs/completed/{slug}/
72
+
73
+ Library: {Added to .catalyst/library/X.md | Skipped}
74
+
75
+ Note: This was a lightweight archive (no git ceremony).
76
+ For full commit + branch management, use /seal-spec.
77
+ ```
@@ -167,15 +167,14 @@ Created: .catalyst/specs/YYYY-MM-DD-{slug}/
167
167
  ├── handoff.md <- Living document
168
168
  └── assets/ <- UI references (if any)
169
169
 
170
- REMINDER: /build-spec follows strict TDD
170
+ REMINDER: /forge-spec follows strict TDD
171
171
  1. Tests written FIRST (Enforcer)
172
172
  2. Tests must FAIL (red phase)
173
173
  3. Then implement (Builders)
174
174
  4. Tests must PASS (green phase)
175
175
 
176
176
  Next steps:
177
- - /build-spec @YYYY-MM-DD-{slug} to start TDD build
178
- - Or /iterate-spec if you want changes first
177
+ - /forge-spec @YYYY-MM-DD-{slug} to start TDD build
179
178
  ```
180
179
 
181
- **IMPORTANT: Do NOT suggest `/commit-spec` after spec shaping.** `/commit-spec` is only for committing a fully built and validated implementation — it is the FINAL step, not a plan-approval step. The correct flow is: `/catalyze-spec` → `/build-spec` → `/review-spec` → `/commit-spec`.
180
+ **IMPORTANT: Do NOT suggest `/seal-spec` after spec shaping.** `/seal-spec` is only for committing a fully built and validated implementation — it is the FINAL step, not a plan-approval step. The correct flow is: `/catalyze-spec` → `/forge-spec` → `/audit-spec` → `/seal-spec`.
@@ -5,7 +5,7 @@
5
5
 
6
6
  ## Purpose
7
7
 
8
- Update spec documentation (requirements, tasks, research) without continuing to build. Unlike `/iterate-spec`, this STOPS after updating docs.
8
+ Update spec documentation (requirements, tasks, research) without continuing to build.
9
9
 
10
10
  ## Skills Referenced
11
11
 
@@ -79,5 +79,5 @@ Change: {description}
79
79
  Updated files: {list}
80
80
  Impact: {new/removed requirements and tasks}
81
81
 
82
- Next: Continue with /build-spec or /iterate-spec
82
+ Next: Continue with /forge-spec
83
83
  ```
@@ -1,8 +1,12 @@
1
1
  # Spec Validation
2
2
 
3
3
  > **When to invoke:** When running validation checks on a completed implementation.
4
- > **Invoked by:** `/review-spec` command.
4
+ > **Invoked by:** `/audit-spec` command.
5
5
  > **Orchestrator:** Arbiter agent.
6
+ >
7
+ > **Lifecycle position:** `/catalyze-spec` → `/forge-spec` → **`/audit-spec`** → `/seal-spec`
8
+ >
9
+ > This skill audits the CODE implementation (quality, security, tests) — not the spec document.
6
10
 
7
11
  ## Purpose
8
12
 
@@ -14,11 +18,16 @@ Orchestrate comprehensive validation: TDD compliance, unit tests, E2E tests, cod
14
18
  - `agent-delegation` — Parallel agent spawning rules
15
19
  - `test-driven-development` — TDD compliance verification
16
20
 
17
- ## Prerequisites
21
+ ## Prerequisites — BLOCKING
18
22
 
19
- - Spec must be in "build complete" state
20
- - All tasks in `tasks.md` marked complete
21
- - TDD compliance verified (tests pass)
23
+ Before ANY validation begins, verify the spec was actually built:
24
+
25
+ 1. **tasks.md must exist** in the spec folder
26
+ - IF NOT FOUND → STOP: "No tasks.md found. Run `/forge-spec @{slug}` first."
27
+ 2. **Spec status must be IN_PROGRESS or later** (not DRAFT)
28
+ - IF DRAFT → STOP: "Spec is still in DRAFT. Run `/forge-spec @{slug}` to implement it first."
29
+ 3. All tasks in `tasks.md` marked complete
30
+ 4. TDD compliance verified (tests pass)
22
31
 
23
32
  ## Output Location
24
33
 
@@ -38,7 +47,7 @@ Before validation begins, verify TDD was followed:
38
47
  2. Verify all tests pass
39
48
  3. Verify tests were written before implementation
40
49
 
41
- If TDD was skipped → REJECT and return to /build-spec
50
+ If TDD was skipped → REJECT and return to /forge-spec
42
51
  ```
43
52
 
44
53
  ## Parallel Execution
@@ -157,19 +166,19 @@ If all validation passes, create handoff.md with:
157
166
  ```
158
167
  Validation complete!
159
168
  Status: READY FOR APPROVAL
160
- Next: /commit-spec @slug
169
+ Next: /seal-spec @slug
161
170
  ```
162
171
 
163
172
  ### TDD Failure
164
173
  ```
165
174
  Validation blocked!
166
175
  TDD Compliance: FAILED
167
- Action: Return to /build-spec and follow TDD process
176
+ Action: Return to /forge-spec and follow TDD process
168
177
  ```
169
178
 
170
179
  ### Validation Failure
171
180
  ```
172
181
  Validation failed!
173
182
  Failed Checks: [details]
174
- Action: Fix issues and re-run /review-spec
183
+ Action: Fix issues and re-run /audit-spec
175
184
  ```
@@ -42,13 +42,13 @@ Skills tell you HOW. User instructions tell you WHAT.
42
42
  | Skill | Path | Load when... |
43
43
  |-------|------|-------------|
44
44
  | **spec-shaping** | `.claude/skills/spec-shaping/SKILL.md` | `/catalyze-spec` — shaping a new specification |
45
- | **build-orchestration** | `.claude/skills/build-orchestration/SKILL.md` | `/build-spec` — implementing a specification |
46
- | **spec-iteration** | `.claude/skills/spec-iteration/SKILL.md` | `/iterate-spec` — updating and continuing a build |
47
- | **spec-validation** | `.claude/skills/spec-validation/SKILL.md` | `/review-spec` — quality checks on implementation |
48
- | **spec-approval** | `.claude/skills/spec-approval/SKILL.md` | `/commit-spec` — final commit and archival |
45
+ | **build-orchestration** | `.claude/skills/build-orchestration/SKILL.md` | `/forge-spec` — implementing a specification |
46
+ | **spec-validation** | `.claude/skills/spec-validation/SKILL.md` | `/audit-spec` — quality checks on implementation |
47
+ | **spec-approval** | `.claude/skills/spec-approval/SKILL.md` | `/seal-spec` — final commit and archival |
48
+ | **spec-archival** | `.claude/skills/spec-archival/SKILL.md` | `/archive-spec` — lightweight completion and archival |
49
49
  | **project-initialization** | `.claude/skills/project-initialization/SKILL.md` | `/catalyze-project` — setting up a new project |
50
- | **task-building** | `.claude/skills/task-building/SKILL.md` | `/build-task` — building a single task (brownfield) |
51
50
  | **spec-update** | `.claude/skills/spec-update/SKILL.md` | `/update-spec` — modifying an existing spec |
51
+ | **project-sync** | `.claude/skills/project-sync/SKILL.md` | `/sync-project` — batch sync and archive specs |
52
52
 
53
53
  ---
54
54
 
package/README.md CHANGED
@@ -10,10 +10,9 @@
10
10
  npx catalyst-os # Install to your project
11
11
  /catalyze-project # Initialize project foundation
12
12
  /catalyze-spec "description" # Shape a feature specification
13
- /build-spec @spec-name # Implement with TDD
14
- /iterate-spec @spec-name "improvement" # Add improvements mid-build
15
- /review-spec @spec-name # Run quality checks
16
- /commit-spec @spec-name # Accept and archive
13
+ /forge-spec @spec-name # Implement with TDD
14
+ /audit-spec @spec-name # Run quality checks
15
+ /seal-spec @spec-name # Accept and archive
17
16
  ```
18
17
 
19
18
  ---
@@ -46,11 +45,11 @@ Then run `/catalyze-project` to initialize — this detects your workspace type,
46
45
  │ ├── workspace-detection/
47
46
  │ ├── spec-shaping/
48
47
  │ ├── build-orchestration/
49
- │ ├── spec-iteration/
50
48
  │ ├── spec-validation/
51
49
  │ ├── spec-approval/
50
+ │ ├── spec-archival/
52
51
  │ ├── project-initialization/
53
- │ ├── task-building/
52
+ │ ├── project-sync/
54
53
  │ └── spec-update/
55
54
  └── commands/ # WHEN - Thin triggers (invoke skills)
56
55
 
@@ -103,12 +102,12 @@ Without this, skills are optional documentation. With it, they're mandatory proc
103
102
  | Skill | Command | Purpose |
104
103
  |-------|---------|---------|
105
104
  | `spec-shaping` | `/catalyze-spec` | Shape feature requests into specifications |
106
- | `build-orchestration` | `/build-spec` | DAG-based TDD implementation |
107
- | `spec-iteration` | `/iterate-spec` | Update and continue mid-build |
108
- | `spec-validation` | `/review-spec` | Quality checks via Guardian agents |
109
- | `spec-approval` | `/commit-spec` | Final verification and archival |
105
+ | `build-orchestration` | `/forge-spec` | DAG-based TDD implementation |
106
+ | `spec-validation` | `/audit-spec` | Quality checks via Guardian agents |
107
+ | `spec-approval` | `/seal-spec` | Final verification and archival |
108
+ | `spec-archival` | `/archive-spec` | Lightweight completion and archival |
110
109
  | `project-initialization` | `/catalyze-project` | Workspace detection + foundation docs |
111
- | `task-building` | `/build-task` | Single task (brownfield) |
110
+ | `project-sync` | `/sync-project` | Batch sync and archive specs |
112
111
  | `spec-update` | `/update-spec` | Modify spec during planning phase |
113
112
 
114
113
  ---
@@ -173,9 +172,9 @@ Guardians (Quality)
173
172
  ```
174
173
  ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐
175
174
  │ │ │ │ │ │ │ │
176
- │ CATALYZE │────>│ BUILD │────>│ REVIEW │────>│ COMMIT
175
+ │ CATALYZE │────>│ FORGE │────>│ AUDIT │────>│ SEAL
177
176
  │ │ │ │ │ │ │ │
178
- │ /catalyze- │ │ /build-spec │ │ /review-spec │ │ /commit-spec
177
+ │ /catalyze- │ │ /forge-spec │ │ /audit-spec │ │ /seal-spec
179
178
  │ spec │ │ │ │ │ │ │
180
179
  └──────────────┘ └──────────────┘ └──────────────┘ └──────────────┘
181
180
  │ │ │ │
@@ -184,15 +183,6 @@ Guardians (Quality)
184
183
  │ spec.md │ │ tasks.md │ │ validation.md│ │ Commit + │
185
184
  │ research.md │ │ (updated) │ │ handoff.md │ │ Archive │
186
185
  └──────────────┘ └──────────────┘ └──────────────┘ └──────────────┘
187
-
188
- v
189
- ┌──────────────┐
190
- │ ITERATE │ <--- New idea during build?
191
- │ │
192
- │ /iterate- │ Updates spec + tasks
193
- │ spec │ Continues building
194
- └──────────────┘
195
-
196
186
  Context full? New conversation?
197
187
  Run /primer-spec @slug to restore awareness before continuing.
198
188
  ```
@@ -205,12 +195,12 @@ Guardians (Quality)
205
195
  |---------|-------------|--------|
206
196
  | `/catalyze-project` | Start new project | mission.md, roadmap.md, tech-stack.md |
207
197
  | `/catalyze-spec "feature"` | New feature request | spec.md, research.md |
208
- | `/build-spec @slug` | Implement feature | tasks.md (updated) |
209
- | `/iterate-spec @slug "idea"` | Add improvements mid-build | Updated spec + tasks, continues building |
198
+ | `/forge-spec @slug` | Implement feature | tasks.md (updated) |
210
199
  | `/primer-spec @slug` | Restore context (new conversation) | Brief status summary |
211
- | `/build-task "description"` | Modify existing code | task.md in .catalyst/tasks/ |
212
- | `/review-spec @slug` | Quality checks | validation.md, handoff.md |
213
- | `/commit-spec @slug` | Finalize | Commit + Archive |
200
+ | `/audit-spec @slug` | Quality checks | validation.md, handoff.md |
201
+ | `/seal-spec @slug` | Finalize | Commit + Archive |
202
+ | `/archive-spec @slug` | Lightweight archive | Archive (no git ceremony) |
203
+ | `/sync-project` | Batch sync spec statuses | Sync report + archives |
214
204
  | `/discard-spec @slug "reason"` | Discard implementation | Status: REJECTED |
215
205
  | `/status-spec @slug` | Check progress | Current status |
216
206
  | `/update-spec @slug "change"` | Modify spec (planning phase) | Updated spec.md |
@@ -296,7 +286,7 @@ Enforcer -> Builders │ TDD: tests before code
296
286
 
297
287
  ## Pattern Library
298
288
 
299
- Reusable implementation patterns extracted from completed specs via `/commit-spec`.
289
+ Reusable implementation patterns extracted from completed specs via `/seal-spec`, `/archive-spec`, or `/sync-project`.
300
290
 
301
291
  **Location:** `.catalyst/library/`
302
292
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "catalyst-os",
3
- "version": "1.3.1",
3
+ "version": "2.0.0",
4
4
  "scripts": {
5
5
  "postinstall": "node .catalyst/bin/install.js",
6
6
  "validate": "node .catalyst/bin/validate-artifacts.js"
@@ -1,16 +0,0 @@
1
- # /build-task
2
-
3
- Execute a focused task on an existing codebase. Works with or without prior specs.
4
-
5
- ## Usage
6
-
7
- ```
8
- /build-task "change session timeout to 30 days"
9
- /build-task @2026-01-11-supabase-auth "change session timeout"
10
- ```
11
-
12
- ---
13
-
14
- **Invoke skill:** `task-building`
15
-
16
- **Process skills used:** `test-driven-development`, `agent-delegation`, `verification-before-completion`, `systematic-debugging`
@@ -1,20 +0,0 @@
1
- # /commit-spec
2
-
3
- Commit, archive, and propagate learnings from a **fully built and validated** implementation.
4
-
5
- > **Lifecycle position:** This is the FINAL step. Only use after `/build-spec` and `/review-spec` have completed successfully.
6
- >
7
- > **Flow:** `/catalyze-spec` → `/build-spec` → `/review-spec` → **`/commit-spec`**
8
-
9
- ## Usage
10
-
11
- ```
12
- /commit-spec @2025-11-29-stripe-integration
13
- /commit-spec @2025-11-29-stripe-integration "Great work!"
14
- ```
15
-
16
- ---
17
-
18
- **Invoke skill:** `spec-approval`
19
-
20
- **Process skills used:** `verification-before-completion`, `agent-delegation`
@@ -1,28 +0,0 @@
1
- # /iterate-spec
2
-
3
- Continue building a spec with new improvements discovered during development.
4
-
5
- ## Usage
6
-
7
- ```
8
- /iterate-spec @2025-11-29-stripe-integration "add support for annual billing"
9
- /iterate-spec @2025-11-29-stripe-integration "handle edge case where user cancels mid-checkout"
10
- ```
11
-
12
- ## Pre-computed Context
13
-
14
- ```bash
15
- # Current state for iteration
16
- echo "=== BRANCH ===" && git branch --show-current
17
- echo "=== STATUS ===" && git status --short
18
- echo "=== TASKS.MD ===" && cat .catalyst/specs/*$ARGUMENTS*/tasks.md 2>/dev/null | head -80 || echo "No tasks.md for: $ARGUMENTS"
19
- echo "=== SPEC FRONTMATTER ===" && head -30 .catalyst/specs/*$ARGUMENTS*/spec.md 2>/dev/null || echo "No spec.md"
20
- ```
21
-
22
- ---
23
-
24
- **Invoke skill:** `spec-iteration`
25
-
26
- **Orchestrator:** Forge-Master (delegates to Oracle, Scribe, Forger, Enforcer, Smith, Shaper, Alchemist)
27
-
28
- **Process skills used:** `test-driven-development`, `agent-delegation`, `brainstorming`
@@ -1,135 +0,0 @@
1
- # Spec Iteration
2
-
3
- > **When to invoke:** When adding improvements, enhancements, or edge case handling to a spec that's being built.
4
- > **Invoked by:** `/iterate-spec` command.
5
- > **Orchestrator:** Forge-Master agent.
6
-
7
- ## Purpose
8
-
9
- Continue building a spec with new improvements discovered during development. Unlike `/update-spec` which stops after updating docs, iteration updates docs AND continues building in one flow.
10
-
11
- ## Skills Referenced
12
-
13
- - `test-driven-development` — New tests must follow TDD
14
- - `agent-delegation` — Orchestrator rules
15
- - `verification-before-completion` — Verify before claiming done
16
- - `brainstorming` — Oracle uses if improvement needs clarification
17
-
18
- ## Prerequisites
19
-
20
- - Spec must exist in `.catalyst/specs/`
21
- - Build has been started (`tasks.md` exists)
22
- - On the feature branch from `/build-spec`
23
-
24
- ## Key Difference
25
-
26
- ```
27
- /update-spec → Updates docs → STOPS → Manual /build-spec
28
- /iterate-spec → Updates docs → CONTINUES BUILDING (single flow)
29
- ```
30
-
31
- ## Git Workflow
32
-
33
- ```
34
- PHASE 0: Verify on feature branch
35
- GATE 1: RED FLAG → Commit: "test({scope}): add tests for {improvement}"
36
- GATE 2: GREEN FLAG → Commit: "feat({scope}): {improvement description}"
37
- ```
38
-
39
- ## TDD IS MANDATORY
40
-
41
- ```
42
- 1. Task(subagent_type="scribe") -> Update spec.md
43
- 2. Task(subagent_type="forger") -> Add new tasks to tasks.md
44
- 3. Task(subagent_type="enforcer") -> Write tests for NEW tasks (must FAIL)
45
- 4. Verify -> Run tests, confirm RED for new tests
46
- 5. Task(subagent_type="smith/shaper/alchemist") -> Implement until GREEN
47
- ```
48
-
49
- ## Execution Order
50
-
51
- ```
52
- Phase 1: Clarify (Oracle — if needed)
53
- |
54
- Phase 2: Update Spec (Scribe)
55
- |
56
- Phase 3: Update Tasks (Forger)
57
- |
58
- Phase 4: Write Tests (Enforcer) — NEW tasks only
59
- |
60
- GATE 1: RED PHASE — New tests must FAIL, existing PASS
61
- |
62
- Phase 5: Implement (Smith/Shaper/Alchemist)
63
- |
64
- GATE 2: GREEN PHASE — All tests must PASS
65
- ```
66
-
67
- ## Workflow Detail
68
-
69
- ### Phase 0: Verify State
70
-
71
- 1. Check if `.catalyst/worktrees/{spec-slug}` exists
72
- - IF exists: `cd` into it (worktree mode)
73
- 2. ELSE: Verify on feature branch: `git branch --show-current`
74
- 3. Read existing spec.md and tasks.md
75
- 4. If neither worktree nor feature branch: ask user to run `/build-spec` or `/build-spec-worktree`
76
-
77
- ### Phase 1: Clarify (Oracle — Optional)
78
-
79
- If improvement description is vague, spawn Oracle. Skip if already clear and specific.
80
-
81
- ### Phase 2: Update Specification (Scribe)
82
-
83
- Spawn Scribe to update spec.md:
84
- - Add new requirements
85
- - Update Changelog with date and description
86
- - Keep Status as IN_PROGRESS
87
- - Do NOT change completed requirements
88
-
89
- ### Phase 3: Update Tasks (Forger)
90
-
91
- Spawn Forger to update tasks.md:
92
- - Read current tasks, identify completed vs pending
93
- - Add NEW tasks with `iter-` prefix
94
- - Update Build DAG with dependencies
95
- - Do NOT modify completed tasks
96
-
97
- ### Phase 4: Write Tests (Enforcer) — RED PHASE
98
-
99
- Write tests for NEW iteration tasks only. Do NOT modify existing tests.
100
-
101
- ### GATE 1: Red Phase
102
-
103
- - New tests FAIL
104
- - Existing tests still PASS (no regression)
105
- - Commit: `test({scope}): add tests for {improvement}`
106
-
107
- ### Phase 5: Implementation
108
-
109
- Spawn appropriate agents (Smith/Shaper/Alchemist) based on task types. Parallel execution allowed if non-overlapping scopes.
110
-
111
- ### GATE 2: Green Phase
112
-
113
- - All new tests PASS
114
- - All existing tests still PASS
115
- - Commit: `feat({scope}): {improvement description}`
116
-
117
- ## Failure Modes
118
-
119
- | Failure | Action |
120
- |---------|--------|
121
- | Not on feature branch | Checkout, run `/build-spec`, or `/build-spec-worktree` first |
122
- | Spec not found | Run `/catalyze-spec` first |
123
- | tasks.md missing | Run `/build-spec` first |
124
- | Improvement conflicts with existing | Spawn Oracle to discuss options |
125
- | New tests pass immediately | Tests are wrong — rewrite for NEW functionality |
126
-
127
- ## When to Use
128
-
129
- - Discovered better approach during testing
130
- - Thought of an improvement or enhancement
131
- - Found an edge case that should be handled
132
- - Want to add something that makes the feature better
133
-
134
- **NOT for bugs** — bugs are implementation issues, not spec changes.
135
- **NOT for missing requirements** — use `/update-spec` first.
@@ -1,96 +0,0 @@
1
- # Task Building
2
-
3
- > **When to invoke:** When executing a focused task on an existing codebase.
4
- > **Invoked by:** `/build-task` command.
5
-
6
- ## Purpose
7
-
8
- Execute focused, brownfield-compatible tasks. Works with or without prior specs. Simpler flow than full spec build.
9
-
10
- ## Skills Referenced
11
-
12
- - `test-driven-development` — Test assessment and TDD when needed
13
- - `agent-delegation` — Orchestrator rules
14
- - `verification-before-completion` — Verify before marking complete
15
- - `systematic-debugging` — When tests fail during implementation
16
-
17
- ## When to Use
18
-
19
- | Use `/build-task` | Use `/catalyze-spec` |
20
- |-------------------|----------------------|
21
- | Modify existing feature | New feature from scratch |
22
- | Stakeholder change request | Major addition |
23
- | Mid-level refactoring | Architectural change |
24
- | Post-completion modifications | Needs research phase |
25
- | Brownfield projects (no specs) | Greenfield projects |
26
-
27
- ## Output Location
28
-
29
- ```
30
- .catalyst/tasks/YYYY-MM-DD-{slug}.md
31
- ```
32
-
33
- Tasks are independent entities. They can optionally reference specs.
34
-
35
- ## Workflow
36
-
37
- ### Phase 0: Context Gathering
38
-
39
- 1. Check for @spec reference → read spec for context
40
- 2. Auto-detect related specs in `.catalyst/specs/`
41
- 3. Create task file
42
-
43
- ### Phase 1: Test Assessment (Enforcer)
44
-
45
- Spawn Enforcer to analyze test coverage:
46
-
47
- | Strategy | Condition | Action |
48
- |----------|-----------|--------|
49
- | **COVERED** | Existing tests fully cover this change | Skip to Phase 3 |
50
- | **MODIFY** | Tests exist but assertions need updating | Update tests first |
51
- | **NEW** | No tests cover this area | Write new tests first |
52
-
53
- ### Phase 2: Tests (if MODIFY or NEW)
54
-
55
- Spawn Enforcer to write/update tests. Tests must FAIL before implementation (TDD).
56
-
57
- ### Phase 3: Implementation
58
-
59
- Spawn appropriate builder based on task scope:
60
- - Smith for backend
61
- - Shaper for frontend
62
- - Alchemist for database
63
-
64
- ### Phase 4: Verify & Commit
65
-
66
- 1. Run tests — all must pass
67
- 2. Run lint — no errors
68
- 3. Update task file — mark COMPLETE
69
- 4. Commit with structured message
70
-
71
- ## Task File Format
72
-
73
- ```markdown
74
- # Task: {Title}
75
-
76
- > Status: IN_PROGRESS | COMPLETE
77
- > Created: YYYY-MM-DD
78
- > Related Spec: @spec-name (optional)
79
-
80
- ## Description
81
- {What needs to change and why}
82
-
83
- ## Test Assessment
84
- | Strategy | Reason |
85
- |----------|--------|
86
- | COVERED / MODIFY / NEW | {Explanation} |
87
-
88
- ## Changes Required
89
- - [ ] {Task item}
90
-
91
- ## Files Modified
92
- - src/path/to/file.ts
93
-
94
- ## Commit
95
- - Hash: {filled on completion}
96
- ```