A Simple MCP RAG with GroundX
Wellknown found it in public sources; nobody has proven control of it yet. Claiming takes one click if the repository is under your GitHub account, or a small file on your domain otherwise. Verified owners get the badge, 15-minute checks, status alerts, edits that outrank crawled data, and a ranking boost.
Agents can do it too: POST https://wellknown.network/api/v1/claims with {"agent":"iflow-mcp-mcp-rag","method":"well_known_file"} — machine-readable steps at claim.json, guide at /docs/claim.
Everything here was measured by our prober or read from a registry. Nothing is self-reported.
Attributed to the source that supplied each field. Treated as claims, not facts.
# MCP-RAG: Model Context Protocol with RAG 🚀 A powerful and efficient RAG (Retrieval-Augmented Generation) implementation using GroundX and OpenAI, built with Modern Context Processing (MCP). ## 🌟 Features - **Advanced RAG Implementation**: Utilizes GroundX for high-accuracy document retrieval - **Model Context Protocol**: Seamless integration with MCP for enhanced context handling - **Type-Safe**: Built with Pydantic for robust type checking and validation - **Flexible Configuration**: Easy-to-customize settings through environment variables - **Document Ingestion**: Support for PDF document ingestion and processing - **Intelligent Search**: Semantic search capabilities with scoring ## 🛠️ Prerequisites - Python 3.12 or higher - OpenAI API key - GroundX API key - MCP CLI tools ## 📦 Installation 1. Clone the repository: ```bash git clone <repository-url> cd mcp-rag ``` 2. Create and activate a virtual environment: ```bash uv sync source .venv/bin/activate # On Windows, use `.venv\Scripts\activate` ``` ## ⚙️ Configuration 1. Copy the example environment file: ```bash cp .env.example .env ``` 2. Configure your environment variables in `.env`: ```env GROUNDX_API_KEY="your-groundx-api-key" OPENAI_API_KEY="your-openai-api-key" BUCKET_ID="your-bucket-id" ``` ## 🚀 Usage ### Starting the Server Run the inspect server using: ```bash mcp dev server.py ``` ### Document Ingestion To ingest new documents: ```python from server import ingest_documents result = ingest_documents("path/to/your/document.pdf") print(result) ``` ### Performing Searches Basic search query: ```python from server import process_search_query response = process_search_query("your search query here") print(f"Query: {response.query}") print(f"Score: {response.score}") print(f"Result: {response.result}") ``` With custom configuration: ```python from server import process_search_query, SearchConfig config = SearchConfig( completion_model="gpt-4", bucket_id="custom-bucket-id" …
Mapped onto the structured taxonomy from declared text and observed tool names. Confidence shown for derived entries.
Every source is kept verbatim. Field changes are logged as events.