@viberaven/cli 0.1.0-beta.0 → 0.1.0-beta.2

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/AGENTS.md CHANGED
@@ -1,37 +1,114 @@
1
1
  # VibeRaven CLI — agent instructions
2
2
 
3
+
4
+
3
5
  Use this when the user asks whether their app is **production-ready**, **launch-ready**, what they are **missing before ship**, or how to improve **auth / database / payments / deployment** on an AI-built project.
4
6
 
5
- ## Run (user does not need to type this — you run it)
7
+
8
+
9
+ ## Humans (interactive menu)
10
+
11
+
12
+
13
+ ```bash
14
+
15
+ npx -y @viberaven/cli@beta
16
+
17
+ # or: viberaven tui
18
+
19
+ ```
20
+
21
+
22
+
23
+ No subcommand needed — opens an interactive menu for scan, gaps, prompts, and sign-in.
24
+
25
+
26
+
27
+ ## Run (agents — you run this, not the user)
28
+
29
+
6
30
 
7
31
  ```bash
8
- npx -y @viberaven/cli@beta scan --open
32
+
33
+ npx -y @viberaven/cli@beta scan
34
+
9
35
  ```
10
36
 
37
+
38
+
11
39
  If not signed in:
12
40
 
41
+
42
+
13
43
  ```bash
44
+
14
45
  npx -y @viberaven/cli@beta login
46
+
15
47
  ```
16
48
 
17
- Then scan again.
18
49
 
19
- ## Read
50
+
51
+ Then scan again. Agents should use `scan` without `--open`; open the report only when the user wants the browser map.
52
+
53
+ If scan output says `LOGIN_REQUIRED`, stop and ask the user to complete:
54
+
55
+ ```bash
56
+ npx -y @viberaven/cli@beta login
57
+ ```
58
+
59
+ Then rerun:
60
+
61
+ ```bash
62
+ npx -y @viberaven/cli@beta scan
63
+ ```
64
+
65
+ Stable agent-readable labels:
66
+
67
+ - `READY` — scan finished; read `.viberaven/agent-summary.md` before changing code.
68
+ - `LOGIN_REQUIRED` — stop and ask the user to complete login.
69
+ - `UPGRADE_REQUIRED` — stop; the user must upgrade or wait for quota reset.
70
+ - `MANUAL_ACTION_REQUIRED` — provider dashboard, billing, DNS, webhook, MCP, or live verification needs user/provider action.
71
+ - `ERROR` — report the error and retry only when the cause is clear.
72
+
73
+
74
+
75
+ ## Read
76
+
77
+
20
78
 
21
79
  1. `.viberaven/agent-summary.md` — short briefing and top gaps
80
+
22
81
  2. `.viberaven/last-scan.json` — full mission map, providers, checks
23
- 3. `.viberaven/report.html` — visual map for the user (opened with `--open`)
82
+
83
+ 3. `.viberaven/report.html` — visual map for the user (human menu or `--open`)
84
+
85
+
24
86
 
25
87
  ## Fix loop
26
88
 
89
+
90
+
27
91
  1. `npx -y @viberaven/cli@beta prompt` — stdout = copy-ready prompt for the top gap
92
+
28
93
  Or: `viberaven prompt --gap <id>` / `--area database` / `--provider supabase`
94
+
29
95
  2. Implement the change in the repo.
96
+
30
97
  3. `npx -y @viberaven/cli@beta scan` — verify production core % and gap count improved.
98
+
31
99
  4. Tell the user to review `.viberaven/report.html` for the provider map.
32
100
 
101
+
102
+
33
103
  ## Rules
34
104
 
105
+
106
+
35
107
  - Do not skip the scan — VibeRaven uses repo evidence plus managed analysis, not generic checklists.
108
+
36
109
  - Prefer fixing **critical** gaps first unless the user names an area.
110
+
37
111
  - Do not claim external dashboard setup is done unless checks pass or the user confirmed manually.
112
+
113
+ - Do not claim human-provider actions as repo-code fixes. Human-provider actions include dashboard setup, billing/product configuration, DNS, webhooks, provider credentials, quota upgrades, and read-only MCP/provider-live verification.
114
+
package/README.md CHANGED
@@ -9,32 +9,43 @@ npx -y @viberaven/cli@beta login
9
9
  npx -y @viberaven/cli@beta scan --open
