Vinv

io.github.VinvAI由 GitHub 帳號 VinvAI 發布v0.0.5更新於 Oct 24, 2026

Vinv runs, tests, and finds issues in your services — with zero code changes.

概覽

AI 產生的概覽

Vinv 為編碼助理提供 Python 程式庫的執行時證據:語意搜尋、追蹤、故障定位、死程式碼偵測,以及修復驗證迴圈。

可以做什麼
  • 搜尋與瀏覽程式碼:依語意回傳排序後的符號、持久化程式碼圖譜,並可透過回饋調整檢索。
  • 檢視已擷取的執行:依故障排序的嫌疑符號、觀測到的參數與回傳值、呼叫鏈、覆蓋率、呼叫端與影響範圍。
  • 驅動服務測試:自動呼叫端點與函式,把回應存成回歸案例,並讀取問題、熱點、記憶體趨勢與可快取點。
  • 處理發現:啟動修復流程、執行掃描、設定目標與預算,並用助理看不到的驗收測試驗證修復。
適用情境
適合助理處理 Python 服務或 API 時使用,讓它依據真實追蹤而非猜測來除錯、找出死程式碼或延遲熱點,並在接受修復前證明修復確實有效。其他語言僅支援索引與搜尋,價值有限。
執行需求
透過 npx vinv-mcp 以 stdio 在本機執行,不需帳號或 API 金鑰。需先建置本機引擎(需要 uv 與 Rust,約三分鐘),並一次性下載約 100 MB 的嵌入模型。執行時證據需要 Python 服務;工作區透過 MCP roots 或 VINV_WORKSPACE 指定。
安裝前請注意
Vinv 會啟動並驅動你的服務,並在沙箱副本中執行程式碼,因此會在本機執行專案程式碼。它會在儲存庫的 .vinv/ 與本機的 ~/.vinv/ 寫入狀態,並可還原某次流程改動過的內容。啟用時會向通知主機發出一次外部請求,可關閉。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Vinv,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

[License] [Version] [Downloads] [Tests] [Open issues] [100% local]

VinvAI

Tools for AI agents to test, fix and optimise your codebase.

Vinv connects runtime traces to the exact source that produced them, hands that evidence to the coding agent you already use, then re-runs the code to prove the fix actually works. It's not another coding agent — it's the evidence layer under the one you already use: your agent proposes, Vinv verifies.



See it in action · What it does · Under the hood · 2-min demo


[Six clients — VS Code, Cursor, Claude Code, Codex, Gemini CLI and Windsurf — all reading one workspace context in .vinv/: the code graph, runtime traces and metrics, joined on the function that handled each request]

One workspace context, built once — every agent reads the same .vinv/ store.


Why Vinv

84% of developers now use or plan to use AI coding tools — but more of them distrust the output (46%) than trust it (33%), and distrust nearly doubled in a year (Stack Overflow 2025, 49k developers).

The reason is familiar: the agent edits the wrong handler, invents return shapes, then grades its own homework while the server won't even start. Or it loops — test fails, agent edits the same function, test fails again — burning your context window on "let me verify."

Both failures share one root cause: the agent has never watched your code run. It argues from static text.

The industry automated writing code and left proving it entirely manual. Vinv automates the proving — and only then the finding and the fixing.

Install

Vinv works three ways — an editor extension, a CLI, or an MCP server for any agent. All three share the same local engines.

Editor extension

One click — install from vinv.ai, which opens the extension directly in your editor (VS Code, Cursor, Windsurf, VSCodium, Trae and Insiders). The listing lives on Open VSX and the VS Code Marketplace.

Or from your editor's CLI:

EditorCommand
VS Codecode --install-extension VinvAI.VinvAI
Cursorcursor --install-extension VinvAI.VinvAI
Windsurfwindsurf --install-extension VinvAI.VinvAI
VSCodiumcodium --install-extension VinvAI.VinvAI
Traetrae --install-extension VinvAI.VinvAI
VS Code Insiderscode-insiders --install-extension VinvAI.VinvAI

