SlideShare a Scribd company logo
Session ID: 3322A
Company: Craftworkz
Sam Hendrickx & Michiel Vandendriessche
IBM InterConnect 2017 Conference
Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
Hi handsome! How are you doing
today?
Feeling great! Just visiting San
Francisco. How r u?
Not yet, we just came back from a
conference.
I’m doing fine. Any plans for tonight?
Want to go for a drink?
Yeah why not!
Awesome Michiel! Can you please
verify your identity here so I know
you’re not a creep: http://bit.ly/abc123
OMG, IT’S A BOT!
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
THE ERA OF BOTS
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
BELGIUM
FRENCH GERMAN
39%
DUTCH
1%60%
BELGIUM
NOBODY CARES
ABOUT DUTCH
LET’S BUILD IT
OURSELVES
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
NLP
REST
SESSION
RESPONSE
FIRST APPROACH
NLP
REST
SESSION
RESPONSE
FIRST APPROACH
NLP
REST
SESSION
RESPONSE
FIRST APPROACH
NLP
REST
SESSION
RESPONSE
FIRST APPROACH
NLP
REST
SESSION
RESPONSE
FIRST APPROACH
What can you tell me about IBM
InterConnect 2017?
InterConnect is a conference where
you can tap into the most advanced
cloud technology in the market
today!
Where is it being held?
The location of InterConnect is
Mandalay Bay, Las Vegas, NV
DAMN, IT’S NOT
SCALING!
10 USERS
10 MESSAGES
1.000 USERS
10 MESSAGES
ADD MORE
INSTANCES!
NLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSE
PYTHON RUNTIMES
. . .
BOT SUFFERING
FROM AMNESIA
What can you tell me about IBM
InterConnect 2017?
InterConnect is a conference where
you can tap into the most advanced
cloud technology in the market
today!
Where is it being held?
I don’t know how to answer that
question…
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
NLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSE
PYTHON RUNTIMES
. . .
NLP
REST
SESSION
RESPONSE
CONTEXT STORED
IN MEMORY
NLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSENLP
REST
SESSION
RESPONSE
PYTHON RUNTIMES
. . .
STORE SESSION
INFO IN DATABASE
NLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSE
PYTHON RUNTIMES
. . .
SESSION
COMPOSE FOR MONGODB
OUR BOT IS NOT
ON SOCIAL MEDIA!
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
NLP
REST
SESSION MANAGER
RESPONSE
WE DON’T WANT
TO MANAGE
CONNECTIONS HERE
ADD API MANAGER
TO ARCHITECTURE
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER
. . .
NODEJS RUNTIMES
NLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSE
PYTHON RUNTIMES
. . .
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER
. . .
NODEJS RUNTIMES
NLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSE
PYTHON RUNTIMES
. . .
SOME MESSAGES
ARE GETTING LOST!
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER
. . .
NODEJS RUNTIMES
NLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSENLP
REST
SESSION MANAGER
RESPONSE
PYTHON RUNTIMES
. . .
MESSAGE
LOSS!
QUEUEING TO
THE RESCUE!
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER
. . .
NODEJS RUNTIMES
COMPOSE FOR REDIS
NLP
SESSION MANAGER
RESPONSE
PYTHON RUNTIMES
. . .
NLP
SESSION MANAGER
RESPONSE NLP
SESSION MANAGER
RESPONSE
OUR AI NEEDS
EXTERNAL DATA!
LET’S MANAGE THOSE
CONNECTIONS!
NLP
CONNECTION MANAGER
SESSION MANAGER
RESPONSE
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER . . .
NODEJS RUNTIMES
COMPOSE FOR REDIS
PYTHON RUNTIMES
. . .
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
OOPS, THIS I/O
IS QUITE SLOW!
BEFORE
NLP
SESSION MANAGER
RESPONSE
Q
A
~ 20 ms
WITH I/O
NLP
CONNECTION MANAGER
SESSION MANAGER
RESPONSE
Q
A
~ 200 ms
10.000 USERS
10 MESSAGES
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
CPU USAGE
THREADS THREADS
THREADS THREADS!
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
CPU USAGE
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER . . .
NODEJS RUNTIMES
COMPOSE FOR REDIS
PYTHON RUNTIMES
. . .
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
RESULTS
THESE INSTANCES
SHOULD BE SCALING…
BLUEMIX AUTO-SCALING,
TAKE IT AWAY!
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
FINAL RESULTS
Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix
NOBODY CARES
ABOUT DUTCH
WATSON CARES!
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER . . .
NODEJS RUNTIMES
COMPOSE FOR REDIS
PYTHON RUNTIMES
. . .
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
NLP
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
SESSION
COMPOSE FOR MONGODB
API
MANAGER
API
MANAGER
API
MANAGER . . .
NODEJS RUNTIMES
COMPOSE FOR REDIS
PYTHON RUNTIMES
. . .SESSION MANAGER
RESPONSE
CONNECTION MANAGER
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
SESSION MANAGER
RESPONSE
CONNECTION MANAGER
Get Connected
@craftworkz_co
Let’s stay in touch! We can meet you in one of our offices in
Leuven or Kontich. Or we can come to you. Nothing beats a coffee
and an interesting conversation ;-)
@craftworkz
@craftworkzco
@craftworkz_co
www.craftworkz.be
Veldkant 33A, 2550 Kontich
info@craftworkz.be
+32 498 44 50 61
Headquarter
Gaston Geenslaan 11 B4
BE-3001 Leuven
LEUVEN (BE) OFFICE
Veldkant 33A
BE-2550 Kontich
ANTWERP (BE) OFFICE
Pedro de Medinalaan 81,
NL-1086 XP Amsterdam
AMSTERDAM (NL) OFFICE

