QMD
$ qmd Community Low RiskQMD (@tobilu/qmd) indexes local Markdown knowledge bases, docs, and meeting notes on-device using SQLite FTS5 BM25, local GGUF embeddings, and LLM reranking. Offers qmd search (BM25), qmd vsearch (vector), qmd query (hybrid), qmd get, -c/--collection, -n, --json, and qmd mcp.
npm install -g @tobilu/qmd qmd excels both as a fast CLI (qmd search/query/get --json) and as an embedded qmd mcp server with qmd skill instructions for coding agents.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
First-class --json, -c/--collection, -n result limits, --files/--full, qmd status, and built-in agent skill/MCP support.
--json,-c/--collection,-n,qmd get,qmd status, andqmd mcp
100% local on-device indexing and inference with zero external network calls after GGUF model download; clean split between search and index updates.
- Local SQLite +
node-llama-cppGGUF execution with read-only search commands
Installable via npm install -g @tobilu/qmd or bun install -g, though local GGUF embedding/reranker models download ~2 GB on first vector/hybrid run.
- Published on npm (
@tobilu/qmd); uses localnode-llama-cppmodels
Combines sub-second BM25 (search), semantic (vsearch), and hybrid reranked (query) retrieval in one local tool.
- Three retrieval tiers (
search,vsearch,query) plus doc retrieval (get)
Actively maintained MIT-licensed project (tobi/qmd) by Tobias Lütke.
- Active
tobi/qmdrepo under MIT license
Detailed README documenting CLI commands, MCP server setup, collection management, and --intent queries.
- GitHub README documents all subcommands, flags, and MCP tools
Security, Auth & Guardrails
Runs 100% locally using SQLite and cached GGUF models; no external API keys required.
100% free, local-first, and MIT open-source.
# QMD Agent Rules - Always pass `--json` and `-n <limit>` on `qmd search`, `qmd vsearch`, and `qmd query`. - Use `qmd search` first for exact symbols/terms before slower `qmd query` LLM reranking.
Agent-Ready Command Recipes
Safe Read-Only Queries
qmd search "auth token refresh" -c docs -n 5 --json
Searches the docs collection with BM25 in milliseconds and returns top 5 scored results as JSON.
qmd query "deployment rollback" --json -n 3
Executes query expansion, BM25 + vector retrieval, and local reranking, returning JSON snippets.
Controlled Writes & Previews
qmd collection add ./docs --name docs && qmd update && qmd embed
Adds ./docs to QMD's local SQLite index and generates local vector embeddings.
Strengths for Agents
- + Three-tier local search (
search,vsearch,query) with--jsonand-noutput limits. - + Completely private on-device retrieval without third-party vector DBs or API keys.
- + Ships both a scriptable CLI and
qmd mcpserver.
Caveats & Pitfalls
- !
qmd embedandqmd querydownload and run local GGUF models (~2 GB), requiring decent disk/RAM. - ! Requires
qmd update/qmd embedto reflect newly added Markdown files.