{"_id":"@4bk/vdiff","_rev":"14-a8eb1174d2dee6d4e3d8dc6c4eb69dec","name":"@4bk/vdiff","dist-tags":{"latest":"0.1.11"},"versions":{"0.1.8":{"name":"@4bk/vdiff","version":"0.1.8","keywords":["diff","verification","ai","code-review","cli","llm"],"author":{"name":"Felipe Forbeck","email":"fforbeck@gmail.com"},"license":"UNLICENSED","_id":"@4bk/vdiff@0.1.8","maintainers":[{"name":"fforbeck","email":"fforbeck@gmail.com"}],"homepage":"https://vdiff.app","bugs":{"url":"https://github.com/fforbeck/vdiff/issues"},"bin":{"vdiff":"dist/index.cjs"},"dist":{"shasum":"d3a3c202a70f3ea5c1793bf49e843f540148eedd","tarball":"https://registry.npmjs.org/@4bk/vdiff/-/vdiff-0.1.8.tgz","fileCount":5,"integrity":"sha512-Pf3ODb1Bom7YgzEkxvPH8wekmK+X/3U/13oiE4QT5EJOHYKogq/n2t4ljPH6f5Du8I6VXp4vD5jixFWI739grw==","signatures":[{"sig":"MEYCIQCil8G54aJ0N0HJOlNqOEBnPYfbwCgzMAPfnrOfHsuWUgIhAK/vriN5tixwrwC619+XefAbOd2gL0QG2aiuVpxoxbd/","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1237622},"main":"dist/index.cjs","type":"module","engines":{"node":">=20.0.0"},"gitHead":"f071000860f150bccccaeebeedd8bf6b80affd2a","scripts":{"dev":"tsx src/index.ts","test":"vitest run","build":"node build.mjs","prepack":"node verify-pack.mjs","typecheck":"tsc --noEmit","publish:npm":"npm publish --access public","release:major":"npm version major","release:minor":"npm version minor","release:patch":"npm version patch","test:coverage":"vitest run --coverage","prepublishOnly":"pnpm test && pnpm build"},"_npmUser":{"name":"fforbeck","email":"fforbeck@gmail.com"},"repository":{"url":"git+https://github.com/fforbeck/vdiff.git","type":"git"},"_npmVersion":"10.9.2","description":"VeriDiff - Verification layer for AI-generated code. Verify your diffs.","directories":{},"_nodeVersion":"23.11.1","dependencies":{"chalk":"5.6.2","openai":"6.33.0","commander":"14.0.3","picomatch":"^4.0.4","web-tree-sitter":"0.25.10","@anthropic-ai/sdk":"0.82.0","@inquirer/prompts":"^8.4.2","tree-sitter-wasms":"0.1.13"},"_hasShrinkwrap":false,"packageManager":"pnpm@10.14.0+sha512.ad27a79641b49c3e481a16a805baa71817a04bbe06a38d17e60e2eaee83f6a146c6a688125f5792e48dd5ba30e7da52a5cda4c3992b9ccf333f9ce223af84748","devDependencies":{"tsx":"4.19.0","vite":"^6.0.0","vitest":"^4.1.5","esbuild":"0.28.0","typescript":"5.7.2","@types/node":"^22.10.0","@types/picomatch":"^4.0.3","@vitest/coverage-v8":"^4.1.5","javascript-obfuscator":"5.4.2"},"_npmOperationalInternal":{"tmp":"tmp/vdiff_0.1.8_1777730880495_0.6191114123379449","host":"s3://npm-registry-packages-npm-production"}},"0.1.9":{"name":"@4bk/vdiff","version":"0.1.9","keywords":["diff","verification","ai","code-review","cli","llm"],"author":{"name":"Árvore Sistemas","email":"contato@4bk.com.br"},"license":"Apache-2.0","_id":"@4bk/vdiff@0.1.9","maintainers":[{"name":"fforbeck","email":"fforbeck@gmail.com"}],"homepage":"https://vdiff.app","bugs":{"url":"https://github.com/fforbeck/vdiff/issues"},"bin":{"vdiff":"dist/index.cjs"},"dist":{"shasum":"da27ffcaa8076ba3ad1dcccabb9000d2178a8798","tarball":"https://registry.npmjs.org/@4bk/vdiff/-/vdiff-0.1.9.tgz","fileCount":5,"integrity":"sha512-Acnmc0dlGZXsEahD0l/3nffaLPxQnMEMUEaLL8vUDyM20jA0XW1hrWhTaOrqj53ek0niS60s4FoQSpL7Z0IfkQ==","signatures":[{"sig":"MEUCIQDE678ZRL3DHQBSC0LfyXu36U2mXoLPKVqlGlcAyANhIAIgLeDdPDzjmbGotmu9VkctbSGUrpJeSZKbNlQ1FmWPIWo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":479517},"main":"dist/index.cjs","type":"module","engines":{"node":">=20.0.0"},"gitHead":"6d6a84d948f2ddea4d1d4508c06cc68213e61c45","scripts":{"dev":"tsx src/index.ts","test":"vitest run","build":"node build.mjs","typecheck":"tsc --noEmit","publish:npm":"npm publish --access public","release:major":"npm version major","release:minor":"npm version minor","release:patch":"npm version patch","test:coverage":"vitest run --coverage","prepublishOnly":"pnpm test && pnpm build"},"_npmUser":{"name":"fforbeck","email":"fforbeck@gmail.com"},"repository":{"url":"git+https://github.com/fforbeck/vdiff.git","type":"git"},"_npmVersion":"10.9.2","description":"VeriDiff - Verification layer for AI-generated code. Verify your diffs.","directories":{},"_nodeVersion":"23.11.1","dependencies":{"chalk":"5.6.2","openai":"6.33.0","commander":"14.0.3","picomatch":"^4.0.4","web-tree-sitter":"0.25.10","@anthropic-ai/sdk":"0.82.0","@inquirer/prompts":"^8.4.2","tree-sitter-wasms":"0.1.13"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"packageManager":"pnpm@10.14.0+sha512.ad27a79641b49c3e481a16a805baa71817a04bbe06a38d17e60e2eaee83f6a146c6a688125f5792e48dd5ba30e7da52a5cda4c3992b9ccf333f9ce223af84748","devDependencies":{"tsx":"4.19.0","vite":"^6.0.0","vitest":"^4.1.5","esbuild":"0.28.0","typescript":"5.7.2","@types/node":"^22.10.0","@types/picomatch":"^4.0.3","@vitest/coverage-v8":"^4.1.5"},"_npmOperationalInternal":{"tmp":"tmp/vdiff_0.1.9_1777992443397_0.44980177056217485","host":"s3://npm-registry-packages-npm-production"}},"0.1.10":{"name":"@4bk/vdiff","version":"0.1.10","keywords":["diff","verification","ai","code-review","cli","llm"],"author":{"name":"Árvore Sistemas","email":"contato@4bk.com.br"},"license":"Apache-2.0","_id":"@4bk/vdiff@0.1.10","maintainers":[{"name":"fforbeck","email":"fforbeck@gmail.com"}],"homepage":"https://vdiff.app","bugs":{"url":"https://github.com/fforbeck/vdiff/issues"},"bin":{"vdiff":"dist/index.cjs"},"dist":{"shasum":"eac1282731892fb899fa58d303e9dae43541118b","tarball":"https://registry.npmjs.org/@4bk/vdiff/-/vdiff-0.1.10.tgz","fileCount":6,"integrity":"sha512-zSB9o3dLMg6LwvtAaRymTritU2oco0HNaFxZCkwq+S8n+X+/zfnS/QsHczfdE8kluLaNfc1aQm5BngNODxDhWg==","signatures":[{"sig":"MEYCIQCVE2Nd/I4EDyhVS5Oa3bhfKyhxVtkiXhajesmrqgeoCwIhAOp4LkRkW37vdnuzM+iBT8zg6u/gsa+5trPsR/KbuWLh","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":490403},"main":"dist/index.cjs","type":"module","engines":{"node":">=20.0.0"},"gitHead":"c39d79b505ce363bc3b701e8e1f8846a4cb55a31","scripts":{"dev":"tsx src/index.ts","test":"vitest run","build":"node build.mjs","typecheck":"tsc --noEmit","publish:npm":"npm publish --access public","release:major":"npm version major","release:minor":"npm version minor","release:patch":"npm version patch","test:coverage":"vitest run --coverage","prepublishOnly":"pnpm test && pnpm build"},"_npmUser":{"name":"fforbeck","email":"fforbeck@gmail.com"},"repository":{"url":"git+https://github.com/fforbeck/vdiff.git","type":"git"},"_npmVersion":"10.9.2","description":"vdiff — verification layer for AI-generated code. Verify your diffs.","directories":{},"_nodeVersion":"23.11.1","dependencies":{"chalk":"5.6.2","openai":"6.33.0","commander":"14.0.3","picomatch":"^4.0.4","web-tree-sitter":"0.25.10","@anthropic-ai/sdk":"0.82.0","@inquirer/prompts":"^8.4.2","tree-sitter-wasms":"0.1.13"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"packageManager":"pnpm@10.14.0+sha512.ad27a79641b49c3e481a16a805baa71817a04bbe06a38d17e60e2eaee83f6a146c6a688125f5792e48dd5ba30e7da52a5cda4c3992b9ccf333f9ce223af84748","devDependencies":{"tsx":"4.19.0","vite":"^6.0.0","vitest":"^4.1.5","esbuild":"0.28.0","typescript":"5.7.2","@types/node":"^22.10.0","@types/picomatch":"^4.0.3","@vitest/coverage-v8":"^4.1.5"},"_npmOperationalInternal":{"tmp":"tmp/vdiff_0.1.10_1778170630627_0.2219031017178592","host":"s3://npm-registry-packages-npm-production"}},"0.1.11":{"name":"@4bk/vdiff","version":"0.1.11","description":"vdiff — verification layer for AI-generated code. Verify your diffs.","type":"module","main":"dist/index.cjs","bin":{"vdiff":"dist/index.cjs"},"exports":{".":"./dist/index.cjs","./core":{"import":"./dist/core.js","types":"./dist/core.d.ts","default":"./dist/core.js"}},"scripts":{"dev":"tsx src/index.ts","build":"node build.mjs","typecheck":"tsc --noEmit","test":"vitest run","test:coverage":"vitest run --coverage","prepublishOnly":"pnpm test && pnpm build","release:patch":"npm version patch","release:minor":"npm version minor","release:major":"npm version major","publish:npm":"npm publish --access public"},"dependencies":{"@anthropic-ai/sdk":"0.82.0","@inquirer/prompts":"^8.4.2","chalk":"5.6.2","commander":"14.0.3","openai":"6.33.0","picomatch":"^4.0.4","tree-sitter-wasms":"0.1.13","web-tree-sitter":"0.25.10"},"devDependencies":{"@types/node":"^22.10.0","@types/picomatch":"^4.0.3","@vitest/coverage-v8":"^4.1.5","esbuild":"0.28.0","tsx":"4.19.0","typescript":"5.7.2","vite":"^6.0.0","vitest":"^4.1.5"},"engines":{"node":">=20.0.0"},"keywords":["diff","verification","ai","code-review","cli","llm"],"author":{"name":"Árvore Sistemas","email":"contato@4bk.com.br"},"license":"Apache-2.0","repository":{"type":"git","url":"git+https://github.com/fforbeck/vdiff.git"},"publishConfig":{"access":"public"},"homepage":"https://vdiff.app","packageManager":"pnpm@10.14.0+sha512.ad27a79641b49c3e481a16a805baa71817a04bbe06a38d17e60e2eaee83f6a146c6a688125f5792e48dd5ba30e7da52a5cda4c3992b9ccf333f9ce223af84748","_id":"@4bk/vdiff@0.1.11","gitHead":"c0da28811a463c0fbc2b9b3773fa6c60d033cf33","bugs":{"url":"https://github.com/fforbeck/vdiff/issues"},"_nodeVersion":"23.11.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-0x9jJMao28Q1sFBxsGIBjQGVc2Wbzd+RD6022ToMAPcAsx8DzSienVjm0jMZMgbA/JFQxD2F0nqOwwnA4NXU5A==","shasum":"aa1383f00c974e40fe52fe6bef5006db0064073a","tarball":"https://registry.npmjs.org/@4bk/vdiff/-/vdiff-0.1.11.tgz","fileCount":8,"unpackedSize":808437,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDBxnE2DpS6+0Z7fCp6WMU2dq5TBOEZ4yQUE1IGGAXLzwIgNogLAte2m7WzrjQQTOjBTC8ZqxwuB8Ww70KWiwcLJ0Y="}]},"_npmUser":{"name":"fforbeck","email":"fforbeck@gmail.com"},"directories":{},"maintainers":[{"name":"fforbeck","email":"fforbeck@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/vdiff_0.1.11_1784574350896_0.41578312822451924"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-02T01:14:11.254Z","modified":"2026-07-20T19:05:51.283Z","0.1.2":"2026-05-02T01:14:11.541Z","0.1.3":"2026-05-02T02:08:04.537Z","0.1.4":"2026-05-02T02:15:09.421Z","0.1.5":"2026-05-02T03:10:11.726Z","0.1.6":"2026-05-02T03:40:45.656Z","0.1.8":"2026-05-02T14:08:00.770Z","0.1.9":"2026-05-05T14:47:23.657Z","0.1.10":"2026-05-07T16:17:10.865Z","0.1.11":"2026-07-20T19:05:51.107Z"},"bugs":{"url":"https://github.com/fforbeck/vdiff/issues"},"author":{"name":"Árvore Sistemas","email":"contato@4bk.com.br"},"license":"Apache-2.0","homepage":"https://vdiff.app","keywords":["diff","verification","ai","code-review","cli","llm"],"repository":{"type":"git","url":"git+https://github.com/fforbeck/vdiff.git"},"description":"vdiff — verification layer for AI-generated code. Verify your diffs.","maintainers":[{"name":"fforbeck","email":"fforbeck@gmail.com"}],"readme":"# vdiff\n\n**Code Verification Layer**\n\nKnow if your change is safe to merge in seconds. Deterministic checks + AI reasoning. No guesses.\n\nvdiff analyzes git diffs and produces structured verification reports surfacing risks, detecting suspicious patterns, identifying validation gaps, and guiding human review.\n\n## Installation\n\n```bash\nnpm install -g @4bk/vdiff\npip install graphifyy\n```\n\nvdiff requires [Graphify](https://graphify.net) (Python 3) to build the dependency graph for your codebase.\n\n### Cursor IDE (optional plugin)\n\nBundled Cursor plugin directory: **`plugins/cursor/`** — rules, **`/vdiff`** skill, commands, optional **stop-hook** reminder. Local install:\n\n```bash\nln -sf \"$(pwd)/plugins/cursor\" ~/.cursor/plugins/local/vdiff\n```\n\nDetails: [**plugins/cursor/README.md**](plugins/cursor/README.md). Uses [Cursor Plugins](https://cursor.com/docs/plugins) and [`stop` hooks](https://cursor.com/docs/hooks.md).\n\n## Quick Start\n\n```bash\n# Navigate to your project\ncd your-project\n\n# Guided setup (API key, models, knowledge graph)\nvdiff init\n\n# Analyze your changes\nvdiff -v\n```\n\nRun `vdiff init` from your project root so it can index your codebase and generate the knowledge graph.\n\nSee also `vdiff models` for curated default/high models per provider.\n\n## For agents and automation\n\nCoding agents, CI, and scripts should use **flags only** (no interactive menus), **JSON output**, and **`--no-feedback`**. Set **`CI=1`** or **`VDIFF_NON_INTERACTIVE=1`** to skip the optional post-run feedback prompt in TTY environments.\n\n- **Stored reviews:** use `vdiff reviews list` and `vdiff reviews show <index> --format json` — not bare `vdiff reviews` (that opens a TTY picker).\n- **GitHub:** this repository includes an optional **approval-gated PR workflow** (`.github/workflows/vdiff-pr.yml`). Setup: [.github/docs/vdiff-workflow.md](.github/docs/vdiff-workflow.md). [AGENTS.md](./AGENTS.md) in this package (published on npm as `@4bk/vdiff`). Shorter hints also appear in **`vdiff --help`** and **`vdiff analyze --help`**.\n\n## Configuration\n\n```bash\n# Set provider explicitly\nvdiff config set -g llm.provider anthropic\n\n# Set default model (used for quick checks)\nvdiff config set -g llm.model claude-haiku-4-5-20251001\n\n# Set high-depth model (used with --thinking-level high)\nvdiff config set -g llm.highModel claude-sonnet-4-6\n\n# View current config\nvdiff config list -g\n\n# Show config file locations\nvdiff config path\n```\n\nConfiguration is stored in `~/.vdiff/config.json` (global) and `.vdiff/config.json` (project-local, overrides global).\n\n### Config Schema\n\n```json\n{\n  \"llm\": {\n    \"provider\": \"anthropic\",\n    \"apiKey\": \"sk-ant-...\",\n    \"model\": \"claude-haiku-4-5-20251001\",\n    \"highModel\": \"claude-sonnet-4-6\"\n  },\n  \"analysis\": {\n    \"contextThreshold\": 1.0\n  }\n}\n```\n\n## Usage\n\n### Analyze Changes\n\n```bash\n# Smart default: staged if any, else unstaged\nvdiff\n\n# Staged changes only\nvdiff --staged\n\n# All changes (staged + unstaged)\nvdiff --all\n\n# Specific commit\nvdiff --commit HEAD~1\n\n# Branch diff (PR-style review)\nvdiff --base main\n\n# Piped diff\ngit diff | vdiff --stdin\n```\n\n### Context and Depth\n\n```bash\n# Include full source of changed files\nvdiff -f\n\n# Deep analysis (better model + auto-includes full files)\nvdiff --thinking-level high\n\n# Verify changes against a spec, PRD, or task file\nvdiff -s docs/spec.md\n\n# Combine: deep analysis + spec verification\nvdiff --thinking-level high -s docs/prd.md\n\n# Only analyze files matching a pattern\nvdiff -p \"src/auth/**\"\n```\n\n### Output\n\n```bash\n# Verbose: show all sections and all findings\nvdiff -v\n\n# JSON output (for tooling / CI integration)\nvdiff --format json\n\n# Markdown output (for PR comments)\nvdiff --format markdown\n\n# Debug: show analysis progress and diagnostics\nvdiff -d\n```\n\n### Knowledge Graph\n\nProvide cross-file dependency context for richer analysis.\n\n```bash\n# Build the knowledge graph (one-time)\nvdiff graph init\n\n# Check graph status\nvdiff graph status\n\n# Use a specific graph file\nvdiff -g path/to/graph.json\n\n# Skip graph context\nvdiff --no-graph\n```\n\n### Custom Rules\n\nDefine project-specific rules in `.vdiff/rules/` as `.md` or `.txt` files:\n\n```bash\nmkdir -p .vdiff/rules\n```\n\nExample `.vdiff/rules/billing.md`:\n\n```markdown\n- Any change to src/billing/ must include a migration file.\n- Never remove rate limiting middleware from payment endpoints.\n- Flag any hardcoded price or currency value.\n```\n\n### Learned Rules\n\nSave review decisions that persist across analyses:\n\n```bash\n# Add a global rule\nvdiff rule add \"API routes must validate request body\"\n\n# Add a scoped rule (only applies when matching files change)\nvdiff rule add --scope \"src/billing/**\" \"Never import from orders directly\"\n\n# List all rules\nvdiff rule list\n\n# Remove a rule\nvdiff rule remove <n>\n```\n\n### Git Hook\n\n```bash\n# Install pre-commit hook (blocks on high severity by default)\nvdiff hook install\n\n# Block on high + medium severity\nvdiff hook install --block-on high,medium\n\n# Informational only (no blocking)\nvdiff hook install --block-on none\n\n# Check hook status\nvdiff hook status\n\n# Remove the hook\nvdiff hook remove\n```\n\nThe hook runs `vdiff --staged` before each commit. By default, it **blocks commits** that introduce high-severity findings (security, data loss, auth bypass). Bypass with `git commit --no-verify`.\n\nConfigure the blocking threshold in `.vdiff/config.json`:\n\n```bash\nvdiff config set hook.blockOn '[\"high\",\"medium\"]'\n```\n\n### IDE Integration\n\nInstall vdiff into your AI coding assistant:\n\n```bash\n# Install for a specific IDE\nvdiff ide install cursor\nvdiff ide install windsurf\nvdiff ide install claude-code\n\n# Install for all detected IDEs\nvdiff ide install\n\n# Check status\nvdiff ide status\n```\n\n### Review History\n\n```bash\n# Browse past reviews (interactive selector)\nvdiff reviews\n\n# List all stored reviews (non-interactive, agent/CI friendly)\nvdiff reviews list\n\n# Show a specific past review by index\nvdiff reviews show <index>\n```\n\n### CI / Exit Codes\n\n```bash\n# Exit non-zero when verdict is not_ready (default)\nvdiff --base main\n\n# Stricter: exit non-zero on caution OR not_ready\nvdiff --base main --strict\n```\n\nExit codes: `0` = ready or caution, `1` = not_ready. With `--strict`, caution also exits 1.\n\n## Output\n\nvdiff separates **what it knows** from **what it infers** from **what it can't verify**:\n\n| Section | What it shows | Mode |\n|---------|---------------|------|\n| **Verdict** | Merge readiness (ready/caution/not ready) + risk bar + actions | Always |\n| **Change** | Plain language description + file stats | Always |\n| **Actions** | Prioritized next steps (required/recommended/optional) | Verbose only |\n| **Impact** | Dependency graph impact level + affected dependents | When graph exists |\n| **Structural Health** | Quality signal + metric bars (Modularity, Acyclicity, Depth, Equality) | Verbose only |\n| **Spec Alignment** | Requirement coverage bar + status breakdown | When `--spec` used |\n| **Findings** | Risk inferences + missing evidence with severity, confidence, category | Always |\n| **Review Delta** | Resolved/reopened/open findings vs previous review | When prior review exists |\n| **Focus** | Prioritized files and lines to inspect first | Verbose only |\n\n### Example\n\n```\n──────────────────────────────────────────────────\n  VDIFF ANALYSIS\n──────────────────────────────────────────────────\n\nVERDICT\n\n  ⚠ Merge with caution\n  → High impact: 19 files depend on changes\n\n  Risk:  ●●○○○  Low · [Moderate] · High\n\n  ! Fix: JWT secret read without fallback crashes server\n  → Verify: Token refresh uses rotating keys per spec\n  → Add tests for src/middleware/auth.ts\n\nCHANGE\n\n  Added JWT auth middleware with session validation\n  and rate limiting on login endpoint.\n\n  4 files +86 -12\n\nIMPACT\n\n  ●●●○○  Low · [Moderate] · High\n  You changed 4 files. 7 other files depend on them.\n\n  [shared]  src/middleware/auth.ts  → 5 dependents\n\nFINDINGS\n\n  1 high severity · 1 medium severity\n\n  [HIGH] [verified]  src/middleware/auth.ts:34\n  › JWT secret is read from process.env without\n    fallback, server crashes on missing env var.\n\n    Evidence:  validateToken() calls jwt.verify(token,\n               process.env.JWT_SECRET) with no guard\n    Confidence: ●●● [Strong]  ·  Category: [security]\n\n  ... 1 more (use -v to expand)\n\n──────────────────────────────────────────────────\n  Verdict:  ⚠ Caution (High impact: 19 files depend on changes)\n  Quality:  68 (Mod 71% · Acy 100% · Dep 58% · Eq 44%)\n  Findings: 1 HIGH | 1 MEDIUM\n  Changes:  4 files changed · 2 tests updated\n  ↑18.2k · ↓2.1k · ~$0.07 · claude-haiku-4-5 · low · 3.1s\n──────────────────────────────────────────────────\n```\n\nUse `vdiff -v` to expand all sections with full detail.\n\n## Analytics\n\nvdiff can send **anonymous** usage to vdiff.app (opt-in by default during `vdiff init` for interactive setup; otherwise off until you enable it). This includes run counts, `command` name (`analyze` after each review, `init` after a successful setup), model/provider, finding counts, quality scores, **`source`** (`cli` vs `cursor-plugin`, from `VDIFF_SOURCE` or terminal heuristics—see below), and optional **feedback** from the “Was this useful?” prompt (`-1` = not asked or skipped, including `--no-feedback` / JSON / non-TTY, `0` / `1` = down / up). **No** code, diffs, file contents, or API keys are sent.\n\nThe public API applies **per-device** daily and **per-minute** limits (e.g. separate caps for `init` vs `analyze`); see the `web` package `README.md` for current server behavior.\n\n```bash\n# Opt out of anonymous analytics\nvdiff config set -g analytics.enabled false\n\n# Opt back in\nvdiff config set -g analytics.enabled true\n```\n\nYou can also skip the post-analysis feedback prompt:\n\n```bash\nvdiff --no-feedback\n```\n\nUsage events are still sent when analytics are enabled; **`feedback` is `-1`** when the prompt is skipped. To tag runs from Cursor integrations, set:\n\n```bash\nVDIFF_SOURCE=cursor-plugin vdiff --staged --format json --no-feedback\n```\n\nOtherwise vdiff uses **`source: cli`**, or **`cursor-plugin`** when `TERM_PROGRAM` contains `cursor` (override with `VDIFF_SOURCE=cli` if needed).\n## Local Data\n\nvdiff stores all data locally:\n\n- `~/.vdiff/config.json` -- global configuration\n- `~/.vdiff/device.json` -- anonymous device identifier (for usage quota)\n- `.vdiff/config.json` -- project-local config (overrides global)\n- `.vdiff/rules/*.md` -- project-specific analysis rules\n- `.vdiff/rules/learned.md` -- learned rules from review decisions\n- `.vdiff/reviews.json` -- finding registry (review memory)\n- `.vdiff/reviews/results/*.json` -- stored review results for `vdiff reviews`\n\nLLM API calls use your own key (BYOK). Anonymous usage analytics are sent unless opted out (see above).\n\n## License\n\nApache License 2.0 by **Árvore Sistemas**. See [LICENSE](./LICENSE) for details.\n","readmeFilename":"README.md"}