Enables secure storage of API keys and environment variables through .env files.
Used for version control and installation of the application.
Integrates with OpenAI's GPT-4 model to power the multi-agent AI system, enabling intelligent customer service for Mercadinho Mercantes.
Referenced as a product example in the store's inventory that customers can inquire about and schedule store visits to see.
Uses Python 3.8+ as the backend language for the MCP server implementation.
Provides a modern, responsive web interface for customer interaction with the AI agents through real-time chat.
Mercadinho Mercantes - Multi-Agent AI Assistant
A sophisticated multi-agent AI system for Mercadinho Mercantes, a Brazilian retail chain. This system provides intelligent customer service through multiple specialized AI agents that can handle product inquiries, sales assistance, customer management, and store operations.
🏪 About Mercadinho Mercantes
Mercadinho Mercantes is a proud Brazilian retail company with multiple locations across São Paulo and Rio de Janeiro. Our AI assistant system enhances customer experience by providing personalized product recommendations, promotional information, and seamless appointment scheduling.
✨ Features
🤖 Multi-Agent Architecture
- Reception Agent: Welcomes customers and directs them to appropriate services
- Sales Agent: Handles product inquiries, recommendations, and sales assistance
- Customer Maintenance Agent: Manages existing customer accounts and special discounts
🛍️ Core Functionality
- Product Catalog: Browse available products with pricing and inventory
- Store Information: Find store locations and contact details
- Promotional System: Access store-specific promotions and discounts
- Customer Management: Track customer profiles and loyalty benefits
- Appointment Scheduling: Book store visits and product reservations
- Special Discounts: Exclusive offers for registered customers
🛠️ Technical Features
- MCP Integration: Model Context Protocol for tool calling
- Streamlit UI: Modern, responsive web interface
- Real-time Chat: Interactive conversation with AI agents
- Tool Visualization: Transparent view of AI tool usage
- Session Management: Persistent conversation history
🚀 Quick Start
Prerequisites
- Python 3.8 or higher
- OpenAI API key
- Git
Installation
- Clone the repository
- Install dependencies
- Set up environment variablesOr create a
.env
file:
Running the Application
- Start the MCP server (in one terminal):
- Launch the Streamlit client (in another terminal):
- Open your browser and navigate to the URL shown in the Streamlit output (typically
http://localhost:8501
)
🏗️ Architecture
System Components
Agent Roles
Reception Agent (RecepcaoAssistente
)
- Purpose: Initial customer contact and routing
- Responsibilities:
- Welcome customers to Mercadinho Mercantes
- Present company information and website
- Route customers to appropriate specialized agents
- Handle general inquiries
Sales Agent (VendasAssistente
)
- Purpose: Product sales and recommendations
- Responsibilities:
- Show available products and inventory
- Provide product recommendations
- Handle promotional offers
- Schedule store visits
- Process sales inquiries
Customer Maintenance Agent (ManutencaoSocioAssistente
)
- Purpose: Existing customer support and loyalty management
- Responsibilities:
- Verify customer membership status
- Apply special discounts for members
- Handle product reservations
- Manage customer accounts
Available Tools (MCP Functions)
Tool | Description | Parameters |
---|---|---|
get_produtos_disponiveis() | Retrieve available products | None |
get_lojas() | Get store locations and information | None |
get_promocao_por_loja(id_loja) | Get promotions for specific store | id_loja: int |
get_info_cliente(nome) | Get customer information | nome: str |
reservar_pedido_com_desconto() | Reserve order with discount | id_loja, id_cliente, data_hora |
agenda_visita_para_compra() | Schedule store visit | id_loja, data_hora |
📊 Data Structure
Products
- Categories: Hortifruit, Electronics
- Information: ID, name, category, price, quantity
- Examples: Bananas, Apples, PlayStation 5, LED TV
Stores
- Locations: São Paulo (Parelheiros, Mooca), Guarujá, Santo André, Rio de Janeiro (Ipanema, Nova Iguaçu)
- Information: ID, name, city, state
Customers
- Types: Regular customers, Members (with special discounts)
- Information: ID, name, associated store, discount eligibility
🎯 Usage Examples
Product Inquiry
Store Visit Scheduling
Customer Discount Check
🔧 Configuration
Environment Variables
OPENAI_API_KEY
: Your OpenAI API key for GPT-4 access
Model Settings
- Model: GPT-4-1106-preview
- Temperature: 0 (deterministic responses)
- Tool Choice: Auto
- Parallel Tool Calls: Disabled
🛡️ Security Considerations
- API keys should be stored securely in environment variables
- Never commit API keys to version control
- Use
.env
files for local development - Consider implementing rate limiting for production use
🤝 Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
📝 License
This project is licensed under the MIT License - see the LICENSE file for details.
🆘 Support
For support and questions:
- Check the Issues page
- Contact the development team
- Visit Mercadinho Mercantes
🔮 Future Enhancements
- Integration with real inventory systems
- Payment processing capabilities
- Multi-language support (Portuguese/English)
- Mobile app development
- Advanced analytics and reporting
- Integration with CRM systems
Built with ❤️ for Mercadinho Mercantes
This server cannot be installed
A sophisticated MCP server that provides intelligent customer service for a Brazilian retail chain through multiple specialized AI agents that handle product inquiries, sales assistance, customer management, and store operations.
Related MCP Servers
- -securityFlicense-qualityMCP server that enables AI assistants to perform SEO automation tasks including keyword research, SERP analysis, and competitor analysis through Google Ads API integration.Last updated -
- -securityAlicense-qualityA Model Context Protocol (MCP) server that provides AI-powered customer support using Cursor AI and Glama.ai integration.Last updated -1PythonMIT License
- -securityAlicense-qualityA Model Context Protocol (MCP) server that provides AI-powered customer support using Cursor AI and Glama.ai integration.Last updated -1PythonMIT License
- -securityFlicense-qualityAn advanced MCP server that implements sophisticated sequential thinking using a coordinated team of specialized AI agents (Planner, Researcher, Analyzer, Critic, Synthesizer) to deeply analyze problems and provide high-quality, structured reasoning.Last updated -124Python