Skip to main content

CLI Documentation

Complete reference for the Vibgrate Command Line Interface — commands grouped by what they do, plus configuration, scanners, CI, and reference guides.

Quick Start

npx @vibgrate/cli scan

no install·Nothing is installed globally — ideal for CI or a one-off scan.

Overview

Commands

Grouped by what each command set is for — pick a set, then open a command.

Drift scoring & supply chain

Scan, score, baseline, report, vulnerabilities, SBOM, and evidence.

All commands (A–Z)

Code graph

Build the map, navigate symbols, impact, tests, and export.

All commands (A–Z)

vg ask

Ask the code map a question using hybrid lexical + structural + semantic search. Returns a budget-bounded context block ready to paste into any AI assistant — fully offline after first use.

vg build

Build or update the code map incrementally. Maps source code into a graph artifact that powers all downstream queries — vg show, vg ask, vg impact, and more.

vg bundle

Build a self-contained, air-gapped bundle — parser grammars, your code map, and the library catalog — so Vibgrate runs with no network at all.

vg drift

What is outdated across your dependencies. Offline by default (inventory plus installed versions); --online queries the registry for the latest, and --fail-on gates CI on version or standards violations.

vg embed

Precompute the semantic index so the next vg ask is instant. Local ONNX model downloaded once into a shared cache — fully offline after first run.

vg export

Export the code map in various formats: JSON, GraphML, Graphviz DOT, Neo4j Cypher, Markdown, HTML, CycloneDX SBOM, or SPDX.

vg facts

Deterministic open facts for a node — contract, invariant, characterization. Epistemic-typed: declared/static through to observed/derived.

vg guide

Cited, relevant standards and practices for a node in your code map — a free pack of guidance attached to the symbol you name.

vg impact

What breaks if you change a node? Deterministic structural blast radius using reverse reachability and decay confidence. With --tests, surfaces exactly the tests to run before shipping.

vg map / vg hubs / vg areas / vg oddities

Map-level insights: overview, most-depended-on hubs, natural code groupings (communities), and surprising cross-area links (architectural smells).

vg path

Show how node A connects to node B — the shortest path in the call graph.

vg savings

A local, privacy-safe report of the tokens and cost saved by querying the code map instead of re-reading files, estimated against a grep baseline over a window you choose.

vg share

Make the code map committable and auto-updating for your team. Installs a pre-commit hook, deterministic merge driver, and .gitignore.

vg show

Explain a single code node: what it is, what it calls, and what calls it. The richest single-node view with callers, callees, and structural metadata.

vg status

Graph freshness, node/edge counts, staleness, and resolver rungs used. Compares the committed graph against the current working tree.

vg tests

Which tests cover a node via call or coverage linkage. --missing shows untested nodes nearby. --run prints (or --exec runs) the minimal command to exercise exactly those tests.

vg tree

The call tree rooted at a node — callees by default, callers with --callers. Depth-bounded and cycle-safe.

vg unknowns

What the code map cannot resolve, ranked by blast radius — so you can see exactly where the graph is incomplete and how much depends on those gaps.

vg watch

Rebuild the code map when source files change (debounced). Useful for long agent sessions and live map freshness without a full rebuild each time.

Configuration

Scanners

Architecture Layers Scanner

Classify source files into architectural layers and detect project archetypes.

Breaking Change Exposure Scanner

Flag packages and patterns known to cause upgrade pain.

Build & Deploy Scanner

Detect CI/CD systems, containerization, and infrastructure-as-code.

Code Quality Scanner

Fast AST-based quality checks for cyclomatic complexity and upgrade friction hotspots.

Database Schema Scanner

Table and column structure from Prisma, SQL migrations, Drizzle, and TypeORM — never a query, a row, or a credential.

Dependency Graph Scanner

Lockfile analysis for duplicate packages, phantom dependencies, and workspace graphs.

Dependency Risk Scanner

Risk classification for deprecated packages, native modules, and platform-specific dependencies.

Extended Scanners Overview

Beyond core drift scoring — platform matrix, dependency graph, security posture, and more.

File Hotspots Scanner

Lightweight complexity analysis using filesystem metadata only.

OWASP Category Mapping

Map security findings into OWASP Top 10 categories for triage.

Platform Matrix Scanner

Collect platform and architecture signals that predict where builds will break.

Security Posture Scanner

Structural security hygiene — lockfiles, .gitignore coverage, audit counts.

Security Scanners Scanner

Local security scanner orchestration and readiness analysis.

Service Dependencies Scanner

Map external service and platform dependencies by detecting SDK packages.

Tooling Inventory Scanner

Map your full technology stack by detecting packages across categories.

TypeScript Modernity Scanner

Analyze tsconfig.json for strictness, module system, and ESM readiness.

CI Integration

Reference

All documentation pages (81)

Alphabetical-by-reading-order list of every page in this guide.

1How It Works2Getting Started3Command reference4vg ask5vg baseline6vg bisect7vg build8vg bundle9vg code10vg drift11vg daemon12vg llm-host13vg dsn create14vg doctor15vg embed16vg evidence17vg export18vg facts19vg fix20vg guide21vg impact22vg init23vg locale24vg install / vg uninstall25vg lib26vg login27vg logout28vg lsp29vg map / vg hubs / vg areas / vg oddities30vg models31vg path32vg policy33vg push34vg hcs35vg module36vg report37vg review38vg savings39vg sbom40vg scan41vg scan --vulns42vg serve43vg share44vg show45vg status46vg watch47vg tests48vg tree49vg unknowns50vg update51vg why52DriftScore53Drift Baselines & Fitness Functions54Output Formats55Configuration56Extended Scanners Overview57Platform Matrix Scanner58Dependency Risk Scanner59Dependency Graph Scanner60Tooling Inventory Scanner61Build & Deploy Scanner62TypeScript Modernity Scanner63Breaking Change Exposure Scanner64File Hotspots Scanner65Security Posture Scanner66Security Scanners Scanner67Service Dependencies Scanner68Architecture Layers Scanner69Code Quality Scanner70OWASP Category Mapping71Database Schema Scanner72CI Integration73GitHub Actions74Azure DevOps75GitLab CI76Vibgrate Cloud Upload77Privacy & Security78Exit Codes79Programmatic API80Supply Chain Inventory81Approved-Alternative Library Policies