Confoo - Vancouver and
Montréal
My first (dummy) bots
Initial attempts
Cassandra helping to colect data
Machine Learning making smart bots
Epic Fails
Resources
Évariste
Bot analysis: It's a greeting
Bot analysis: It's a question
Évariste
Bot analysis: It's a greeting
Bot analysis: It's a question
Évariste
if {
} else {
if {
} else {
if {
} else {
if {
...
Refine the cases and answers
Bot analysis: It's a greeting
Bot analysis: It's a question
Mom
New Contacts
Bot analysis: It's a greeting
Bot analysis: It's a question
Évariste
chat_timestamp | sender | message |
---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... |
2015-08-27-14:11:00 | Hanneli T. | Certo |
chat_timestamp | sender | message | message_category |
---|---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... | Informative |
2015-08-27-14:11:00 | Hanneli T. | Certo | Motivational |
chat_timestamp | sender | message | message_category |
---|---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... | Informative |
2015-08-27-14:11:00 | Hanneli T. | Certo | Motivational |
2015-10-05-14:19:00 | Leandro P. | https://i.imgur.com/sSOmKqw.gifv | GIF |
chat_timestamp | sender | message | message_category |
---|---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... | Informative |
2015-08-27-14:11:00 | Hanneli T. | Certo | Motivational |
2015-10-05-14:19:00 | Leandro P. | https://i.imgur.com/sSOmKqw.gifv | GIF |
chat_by_category
chat_timestamp | sender | message | language |
---|---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... | Portuguese |
2015-08-27-14:11:00 | Évariste G. | Je ne sais... | French |
2015-10-05-14:19:00 | Anton T. | Привіт | Ukrainian |
chat_by_language
chat_timestamp | sender | message | allow | message_category |
---|---|---|---|---|
2015-08-27-14:11:00 | Ilma R. | Só agora... | Yes | Informative |
2015-08-27-14:11:00 | Évariste G. | Je ne sais... | Yes | Casual |
2015-10-05-14:19:00 | Anton T. | Привіт | Yes | Casual |
chat_by_allow
contact_id | name | |||
---|---|---|---|---|
1 | Ilma R. | ilma@ilma.com | _ | ilma.k.r |
contacts
contact_id | name | I_follow_tw | my_friend_fb | |
---|---|---|---|---|
1 | Ilma R. | ilma@ilma.com | yes | yes |
contact_tracking
API reads chat
Hangouts
Parse and create objects
Write in Cassandra
API reads chat
Hangouts
Parse and create objects
Write in Cassandra
Reads from Cassandra
Produces enhanced object
Response
API reads chat
Hangouts
Parse and create objects
Write in Cassandra
Reads from Cassandra
Produces enhanced object
Response
Queue
Queue
Évariste
I want to reply "Yes I saw it!"
Need to collect information from Github.
Évariste
I want to reply "Paulista Avenue, 2001"
Need to collect information from Meetup.
Évariste
I want to reply "slides.com/smart-bots"
Need to collect information Slides. And Calendar.
Analyse the information that I have on Cassandra with spending too much time on boilerplate stuff
Cassandra Connector for Spark - https://github.com/datastax/spark-cassandra-connector
From table to RDD (Resilient Data Model)
API reads chat
Hangouts
*Raw* data to spark
Write raw in Cassandra
text.flatMap(line => line.split(" ")).
map(word => (word, 1)).
reduceByKey(_ + _)
Significant decrease for writing time!
API reads chat
Hangouts
*Raw* data
Write raw in Cassandra
filter and process with Spark
Produces enhanced object
Response
Queue
Queue
Évariste - Monday, 8:45
Évariste - Wednesday, 7:45
Évariste - Wednesday, 7:45
Évariste - Wednesday, 7:45
Great response.
Supervised
Unsupervised
Reinforcement
Supervised
Unsupervised
Reinforcement
Predict - He asked "what time", he will ask "where"
Person started conversation complaining, he/she might be angry
Person started conversation with trivial question that could be found on Google. Should I answer or ignore it?
Analyse the environment.
* Custom list based on my context.
API reads chat
Hangouts
*Raw* data
Write raw in Cassandra
filter and process with Spark
Produces enhanced object
Response
Queue
Queue
Machine Learning Processor
Write in Cassandra
Reads from Cassandra
API reads chat
Hangouts
*Raw* data to spark
Write raw in Cassandra
filter and process with Spark
Produces enhanced object
Response
Queue
Queue
Endpoint A
Endpoint B
Take #11
API reads chat
Hangouts
*Raw* data to spark
Write raw in Cassandra
filter and process with Spark
Produces enhanced object
Response
Queue
Queue
Endpoint B
Endpoint A
Take #12
Weird answers. Friend called Paul Regus (PR)
Paul != Pull Request (PR)
Check if message sender is a developer before evaluating the 'PR'.
Take #13
Trust Problem
Questions?
hannelita@gmail.com
@hannelita