Agentic Swiggy MCP Server
Agentic Swiggy MCP Server
Un servidor de Model Context Protocol (MCP) agéntico, altamente modular y no determinista que simula un asistente de entrega de comida (como Swiggy). Construido con LangGraph, FastMCP y ChromaDB, este servidor aprovecha un agente ReAct inteligente para enrutar tareas dinámicamente, responder preguntas, ofrecer recomendaciones y ejecutar pedidos de comida de forma segura mediante un flujo de trabajo Human-in-the-Loop (HITL).
Funciones Principales
Agente ReAct No Determinista: El agente decide dinámicamente qué herramientas usar según el contexto conversacional, sin flujos de trabajo codificados de forma rígida.
Human-In-The-Loop (HITL): Los pedidos se interceptan de forma segura. El agente interrumpe su ejecución para pedir autorización humana antes de finalizar cualquier transacción real.
Ingesta RAG de Múltiples Formatos: Un pipeline de ingesta desacoplado que universalmente agrega, parsea y procesa archivos
.json,.csv,.md,.txty.pdfen un almacén vectorial local de ChromaDB.Recomendaciones Contextuales: Recomienda el top 3 de platos evaluados dinámicamente según la ubicación geográfica actual del usuario y la hora del día.
Model Context Protocol (MCP): Expone las capacidades del agente como herramientas MCP estandarizadas, haciéndolas detectables y utilizables por clientes LLM modernos (como Claude Desktop).
Embeddings 100% Locales: Soporte integrado para los
sentence-transformersde HuggingFace, lo que permite obtener embeddings vectoriales sin costo ni conexión.
Related MCP server: Food402
Estructura del Proyecto
swiggy_agent/
├── data/
│ ├── restaurants_menu.json # Restaurant catalog & timings
│ ├── order_history.json # Past & active order records
│ ├── food_reviews.csv # Customer reviews & sentiment
│ └── platform_policies.md # Packaging & late-night guidelines
├── src/
│ ├── ingestion.py # Multi-format universal data ingestor
│ ├── tools/
│ │ ├── __init__.py
│ │ ├── order_tool.py # Tool 1: Order Food (HITL sensitive)
│ │ ├── recommendation_tool.py # Tool 2: Geo/Time Recommendations
│ │ ├── history_tool.py # Tool 3: Order tracking & history
│ │ └── rag_tool.py # Tool 4: Review retrieval RAG
│ ├── agent.py # Non-deterministic LangGraph agent + HITL
│ └── mcp_server.py # FastMCP Server exposing tools
├── requirements.txt
├── .env # Environment variables (API Keys)
└── main.py # Entry point for interactive CLI testingConfiguración e Instalación
1. Instalar Dependencias
Asegúrate de tener instalado Python 3.10+. Instala los paquetes requeridos:
pip install -r requirements.txt
# Alternatively, install manually:
pip install mcp langchain langchain-openai langchain-huggingface langchain-chroma langgraph chromadb sentence-transformers python-dotenv2. Configurar Variables de Entorno
Crea un archivo .env en el directorio raíz y añade tus claves de API de LLM (p. ej., Google Gemini, OpenAI o Groq):
# Example using Google Gemini (Recommended for free tier)
GEMINI_API_KEY=your_api_key_here
# Example using OpenAI (If applicable)
# OPENAI_API_KEY=your_api_key_here3. Inicializar la Base de Datos Vectorial
Antes de ejecutar el agente, ingilla los datos sintéticos para construir el almacén vectorial local de ChromaDB:
python src/ingestion.pyUso
Opción 1: Ejecutar la Demo Interactiva del Agente
Prueba el agente de LangGraph y el flujo de trabajo de pedidos Human-in-the-Loop a través de la terminal:
python main.pyPrueba un prompt como: "Hola, soy USR_500 en Koramangala a las 21:00. ¿Qué hay algo bueno por aquí? Revisa las reseñas para ver qué opina la gente y, si está bien valorado, pide 1 porción para 5th Block."
Opción 2: Iniciar el Servidor MCP
Para exponer las herramientas a un cliente compatible con MCP (como Claude Desktop o una aplicación externa):
python src/mcp_server.pyReferencia de Herramientas
Herramienta | Descripción | Salida |
| Hace un pedido de comida. Activa una interrupción en el gradofed que requiere una autorización | Confirmación JSON |
| Evalúa restaurantes locales basados en | Matriz JSON |
| Recupera datos de pedidos activos y pasados para un ID de usuario concreto. | Diccionario JSON |
| Realiza una búsqueda semántica RAG en reseñas, menús y políticas de la plataforma. | Texto Markdown |
Licencia
MIT 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
- FlicenseNot gradedqualityDmaintenanceA proof-of-concept Model Context Protocol server that enables LLM applications to interact with Uber Eats, allowing AI agents to browse and order food through natural language.235
- AlicenseNot gradedqualityDmaintenanceAn MCP server that enables AI assistants to order food from TGO Yemek by browsing restaurants, managing carts, and completing checkouts. It allows users to handle address selection and order tracking directly through natural language interactions.3714MIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server that enables AI agents to discover restaurants and place food delivery orders on Uber Eats and Thuisbezorgd (Just Eat Takeaway). It provides tools for restaurant discovery and order management through normalized platform APIs.22MIT
- AlicenseAqualityDmaintenanceMCP server for Chipotle — let AI agents find locations, browse menus, build custom orders, and checkout for pickup or delivery.41850MIT
Related MCP Connectors
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
MCP server providing access to the Scorecard API to evaluate and optimize LLM systems.
MCP server for AI dialogue using various LLM models via AceDataCloud
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/Ichibu013/Swiggy-Agentic-MCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server