vibe-coding-master 0.3.29 → 0.3.30

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.
Files changed (28) hide show
  1. package/README.md +9 -13
  2. package/dist/backend/api/project-routes.js +1 -1
  3. package/dist/backend/api/{codex-translation-routes.js → translation-worker-routes.js} +21 -21
  4. package/dist/backend/cli/install-vcm-harness.js +30 -25
  5. package/dist/backend/server.js +12 -22
  6. package/dist/backend/services/claude-hook-service.js +51 -1
  7. package/dist/backend/services/harness-service.js +49 -29
  8. package/dist/backend/services/session-service.js +56 -163
  9. package/dist/backend/services/translation-service.js +17 -17
  10. package/dist/backend/services/{codex-translation-service.js → translation-worker-service.js} +11 -11
  11. package/dist/backend/templates/harness/gate-review.js +2 -58
  12. package/dist/shared/constants.js +13 -10
  13. package/dist/shared/types/app-settings.js +1 -1
  14. package/dist/shared/types/session.js +2 -14
  15. package/dist-frontend/assets/{index-Cfum1Prr.css → index-BvUHLq4X.css} +1 -1
  16. package/dist-frontend/assets/{index-K34QFpWK.js → index-D0ezB4na.js} +36 -36
  17. package/dist-frontend/index.html +2 -2
  18. package/docs/{codex-translation-plan.md → claude-code-translation-plan.md} +151 -153
  19. package/docs/full-harness-baseline.md +3 -7
  20. package/docs/gateway-design.md +1 -1
  21. package/docs/product-design.md +2 -2
  22. package/docs/v0.4-custom-workflow-plan.md +0 -1
  23. package/docs/vcm-cc-best-practices.md +2 -5
  24. package/package.json +1 -1
  25. package/dist/backend/api/codex-hook-routes.js +0 -9
  26. package/dist/backend/codex-sandbox-mode.js +0 -28
  27. package/dist/backend/services/codex-hook-service.js +0 -71
  28. package/dist/shared/types/codex-hook.js +0 -1
@@ -36,7 +36,7 @@ CLAUDE.md
36
36
  .claude/agents/coder.md
37
37
  .claude/agents/reviewer.md
38
38
  .claude/agents/gate-reviewer.md