First run builds the engines — about 3 minutes, mostly compiling the Rust index; it also fetches a one-time ~100 MB local embedding model (uv and Rust required). First trace lands about a minute after that; everything after is seconds.

CLI (Python engines)

bash
pip install vinv          # every engine as a console script# or run one with zero install:uvx --from vinv exerciser campaign <repo> --budget 20

MCP server (any agent)

Give Claude Code, Cursor, or any MCP client Vinv's tools — one global config that finds your open workspace automatically via MCP roots.

Claude Code, Codex, Gemini CLI — installed once for every folder you open, not just the current one:

bash
claude mcp add --scope user vinv -- npx -y vinv-mcp
bash
codex mcp add vinv -- npx -y vinv-mcp
bash
gemini mcp add --scope user vinv npx -- -y vinv-mcp

Claude Code defaults to the current directory and Gemini CLI to the current project, so both take --scope user; Codex always writes to ~/.codex/config.toml and has no scope flag.

Other clients: add { "command": "npx", "args": ["-y", "vinv-mcp"] } under mcpServers.vinv. See vinv-mcp — 16 tools: semantic search, dead code, fault localization, runtime values/slices/coverage, and the verify/optimize loop.

Build from source — for contributors
bash
git clone https://github.com/VinvAI/VinvAI ~/.vinv/engines && cd ~/.vinv/engines && ./install.sh

Windows (PowerShell):

powershell
git clone https://github.com/VinvAI/VinvAI $HOME\.vinv\engines; cd $HOME\.vinv\engines; .\install.ps1

The loop, in one picture

Run → Test → Find → Prove. Point Vinv at a Python repo; it does the rest — no code changes, no API keys.

mermaid
flowchart LR  T[Trace] --> I[Index] --> S[Serve MCP] --> V[Verify] --> L[Learn] --> T
  • Run — brings every service up under tracing with zero edits, capturing timings, arguments, return values and call trees from the real run.
  • Test — drives real requests through every endpoint (valid, boundary, negative, authenticated) and banks each response as a regression case.
  • Find — surfaces what actually broke or slowed down — server errors, crashes, latency hotspots, dead code — each tied to the exact source line.
  • Prove — hands the evidence to the agent you already use, then verifies its fix against acceptance tests written before the fix that it never sees. A "faster" change that alters any output is auto-reverted.

Your agent is the only LLM — no new bill, no model picker, no provider keys. See the full walkthrough on vinv.ai/#under-the-hood.

See it in action

Not a lab benchmark — real findings, filed on real projects (scikit-learn, watermarks-remover, semantica, FastAPI, Typer, smolagents), every one with an upstream thread you can open. All of it driven by Cursor running Composer 2.5 with Vinv installed — not a frontier model. The evidence did the work, not the model. The full set with screenshots: vinv.ai/#catches.

Dead code — proven by what never ran

Static tools only prove "nothing references this." Vinv proves "no capture ever executed this," carries each untraced island with the live callers that still point at it, and lets your agent return the verdict — integrate, delete, or keep.

UpstreamWhat Vinv caughtStatus
scikit-learn#34790Unused _find_smallest_angle helper in _ridge.py, stranded after a refactor✅ merged — "thanks for the clean-up"
semantica#117613 unreferenced symbols across 9 files (289 deletions, 0 insertions)✅ merged — review restored 2 as deprecated
fastapi/typer#1937Unused OptionHelpExtra TypedDict in the vendored Click✅ maintainer-confirmed

semantica#1176 is the discipline in one thread: a maintainer flagged two symbols as importable downstream, Vinv restored them with deprecation warnings, and the same maintainer merged.

Optimization — a speedup that has to prove itself

Every call is timed and charged to the symbol that spent it. A candidate fix ships only if a paired-bootstrap 95% CI clears zero and the behavior suite replays byte-identical — faster-but-different is auto-reverted.

