Agentic RAG with MCP Server
Provides tools for entity extraction, query refinement, and relevance checking using OpenAI models.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
π Agentic RAG with MCP Server 
β¨ Overview

Agentic RAG with MCP Server is a powerful project that brings together an MCP (Model Context Protocol) server and client for building Agentic RAG (Retrieval-Augmented Generation) applications.
This setup empowers your RAG system with advanced tools such as:
π΅οΈββοΈ Entity Extraction
π Query Refinement
β Relevance Checking
The server hosts these intelligent tools, while the client shows how to seamlessly connect and utilize them.
Related MCP server: vector-mcp
π₯οΈ Server β server.py
Powered by the FastMCP class from the mcp library, the server exposes these handy tools:
Tool Name | Description | Icon |
| Returns the current date & time | β° |
| Uses OpenAI to extract entities from a query β enhancing document retrieval relevance | π§ |
| Improves the quality of user queries with OpenAI-powered refinement | β¨ |
| Filters out irrelevant content by checking chunk relevance with an LLM | β |
π€ Client β mcp-client.py
The client demonstrates how to connect and interact with the MCP server:
Establish a connection with
ClientSessionfrom themcplibraryList all available server tools
Call any tool with custom arguments
Process queries leveraging OpenAI or Gemini and MCP tools in tandem
βοΈ Requirements
Python 3.9 or higher
openaiPython packagemcplibrarypython-dotenvfor environment variable management
π οΈ Installation Guide
# Step 1: Clone the repository
git clone https://github.com/ashishpatel26/Agentic-RAG-with-MCP-Server.git
# Step 2: Navigate into the project directory
cd Agentic-RAG-with-MCP-Serve
# Step 3: Install dependencies
pip install -r requirements.txtπ Configuration
Create a
.envfile (use.env.sampleas a template)Set your OpenAI model in
.env:
OPENAI_MODEL_NAME="your-model-name-here"
GEMINI_API_KEY="your-model-name-here"π How to Use
Start the MCP server:
python server.pyRun the MCP client:
python mcp-client.pyπ License
This project is licensed under the MIT License.
Thanks for Reading π
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
This server cannot be deployed
Maintenance
Related MCP Connectors
MCP server unifying ERPs, CRMs, APIs and knowledge base for Claude, ChatGPT and Gemini.
MCP server for building and testing AI agents with multi-model experimentation and insights.
The CustomGPT.ai MCP server is a fully managed, RAG-powered endpoint that connects large language models with private knowledge bases and external data sources. It provides tools for retrieval-augmented generation queries (send_message), data ingestion (upload_file), and source listing, enabling AI agents to query private documents like PDFs with high accuracy and real-time citations.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceRAG-enabled MCP server that uses Google Gemini for embeddings and Supabase for vector storage, enabling semantic search and document similarity matching through natural language queries.-
- AlicenseBqualityBmaintenanceA production-grade MCP server for integrating RAG into AI agents, supporting multiple vector databases with enterprise security and dynamic tool selection.716MIT
- FlicenseNot gradedqualityDmaintenanceAn enterprise-ready MCP server that exposes a RAG tool for retrieving relevant context and metadata from a Qdrant vector database using natural language queries.2-
- AlicenseNot gradedqualityCmaintenanceMCP RAG Server is a Python MCP server that indexes documents in multiple formats (Markdown, text, PowerPoint, PDF) using multilingual-e5-large embeddings and enables vector search for retrieval-augmented generation.MIT