A customer support ticket routing system built with LlamaIndex Workflows that demonstrates multi-step processing with sentiment analysis, categorization, priority assignment, and department routing.
This workflow processes customer support tickets through multiple stages:
- Analyze Sentiment - Detects positive/negative sentiment
- Classify Category - Categorizes as Technical, Billing, General, or Complaint
- Check Urgency - Identifies urgent keywords
- Determine Priority - Assigns Low, Medium, High, or Critical priority
- Check Escalation - Determines if manager escalation is needed
- Route to Department - Assigns to Engineering, Finance, Customer Success, or General Support
- Assign Queue - Routes to manager or standard queue
- Generate Response - Creates automated response template
- Finalize Ticket - Returns final ticket output
Run the workflow normally to get the final result:
uipath run agent '{"ticket_id": "T-12345", "customer_message": "The payment system is broken!", "customer_tier": "premium"}'Debug the workflow by breaking at specific events:
uipath debug agent '{"ticket_id": "T-12345", "customer_message": "The payment system is broken!", "customer_tier": "premium"}'When a breakpoint is hit, the execution will pause and you can:
- Inspect the current state
- Resume execution
{
"ticket_id": "T-001",
"customer_message": "URGENT: The application is completely broken and not working!",
"customer_tier": "premium"
}{
"ticket_id": "T-002",
"customer_message": "I'm very disappointed with the incorrect charge on my invoice",
"customer_tier": "standard"
}{
"ticket_id": "T-003",
"customer_message": "How do I reset my password?",
"customer_tier": "standard"
}{
"ticket_id": "T-12345",
"category": "technical",
"priority": "critical",
"assigned_department": "Engineering - Manager",
"requires_escalation": true,
"estimated_resolution_time": 2,
"response_template": "Thank you for contacting us. Your ticket #T-12345 has been assigned to Engineering - Manager with critical priority. Expected resolution time: 2 hours."
}