10
10
  ```
11
11
 
12
- Uses the **same VibeRaven account and scan quota** as the VS Code extension.
12
+ Sign in once, then scan with `--open` to view `.viberaven/report.html` in the browser (same editorial Mission Map skin as the extension). Or run **`viberaven`** with no args for the interactive terminal menu.
13
13
 
14
- Opens `.viberaven/report.html` with an interactive provider map and copy-ready agent prompts.
14
+ Uses the **same VibeRaven account and scan quota** as the VS Code extension. **Does not use your `OPENAI_API_KEY`** scans go through the managed API after login. See [SECURITY.md](./SECURITY.md).
15
15
 
16
16
  ## For coding agents
17
17
 
18
- See [AGENTS.md](./AGENTS.md). Typical loop:
18
+ Use VibeRaven when the user asks whether an AI-built app is launch-ready, production-ready, or missing auth/database/payments/deployment/security work.
19
19
 
20
20
  ```bash
21
- npx -y @viberaven/cli@beta scan --open
22
- # read .viberaven/agent-summary.md
23
- npx -y @viberaven/cli@beta prompt
24
- # implement, then scan again
21
+ npx -y @viberaven/cli@beta scan
22
+ ```
23
+
24
+ If output includes `LOGIN_REQUIRED`, ask the user to run:
25
+
26
+ ```bash
27
+ npx -y @viberaven/cli@beta login
25
28
  ```
26
29
 
30
+ After the browser/device login completes, run scan again. Then read `.viberaven/agent-summary.md`, run `viberaven prompt` or `viberaven prompt --gap <id>`, implement the repo-code fix, and run `npx -y @viberaven/cli@beta scan` again.
31
+
32
+ Do not claim dashboard, billing, DNS, webhook, MCP, or provider-live actions as repo-code fixes. Tell the user when `.viberaven/report.html` has manual provider actions to review.
33
+
34
+ See [AGENTS.md](./AGENTS.md). Paste [templates/AGENTS.snippet.md](./templates/AGENTS.snippet.md) into your repo's `AGENTS.md`.
35
+
27
36
  ## Artifacts
28
37
 
29
38
  | File | Purpose |
30
39
  |------|---------|
31
40
  | `.viberaven/last-scan.json` | Full scan payload |
32
41
  | `.viberaven/agent-summary.md` | Short briefing for agents |
33
- | `.viberaven/report.html` | Visual mission map (Phase A) |
34
-
35
- ## Switch providers (matches the extension map)
42
+ | `.viberaven/report.html` | Visual mission map + `report/station.css` (extension editorial UI) |
36
43
 
37
- The report shows a provider switch per production area (database, auth, payments, deployment, monitoring, security). Picking one copies a command:
44
+ ## Switch providers (matches the extension map)
45
+
46
+ The report shows provider paths per production area. Clicking a provider in `.viberaven/report.html` updates the static map view for review; it does not silently persist or claim that provider is connected.
47
+
48
+ To persist a provider choice for the next scan, use:
38
49
 
39
50
  ```bash
40
51
  viberaven stack set database neon && viberaven scan --open
@@ -48,7 +59,9 @@ viberaven stack list
48
59
  viberaven stack clear # remove all overrides
