The Journey to Conversational Interfaces
Romin Irani | Xoriant | @iRomin
Agenda
Chatbots! Chatbots! Chatbots!
Rule-based v/s AI
Why Slack ?
Respond to Questions
Notifications
Customized Bot
Analyze
Slack API - Go Language packages
Respond
/ticket list
Reporting Issue - Slash Command
/ticket listlist
Handling a Request from Slack
http.HandleFunc("/ticket", MyTicketHandler)
func MyTicketHandler(w http.ResponseWriter, r *http.Request) {
//Extract out multiple params from Request
//Validate if the request is coming from Slack and your team
//Perform business logic
//Compose the Response Struct
json.NewEncoder(w).Encode(/* Slack Response Struct */)
}
Slack Incoming POST parameters
token=oyIQ0AjzcBNgxGMcIsEumUpQ�team_id=T0001�team_domain=example�channel_id=C2147483705�channel_name=general�user_id=U2147483697�user_name=romin�command=/ticket�text=list�response_url=https://hooks.slack.com/commands/1234/5678�
Slack Message Formats - 1
{
"username": "Server Monitor"
"text": "Cloud Storage Service is facing intermittent � issues.\nhttp://status.cloud.google.com",
}
Slack Message Formats - 2
{
"attachments": [
{
"title": "New Ticket: Printer is not working",
"title_link": "https://api.slack.com/",
"text": "The Printer is not functioning….",
"fields": [
{
"title": "Priority",
"value": "High"� },
{
"title": "Reported by",
"value": "romin",
}
],
"footer": "My Help Desk system",
"ts": 1395676789
}
]
}
Notify
Sending Notifications - Incoming Webhook
v := url.Values{"payload": {string(b)}}
http.PostForm(WebhookURL, v)
Analyze
Analytics - Outgoing Webhook
Explosion of Commands
…
/ticket list�/ticket create <title> <details> <priority> <department>�/ticket update <status> <comment>�/ticket close <id>�/ticket view <id>�/ticket help
….
Can we do better?
General AI Agents
Messaging Platforms
NLP , AI as a Service �Platforms
Frameworks & Deployment
Platforms
Our current architecture
Messaging Platforms
NLP
Integrations
Machine Learning
Domains
Bot Endpoint + Logic
How it works?
Diagram inspired from : https://rasa.ai/
Which tickets are assigned to me?
User input in Natural Language
1
NLP Tool
2
intent : tickets_search,
entities:� status : open,� user : romin,� Max_count : 5,
Structured Data
3
Here are your tickets:
1….
2…
3….
Bot output in Natural Language
5
Tickets�API / Database
4
Lessons Learnt
Thank You