vibe-coding-master 0.7.4 → 0.7.6
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 +19 -16
- package/dist/backend/adapters/git-adapter.js +15 -0
- package/dist/backend/api/artifact-routes.js +3 -0
- package/dist/backend/api/harness-routes.js +50 -27
- package/dist/backend/api/runtime-state-routes.js +7 -3
- package/dist/backend/api/task-routes.js +36 -4
- package/dist/backend/api/translation-routes.js +11 -2
- package/dist/backend/api/translation-worker-routes.js +37 -9
- package/dist/backend/cli/install-vcm-harness.js +40 -2
- package/dist/backend/gateway/gateway-service.js +34 -17
- package/dist/backend/server.js +12 -3
- package/dist/backend/services/artifact-service.js +5 -1
- package/dist/backend/services/auto-memory-service.js +156 -81
- package/dist/backend/services/claude-hook-service.js +50 -35
- package/dist/backend/services/command-dispatcher.js +1 -1
- package/dist/backend/services/gate-review-service.js +335 -31
- package/dist/backend/services/harness-feedback-service.js +19 -8
- package/dist/backend/services/harness-service.js +112 -34
- package/dist/backend/services/message-service.js +39 -2
- package/dist/backend/services/round-service.js +10 -121
- package/dist/backend/services/runtime-coordinator-service.js +18 -10
- package/dist/backend/services/runtime-recovery-service.js +1 -2
- package/dist/backend/services/session-service.js +36 -98
- package/dist/backend/services/status-service.js +1 -0
- package/dist/backend/services/task-close-service.js +12 -27
- package/dist/backend/services/task-workflow-service.js +228 -0
- package/dist/backend/services/translation-worker-service.js +14 -7
- package/dist/backend/templates/handoff.js +128 -1
- package/dist/backend/templates/harness/architect-agent.js +85 -22
- package/dist/backend/templates/harness/claude-root.js +25 -29
- package/dist/backend/templates/harness/coder-agent.js +5 -7
- package/dist/backend/templates/harness/coder-worker-agent.js +3 -3
- package/dist/backend/templates/harness/gate-review.js +292 -65
- package/dist/backend/templates/harness/harness-engineer-agent.js +8 -8
- package/dist/backend/templates/harness/memory-block.js +69 -0
- package/dist/backend/templates/harness/project-known-issues.js +1 -0
- package/dist/backend/templates/harness/project-manager-agent.js +217 -75
- package/dist/backend/templates/harness/role-memory.js +9 -12
- package/dist/backend/templates/harness/tester-agent.js +8 -4
- package/dist/backend/templates/harness/vcm-architecture-interview-skill.js +82 -0
- package/dist/backend/templates/harness/vcm-final-acceptance-skill.js +4 -3
- package/dist/backend/templates/harness/vcm-harness-bootstrap-skill.js +14 -3
- package/dist/backend/templates/harness/vcm-propose-memory-skill.js +2 -2
- package/dist/backend/templates/harness/vcm-route-message-skill.js +5 -0
- package/dist/backend/templates/harness/vcm-task-state-skill.js +110 -0
- package/dist/backend/templates/message-envelope.js +1 -1
- package/dist/shared/constants.js +0 -10
- package/dist/shared/types/workflow.js +1 -0
- package/dist/shared/validation/artifact-check.js +41 -1
- package/dist-frontend/assets/index-BO2AuF-q.js +97 -0
- package/dist-frontend/assets/index-C2etsYlK.css +32 -0
- package/dist-frontend/index.html +2 -2
- package/package.json +1 -1
- package/scripts/harness-tools/check-durable-docs +298 -0
- package/scripts/verify-package.mjs +1 -0
- package/dist-frontend/assets/index-DCb-S6Ls.css +0 -32
- package/dist-frontend/assets/index-NTlycxx9.js +0 -97
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
export function renderRootClaudeHarnessRules() {
|
|
2
|
-
return
|
|
3
|
-
|
|
4
|
-
## VCM Start Here
|
|
2
|
+
return `## VCM Start Here
|
|
5
3
|
|
|
6
4
|
- Use the durable project docs below as role-relevant project truth.
|
|
7
5
|
- Read module-local \`CLAUDE.md\` before editing a subdirectory if one exists.
|
|
8
6
|
- \`vcm-route-message\` is the only channel for PM-hub dispatch and reporting among project-manager, architect, coder, and tester. Gate Review and tool-role work use their dedicated VCM skills and controllers. Follow the route skill's write-then-stop rule.
|
|
7
|
+
- Project-manager uses \`vcm-task-state\` to declare the current workflow checkpoint. This state is recoverable context only; flow rules and task artifacts remain authoritative.
|
|
9
8
|
- Use \`vcm-long-running-validation\` for long-running validation. Follow the background job limits below.
|
|
10
9
|
- Use \`vcm-report-harness-issue\` when you notice a reusable VCM harness problem. Record feedback; do not contact Harness Engineer directly.
|
|
11
|
-
- Treat
|
|
10
|
+
- The root \`<VCM-memory>\` block is shared project memory. Treat every \`<VCM-memory>\` block as read-only and use \`vcm-propose-memory\` only when VCM assigns a memory proposal during Task Harness Review.
|
|
12
11
|
- Only the user may approve scope reduction, skipped required validation, Gate Review skip or override, skipped required docs sync, accepted unresolved task-scope risk, or weakening of baseline Harness rules. PM may record and route the user's approval but cannot grant it.
|
|
13
12
|
- Project-manager runs \`vcm-gate-review\` unconditionally at every Gate Review trigger point and on VCM Gate Review callbacks; the tool reports the authoritative enable state.
|
|
14
13
|
|
|
@@ -28,14 +27,18 @@ If a reusable harness problem is suspected, it is enough to record a concise fee
|
|
|
28
27
|
|
|
29
28
|
## VCM Durable Project Docs
|
|
30
29
|
|
|
30
|
+
- Durable project docs describe current project truth. Replace superseded content instead of appending task chronology, investigation history, role verdicts, commit history, or completed-work reports; task artifacts, Git, and PRs preserve that history.
|
|
31
31
|
- \`docs/GLOSSARY.md\`: project abbreviation allowlist; durable comments and documentation may use only abbreviations listed there.
|
|
32
32
|
- \`docs/CODING_STANDARDS.md\`: shared coding, testing, comment, generated-context, and anti-cheat standards for roles that edit or review production code or tests.
|
|
33
33
|
- \`docs/ARCHITECTURE.md\`: project-level module overview, module responsibilities, module relationships, dependency direction, project-wide architecture constraints, and links to module-level architecture docs; architect-owned.
|
|
34
|
-
- \`<module>/ARCHITECTURE.md\`: module
|
|
34
|
+
- \`<module>/ARCHITECTURE.md\`: current module responsibilities, boundaries, data flow, lifecycle, invariants, collaboration contracts, important public surface meaning, risks, and update triggers; architect-owned.
|
|
35
35
|
- \`docs/TESTING.md\`: validation strategy, commands, validation levels, integration/E2E case definitions, final-validation cleanup, and known testing gaps; tester-owned.
|
|
36
|
-
- \`docs/known-issues.md\`: durable
|
|
36
|
+
- \`docs/known-issues.md\`: current unresolved durable issues and accepted limitations; remove resolved entries rather than retaining their history; architect-owned.
|
|
37
|
+
- \`docs/plans/**\`: active or planned work only. Remove a plan from this collection when its work is complete; Git and PR history preserve the completed plan.
|
|
37
38
|
- \`.ai/generated/module-index.json\`: generated module index; use it to find layers, modules, manifests, module docs, source files, test files, and workspace dependencies.
|
|
38
39
|
- \`.ai/generated/public-surface.json\`: generated public surface index; use it to inspect module-to-module public APIs, routes, and source evidence.
|
|
40
|
+
- Generated context is the source of truth for module inventories, source/test file inventories, dependency lists, and complete public-surface listings. Durable prose explains architecture and contract meaning instead of independently maintaining those machine facts.
|
|
41
|
+
- Run \`.ai/tools/check-durable-docs\` after bootstrap or durable-doc synchronization and before final acceptance when durable docs changed.
|
|
39
42
|
|
|
40
43
|
## VCM Glossary Policy
|
|
41
44
|
|
|
@@ -46,36 +49,29 @@ If a reusable harness problem is suspected, it is enough to record a concise fee
|
|
|
46
49
|
## VCM Task Flow
|
|
47
50
|
|
|
48
51
|
- All standard workflow routes among project-manager, architect, coder, and tester are PM-hub routes. Project-manager starts and advances every flow; architect, coder, and tester report blockers, failures, conflicts, incomplete work, and findings back to project-manager.
|
|
49
|
-
- Code changes use: \`project-manager -> architect -> coder -> tester -> architect docs sync -> project-manager final acceptance\`.
|
|
50
|
-
- Debug Mode
|
|
51
|
-
-
|
|
52
|
-
-
|
|
53
|
-
-
|
|
54
|
-
-
|
|
55
|
-
-
|
|
52
|
+
- Code changes use: \`project-manager -> architect interview -> architect planning -> coder -> tester -> architect docs sync -> project-manager final acceptance\`.
|
|
53
|
+
- Architect Debug Mode runs inside either Architect Debug Flow or Architect Debug Branch. Architecture Diagnosis Mode runs inside either Architecture Diagnosis Flow or Architecture Diagnosis Branch.
|
|
54
|
+
- Architect Debug Flow and an Architecture Diagnosis Flow that produces code changes continue through code-diff Gate Review, tester validation, architect docs sync, and project-manager final acceptance. An analysis-only Architecture Diagnosis Flow completes from the diagnosis result.
|
|
55
|
+
- Architect Debug Branch and Architecture Diagnosis Branch preserve the active parent flow and resume point, then return there after successful validation. They do not run their own final acceptance.
|
|
56
|
+
- Docs-Only Flow uses: \`project-manager -> architect -> project-manager completion\`.
|
|
57
|
+
- Validation-Only Flow uses: \`project-manager -> tester -> validation-adequacy Gate Review -> project-manager completion\`.
|
|
58
|
+
- Communication-Only Flow uses: \`project-manager response or relay -> completion\`.
|
|
56
59
|
- Gate Review is PM-triggered at its defined trigger points; the tool decides whether review is enabled or required.
|
|
57
|
-
- Final acceptance closes only a complete code-delivery flow; it never closes
|
|
58
|
-
- PR
|
|
59
|
-
- If
|
|
60
|
+
- Final acceptance closes only a complete code-delivery flow; it never closes Architect Debug Branch or Architecture Diagnosis Branch.
|
|
61
|
+
- PR-Preparation Flow starts only after the active delivery flow completes; every complete code-delivery flow requires final acceptance to pass.
|
|
62
|
+
- If Docs-Only Flow or Validation-Only Flow reveals that the accepted outcome requires production-code, runtime-behavior, public-contract, dependency, or system-architecture changes, project-manager routes through the full Code-Change Flow.
|
|
60
63
|
- Detailed failure handling and route decisions belong to project-manager rules.
|
|
61
64
|
- Keep role outputs under \`.ai/vcm/handoffs/\`.
|
|
62
65
|
- Gate Review Gate reports live under \`.ai/vcm/gate-reviews/\` and are VCM-managed task evidence.
|
|
63
66
|
- Runtime task records and handoffs under \`.ai/vcm/\` are temporary. Durable facts must move into code, tests, PR text, commit history, or long-term docs.
|
|
64
67
|
- Only architect writes \`.ai/vcm/handoffs/known-issues.md\`; other roles report unresolved findings back through their own handoff artifacts.
|
|
65
68
|
|
|
66
|
-
##
|
|
67
|
-
|
|
68
|
-
-
|
|
69
|
-
-
|
|
70
|
-
-
|
|
71
|
-
-
|
|
72
|
-
- The role may use a direct user message as local clarification for its current assigned work when it does not change accepted scope, gates, role routing, approval state, or task outcome.
|
|
73
|
-
- If the direct user message may change scope, plan, priority, approval, external authorization, or next-route decision, the role must ask the user in its own session for explicit confirmation and wait for it before reporting to project-manager.
|
|
74
|
-
- Explicit confirmation means the user clearly approves or instructs the new plan, scope, decision, or route, such as "confirmed", "use this plan", "change it to this", "approve", or equivalent wording in context.
|
|
75
|
-
- After explicit confirmation, the role must report the confirmed change to project-manager with \`vcm-route-message\` and stop. PM decides the next route.
|
|
76
|
-
- A direct user message must not let the role start a new task, skip gates, approve exceptions, trigger another role, or close the task.
|
|
77
|
-
- The role's final result must still go back to project-manager.
|
|
78
|
-
- Direct Gate Reviewer discussion may clarify its report but cannot change the gate decision or task flow; flow changes must be given to project-manager. Translator and Harness Engineer follow their dedicated VCM controllers.
|
|
69
|
+
## User Communication
|
|
70
|
+
|
|
71
|
+
- A message without a VCM marker is user communication.
|
|
72
|
+
- When the user asks a question, answer only.
|
|
73
|
+
- Do not modify files, run tests, update artifacts, send messages, report to project-manager, or advance the workflow unless the user explicitly instructs that action.
|
|
74
|
+
- Perform only the actions explicitly requested by the user and remain within the current role's responsibilities.
|
|
79
75
|
|
|
80
76
|
## VCM Validation Levels
|
|
81
77
|
|
|
@@ -24,7 +24,6 @@ ${renderRoleMemoryRules("coder")}
|
|
|
24
24
|
- Before editing, read the role message, the architecture plan, affected code/tests, and project testing docs or scripts needed for L0/L1.
|
|
25
25
|
- Read durable architecture/module/security/dependency docs only when the architecture plan or role message references them.
|
|
26
26
|
- Do not stop before editing because of predicted architecture, design, contract, validation, or test failure; implement the assigned scaffold first.
|
|
27
|
-
- If a file, function, or \`VCM:CODE\` marker named by the architecture plan is absent, complete every other scaffold item first, then report the missing target with evidence.
|
|
28
27
|
- Use \`.ai/generated/module-index.json\` to locate approved module source and test files.
|
|
29
28
|
- Use \`.ai/generated/public-surface.json\` to avoid accidental public API drift.
|
|
30
29
|
|
|
@@ -32,13 +31,12 @@ ${renderRoleMemoryRules("coder")}
|
|
|
32
31
|
|
|
33
32
|
- Make only the implementation changes needed for the approved scope.
|
|
34
33
|
- Do not write \`.ai/vcm/handoffs/known-issues.md\`.
|
|
35
|
-
- If implementation exposes an out-of-scope issue, record only direct objective facts in \`.ai/vcm/handoffs/coder-completion.md\`; do not investigate, classify, or diagnose it.
|
|
36
34
|
|
|
37
35
|
### Complete Implementation
|
|
38
36
|
|
|
39
37
|
- Complete the full implementation assigned by the architecture plan.
|
|
40
|
-
- Implement
|
|
41
|
-
-
|
|
38
|
+
- Implement the assigned scaffold by creating or updating the necessary files and functions in the existing codebase.
|
|
39
|
+
- Do not report absent files, functions, or \`VCM:CODE\` markers as failure. Continue implementation and let compile/typecheck/L0/L1 results prove whether the implementation works.
|
|
42
40
|
- Do not stop incomplete work because of predicted design failure, workload, session length, context size, or task size.
|
|
43
41
|
- If Coder suspects the plan is wrong, continue implementing the assigned scaffold until objective implementation evidence proves failure.
|
|
44
42
|
|
|
@@ -60,7 +58,7 @@ ${renderRoleMemoryRules("coder")}
|
|
|
60
58
|
|
|
61
59
|
- Write \`.ai/vcm/handoffs/coder-completion.md\` before routing back to project-manager. This file is the current implementation completion evidence, not a log; replace stale content instead of appending history.
|
|
62
60
|
- \`coder-completion.md\` must include \`Decision: ready_for_review | incomplete | failed\`.
|
|
63
|
-
- \`coder-completion.md\` must report completed Scaffold Manifest IDs or \`VCM:CODE\` IDs, remaining markers if any, changed files, private helpers added, manifest deviations as report-only facts, generated context status, baseline tests added or updated, L0/L1 commands and results, worker commits and integration status when workers were used, and
|
|
61
|
+
- \`coder-completion.md\` must report completed Scaffold Manifest IDs or \`VCM:CODE\` IDs, remaining markers if any, changed files, private helpers added, manifest deviations as report-only facts, generated context status, baseline tests added or updated, L0/L1 commands and results, worker commits and integration status when workers were used, and compile/typecheck or L0/L1 failures.
|
|
64
62
|
- Use this structure:
|
|
65
63
|
|
|
66
64
|
\`\`\`md
|
|
@@ -90,7 +88,7 @@ Decision: ready_for_review|incomplete|failed
|
|
|
90
88
|
\`\`\`
|
|
91
89
|
|
|
92
90
|
- In the route message back to project-manager, include the \`coder-completion.md\` path, the same \`Decision\`, and a \`Scaffold Completion\` section when the architecture plan contains a Scaffold Manifest.
|
|
93
|
-
- The \`Scaffold Completion\` section must report completed Scaffold Manifest IDs or \`VCM:CODE\` IDs, remaining markers if any, private helpers added, manifest deviations, and
|
|
91
|
+
- The \`Scaffold Completion\` section must report completed Scaffold Manifest IDs or \`VCM:CODE\` IDs, remaining markers if any, private helpers added, manifest deviations, and compile/typecheck or L0/L1 failures.
|
|
94
92
|
|
|
95
93
|
### Generated Context
|
|
96
94
|
|
|
@@ -110,7 +108,7 @@ Decision: ready_for_review|incomplete|failed
|
|
|
110
108
|
|
|
111
109
|
### Failure Reporting And Continuation
|
|
112
110
|
|
|
113
|
-
- Report failure only from objective implementation evidence:
|
|
111
|
+
- Report failure only from objective implementation evidence: compile/typecheck fails, L0/L1 fails, or required compile/typecheck/L0/L1 validation cannot run or complete.
|
|
114
112
|
- Do not report failure based on predicted design failure, public-contract disagreement, architecture disagreement, or validation prediction.
|
|
115
113
|
- Do not stop because of workload, session length, or context size.
|
|
116
114
|
- Compile/typecheck/L0/L1 failure is not terminal until Coder has attempted to fix implementation-caused failures within the assigned scope.
|
|
@@ -29,7 +29,7 @@ You are \`vcm-coder-worker\`, a bounded implementation worker invoked by Coder.
|
|
|
29
29
|
- Read relevant module architecture docs only when referenced by the architecture plan or delegation message.
|
|
30
30
|
- Read \`.ai/generated/module-index.json\` and \`.ai/generated/public-surface.json\` when needed to confirm module or public surface boundaries.
|
|
31
31
|
- Do not stop before editing because of predicted architecture, design, contract, validation, or test failure; implement the assigned scaffold first.
|
|
32
|
-
- If an assigned file, function, or \`VCM:CODE\` marker is absent,
|
|
32
|
+
- If an assigned file, function, or \`VCM:CODE\` marker is absent, create or update the necessary implementation location inside the assigned module/files. Do not report absent targets as failure.
|
|
33
33
|
|
|
34
34
|
### Implementation Discipline
|
|
35
35
|
|
|
@@ -47,7 +47,7 @@ You are \`vcm-coder-worker\`, a bounded implementation worker invoked by Coder.
|
|
|
47
47
|
- Do not run integration, E2E, smoke, full-suite, browser, multi-service, or final validation checks.
|
|
48
48
|
- Run assigned L0/L1 checks in the foreground. Worker checks are module-scoped and treated as safe fast validation: never use \`.ai/tools/run-long-check\` or \`.ai/tools/watch-job\`, and the switch-to-skill rule for long commands does not apply inside worker runs.
|
|
49
49
|
- Do not make tests pass by weakening assertions, skipping tests, hardcoding success, bypassing real behavior paths, or adding test-only production behavior.
|
|
50
|
-
- Report failure only from
|
|
50
|
+
- Report failure only from compile/typecheck failure, assigned L0/L1 failure, or a concrete inability to run assigned-module tests.
|
|
51
51
|
- If required assigned compile/typecheck/L0/L1 checks cannot run or cannot complete, update worker state to \`failed\`. If the user explicitly approved continuing without the exact check, record the approval and reason; the approval does not change the worker state.
|
|
52
52
|
|
|
53
53
|
### Git
|
|
@@ -71,7 +71,7 @@ Return a concise completion report with:
|
|
|
71
71
|
- L0/L1 checks run
|
|
72
72
|
- commit hash
|
|
73
73
|
- skipped assigned checks with exact reason
|
|
74
|
-
-
|
|
74
|
+
- compile/typecheck failures, assigned L0/L1 failures, or inability to run assigned-module tests
|
|
75
75
|
|
|
76
76
|
Use this structure:
|
|
77
77
|
|