39
- .ai/codex-translator/AGENTS.md
39
+ .claude/agents/translator.md
40
40
  ```
41
41
 
42
42
  Whole-file or raw-file harness files:
@@ -47,9 +47,7 @@ Whole-file or raw-file harness files:
47
47
  .claude/skills/vcm-long-running-validation/SKILL.md
48
48
  .claude/skills/vcm-harness-bootstrap/SKILL.md
49
49
  .claude/skills/vcm-gate-review/SKILL.md
50
- .ai/codex-translator/config.toml
51
- .ai/codex-translator/.codex/config.toml
52
- .ai/codex-translator/.codex/hooks.json
50
+ .claude/agents/translator.md
53
51
  .ai/tools/generate-module-index
54
52
  .ai/tools/generate-public-surface
55
53
  .ai/tools/request-gate-review
@@ -76,8 +74,6 @@ Directory roots created by the installer:
76
74
  .claude/skills/vcm-long-running-validation/
77
75
  .claude/skills/vcm-route-message/
78
76
  .claude/skills/vcm-gate-review/
79
- .ai/codex-translator/
80
- .ai/codex-translator/.codex/
81
77
  .ai/vcm/translations/
82
78
  .ai/vcm/gate-reviews/
83
79
  .ai/tools/
@@ -158,7 +154,7 @@ session recovery.
158
154
 
159
155
  Close Task removes the task-owned worktree, branch, app-local task record, and
160
156
  task-local runtime state. It stops task-scoped VCM role sessions for that task.
161
- It must not stop project-scoped Gate Reviewer or Codex Translator sessions.
157
+ It must not stop project-scoped Gate Reviewer or Translator sessions.
162
158
 
163
159
  Durable facts that should survive task cleanup must be promoted into code,
164
160
  tests, durable docs, PR text, commit history, or release notes before closing
@@ -588,7 +588,7 @@ Service dependencies:
588
588
  template auto/manual orchestration mode.
589
589
  - `TerminalRuntime`: controlled PM terminal submission.
590
590
  - `ClaudeTranscriptService`: PM assistant output extraction.
591
- - `TranslationService` / Codex Translator: inbound Chinese-to-English and
591
+ - `TranslationService` / Translator: inbound Chinese-to-English and
592
592
  outbound target-language translation.
593
593
  - `ClaudeHookService` or hook event integration: trigger PM reply push after PM
594
594
  `Stop`.
@@ -635,7 +635,7 @@ The settings file stores:
635
635
  - global translation target language
636
636
  - recent repository paths
637
637
 
638
- Translation work is routed through the long-lived Codex Translator session. VCM no longer exposes API-key, provider, or prompt-slot settings for the old API-backed translation path.
638
+ Translation work is routed through the long-lived Translator session. VCM no longer exposes API-key, provider, or prompt-slot settings for the old API-backed translation path.
639
639
 
640
640
  Sidebar controls:
641
641
 
@@ -689,7 +689,7 @@ Display behavior:
689
689
  - when translation fails, panel status shows `error` and the entry keeps the visible source plus an error.
690
690
  - `tool-output` is dim, one-line, truncated by CSS, and not translated.
691
691
 
692
- Long translations do not block capture. Translatable prose entries are pushed to the panel before Codex translation starts. Claude Code prose output waits up to 10 seconds so adjacent entries can be batched into one Codex prompt and one temporary result file. When an `end_turn` assistant text arrives, VCM adds it to the current batch and flushes the batch immediately. The default output mode is `final summary`, which translates only `end_turn` assistant text to save Codex quota. In `all output` mode, intermediate assistant text and structured question/todo/agent events are also translated. `tool_use` and `tool_result` entries are never added to the translation queue; they are displayed immediately.
692
+ Long translations do not block capture. Translatable prose entries are pushed to the panel before translation starts. Claude Code prose output waits up to 10 seconds so adjacent entries can be batched into one Claude Code Translator prompt and one temporary result file. When an `end_turn` assistant text arrives, VCM adds it to the current batch and flushes the batch immediately. The default output mode is `PM final reply`, which translates only Project Manager `end_turn` assistant text to reduce translation work. In `all output` mode, intermediate assistant text and structured question/todo/agent events are also translated. `tool_use` and `tool_result` entries are never added to the translation queue; they are displayed immediately.
693
693
 
694
694
  There is no keyword classifier that drops assistant text. A previous design skipped permission-looking or log-looking text; that is removed.
695
695
 
@@ -228,7 +228,6 @@ The role model should not assume every role uses the same CLI.
228
228
  Recommended initial engines:
229
229
 
230
230
  - `claude-code`
231
- - `codex-cli`
232
231
  - `manual`
233
232
  - `command`
234
233
 
@@ -7,7 +7,7 @@ It is based on the latest `example/rust-layered` harness baseline.
7
7
 
8
8
  Do not install this document into target repositories. Target repositories should
9
9
  receive a concise root `CLAUDE.md` VCM block, role agents, repo-local VCM
10
- skills, harness tools, Codex Translator harness files, and project-owned
10
+ skills, harness tools, Translator harness files, and project-owned
11
11
  durable docs.
12
12
 
13
13
  `docs/cc-best-practices.md` is archived as the old generic baseline. Current VCM
@@ -48,10 +48,7 @@ CLAUDE.md
48
48
  .claude/skills/vcm-long-running-validation/SKILL.md
49
49
  .claude/skills/vcm-harness-bootstrap/SKILL.md
50
50
  .claude/skills/vcm-gate-review/SKILL.md
51
- .ai/codex-translator/AGENTS.md
52
- .ai/codex-translator/config.toml
53
- .ai/codex-translator/.codex/config.toml
54
- .ai/codex-translator/.codex/hooks.json
51
+ .claude/agents/translator.md
55
52
  .ai/tools/generate-module-index
56
53
  .ai/tools/generate-public-surface
57
54
  .ai/tools/request-gate-review
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe-coding-master",
3
- "version": "0.3.29",
3
+ "version": "0.3.30",
4
4
  "description": "Local GUI session cockpit for Claude Code role sessions.",
5
5
  "type": "module",
6
6
  "files": [
@@ -1,9 +0,0 @@
1
- export function registerCodexHookRoutes(app, deps) {
2
- app.post("/api/hooks/codex-translator", async (request) => {
3
- return deps.codexHookService.handleHook(request.body);
4
- });
5
- app.post("/api/hooks/codex-translator/stop", async (request) => {
6
- await deps.codexHookService.handleStopHook(request.body);
7
- return {};
8
- });
9
- }
@@ -1,28 +0,0 @@
1
- import { existsSync } from "node:fs";
2
- export function resolveCodexSandboxMode(env = process.env, pathExists = existsSync) {
3
- const explicit = env.VCM_SANDBOX?.trim();
4
- if (explicit) {
5
- return explicit;
6
- }
7
- if (isTruthy(env.VCM_CODEX_DISABLE_SANDBOX) ||
8
- isTruthy(env.VCM_CODEX_BYPASS_SANDBOX) ||
9
- isTruthy(env.CODESPACES) ||
10
- isTruthy(env.REMOTE_CONTAINERS) ||
11
- isTruthy(env.DEVCONTAINER)) {
12
- return "devcontainer";
13
- }
14
- const containerName = (env.container ?? env.CONTAINER ?? "").toLowerCase();
15
- if (containerName === "devcontainer" || containerName === "docker" || containerName === "podman") {
16
- return "devcontainer";
17
- }
18
- if (env.KUBERNETES_SERVICE_HOST || pathExists("/.dockerenv") || pathExists("/run/.containerenv")) {
19
- return "devcontainer";
20
- }
21
- return undefined;
22
- }
23
- function isTruthy(value) {
24
- if (!value) {
25
- return false;
26
- }
27
- return !["0", "false", "no", "off"].includes(value.trim().toLowerCase());
28
- }
@@ -1,71 +0,0 @@
1
- import { isCodexRoleName } from "../../shared/constants.js";
2
- import { VcmError } from "../errors.js";
3
- export function createCodexHookService(deps) {
4
- async function getHookContext(input) {
5
- if (!isCodexRoleName(input.role)) {
6
- throw new VcmError({
7
- code: "CODEX_HOOK_ROLE_INVALID",
8
- message: `Unknown Codex hook role: ${input.role}`,
9
- statusCode: 400
10
- });
11
- }
12
- const project = await deps.projectService.getCurrentProject();
13
- if (!project) {
14
- throw new VcmError({
15
- code: "PROJECT_NOT_CONNECTED",
16
- message: "Connect a repository before accepting Codex hooks.",
17
- statusCode: 409
18
- });
19
- }
20
- return {
21
- project
22
- };
23
- }
24
- async function processHook(input, expectedEventName) {
25
- const eventName = parseHookEvent(input.event.hook_event_name);
26
- if (eventName !== expectedEventName) {
27
- throw new VcmError({
28
- code: "CODEX_HOOK_EVENT_UNSUPPORTED",
29
- message: `Unsupported Codex hook event for this endpoint: ${eventName}`,
30
- statusCode: 400
31
- });
32
- }
33
- const context = await getHookContext(input);
34
- const session = await deps.sessionService.recordProjectTranslatorHookEvent(context.project.repoRoot, {
35
- eventName,
36
- sessionId: stringOrUndefined(input.event.session_id),
37
- transcriptPath: stringOrUndefined(input.event.transcript_path),
38
- cwd: stringOrUndefined(input.event.cwd)
39
- });
40
- await deps.codexTranslationService?.handleCodexHook(context.project.repoRoot, eventName, input.taskSlug);
41
- return {
42
- ok: true,
43
- eventName,
44
- taskSlug: input.taskSlug,
45
- role: input.role,
46
- sessionUpdated: Boolean(session)
47
- };
48
- }
49
- return {
50
- handleHook(input) {
51
- return processHook(input, "UserPromptSubmit");
52
- },
53
- handleStopHook(input) {
54
- return processHook(input, "Stop");
55
- }
56
- };
57
- }
58
- function parseHookEvent(value) {
59
- if (value === "UserPromptSubmit" || value === "Stop") {
60
- return value;
61
- }
62
- throw new VcmError({
63
- code: "CODEX_HOOK_EVENT_UNSUPPORTED",
64
- message: `Unsupported Codex hook event: ${String(value)}`,
65
- statusCode: 400,
66
- hint: "VCM accepts Codex UserPromptSubmit and Stop hooks only."
67
- });
68
- }
69
- function stringOrUndefined(value) {
70
- return typeof value === "string" ? value : undefined;
71
- }
@@ -1 +0,0 @@
1
- export {};