vibe-coding-master 0.6.16 → 0.6.17

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/README.md CHANGED
@@ -1,48 +1,29 @@
1
1
  # VibeCodingMaster
2
2
 
3
- VibeCodingMaster is a local GUI workspace for managing multiple Claude Code role sessions around one engineering task.
4
-
5
- VCM is designed for long-running coding work where one Claude Code conversation is not enough. It gives the user a task workspace with four embedded Claude Code sessions:
6
-
7
- - `project-manager`
8
- - `architect`
9
- - `coder`
10
- - `reviewer`
11
-
12
- Each role runs as a real Claude Code process inside an embedded terminal. The GUI lets the user start, stop, resume, restart, switch, observe, and manually intervene in those sessions without juggling separate terminal windows.
13
-
14
- When Gate Review Gates are enabled for a task, or when a Gate Reviewer session already exists, the workspace can also show a fifth `Gate Reviewer` terminal role. It is an optional VCM flow role powered by Claude Code. Its session is project-scoped and reusable across tasks, but each gate turn is bound to the current task/worktree, writes reports under the task worktree, and stays outside normal PM route-file dispatch.
15
-
16
- ## Current Capabilities
17
-
18
- - GUI-first task workspace.
19
- - Collapsible sidebar with repository connection, settings, harness status, task creation, and task list.
20
- - Recent repository path dropdown, stored locally with the five most recent paths.
21
- - Connected repository status for the base repo, including branch, upstream status, commit hash, dirty state, and fast-forward-only pull.
22
- - Embedded Claude Code terminals powered by `node-pty` and `xterm.js`.
23
- - One Claude Code session per role, with role tabs in the task header.
24
- - Optional Gate Reviewer VCM flow role when any Gate Review Gate is enabled.
25
- - Role session recovery through persisted Claude session ids and `claude --resume`.
26
- - Permission mode selection before start, resume, or restart:
27
- - `bypassPermissions`
28
- - `plan`
29
- - `default`
30
- - PM-mediated role messaging through VCM-dispatched route files.
31
- - Manual and automatic orchestration modes.
32
- - Two-stage VCM harness setup: deterministic fixed install plus AI-assisted bootstrap.
33
- - VCM-managed root rules, role agents, repo-local VCM skills, Claude Code hooks, generated-context tools, and PR template.
34
- - Generated context for Rust and npm workspace module indexing plus public surface indexing.
35
- - Translation panel powered by the long-lived Translator session.
36
- - Mobile Gateway through Tencent iLink / Weixin DM or Lark, for talking to PM and managing tasks from a phone.
37
- - Durable task state, role session state, handoff artifacts, and message history.
3
+ VibeCodingMaster is a local GUI workspace for running complex coding tasks with
4
+ Claude Code role sessions.
5
+
6
+ VCM helps you keep one task organized across dedicated roles:
7
+
8
+ - Project Manager
9
+ - Architect
10
+ - Coder
11
+ - Reviewer
12
+ - optional Gate Reviewer
13
+
14
+ It runs locally, connects to a local Git repository, creates a task branch and
15
+ worktree, starts embedded Claude Code terminals, and manages handoffs,
16
+ orchestration, translation, harness setup, and mobile gateway control.
38
17
 
39
18
  ## Requirements
40
19
 
41
- - Node.js 20 LTS or 22+.
42
- - npm.
43
- - Git.
44
- - Claude Code installed and available as `claude` in the runtime environment.
45
- - For Linux containers, native build/runtime basics for `node-pty`, usually:
20
+ - Node.js 20 LTS or 22+
21
+ - npm
22
+ - Git
23
+ - Claude Code installed and available as `claude`
24
+ - Claude Code authenticated in the same environment where VCM runs
25
+
26
+ For Linux containers, make sure common native build/runtime tools are available:
46
27
 
47
28
  ```bash
48
29
  python3 make g++ git bash
@@ -50,7 +31,7 @@ python3 make g++ git bash
50
31
 
51
32
  ## Install
52
33
 
53
- From npm:
34
+ Install from npm:
54
35
 
55
36
  ```bash
56
37
  npm install -g vibe-coding-master
@@ -58,30 +39,28 @@ vcm --version
58
39
  vcm
59
40
  ```
60
41
 
61
- Useful CLI flags:
42
+ By default, open:
62
43
 
63
- ```bash
64
- vcm --help
65
- vcm --version
66
- vcm --host=127.0.0.1 --port=4173
44
+ ```text
45
+ http://127.0.0.1:4173/
67
46
  ```
68
47
 
69
- From source:
48
+ Useful flags:
70
49
 
71
50
  ```bash
72
- npm install
73
- npm run dev
51
+ vcm --help
52
+ vcm --version
53
+ vcm --host=127.0.0.1 --port=5000
74
54
  ```
75
55
 
76
- ## Run Locally
77
-
78
- Development mode:
56
+ ## Run From Source
79
57
 
80
58
  ```bash
59
+ npm install
81
60
  npm run dev
82
61
  ```
83
62
 
84
- Open the Vite GUI:
63
+ Open the development UI:
85
64
 
86
65
  ```text
87
66
  http://127.0.0.1:5173/
@@ -93,8 +72,6 @@ The backend runs at:
93
72
  http://127.0.0.1:4173/
94
73
  ```
95
74
 
96
- If `5173` is already in use, Vite may choose another frontend port and print it in the terminal.
97
-
98
75
  Production-style local run:
99
76
 
100
77
  ```bash
@@ -108,17 +85,13 @@ Then open:
108
85
  http://127.0.0.1:4173/
109
86
  ```
110
87
 
111
- The global `vcm` command runs the production-style app and serves the GUI from the backend port:
112
-
113
- ```text
114
- http://127.0.0.1:4173/
115
- ```
116
-
117
- ## Run In VS Code Dev Containers
88
+ ## Recommended Sandbox
118
89
 
119
- VCM works inside a VS Code `devContainer` when VCM, Claude Code, and the target repository all run inside the same container filesystem.
90
+ VCM can run Claude Code with relaxed local permissions. The recommended setup is
91
+ to run VCM and the target repository inside a Dev Container, VM, or other local
92
+ sandbox boundary.
120
93
 
121
- Add port forwarding to `.devcontainer/devcontainer.json`:
94
+ For VS Code Dev Containers, forward the UI ports:
122
95
 
123
96
  ```json
124
97
  {
@@ -134,193 +107,243 @@ Add port forwarding to `.devcontainer/devcontainer.json`:
134
107
  }
135
108
  ```
136
109
 
137
- Use the path as seen from inside the container, for example `/workspace`.
110
+ Use repository paths as seen inside the container, for example `/workspace`.
138
111
 
139
- Important container notes:
112
+ If you want VCM app state to survive container rebuilds, set:
140
113
 
141
- - Install Claude Code inside the container, or make `claude` available in the container `PATH`.
142
- - Make sure Claude Code authentication works inside the container.
143
- - Make sure the container has network access to Claude services if translation is enabled.
144
- - VCM accepts normal Git repositories by checking `.git` directly. It also supports `.git` files that point to worktree gitdirs.
145
- - VCM uses per-command `git -c safe.directory=...` for Git metadata reads and does not require global `git config --global --add safe.directory`.
146
- - Treat the container as the sandbox boundary, especially when using relaxed Claude Code permission modes.
114
+ ```json
115
+ {
116
+ "containerEnv": {
117
+ "VCM_DATA_DIR": "/workspace/.ai/vcm"
118
+ }
119
+ }
120
+ ```
147
121
 