More Related Content

Viewers also liked (18)

PDF
Bluemix Girl's Night by Keshia - Building a custom HR application
craftworkz
 
PDF
Introduction to IBM Bluemix
craftworkz
 
PPTX
Intro to Graph Databases
Lauren Hayward Schaefer
 
PDF
Creating Effective Mobile Applications with IBM Bluemix
Andrew Ferrier
 
PPTX
Count-Min Tree Sketch : Approximate counting for NLP tasks
Guillaume Pitel
 
ODP
Hozd egyensúlyba magad a virágok rezgéseivel
Kőszegi Zsuzsanna kineziológus
 
DOCX
Case study haad operating model improvement model
Sandeep Sharma IIMK Smart City,IoT,Bigdata,Cloud,BI,DW
 
PDF
JHipster, modern web application development made easy
Raphaël Brugier
 
PPTX
Getting Started with Graph Databases
Lauren Hayward Schaefer
 
PPTX
Node Summit 2016: Web App Architectures
Chris Bailey
 
PDF
Migrating your monolithic application for micro services with JHipster
Lazaro Prates Junior
 
PPTX
YOGA ASANA BY NEETU RANA
meenarana781
 
PDF
NLP from scratch
Bryan Gummibearehausen
 
PDF
Deploying JHipster Microservices
Joe Kutner
 
PPT
Why Silicon Valley kicks Europe's butt
Loic Le Meur
 
PDF
IBM Bluemix Dedicated – GitHub Enterprise
IBM DevOps
 
PDF
Understanding Docker and IBM Bluemix Container Service
Andrew Ferrier
 
PPTX
2016 06-30-deep-learning-archi
Daisuke Nagao
 
Bluemix Girl's Night by Keshia - Building a custom HR application
craftworkz
 
Introduction to IBM Bluemix
craftworkz
 
Intro to Graph Databases
Lauren Hayward Schaefer
 
Creating Effective Mobile Applications with IBM Bluemix
Andrew Ferrier
 
Count-Min Tree Sketch : Approximate counting for NLP tasks
Guillaume Pitel
 
Hozd egyensúlyba magad a virágok rezgéseivel
Kőszegi Zsuzsanna kineziológus
 
Case study haad operating model improvement model
Sandeep Sharma IIMK Smart City,IoT,Bigdata,Cloud,BI,DW
 
JHipster, modern web application development made easy
Raphaël Brugier
 
Getting Started with Graph Databases
Lauren Hayward Schaefer
 
Node Summit 2016: Web App Architectures
Chris Bailey
 
Migrating your monolithic application for micro services with JHipster
Lazaro Prates Junior
 
YOGA ASANA BY NEETU RANA
meenarana781
 
NLP from scratch
Bryan Gummibearehausen
 
Deploying JHipster Microservices
Joe Kutner
 
