catalyst-os 1.1.1 → 1.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/.catalyst/main/project-config.yaml +3 -0
- package/.claude/agents/alchemist.md +29 -1
- package/.claude/agents/enforcer.md +26 -0
- package/.claude/agents/forge-master.md +10 -1
- package/.claude/agents/shaper.md +29 -1
- package/.claude/agents/smith.md +29 -1
- package/.claude/commands/build-spec-worktree.md +19 -0
- package/.claude/settings.local.json +5 -3
- package/.claude/skills/build-orchestration/SKILL.md +26 -7
- package/.claude/skills/spec-iteration/SKILL.md +6 -4
- package/package.json +1 -1
|
@@ -25,6 +25,9 @@ git:
|
|
|
25
25
|
- "main"
|
|
26
26
|
- "master"
|
|
27
27
|
|
|
28
|
+
# Path for git worktrees (relative to repo root, used by /build-spec-worktree)
|
|
29
|
+
worktree_path: ".catalyst/worktrees"
|
|
30
|
+
|
|
28
31
|
# Commit message templates
|
|
29
32
|
commit_templates:
|
|
30
33
|
red_phase: "test({scope}): write failing tests for {spec}"
|
|
@@ -41,7 +41,8 @@ You handle all database concerns including schema design, migrations, and data t
|
|
|
41
41
|
5. **Indexes**: Plan for query performance
|
|
42
42
|
6. **Migration**: Write safe, reversible migrations
|
|
43
43
|
7. **Self-Review**: Before reporting done (see below)
|
|
44
|
-
8. **
|
|
44
|
+
8. **Update tasks.md**: Mark your task as done (see below) — MANDATORY
|
|
45
|
+
9. **Report**: Actual test/migration output, files changed, any concerns
|
|
45
46
|
|
|
46
47
|
## Self-Review Before Reporting
|
|
47
48
|
|
|
@@ -72,6 +73,33 @@ Before reporting task completion to the orchestrator, review your own work:
|
|
|
72
73
|
|
|
73
74
|
If you find issues during self-review, fix them before reporting.
|
|
74
75
|
|
|
76
|
+
## MANDATORY: Update tasks.md on Completion
|
|
77
|
+
|
|
78
|
+
**After your task passes self-review, you MUST update tasks.md BEFORE reporting back.**
|
|
79
|
+
|
|
80
|
+
The orchestrator may lose context or the conversation may end before it updates. If you don't do this, your work looks like it never happened.
|
|
81
|
+
|
|
82
|
+
### How to Update
|
|
83
|
+
|
|
84
|
+
1. **Find tasks.md**: Read `.catalyst/specs/*/tasks.md` (the spec you're working on)
|
|
85
|
+
2. **Update the Progress table**: Change your task's status from `⚡ Active` to `✓ Done`
|
|
86
|
+
3. **Add commit hash** if you committed
|
|
87
|
+
4. **Update Current Session**: Note what's next based on the DAG
|
|
88
|
+
|
|
89
|
+
### Example
|
|
90
|
+
|
|
91
|
+
Before:
|
|
92
|
+
```
|
|
93
|
+
| db-schema | ⚡ Active | alchemist | Pending | Working... |
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
After:
|
|
97
|
+
```
|
|
98
|
+
| db-schema | ✓ Done | alchemist | ✓ Pass | Schema migrated, types generated |
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
**If you skip this step, `/primer-spec` will show the spec as not started and all your progress is invisible.**
|
|
102
|
+
|
|
75
103
|
## When Receiving Review Feedback
|
|
76
104
|
|
|
77
105
|
Follow `.claude/skills/receiving-code-review/SKILL.md`:
|
|
@@ -85,6 +85,32 @@ Write test → Run (PASS) → Revert the fix → Run (MUST FAIL) → Restore fix
|
|
|
85
85
|
If it doesn't fail when reverted, the test is worthless.
|
|
86
86
|
```
|
|
87
87
|
|
|
88
|
+
## MANDATORY: Update tasks.md on Completion
|
|
89
|
+
|
|
90
|
+
**After completing your test-writing or integration task, you MUST update tasks.md BEFORE reporting back.**
|
|
91
|
+
|
|
92
|
+
The orchestrator may lose context or the conversation may end before it updates. If you don't do this, your work looks like it never happened.
|
|
93
|
+
|
|
94
|
+
### How to Update
|
|
95
|
+
|
|
96
|
+
1. **Find tasks.md**: Read `.catalyst/specs/*/tasks.md` (the spec you're working on)
|
|
97
|
+
2. **Update the Progress table**: Change your task's status from `⚡ Active` to `✓ Done`
|
|
98
|
+
3. **Update Current Session**: Note what's next based on the DAG
|
|
99
|
+
|
|
100
|
+
### Example
|
|
101
|
+
|
|
102
|
+
Before:
|
|
103
|
+
```
|
|
104
|
+
| integration | ⚡ Active | enforcer | Pending | Running E2E tests |
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
After:
|
|
108
|
+
```
|
|
109
|
+
| integration | ✓ Done | enforcer | ✓ Pass | All integration tests passing |
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
**If you skip this step, `/primer-spec` will show the spec as not started and all your progress is invisible.**
|
|
113
|
+
|
|
88
114
|
## Principles
|
|
89
115
|
|
|
90
116
|
- **Red First**: Tests must fail before implementation — and you must WATCH them fail
|
|
@@ -214,9 +214,18 @@ Agent reports "task complete, tests pass":
|
|
|
214
214
|
1. Check: Did the agent include actual test output in its report?
|
|
215
215
|
2. Check: Does VCS diff show the expected file changes?
|
|
216
216
|
3. Run: Execute the test command for that scope yourself
|
|
217
|
-
4.
|
|
217
|
+
4. Verify: Did the agent update tasks.md Progress table? (agents are instructed to)
|
|
218
|
+
5. If NOT updated: Update tasks.md yourself IMMEDIATELY
|
|
219
|
+
6. ONLY THEN: Consider the task Done
|
|
218
220
|
```
|
|
219
221
|
|
|
222
|
+
### CRITICAL: tasks.md Must Stay Current
|
|
223
|
+
|
|
224
|
+
Agents are instructed to update tasks.md themselves. But if an agent fails to do so:
|
|
225
|
+
- **You MUST update tasks.md immediately** after verifying completion
|
|
226
|
+
- Do NOT defer this — if the conversation ends, stale tasks.md means `/primer-spec` shows no progress
|
|
227
|
+
- Update BOTH the Progress table AND the Current Session section
|
|
228
|
+
|
|
220
229
|
## Escalation Protocol
|
|
221
230
|
|
|
222
231
|
See: `.claude/skills/agent-delegation/SKILL.md`
|
package/.claude/agents/shaper.md
CHANGED
|
@@ -41,7 +41,8 @@ You implement frontend functionality including React components, pages, and UI f
|
|
|
41
41
|
5. **Style**: Apply styling to match design
|
|
42
42
|
6. **Polish**: Add interactions, transitions, states
|
|
43
43
|
7. **Self-Review**: Before reporting done (see below)
|
|
44
|
-
8. **
|
|
44
|
+
8. **Update tasks.md**: Mark your task as done (see below) — MANDATORY
|
|
45
|
+
9. **Report**: Actual test output, files changed, any concerns
|
|
45
46
|
|
|
46
47
|
## Self-Review Before Reporting
|
|
47
48
|
|
|
@@ -68,6 +69,33 @@ Before reporting task completion to the orchestrator, review your own work:
|
|
|
68
69
|
|
|
69
70
|
If you find issues during self-review, fix them before reporting.
|
|
70
71
|
|
|
72
|
+
## MANDATORY: Update tasks.md on Completion
|
|
73
|
+
|
|
74
|
+
**After your task passes self-review, you MUST update tasks.md BEFORE reporting back.**
|
|
75
|
+
|
|
76
|
+
The orchestrator may lose context or the conversation may end before it updates. If you don't do this, your work looks like it never happened.
|
|
77
|
+
|
|
78
|
+
### How to Update
|
|
79
|
+
|
|
80
|
+
1. **Find tasks.md**: Read `.catalyst/specs/*/tasks.md` (the spec you're working on)
|
|
81
|
+
2. **Update the Progress table**: Change your task's status from `⚡ Active` to `✓ Done`
|
|
82
|
+
3. **Add commit hash** if you committed
|
|
83
|
+
4. **Update Current Session**: Note what's next based on the DAG
|
|
84
|
+
|
|
85
|
+
### Example
|
|
86
|
+
|
|
87
|
+
Before:
|
|
88
|
+
```
|
|
89
|
+
| ui-profile | ⚡ Active | shaper-1 | Pending | Working... |
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
After:
|
|
93
|
+
```
|
|
94
|
+
| ui-profile | ✓ Done | shaper-1 | ✓ Pass | Profile page complete |
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
**If you skip this step, `/primer-spec` will show the spec as not started and all your progress is invisible.**
|
|
98
|
+
|
|
71
99
|
## When Receiving Review Feedback
|
|
72
100
|
|
|
73
101
|
Follow `.claude/skills/receiving-code-review/SKILL.md`:
|
package/.claude/agents/smith.md
CHANGED
|
@@ -40,7 +40,8 @@ You implement backend functionality including APIs, services, business logic, an
|
|
|
40
40
|
4. **Implement**: Write code to pass tests (green phase)
|
|
41
41
|
5. **Refactor**: Clean up while keeping tests green
|
|
42
42
|
6. **Self-Review**: Before reporting done (see below)
|
|
43
|
-
7. **
|
|
43
|
+
7. **Update tasks.md**: Mark your task as done (see below) — MANDATORY
|
|
44
|
+
8. **Report**: Actual test output, files changed, any concerns
|
|
44
45
|
|
|
45
46
|
## Self-Review Before Reporting
|
|
46
47
|
|
|
@@ -67,6 +68,33 @@ Before reporting task completion to the orchestrator, review your own work:
|
|
|
67
68
|
|
|
68
69
|
If you find issues during self-review, fix them before reporting.
|
|
69
70
|
|
|
71
|
+
## MANDATORY: Update tasks.md on Completion
|
|
72
|
+
|
|
73
|
+
**After your task passes self-review, you MUST update tasks.md BEFORE reporting back.**
|
|
74
|
+
|
|
75
|
+
The orchestrator may lose context or the conversation may end before it updates. If you don't do this, your work looks like it never happened.
|
|
76
|
+
|
|
77
|
+
### How to Update
|
|
78
|
+
|
|
79
|
+
1. **Find tasks.md**: Read `.catalyst/specs/*/tasks.md` (the spec you're working on)
|
|
80
|
+
2. **Update the Progress table**: Change your task's status from `⚡ Active` to `✓ Done`
|
|
81
|
+
3. **Add commit hash** if you committed
|
|
82
|
+
4. **Update Current Session**: Note what's next based on the DAG
|
|
83
|
+
|
|
84
|
+
### Example
|
|
85
|
+
|
|
86
|
+
Before:
|
|
87
|
+
```
|
|
88
|
+
| api-auth | ⚡ Active | smith-1 | Pending | Working... |
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
After:
|
|
92
|
+
```
|
|
93
|
+
| api-auth | ✓ Done | smith-1 | ✓ Pass | Implemented auth endpoints |
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
**If you skip this step, `/primer-spec` will show the spec as not started and all your progress is invisible.**
|
|
97
|
+
|
|
70
98
|
## When Receiving Review Feedback
|
|
71
99
|
|
|
72
100
|
Follow `.claude/skills/receiving-code-review/SKILL.md`:
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# /build-spec-worktree
|
|
2
|
+
|
|
3
|
+
Implement a specification using **strict TDD** in an isolated git worktree.
|
|
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.
|
|
6
|
+
|
|
7
|
+
## Usage
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
/build-spec-worktree @2025-11-29-stripe-integration
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
**Invoke skill:** `build-orchestration` with `--worktree`
|
|
16
|
+
|
|
17
|
+
**Orchestrator:** Forge-Master (delegates to Forger, Enforcer, Smith, Shaper, Alchemist)
|
|
18
|
+
|
|
19
|
+
**Process skills used:** `test-driven-development`, `agent-delegation`, `verification-before-completion`, `systematic-debugging`
|
|
@@ -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` command.
|
|
4
|
+
> **Invoked by:** `/build-spec` or `/build-spec-worktree` command.
|
|
5
5
|
> **Orchestrator:** Forge-Master agent.
|
|
6
6
|
|
|
7
7
|
## Purpose
|
|
@@ -38,8 +38,14 @@ Orchestrate the full build workflow: task breakdown, test writing, foundation, c
|
|
|
38
38
|
```
|
|
39
39
|
PHASE 0: Setup
|
|
40
40
|
├── Read .catalyst/main/project-config.yaml
|
|
41
|
-
├──
|
|
42
|
-
|
|
41
|
+
├── IF --worktree flag:
|
|
42
|
+
│ ├── mkdir -p {worktree_path}
|
|
43
|
+
│ ├── git worktree add {worktree_path}/{spec-slug} -b {branch_prefix}/{spec-slug} {development_branch}
|
|
44
|
+
│ ├── cd {worktree_path}/{spec-slug}
|
|
45
|
+
│ └── Record worktree path in spec's handoff.md
|
|
46
|
+
├── ELSE (default):
|
|
47
|
+
│ ├── Checkout to development_branch (default: main)
|
|
48
|
+
│ └── Create branch: {branch_prefix}/{spec-slug}
|
|
43
49
|
|
|
44
50
|
GATE 1: RED FLAG
|
|
45
51
|
└── Commit: "test({scope}): write failing tests for {spec}"
|
|
@@ -105,9 +111,15 @@ Phase 6: Integration (Enforcer — cross-boundary tests)
|
|
|
105
111
|
|
|
106
112
|
### Phase 0: Git Setup
|
|
107
113
|
|
|
108
|
-
1. Read `project-config.yaml` for `development_branch` and `
|
|
109
|
-
2.
|
|
110
|
-
|
|
114
|
+
1. Read `project-config.yaml` for `development_branch`, `branch_prefix`, and `worktree_path`
|
|
115
|
+
2. IF `--worktree` flag (from `/build-spec-worktree`):
|
|
116
|
+
- `mkdir -p {worktree_path}` (default: `.catalyst/worktrees`)
|
|
117
|
+
- `git worktree add {worktree_path}/{spec-slug} -b {branch_prefix}/{spec-slug} {development_branch}`
|
|
118
|
+
- `cd {worktree_path}/{spec-slug}` — all subsequent work happens here
|
|
119
|
+
- Record `worktree: {worktree_path}/{spec-slug}` in the spec's `handoff.md`
|
|
120
|
+
3. ELSE (default — branch checkout):
|
|
121
|
+
- Checkout development branch and pull
|
|
122
|
+
- Create spec feature branch: `{branch_prefix}/{spec-slug}`
|
|
111
123
|
|
|
112
124
|
### Phase 1: Task Breakdown (Forger)
|
|
113
125
|
|
|
@@ -179,13 +191,20 @@ FOR EACH TASK:
|
|
|
179
191
|
3. Run test → must PASS
|
|
180
192
|
4. Refactor if needed
|
|
181
193
|
5. Run test → must still PASS
|
|
182
|
-
6. Update tasks.md Progress
|
|
194
|
+
6. Update tasks.md Progress — THE AGENT DOING THE WORK MUST DO THIS
|
|
183
195
|
|
|
184
196
|
NEVER write code without a failing test first
|
|
185
197
|
NEVER write more code than needed to pass the test
|
|
186
198
|
NEVER modify files outside your SCOPE
|
|
199
|
+
NEVER report done without updating tasks.md first
|
|
187
200
|
```
|
|
188
201
|
|
|
202
|
+
### tasks.md Update Responsibility
|
|
203
|
+
|
|
204
|
+
**Every agent (smith, shaper, alchemist, enforcer) MUST update tasks.md before reporting back.**
|
|
205
|
+
The orchestrator (forge-master) verifies and fills gaps, but agents are the primary updaters.
|
|
206
|
+
This ensures `/primer-spec` always reflects actual progress, even if the orchestrator loses context.
|
|
207
|
+
|
|
189
208
|
## Failure Modes
|
|
190
209
|
|
|
191
210
|
| Failure | Action |
|
|
@@ -68,9 +68,11 @@ Phase 5: Implement (Smith/Shaper/Alchemist)
|
|
|
68
68
|
|
|
69
69
|
### Phase 0: Verify State
|
|
70
70
|
|
|
71
|
-
1.
|
|
72
|
-
|
|
73
|
-
|
|
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`
|
|
74
76
|
|
|
75
77
|
### Phase 1: Clarify (Oracle — Optional)
|
|
76
78
|
|
|
@@ -116,7 +118,7 @@ Spawn appropriate agents (Smith/Shaper/Alchemist) based on task types. Parallel
|
|
|
116
118
|
|
|
117
119
|
| Failure | Action |
|
|
118
120
|
|---------|--------|
|
|
119
|
-
| Not on feature branch | Checkout
|
|
121
|
+
| Not on feature branch | Checkout, run `/build-spec`, or `/build-spec-worktree` first |
|
|
120
122
|
| Spec not found | Run `/catalyze-spec` first |
|
|
121
123
|
| tasks.md missing | Run `/build-spec` first |
|
|
122
124
|
| Improvement conflicts with existing | Spawn Oracle to discuss options |
|