148
- ## Basic Usage
122
+ ## Quick Start
149
123
 
150
- 1. Start VCM.
124
+ 1. Start VCM with `vcm`.
151
125
  2. Open the GUI.
152
- 3. In the sidebar, open `Repository Path`, enter a repository path or choose one from `Recent`, then click `Connect`.
153
- 4. Review `VCM Harness`; if fixed files need install/update, click `Install / Update`.
154
- 5. If bootstrap checks are incomplete, click `Run Bootstrap` and let the visible Claude Code bootstrap session fill project-specific docs and generated context.
155
- 6. Review and commit harness changes when they look right.
156
- 7. Create a task from `New Task` with a single task name.
157
- 8. Select the task from `Tasks`.
158
- 9. Use the role tabs in the task header to switch between `Project Manager`, `Architect`, `Coder`, and `Reviewer`.
159
- 10. Choose the permission mode for the active role.
160
- 11. Click `Start`, `Resume`, `Restart`, or `Stop` as needed.
161
- 12. Talk mostly to `project-manager`; let PM coordinate the other roles through VCM messaging.
162
-
163
- The recommended flow is:
126
+ 3. In `Repository`, enter a local Git repository path and click `Connect`.
127
+ 4. Create or select a task in the `Task` section. VCM creates a task branch and
128
+ worktree immediately.
129
+ 5. In `VCM Harness`, initialize or update fixed harness files if VCM reports
130
+ pending changes. Harness changes are written to the active task worktree.
131
+ 6. If bootstrap is incomplete, open Harness Studio and run bootstrap through
132
+ Harness Engineer.
133
+ 7. Review the harness/bootstrap commit diff.
134
+ 8. Start the role sessions, or use the saved launch template / one-click start.
135
+ 9. Talk mostly to Project Manager.
136
+ 10. Let PM route work to Architect, Coder, Reviewer, and Gate Reviewer when
137
+ enabled.
138
+ 11. Review the final result and close the task when finished.
139
+
140
+ ## Repository Setup
141
+
142
+ VCM works with normal local Git repositories.
143
+
144
+ After you create or select a task, VCM can install or update harness files in
145
+ the active task worktree:
146
+
147
+ - root `CLAUDE.md` managed block
148
+ - `.claude/agents/**`
149
+ - `.claude/skills/**`
150
+ - `.claude/settings.json` hooks
151
+ - `.ai/tools/**`
152
+ - `.gitignore` entries for VCM runtime state and task worktrees
153
+ - generated-context tooling
154
+ - pull request template
155
+
156
+ VCM preserves user-authored content outside VCM managed blocks.
157
+
158
+ The fixed harness install is deterministic and creates a commit in the active
159
+ task worktree. Bootstrap is AI-assisted and is run through the Harness Engineer
160
+ role. Bootstrap fills project-specific docs and generated context such as:
161
+
162
+ - `docs/ARCHITECTURE.md`
163
+ - module-level `ARCHITECTURE.md`
164
+ - `docs/TESTING.md`
165
+ - `.ai/generated/module-index.json`
166
+ - `.ai/generated/public-surface.json`
167
+
168
+ ## Task Workflow
169
+
170
+ VCM uses one branch and one worktree for each task:
164
171
 
165
172
  ```text
166
- project-manager
167
- -> architect architecture plan, Scaffold Manifest, and code scaffolding
168
- -> coder implementation and baseline unit checks
169
- -> reviewer independent validation
170
- -> architect docs sync / architecture drift check
171
- -> project-manager final acceptance, commit, and PR
173
+ one task = one branch + one task worktree + one role-session set
172
174
  ```
173
175
 
174
- ## VCM Runtime Terminology
176
+ By default:
177
+
178
+ - branch: `feature/<task-name>`
179
+ - worktree: `<repo>/.claude/worktrees/<task-name>`
180
+
181
+ Roles for the same task share the same task worktree. VCM does not create one
182
+ worktree per role.
175
183
 
176
- VCM statistics use three nested terms:
184
+ Typical flow:
177
185
 
178
186
  ```text
179
- Session = n x Round = m x Turn
187
+ Project Manager
188
+ -> Architect
189
+ -> Coder
190
+ -> Reviewer
191
+ -> Architect docs sync
192
+ -> Project Manager final acceptance
180
193
  ```
181
194
 
182
- - `Session`: the whole VCM task. It aggregates all statistics for that task, from task creation until the task is closed.
183
- - `Round`: one user-facing VCM conversation cycle. It starts when a user prompt or VCM-delivered prompt is accepted, continues through automatic role orchestration, and normally ends when the final `project-manager` result has stopped and no next role turn starts inside the 10 second stop window.
184
- - `Turn`: one role-level Claude Code conversation. A turn starts when VCM or the user submits a prompt to one role session and ends when that Claude Code process emits `Stop`.
195
+ For complex tasks, ask PM to use managed mode. PM will keep the task moving and
196
+ ask the user only when user intent, authorization, external access, real cost,
197
+ production permission, sensitive data, or a proven outcome change requires a
198
+ human decision.
185
199
 
186
- Turns inside one Round are strictly sequential. VCM should finish one role Turn before starting the next role Turn in that Round.
200
+ ## Role Sessions
187
201
 
188
- Session state is intentionally small: `created` means no Round has started yet, `running` means there is a current running Round, and `stopped` means there is no current running Round after at least one Round has stopped. Starting Claude Code role sessions does not make the VCM Session `running`.
202
+ Each role runs in an embedded Claude Code terminal.
189
203
 
190
- Round state is only `running` or `stopped`. After a `Stop` hook, the 10 second stop window still counts as `running`; the Round becomes `stopped` only when the timer expires without another `UserPromptSubmit`.
204
+ Controls:
191
205
 
192
- In this terminology, `Session` is a VCM statistics term. It is different from a Claude Code role session. VCM still runs one Claude Code role session per role, but the sidebar task statistics treat the task itself as the VCM Session.
206
+ - `Start`: start a new Claude Code role session
207
+ - `Resume`: resume a saved Claude Code session
208
+ - `Restart`: stop current process and start fresh
209
+ - `Stop`: stop the embedded terminal process
193
210
 
194
- ## Task Worktree Management
195
-
196
- VCM uses task-level worktree management for every task:
211
+ Permission modes:
197
212
 
198
213
  ```text
199
- one task = one branch + one git worktree + one handoff directory + one role-session set
214
+ bypassPermissions
215
+ plan
216
+ default
200
217
  ```
201
218
 
202
- - task name: `<task>`
203
- - branch: `feature/<task>`
204
- - worktree path: `.claude/worktrees/<task>` inside the connected base repository
205
- - role session cwd: that task worktree
206
-
207
- VCM will not create worktrees per role. `project-manager`, `architect`, `coder`, and `reviewer` for the same task share the same task worktree.
219
+ `bypassPermissions` is the default because VCM expects a local sandbox boundary
220
+ such as a Dev Container or VM.
208
221
 
209
- VCM will not offer a separate `Create task worktree` button after a task exists, and a task should not be switched to another branch/worktree mode after creation.
222
+ Model and effort can be selected before start/resume/restart. Changes affect the
223
+ next launched process, not a currently running Claude Code process.
210
224
 