UpstreamWhat Vinv provedStatus
watermarks-remover#261Skip a discarded exiftool subprocess and redundant SynthID scoring in clean_image — output identical, regression-tested✅ merged
smolagents#2572Fast-path in sanitize_for_rich: 36.27 KB → 0.00 KB/call (~37,137× less), regression-tested over 2,014 inputs🔵 open, under review
semantica#1178Build the built-in algorithm catalog once, share it copy-on-write🔵 open, triaged

Bug report — bugs that only exist while something runs

Scanners read source and guess. Vinv drives the service and watches what comes back:

  • drive — every discovered endpoint, exercised with inputs nobody wrote.
  • judge — a 500 is not a finding on its own; the oracle names the status that should have come back.
  • hand over — ships as an evidence pack: repro command, caller chain, real argument values.

On fastapi/full-stack-fastapi-template (~44k★), the authenticated sweep filed discussion #2454 — four endpoints answering 500 to input that should be 4xx, one repro each — then another contributor reproduced all four against master, file-and-line: "checked against master — they're all real."

What Vinv gives your agent

One loop, grouped by what you came to fix. Each capability links to a live walkthrough on the site.

Understand the codebase → vinv.ai/#what-it-does

  • Semantic code search — ask by meaning, get ranked symbols with def bodies and line numbers, embedded by a local model.
  • Code Graph — a persistent map of every symbol and call edge, updated incrementally on save, with a live runtime overlay.
  • Runtime tracing — zero-edit tracing: timing, memory, args, returns, errors, per call, joined to source.
  • Ask Vinv — plain-English questions about your running system, every answer citing the exact trace spans and source lines, with a deterministic critic that blocks any claim the evidence can't back.

Find what actually broke → vinv.ai/#catches

  • Rank suspects — on any failure, symbols ranked by fault-localization score over real pass/fail requests, with the real error messages attached.
  • Behavior exerciser — Vinv doesn't wait for traffic: it drives every discovered endpoint itself, picks strategies with a Thompson-sampling bandit, and banks every response as a permanent regression case.

Clean up dead code → vinv.ai/#what-it-does

  • Dead-code sections — untraced islands split into "no references" vs "reached from live code but never taken," each with the live callers that still point at it and a keep-or-cut verdict with reasoning.

Recover latency → vinv.ai/#what-it-does

  • Recoverable time — latency hotspots ranked by the milliseconds you'd actually get back, each dispatched as a predicted-then-proven optimization instead of a guess.

Trust the fix → vinv.ai/#under-the-hood

  • Verified fixes — replayed start, live port, acceptance tests the agent never sees. One click reverts everything an episode touched.
  • Journey — one walkthrough of everything verified: every service, then every endpoint's call tree, latency flamegraph, and exact inputs → outputs, with a form to add your own test inputs that the engine replays forever.
  • Auto-Pilot — one click drives discover → set up → trace → exercise → fix → verify, until green or budget; when new trace errors land, the fix episode is already dispatched by the time you see the red ring in the graph.
  • Findings — issue clusters, optimization episodes with paired-bootstrap confidence intervals, regression diffs by kind, and a machine-readable findings.json your agent can consume directly.

Honest scope: Python first — services and APIs. Other languages get the index, graph and grounded Q&A, but no runtime evidence yet. TypeScript and Go are next.

Agent alone vs Agent + Vinv

Agent aloneAgent + Vinv
Finding codegreps and guesses filesranked symbols with line numbers, by meaning
"Done"claims it, grades its own homeworkreplayed start, live port, unseen acceptance tests
Memoryforgets every sessionpersistent index + graph, updated on save
Runtimecan't see itreal traces, values, flamegraphs per call
Debuggingreads source, speculatesfault-ranked suspects with real error messages
Dead codecan't tell used from unusednever-executed islands with live callers and a verdict
Bad fixyou diff and prayone-click revert of everything the episode touched
API testingwrites tests it then grades itselfexercises every endpoint, banks each response as an unseen regression case
Perf claims"should be faster now"paired-bootstrap 95% CI must exclude zero, behavior byte-identical, or auto-revert
Costburns tokens re-exploringevidence pack composed once, locally; the bandit learns which composition pays

