yeaight7/agent-powerups / plugins/codebase-intelligence/skills/local-rag-mcp
local-rag-mcp
VerifiedUse when querying, ingesting, or maintaining a local RAG MCP corpus for semantic document retrieval with privacy controls.
Local RAG MCP
When to use
Use when the task requires semantic search over a local document corpus and an appropriate local RAG MCP server is available. Prefer standard grep/glob for simple pattern matching — RAG adds value for conceptual queries and cross-document synthesis.
Requirements / Checks
- Verify a local RAG MCP server is configured (
apx mcp listor check MCP settings). - Do NOT attempt to install or spin up Docker containers for vector databases without explicit user permission.
- Confirm whether the embedding provider is local or remote — if remote (e.g., OpenAI), warn the user before ingesting sensitive content.
Workflow
-
Identify need — determine whether the query requires semantic retrieval (conceptual, cross-document) vs. standard grep/glob (exact pattern, single file).
-
Check configuration — verify the connection to the local RAG MCP server. If it fails, surface the error rather than falling back silently.
-
Inventory corpus — use status or list tools to see what's already indexed before ingesting anything.
-
Ingest (only if necessary) — ingest only files explicitly approved for this corpus. Include clear source metadata (file path, ingest timestamp). Exclude:
.envfiles, credential files, SSH keys, and files outside the workspace. -
Query strategy:
- Start with the user's exact terms; do not paraphrase into broader concepts.
- Add one specific disambiguating detail if initial results are too broad.
- Keep result limits small first (top 5); expand only if results are insufficient.
-
Expand around hits — if a top result lacks surrounding context, fetch neighboring chunks before drawing conclusions.
-
Synthesize with citations — in your response, distinguish between retrieved evidence (cite source and chunk) and your own inference.
-
Clean up — delete stale or incorrectly ingested sources when requested; do not accumulate unrelated documents.
Tool Interface (illustrative — actual names depend on your server)
The local RAG server typically exposes tools along these lines:
- query: keyword + semantic search with a score/rank and result limit.
- ingest_file: absolute-path document ingestion.
- ingest_data: string/HTML/Markdown ingestion with source and format metadata.
- delete_source: remove an ingested file or source by ID.
- list_sources / status: corpus inventory and database health.
- get_neighbors: expand context around a specific chunk.
Exact tool names and schemas vary by implementation. Read your server's tool list before assuming names.
Safety Constraints
- Do NOT ingest sensitive personal data, secrets, or
.envfiles into the local RAG store. - Warn the user before ingesting content if the embedding model sends data to a remote API.
- Do not ingest whole repositories by default — start with approved docs or scoped folders.
- Do not treat a semantic match as ground truth without reading the source chunk in context.
Validation / Done Criteria
- Relevant context was retrieved and cited.
- Ingestion explicitly excluded sensitive paths.
- Query result synthesis distinguishes retrieved evidence from inference.
References
references/rag-tool-model.md
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 469k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 321k | Updated | Claude CodeCodex | Verified | Install |