211
- Because worktrees live under `.claude/worktrees/`, the connected repository must ignore both `.ai/vcm/` and `.claude/worktrees/`. Apply the VCM Harness before creating tasks so `.gitignore` contains the managed ignore block. The base repository must also be clean because the task branch/worktree is created from the connected repo's current `HEAD`.
225
+ ## Launch Template
212
226
 
213
- When a task is complete, VCM provides a red `Close Task` action. Closing a task shows a destructive confirmation, stops VCM-managed running role sessions for that task, then deletes the task worktree, deletes the task branch by default, removes the app-local task record, and removes task runtime metadata. VCM does not preflight running sessions or uncommitted changes before closing. Project-scoped Gate Reviewer and Translator sessions are not task-owned and are not stopped by Close Task.
227
+ The launch template stores per-role defaults:
214
228
 
215
- ## Sidebar UI
229
+ - permission mode
230
+ - model
231
+ - effort
232
+ - auto orchestration
216
233
 
217
- The left sidebar is intentionally compact and collapsible:
234
+ One-click start launches the four core roles. If any Gate Review Gate is enabled,
235
+ it also launches Gate Reviewer.
218
236
 
219
- - `Repository Path`: path input on one row; `Recent` and `Connect` on the next row.
220
- - `Connected Repository`: connected base repo path, branch, upstream/ahead-behind status, commit hash, working tree state, and a `Pull` button.
221
- - `Settings`: `Theme`, `Flow pause alert`, `Try alert`, `Messages`, and `Events`.
222
- - `Translation`: global conversation translation, auto-send, target language, output scope, file translation, bootstrap, memory update, session status, and Translator session access.
223
- - `Gate Review Gates`: global gate switches for architecture plan, validation adequacy, and final diff.
224
- - `Gateway`: Weixin iLink or Lark setup, Gateway on/off, Gateway translation, and QR login/setup.
225
- - `VCM Harness`: fixed-install status, bootstrap completion checks, and the bootstrap terminal when one is running.
226
- - `New Task`: one `task name` input.
227
- - `Tasks`: task list and task status.
237
+ Translator and Harness Engineer are tool roles. They are controlled from their
238
+ own panels, not from the main role tab bar.
228
239
 
229
- All sidebar sections are collapsed by default. When no task is selected, `Repository Path` opens by default. The sidebar behaves as a single-open accordion: opening one section closes the previously open section, and clicking the open section collapses it.
240
+ ## Orchestration
230
241
 
231
- Opening `Connected Repository` refreshes the base repo status through the
232
- backend. VCM does not poll it continuously. The `Pull` button runs
233
- `git pull --ff-only` against the connected base repo only. It is disabled when
234
- the base repo has uncommitted changes or when the current branch has no
235
- upstream. It does not stash, merge, or mutate task worktrees.
242
+ VCM supports manual and automatic orchestration.
236
243
 
237
- When VCM is connected to an active task, the bottom of the sidebar shows a task status dock. It stays outside the collapsible groups and shows the active VCM Session title, task status, start time, total elapsed time, total Round count, and role active runtime. The dock also shows the Current Round while it is running, or the Last Round after a flow pause, including start time, total elapsed time, role active runtime, Turn count, and Round status.
238
-
239
- ## Mobile Gateway
244
+ Manual mode:
240
245
 
241
- VCM Gateway lets mobile chat clients talk to one desktop VCM instance. It supports Weixin iLink and Lark. It is a mobile control surface for the current desktop VCM, not a remote terminal.
246
+ - roles write route messages
247
+ - messages appear in the Messages panel
248
+ - the user decides what to copy, send, or clear
242
249
 
243
- Gateway rules:
250
+ Automatic mode:
244
251
 
245
- - Weixin is DM only; Lark can receive group messages only when the bot is mentioned.
246
- - Weixin binds one phone identity to one desktop VCM instance.
247
- - Lark accepts any DM or @mention from a chat that can reach the bot; the most recent active Lark chat becomes the PM reply target.
248
- - The active mobile chat can manage projects and tasks available to that desktop VCM instance.
249
- - When the desktop UI has an active task selected, Gateway uses that task automatically.
250
- - After setup, VCM keeps a lightweight Gateway connection for `/start` and read-only commands even when the `Gateway` toggle is off.
251
- - VCM caches the latest PM reply for each task locally, so `/start` can immediately return the current task's latest PM status when available.
252
- - Plain text messages go only to the current task's `project-manager`.
253
- - Gateway never sends directly to `architect`, `coder`, or `reviewer`.
254
- - Gateway credentials and audit logs stay in local app state, not in connected repositories.
252
+ - VCM dispatches route messages to idle target roles
253
+ - the UI switches to the target role before dispatch
254
+ - Claude Code hooks confirm whether the prompt was accepted
255
255
 
256
- Gateway state is stored locally under:
256
+ If the flow stops, VCM shows a pause alert. The `Pause alert sound` setting only
257
+ controls the sound; the stopped-flow state is still shown in the UI.
257
258
 
258
- ```text
259
- <vcmDataDir>/gateway/settings.json
260
- <vcmDataDir>/gateway/audit.jsonl
261
- ```
259
+ ## Gate Review Gates
262
260
 
263
- ### Bind Weixin
261
+ Gate Review is optional and off by default.
264
262
 
265
- 1. Start VCM and open the GUI.
266
- 2. Open the sidebar `Gateway` section.
267
- 3. Click `Start QR Login`.
268
- 4. VCM opens a global `Weixin Gateway Login` dialog with a QR code.
269
- 5. Scan the QR code with Weixin and confirm login on the phone.
270
- 6. Click `Confirm` in the dialog.
271
- 7. After binding succeeds, close the dialog and turn `Gateway` on in the sidebar.
263
+ Available gates:
272
264
 
273
- `Start QR Login` is shown only when Gateway is not bound. It creates a new Tencent iLink QR login session and opens the QR dialog. The dialog `Confirm` button asks iLink whether the QR code has been scanned and confirmed. After binding succeeds, the sidebar shows `Reset Binding` instead of `Start QR Login`.
265
+ - Architecture plan
266
+ - Validation adequacy
267
+ - Final diff
274
268
 
275
- The `Gateway` toggle is disabled until a QR login has produced a usable iLink token. After binding, VCM keeps receiving `/help`, `/start`, `/status`, `/projects`, and `/tasks` even when the toggle is off. Turning `Gateway` on, either from desktop or by sending `/start`, enables PM messages, task-changing commands, and PM reply push. `Reset Binding` clears the stored token and bound Weixin identity so the desktop VCM can bind again.
269
+ When a gate is enabled, VCM uses Gate Reviewer as an independent review role.
270
+ Gate Reviewer reviews artifacts and diffs, writes a gate report, and returns
271
+ only:
276
272
 
277
- ### Bind Lark
273
+ - `approve`
274
+ - `request_changes`
278
275
 
279
- 1. Open the sidebar `Gateway` section and select `Lark`.
280
- 2. Click `Start QR Setup`.
281
- 3. Scan the QR code with Lark and approve bot creation.
282
- 4. Click `Confirm` in the setup dialog.
283
- 5. Turn `Gateway` on in the sidebar.
284
- 6. Send a DM to the bot, or @mention it from a group.
276
+ Gate Reviewer does not run tests and does not choose owners or fixes. PM routes
277
+ findings back to the responsible role.
285
278
 
286
- Lark QR setup creates/configures the bot app and stores the resulting App ID/App Secret in local VCM state. The App Secret is not shown in the UI. Any Lark chat that can message the bot can control Gateway; VCM always treats the most recent active Lark chat as the PM reply target.
279
+ ## Translation
287
280
 
