opencastle 0.23.1 → 0.23.2
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/dist/cli/convoy/engine.d.ts +1 -0
- package/dist/cli/convoy/engine.d.ts.map +1 -1
- package/dist/cli/convoy/engine.js +72 -22
- package/dist/cli/convoy/engine.js.map +1 -1
- package/dist/cli/convoy/engine.test.js +205 -0
- package/dist/cli/convoy/engine.test.js.map +1 -1
- package/dist/cli/dashboard.d.ts.map +1 -1
- package/dist/cli/dashboard.js +5 -4
- package/dist/cli/dashboard.js.map +1 -1
- package/dist/cli/run/schema.d.ts.map +1 -1
- package/dist/cli/run/schema.js +8 -0
- package/dist/cli/run/schema.js.map +1 -1
- package/dist/cli/run/schema.test.js +41 -0
- package/dist/cli/run/schema.test.js.map +1 -1
- package/dist/cli/run.d.ts.map +1 -1
- package/dist/cli/run.js +16 -4
- package/dist/cli/run.js.map +1 -1
- package/dist/cli/types.d.ts +2 -0
- package/dist/cli/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/cli/convoy/engine.test.ts +240 -0
- package/src/cli/convoy/engine.ts +80 -23
- package/src/cli/dashboard.ts +6 -5
- package/src/cli/run/schema.test.ts +51 -0
- package/src/cli/run/schema.ts +10 -0
- package/src/cli/run.ts +18 -6
- package/src/cli/types.ts +2 -0
- package/src/dashboard/node_modules/.vite/deps/_metadata.json +6 -6
- package/src/orchestrator/agents/team-lead.agent.md +6 -6
- package/src/orchestrator/prompts/bug-fix.prompt.md +6 -2
- package/src/orchestrator/prompts/generate-convoy.prompt.md +3 -3
- package/src/orchestrator/prompts/implement-feature.prompt.md +8 -19
|
@@ -145,14 +145,14 @@ Before EVERY delegation verify: (1) Tracker issue exists, (2) File partition is
|
|
|
145
145
|
|
|
146
146
|
## Convoy Integration
|
|
147
147
|
|
|
148
|
-
The convoy engine is the
|
|
148
|
+
The convoy engine is the **mandatory** execution mechanism for all project-related work — features, bug fixes, and refactors. This ensures consistent observability, crash recovery, and progress visibility.
|
|
149
149
|
|
|
150
150
|
### When to use convoy vs. direct delegation
|
|
151
151
|
|
|
152
|
-
|
|
|
153
|
-
|
|
154
|
-
|
|
|
155
|
-
|
|
|
152
|
+
| Work type | Approach |
|
|
153
|
+
|-----------|----------|
|
|
154
|
+
| Features, bug fixes, refactors (any subtask count) | **Convoy execution** — always generate a `.convoy.yml` spec, even for 1-task fixes |
|
|
155
|
+
| Utility prompts (`bootstrap-customizations`, `create-skill`, `generate-convoy`, `brainstorm`, `quick-refinement`) | **Direct** — these are meta/tooling operations, not project code changes |
|
|
156
156
|
|
|
157
157
|
### How to generate a convoy spec
|
|
158
158
|
|
|
@@ -164,7 +164,7 @@ The convoy engine is the preferred execution mechanism for multi-task work. Use
|
|
|
164
164
|
|
|
165
165
|
Tell the user to run:
|
|
166
166
|
```
|
|
167
|
-
npx opencastle run -f
|
|
167
|
+
npx opencastle run -f .opencastle/convoys/<name>.convoy.yml
|
|
168
168
|
```
|
|
169
169
|
This gives the user control over when execution starts (preferred — supports overnight/unattended runs and manual review of the spec before execution).
|
|
170
170
|
|
|
@@ -83,9 +83,13 @@ Find WHY the bug happens, not just WHERE:
|
|
|
83
83
|
|
|
84
84
|
### 4. Implement the Fix
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
All bug fixes are executed via the convoy engine — even single-task fixes — to ensure observability and crash recovery.
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
1. **Generate a convoy spec** — use the `generate-convoy` prompt with the root cause analysis, fix approach, and file paths as context.
|
|
89
|
+
2. **Hand the spec to the user** — tell them to run: `npx opencastle run -f .opencastle/convoys/<name>.convoy.yml`
|
|
90
|
+
3. **After convoy completes** — proceed to Step 5 (validation).
|
|
91
|
+
|
|
92
|
+
#### Convoy Task Prompt Must Include
|
|
89
93
|
|
|
90
94
|
- **Tracker issue ID and title** — e.g., `TAS-XX — [Bug] Description`
|
|
91
95
|
- **Root cause** — What's wrong and why
|
|
@@ -7,7 +7,7 @@ agent: 'Team Lead (OpenCastle)'
|
|
|
7
7
|
|
|
8
8
|
# Generate Convoy Spec
|
|
9
9
|
|
|
10
|
-
You are the Team Lead. The user wants to run `opencastle run` to execute a batch of tasks autonomously via the convoy engine. Your job is to produce a valid `.convoy.yml` file they can feed to the CLI. Derive a short, descriptive, kebab-case filename from the user's goal (2–4 words max) and use it as the filename — for example `auth-refactor.convoy.yml` or `add-search.convoy.yml`. Always use the `.convoy.yml` extension.
|
|
10
|
+
You are the Team Lead. The user wants to run `opencastle run` to execute a batch of tasks autonomously via the convoy engine. Your job is to produce a valid `.convoy.yml` file they can feed to the CLI. Derive a short, descriptive, kebab-case filename from the user's goal (2–4 words max) and use it as the filename — for example `auth-refactor.convoy.yml` or `add-search.convoy.yml`. Always use the `.convoy.yml` extension. Store all generated convoy specs in the `.opencastle/convoys/` directory (create it if it doesn't exist).
|
|
11
11
|
|
|
12
12
|
## User Goal
|
|
13
13
|
|
|
@@ -137,7 +137,7 @@ Before presenting the YAML, mentally verify:
|
|
|
137
137
|
Return the final YAML inside a fenced code block with a filename annotation:
|
|
138
138
|
|
|
139
139
|
````yaml
|
|
140
|
-
#
|
|
140
|
+
# .opencastle/convoys/<feature-name>.convoy.yml
|
|
141
141
|
name: <run name>
|
|
142
142
|
version: 1
|
|
143
143
|
concurrency: <n>
|
|
@@ -172,6 +172,6 @@ gates:
|
|
|
172
172
|
Also provide:
|
|
173
173
|
1. A **DAG summary** showing the phase structure so the user can verify execution order.
|
|
174
174
|
2. An **estimated total duration** (sum of timeouts on the critical path).
|
|
175
|
-
3. A `--dry-run` command they can use to validate: `npx opencastle run --file
|
|
175
|
+
3. A `--dry-run` command they can use to validate: `npx opencastle run --file .opencastle/convoys/<feature-name>.convoy.yml --dry-run`
|
|
176
176
|
|
|
177
177
|
|
|
@@ -47,31 +47,20 @@ Every subtask must be tracked. **No issue = no implementation.** This step produ
|
|
|
47
47
|
5. **Link to roadmap** — Reference the roadmap section in the issue description so context is never lost
|
|
48
48
|
6. **Verify issues exist** — List all created issue IDs. If count is 0, do NOT proceed to Step 2.5
|
|
49
49
|
|
|
50
|
-
### 2.5
|
|
50
|
+
### 2.5 Generate Convoy Spec (BLOCKING — decides how Step 3 proceeds)
|
|
51
51
|
|
|
52
|
-
|
|
52
|
+
All project-related work is executed via the convoy engine — regardless of subtask count. This ensures consistent observability, crash recovery, and live progress.
|
|
53
53
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
| 3+ subtasks | **Convoy execution** — generate a `.convoy.yml` spec using the `generate-convoy` prompt, then hand it to the user |
|
|
58
|
-
|
|
59
|
-
#### Direct delegation (1–2 subtasks)
|
|
60
|
-
|
|
61
|
-
Proceed with the normal Step 3 delegation workflow. Sub-agents handle each task inline.
|
|
62
|
-
|
|
63
|
-
#### Convoy execution (3+ subtasks)
|
|
64
|
-
|
|
65
|
-
1. **Generate the spec** — use the `generate-convoy` prompt with the decomposed task list as context. The spec IS the implementation plan — no manual per-task delegation is needed.
|
|
66
|
-
2. **Hand the spec to the user** — tell them to run: `npx opencastle run -f <name>.convoy.yml`
|
|
67
|
-
3. **The convoy engine handles** isolated git worktrees, parallel execution, merge queue ordering, and crash recovery automatically.
|
|
54
|
+
1. **Generate the spec** — use the `generate-convoy` prompt with the decomposed task list as context. The spec IS the implementation plan — no manual per-task delegation is needed. Even single-task fixes go through convoy for observability.
|
|
55
|
+
2. **Hand the spec to the user** — tell them to run: `npx opencastle run -f .opencastle/convoys/<name>.convoy.yml`
|
|
56
|
+
3. **The convoy engine handles** isolated git worktrees, parallel execution, merge queue ordering, crash recovery, and structured logging automatically.
|
|
68
57
|
4. **After convoy completes** — proceed to Step 4 (validation) and Step 5 (delivery/PR). The convoy engine will have created its own commits on the configured branch.
|
|
69
58
|
|
|
70
|
-
> **Why convoy
|
|
59
|
+
> **Why always convoy?** Convoy execution is the only path that guarantees observability logging, crash recovery, gate validation, and live progress. Direct sub-agent delegation produces no structured logs and cannot be resumed if interrupted.
|
|
71
60
|
|
|
72
61
|
### 3. Implementation Rules
|
|
73
62
|
|
|
74
|
-
> **
|
|
63
|
+
> **Convoy execution:** The convoy spec file IS the implementation plan — skip the manual delegation workflow below and jump to Step 4 after the user runs the convoy. The convoy engine delegates tasks internally using the agents and prompts defined in the spec.
|
|
75
64
|
|
|
76
65
|
#### Issue Traceability
|
|
77
66
|
|
|
@@ -117,7 +106,7 @@ Every subtask must pass ALL gates before being marked Done:
|
|
|
117
106
|
|
|
118
107
|
Follow the **Delivery Outcome** defined in the **git-workflow** skill — commit, push, open PR (not merged), and link to the tracker.
|
|
119
108
|
|
|
120
|
-
>
|
|
109
|
+
> The convoy engine creates commits on the configured `branch` directly. After validation passes, open the PR from that branch. No additional commits from the Team Lead are needed unless gates failed and required manual fixes.
|
|
121
110
|
|
|
122
111
|
### 6. Documentation & Traceability
|
|
123
112
|
|