Model Context Protocol Server
🚀 Agentic RAG 与 MCP 服务器
✨ 概述

带有 MCP 服务器的 Agentic RAG是一个强大的项目,它将 MCP(模型上下文协议)服务器和客户端结合在一起,用于构建Agentic RAG (检索增强生成)应用程序。
此设置为您的 RAG 系统提供了高级工具,例如:
🕵️♂️实体提取
🔍查询细化
✅相关性检查
服务器承载这些智能工具,而客户端展示如何无缝连接和使用它们。
Related MCP server: MCP-RAGNAR
🖥️ 服务器 — server.py
在mcp库的FastMCP类的支持下,服务器公开了以下便捷的工具:
工具名称 | 描述 | 图标 |
| 返回当前日期和时间 | ⏰ |
| 使用OpenAI从查询中提取实体——增强文档检索相关性 | 🧠 |
| 利用OpenAI 支持的改进技术提高用户查询的质量 | ✨ |
| 通过使用 LLM 检查块相关性来过滤不相关的内容 | ✅ |
🤝 客户端 — mcp-client.py
客户端演示如何与 MCP 服务器连接并交互:
与
mcp库中的ClientSession建立连接列出所有可用的服务器工具
使用自定义参数调用任何工具
利用OpenAI 或 Gemini和 MCP 工具协同处理查询
⚙️ 要求
Python 3.9 或更高版本
openaiPython 包mcp库python-dotenv用于环境变量管理
🛠️ 安装指南
# 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🔐 配置
创建
.env文件(使用.env.sample作为模板)在
.env中设置你的 OpenAI 模型:
OPENAI_MODEL_NAME="your-model-name-here"
GEMINI_API_KEY="your-model-name-here"🚀 如何使用
启动 MCP 服务器:
python server.py运行 MCP 客户端:
python mcp-client.py📜 许可证
该项目已获得MIT 许可。
感谢阅读🙏
This server cannot be deployed
Maintenance
Related MCP Connectors
Cloud or self-hosted knowledge for AI agents: hybrid search, reranking, GraphRAG, scoped MCP tools.
Ingest, manage, and retrieve documents for RAG-powered AI applications
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.
AI Reasoning Cache & Consensus Layer with 11 MCP tools via Streamable HTTP.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn intelligent codebase processing server that provides agentic RAG capabilities for code repositories, enabling semantic search and contextual understanding through self-evaluating retrieval loops.2MIT
- AlicenseNot gradedqualityDmaintenanceA local RAG server that enables document indexing and sentence window retrieval across multiple file formats like PDF, MD, and DOCX. It supports both local Hugging Face models and OpenAI embeddings for efficient context-aware querying through the Model Context Protocol.GPL 3.0
- FlicenseNot gradedqualityDmaintenanceThe MCP server provides tools for entity extraction, query refinement, and relevance checking to enhance RAG applications by integrating with OpenAI and Gemini.-
- AlicenseNot gradedqualityDmaintenanceRAGX MCP Server enables retrieval-augmented generation with document ingestion, hybrid search, and agentic answering using Claude, exposing tools for querying, searching, and managing documents.2MIT