tiempo-mcp
Un sistema de inteligencia artificial agente mínimo que responde preguntas generales y relacionadas con el tiempo mediante un proceso de LLM aumentado con herramientas.
Características
- API de Flask : proporciona la marca de tiempo actual.
- Servidor de agente MCP : agente de razonamiento que detecta la intención del usuario, llama a herramientas (como la API de tiempo), genera indicaciones e interactúa con un LLM a través de OpenRouter (API compatible con OpenAI).
- Interfaz de usuario optimizada : interfaz de chat sencilla para hablar con el agente de IA.
Configuración
1. Clonar e instalar dependencias
2. Variable de entorno
Configure su clave API de OpenRouter (obtenga una en https://openrouter.ai ):
3. Ejecutar los servidores
Abra tres terminales (o utilice procesos en segundo plano):
Terminal 1: API de tiempo de Flask
Terminal 2: Servidor del agente MCP
Terminal 3: Interfaz de usuario optimizada
La interfaz de usuario de Streamlit se abrirá en su navegador (predeterminado: http://localhost:8501 )
Uso
- Pregúntele cualquier pregunta al agente en la interfaz de usuario de Streamlit.
- Si preguntas la hora (por ejemplo, "¿Qué hora es?"), el agente llamará a la API de Flask, obtendrá la hora actual y elaborará una respuesta hermosa y natural utilizando el LLM.
- Para otras preguntas, el agente responderá utilizando únicamente el LLM.
Arquitectura
- El agente MCP detecta la intención, llama a las herramientas según sea necesario, diseña indicaciones y las envía al LLM.
- Fácilmente extensible para agregar más herramientas (solo agréguelo a la clase MCPAgent).
Personalización
- Agregar más herramientas : implementar nuevos métodos en
MCPAgent
y actualizarself.tools
. - Mejorar la detección de intenciones : ampliar
detect_intent()
enMCPAgent
. - Cambiar el modelo LLM : actualice el campo
model
encall_llm()
.
Requisitos
- Python 3.7+
- Consulte
requirements.txt
para conocer las dependencias.
Créditos
- Desarrollado con Flask, Streamlit, OpenRouter y Python.
- Inspirado en patrones de diseño LLM de agencia.
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Un sistema de inteligencia artificial agente que responde preguntas relacionadas con el tiempo llamando a una herramienta API de tiempo y preguntas generales usando un LLM, accesible a través de una interfaz de chat simple.
Related MCP Servers
- -securityFlicense-qualityA server that routes user questions to specialized agents (date, location, weather) or an LLM expert, with a simple Streamlit web interface for easy interaction.Last updated -Python
- -securityFlicense-qualityAn agentic AI system that orchestrates multiple specialized AI tools to perform business analytics and knowledge retrieval, allowing users to analyze data and access business information through natural language queries.Last updated -2Python
- -securityAlicense-qualityA Model Context Protocol server that provides the current time in any timezone with customizable formatting, allowing AI assistants to access accurate time information.Last updated -PythonMIT License
- AsecurityAlicenseAqualityAn AI agent task management system that provides structure and visualization for long-term task planning with support for the Model Context Protocol (MCP) standard.Last updated -151PythonMIT License