Why agents can't reward-hack under Vinv

Vinv ties every runtime trace to the exact code that produced it and hands your agent a context graph built from that join — so the agent argues from evidence, not vibes. And when it claims victory, Vinv doesn't take its word:

  • Acceptance tests are authored before the fix, stored outside the workspace under an opaque token, and must fail deterministically twice on the broken code — a test that passes pre-fix is thrown away.
  • A "faster" fix that changes any observable output is auto-reverted — the behavior suite must replay byte-identical and the speedup's paired-bootstrap 95% CI must exclude zero.
  • Deliberate 4xx rejections aren't "errors" to fix — the defect classifier knows a service saying no correctly from a service breaking, so the agent is never handed a fake goal it can only game.
  • When two attempts stop making progress, a Nash-bargaining stall judge continues only if both an explorer stance and an auditor stance strictly prefer it to asking you.
Under the hood: the oracle roster, the budget dispatcher, and the sandbox

The Test stage isn't one tester — it's a set of oracles, each hunting a different class of defect, all writing into the same findings and fix-dispatch path.

OracleWhat it findsFinding kinds
HTTP exerciserDrives every endpoint itself — schema-valid, boundary, negative, values mined from real traces, multi-step authserver-error · crash · invariant-violation
Differential oracleCompares a handler or evaluator against a reference — for a parser, CPython itself; disagreement is the bug reportdifferential-mismatch
Fault injectionAdversarial-but-legal shapes at a dependency boundary, plus every chunk-split point on a streamfault-crash · fault-divergence
Concurrency oracleDeterministic interleavings and timeout injection — shared state that corrupts under parallel calls, lock orderings that deadlockconcurrency-divergence · concurrency-hang
Environment oracleA dependency-resolution matrix, and upstream symbols whose signature moved under yousignature-drift
Golden I/O baselinesA "faster" change that quietly dropped a field or changed a status classbaseline-degraded
Dead codeUntraced islands with the live callers that still reference themdead sections
Runtime analysisLatency hotspots, memory-leak suspects (Theil–Sen), duplicate recomputation worth caching, throughput ceiling (USL fit)hotspots · leaks · cache candidates · throughput-ceiling

The dispatcher is a bandit. exerciser campaign allocates one budget across every armed oracle by Thompson sampling over (target × technique × oracle). Cost is measured (wall-clock normalized to probe-equivalents plus subprocesses spawned), and credit is paid once per defect signature so a deterministic oracle can't re-earn credit for the same bug. Posteriors persist in campaign.json — which technique pays on your repo is learned.

Unverified code runs behind a containment ladder: a kernel-enforced OS sandbox (sandbox-exec / bwrap / unshare) where the host offers one, otherwise a process shim — always with a disposable repo copy, redirected HOME/TMPDIR, blocked network and subprocess spawning. The tier is decided by a probe that verifies a write outside the root really failed, never by a binary being on PATH. Postgres, Redis and S3 are substituted inside the jail so code that needs them runs instead of failing to connect.

Proven on itself

Vinv's release gate is Vinv — these numbers come from running the loop on this repository:

MetricResult
Index4,036 symbols
Searchfile hit@10 0.90 · symbol MRR 0.51 · p50 81ms
Crash recoveryindexer, embedder, and traced service all kill-tested mid-run
Self-found waste83% duplicate compute found → now cached
Retrieval tuningoff-policy evaluation (doubly-robust, BCa bootstrap) over 800 logged decisions promoted top-k 10 (+0.173, 95% CI [+0.081, +0.317]) and blocked both other candidates
Test suite2,376 tests — 1,575 Python · 801 extension

