opencode-onboard 0.1.10 → 0.1.12

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-onboard",
3
- "version": "0.1.10",
3
+ "version": "0.1.12",
4
4
  "description": "Prepare any brownfield codebase for AI agent workflows using OpenCode, OpenSpec, and ensemble orchestration.",
5
5
  "keywords": [
6
6
  "opencode",
package/src/index.js CHANGED
@@ -10,7 +10,6 @@ import { chooseSkillsProvider } from './steps/choose-skills-provider.js'
10
10
  import { cleanAiFiles } from './steps/clean-ai-files.js'
11
11
  import { copyContentStep } from './steps/copy-content.js'
12
12
  import { initOpenspec } from './steps/init-openspec.js'
13
- import { installBrowser } from './steps/install-browser.js'
14
13
 
15
14
  if (process.stdout.isTTY) console.clear()
16
15
  console.log()
@@ -8,51 +8,66 @@ const ENSEMBLE_PATCH = `6. **Implement via ensemble team**
8
8
  NEVER implement tasks directly. Always delegate to specialists via ensemble.
9
9
  Do NOT touch any source files before the team is running, not even a single edit.
10
10
 
11
- a. Create feature branch if not already on one: \`feature/{id}-{slug}\`
11
+ Steps MUST be followed in order. Do not skip any step.
12
12
 
13
- b. Clean up any stale team state, then create the team:
13
+ **Step 6a.** Create feature branch if not already on one: \`feature/{id}-{slug}\`
14
+
15
+ **Step 6b.** Clean up stale state, then create the team:
14
16
  \`\`\`
15
- team_cleanup force:true acknowledge_uncommitted:true (ignore "not in a team" errors)
17
+ team_cleanup force:true acknowledge_uncommitted:true
16
18
  team_create "<change-name>"
17
19
  \`\`\`
20
+ "not in a team" error from team_cleanup is expected, ignore it.
18
21
  Announce: "Team running. Monitor at http://localhost:4747/"
19
22
 
20
- c. Add all tasks to the shared board so progress is visible in the dashboard.
21
- Tasks take { content, priority } only, no assignee field:
23
+ **Step 6c.** Add ALL tasks to the shared board BEFORE spawning anyone.
24
+ Schema: { content: string, priority: "high"|"medium"|"low" }. No other fields.
22
25
  \`\`\`
23
26
  team_tasks_add tasks:[
24
- { content: "1.1 <task description>", priority: "high" },
25
- { content: "1.2 <task description>", priority: "high" },
26
- ...one entry per task from the tasks.md checklist...
27
+ { content: "1.1 <exact task text from tasks.md>", priority: "high" },
28
+ { content: "1.2 <exact task text>", priority: "high" },
29
+ ...every task from tasks.md, one entry each...
27
30
  ]
28
31
  \`\`\`
29
- team_tasks_add returns the task IDs, save them to pass to each agent.
30
-
31
- d. Spawn specialists one at a time (wait for each team_spawn result before calling the next,
32
- this avoids git worktree contention). Include the FULL task list,
33
- ALL context file paths, and the task IDs for their assigned tasks directly in each spawn prompt.
34
- Agents must call team_claim on each task ID before starting it, then team_tasks_complete when done:
32
+ Save the task IDs returned. You MUST pass them to agents in step 6d.
33
+ DO NOT proceed to 6d until team_tasks_add succeeds.
34
+
35
+ **Step 6d.** Spawn specialists ONE AT A TIME. Wait for each team_spawn result before calling the next.
36
+ Each team_spawn MUST include agent field (required, causes NOT NULL error if omitted).
37
+ Include: full task list, all context file paths, the task IDs for their tasks, and these instructions:
38
+ - call team_claim with the task ID before starting each task
39
+ - call team_tasks_complete with the task ID after finishing each task
40
+ - send results to lead via team_message when all done or blocked
35
41
  \`\`\`
36
- team_spawn name:back agent:back-engineer prompt:"<full task list + context file paths + architecture notes + task IDs for your tasks + call team_claim before each task, team_tasks_complete after + report back when done or blocked>"
37
- team_spawn name:front agent:front-engineer prompt:"<full task list + context file paths + architecture notes + task IDs for your tasks + call team_claim before each task, team_tasks_complete after + report back when done or blocked>"
38
- team_spawn name:infra agent:infra-engineer prompt:"<full task list + context file paths + architecture notes + task IDs for your tasks + call team_claim before each task, team_tasks_complete after + report back when done or blocked>"
42
+ team_spawn name:"back" agent:"back-engineer" prompt:"..."
43
+ (wait for result)
44
+ team_spawn name:"front" agent:"front-engineer" prompt:"..."
45
+ (wait for result)
46
+ team_spawn name:"infra" agent:"infra-engineer" prompt:"..."
47
+ (wait for result)
39
48
  \`\`\`
40
49
 
41
- e. Wait for all \`team_results\` \`team_shutdown\` + \`team_merge\`
50
+ **Step 6e.** After all spawns, tell the user what is running, then STOP and wait.
51
+ Do NOT call team_results, team_status, or team_broadcast in a loop.
52
+ Teammates will message you when done or blocked. Wait for those messages.
53
+
54
+ **Step 6f.** When teammates message back: call team_results to get full output,
55
+ then team_shutdown + team_merge for each. Fix any blockers reported.
42
56
 
43
57
  7. **Quality check**
44
58
 
59
+ Spawn quality engineer, wait for message back:
45
60
  \`\`\`
46
- team_spawn name:quality agent:quality-engineer prompt:"<task list, context files, run tests + build + lint + verify acceptance criteria, call team_claim before each task, team_tasks_complete after, report back when done>"
61
+ team_spawn name:"quality" agent:"quality-engineer" prompt:"<task list, context files, run tests + build + lint + verify acceptance criteria, call team_claim/team_tasks_complete per task, send results to lead when done>"
47
62
  \`\`\`
48
- Wait → \`team_results\` → fix blockers → \`team_shutdown\`
63
+ Wait for message → team_results → fix blockers → team_shutdown + team_merge
49
64
 
50
65
  8. **Mark tasks complete in openspec**
51
66
 
52
- After specialists finish, update the tasks file: \`- [ ]\` → \`- [x]\` for each completed task.
53
- Run \`openspec status --change "<name>" --json\` to confirm progress.
67
+ Update tasks.md: \`- [ ]\` → \`- [x]\` for each completed task.
68
+ Run \`rtk openspec status --change "<name>" --json\` to confirm.
54
69
 
55
- 9. **On completion or pause, show status**
70
+ 9. **Show status, then cleanup**
56
71
 
57
72
  Display:
58
73
  - Tasks completed this session
@@ -63,20 +78,21 @@ const ENSEMBLE_PATCH = `6. **Implement via ensemble team**
63
78
  Then run \`team_cleanup\`.
64
79
 
65
80
  **Guardrails**
66
- - NEVER implement tasks directly. Always use \`team_create\` + \`team_spawn\`, no exceptions
67
- - NEVER touch source files before \`team_create\` is called, not even one edit
68
- - ALWAYS run \`team_cleanup force:true\` before \`team_create\` to clear stale state from previous runs
69
- - ALWAYS add tasks to the board with \`team_tasks_add tasks:[{content, priority}]\` before spawning. No assignee field exists.
70
- - ALWAYS pass the task IDs returned by team_tasks_add to each agent in their spawn prompt so they can call team_claim
71
- - NEVER claim or complete tasks yourself as lead. Only subagents call team_claim and team_tasks_complete
72
- - Spawn teammates ONE AT A TIME, waiting for each team_spawn result before calling the next (avoids git worktree contention)
73
- - "Small feature", "faster to do it directly", "environment issues", "teammates not responding" are NOT valid reasons to implement directly. If teammates are stuck, use \`team_message\` to resend tasks, then wait
74
- - Always read context files before spawning (from the apply instructions output)
81
+ - NEVER skip or reorder steps 6a-6f
82
+ - NEVER implement tasks directly. Always use team_create + team_spawn, no exceptions
83
+ - NEVER touch source files before team_create is called, not even one edit
84
+ - NEVER call team_spawn without the agent field it is required and will fail without it
85
+ - NEVER call team_spawn before team_tasks_add tasks must exist before agents are spawned
86
+ - NEVER poll team_results or team_status in a loop wait for teammates to message you
87
+ - NEVER claim or complete tasks as lead only subagents call team_claim and team_tasks_complete
88
+ - ALWAYS run team_cleanup force:true before team_create to clear stale state
89
+ - ALWAYS add every task from tasks.md to the board with team_tasks_add before spawning
90
+ - ALWAYS pass the task IDs returned by team_tasks_add to each agent's spawn prompt
91
+ - ALWAYS spawn one at a time, waiting for each result before the next (avoids worktree contention)
92
+ - If teammates are stuck, use team_message to resend tasks, then wait — never implement directly
75
93
  - Mark tasks complete in openspec AFTER specialists finish, not before
76
- - If task is ambiguous, pause and ask before spawning
77
- - If implementation reveals issues, pause and suggest artifact updates
78
94
  - Pause on errors, blockers, or unclear requirements. Do not guess
79
- - Use contextFiles from CLI output, do not assume specific file names
95
+ - Use contextFiles from CLI output, do not assume specific file paths
80
96
  `
81
97
 
82
98
  // Patterns that identify the solo implementation step in openspec-generated files