@vibecompass/vibecompass 0.3.4 → 0.4.0
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 +166 -9
- package/package.json +1 -1
- package/src/cli.js +263 -0
- package/src/compatibility.js +308 -0
- package/src/index.js +5 -1
- package/src/init.js +42 -2
- package/src/manifest.js +16 -4
- package/src/read-model.js +17 -1
- package/src/refresh-workflow.js +233 -0
- package/src/scaffold.js +38 -18
- package/src/setup.js +251 -0
- package/src/status.js +350 -0
- package/src/version.js +6 -0
package/README.md
CHANGED
|
@@ -25,24 +25,27 @@ Shipped today:
|
|
|
25
25
|
- `vibecompass list-sessions` / `vibecompass switch-session` for multiple active session lanes
|
|
26
26
|
- `vibecompass end-session` as a discoverable alias for `close-session`
|
|
27
27
|
- `vibecompass sync-agents` for generated `CLAUDE.md`, `AGENTS.md`, `.cursorrules`, and `.github/copilot-instructions.md` views
|
|
28
|
+
- `vibecompass status` for a read-only project-memory health and drift report
|
|
29
|
+
- `vibecompass refresh-workflow` for explicit dry-run/apply refresh of package-owned derived workflow files
|
|
28
30
|
- `vibecompass docs-review --guided` — print a comprehensive review prompt for your chosen LLM to run
|
|
29
31
|
- `vibecompass docs-review --submit-hosted` — submit the review request to the hosted app and poll for proposal/artifact output
|
|
30
32
|
- `vibecompass docs-review --run-local --provider anthropic` — local provider adapter that saves review output locally
|
|
31
33
|
- `vibecompass docs-review --apply-output` — apply accepted architecture-doc blocks into canonical `architecture/` docs
|
|
32
34
|
- `vibecompass docs-review --complete` — mark the review accepted after the docs land
|
|
35
|
+
- hosted sync commands: `push`, `pull-preview`, `pull-export`, and `apply-export`
|
|
33
36
|
- canonical file scanning and validation
|
|
34
37
|
- `state/manifest.json` generation
|
|
35
38
|
- JavaScript read-model helpers for project, feature, decision, and file context
|
|
36
39
|
|
|
37
40
|
Not shipped yet:
|
|
38
41
|
|
|
39
|
-
- hosted
|
|
40
|
-
- hosted docs-review execution that runs the review and writes canonical docs
|
|
42
|
+
- one-command hosted docs-review that directly writes canonical local docs
|
|
41
43
|
- additional local docs-review providers beyond Anthropic
|
|
42
44
|
- automatic acceptance of review findings without a local apply step
|
|
43
45
|
|
|
44
|
-
The package is
|
|
45
|
-
|
|
46
|
+
The package is useful today as the local project-memory CLI and JavaScript
|
|
47
|
+
core. Use it to create a root, keep project memory current, run local sessions,
|
|
48
|
+
and sync with hosted VibeCompass when you have a hosted project binding.
|
|
46
49
|
|
|
47
50
|
## Requirements
|
|
48
51
|
|
|
@@ -67,7 +70,7 @@ npm install @vibecompass/vibecompass
|
|
|
67
70
|
|
|
68
71
|
## Quickstart
|
|
69
72
|
|
|
70
|
-
|
|
73
|
+
Most users should start with the guided bootstrap:
|
|
71
74
|
|
|
72
75
|
```bash
|
|
73
76
|
npx -y @vibecompass/vibecompass init --guided
|
|
@@ -78,6 +81,18 @@ Guided init asks about repo topology, recommends a placement pattern
|
|
|
78
81
|
lightweight starter project memory, scaffolds the workflow files you opt into,
|
|
79
82
|
and can open the first builder session immediately.
|
|
80
83
|
|
|
84
|
+
After init, the usual loop is:
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
npx -y @vibecompass/vibecompass status --root .compass
|
|
88
|
+
npx -y @vibecompass/vibecompass start-session --root .compass --id feature-lane --working-on "Build the next feature"
|
|
89
|
+
npx -y @vibecompass/vibecompass docs-review --root .compass --guided
|
|
90
|
+
npx -y @vibecompass/vibecompass close-session --root .compass --session feature-lane --title "Feature Lane" --completed "Shipped the slice" --next-step "Review and publish"
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Run `vibecompass status` when you are not sure what to do next. It is
|
|
94
|
+
read-only and prints the safest follow-up commands for the current root.
|
|
95
|
+
|
|
81
96
|
When the owner directory is a workspace root or primary repo, the canonical
|
|
82
97
|
root defaults to `.compass/` inside that directory. For a dedicated memory repo,
|
|
83
98
|
the canonical root defaults to the repo root itself.
|
|
@@ -130,6 +145,34 @@ AGENTS.md # at the tooling root, only if missing and --with-agents is
|
|
|
130
145
|
`context.md` is a derived package-owned file. Re-running `init --force --with-workflow`
|
|
131
146
|
regenerates it; do not treat it as a hand-edited source document.
|
|
132
147
|
|
|
148
|
+
Check an initialized root without writing files:
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
npx -y @vibecompass/vibecompass status --root .compass
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
Use `status --json` when another tool needs the typed diagnostic model. The
|
|
155
|
+
JSON output intentionally excludes raw hosted preview tokens and resolved
|
|
156
|
+
credential values.
|
|
157
|
+
|
|
158
|
+
Preview package-owned workflow refreshes without mutating files:
|
|
159
|
+
|
|
160
|
+
```bash
|
|
161
|
+
npx -y @vibecompass/vibecompass refresh-workflow --root .compass --dry-run
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
Apply the refresh explicitly when the plan looks right:
|
|
165
|
+
|
|
166
|
+
```bash
|
|
167
|
+
npx -y @vibecompass/vibecompass refresh-workflow --root .compass --apply
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
`refresh-workflow` updates generated workflow artifacts such as `context.md`,
|
|
171
|
+
workflow guide READMEs, managed agent-file blocks, and the local
|
|
172
|
+
`state/manifest.json`. Existing package-version stamps are sticky by default;
|
|
173
|
+
pass `--update-package-stamp` when you intentionally want to move the
|
|
174
|
+
canonical `project.yaml.metadata.package_version` stamp to the current CLI.
|
|
175
|
+
|
|
133
176
|
## After init: generate real architecture docs
|
|
134
177
|
|
|
135
178
|
`init` writes a small starter map of your project. To turn it into real
|
|
@@ -336,6 +379,7 @@ Options:
|
|
|
336
379
|
- `--close-session-git-publish`: store that the close-session workflow includes a Git publish step
|
|
337
380
|
- `--close-session-git-remote <name>`: optional default Git remote name for that stored publish step
|
|
338
381
|
- `--force`: overwrite an existing `project.yaml`
|
|
382
|
+
- `--replace-active-lanes`: allow `--force` to replace a root that has active session lanes
|
|
339
383
|
|
|
340
384
|
When `--start-session` is used, `init` automatically enables the minimum
|
|
341
385
|
workflow bootstrap required for that session: `context.md` plus `CLAUDE.md`.
|
|
@@ -371,6 +415,51 @@ actual token in your environment before running hosted commands.
|
|
|
371
415
|
Running it again replaces the existing hosted binding in `project.yaml`, which
|
|
372
416
|
is the intended rotation path after you create a new sync credential.
|
|
373
417
|
|
|
418
|
+
### `vibecompass status`
|
|
419
|
+
|
|
420
|
+
```text
|
|
421
|
+
vibecompass status [options]
|
|
422
|
+
```
|
|
423
|
+
|
|
424
|
+
Options:
|
|
425
|
+
|
|
426
|
+
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
427
|
+
- `--tooling-root <path>`: directory where agent files are inspected; defaults to cwd
|
|
428
|
+
- `--json`: print the typed status model as JSON
|
|
429
|
+
|
|
430
|
+
`status` is strictly read-only. It reports project identity, active session
|
|
431
|
+
lanes, package-version drift, local manifest compatibility, docs-review
|
|
432
|
+
marker state, generated agent-file drift, warnings, and recommended next
|
|
433
|
+
commands. It does not write canonical files, generated workflow files, agent
|
|
434
|
+
instruction files, or `state/manifest.json`.
|
|
435
|
+
|
|
436
|
+
### `vibecompass refresh-workflow`
|
|
437
|
+
|
|
438
|
+
```text
|
|
439
|
+
vibecompass refresh-workflow [--dry-run|--apply] [options]
|
|
440
|
+
```
|
|
441
|
+
|
|
442
|
+
Options:
|
|
443
|
+
|
|
444
|
+
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
445
|
+
- `--tooling-root <path>`: directory where agent files are refreshed; defaults to cwd
|
|
446
|
+
- `--dry-run`: show planned refresh without changing files; this is the default
|
|
447
|
+
- `--apply`: apply the planned workflow refresh
|
|
448
|
+
- `--update-package-stamp`: update an existing `project.yaml` package-version stamp
|
|
449
|
+
- `--allow-downgrade-templates`: allow applying templates with a CLI older than the root stamp
|
|
450
|
+
|
|
451
|
+
`refresh-workflow` is the explicit upgrade path for package-owned derived
|
|
452
|
+
artifacts. Dry-run mode is read-only. Apply mode can regenerate `context.md`,
|
|
453
|
+
workflow guide READMEs that still match the package-generated shape, managed
|
|
454
|
+
agent-file blocks, and `state/manifest.json`. It leaves user-authored workflow
|
|
455
|
+
guide files untouched when they no longer match the generated guide shape.
|
|
456
|
+
|
|
457
|
+
Package-version stamps are intentionally conservative: missing legacy stamps
|
|
458
|
+
can be created by apply mode, existing older or invalid stamps are left
|
|
459
|
+
untouched unless `--update-package-stamp` is passed, and roots stamped by a
|
|
460
|
+
newer CLI require `--allow-downgrade-templates` before older templates are
|
|
461
|
+
applied.
|
|
462
|
+
|
|
374
463
|
### `vibecompass start-session`
|
|
375
464
|
|
|
376
465
|
```text
|
|
@@ -387,6 +476,9 @@ Options:
|
|
|
387
476
|
- `--repo <id>`: repeatable repo ID for the lane
|
|
388
477
|
- `--claim <path>`: repeatable path claim for overlap warnings
|
|
389
478
|
- `--date <YYYY-MM-DD>`: optional explicit session date
|
|
479
|
+
- `--last-thing-completed <text>`: optional override for the `CLAUDE.md` current-session block
|
|
480
|
+
- `--blockers <text>`: optional current blockers summary
|
|
481
|
+
- `--next-session-should <text>`: optional current-session handoff summary
|
|
390
482
|
|
|
391
483
|
This command updates the `Current session` block in `CLAUDE.md` and creates
|
|
392
484
|
`sessions/active/<lane-id>/session.yaml`, `wip.md`, and `handoff.md` for the
|
|
@@ -404,6 +496,10 @@ vibecompass list-sessions [options]
|
|
|
404
496
|
|
|
405
497
|
Lists active session lanes and marks the current lane.
|
|
406
498
|
|
|
499
|
+
Options:
|
|
500
|
+
|
|
501
|
+
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
502
|
+
|
|
407
503
|
### `vibecompass switch-session`
|
|
408
504
|
|
|
409
505
|
```text
|
|
@@ -412,6 +508,11 @@ vibecompass switch-session <lane-id> [options]
|
|
|
412
508
|
|
|
413
509
|
Changes the current lane in `sessions/active/index.yaml`.
|
|
414
510
|
|
|
511
|
+
Options:
|
|
512
|
+
|
|
513
|
+
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
514
|
+
- `--session <lane-id>`: lane ID; positional ID is also accepted
|
|
515
|
+
|
|
415
516
|
### `vibecompass close-session`
|
|
416
517
|
|
|
417
518
|
```text
|
|
@@ -434,6 +535,8 @@ Options:
|
|
|
434
535
|
- `--model <text>`: optional repeatable model contribution entry
|
|
435
536
|
- `--blocker <text>`: repeatable blocker or open question
|
|
436
537
|
- `--next-step <text>`: repeatable next-session instruction
|
|
538
|
+
- `--last-thing-completed <text>`: optional override for the `CLAUDE.md` completed summary
|
|
539
|
+
- `--next-session-should <text>`: optional override for the `CLAUDE.md` next-session summary
|
|
437
540
|
|
|
438
541
|
This command finalizes the active scratchpad into
|
|
439
542
|
`sessions/YYYY-MM-DD-N-display-title.md`, deletes the closed lane directory
|
|
@@ -464,6 +567,38 @@ memory. It creates missing files with managed markers, replaces existing
|
|
|
464
567
|
managed regions, preserves content outside markers, and warns instead of
|
|
465
568
|
overwriting existing unmarked files unless `--adopt-existing` is supplied.
|
|
466
569
|
|
|
570
|
+
### Hosted sync commands
|
|
571
|
+
|
|
572
|
+
```text
|
|
573
|
+
vibecompass push [options]
|
|
574
|
+
vibecompass pull-preview [options]
|
|
575
|
+
vibecompass pull-export [options]
|
|
576
|
+
vibecompass apply-export [options]
|
|
577
|
+
```
|
|
578
|
+
|
|
579
|
+
Common option:
|
|
580
|
+
|
|
581
|
+
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
582
|
+
|
|
583
|
+
Hosted sync commands require `project.yaml` mode `local-primary`, a
|
|
584
|
+
non-secret `project.yaml.sync` binding, and the token named by
|
|
585
|
+
`sync.credential_env_var` in your environment.
|
|
586
|
+
|
|
587
|
+
`push` sends canonical local project memory to the hosted sync API.
|
|
588
|
+
|
|
589
|
+
`pull-preview` asks hosted sync for pending proposal state without changing
|
|
590
|
+
canonical local files. It records preview metadata in local `state/`. Pass
|
|
591
|
+
`--no-pending-proposals` when you only want remote state and conflict data.
|
|
592
|
+
|
|
593
|
+
`pull-export` exports accepted hosted proposal operations into a local bundle
|
|
594
|
+
under `state/pull-export.json` by default. Use `--proposal <id>` to select
|
|
595
|
+
proposal IDs, `--preview-token <token>` to export from a specific preview, and
|
|
596
|
+
`--output <path>` to choose a different output path under the root.
|
|
597
|
+
|
|
598
|
+
`apply-export` applies a local export bundle to canonical project-memory files
|
|
599
|
+
and records the resulting state. Use `--output <path>` when the export bundle
|
|
600
|
+
is not at the default `state/pull-export.json`.
|
|
601
|
+
|
|
467
602
|
### `vibecompass docs-review`
|
|
468
603
|
|
|
469
604
|
```text
|
|
@@ -475,10 +610,14 @@ Options:
|
|
|
475
610
|
- `--root <path>`: project-memory root; defaults to `.compass`
|
|
476
611
|
- `--guided`: print a comprehensive review prompt for your chosen LLM to run (recommended)
|
|
477
612
|
- `--submit-hosted`: submit the review request to the hosted app
|
|
613
|
+
- `--poll-hosted`: poll a hosted docs-review run and update `state/docs-review.json`
|
|
478
614
|
- `--run-local`: run the generated review request with a local provider
|
|
479
615
|
- `--provider <name>`: local provider for `--run-local`; currently `anthropic`
|
|
480
616
|
- `--run-local-anthropic`: compatibility alias for `--run-local --provider anthropic`
|
|
481
617
|
- `--apply-output`: apply accepted architecture-doc blocks from review output
|
|
618
|
+
- `--apply-decision-artifact`: append an accepted hosted decision artifact locally
|
|
619
|
+
- `--artifact <id>`: artifact ID for `--apply-decision-artifact`
|
|
620
|
+
- `--refresh-index`: also regenerate `decisions/INDEX.md` after applying a decision artifact
|
|
482
621
|
- `--output <path>`: review output path for `--apply-output`; defaults to `state/docs-review-output.md`
|
|
483
622
|
- `--complete`: mark accepted docs-review changes as completed in local state
|
|
484
623
|
- `--llm <name>`: preferred LLM/provider to record for the review (e.g. `claude`, `codex`, `gemini`)
|
|
@@ -500,9 +639,10 @@ Project-mode requirements:
|
|
|
500
639
|
hosted binding, so hosted precedence does not apply when that flag is set.
|
|
501
640
|
|
|
502
641
|
`--submit-hosted` uses `sync.credential_env_var` and records the hosted run
|
|
503
|
-
ID in `state/docs-review.json`.
|
|
504
|
-
artifacts; for `local-primary`
|
|
505
|
-
|
|
642
|
+
ID in `state/docs-review.json`. Use `--poll-hosted` to refresh the run marker.
|
|
643
|
+
Hosted execution creates review proposals and artifacts; for `local-primary`
|
|
644
|
+
roots, local files stay untouched until you pull-preview, export, apply
|
|
645
|
+
locally, and push to confirm the accepted output.
|
|
506
646
|
Missing or stale hosted baselines fail with package-facing next-step guidance
|
|
507
647
|
instead of running model work against the wrong source of truth.
|
|
508
648
|
|
|
@@ -554,19 +694,36 @@ recorded in `project.yaml`.
|
|
|
554
694
|
|
|
555
695
|
```js
|
|
556
696
|
import {
|
|
697
|
+
PACKAGE_VERSION,
|
|
698
|
+
STATE_VERSION,
|
|
557
699
|
initializeProjectMemory,
|
|
700
|
+
inspectProjectCompatibility,
|
|
701
|
+
formatCompatibilityWarnings,
|
|
558
702
|
preflightDocsReview,
|
|
559
703
|
startProjectSession,
|
|
704
|
+
listProjectSessions,
|
|
705
|
+
switchProjectSession,
|
|
560
706
|
closeProjectSession,
|
|
561
707
|
syncAgentInstructionFiles,
|
|
708
|
+
getSupportedAgentFormats,
|
|
709
|
+
getProjectStatus,
|
|
710
|
+
renderStatusText,
|
|
711
|
+
toStatusJson,
|
|
712
|
+
refreshWorkflow,
|
|
562
713
|
scanProjectMemory,
|
|
714
|
+
generateStateManifest,
|
|
715
|
+
prepareStateManifest,
|
|
563
716
|
writeStateManifest,
|
|
717
|
+
pushProjectMemory,
|
|
718
|
+
pullPreviewProjectMemory,
|
|
719
|
+
pullExportProjectMemory,
|
|
720
|
+
applyPullExport,
|
|
564
721
|
loadProjectReadModel,
|
|
565
722
|
getProjectContext,
|
|
566
723
|
getFeatureContext,
|
|
567
724
|
getDecisionLog,
|
|
568
725
|
getFileContext,
|
|
569
|
-
} from "vibecompass";
|
|
726
|
+
} from "@vibecompass/vibecompass";
|
|
570
727
|
```
|
|
571
728
|
|
|
572
729
|
Typical flow:
|