The full learning walk — reward, propensity, gating math, with file:line for every claim — is docs/learning.md. The test ontology is docs/testing-ontology.md.

Works with your agent

One command (Register Vinv MCP in Agent Tools) writes the servers into every agent it detects:

AgentFix dispatchMCP tools
Claude Code✅✅ auto
Cursor (CLI + chat)✅✅ auto
Codex CLI✅✅ auto
Gemini CLI✅✅ manual
Copilot Chat (VS Code)✅✅ auto
Windsurf Cascade✅✅ auto
Where the config lands, per client — and how to verify

Registration is idempotent and never commits secrets. The servers (vinv-index, vinv-runtime, vinv-exercise) launch over stdio via the editor's own runtime.

  • Claude Code — ~/.claude.json, project-local scope. Verify: claude mcp list.
  • Cursor — <repo>/.cursor/mcp.json. Verify: Settings → MCP shows them green.
  • Codex CLI — ~/.codex/config.toml under [mcp_servers.vinv-index] / [mcp_servers.vinv-runtime].
  • Copilot Chat — native VS Code MCP provider (auto), .vscode/mcp.json on older builds.
  • Windsurf Cascade — ~/.codeium/windsurf/mcp_config.json.
  • Gemini CLI — dispatch works out of the box; for MCP tools, add the same stdio servers to ~/.gemini/settings.json.

Your agent is also Vinv's only LLM — every analysis step routes through the coding-agent CLI you already pay for.

MCP tools reference — few tool names on purpose; the session tool multiplexes

vinv-index — your code and the session:

ToolReturns
vinv_queryRanked symbols with paths + a decision id — any by-meaning search, before grep
vinv_feedbackack — reward −1..1 after acting on results; trains retrieval
vinv_session10 actions in one tool — read: trajectory · status · issues · hotspots · memory_trends · cache_candidates; act: fix · run_sweep · set_goal · set_budget

vinv-runtime — the captured runs (read-only, provenance-stamped):

ToolReturns
rank_suspectsFault-ranked symbols over pass/fail requests, real errors attached
values_ofObserved argument/return types, null-rates, ranges
sliceObserved caller chain from request root, values at each frame
coverage_ofWhat ran, how often, ok/error, timing
callers_of / blast_radius / why_did_this_runObserved callers · transitive impact · entry-point paths

vinv-exercise — your agent exercises your service and reports the run back; Vinv grades what came back.

The engines

pip install vinv ships every engine as a console script — or use any one standalone:

EngineCommandWhat it does
exerciserexerciser campaign <repo> --budget NStart here. Coverage-guided API exerciser + oracle swarm; banks a permanent regression suite and reports which technique paid.
tracelenstracelens run -- <cmd>Zero-edit runtime tracer — timings, arguments, return values, call trees.
indexindex query <repo> · index deadcode <repo>Rust semantic code index — search by meaning, plus a source-only dead-code report.
identificationidentification consolidate <repo>Joins traces to source — API surface + call-graph map.
bringupbringup list/start <repo>Brings services up under tracing.
handbookhandbook generate <repo>Renders the codebase-discovery task your agent runs. Prompt-only.
goalgoal create <context>Distills a working context into one standing goal. Prompt-only.
embeddervinv-embedder serveLocal embedding sidecar (granite-embedding-small) — no cloud keys.
contracts(library)lens_contracts — the shared data contract every engine reads and writes.
exerciser CLI — the oracle swarm, runnable standalone
CommandWhat it does
exerciser campaign <repo> [--base-url URL] [--budget N]Start here. One budget across every armed oracle by Thompson sampling
exerciser plan <repo> [--base-url URL]Per-endpoint input plan (schema + observed + semantic layers)
exerciser run <repo> --base-url URLExecute the plan against the live traced service, coverage-guided
exerciser functions <repo> [--require-tier os-sandbox]Drive entry points and exported functions in process, contained
exerciser differential <repo> [--target M:f --reference cpython-exec]Compare a function against a reference implementation
exerciser faults <repo> [--auto-target M:f]Legal-but-adversarial shapes at a dependency boundary
exerciser concurrency <repo> --target M:fDeterministic schedules + timeout injection
exerciser environment <repo>Dependency-resolution matrix + upstream signature drift
exerciser containmentWhich containment tier this host can actually provide, and why
exerciser throughput-sweep <repo> --base-url URLConcurrency sweep + USL fit → throughput-ceiling opportunities
exerciser regress <repo> --base-url URLReplay the accumulated behavior suite, report diffs by kind
exerciser scorecard <repo>Per-service scorecard: coverage before→after, invariants, issues, latency