288
- When Gateway is turned on, VCM automatically turns off the browser `Flow pause alert` and disables `Try alert`. Gateway becomes the notification path, so the browser should not show blocking flow-pause dialogs while the user is managing the task from the phone.
281
+ Conversation translation is controlled from the sidebar `Translation` section.
289
282
 
290
- ### Translation
283
+ VCM uses the project-scoped Translator role and Claude transcript JSONL files,
284
+ not raw terminal text.
291
285
 
292
- The Gateway section has its own `Translation` toggle.
286
+ Common controls:
293
287
 
294
- When Gateway translation is on:
288
+ - enable/disable conversation translation
289
+ - auto-send translated user input
290
+ - target language
291
+ - reply scope
292
+ - open Translator session
293
+ - file translation
294
+ - bootstrap translation memory
295
+ - update memory
295
296
 
296
- - Mobile input is translated to English before being submitted to PM.
297
- - The prompt sent to PM includes only the translated English text with a `[VCM Gateway]` marker.
298
- - The original Chinese text is not included in the PM prompt.
299
- - PM replies are translated before VCM sends them to the active mobile chat.
300
- - If PM reply translation fails or times out, VCM sends a translation failure notice instead of the English source. The user can send `/retry` to retry the latest failed Gateway output translation.
297
+ Supported target languages:
301
298
 
302
- When Gateway translation is off, plain mobile text is sent to PM as-is.
299
+ - Chinese
300
+ - Japanese
301
+ - Korean
302
+ - French
303
+ - German
304
+ - Spanish
303
305
 
304
- ### Commands
306
+ Reply scope options:
305
307
 
306
- After Gateway is configured, send commands in the active mobile conversation.
308
+ - Round final reply
309
+ - PM final reply
310
+ - Each role final reply
311
+ - All replies
307
312
 
308
- When `Gateway` is off, only these commands are accepted:
313
+ File and conversation translation state lives under:
309
314
 
310
315
  ```text
311
- /help
312
- /start
313
- /status
314
- /projects
315
- /tasks
316
+ <baseRepoRoot>/.ai/vcm/translations/
316
317
  ```
317
318
 
318
- When `Gateway` is on, the full command set is accepted:
319
+ ## Mobile Gateway
320
+
321
+ Gateway lets a mobile chat client control the current local VCM instance.
322
+
323
+ Supported channels:
324
+
325
+ - Weixin iLink
326
+ - Lark
327
+
328
+ Gateway can:
329
+
330
+ - show status
331
+ - list projects and tasks
332
+ - select a project or task
333
+ - create a task
334
+ - close a task with confirmation
335
+ - send plain text to Project Manager
336
+ - push PM replies back to the active chat
337
+ - translate mobile messages when Gateway translation is enabled
338
+
339
+ Gateway does not expose the embedded terminal and does not send directly to
340
+ Architect, Coder, Reviewer, or Gate Reviewer.
341
+
342
+ Common commands:
319
343
 
320
344
  ```text
321
345
  /help
322
346
  /start
323
- /retry
324
347
  /status
325
348
  /projects
326
349
  /use-project <index-or-path>
@@ -332,333 +355,105 @@ When `Gateway` is on, the full command set is accepted:
332
355
  /close-task confirm <task-slug>
333
356
  /translate on
334
357
  /translate off
358
+ /retry
335
359
  ```
336
360
 
337
- Plain text that does not start with `/` is sent as a message to the current task's PM session only when `Gateway` is on.
338
-
339
- In normal use, VCM runs one project and one task at a time. If the desktop UI has a task selected, turning Gateway on syncs that project/task into Gateway automatically. `/status` also refreshes this context, so the phone usually does not need to run `/tasks` and `/use-task` before sending a PM message.
340
-
341
- Typical mobile flow:
342
-
343
- ```text
344
- /projects
345
- /use-project 1
346
- /pull-current
347
- /create-task mobile-demo "Implement mobile gateway smoke test"
348
- /status
349
- 继续推进这个任务,先让 PM 安排下一步。
350
- /close-task
351
- /close-task confirm mobile-demo
352
- ```
353
-
354
- ### Command Behavior
355
-
356
- - `/status`: shows Gateway, active chat, translation, current project, current task, and last poll status.
357
- - `/status` also adopts the current desktop project/task when one is selected.
358
- - `/start`: turns Gateway on from the active mobile conversation so full mobile task operations and PM messages are allowed. If the current task has a cached latest PM reply, `/start` includes it in the response.
359
- - `/retry`: retries the latest failed Gateway output translation in the current VCM process.
360
- - `/projects`: lists the current/recent repositories known by the desktop VCM.
361
- - `/use-project <index-or-path>`: selects the Gateway's current project context.
362
- - `/pull-current`: runs the same fast-forward-only connected repository pull as the desktop `Pull` button.
363
- - `/tasks`: lists tasks for the selected project.
364
- - `/use-task <index-or-task-slug>`: selects the Gateway's current task context.
365
- - `/create-task <task-slug> [title]`: creates a worktree-backed task and starts the four core role sessions using the saved launch template. If any Gate Review Gate is enabled, Gateway also resumes or starts Gate Reviewer from the saved template.
366
- - `/close-task`: starts a destructive close confirmation for the current task.
367
- - `/close-task confirm <task-slug>`: closes the task through VCM cleanup after exact slug confirmation.
368
- - `/translate on` and `/translate off`: changes Gateway translation for mobile messages.
369
-
370
- `/pull-current` only pulls the connected base repository. It does not pull task worktrees, stash local changes, merge divergent branches, or run arbitrary shell commands.
371
-
372
- `/create-task` uses the saved launch template from the desktop settings. The template controls permission mode, model, effort, and auto orchestration for the four core role sessions plus the optional Gate Reviewer. Gateway translation uses the global Gateway translation setting, not the launch template.
373
-
374
- `/close-task` is destructive. It stops VCM-managed role sessions and removes task-owned worktree/branch state according to the same cleanup behavior as the desktop `Close Task` action.
375
-
376
- ### Troubleshooting
377
-
378
- - If the QR dialog does not appear, refresh the page and click `Start QR Login` again.
379
- - If the QR status stays `wait`, confirm the login on the phone and click `Confirm` again.
380
- - If the QR code expires, start a new QR login.
381
- - If `Gateway` cannot be enabled, bind Weixin or complete Lark QR setup first.
382
- - If `/start` or read-only commands do not receive replies, check that the selected channel is connected and that Lark messages are sent as DM or group @mentions.
383
- - If PM messages or task-changing commands are rejected, check that Gateway is on.
384
- - If plain text cannot be sent to PM, select a project and task first, and make sure the task's PM session is running and idle.
385
- - If PM replies are not pushed, check that Gateway is on and the PM session is producing normal Claude transcript output.
386
- - If PM reply translation fails, send `/retry` from the active mobile conversation. Retry state is memory-only and is cleared when VCM restarts.
387
-
388
- ## Translation
389
-
390
- Translation is controlled from the sidebar `Translation` group. When conversation translation is enabled, each running core VCM role console shows a translation panel beside the embedded terminal. The terminal and translation panel split the available width evenly.
391
-
392
- The task header does not include a manual `Refresh` button. Task status, role status, messages, orchestration state, and flow pause state refresh automatically. The remaining `Refresh` button lives only in the sidebar `VCM Harness` section and is for rechecking harness files.
393
-
394
- Translation settings are local and stored in:
395
-
396
- ```text
397
- <vcmDataDir>/settings.json
398
- ```
399
-
400
- The same file stores recent repository paths and global translation preferences such as enablement, auto-send, and target language.
401
-
402
- VCM resolves `vcmDataDir` from `VCM_DATA_DIR`. If `VCM_DATA_DIR` is unset or empty, VCM uses `~/.vcm`. In Dev Containers, set `VCM_DATA_DIR=/workspace/.ai/vcm` through `containerEnv` so VCM app state survives container rebuilds.
403
-
404
- The sidebar `Settings` section also stores the UI theme preference in this file. The default is `system`, which follows the OS/browser color-scheme preference; users can cycle between `System`, `Light`, and `Dark`.
405
-
406
- The same sidebar also has a `Flow pause alert` toggle. It is on by default and controls the local alert that fires when VCM detects that the current role flow has stopped advancing. Short flows use a weak reminder: the soft two-note chime plays 3 times, 1.4 seconds apart. Flows lasting 2 minutes or longer use a strong reminder: VCM shows an alert dialog and repeats the chime until the user confirms it. The alert sound reuses one browser audio context so repeated reminders remain reliable in stricter browsers such as Safari. Safari users may still need to manually set `Safari > Website Settings > Auto-Play > Allow All Auto-Play`; Chrome is recommended for the most reliable alert sound behavior. The `Try alert` button always triggers the strong reminder for testing.
361
+ Gateway credentials and audit logs are stored in app-local state, not connected
362
+ repositories.
407
363
 
