# ποΈ IT Ticket AI System
A multi-agent AI system for intelligent IT ticket management with natural language processing, trend analysis, and automated insights.
- π€ Multi-Agent Architecture - Specialized AI agents for different tasks
- π Analytics Agent - Real-time trend analysis and pattern detection
- π£οΈ Natural Language Interface - Conversational AI responses (no more JSON!)
- π Agent-to-Agent Communication - Seamless task delegation via A2A protocol
- π οΈ MCP Tools - Model Context Protocol for ticket operations
- π― Intelligent Routing - Queries automatically routed to the right agent
- Python 3.9+
- OpenAI API key (set as environment variable
OPENAI_API_KEY) - Required packages:
pip install -r requirements.txt
Option A: PowerShell Script (Recommended)
.\START_ALL.ps1Option B: Manual Startup
# Start each service in order
Start-Process python -ArgumentList "a2a_protocol/real_a2a_server.py"
Start-Sleep -Seconds 2
Start-Process python -ArgumentList "mcp_server/real_mcp_server.py"
Start-Sleep -Seconds 2
Start-Process python -ArgumentList "agents/real_analytics_agent.py"
Start-Sleep -Seconds 2
Start-Process python -ArgumentList "agents/real_main_agent.py"
Start-Sleep -Seconds 2
Start-Process streamlit -ArgumentList "run ui/full_agent_app.py"Open your browser to: http://localhost:8501
βββββββββββββββββββββββββββββββββββ
β Full Agent App (Streamlit) β β User Interface
β Port 8501 β
ββββββββββββββ¬βββββββββββββββββββββ
β
βββββββ΄ββββββ¬ββββββββββββββββ
β β β
βββββΌβββββ βββββΌββββββ βββββββΌβββββββ
β A2A β β MCP β β OpenAI β
β Server β β Server β β API β
β 9090 β β 8080 β ββββββββββββββ
βββββ¬βββββ βββββββββββ
β
ββββ΄βββββββββββββββ
β β
βββββΌβββββββββββ ββββΌβββββββββββββ
β Analytics β β Main Agent β
β Agent β β β
ββββββββββββββββ βββββββββββββββββ
-
A2A Server (Port 9090)
- Agent-to-Agent communication protocol
- Task delegation and status management
- Agent registration and discovery
-
MCP Server (Port 8080)
- Model Context Protocol implementation
- Ticket search, analysis, and summarization tools
- Direct access to ticket data
-
Analytics Agent
- Specialized in trend analysis and pattern detection
- Processes complex analytical queries
- Returns detailed insights and recommendations
-
Main Agent
- Query orchestration and routing
- Handles general user interactions
- Delegates to Analytics Agent when needed
-
Full Agent App (Streamlit UI)
- Web-based user interface
- Natural language query processing
- AI-powered response conversion
β
"Show tickets assigned to Michael and give trend"
β
"Analyze trends in network issues"
β
"Generate a comprehensive report"
β
"What patterns do you see in high priority tickets?"
β
"Give me insight into hardware failures"
β
"Show me all tickets"
β
"Find tickets assigned to Sarah"
β
"List high priority tickets"
β
"Search for network-related issues"
β
"What's the ticket summary?"
β
"Give me an overview of all tickets"
β
"Show me statistics"
Query: "Show tickets assigned to Michael and give trend"
Response:
π Analytics Agent Response
Based on my analysis of the tickets assigned to Michael, I've reviewed 150 tickets
and discovered some interesting patterns.
The most notable trend is that network issues are on the rise - we're seeing about
a 15% increase compared to previous periods. This is something we should pay attention
to.
Looking at the categories, the top three areas are Network issues, Email problems,
and Hardware-related requests. The priority distribution shows that 60% are Medium
priority, 25% are High priority (needing immediate attention), and 15% are Low priority.
Here are my recommendations:
1. Focus on network infrastructure improvements - With the 15% increase in network
issues, we should investigate the root cause.
2. Consider additional email support resources - Email is a top category, so evaluate
if more support is needed.
3. Monitor hardware failure patterns - Keep an eye on hardware issues to identify
any patterns.
Let me know if you'd like me to dive deeper into any of these areas!
# Check if ports are in use
netstat -ano | findstr ":9090"
netstat -ano | findstr ":8080"
# Stop all Python processes
Get-Process python,streamlit -ErrorAction SilentlyContinue | Stop-Process -Force
# Restart services
.\START_ALL.ps1- Ensure all services start in order (A2A β MCP β Agents β UI)
- Wait 2-3 seconds between starting each service
- Check that
OPENAI_API_KEYenvironment variable is set
it_tickets_project/
βββ a2a_protocol/
β βββ real_a2a_server.py # Agent-to-Agent server
βββ agents/
β βββ real_analytics_agent.py # Analytics specialist
β βββ real_main_agent.py # Main orchestrator
βββ mcp_server/
β βββ real_mcp_server.py # MCP tools server
βββ ui/
β βββ full_agent_app.py # Main Streamlit app
βββ data/
β βββ dummy_it_tickets.csv # Sample ticket data
βββ START_ALL.ps1 # PowerShell startup script
βββ requirements.txt # Python dependencies
βββ README.md # This file
- FINAL_SOLUTION.md - Technical details of the complete solution
- NATURAL_LANGUAGE_RESPONSE.md - How natural language conversion works
- QUICK_START_GUIDE.md - Detailed startup instructions
- SYSTEM_SETUP.md - Comprehensive system setup guide
# Stop all services
Get-Process python,streamlit -ErrorAction SilentlyContinue | Stop-Process -ForceThe system uses GPT-4o-mini to convert technical JSON responses into conversational, human-friendly explanations.
Queries containing keywords like "trend", "analysis", "pattern", or "insight" are automatically routed to the Analytics Agent.
If the Analytics Agent is unavailable, the system falls back to:
- MCP trend analysis tools
- MCP search tools
- Direct AI response
The Analytics Agent processes queries in real-time and provides:
- Trend analysis
- Pattern detection
- Statistical summaries
- Actionable recommendations
- Start queries with action words: "Show", "Analyze", "Find", "Generate"
- Be specific: "Network issues in Q4" vs "issues"
- Use natural language: Ask as you would ask a colleague
- Try different phrasings if results aren't what you expect
β
Multi-Agent Architecture - Working
β
Natural Language Responses - Working
β
Analytics Agent - Working
β
Task Delegation - Working
β
Real-Time Analysis - Working
β
Fallback Mechanisms - Working
This project is for internal use and demonstration purposes.
For issues or questions, refer to the documentation files or check the troubleshooting section above.
Enjoy your intelligent IT ticket management system! π