1 个 Skill
# PinRAG MCP tools
Use this skill whenever the **PinRAG** MCP server is running. The server
process is named `pinrag-mcp`; it is launched automatically from your editor's
MCP configuration via `uvx --from pinrag pinrag-mcp` (or from PATH after
`pipx install pinrag` / `uv tool install pinrag`).
## Prerequisites
- **API keys:** Set `ANTHROPIC_API_KEY` and/or `OPENAI_API_KEY` in the MCP
`env` block. Default setup: Anthropic LLM + OpenAI embeddings (both keys
required). OpenAI-only: set `PINRAG_LLM_PROVIDER=openai` and only
`OPENAI_API_KEY`. See the [PinRAG README](https://github.com/ndjordjevic/pinrag#installation).
- **uv:** Required when using `uvx`. Install from [docs.astral.sh/uv](https://docs.astral.sh/uv/).
- **Stable index path:** Set `PINRAG_PERSIST_DIR` to an absolute path (e.g.
`~/.pinrag/chroma_db`) so the vector store is not tied to the editor's
working directory.
## Tools
| Tool | When to use | Key parameters |
|------|-------------|----------------|
| `query_tool` | Answer questions over the index; returns answer with citations | Required: `query`. Optional: `document_id`, `tag`, `document_type`, `page_min`, `page_max` (PDF), `file_path` (GitHub), `response_style` (`thorough` or `concise`) |
| `add_document_tool` | Index local files, directories, or any supported URL in one call | Required: `paths` (list of strings — file paths, dirs, YouTube/playlist URLs, GitHub URLs). Optional: `tags` (list, one per path) |
| `add_url_tool` | Index a single YouTube video/playlist or GitHub repo URL | Required: `url` |
| `list_documents_tool` | List indexed documents and chunk counts | Optional: `tag` to filter |
| `remove_document_tool` | Remove a document from the index | Required: `document_id` (from `list_documents_tool`) |
`add_document_tool` accepts both local paths **and** URLs in a single call;
use `add_url_tool` only when the user provides a single URL and no local paths.
## MCP resources and prompt
- `pinrag://documents` — indexed documents (read in the MCP resources panel).
- `pinrag://server-config` — effective config: LLM, embeddings, API key
status, chunking settings.
- Prompt `use_pinrag` (parameter: `request`) — for combined flows when the
host supports MCP prompts.
## Workflow
1. Identify what the user wants:
- Question / search → `query_tool`
- "Index / add …" → `add_document_tool` (files, dirs, or mixed paths+URLs);
single URL only → `add_url_tool`
- "List / show documents" → `list_documents_tool`
- "Remove / delete …" → `remove_document_tool` (obtain `document_id` first
with `list_documents_tool` if not given)
2. Call the tool with required parameters; add optional filters as appropriate.
3. Return the result verbatim — citations (page numbers, timestamps, file paths)
are embedded in the server response.
## Examples
- "What does the amiga-book PDF say about AGA?" →
`query_tool` `{"query": "What does it say about AGA?", "tag": "AMIGA"}`
- "Index ~/papers with tag ml" →
`add_document_tool` `{"paths": ["~/papers"], "tags": ["ml"]}`
- "Add this YouTube video https://youtu.be/abc" →
`add_url_tool` `{"url": "https://youtu.be/abc"}`
- "Index the LangChain repo" →
`add_document_tool` `{"paths": ["https://github.com/langchain-ai/langchain"]}`
- "List documents" →
`list_documents_tool` `{}`
- "Remove document 42" →
`remove_document_tool` `{"document_id": "42"}`
- "Search only in document intro.pdf for chunking" →
`query_tool` `{"query": "chunking", "document_id": "intro.pdf"}`
If PinRAG is not configured, direct the user to
[PinRAG installation](https://github.com/ndjordjevic/pinrag) or this plugin's
`.mcp.json`.相关插件
PinRAG↓ 2
面向编辑器或 CLI 的 RAG:索引 PDF、YouTube、GitHub 仓库与 Discord 导出内容,并带引用进行查询。NotebookLM MCP↓ 62
NotebookLM MCP:全自动操作 Google NotebookLM——问答引用、播客/视频/信息图生成,27 个工具。GitHub MCP Server↓ 39
GitHub MCP Server:访问仓库数据、用户画像、Trending、提交历史与开源分析。Academic Research MCP Server↓ 37
学术文献 MCP 服务器:论文搜索、引用分析、作者检索与学术发现,基于 Apify 云基础设施。Memstate AI↓ 25
为 AI agent 提供版本化的结构化记忆,追踪每个事实并记录每次变更,确保 agent 始终获取最新答案而非过时上下文。在复杂的多会话编码任务中,其记忆检索与召回表现优于 mem0(84.4% vs 20.4%)。WoopSocial social media scheduler↓ 17
通过远程 MCP server 创建、排期并发布社交媒体内容,覆盖 LinkedIn、X、Instagram、Facebook、Pinterest、TikTok、YouTube 等平台。Talonic↓ 8
从 PDF、扫描件、图片、表格与表单中提取结构化、经 schema 校验的数据,让 AI agent 通过 Model Context Protocol 从任意文档抽取干净的 JSON。Alai↓ 7
借助 Alai 的 MCP 用 AI 创建、编辑并导出高质量演示文稿,支持幻灯片生成、编辑以及导出为 PowerPoint 或 PDF。