408
- When Gateway is on, `Flow pause alert` is forced off because mobile notifications are delivered through Gateway and browser alerts can block normal workflow progress.
364
+ ## Harness Studio
409
365
 
410
- Translation behavior:
366
+ Harness Studio is the UI for VCM harness maintenance.
411
367
 
412
- - Conversation translation is routed through the Translator session and result files.
413
- - Global translation controls live in the sidebar Translation section: enablement, auto-send, target language, output scope, bootstrap, memory update, file translation, session status, and `Open Session`.
414
- - File and conversation translation share `<baseRepoRoot>/.ai/vcm/translations/`; conversation result files are temporary runtime artifacts.
415
- - Claude Code output translation reads semantic Claude transcript JSONL files under `~/.claude/projects`, not raw PTY output.
416
- - Claude Code prose output waits 10 seconds before dispatch so adjacent output can be translated in one Claude Code Translator batch.
417
- - VCM tails those transcript files in the backend. Closing the translation panel does not stop capture; the tailer stops only when the role session is stopped/restarted or the task is closed.
418
- - Translation events are cached under the task runtime repo at `.ai/vcm/translation/<task>/<role>/<session-id>.jsonl` and delivered to the frontend through HTTP polling.
419
- - The polling cursor is the next expected seq: `after=18` acknowledges seq `1..17` and returns seq `18+`; there is no snapshot mismatch error.
420
- - The translation panel retains the most recent 500 entries per role session in frontend/backend memory. Older entries are pruned from the live panel state and event cache to keep long sessions responsive.
421
- - When new translation events arrive, the active translation panel automatically scrolls to the bottom so the latest output, retry result, or conversation boundary is visible.
422
- - Failed output translations are tracked in a backend failure list. When failures exist, the panel shows `Ignore N` and `Retry N`; retry reuses the original entry id so the failed row is replaced by the normal translating/translated flow. If an old failed entry is pruned by the 500-entry cap, its failure-list item is removed too.
423
- - Assistant prose is shown as English source while translating, then replaced by the translated Chinese result.
424
- - Assistant prose renders Markdown in the panel, including headings, lists, code fences, tables, and links.
425
- - Tool calls and tool results are preserved as dim one-line rows such as `● Bash({"command":"npm test"})`.
426
- - User input uses one textarea. Press `Enter` to translate or send the current English draft; press `Shift+Enter` for a newline.
427
- - After user input is translated, the English draft is appended after the original source text in the same textarea.
428
- - `Send English` writes the current English draft to the active embedded terminal and submits it.
429
- - Automatic terminal submission uses bracketed paste first, then sends Enter separately for Claude Code TUI reliability.
430
- - The sidebar `Auto-send` toggle sends the translated draft automatically when translation succeeds without warnings.
368
+ Use it to:
431
369
 
432
- ## Project Harness
370
+ - inspect fixed harness status
371
+ - run bootstrap
372
+ - open Harness Engineer
373
+ - review harness files
374
+ - copy file paths for discussion
375
+ - review task harness after a task completes
376
+ - inspect commit diffs for harness changes
377
+ - merge task harness commits back to the connected repository branch when
378
+ appropriate
433
379
 
434
- VCM works best when the connected repository contains VCM collaboration rules as normal project files. Harness setup has two stages.
380
+ Harness Engineer is project-scoped and resumable. When it performs task work,
381
+ VCM runs it from the active task worktree.
435
382
 
436
- Fixed install is deterministic. It installs or updates VCM-owned files and managed blocks:
383
+ ## Closing a Task
437
384
 
438
- ```text
439
- CLAUDE.md
440
- .gitignore
441
- .claude/settings.json
442
- .claude/agents/project-manager.md
443
- .claude/agents/architect.md
444
- .claude/agents/coder.md
445
- .claude/agents/reviewer.md
446
- .claude/skills/vcm-route-message/SKILL.md
447
- .claude/skills/vcm-final-acceptance/SKILL.md
448
- .claude/skills/vcm-long-running-validation/SKILL.md
449
- .claude/skills/vcm-harness-bootstrap/SKILL.md
450
- .claude/skills/vcm-gate-review/SKILL.md
451
- .claude/agents/gate-reviewer.md
452
- .claude/agents/translator.md
453
- .ai/tools/request-gate-review
454
- .ai/tools/generate-module-index
455
- .ai/tools/generate-public-surface
456
- .ai/tools/run-long-check
457
- .ai/tools/watch-job
458
- .ai/tools/vcm-bash-guard
459
- .github/pull_request_template.md
460
- ```
461
-
462
- Repo-local skills are installed as `.claude/skills/<skill-name>/SKILL.md` so
463
- Claude Code can register them.
464
-
465
- VCM roles must not run background Bash. A `PreToolUse` hook
466
- (`.ai/tools/vcm-bash-guard`) denies `run_in_background`, `nohup`, `setsid`,
467
- `disown`, and trailing `&` calls in VCM role sessions. The only sanctioned
468
- long-running mechanism is `.ai/tools/run-long-check` plus
469
- `.ai/tools/watch-job` through `vcm-long-running-validation`:
470
-
471
- - The detached job worker itself enforces the job ceiling (`--timeout`, max 60
472
- minutes) and a supervision lease: a job left without a live foreground
473
- watcher for about 2 minutes is killed and recorded as `orphaned`.
474
- - `watch-job` renews the lease and watches in windows of up to 8 minutes; it
475
- exits `125` while the job is still running instead of killing it, and the
476
- role re-runs it in the same turn until a terminal result.
477
- - The VCM backend blocks a role from ending its turn while one of its
478
- validation jobs is still running.
479
- - Only one validation job may be active at a time.
480
-
481
- If a managed-block file already exists, VCM preserves user-authored content and only inserts or replaces the VCM block:
482
-
483
- ```md
484
- <!-- VCM:BEGIN version=1 -->
485
- VCM-managed rules live here.
486
- <!-- VCM:END -->
487
- ```
385
+ `Close Task` is destructive.
488
386
 
