codebase-rag-mcp
codebase-rag-mcp
Un servidor de Model Context Protocol (MCP) que convierte cualquier base de código local en una base de conocimiento consultable y fundamentada en citas. Construido sobre un recuperador híbrido (FAISS denso + BM25 disperso), un reordenador opcional y un proveedor de LLM intercambiable (NVIDIA, Groq, OpenRouter, Gemini o cualquier endpoint local compatible con OpenAI).
Estado: solo andamiaje. El paquete se instala, la CLI se ejecuta y el servidor MCP arranca y anuncia una herramienta
pingprovisional. La canalización RAG (ingesta → parseo → fragmentación → indexación → recuperación → reordenamiento → generación) se está construyendo de forma incremental sobre este esqueleto. ConsultaDECISIONS.mdyFLOW.md.
Install
Requiere Python 3.11+.
# Editable install with dev tooling (pytest, ruff, mypy)
pip install -e ".[dev]"Esto incluye tree-sitter, FAISS (CPU), rank-bm25, sentence-transformers, langchain-huggingface / langchain-community, el SDK oficial de MCP para Python y httpx para llamadas salientes a proveedores.
Related MCP server: Grounded Code MCP
Configure
Copia el archivo de entorno de ejemplo y completa las claves de proveedor que tengas:
cp .env.example .env
# then edit .envVariables reconocidas (consulta .env.example para la lista completa):
Variable | Propósito |
| API de NVIDIA NIM / build |
| Groq Cloud |
| OpenRouter (proxy de múltiples proveedores) |
| Google Gemini (opcional) |
| Servidor local compatible con OpenAI (Ollama, vLLM, LM Studio, ...) |
| Nombre del modelo que se usará con el servidor local |
| Token de portador opcional para el servidor local |
|
|
| Dónde residen los corpus ingeridos (por defecto |
| Dónde persisten los artefactos de FAISS / BM25 (por defecto |
Run
# Print the version
codebase-rag --version
# Boot the MCP server over stdio (advertises a 'ping' tool today)
codebase-rag serveDevelop
ruff check . # lint
ruff format --check . # format check
mypy # type-check
pytest # testsUn flujo de trabajo de GitHub Actions preconfigurado en .github/workflows/ci.yml ejecuta los cuatro en cada push.
Layout
src/codebase_rag_mcp/
config.py # python-dotenv loader
cli/main.py # `codebase-rag` entrypoint
mcp/server.py # stdio MCP server (stub)
ingestion/ # file discovery (TBD)
parser/ # tree-sitter AST extraction (TBD)
chunker/ # AST-aware chunking (TBD)
indexing/
vector.py # FAISS dense index (TBD)
bm25.py # rank-bm25 sparse index (TBD)
retrieval/ # hybrid query routing (TBD)
reranker/ # cross-encoder / LLM reranker (TBD)
generation/
providers/ # NVIDIA / Groq / OpenRouter / Gemini / local (TBD)
citations/ # chunk → source citations (TBD)
impact/ # symbol-graph impact analysis (TBD)License
MIT. Consulta LICENSE.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceA local MCP server that provides AI coding assistants with semantic search capabilities over codebases. It indexes code using local embeddings and exposes tools for efficient code retrieval, saving tokens and improving response quality.314MIT
- AlicenseNot gradedqualityBmaintenanceA local MCP server that gives AI coding assistants retrieval access to your personal knowledge base of books, standards, and docs, grounding their answers in sources you trust.MIT
- FlicenseNot gradedqualityDmaintenanceAn MCP server for team documentation and knowledge bases, enabling semantic search over documentation files using local embeddings.
- AlicenseNot gradedqualityDmaintenanceA knowledge base MCP server backed by Qdrant vector database with local embeddings for semantic search and document management.51ISC
Related MCP Connectors
An MCP server that gives your AI access to the source code and docs of all public github repos
Driflyte MCP server which lets AI assistants query topic-specific knowledge from web and GitHub.
Serve a folder of Markdown notes as an MCP server: hybrid search, reading, and sourced answers.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/AyushShanu/CodeBase-MCP-Server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server