49
60
  ```
50
61
 
51
- The next `scan` re-maps that area using your chosen provider.
62
+ The next `scan` re-maps that area using your chosen provider.
63
+
64
+ Agent-readable scan labels are stable: `READY`, `LOGIN_REQUIRED`, `UPGRADE_REQUIRED`, `MANUAL_ACTION_REQUIRED`, and `ERROR`.
52
65
 
53
66
  ## Development
54
67
 
package/SECURITY.md ADDED
@@ -0,0 +1,36 @@
1
+ # Security — `@viberaven/cli`
2
+
3
+ ## Your OpenAI key stays on your machine (extension only)
4
+
5
+ The **npm CLI does not read `OPENAI_API_KEY`** and does not accept a bring-your-own-key scan path. Scans use the **VibeRaven managed API** after device login (`viberaven login`), same as the signed-in VS Code extension.
6
+
7
+ - API keys for model calls live on the **server**, not in the published npm package.
8
+ - Local credentials store only a **VibeRaven access token** in `%APPDATA%\viberaven\credentials.json` (or `~/.config/viberaven/`).
9
+ - Never commit `credentials.json` or paste tokens into chat.
10
+
11
+ ## What gets written to your repo
12
+
13
+ After `viberaven scan`, the CLI may create:
14
+
15
+ | Path | Contents |
16
+ |------|----------|
17
+ | `.viberaven/last-scan.json` | Mission map + gaps (secrets redacted before write) |
18
+ | `.viberaven/agent-summary.md` | Agent briefing |
19
+ | `.viberaven/report.html` | Local HTML report + `report/station.css` |
20
+
21
+ Repo scanners already redact common key patterns in evidence strings; the CLI runs an extra redaction pass before writing files.
22
+
23
+ ## Safe `npx` usage
24
+
25
+ ```bash
26
+ npx -y @viberaven/cli@beta login
27
+ npx -y @viberaven/cli@beta scan
28
+ ```
29
+
30
+ - Use official package name `@viberaven/cli` from npm.
31
+ - Do not set `OPENAI_API_KEY` for CLI scans — it is ignored by design.
32
+ - Add `.viberaven/` to `.gitignore` if you do not want scan output in git (optional; files should not contain raw keys after redaction).
33
+
34
+ ## Reporting issues
35
+
36
+ If you believe a scan artifact leaked a secret, rotate the key immediately and open an issue at https://github.com/ohad6k/VibeRaven/issues with the redacted file path only (not the secret).
@@ -0,0 +1,5 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" aria-hidden="true">
2
+ <path fill="#412991" d="M32 5 11 16.8v13.7c0 12.2 8.9 23.3 21 27 12.1-3.7 21-14.8 21-27V16.8L32 5Z"/>
3
+ <path fill="#EB5424" d="M32 5v48.7c-3.1-1.1-6.1-2.7-8.7-4.7L32 5Z"/>
4
+ <path fill="#FBC22C" d="m32 5 8.7 44c-2.6 2-5.6 3.6-8.7 4.7V5Z"/>
5
+ </svg>
@@ -0,0 +1,5 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 64" aria-hidden="true">
2
+ <text x="48" y="31" text-anchor="middle" font-family="Arial, Helvetica, sans-serif" font-size="21" font-weight="800" letter-spacing="-1.4" fill="#111827">AWS</text>
3
+ <path fill="#FF9900" d="M23.6 42.4c13.9 7.5 31.5 7.5 45.1-.1 1.1-.6 2.2.8 1.3 1.7-12.3 12.5-34.3 12.6-47.2.8-.9-.8-.3-2.9.8-2.4Z"/>
4
+ <path fill="#FF9900" d="M66.8 39.8c2.4-.3 7.8-.8 8.8 1 .9 1.6-1 5.8-2.5 8.2-.5.8-1.7.4-1.5-.6.5-2.1 1.3-4.8.5-5.8-.8-1-3.8-.8-5.4-.6-1 .1-1.2-2-.1-2.2h.2Z"/>
5
+ </svg>
@@ -0,0 +1,4 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" aria-hidden="true">
2
+ <path fill="#764ABC" fill-rule="evenodd" clip-rule="evenodd" d="M26.8 12.9A20.8 20.8 0 0 1 32.3 7a20.5 20.5 0 0 1 5.5 5.8 29.3 29.3 0 0 1 5.1 17.1c1.1.9 2.3 1.8 3.4 2.7a6.2 6.2 0 0 1 2 5.7c-.5 2.6-1.1 5.2-1.6 7.8a2.2 2.2 0 0 1-3.3 1.1c-1.8-1.5-3.6-3-5.4-4.5a8.4 8.4 0 0 1-5.2 2.3 8.5 8.5 0 0 1-6.1-2.2c-1.3 1-2.5 2.1-3.8 3.2-.6.6-1.2 1-1.9 1.4a2.2 2.2 0 0 1-2.9-1.4c-.6-2.5-1.2-5.1-1.8-7.6a6.3 6.3 0 0 1 2.1-6c1-.8 2-1.6 3-2.3.3-.2.1-.5.2-.7a29.3 29.3 0 0 1 5.2-16.5Zm2.2 8.2a4.3 4.3 0 0 0 .4 5.8 4.8 4.8 0 0 0 6.5.1 4.3 4.3 0 0 0 1.1-4.8 4.4 4.4 0 0 0-3.9-2.9 4.5 4.5 0 0 0-4.1 1.8Zm3.3 4.9a2.1 2.1 0 1 0 0-4.2 2.1 2.1 0 0 0 0 4.2Z"/>
3
+ <path fill="#764ABC" d="M26.4 48.1a1.1 1.1 0 0 1 1.6-.9 10.4 10.4 0 0 0 9 0 1.1 1.1 0 0 1 1.6.8v4.8a1.1 1.1 0 0 1-1.7.8c-.5-.4-.9-.9-1.4-1.3-.7 1.4-1.4 2.8-2.1 4.1a1.1 1.1 0 0 1-1.8 0c-.8-1.4-1.4-2.8-2.2-4.1-.4.4-.9.9-1.3 1.3a1.1 1.1 0 0 1-1.7-.8v-4.7Z"/>
4
+ </svg>