opencode-onboard 0.4.2 → 0.4.3

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Quique Fdez Guerra
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,301 +1,303 @@
1
- <div align="center">
2
-
3
- <img src="https://raw.githubusercontent.com/CKGrafico/opencode-onboard/refs/heads/main/logo.png" alt="opencode-onboard" width="160" />
4
-
5
- # 🧰 opencode-onboard
6
-
7
- **One command to prepare any codebase for AI agent workflows in OpenCode.**
8
-
9
- Works with [OpenCode](https://opencode.ai), [OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble), [OpenSpec](https://github.com/fission-ai/openspec), GitHub and Azure DevOps.
10
-
11
- [![npm version](https://img.shields.io/npm/v/opencode-onboard?style=flat-square&color=black)](https://www.npmjs.com/package/opencode-onboard)
12
- [![npm downloads](https://img.shields.io/npm/dm/opencode-onboard?style=flat-square&color=black)](https://www.npmjs.com/package/opencode-onboard)
13
- [![license](https://img.shields.io/npm/l/opencode-onboard?style=flat-square&color=black)](./LICENSE)
14
- [![node](https://img.shields.io/node/v/opencode-onboard?style=flat-square&color=black)](https://nodejs.org)
15
-
16
- </div>
17
-
18
- ## What is this?
19
-
20
- Most codebases have no `AGENTS.md`, no architecture docs agents can read, and no defined workflow for picking up tasks. Agents end up improvising, and that produces inconsistent, brittle results.
21
-
22
- **opencode-onboard** fixes that in a single interactive run. It installs a universal and agnostic agent team,but let you choose your own skills, preconfigured your AI models, and initd OpenCode with Openspec and Ensemble.
23
-
24
- <div align="center">
25
- <img src="https://raw.githubusercontent.com/CKGrafico/opencode-onboard/refs/heads/main/demo.gif" alt="opencode-onboard demo" width="700" />
26
- </div>
27
-
28
- ## Quick start
29
-
30
- ```bash
31
- npx opencode-onboard@latest
32
- ```
33
-
34
- Requires **Node.js 18+**.
35
-
36
- ### Run specific steps
37
-
38
- You can run individual setup/maintenance steps without running the full wizard:
39
-
40
- ```bash
41
- # Run one step directly
42
- npx opencode-onboard clean
43
- npx opencode-onboard platform
44
- npx opencode-onboard copy
45
- npx opencode-onboard openspec
46
- npx opencode-onboard models
47
- npx opencode-onboard optimization
48
- npx opencode-onboard browser
49
- npx opencode-onboard metadata
50
-
51
- # Show CLI help and all commands
52
- npx opencode-onboard --help
53
- npx opencode-onboard -h
54
- ```
55
-
56
- When available, step commands reuse context from `.opencode/opencode-onboard.json`.
57
-
58
- Typical flow for reruns:
59
- - Run `clean` if you want to reset old AI files
60
- - Run `copy` if templates/skills changed in a new onboard release
61
- - Run `optimization` if you want to reconfigure RTK/quota/caveman + `ob-global`
62
- - Run `metadata` last to refresh `.opencode/opencode-onboard.json`
63
-
64
- ---
65
-
66
- ## How it works
67
-
68
- The CLI runs a 10-step onboarding wizard. It keeps the current step visible, plus the last two completed steps, so progress is always clear.
69
-
70
- | Step | What happens |
71
- |------|-------------|
72
- | **1. Source scope** | Choose current repo or sibling source roots for code analysis |
73
- | **2. Clean AI files** | Detects existing `AGENTS.md`, `.cursorrules`, `CLAUDE.md`, `.agents/` etc. and removes them, preserves your `.agents/skills/` |
74
- | **3. Choose platform** | GitHub or Azure DevOps |
75
- | **4. Check platform CLI** | Verifies `gh` (GitHub) or `az` + `azure-devops` (Azure DevOps) |
76
- | **5. Copy scaffolding** | Copies agents + built-in skills + bootstrap docs, writes source-roots metadata, applies AGENTS bootstrap patching, copies `skills-lock.json`, then runs `npx skills` |
77
- | **6. Init OpenSpec** | Runs `npx @fission-ai/openspec init` silently for structured change management |
78
- | **7. Choose models** | Fetches live model list from [models.dev](https://models.dev), lets you pick plan / build / fast models with cost indicators and canonical pricing |
79
- | **8. Token optimization tools** | Optional (recommended). One checklist step for RTK check, opencode-quota setup, caveman install, and dynamic `ob-global` token-optimization rule injection |
80
- | **9. Install browser plugin** | Installs `@different-ai/opencode-browser` globally for agent browser automation |
81
- | **10. Write onboarding metadata** | Writes `.opencode/opencode-onboard.json` with selected setup details |
82
-
83
- When it finishes, open OpenCode in your project and type:
84
-
85
- ```
86
- init
87
- ```
88
-
89
- OpenCode generates `ARCHITECTURE.md` and `DESIGN.md` from your actual codebase, then activates the full agent team.
90
-
91
- ---
92
-
93
- ## Commands
94
-
95
- Custom slash commands are installed into `.opencode/commands/` and are available directly in OpenCode.
96
-
97
- | Command | Description |
98
- |---------|-------------|
99
- | `/init` | Initialize the project: generate `ARCHITECTURE.md`, `DESIGN.md`, archive history, activate agent team |
100
- | `/plan <url>` | Parse a user story URL and produce a plan — proposal, specs, and tasks. Stops before implementation. |
101
- | `/main <task>` | Quick direct implementation no OpenSpec, no ensemble, no PRs. Just do it. |
102
-
103
- ---
104
-
105
- ## Agents and Skills
106
-
107
- opencode-onboard draws a hard line between two concepts:
108
-
109
- ### Agents, universal behaviors
110
-
111
- Agents define *how to work*. They are universal personas (same behavior across projects and stacks).
112
-
113
- Current baseline uses a generic execution model:
114
-
115
- ```
116
- devops-manager lead/orchestrator, planning, PR lifecycle
117
- basic-engineer implementation worker, ability-driven
118
- ```
119
-
120
- `basic-engineer` behavior is composed by abilities, not hardcoded role silos.
121
-
122
- ### Skills, platform knowledge
123
-
124
- Skills define *what to know*. They provide project rules, platform behavior, and task-specific execution guidance. Agents auto-detect/load relevant skills; **you do not manually choose skills per prompt**.
125
-
126
- Current loading model:
127
- - `ob-global` is baseline and should be loaded first
128
- - `ob-default` is fallback when nothing else matches
129
- - `ob-generic-guardrails` is a minimal base users can extend with custom guardrail skills
130
-
131
- Default `basic-engineer` abilities:
132
-
133
- ```
134
- ## Abilities
135
- - Guardrails: @ob-generic-guardrails, @ob-default
136
- - Development: @ob-default
137
- - Testing: @ob-default
138
- - Infrastructure: @ob-default
139
- ```
140
-
141
- Users are expected to create additional skills and map them into abilities over time.
142
-
143
- Built-in skills (`ob-` prefix) shipped with opencode-onboard:
144
-
145
- | Skill | Purpose |
146
- |-------|---------|
147
- | `ob-global` | Baseline skill loaded first: context rules, source-roots scope, git/secrets guardrails, token-optimization rules |
148
- | `ob-default` | Fallback, when no other skill matches. Still loads ob-global first |
149
- | `ob-generic-guardrails` | Foundation for user guardrails skills |
150
- | `ob-userstory-gh` | Parse a GitHub Issue URL into a structured work item |
151
- | `ob-userstory-az` | Parse an Azure DevOps work item URL |
152
- | `browser-automation` | Browser control via `@different-ai/opencode-browser` |
153
-
154
- Skills live in `.agents/skills/`. Any `SKILL.md` file in a subdirectory is automatically discoverable, write your own and agents will pick them up.
155
-
156
- ### Models, plan / build / fast
157
-
158
- During onboarding you pick three models:
159
-
160
- | Role | Used by | Pick |
161
- |------|---------|------|
162
- | **plan** | Main OpenCode session | Something capable with strong reasoning |
163
- | **build** | All builder agents | Something capable for implementation |
164
- | **fast** | `devops-manager` | Something fast and cheap |
165
-
166
- Models are fetched live from [models.dev](https://models.dev) (3000+ models, cached weekly). Cost tiers `[$]` `[$$]` `[$$$]` always reflect the canonical provider price, so `github-copilot/claude-opus-4.7` shows `[$$]` not `[$]`.
167
-
168
- ---
169
-
170
- ## The pipeline
171
-
172
- When you give the lead agent a work item URL, execution follows this pipeline:
173
-
174
- ```
175
- devops-manager (load ob-global first)
176
-
177
- parse work item via userstory skill
178
-
179
- openspec-propose
180
- proposal + specs + tasks
181
-
182
- [confirm with user]
183
-
184
- basic-engineer + custom-engineer-* (parallel)
185
- claim tasks → load abilities → implement
186
-
187
- verify (tests/build/lint as needed)
188
-
189
- devops-manager (ship mode, if configured)
190
- commit → push → PR → feedback loop
191
- ```
192
-
193
- 1. Load `ob-global` baseline rules
194
- 2. Load platform userstory skill (`ob-userstory-gh` or `ob-userstory-az`)
195
- 3. Run `/opsx-propose` to produce `proposal.md`, specs, and `tasks.md`
196
- 4. Confirm with user before implementation
197
- 5. Run `/opsx-apply` to orchestrate implementation workers
198
- 6. Spawn one or more engineers in parallel (`basic-engineer` and/or custom engineers)
199
- 7. Each engineer claims tasks, loads relevant abilities, and executes
200
- 8. Verify with tests/build/lint according to task scope
201
- 9. Ship/update PR via devops-manager flow
202
-
203
- Each agent runs in its own isolated git worktree via [OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble), with a live dashboard at `http://localhost:4747`.
204
-
205
- ---
206
-
207
- ## What gets installed
208
-
209
- ```
210
- your-project/
211
- ├── AGENTS.md ← bootstrap mode, replaced after first "init"
212
- ├── ARCHITECTURE.md ← prompt for agents to fill in from your codebase
213
- ├── DESIGN.md ← prompt for agents to fill in from your codebase
214
- ├── .opencode/
215
- ├── opencode.json default model + plugin config
216
- ├── ensemble.json ← model assignments for plan/build/fast roles
217
- └── opencode-onboard.json onboarding metadata snapshot
218
- └── .agents/
219
- ├── agents/
220
- │ ├── devops-manager.md
221
- │ └── basic-engineer.md
222
- └── skills/
223
- ├── ob-global/ ← baseline skill, load FIRST
224
- ├── ob-default/ ← fallback skill
225
- ├── ob-generic-guardrails/ foundation for user guardrails
226
- ├── ob-userstory-gh/ or -az, depending on platform
227
- ├── ob-userstory-az/
228
- └── browser-automation/
229
- ```
230
-
231
- `ob-global` is the baseline skill template. During onboarding, source-roots and token-optimization sections are injected into that template.
232
-
233
- ---
234
-
235
- ## The bootstrap sequence
236
-
237
- The first time you type `init` in OpenCode after onboarding:
238
-
239
- 1. Bootstrap-mode `AGENTS.md` triggers the initialization workflow
240
- 2. OpenCode archives existing project context into OpenSpec (`project-history`)
241
- 3. OpenCode generates real `DESIGN.md` and `ARCHITECTURE.md` from your codebase
242
- 4. Bootstrap `AGENTS.md` is replaced with production guidance
243
- 5. Team workflows become fully active for normal implementation tasks
244
-
245
- After this, every agent has accurate, persistent context about your project, no manual documentation required.
246
-
247
- ---
248
-
249
- ## Prerequisites
250
-
251
- | Requirement | Notes |
252
- |-------------|-------|
253
- | **Node.js 18+** | Required |
254
- | **[OpenCode](https://opencode.ai)** | The agent runtime |
255
- | **[OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble)** | Multi-agent parallel execution |
256
- | **[rtk](https://github.com/rtk-ai/rtk#pre-built-binaries)** | Recommended for safer agent CLI command execution |
257
- | **[gh CLI](https://cli.github.com)** | GitHub platform, must be authenticated |
258
- | **[az CLI](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli)** + azure-devops extension | Azure DevOps platform |
259
-
260
- ---
261
-
262
- ## Development
263
-
264
- Wizard choices and defaults live in `src/presets/` where possible:
265
-
266
- - `source.json` controls source-scope prompt options
267
- - `platforms.json` controls platform labels and CLI checks
268
- - `clean.json` controls AI file detection and preservation
269
- - `models.json` controls model role prompts and agent assignments
270
- - `optimization.json` controls RTK/quota/caveman checklist defaults
271
- - `quota.json` controls opencode-quota defaults
272
- - `browser.json` controls opencode-browser installer automation
273
-
274
- ```bash
275
- git clone https://github.com/ckgrafico/opencode-onboard.git
276
- cd opencode-onboard
277
- pnpm install
278
-
279
- # Run the CLI locally
280
- node src/index.js
281
-
282
- # Run tests
283
- pnpm test
284
-
285
- # Run linting
286
- pnpm lint
287
-
288
- # Fix auto-fixable lint issues
289
- pnpm lint:fix
290
-
291
- # Watch mode
292
- pnpm test:watch
293
- ```
294
-
295
- Tests are written with [Vitest](https://vitest.dev). Linting uses ESLint flat config with Node ESM defaults and stricter correctness rules.
296
-
297
- ---
298
-
299
- ## License
300
-
301
- MIT © [ckgrafico](https://github.com/ckgrafico)
1
+ <div align="center">
2
+
3
+ <img src="https://raw.githubusercontent.com/CKGrafico/opencode-onboard/refs/heads/main/logo.png" alt="opencode-onboard" width="160" />
4
+
5
+ # 🧰 opencode-onboard
6
+
7
+ **One command to prepare any codebase for AI agent workflows in OpenCode.**
8
+
9
+ Works with [OpenCode](https://opencode.ai), [OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble), [OpenSpec](https://github.com/fission-ai/openspec), GitHub and Azure DevOps.
10
+
11
+ [![npm version](https://img.shields.io/npm/v/opencode-onboard?style=flat-square&color=black)](https://www.npmjs.com/package/opencode-onboard)
12
+ [![npm downloads](https://img.shields.io/npm/dm/opencode-onboard?style=flat-square&color=black)](https://www.npmjs.com/package/opencode-onboard)
13
+ [![license](https://img.shields.io/npm/l/opencode-onboard?style=flat-square&color=black)](./LICENSE)
14
+ [![node](https://img.shields.io/node/v/opencode-onboard?style=flat-square&color=black)](https://nodejs.org)
15
+
16
+ </div>
17
+
18
+ ## What is this?
19
+
20
+ Most codebases have no `AGENTS.md`, no architecture docs agents can read, and no defined workflow for picking up tasks. Agents end up improvising, and that produces inconsistent, brittle results.
21
+
22
+ **opencode-onboard** fixes that in a single interactive run. It installs a universal and agnostic agent team,but let you choose your own skills, preconfigured your AI models, and initd OpenCode with Openspec and Ensemble.
23
+
24
+ <div align="center">
25
+ <img src="https://raw.githubusercontent.com/CKGrafico/opencode-onboard/refs/heads/main/demo.gif" alt="opencode-onboard demo" width="700" />
26
+ </div>
27
+
28
+ ## Quick start
29
+
30
+ ```bash
31
+ npx opencode-onboard@latest
32
+ ```
33
+
34
+ Requires **Node.js 18+**.
35
+
36
+ ### Run specific steps
37
+
38
+ You can run individual setup/maintenance steps without running the full wizard:
39
+
40
+ ```bash
41
+ # Run one step directly
42
+ npx opencode-onboard clean
43
+ npx opencode-onboard platform
44
+ npx opencode-onboard copy
45
+ npx opencode-onboard openspec
46
+ npx opencode-onboard models
47
+ npx opencode-onboard optimization
48
+ npx opencode-onboard browser
49
+ npx opencode-onboard metadata
50
+ npx opencode-onboard join
51
+
52
+ # Show CLI help and all commands
53
+ npx opencode-onboard --help
54
+ npx opencode-onboard -h
55
+ ```
56
+
57
+ When available, step commands reuse context from `.opencode/opencode-onboard.json`.
58
+
59
+ Typical flow for reruns:
60
+ - Run `clean` if you want to reset old AI files
61
+ - Run `copy` if templates/skills changed in a new onboard release
62
+ - Run `optimization` if you want to reconfigure RTK/quota/caveman + `ob-global`
63
+ - Run `metadata` last to refresh `.opencode/opencode-onboard.json`
64
+ - Run `join` if you're a new member of an existing onboarded project and want to sync the latest onboarding metadata
65
+
66
+ ---
67
+
68
+ ## How it works
69
+
70
+ The CLI runs a 10-step onboarding wizard. It keeps the current step visible, plus the last two completed steps, so progress is always clear.
71
+
72
+ | Step | What happens |
73
+ |------|-------------|
74
+ | **1. Source scope** | Choose current repo or sibling source roots for code analysis |
75
+ | **2. Clean AI files** | Detects existing `AGENTS.md`, `.cursorrules`, `CLAUDE.md`, `.agents/` etc. and removes them, preserves your `.agents/skills/` |
76
+ | **3. Choose platform** | GitHub or Azure DevOps |
77
+ | **4. Check platform CLI** | Verifies `gh` (GitHub) or `az` + `azure-devops` (Azure DevOps) |
78
+ | **5. Copy scaffolding** | Copies agents + built-in skills + bootstrap docs, writes source-roots metadata, applies AGENTS bootstrap patching, copies `skills-lock.json`, then runs `npx skills` |
79
+ | **6. Init OpenSpec** | Runs `npx @fission-ai/openspec init` silently for structured change management |
80
+ | **7. Choose models** | Fetches live model list from [models.dev](https://models.dev), lets you pick plan / build / fast models with cost indicators and canonical pricing |
81
+ | **8. Token optimization tools** | Optional (recommended). One checklist step for RTK check, opencode-quota setup, caveman install, and dynamic `ob-global` token-optimization rule injection |
82
+ | **9. Install browser plugin** | Installs `@different-ai/opencode-browser` globally for agent browser automation |
83
+ | **10. Write onboarding metadata** | Writes `.opencode/opencode-onboard.json` with selected setup details |
84
+
85
+ When it finishes, open OpenCode in your project and type:
86
+
87
+ ```
88
+ init
89
+ ```
90
+
91
+ OpenCode generates `ARCHITECTURE.md` and `DESIGN.md` from your actual codebase, then activates the full agent team.
92
+
93
+ ---
94
+
95
+ ## Commands
96
+
97
+ Custom slash commands are installed into `.opencode/commands/` and are available directly in OpenCode.
98
+
99
+ | Command | Description |
100
+ |---------|-------------|
101
+ | `/init` | Initialize the project: generate `ARCHITECTURE.md`, `DESIGN.md`, archive history, activate agent team |
102
+ | `/plan <url>` | Parse a user story URL and produce a plan, proposal, specs, and tasks. Stops before implementation. |
103
+ | `/main <task>` | Quick direct implementation, no OpenSpec, no ensemble, no PRs. Just do it. |
104
+
105
+ ---
106
+
107
+ ## Agents and Skills
108
+
109
+ opencode-onboard draws a hard line between two concepts:
110
+
111
+ ### Agents, universal behaviors
112
+
113
+ Agents define *how to work*. They are universal personas (same behavior across projects and stacks).
114
+
115
+ Current baseline uses a generic execution model:
116
+
117
+ ```
118
+ devops-manager lead/orchestrator, planning, PR lifecycle
119
+ basic-engineer implementation worker, ability-driven
120
+ ```
121
+
122
+ `basic-engineer` behavior is composed by abilities, not hardcoded role silos.
123
+
124
+ ### Skills, platform knowledge
125
+
126
+ Skills define *what to know*. They provide project rules, platform behavior, and task-specific execution guidance. Agents auto-detect/load relevant skills; **you do not manually choose skills per prompt**.
127
+
128
+ Current loading model:
129
+ - `ob-global` is baseline and should be loaded first
130
+ - `ob-default` is fallback when nothing else matches
131
+ - `ob-generic-guardrails` is a minimal base users can extend with custom guardrail skills
132
+
133
+ Default `basic-engineer` abilities:
134
+
135
+ ```
136
+ ## Abilities
137
+ - Guardrails: @ob-generic-guardrails, @ob-default
138
+ - Development: @ob-default
139
+ - Testing: @ob-default
140
+ - Infrastructure: @ob-default
141
+ ```
142
+
143
+ Users are expected to create additional skills and map them into abilities over time.
144
+
145
+ Built-in skills (`ob-` prefix) shipped with opencode-onboard:
146
+
147
+ | Skill | Purpose |
148
+ |-------|---------|
149
+ | `ob-global` | Baseline skill loaded first: context rules, source-roots scope, git/secrets guardrails, token-optimization rules |
150
+ | `ob-default` | Fallback, when no other skill matches. Still loads ob-global first |
151
+ | `ob-generic-guardrails` | Foundation for user guardrails skills |
152
+ | `ob-userstory-gh` | Parse a GitHub Issue URL into a structured work item |
153
+ | `ob-userstory-az` | Parse an Azure DevOps work item URL |
154
+ | `browser-automation` | Browser control via `@different-ai/opencode-browser` |
155
+
156
+ Skills live in `.agents/skills/`. Any `SKILL.md` file in a subdirectory is automatically discoverable, write your own and agents will pick them up.
157
+
158
+ ### Models, plan / build / fast
159
+
160
+ During onboarding you pick three models:
161
+
162
+ | Role | Used by | Pick |
163
+ |------|---------|------|
164
+ | **plan** | Main OpenCode session | Something capable with strong reasoning |
165
+ | **build** | All builder agents | Something capable for implementation |
166
+ | **fast** | `devops-manager` | Something fast and cheap |
167
+
168
+ Models are fetched live from [models.dev](https://models.dev) (3000+ models, cached weekly). Cost tiers `[$]` `[$$]` `[$$$]` always reflect the canonical provider price, so `github-copilot/claude-opus-4.7` shows `[$$]` not `[$]`.
169
+
170
+ ---
171
+
172
+ ## The pipeline
173
+
174
+ When you give the lead agent a work item URL, execution follows this pipeline:
175
+
176
+ ```
177
+ devops-manager (load ob-global first)
178
+
179
+ parse work item via userstory skill
180
+
181
+ openspec-propose
182
+ proposal + specs + tasks
183
+
184
+ [confirm with user]
185
+
186
+ basic-engineer + custom-engineer-* (parallel)
187
+ claim tasks → load abilities → implement
188
+
189
+ verify (tests/build/lint as needed)
190
+
191
+ devops-manager (ship mode, if configured)
192
+ commit → push → PR → feedback loop
193
+ ```
194
+
195
+ 1. Load `ob-global` baseline rules
196
+ 2. Load platform userstory skill (`ob-userstory-gh` or `ob-userstory-az`)
197
+ 3. Run `/opsx-propose` to produce `proposal.md`, specs, and `tasks.md`
198
+ 4. Confirm with user before implementation
199
+ 5. Run `/opsx-apply` to orchestrate implementation workers
200
+ 6. Spawn one or more engineers in parallel (`basic-engineer` and/or custom engineers)
201
+ 7. Each engineer claims tasks, loads relevant abilities, and executes
202
+ 8. Verify with tests/build/lint according to task scope
203
+ 9. Ship/update PR via devops-manager flow
204
+
205
+ Each agent runs in its own isolated git worktree via [OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble), with a live dashboard at `http://localhost:4747`.
206
+
207
+ ---
208
+
209
+ ## What gets installed
210
+
211
+ ```
212
+ your-project/
213
+ ├── AGENTS.md ← bootstrap mode, replaced after first "init"
214
+ ├── ARCHITECTURE.md ← prompt for agents to fill in from your codebase
215
+ ├── DESIGN.md prompt for agents to fill in from your codebase
216
+ ├── .opencode/
217
+ ├── opencode.json default model + plugin config
218
+ │ ├── ensemble.json ← model assignments for plan/build/fast roles
219
+ │ └── opencode-onboard.json ← onboarding metadata snapshot
220
+ └── .agents/
221
+ ├── agents/
222
+ │ ├── devops-manager.md
223
+ │ └── basic-engineer.md
224
+ └── skills/
225
+ ├── ob-global/ baseline skill, load FIRST
226
+ ├── ob-default/ fallback skill
227
+ ├── ob-generic-guardrails/ ← foundation for user guardrails
228
+ ├── ob-userstory-gh/ ← or -az, depending on platform
229
+ ├── ob-userstory-az/
230
+ └── browser-automation/
231
+ ```
232
+
233
+ `ob-global` is the baseline skill template. During onboarding, source-roots and token-optimization sections are injected into that template.
234
+
235
+ ---
236
+
237
+ ## The bootstrap sequence
238
+
239
+ The first time you type `init` in OpenCode after onboarding:
240
+
241
+ 1. Bootstrap-mode `AGENTS.md` triggers the initialization workflow
242
+ 2. OpenCode archives existing project context into OpenSpec (`project-history`)
243
+ 3. OpenCode generates real `DESIGN.md` and `ARCHITECTURE.md` from your codebase
244
+ 4. Bootstrap `AGENTS.md` is replaced with production guidance
245
+ 5. Team workflows become fully active for normal implementation tasks
246
+
247
+ After this, every agent has accurate, persistent context about your project, no manual documentation required.
248
+
249
+ ---
250
+
251
+ ## Prerequisites
252
+
253
+ | Requirement | Notes |
254
+ |-------------|-------|
255
+ | **Node.js 18+** | Required |
256
+ | **[OpenCode](https://opencode.ai)** | The agent runtime |
257
+ | **[OpenCode Ensemble](https://github.com/hueyexe/opencode-ensemble)** | Multi-agent parallel execution |
258
+ | **[rtk](https://github.com/rtk-ai/rtk#pre-built-binaries)** | Recommended for safer agent CLI command execution |
259
+ | **[gh CLI](https://cli.github.com)** | GitHub platform, must be authenticated |
260
+ | **[az CLI](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli)** + azure-devops extension | Azure DevOps platform |
261
+
262
+ ---
263
+
264
+ ## Development
265
+
266
+ Wizard choices and defaults live in `src/presets/` where possible:
267
+
268
+ - `source.json` controls source-scope prompt options
269
+ - `platforms.json` controls platform labels and CLI checks
270
+ - `clean.json` controls AI file detection and preservation
271
+ - `models.json` controls model role prompts and agent assignments
272
+ - `optimization.json` controls RTK/quota/caveman checklist defaults
273
+ - `quota.json` controls opencode-quota defaults
274
+ - `browser.json` controls opencode-browser installer automation
275
+
276
+ ```bash
277
+ git clone https://github.com/ckgrafico/opencode-onboard.git
278
+ cd opencode-onboard
279
+ pnpm install
280
+
281
+ # Run the CLI locally
282
+ node src/index.js
283
+
284
+ # Run tests
285
+ pnpm test
286
+
287
+ # Run linting
288
+ pnpm lint
289
+
290
+ # Fix auto-fixable lint issues
291
+ pnpm lint:fix
292
+
293
+ # Watch mode
294
+ pnpm test:watch
295
+ ```
296
+
297
+ Tests are written with [Vitest](https://vitest.dev). Linting uses ESLint flat config with Node ESM defaults and stricter correctness rules.
298
+
299
+ ---
300
+
301
+ ## License
302
+
303
+ MIT © [ckgrafico](https://github.com/ckgrafico)