
trovex
io.github.TsukumoHQ由 GitHub 帳號 TsukumoHQ 發布v0.16.1更新於 Oct 24, 2026
Serves coding agents one canonical doc per query instead of rereading the repo — ~60% fewer tokens.
概覽
本機 MCP 伺服器,索引儲存庫中的 Markdown,為編碼代理回傳回答問題的唯一權威文件,並提供共用寫回儲存。
- 可以做什麼
- 把問題路由到磁碟上唯一目前有效的 Markdown 文件,回傳 path:line 指標與 canonical、stale、duplicate 新鮮度標記,並只給出回答所在的章節而非整個檔案。在儲存中依段落檢索並支援標籤篩選,適合需要最相符片段而非單一權威文件時使用。寫入、讀取、加標籤與軟刪除保存在 trovex 自有儲存中的文件,可只修補某一章節,讓多個代理與團隊成員共用同一事實來源。在渲染閱讀器中檢視 trovex 自有文件,並在本機儀表板查看累計節省的 token。
- 適用情境
- 當編碼代理反覆重讀儲存庫 Markdown 以判斷哪份文件是目前版本、希望減少文件查找的 token 消耗時適用。也適合多個代理或開發者需要讀寫同一批筆記、決策與操作手冊、避免重複推導的團隊。
- 執行需求
- 以 Python 3.11 本機程序執行,透過 uv 從 PyPI 安裝(uvx 可免安裝執行)。索引需另外執行指令,啟動伺服器後在 localhost 提供 MCP 端點。預設在本機產生嵌入,也可設定 OpenAI 相容端點。本機使用無需 API 金鑰。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 trovex,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
[trovex: one canonical doc for your coding agents, ~60% fewer tokens.]
trovex
trovex: one canonical doc for your coding agents, ~60% fewer tokens.
[Join the tsukumo community on Discord]
Your coding agents (Claude Code, Cursor, Windsurf, Zed, any MCP client) reread the repo
every session to work out which .md is current, then answer from a guess. You pay for
that on every session, every agent, every teammate.
trovex indexes your repo's markdown and exposes one MCP tool. Your agent asks a question;
trovex returns the single current doc that answers it as a path:line pointer with a
freshness marker (canonical / stale / duplicate), and serves just the section that answers
instead of the whole file. Agents also write what they learn back through one shared point,
so every agent and teammate reads the same source of truth instead of re-deriving it.
About 60% fewer tokens on doc lookups, measured at equal task-success on our own repo (it varies by yours). Runs locally: vectors in SQLite, embeddings via ONNX, no cloud or API keys.
What you're installing
A 30-second trust check, since the decision happens on the README, not the directory listing:
- First-party, open source. Built and run in production by tsukumo, the team behind it. AGPL-3.0-or-later.
- Local-first, nothing leaves your machine. Vectors in SQLite, embeddings via ONNX. No cloud, no API keys, no network call to answer a query.
- Confined writes, no shell. Six MCP tools: three read-only (
trovex,trovex_read,trovex_search) and three that mutate only trovex's own doc store (trovex_write,trovex_tag,trovex_delete). No shell execution, no writes to your source files. - The ~60% is reproducible. Measured at equal task-success on our own repo (median 69%, ~41–81% by repo, n=26, LLM-judged);
trovex searchprints the savings on yours. Full method at trovex.dev/measure.
Quick start
trovex is in public beta, on PyPI. No clone needed; uv tool install puts trovex
on your PATH:
Don't have uv? It's a one-line install: curl -LsSf https://astral.sh/uv/install.sh | sh
(or brew install uv).
The search step is the fast way to see the point: it returns the one canonical doc and
prints how many tokens that saved versus reading the top few candidates. Once trovex is
wired into your agent over MCP, the same numbers accumulate on the savings dashboard at
http://localhost:8765/savings.
Prefer not to install anything yet?
uvx trovex search "..."runs a single command in a throwaway environment, no install.
Wire it into your agent
trovex is an MCP server. Point your client at http://localhost:8765/mcp after trovex serve.
Per-client setup (Claude Code, Cursor, Windsurf, Cline, Zed, Roo) is at
trovex.dev/for.
Claude Code, one command. trovex setup installs the Claude Code skill, the
Active-Memory hooks, and registers the MCP server in one step (idempotent, safe to
re-run):
Restart Claude Code afterwards so it loads the skill + hooks. Prefer to wire just the
MCP server by hand? trovex setup --no-skill --no-hooks, or:
For Cursor, one click (after trovex serve):
Add trovex to Cursor
How it works
trovex turns your repo's markdown into one queryable, canonical store, then serves each agent the single current doc that answers a question, not a pile of candidates to rank.
Four ideas do the work:
- Canonical, not complete. For each question there should be one doc that answers it. trovex marks every doc canonical / stale / duplicate, so retrieval can prefer the one that's still true: a stale doc is exactly as similar to a query as the current one, so similarity alone can't tell them apart.
- Route, then serve the section. A query returns a
path:linepointer to the one doc and just the section that answers, not the whole file, and not the top-k pile your agent would otherwise read and rank itself. Closing that gap is where the tokens are saved. - Local by default. Indexing, embeddings (ONNX,
bge-small-en-v1.5) and vector search (sqlite-vec) all run on your machine. No cloud, no API key, no network call to answer a query. - A shared write-back path. Agents store what they learn once (
trovex_write) in trovex's own store; every other agent and teammate reads it back (trovex_read) instead of re-deriving it.
The read-and-write loop that keeps every agent on the same source of truth:
Prove it on your own repo
The ~60% is a claim you can run, not a number to take on faith. Two commands:
bench reports the distribution (median + spread), not a best case: the cost of reading the
one routed canonical doc versus the top-k candidates an unaided agent would read. --eval
goes further: both arms answer, an LLM judges, and a saving counts only when both answer
correctly. Full method and our own numbers are at trovex.dev/measure.
Already running trovex through the md-guard hook? trovex measure compares your real .md
token consumption before and after, from the hook's baseline log.
Dev notes: the claims eval harness
bench --eval above answers "does trovex still get the right answer" per-query, one arm vs
the other. trovex eval-harness (src/trovex/eval_harness.py) is the release-gate version of
that idea: a versioned cases.jsonl set, retrieval quality (hit@k/MRR/recall@k, free) plus a
weighted rubric score (correctness35/autonomy25/actionability20/safety10/concision10, blind —
the judge never sees which config produced an answer), a $ budget cap, and resumability.
--retrieval-only (what make eval runs) never calls an LLM — it gates purely on hit@1
against benchmarks/token-savings/eval-baseline.json. The full rubric pass needs a key, so
it's a manual/CI-secret-gated run, not part of make test. The bundled cases.jsonl (47
cases) and eval-baseline.json thresholds are versioned in benchmarks/token-savings/ — the
baseline is a placeholder until it's been run once for real and the numbers copied in
deliberately (the file is never auto-overwritten by a run).
MCP tools
trovex(q): route a question to the right on-disk.mdand get backpath:linepointers with freshness markers, not a pile of files to rank.trovex_write(content, kind?, doc_id?, tags?, section?)/trovex_read(query | doc_id, section?): docs owned inside trovex. An agent stores a record (an incident, a decision, "what actually worked") once; every other agent and a second dev read it back as content (optionally just one section) instead of re-deriving it. Passsection=totrovex_writeto patch one heading's section in place instead of replacing the whole doc.trovex_search(query, k?, tags?): passage-level retrieval across the store with tag filters, for when you want the top matching chunks rather than one canonical doc.trovex_tag(...)/trovex_delete(...): tag or soft-delete a stored doc; delete is a recoverable archive, not a hard wipe. Both touch only the trovex store, never your files.
Humans read trovex-owned docs at /doc/{id} in the rendered reader. To make agents route
.md writes through trovex_write instead of the disk, install the PreToolUse hook
deploy/hooks/trovex-md-guard.sh and carve out exceptions in .trovexignore.
How it compares
- vs
CLAUDE.md/AGENTS.md: one static file that goes stale and can't route a question to the right doc, vs many docs kept canonical and served per query. More. - vs
repomix/ files-to-prompt: pack the whole repo into the window vs retrieve the one answer. More. - vs a vector DB / plain RAG: a ranked pile of candidate chunks with no freshness signal vs one current doc with an explicit marker. More.
The reasoning behind the ~60% number is written up in the benchmark methodology.
Stack
- Python 3.11 + uv
- FastAPI (MCP HTTP + server-rendered HTML UI)
- fastembed (local embeddings, ONNX under the hood)
- sqlite-vec (vector search in SQLite)
- Jinja2 + HTMX (UI, no build step)
Embeddings: local by default, bring your own
trovex embeds locally out of the box with BAAI/bge-small-en-v1.5 (ONNX, 384-d).
No API key, nothing leaves your machine. You can swap in any embedder:
- Another local model:
TROVEX_EMBED_MODEL=<fastembed model>plusTROVEX_EMBED_DIM=<its dimension>if it's not a built-in. - An OpenAI-compatible endpoint (incl. a local server like Ollama, LM Studio,
vLLM):
TROVEX_EMBED_PROVIDER=openai,TROVEX_EMBED_MODEL=<model>,TROVEX_OPENAI_BASE_URL=http://localhost:11434/v1,TROVEX_EMBED_DIM=<dim>. Point it atlocalhostand you stay fully local; point it at OpenAI (text-embedding-3-large) for stronger retrieval at the cost of sending each chunk to OpenAI's API.
Changing the model changes the vector dimension, so switching requires a reindex.
Public beta
trovex is in public beta. Install it, run it on your repo, and if it saves you tokens a GitHub star helps other devs find it. Issues and PRs welcome.
Questions, or comparing notes with other people running agents? Join the community on Discord: tsukumo.ch/discord.
Security
trovex is local-first and single-tenant: it runs on your machine, indexes your docs, and
serves your agents. Mutations are gated behind the X-TROVEX-Write-Token header, and the
default is fail-closed: with no token configured, trovex auto-generates a per-instance
token on first run and persists it to <data_dir>/.write_token (chmod 600), so a
network-exposed instance does not accept anonymous writes. Set TROVEX_WRITE_TOKEN to share
one token across machines, or TROVEX_ALLOW_UNAUTH_WRITES=1 to deliberately run with open
writes on a trusted localhost. The trust model, what's hardened, and how to report a
vulnerability are documented in SECURITY.md.
License
trovex is licensed under the GNU AGPL-3.0-or-later (see LICENSE). You can
self-host and modify it freely; if you run a modified version as a network service, AGPL
requires you to share your changes.
Part of the suite
trovex is the context layer of a four-part open-source suite for running AI coding agents in production, built by tsukumo:
- trovex, context: serve agents the one canonical doc per query instead of rereading the repo (~60% fewer tokens per lookup; method at trovex.dev/measure).
- wrai.th, orchestration: run and coordinate a fleet of agents.
- yoru, observability: session receipts of what each agent actually did.
- dokan, deterministic execution: run the agent's settled, repeatable work as scripts in clean containers, no model in the loop.
Working with a team?
trovex is free to run yourself. If your team is rolling out coding agents at scale and wants hands-on help doing it well, or to embed and host a modified trovex privately without the AGPL's copyleft obligations, that's what the consulting is for. Reach out to tsukumo, the team behind trovex.
來源:README.md,提交 1c3da4a
工具
0版本歷史
3- v0.16.1最新Sep 27, 2026
- v0.15.2Sep 26, 2026
- v0.15.0Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分