@vibgrate/cli 2026.711.2 → 2026.717.1

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/DOCS.md CHANGED
@@ -76,6 +76,7 @@ For a quick overview, see the [README](./README.md). This document covers everyt
76
76
  - [Security Posture](#security-posture)
77
77
  - [Security Scanners](#security-scanners)
78
78
  - [Service Dependencies](#service-dependencies)
79
+ - [Database Schema](#database-schema)
79
80
  - [Architecture Layers](#architecture-layers)
80
81
  - [Code Quality Metrics](#code-quality-metrics)
81
82
  - [OWASP Category Mapping](#owasp-category-mapping)
@@ -566,7 +567,7 @@ vg ask "<question>"
566
567
 
567
568
  A local ONNX embedding model is downloaded once on first use, then cached and fully offline. Degrades gracefully to lexical-only under `--local` or `--no-semantic`.
568
569
 
569
- > **Semantic search is opt-in.** The embedding backend (`fastembed`, which pulls a native ONNX runtime) is declared as an **optional dependency**: package managers install it by default, but if it's absent — e.g. you installed with `--omit=optional`, or it failed to build on your platform — `vg ask` and `vg embed` transparently fall back to lexical + structural search. Nothing else in the CLI needs it, so `vg build`, `vg show`, `vg impact`, drift reporting, and MCP serving all run without it. If you never use semantic `ask`, you can install lean: `npm i @vibgrate/cli --omit=optional`.
570
+ > **Semantic search is opt-in.** The embedding backend (`fastembed`, which pulls a native ONNX runtime) is declared as an **optional dependency**: package managers install it by default, but if it's absent — e.g. you installed with `--omit=optional`, or it failed to build on your platform — `vg ask` and `vg embed` transparently fall back to lexical + structural search. Nothing else in the CLI needs it, so `vg build`, `vg show`, `vg impact`, drift reporting, and MCP serving all run without it. If you never use semantic `ask`, you can install lean: `npm i @vibgrate/cli --omit=optional`. A host application that bundles the CLI without optional dependencies (Vibgrate for VS Code does this) can supply the backend from its own directory by setting `VIBGRATE_EMBEDDER_PATH` to a folder whose `node_modules` contains `fastembed`; when set, that copy is used first.
570
571
 
571
572
  Before answering, `ask` checks whether files changed since the map was last built and, if so, rebuilds it incrementally first (only the changed files re-parse) — so answers always reflect the code as it is now. The check is stat-based and costs almost nothing when nothing changed; `--no-refresh` opts out.
572
573
 
@@ -1109,6 +1110,7 @@ const config: VibgrateConfig = {
1109
1110
  securityPosture: { enabled: true },
1110
1111
  securityScanners: { enabled: true },
1111
1112
  serviceDependencies: { enabled: true },
1113
+ databaseSchema: { enabled: true },
1112
1114
  },
1113
1115
  };
1114
1116
 
@@ -1164,7 +1166,34 @@ Beyond the core drift score, Vibgrate runs a suite of extended scanners that col
1164
1166
  - Are **read-only** — they never write files or execute project code
1165
1167
  - Run **in parallel** — failures in one scanner never affect the others
1166
1168
  - Can be **individually toggled** in the config
1167
- - Collect **zero sensitive data** — no source code, no secrets, no PII
1169
+ - Collect **zero sensitive data** — no secrets, no PII, and no credentials, even the ones that do open source files (below)
1170
+
1171
+ The core drift score is manifest/lockfile-only. Several extended scanners, and
1172
+ the code graph (`vg build`/`vg map`/`vg share`/`vg serve`), go further and open
1173
+ your source files locally — that is how they work, not an accident:
1174
+
1175
+ | Reads source locally | What it extracts | Keeps raw text? |
1176
+ |---|---|---|
1177
+ | **Code graph** (`vg build`/`vg map`) | Symbol names, call edges, file paths, hubs/areas — the graph itself | No — never a source line, only structural graph facts |
1178
+ | **Code Quality** (`codeQuality`) | Cyclomatic complexity, function length, nesting depth, dead code, "god files" | No — computed metrics only |
1179
+ | **Breaking Change Exposure** (`breakingChangeExposure`) | Import/usage-pattern hit counts for majorly-outdated packages | No — counts only |
1180
+ | **Database Schema** (`databaseSchema`) | Table/model names, column names and types, relation/key flags from SQL/Prisma/Drizzle/TypeORM files | No — never a query, row, or credential |
1181
+ | **UI Purpose** (`uiPurpose`) | Route/nav/title/CTA copy, for feature detection | **Yes** — short evidence samples of the literal UI text are kept locally (never business logic, never a full file) |
1182
+
1183
+ None of this is executed, and **nothing above leaves your machine** unless you
1184
+ run `vg share`/`vg push` or scan with a DSN configured — and even then, what
1185
+ uploads is the computed/structural output in the table above, never a raw
1186
+ source file. Each of these is individually toggleable; set the matching
1187
+ `scanners.<name>.enabled` to `false` (or `scanners: false` for all extended
1188
+ scanners, which does not affect the code graph) if you don't want the read to
1189
+ happen at all. See [Scanner Toggles](#scanner-toggles) above and each
1190
+ scanner's own section below.
1191
+
1192
+ The one exception where code truly leaves your machine is the **remediation
1193
+ agent**: when you ask it to write a fix, it clones your repository into an
1194
+ isolated virtual machine Vibgrate controls, makes the change, and hands you a
1195
+ pull request. That only happens when you ask for it. See
1196
+ [vibgrate.com/subprocessors](https://vibgrate.com/subprocessors) for who processes what.
1168
1197
 
1169
1198
  ### Platform Matrix
1170
1199
 
@@ -1299,6 +1328,30 @@ Maps external service and platform dependencies by detecting SDK packages:
1299
1328
  | Messaging | SQS, SNS, Kafka, BullMQ |
1300
1329
  | Observability | Sentry, DataDog, New Relic |
1301
1330
 
1331
+ ### Database Schema
1332
+
1333
+ Extracts structural database-schema facts across five sources — Prisma
1334
+ (`schema.prisma`), raw SQL migrations (`.sql` files), SQL Server database
1335
+ projects (`.sqlproj`), Drizzle (`pgTable`/`mysqlTable`/`sqliteTable`), and
1336
+ TypeORM (`@Entity()` classes) — merged into one report:
1337
+
1338
+ - Table/model names, per-field name and type, and relation/list/optional/id/unique flags
1339
+ - Enum names and values (Prisma)
1340
+ - Datasource providers (e.g. `postgresql`, `mysql`) — never the connection-string `url`
1341
+ - Files scanned, with a per-project breakdown
1342
+
1343
+ Only structural facts are ever extracted — never a raw source line, a query,
1344
+ or a connection string/credential (any `scheme://user:pass@host` line is
1345
+ stripped as defense in depth even though hand-written SQL rarely embeds one).
1346
+ Reading these facts means opening `.sql`/`.prisma`/ORM source files locally —
1347
+ see the table at the top of this section for how this compares to the code
1348
+ graph and the other scanners that also read source. It's on by default; disable it with
1349
+ `scanners.databaseSchema.enabled: false` in `vibgrate.config.ts` (see
1350
+ [Scanner Toggles](#scanner-toggles)). Like every extended scanner, results
1351
+ only leave your machine when you run `vg push` or scan with a DSN configured
1352
+ — and the models/fields/files arrays are capped before upload so a
1353
+ large-monorepo schema can't balloon the payload.
1354
+
1302
1355
  ### Architecture Layers
1303
1356
 
1304
1357
  Classifies source files into architectural layers and reports drift by layer to make refactors more predictable:
package/README.md CHANGED
@@ -232,8 +232,8 @@ vg vex # generate an OpenVEX document for attestation
232
232
 
233
233
  ## Privacy & offline-first
234
234
 
235
- - No data leaves your machine unless you run `--push` / `vg push`.
236
- - Core graph analysis and drift scoring read manifests and configs**not your source code**.
235
+ - No data leaves your machine unless you run `--push` / `vg push` / `vg share`.
236
+ - Drift scoring reads manifests and configs only. The code graph (`vg build`/`vg map`) and a few extended scanners (code quality, database schema, UI text) read your source **locally** to compute structural facts and metricsnever a raw source line, and never uploaded as-is; see [DOCS.md](./DOCS.md#extended-scanners) for exactly what each one reads.
237
237
  - Works without login and without any SaaS dependency.
238
238
  - `--offline` disables registry/network lookups; `--package-manifest <file>` feeds drift scoring a local version bundle.
239
239
  - `--max-privacy` suppresses local artifact writes and high-context scanners; `--no-local-artifacts` skips writing `.vibgrate/*.json` to disk.
@@ -0,0 +1,6 @@
1
+ export { baselineCommand, runBaseline } from './chunk-WZNIDXZP.js';
2
+ import './chunk-M62BGJMK.js';
3
+ import './chunk-RXP66R2E.js';
4
+ import './chunk-GI6W53LM.js';
5
+ //# sourceMappingURL=baseline-YWGSHCKW.js.map
6
+ //# sourceMappingURL=baseline-YWGSHCKW.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"baseline-SRVG4ZAD.js"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"baseline-YWGSHCKW.js"}