Requires identification consolidate first for apis.json, and — for real coverage — a service running under tracelens.

FAQ

Do I need my own API keys? No. Vinv runs everything locally. The semantic index and code embedder run on your machine without any provider keys. Your agent CLI (Claude Code, Cursor, …) handles its own LLM communication using the auth you already set up.
Is there any telemetry or data collection? No telemetry, no analytics, no usage pings, no crash reports. Vinv stores per-repo state in .vinv/ and per-machine state in ~/.vinv/; sensitive data in traces is redacted and never sent anywhere. The extension makes exactly one outbound request of its own: a GET of a static file at notices.vinv.ai on activation, so a broken release can tell you. No query string, no identifiers, nothing uploaded; at most once an hour. Turn it off with vinv.notices.enabled.
Does Vinv modify my code? No. Vinv uses a zero-edit tracer, instrumenting your Python backend at runtime without SDK integrations, decorators, or source changes.
How does it know if a fix worked? Acceptance tests are authored before the fix, stored outside your workspace under an opaque token, and required to fail deterministically twice on the broken code — a test that passes pre-fix is discarded. The fix must then pass them, with a replayed start, a live port, and every other observable behavior byte-identical. A deterministic anti-cheat audit over the diff blocks test edits, swallowed exceptions and shadow modules outright.
Which languages and agents are supported? Runtime evidence — tracing, the oracle swarm, verified fixes — is Python today, for services and APIs; other stacks get the semantic index, code graph, and grounded Q&A. TypeScript and Go are next. Editors: VS Code, Cursor, Windsurf, VSCodium, Trae, VS Code Insiders. Agents it drives: Claude Code, Cursor CLI, Codex CLI, Gemini CLI, Copilot Chat, Windsurf Cascade.
Is it really free and open source? Yes — Apache 2.0, every engine builds from source in this repo.

Privacy

  • Everything on your machine — per-repo state in .vinv/ (auto-gitignored), per-machine in ~/.vinv/. No account, no API keys, no telemetry — none.
  • One outbound request, and you can read it: a GET of a static JSON file at notices.vinv.ai on activation, for broken-release and security notices only. No query string, no identifiers, nothing uploaded; at most once per 12 hours; disable with vinv.notices.enabled.
  • The only download is the embedding model (Hugging Face, once, ~100 MB); everything else builds from this repo.
  • Traces store bounded summaries, not raw values; sensitive parameter names (password, token, api_key, …) are redacted, never captured.
  • The only LLM Vinv talks to is the coding-agent CLI you configured, through its own auth.

Contributing & license

See CONTRIBUTING.md — uv sync, cargo build in index/, npm install && npm run check in extension/, keep tests/e2e/planted_bug_golden/run.py green. Good first issues are labeled. By taking part you agree to our Code of Conduct; to report a vulnerability, see SECURITY.md. Apache License 2.0 © 2026 VinvAI.

Your agent says it's done. Vinv says prove it.

If Vinv caught something your agent missed — leave a review on Open VSX and ⭐ star this repo.

vinv.ai · What it catches · Open VSX · LinkedIn · [email protected]

來源:README.md,提交 2d04f9c

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.0.5最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分