MCP Local RAG
shinpr/mcp-local-rag
Searches, saves, and maintains a local document index through a local RAG MCP server.
Three-step multi-tool workflow — search the corpus, fetch the most relevant document in full, then find similar documents.
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install lyonzin/knowledge-rag rag-deep-dive --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/workflow/rag-deep-dive .claude/skills/rag-deep-dive && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .claude/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-diveType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install lyonzin/knowledge-rag rag-deep-dive --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/workflow/rag-deep-dive .agents/skills/rag-deep-dive && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .agents/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install lyonzin/knowledge-rag rag-deep-dive --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/workflow/rag-deep-dive .cursor/skills/rag-deep-dive && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .cursor/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/lyonzin/knowledge-rag.git --path skills/workflow/rag-deep-dive--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install lyonzin/knowledge-rag rag-deep-dive --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/workflow/rag-deep-dive .gemini/skills/rag-deep-dive && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .gemini/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install lyonzin/knowledge-rag rag-deep-diveInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/workflow/rag-deep-dive .github/skills/rag-deep-dive && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .github/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install lyonzin/knowledge-rag rag-deep-dive --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/lyonzin/knowledge-rag.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/workflow/rag-deep-dive .opencode/skills/rag-deep-dive && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "rag-deep-dive" agent skill from https://github.com/lyonzin/knowledge-rag/tree/master/skills/workflow/rag-deep-dive into .opencode/skills/rag-deep-dive/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "rag-deep-dive", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
rag-deep-diveThree-step multi-tool workflow — search the corpus, fetch the most relevant document in full, then find similar documents.
RAG Deep Dive is an agent skill from lyonzin/knowledge-rag. Three-step multi-tool workflow — search the corpus, fetch the most relevant document in full, then find similar documents. Use when a single searchknowledge hit is not enough because the user asked a "how does X work end to end" or "explain the pattern" or "give me the full picture" question. Prevents shallow answers on complex topics.
Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in AI & LLM Engineering, covering Retrieval-augmented generation. It works with Model Context Protocol. The repository describes itself as: Local RAG MCP server for Claude Code — hybrid search (semantic + BM25), cross-encoder reranking, 13 MCP tools, 20 format parsers. Zero external servers, zero API keys. The licence is MIT.
3 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit df9cccb. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
RAG Deep Dive loads about 1.6k tokens when it runs. Until then it costs about 88 tokens; SKILL.md has 473 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from lyonzin/knowledge-rag at commit df9cccb, republished under its MIT licence (© lyonzin). 473 words, ~1,569 tokens.
.claude/skills/rag-deep-dive/SKILL.md (or your agent's skills folder).Trigger this skill when the user asks something that needs breadth AND depth:
Do NOT trigger for:
rag-check-first alone is enoughThe agent runs a 3-tool chain in a fixed order:
search_knowledge — find candidatesget_document — read the top match in fullsearch_similar — find related materialThen synthesizes an answer that pulls from all three, cites each source, and flags gaps.
Search — cast a wide net:
search_knowledge(query="<user's topic>", max_results=8, snippet_mode=true, min_score=0.15)Wider than usual (8 not 5) because we want candidate diversity for the similar-search step.
Fetch — read the winner in full:
get_document(filepath="<top_hit.source>")The full document, not just the chunk. This gives you sections that adjacent chunks did not surface.
Find similar — discover the surrounding graph:
search_similar(filepath="<top_hit.source>", max_results=5)These are documents ChromaDB considers semantically close to the top hit. Often surfaces the "obvious next document" that keyword search missed.
Cross-reference the 3 result sets. Look for:
get_document.Structure the answer:
Example 1 — "How does the ingestion pipeline work?"
Agent (internal):
1. search_knowledge(query="document ingestion pipeline chunks embedding", max_results=8)
→ 6 hits: ingestion.md (0.88), parsers.md (0.72), chunker.md (0.69), embeddings.md (0.65),
fastembed.md (0.61), watchdog.md (0.55)
2. get_document(filepath="docs/ingestion.md")
→ 4200-char full doc: 5 sections (parsing / chunking / embedding / storage / watcher)
3. search_similar(filepath="docs/ingestion.md", max_results=5)
→ 5 hits: ADR-0007-parser-choice.md, storage-format.md, chromadb-tuning.md,
benchmark-ingestion.md, migration-v4.md
4. Synthesized reply:
"The ingestion pipeline has 5 stages [docs/ingestion.md]:
1. Parsing — dispatcher maps extension to parser [ingestion.py:174]
2. Chunking — markdown-aware or code-aware per format [chunker.md]
3. Embedding — FastEmbed ONNX lazy-loaded [embeddings.md]
4. Deduplication — SHA256 [ingestion.md#dedup]
5. Storage — ChromaDB with WAL mode [chromadb-tuning.md]
The parser choice per format is documented in ADR-0007 [docs/adr/0007-parser-choice.md].
Recent migration notes: [docs/migration-v4.md].
Not covered by the corpus: the exact chunk-size tuning for large PDFs — you may want
to open an ADR on this if it comes up often."Example 2 — "Walk me through OAuth2 flow in our services"
Agent (internal):
1. search_knowledge(query="oauth2 flow authorization refresh", max_results=8)
→ 4 hits: adr/0018-auth.md, oauth-runbook.md, auth-service.md, token-storage.md
2. get_document(filepath="docs/adr/0018-auth.md")
→ Full ADR with 3 diagrams + decision + consequences
3. search_similar(filepath="docs/adr/0018-auth.md", max_results=5)
→ adr/0019-mtls.md, session-management.md, refresh-token-rotation.md,
audit-logging.md, revocation.md
4. Reply weaves them together with explicit citations, calls out that
adr/0019-mtls.md is about the S2S path (adjacent decision), and flags
that "token revocation on user logout" is only mentioned in passing —
worth clarifying with the security team.get_document for completeness; then either lean on similar-search or run a 2nd search with different keywords.search_similar returns the same file — expected for near-unique docs; move on.rag-check-first.rag-check-first — the prerequisite (deep-dive is check-first + 2 more tools).rag-cite-sources — even more important on deep-dive because you are quoting many sources.rag-web-fallback — if the corpus does not cover the topic in depth, the deep-dive itself will surface that gap and you can chain to web search.© lyonzin, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/workflow/rag-deep-dive of lyonzin/knowledge-rag.
Open the folder on GitHubat commit df9cccb
RAG Deep Dive next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| RAG Deep Dive this skilllyonzin/knowledge-rag | 292 | — | ~1.6k | Automated safety check: Pass | MIT | |
| MCP Local RAGshinpr/mcp-local-rag | 411 | — | ~4.4k | Automated safety check: Pass | MIT | |
| Local RAG Searchnkapila6/mcp-local-rag | 134 | 1 repos | ~1.6k | Automated safety check: Pass | MIT | |
| AutoRAG Setup and RepairMarker-Inc-Korea/AutoRAG | 5.1k | — | ~5.5k | Automated safety check: Pass | MIT | |
| Sciverseopendatalab/Sciverse-Agent-Tools | 119 | — | ~3k | Automated safety check: Pass | Custom licence | |
| Pgvector Semantic Searchtimescale/pg-aiguide | 1.9k | — | ~3.8k | Automated safety check: Pass | Apache-2.0 |
shinpr/mcp-local-rag
Searches, saves, and maintains a local document index through a local RAG MCP server.
nkapila6/mcp-local-rag
Efficiently perform web searches using the mcp-local-rag server with semantic similarity ranking.
Marker-Inc-Korea/AutoRAG
Installs, configures, and repairs AutoRAG's search model, approved folders, indexes, and datasources, and registers its Lite MCP server.
opendatalab/Sciverse-Agent-Tools
A skill your agent uses when the user needs academic paper retrieval — searching scientific literature by author/year/journal, finding paper chunks for RAG-style citations, or expanding original…
timescale/pg-aiguide
A skill your agent uses for setting up vector similarity search with pgvector for AI/ML embeddings, RAG applications, or semantic search.
timescale/pg-aiguide
A skill your agent uses to implement hybrid search combining BM25 keyword search with semantic vector search using Reciprocal Rank Fusion (RRF).
lyonzin/knowledge-rag
Before answering any technical question, code request, architecture decision, or factual claim, call searchknowledge to check the local corpus.
lyonzin/knowledge-rag
Every technical claim drawn from the local corpus must ship with a source citation formatted as path:line or path:section.
lyonzin/knowledge-rag
When performing code review on a PR, diff, snippet, or "look at this change" request, first consult the corpus for related ADRs, coding standards, prior patterns, and similar files.
lyonzin/knowledge-rag
When the user reports a bug, error message, stack trace, unexpected behavior, or "why is this broken" question, search the corpus first for prior occurrences, known fixes, or related runbooks.
lyonzin/knowledge-rag
Measure retrieval quality using evaluateretrieval (MRR@5 and Recall@5) and getindexstats.
lyonzin/knowledge-rag
After making a non-obvious architectural decision, solving a novel bug, agreeing on a coding standard, or reaching a conclusion worth remembering, index it back into the knowledge base so the next…
Works with
Categories
Three-step multi-tool workflow — search the corpus, fetch the most relevant document in full, then find similar documents. RAG Deep Dive is an agent skill from lyonzin/knowledge-rag. Three-step multi-tool workflow — search the corpus, fetch the most relevant document in full, then find similar documents.
RAG Deep Dive fits situations like: A single searchknowledge hit is not enough because the user asked a how does X work end to end; explain the pattern; give me the full picture question.
Run `npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a claude-code`. Or copy the skill folder (skills/workflow/rag-deep-dive in lyonzin/knowledge-rag) into .claude/skills/rag-deep-dive in your project. Claude Code loads it when a task matches its description.
Run `npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a codex`. Or copy the skill folder (skills/workflow/rag-deep-dive in lyonzin/knowledge-rag) into .agents/skills/rag-deep-dive in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add lyonzin/knowledge-rag --skill rag-deep-dive -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/rag-deep-dive, .gemini/skills/rag-deep-dive, .github/skills/rag-deep-dive and .opencode/skills/rag-deep-dive in your project.
SKILL.md names no scripts, command-line tools or credentials: RAG Deep Dive is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
RAG Deep Dive is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.6k tokens (SKILL.md is roughly 6.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with RAG Deep Dive: MCP Local RAG (shinpr/mcp-local-rag, 411 stars), Local RAG Search (nkapila6/mcp-local-rag, 134 stars), AutoRAG Setup and Repair (Marker-Inc-Korea/AutoRAG, 5.1k stars) and Sciverse (opendatalab/Sciverse-Agent-Tools, 119 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
lyonzin (a GitHub user) maintains it in lyonzin/knowledge-rag, which has 292 GitHub stars. The repository holds 10 skills in this directory. The repository was last updated on October 4, 2026.
Source: lyonzin/knowledge-rag on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.