489
- For `.gitignore`, VCM uses a gitignore-native managed block:
387
+ It stops task-owned VCM role sessions and removes task-owned worktree/branch
388
+ state. Commit or preserve anything important before closing.
490
389
 
491
- ```gitignore
492
- # VCM:BEGIN version=1
493
- .ai/vcm/
494
- .claude/worktrees/
495
- # VCM:END
496
- ```
390
+ Project-scoped tool sessions such as Translator and Harness Engineer are not
391
+ ordinary task deliverables. VCM may move them to a safe cwd when task context
392
+ changes.
497
393
 
498
- `.ai/vcm/` is the active VCM local control area, and `.claude/worktrees/` is the Claude-compatible task worktree area. VCM keeps the task index in app-local project state under `<vcmDataDir>/projects/`; each task runtime repo keeps its own session, message, orchestration, and translation state.
394
+ ## Troubleshooting
499
395
 
500
- VCM also JSON-merges `.claude/settings.json` to install Claude Code `PreToolUse`, `UserPromptSubmit`, `Stop`, and `PermissionRequest` hooks plus a managed `env.BASH_DEFAULT_TIMEOUT_MS` so foreground watch windows fit inside the Bash tool timeout. The hooks post directly to the local VCM backend, so roles do not need a VCM CLI command to confirm delivery or report turn completion. The `Stop` hook forwards the backend response to Claude Code, which lets VCM block turn-end while a validation job is still running.
396
+ ### The page does not open
501
397
 
502
- Bootstrap is AI-assisted. VCM starts or resumes the project-scoped Harness Engineer Claude Code session in the connected repository and asks it to use the `vcm-harness-bootstrap` skill. Bootstrap fills project-specific content and generated context:
398
+ Check the port printed by VCM. If you start with:
503
399
 