Why Silicon Valley kicks Europe's butt
Loic Le Meur
 
IBM Bluemix Dedicated – GitHub Enterprise
IBM DevOps
 
Understanding Docker and IBM Bluemix Container Service
Andrew Ferrier
 
2016 06-30-deep-learning-archi
Daisuke Nagao
 

Similar to Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix (20)

PPTX
Digital Transformation Services and Solutions - Chatbot Development
PrajaktaKulkarni55
 
PDF
Asynchronous Architectures for Implementing Scalable Cloud Services - Evan Co...
Twilio Inc
 
PDF
Building Web APIs that Scale
Salesforce Developers
 
PDF
Parse.ly: Inside a modern RIA built with Solr
Andrew Montalenti
 
PDF
Building a high-performance, scalable ML & NLP platform with Python, Sheer El...
Pôle Systematic Paris-Region
 
KEY
PyCon US 2012 - Web Server Bottlenecks and Performance Tuning
Graham Dumpleton
 
PDF
Python Load Testing - Pygotham 2012
Dan Kuebrich
 
PDF
Future of the Web with Conversational Interface
Tomomi Imura
 
PDF
Gmr Highload Presentation Revised
Ontico
 
PDF
Gmr Highload Presentation
Ontico
 
PDF
Architecture Patterns - Open Discussion
Nguyen Tung
 
PDF
Live chat srs
madhuripallod
 
PPTX
Your Next App Might Just Be a Bot: Building Conversational Bots with Python
David Asamu
 
PDF
PyCon 2011 Scaling Disqus
zeeg
 
PDF
Microservices Architecture For Conversational Intelligence Platform
Rafael Casuso Romate
 
PDF
My internship presentation at WSO2
Prabhath Suminda
 
PDF
Google App Engine Update 2012
David Chandler
 
PDF
Dragoncraft Architectural Overview
jessesanford
 
PDF
[TechWorldSummit Stockholm 2019] Building Bots for Human with Conversational ...
Tomomi Imura
 
PDF
"Humate AI: AI-powered task automation platform."
silentkillergrp
 
Digital Transformation Services and Solutions - Chatbot Development
PrajaktaKulkarni55
 
Asynchronous Architectures for Implementing Scalable Cloud Services - Evan Co...
Twilio Inc
 
Building Web APIs that Scale
Salesforce Developers
 
Parse.ly: Inside a modern RIA built with Solr
Andrew Montalenti
 
Building a high-performance, scalable ML & NLP platform with Python, Sheer El...
Pôle Systematic Paris-Region
 
PyCon US 2012 - Web Server Bottlenecks and Performance Tuning
Graham Dumpleton
 
Python Load Testing - Pygotham 2012
Dan Kuebrich
 
Future of the Web with Conversational Interface
Tomomi Imura
 
Gmr Highload Presentation Revised
Ontico
 
Gmr Highload Presentation
Ontico
 
Architecture Patterns - Open Discussion
Nguyen Tung
 
Live chat srs
madhuripallod
 
Your Next App Might Just Be a Bot: Building Conversational Bots with Python
David Asamu
 
PyCon 2011 Scaling Disqus
zeeg
 
Microservices Architecture For Conversational Intelligence Platform
Rafael Casuso Romate
 
My internship presentation at WSO2
Prabhath Suminda
 
Google App Engine Update 2012
David Chandler
 
Dragoncraft Architectural Overview
jessesanford
 
[TechWorldSummit Stockholm 2019] Building Bots for Human with Conversational ...
Tomomi Imura
 
"Humate AI: AI-powered task automation platform."
silentkillergrp
 
Ad

Recently uploaded (20)

PPTX
apidays Munich 2025 - Building Telco-Aware Apps with Open Gateway APIs, Subhr...
apidays
 
PDF
NIS2 Compliance for MSPs: Roadmap, Benefits & Cybersecurity Trends (2025 Guide)
GRC Kompas
 
PDF
Optimizing Large Language Models with vLLM and Related Tools.pdf
Tamanna36
 
PDF
Driving Employee Engagement in a Hybrid World.pdf
Mia scott
 