504
- ```text
505
- CLAUDE.md project context outside the VCM managed block
506
- docs/ARCHITECTURE.md
507
- <module>/ARCHITECTURE.md
508
- docs/TESTING.md
509
- .ai/generated/module-index.json
510
- .ai/generated/public-surface.json
400
+ ```bash
401
+ vcm --port=5000
511
402
  ```
512
403
 
513
- The generated-context tools support Rust/Cargo projects and npm workspace TypeScript/JavaScript projects. Other repository shapes can still install the fixed harness, but generated context should be treated as unsupported until project-specific generators exist.
514
-
515
- After applying harness changes or completing bootstrap, VCM reports the exact files changed or checks completed and reminds the user to review and commit them before starting long-running work.
516
-
517
- Role sessions learn VCM rules from `CLAUDE.md` and `.claude/agents/*.md`. VCM does not paste a long context block into the terminal at session start.
518
-
519
- ## Message Bus
520
-
521
- The message bus is file-driven and dispatched by VCM after Claude Code turn completion. Roles do not call a VCM CLI to send messages.
522
-
523
- Role communication works like this:
404
+ open:
524
405
 
525
406
  ```text
526
- Claude Code role
527
- -> writes or updates .ai/vcm/handoffs/messages/<from-role>-<to-role>.md
528
- -> ends the Claude Code turn
529
- -> Stop hook calls VCM backend directly
530
- -> VCM scans pending route files
531
- -> VCM validates and dispatches at most one pending route file
532
- -> VCM records dispatchingAt and the GUI switches to the target role
533
- -> VCM snapshots only actually delivered message history
534
- -> UserPromptSubmit hook records acceptedAt and clears the matching route file
407
+ http://127.0.0.1:5000/
535
408
  ```
536
409
 
537
- Examples:
410
+ ### Claude Code cannot start
538
411
 
539
- ```text
540
- .ai/vcm/handoffs/messages/project-manager-coder.md
541
- .ai/vcm/handoffs/messages/coder-project-manager.md
542
- .ai/vcm/handoffs/messages/project-manager-reviewer.md
543
- ```
544
-
545
- Runtime message and handoff files:
412
+ Check that `claude` is available in the same shell/container where VCM runs:
546
413
 
547
- ```text
548
- .ai/vcm/messages/<task>.jsonl # under the task runtime repo
549
- .ai/vcm/orchestration/<task>.json # under the task runtime repo
550
- .ai/vcm/handoffs/messages/<from-role>-<to-role>.md
414
+ ```bash
415
+ claude --version
551
416
  ```
552
417
 
553
- Each directed role route has exactly one message file. Route messages are the only dynamic task-dispatch files. If a role changes its mind during one turn, it edits the same route file instead of creating another message. A blank file means no pending message; a non-empty file means pending work for VCM to submit.
554
-
555
- ## Orchestration Modes
556
-
557
- VCM has a task-level `Auto orchestration` switch in the role console toolbar. New tasks default to auto orchestration.
558
-
559
- When it is off, VCM is in manual mode:
560
-
561
- - Roles may write pending route files under `.ai/vcm/handoffs/messages/`.
562
- - Messages appear in the `Messages` modal.
563
- - The user can inspect them.
564
- - The current GUI shows newest message history first with stable increasing sequence numbers, timestamp, body preview, path, `Copy`, `Mark All Done`, and `Delete All`.
565
- - `Mark All Done` clears non-empty pending route files after the user manually copied or handled stuck handoff content.
566
- - `Delete All` removes message history from the Messages modal without touching pending route files.
567
- - The user decides what to do next by copying or manually acting on the message.
568
- - VCM does not write to the target terminal or press Enter for the user.
418
+ Also confirm Claude Code authentication works in that environment.
569
419
 
570
- When it is on, VCM is in auto mode:
420
+ ### Repository cannot create a task
571
421
 
572
- - Backend policy still applies.
573
- - Roles write pending route files under `.ai/vcm/handoffs/messages/`.
574
- - On Claude Code `Stop`, VCM scans pending route files.
575
- - If the target role session is running and idle, VCM writes a `[VCM MESSAGE]` envelope to the target terminal and submits it.
576
- - Just before terminal submission, VCM records `dispatchingAt`, waits briefly for the GUI to switch tabs, then writes to the embedded terminal.
577
- - After successful terminal write, VCM snapshots the delivered body as message history.
578
- - Claude Code `UserPromptSubmit` confirms that the prompt was accepted; VCM stores `acceptedAt` and clears the source route file if it still contains the same message.
579
- - If `UserPromptSubmit` does not confirm the auto-delivered message, VCM retries Enter from the backend PTY and finally records `failureReason` on the message if submission is still not confirmed.
580
- - When the GUI observes a newly dispatching auto message, it switches the active role tab to that message's target role before the message is submitted.
581
- - VCM enforces sequential turn-taking from hook state: a role that has accepted a prompt is busy until its `Stop` hook fires.
582
- - Additional pending files to a busy target role remain non-empty and are not written to that terminal.
583
- - When the target role later reaches `Stop`, VCM scans again and may deliver the next pending route file.
584
- - If auto orchestration gets stuck after a manual copy/paste recovery, `Mark All Done` clears pending route files. It does not mutate message history.
422
+ Make sure:
585
423
 
586
- VCM Harness injects Claude Code `UserPromptSubmit` and `Stop` hooks into `.claude/settings.json`. Role tabs become `running` when Claude Code accepts a prompt and `idle` after `Stop`; VCM also marks a role `running` immediately after it writes a message to that embedded terminal. Gate Reviewer uses the same Claude hook/Round/translation path as other VCM flow roles, while VCM still owns gate report polling and the PM callback. The terminal process status is tracked separately. Claude role rules require a role to end its turn after writing or updating a message route file, rather than polling, looping, or waiting for another role inside the same Claude Code turn.
424
+ - the repository is a Git repository
425
+ - the connected base repo is clean
426
+ - no other task is currently active for this project
427
+ - the derived `feature/<task>` branch does not already exist
428
+ - the derived `.claude/worktrees/<task>` directory does not already exist
587
429
 
588
- The implementation keeps only the active manual/auto orchestration mode. It does not expose pause/resume, stage/approve/reject, or a separate agent-facing message CLI.
430
+ ### Resume fails
589
431
 
590
- ## Flow Pause Alerts
432
+ Claude Code only resumes conversations it actually saved. VCM records a Claude
433
+ session id after the first accepted prompt. If a session never received a prompt,
434
+ start a fresh session instead of resuming.
591
435
 
592
- VCM detects flow pauses from Claude Code hook events, not PTY silence, message history, or pending route files. `UserPromptSubmit` starts a new Round when there is no current running Round, or continues the current Round when it fires within the 10 second stop window.
436
+ ### Translation does not appear
593
437
 
594
- When a `Stop` hook fires, VCM ends the current Turn and starts a 10 second timer. During that timer, the Round is still `running`. If another `UserPromptSubmit` fires inside that window, the same Round continues and VCM increments the Turn count. If no new prompt is accepted before the deadline, VCM marks the Round as `stopped`.
438
+ Check that:
595
439
 
596
- The normal path is timer-driven: `Stop` starts a backend timer, and `UserPromptSubmit` cancels it.
440
+ - conversation translation is enabled
441
+ - Translator session is running
442
+ - the target role has an active Claude Code transcript
443
+ - reply scope includes the content you expect to translate
597
444
 
598
- When `Flow pause alert` is enabled, the frontend polls the task Round state and deduplicates each stopped Round so the same stopped state does not alert on every poll. Flow duration is measured from the first `UserPromptSubmit` to `stoppedAt`, falling back to the last `Stop` when needed. If the flow lasted less than 2 minutes, it plays the local chime 3 times at 1.4 second intervals. If the flow lasted 2 minutes or longer, it shows a modal alert and repeats the local chime until the user clicks `Confirm`. A stopped Round can mean normal completion, user decision needed, dispatch failure, or another workflow interruption; the point is to get the user to look with the right amount of urgency.
445
+ ### Gateway cannot send messages
599
446
 
600
- The Round dock separates wall-clock Round duration from role active runtime. For a running Round, `Total` is `now - Round.startedAt`; for a stopped Round, it is `stoppedAt - Round.startedAt`. `Role runtime` is only the accumulated time between each Turn's `UserPromptSubmit` and `Stop`; `Turn count` is the number of accepted prompts inside the Round.
447
+ Check that:
601
448
 
602
- ## Resume Behavior
449
+ - Gateway connection is configured
450
+ - Gateway is turned on for task-changing commands
451
+ - a project and task are selected
452
+ - the PM session is running and idle
603
453
 
604
- Each role session stores its Claude session id and transcript path under:
454
+ ## Development
605
455
 
606
- ```text
607
- .ai/vcm/sessions/<task>.json # under the task runtime repo
608
- ```
609
-
610
- Session buttons behave as follows:
611
-
612
- - `Start`: creates a fresh UUID, builds `claude --agent <role> --session-id <uuid>`, and stores the transcript path.
613
- - `Resume`: reuses the persisted Claude session id and builds `claude --agent <role> --resume <uuid>`.
614
- - `Restart`: stops the current process if needed, creates a new UUID, and starts a fresh Claude session.
615
- - `Stop`: stops the embedded terminal process and leaves the persisted Claude session id resumable.
616
-
617
- Ordinary VCM role sessions do not persist raw terminal logs under handoff state. Claude Code transcript JSONL files under `~/.claude/projects/` are the semantic record used for output translation and recovery.
618
-
619
- ## Local Project Files
620
-
621
- For a connected repository, VCM uses:
622
-
623
- ```text
624
- <vcmDataDir>/projects/<project-id>/config.json
625
- <vcmDataDir>/projects/<project-id>/tasks/<task>.json
626
- <baseRepoRoot>/.claude/worktrees/<task>/
627
- <taskRepoRoot>/.ai/vcm/sessions/<task>.json
628
- <taskRepoRoot>/.ai/vcm/messages/<task>.jsonl
629
- <taskRepoRoot>/.ai/vcm/orchestration/<task>.json
630
- <taskRepoRoot>/.ai/vcm/translation/<task>/
631
- <taskRepoRoot>/.ai/vcm/handoffs/architecture-plan.md
632
- <taskRepoRoot>/.ai/vcm/handoffs/known-issues.md
633
- <taskRepoRoot>/.ai/vcm/handoffs/review-report.md
634
- <taskRepoRoot>/.ai/vcm/handoffs/docs-sync-report.md
635
- <taskRepoRoot>/.ai/vcm/handoffs/messages/<from-role>-<to-role>.md
636
- <taskRepoRoot>/.ai/vcm/gate-reviews/
637
- <baseRepoRoot>/.ai/vcm/gate-reviewer/session.json
638
- <baseRepoRoot>/.ai/vcm/translations/
639
- ```
640
-
641
- The project config is stored under `vcmDataDir` so it is durable local app state. `vcmDataDir` is `VCM_DATA_DIR` when set, otherwise `~/.vcm`. For Dev Containers, prefer:
642
-
643
- ```json
644
- {
645
- "containerEnv": {
646
- "VCM_DATA_DIR": "/workspace/.ai/vcm"
647
- }
648
- }
649
- ```
650
-
651
- For every task, `taskRepoRoot` is `<baseRepoRoot>/.claude/worktrees/<task>`.
652
-
653
- ## Packaging
654
-
655
- The npm package publishes built output, not raw TypeScript entry files. `package.json` includes:
656
-
657
- - `bin.vcm`: `dist/main.js`
658
- - `files`: `dist`, `dist-frontend`, `scripts`, `README.md`
659
- - `prepack`: `npm run build && npm run verify:package`
660
-
661
- Use this before publishing:
456
+ Useful commands:
662
457
 
663
458
  ```bash
664
459
  npm run typecheck
@@ -667,30 +462,23 @@ npm run build
667
462
  npm run verify:package
668
463
  ```
669
464
 
670
- ## Validation
465
+ Development server:
466
+
467
+ ```bash
468
+ npm run dev
469
+ ```
470
+
471
+ Production-style run:
671
472
 
672
473
  ```bash
673
- npm run typecheck
674
- npm test
675
474
  npm run build
475
+ npm start
676
476
  ```
677
477
 
678
- ## Current Boundaries
679
-
680
- - VCM does not use tmux.
681
- - VCM does not auto-confirm Claude Code permission prompts.
682
- - VCM does not isolate roles with separate worktrees; roles for one task share one task worktree.
683
- - VCM does not translate Claude output from raw PTY output; translation reads Claude transcript JSONL files.
684
- - VCM does not write translation output into handoff artifacts unless a user or role explicitly copies it there.
685
- - Role file writes happen in the task worktree when a task has a worktree.
686
- - The safest sandbox today is a container or VM boundary controlled by the user.
687
-
688
- See also:
689
-
690
- - `docs/product-design.md`
691
- - `docs/v0.2-implementation-plan.md`
692
- - `docs/vcm-cc-best-practices.md`
693
- - `docs/full-harness-baseline.md`
694
- - `docs/gate-review-gates.md`
695
- - `docs/claude-code-translation-plan.md`
696
- - `docs/cc-best-practices.md` is archived and no longer maintained.
478
+ ## Documentation
479
+
480
+ - `docs/ARCHITECTURE.md`: repository architecture
481
+ - `docs/TESTING.md`: validation strategy
482
+ - `docs/vcm-cc-best-practices.md`: current VCM Claude Code harness practice
483
+ - `docs/v0.5-custom-workflow-plan.md`: future custom workflow plan
484
+ - `docs/cc-best-practices.md`: archived generic Claude Code harness notes
@@ -1656,7 +1656,7 @@ Required work:
1656
1656
  - Run .ai/tools/generate-public-surface from the target task worktree after module-index.json exists.
1657
1657
  - Add or update project-specific Project Context and Project Constraints in target CLAUDE.md above the VCM managed block.
1658
1658
  - Fill target docs/ARCHITECTURE.md with project-level module overview, responsibilities, relationships, dependency direction, project-wide constraints, and links to module-level architecture docs.
1659
- - Create or update target module-level ARCHITECTURE.md files for clear module boundaries listed by module-index.json.
1659
+ - Create or update target module-level ARCHITECTURE.md files for clear non-root module boundaries with architectureDoc paths in module-index.json.
1660
1660
  - Fill target docs/TESTING.md with project-native validation levels, commands, validation selection rules, final-validation cleanup, test layout, integration/E2E case lists, generated-context freshness checks, and known testing gaps.
1661
1661
  - Review git status and git diff in the target task worktree.
1662
1662
  - Stage only allowed bootstrap harness changes and create a commit in the target task worktree.
@@ -17,7 +17,7 @@ This skill is an operating procedure. It does not replace the deterministic VCM
17
17
  1. Generate context when supported: run \`.ai/tools/generate-module-index\`, then run \`.ai/tools/generate-public-surface\` after \`module-index.json\` exists.
18
18
  2. Inspect the project: read \`README.md\`, read \`CLAUDE.md\`, durable project docs, project manifests/config, source layout, tests, and existing validation commands.
19
19
  3. Fill project context: add or update non-managed project facts in \`CLAUDE.md\` above the VCM managed block.
20
- 4. Fill durable docs: update \`docs/ARCHITECTURE.md\`, module-level \`ARCHITECTURE.md\` files, and \`docs/TESTING.md\` with detailed project-specific content.
20
+ 4. Fill durable docs: update \`docs/ARCHITECTURE.md\`, module-level \`ARCHITECTURE.md\` files for clear non-root module boundaries, and \`docs/TESTING.md\` with detailed project-specific content.
21
21
  5. Preserve user-authored content and VCM managed blocks.
22
22
  6. Review \`git status\` and \`git diff\`.
23
23
  7. Stage only allowed bootstrap harness changes and create a commit in the active task worktree.
@@ -29,7 +29,7 @@ This skill is an operating procedure. It does not replace the deterministic VCM
29
29
  - \`docs/ARCHITECTURE.md\`
30
30
  - \`docs/TESTING.md\`
31
31
  - \`docs/known-issues.md\` only for confirmed durable issues
32
- - module-level \`ARCHITECTURE.md\` files
32
+ - module-level \`ARCHITECTURE.md\` files for clear non-root module boundaries
33
33
  - \`.ai/generated/module-index.json\`
34
34
  - \`.ai/generated/public-surface.json\`
35
35
 
@@ -55,7 +55,8 @@ This skill is an operating procedure. It does not replace the deterministic VCM
55
55
 
56
56
  ### Module-Level \`ARCHITECTURE.md\`
57
57
 
58
- - Create or update one module-level \`ARCHITECTURE.md\` for each clear module boundary.
58
+ - Create or update one module-level \`ARCHITECTURE.md\` for each clear non-root module boundary with an \`architectureDoc\` path in \`.ai/generated/module-index.json\`.
59
+ - Do not create a root-level \`ARCHITECTURE.md\` only because the root package exists.
59
60
  - Document module boundaries, responsibilities, allowed dependencies, important behavior, important public surface explanations, risks, and update triggers.
60
61
  - Keep complete public API listings in \`.ai/generated/public-surface.json\`; module docs should explain meaning and design intent, not duplicate the full generated index.
61
62
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe-coding-master",
3
- "version": "0.6.16",
3
+ "version": "0.6.17",
4
4
  "description": "Local GUI session cockpit for Claude Code role sessions.",
5
5
  "type": "module",
6
6
  "files": [
@@ -327,22 +327,21 @@ def build_node_index(project_root: Path, node_root: Path) -> dict:
327
327
  layer_by_name[layer_name] = layer
328
328
  layers.append(layer)
329
329
 
330
- layer_by_name[layer_name]["modules"].append(
331
- {
332
- "name": record["name"],
333
- "path": module_path,
334
- "manifest": manifest_rel,
335
- "architectureDoc": f"{module_path}/ARCHITECTURE.md"
336
- if module_path != "."
337
- else "ARCHITECTURE.md",
338
- "workspaceDependencies": record["workspaceDependencies"],
339
- "language": "typescript",
340
- "files": {
341
- "source": source_files,
342
- "tests": test_files,
343
- },
344
- }
345
- )
330
+ module_entry = {
331
+ "name": record["name"],
332
+ "path": module_path,
333
+ "manifest": manifest_rel,
334
+ "workspaceDependencies": record["workspaceDependencies"],
335
+ "language": "typescript",
336
+ "files": {
337
+ "source": source_files,
338
+ "tests": test_files,
339
+ },
340
+ }
341
+ if module_path != ".":
342
+ module_entry["architectureDoc"] = f"{module_path}/ARCHITECTURE.md"
343
+
344
+ layer_by_name[layer_name]["modules"].append(module_entry)
346
345
 
347
346
  return {
348
347
  "schemaVersion": 1,
@@ -441,21 +440,20 @@ def build_cargo_index(project_root: Path, cargo_root: Path) -> dict:
441
440
  layer_by_name[layer_name] = layer
442
441
  layers.append(layer)
443
442
 
444
- layer_by_name[layer_name]["modules"].append(
445
- {
446
- "name": record["name"],
447
- "path": module_path,
448
- "manifest": manifest_rel,
449
- "architectureDoc": f"{module_path}/ARCHITECTURE.md"
450
- if module_path != "."
451
- else "ARCHITECTURE.md",
452
- "workspaceDependencies": record["workspaceDependencies"],
453
- "files": {
454
- "source": rust_files_under(module_dir, project_root, "src"),
455
- "tests": rust_files_under(module_dir, project_root, "tests"),
456
- },
457
- }
458
- )
443
+ module_entry = {
444
+ "name": record["name"],
445
+ "path": module_path,
446
+ "manifest": manifest_rel,
447
+ "workspaceDependencies": record["workspaceDependencies"],
448
+ "files": {
449
+ "source": rust_files_under(module_dir, project_root, "src"),
450
+ "tests": rust_files_under(module_dir, project_root, "tests"),
451
+ },
452
+ }
453
+ if module_path != ".":
454
+ module_entry["architectureDoc"] = f"{module_path}/ARCHITECTURE.md"
455
+
456
+ layer_by_name[layer_name]["modules"].append(module_entry)
459
457
 
460
458
  return {
461
459
  "schemaVersion": 1,