PPTX
apidays Helsinki & North 2025 - Agentic AI: A Friend or Foe?, Merja Kajava (A...
apidays
 
PDF
apidays Helsinki & North 2025 - Monetizing AI APIs: The New API Economy, Alla...
apidays
 
PDF
apidays Helsinki & North 2025 - How (not) to run a Graphql Stewardship Group,...
apidays
 
PDF
The European Business Wallet: Why It Matters and How It Powers the EUDI Ecosy...
Lal Chandran
 
PPTX
apidays Singapore 2025 - The Quest for the Greenest LLM , Jean Philippe Ehre...
apidays
 
PDF
Simplifying Document Processing with Docling for AI Applications.pdf
Tamanna36
 
PDF
Product Management in HealthTech (Case Studies from SnappDoctor)
Hamed Shams
 
PDF
Data Science Course Certificate by Sigma Software University
Stepan Kalika
 
PDF
apidays Singapore 2025 - Streaming Lakehouse with Kafka, Flink and Iceberg by...
apidays
 
PPTX
BinarySearchTree in datastructures in detail
kichokuttu
 
PPTX
apidays Helsinki & North 2025 - APIs at Scale: Designing for Alignment, Trust...
apidays
 
PPTX
apidays Singapore 2025 - From Data to Insights: Building AI-Powered Data APIs...
apidays
 
PPTX
Aict presentation on dpplppp sjdhfh.pptx
vabaso5932
 
PPTX
apidays Helsinki & North 2025 - Vero APIs - Experiences of API development in...
apidays
 
PPT
Growth of Public Expendituuure_55423.ppt
NavyaDeora
 
PDF
apidays Singapore 2025 - From API Intelligence to API Governance by Harsha Ch...
apidays
 
apidays Munich 2025 - Building Telco-Aware Apps with Open Gateway APIs, Subhr...
apidays
 
NIS2 Compliance for MSPs: Roadmap, Benefits & Cybersecurity Trends (2025 Guide)
GRC Kompas
 
Optimizing Large Language Models with vLLM and Related Tools.pdf
Tamanna36
 
Driving Employee Engagement in a Hybrid World.pdf
Mia scott
 
apidays Helsinki & North 2025 - Agentic AI: A Friend or Foe?, Merja Kajava (A...
apidays
 
apidays Helsinki & North 2025 - Monetizing AI APIs: The New API Economy, Alla...
apidays
 
apidays Helsinki & North 2025 - How (not) to run a Graphql Stewardship Group,...
apidays
 
The European Business Wallet: Why It Matters and How It Powers the EUDI Ecosy...
Lal Chandran
 
apidays Singapore 2025 - The Quest for the Greenest LLM , Jean Philippe Ehre...
apidays
 
Simplifying Document Processing with Docling for AI Applications.pdf
Tamanna36
 
Product Management in HealthTech (Case Studies from SnappDoctor)
Hamed Shams
 
Data Science Course Certificate by Sigma Software University
Stepan Kalika
 
apidays Singapore 2025 - Streaming Lakehouse with Kafka, Flink and Iceberg by...
apidays
 
BinarySearchTree in datastructures in detail
kichokuttu
 
apidays Helsinki & North 2025 - APIs at Scale: Designing for Alignment, Trust...
apidays
 
apidays Singapore 2025 - From Data to Insights: Building AI-Powered Data APIs...
apidays
 
Aict presentation on dpplppp sjdhfh.pptx
vabaso5932
 
apidays Helsinki & North 2025 - Vero APIs - Experiences of API development in...
apidays
 
Growth of Public Expendituuure_55423.ppt
NavyaDeora
 
apidays Singapore 2025 - From API Intelligence to API Governance by Harsha Ch...
apidays
 
Ad

Craftworkz at InterConnect 2017 - Creating a Highly Scalable Chatbot in a Microservices Architecture Using IBM Bluemix

Editor's Notes

  • #2: SAM
  • #3: SAM a couple of months ago -> San Francisco When we came back from the conference -> Michiel Tinder Michiel was swiping left & right Came across beautiful girl Match Converstation went like this
  • #4: SAM
  • #5: SAM
  • #6: SAM - We we’rent the only ones
  • #7: SAM
  • #8: MICHIEL Sam & Michiel from Belgium Idea of where Belgium is -> animation Now -> Las Vegas
  • #9: MICHIEL Very small country with only 11 million inhabitants Very complex country 6 different governments in this very small country 3 different official languages Over 1000 kinds of beer ** DOES ANYBODY HAVE AN IDEA WHICH LANGUAGES? **
  • #10: MICHIEL … Era of chatbots Build chatbots A lot of cool tools for developers from different vendors on the market But one problem…
  • #11: MICHIEL … Those developer tools do not support the Dutch language Very simple solution
  • #12: MICHIEL … Let’s build this chatbot framework ourselves
  • #13: MICHIEL Founders of Craftworkz Build innovative prototypes for other companies Strong focus on artificial intelligence Build an engine that can be trained to interpret sentences in a specific domain Started with a very modest and humble approach
  • #14: MICHIEL Let’s take a look at this first approach
  • #15: MICHIEL REST API for handling HTTP requests
  • #16: MICHIEL NLP component for interpreting the sentences and invoking the right response NLP in a chatbot context uses machine learning to learn how to interpret short sentences Train the engine by giving examples of sentences and their corresponding interpretations
  • #17: MICHIEL Component that handles the actual responses
  • #18: MICHIEL Session component for keeping context We deployed this onto Bluemix and we built a first chatbot that could have looked something like this
  • #19: MICHIEL We will do a live demo later in the session
  • #20: SAM
  • #21: SAM
  • #22: SAM
  • #23: SAM
  • #24: SAM
  • #25: MICHIEL With this new architecture A new problem arose …
  • #26: MICHIEL Let’s take a look at the previous conversation … This only happened some times but not all the times
  • #27: MICHIEL ** DOES ANYONE HAVE AN IDEA WHAT HAPPENED? **
  • #28: MICHIEL Take a look at the architecture
  • #29: MICHIEL Context is stored in memory in the instances
  • #30: MICHIEL Every engine has its own version of the context in memory and they are not in sync What can you tell me about IBM InterConnect? -> handled by one engine The follow up question: Where is it being held? -> handled by another engine not knowing about the context
  • #31: MICHIEL Solution: … Looked at the Bluemix catalog
  • #32: MICHIEL Added a compose for MongoDB database Shared across all the engines Every engine now has a session manager for communicating with the MongoDB
  • #33: SAM
  • #34: SAM
  • #35: SAM
  • #36: SAM
  • #37: SAM
  • #38: SAM
  • #39: SAM
  • #40: SAM
  • #41: SAM
  • #42: SAM
  • #43: MICHIEL Chatbots need to integrate with external datasources API’s, databases, SQL, NoSQL, CRM’s and so on The responses can be enriched with data from these data sources
  • #44: MICHIEL …
  • #45: MICHIEL Added a connection manager to our engine …
  • #46: MICHIEL Complete architecture looked something like this Message comes from social media Sent to the API Pushed on the queue Pulled from the queue Analyzed Response is generated, with external data Keeping context in mind Sent back to the frontend
  • #47: MICHIEL We encoutered a new problem …
  • #48: MICHIEL Let’s take a look at how a message was processed before Pulled from the queue to the engine, processed, a response in generated and sent back
  • #49: MICHIEL Now Pulled from the queue Processed Response is enriched with external data -> communication takes some time Sent back to the frontend 10 times as long
  • #50: MICHIEL 10.000 users sending 10 messages in parallel This was getting slow Up to minutes response time We didn’t really know how to solve this
  • #51: MICHIEL Installed an activity monitor plugin for bluemix This is what it looked like under heavy load Disk usage -> don’t really care Memory -> seems okay CPU is very idle
  • #52: MICHIEL Only 5% of CPU usage under heavy load Most of the time, the CPU is waiting for I/O Waiting for external data
  • #53: MICHIEL Multithreading to the rescue Added 100 threads per instance working in parallel for handling messages
  • #54: MICHIEL If we now take a look at the activity monitor
  • #55: MICHIEL CPU usage of 93% A lot more efficient
  • #56: MICHIEL Let’s take a look at the complete testing architecture Jmeter for simulating 10.000users talking in parallel Making requests to the API
  • #57: MICHIEL This is what it looked like in a testing environment
  • #58: MICHIEL Average response time of around …
  • #59: SAM
  • #60: SAM
  • #61: SAM
  • #62: SAM
  • #63: MICHIEL
  • #64: SAM
  • #65: SAM
  • #66: SAM
  • #67: SAM
  • #68: SAM