SlideShare a Scribd company logo
1 of 17
Download to read offline
www.neosperience.com | blog.neosperience.com | info@neosperience.comServerless Usergroup
November 2016
Serverless Chatbots
Luca Bianchi, Chief Technology Officer @ Neosperience
Janos Tolgyesi, Team Leader iOS @ Neosperience
github.com/aletheia
https://it.linkedin.com/in/lucabianchipavia
@bianchiluca
github.com/mrtj
https://it.linkedin.com/in/janostolgyesi
Who are we?
Working on a lot of bleeding edge technologies. Passionate developers.
Love writing code.
One of us speaks Magyar very well, guess who? :-)
The Neosperience Cloud
• Software as a service cloud for Digital Customer Experience processes (couponing, gamification, proximity, etc.)
• Completely built on AWS
• Moved from VMWare, to EC2, to Elastic Beanstalk, to Lambda
• Dozens of micro and nano services
Neosperience
The Digital Customer Experience Company, aims to change the way brands and customers interact with an
approach of a software vendor targeting Digital Customer Experience as the evolution of Marketing automation.
✓ Functions are the unit of development and scaling
✓ No machine, VMs or containers visible in the programming model
✓ Permanent storage lives elsewhere (stateless code)
✓ Scales per request. Users cannot over or under-provision capacity
✓ Never pay for idle
✓ Implicitly fault tolerant
✓ BYOC - Bring Your Own Code
✓ Metrics and logging are an universal right
The Serverless Manifesto
The Serverless Framework (aka serverless.com)
• Started less than one year ago (was named JAWS)
• Fast moving (with a bi-weekly release model)
• Funded by a 3M investment
• Manages service deployments and provisioning
• Vendor independent (in a future release)
• Auto-provision of resources
• Supports for micro-services
• Improved plugin management system
• Production ready
Getting started
• Install Serverless locally (trust me, it’s better)

npm install serverless —save
• Create a function in NodeJS (Java and Python supported too)

serverless create —template=aws-nodejs
• Deploy service

serverless deploy
done!
Architecture
Facebook Bot Messenger
Platform
Messenger Hook
Service
1. send
message
2. HTTP method
call to REST
3. synch HTTP call
to api.ai
4.Context
and answer
5. message sent back
to Facebook
6. Message
Content Data
Service
3.2 Textual
Answer
3.1 Api.ai
Webhook
Introducing Api.ai
• “Conversation UX platform”
• Natural language understanding: intent recognition, entity extraction
• Conversational engine
• Optionally speech recognition and TTS
• Predefined conversational domain (eg. “Small Talk”)
• Integration with various chat platforms
• Free tier
http://api.ai/
Facebook Messenger Platform
• Build chat bots for Messenger
• web-hook based callbacks
• relatively complex setup (Page, App, verify token, etc.)
Step 1: Create bot on api.ai
• Create intents: sample phrases (utterances)
• (Optional) Create entities: attributes of intent, to be extracted from user response
• Enabled domains if needed (Small Talk)
• api.ai webhooks: content data service
• api.ai integration API: we will use this!
http://api.ai/
Step 2: Configure Messenger App
• Create a Facebook Page (chat bots live inside Pages)
• Create a Facebook App
• Setup webhooks: Messenger will send here the messages of the user
• Security considerations: verify token and page access token
• Subscribe app to page events (eg. new message)
• Receive messages and postbacks, and send structured response
https://developers.facebook.com/docs/messenger-platform/
What’s inside a Service?
JSON
Request Event
JSON
Response Event
Request
to Api.ai
Response
from Api.ai
Step 3: Lambda connects the two worlds
• When the webhook is called by facebook, the lambda is invoked
• Parses Messenger payload and extracts user message
• Assembles api.ai message requests and sends it to REST api endpoint
• Parses api.ai responds including recognized intent and bot response
• Assembles Messenger response and sends it back to Messenger
• + administrative functions (verify token authentication, page subscription)
Architecture
Facebook Bot Messenger
Platform
Messenger Hook
Service
1. send
message
2. HTTP method
call to REST
3. synch HTTP call
to api.ai
4.Context
and answer
5. message sent back
to Facebook
6. Message
Content Data
Service
3.2 Textual
Answer
3.1 Api.ai
Webhook
The good..
• Fast time to market (the whole project built in 8h)
• Modularity by design
• Functions can run locally
• Everything is contained and versioned
• Serverless avoids a lot of boilerplate
• Incremental deployments
• Supports CI
• Cost-effective
• Api.ai acquired by Google (now with support for Italian language)
..the bad
• Architecture has to be enforced (your code is as good as you)
• Testing is unavoidable, TDD is encouraged
• Every deploy hits the cloud
• Cannot test offline (no matter how you try)
• Avoid Lambda cold start issue
• Not everything is supported by CloudFormation
• Many pieces stored in different places (maybe CloudFormation CustomResource?)
Thank you
github.com/aletheia
https://it.linkedin.com/in/lucabianchipavia
@bianchiluca
Slides available on Slideshare

http://bit.ly/2fZMM2Q
Try our Neosperience DCX Bot

http://m.me/neosperience
github.com/mrtj
https://it.linkedin.com/in/janostolgyesi
www.neosperience.com | blog.neosperience.com | info@neosperience.com

More Related Content

What's hot

Scaling API Design
Scaling API DesignScaling API Design
Scaling API DesignJason Harmon
 
Past, Present, Future of APIS
Past, Present, Future of APISPast, Present, Future of APIS
Past, Present, Future of APISJason Harmon
 
Scaling API Design
Scaling API DesignScaling API Design
Scaling API DesignJason Harmon
 
Scaling API Design - Nordic APIs 2014
Scaling API Design - Nordic APIs 2014Scaling API Design - Nordic APIs 2014
Scaling API Design - Nordic APIs 2014Jason Harmon
 
Automating PhoneGap Build
Automating PhoneGap BuildAutomating PhoneGap Build
Automating PhoneGap BuildMatt Gifford
 
DirectLineAPI - Xamarin.Forms App and Bot Framework Integration
DirectLineAPI - Xamarin.Forms App and Bot Framework IntegrationDirectLineAPI - Xamarin.Forms App and Bot Framework Integration
DirectLineAPI - Xamarin.Forms App and Bot Framework IntegrationBryan Anthony Garcia
 
Bot Framework with Xamarin Forms
Bot Framework with Xamarin FormsBot Framework with Xamarin Forms
Bot Framework with Xamarin FormsCheah Eng Soon
 
GitHub Copilot.pptx
GitHub Copilot.pptxGitHub Copilot.pptx
GitHub Copilot.pptxLuis Beltran
 
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflixapidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflixapidays
 
Facebook F8 2016
Facebook F8 2016Facebook F8 2016
Facebook F8 2016Fate Chang
 
Build html 5 apps for mobile
Build html 5 apps for mobileBuild html 5 apps for mobile
Build html 5 apps for mobileJoão Ferreira
 
Building Salesforce1 Communities Apps with React Native and Flux
Building Salesforce1 Communities Apps with React Native and FluxBuilding Salesforce1 Communities Apps with React Native and Flux
Building Salesforce1 Communities Apps with React Native and FluxSalesforce Developers
 
Business of APIs - Introduction
Business of APIs - IntroductionBusiness of APIs - Introduction
Business of APIs - Introductionaubs
 
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019Alan Quayle
 
API Strategy & Practice Conference - API Consumption from the Hackathon Trenches
API Strategy & Practice Conference - API Consumption from the Hackathon TrenchesAPI Strategy & Practice Conference - API Consumption from the Hackathon Trenches
API Strategy & Practice Conference - API Consumption from the Hackathon TrenchesAlex Gaber
 
Developing Chatbots with Google DialogFlow
Developing Chatbots with Google DialogFlowDeveloping Chatbots with Google DialogFlow
Developing Chatbots with Google DialogFlowEveristus Olumese
 

What's hot (19)

Scaling API Design
Scaling API DesignScaling API Design
Scaling API Design
 
Silverlight+Twitter
Silverlight+TwitterSilverlight+Twitter
Silverlight+Twitter
 
Past, Present, Future of APIS
Past, Present, Future of APISPast, Present, Future of APIS
Past, Present, Future of APIS
 
Scaling API Design
Scaling API DesignScaling API Design
Scaling API Design
 
Scaling API Design - Nordic APIs 2014
Scaling API Design - Nordic APIs 2014Scaling API Design - Nordic APIs 2014
Scaling API Design - Nordic APIs 2014
 
Automating PhoneGap Build
Automating PhoneGap BuildAutomating PhoneGap Build
Automating PhoneGap Build
 
DirectLineAPI - Xamarin.Forms App and Bot Framework Integration
DirectLineAPI - Xamarin.Forms App and Bot Framework IntegrationDirectLineAPI - Xamarin.Forms App and Bot Framework Integration
DirectLineAPI - Xamarin.Forms App and Bot Framework Integration
 
Bot Framework with Xamarin Forms
Bot Framework with Xamarin FormsBot Framework with Xamarin Forms
Bot Framework with Xamarin Forms
 
GitHub Copilot.pptx
GitHub Copilot.pptxGitHub Copilot.pptx
GitHub Copilot.pptx
 
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflixapidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
 
Facebook F8 2016
Facebook F8 2016Facebook F8 2016
Facebook F8 2016
 
Build html 5 apps for mobile
Build html 5 apps for mobileBuild html 5 apps for mobile
Build html 5 apps for mobile
 
Building Salesforce1 Communities Apps with React Native and Flux
Building Salesforce1 Communities Apps with React Native and FluxBuilding Salesforce1 Communities Apps with React Native and Flux
Building Salesforce1 Communities Apps with React Native and Flux
 
Pitch
PitchPitch
Pitch
 
Api Design
Api DesignApi Design
Api Design
 
Business of APIs - Introduction
Business of APIs - IntroductionBusiness of APIs - Introduction
Business of APIs - Introduction
 
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019
You do not understand me, Rob Pickering, Aplisay, TADSummit EMEA 2019
 
API Strategy & Practice Conference - API Consumption from the Hackathon Trenches
API Strategy & Practice Conference - API Consumption from the Hackathon TrenchesAPI Strategy & Practice Conference - API Consumption from the Hackathon Trenches
API Strategy & Practice Conference - API Consumption from the Hackathon Trenches
 
Developing Chatbots with Google DialogFlow
Developing Chatbots with Google DialogFlowDeveloping Chatbots with Google DialogFlow
Developing Chatbots with Google DialogFlow
 

Viewers also liked

The curious Life of JavaScript - Talk at SI-SE 2015
The curious Life of JavaScript - Talk at SI-SE 2015The curious Life of JavaScript - Talk at SI-SE 2015
The curious Life of JavaScript - Talk at SI-SE 2015jbandi
 
How do I write Testable Javascript?
How do I write Testable Javascript?How do I write Testable Javascript?
How do I write Testable Javascript?Gavin Pickin
 
DwesaBot - a Telegram bot for Africa
DwesaBot - a Telegram bot for AfricaDwesaBot - a Telegram bot for Africa
DwesaBot - a Telegram bot for AfricaFrancesco Bonadiman
 
Facebook Messenger Platform Framework
Facebook Messenger Platform FrameworkFacebook Messenger Platform Framework
Facebook Messenger Platform FrameworkRam Murat Sharma
 
Designing a Conversational Intelligent Bot which can cook
Designing a Conversational Intelligent Bot which can cookDesigning a Conversational Intelligent Bot which can cook
Designing a Conversational Intelligent Bot which can cookKaushik Das
 
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016Codemotion
 
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...Codemotion
 
Conversational UI, chatbot, AI - simply explained
Conversational UI, chatbot, AI - simply explained Conversational UI, chatbot, AI - simply explained
Conversational UI, chatbot, AI - simply explained Daniil Lanovyi
 
101 Conversational User Interfaces
101 Conversational User Interfaces 101 Conversational User Interfaces
101 Conversational User Interfaces Redweb Ltd
 
Messengers, Bots and Personal Assistants
Messengers, Bots and Personal AssistantsMessengers, Bots and Personal Assistants
Messengers, Bots and Personal AssistantsKonstantin Savenkov
 
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016Codemotion
 
Lead generation in confessionale con i bot
Lead generation in confessionale con i botLead generation in confessionale con i bot
Lead generation in confessionale con i botPaolo Montrasio
 

Viewers also liked (14)

The curious Life of JavaScript - Talk at SI-SE 2015
The curious Life of JavaScript - Talk at SI-SE 2015The curious Life of JavaScript - Talk at SI-SE 2015
The curious Life of JavaScript - Talk at SI-SE 2015
 
How do I write Testable Javascript?
How do I write Testable Javascript?How do I write Testable Javascript?
How do I write Testable Javascript?
 
DwesaBot - a Telegram bot for Africa
DwesaBot - a Telegram bot for AfricaDwesaBot - a Telegram bot for Africa
DwesaBot - a Telegram bot for Africa
 
Facebook Messenger Platform Framework
Facebook Messenger Platform FrameworkFacebook Messenger Platform Framework
Facebook Messenger Platform Framework
 
Designing a Conversational Intelligent Bot which can cook
Designing a Conversational Intelligent Bot which can cookDesigning a Conversational Intelligent Bot which can cook
Designing a Conversational Intelligent Bot which can cook
 
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016
Milano Chatbots Meetup - Paolo Montrasio - Codemotion Milan 2016
 
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...
Elixir and Lambda talk with a Telegram bot - Paolo Montrasio - Codemotion Mil...
 
Conversational UI, chatbot, AI - simply explained
Conversational UI, chatbot, AI - simply explained Conversational UI, chatbot, AI - simply explained
Conversational UI, chatbot, AI - simply explained
 
101 Conversational User Interfaces
101 Conversational User Interfaces 101 Conversational User Interfaces
101 Conversational User Interfaces
 
Messengers, Bots and Personal Assistants
Messengers, Bots and Personal AssistantsMessengers, Bots and Personal Assistants
Messengers, Bots and Personal Assistants
 
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016
Il Bot di Codemotion - Emanuele Capparelli - Codemotion Milan 2016
 
Chatbot timezip
Chatbot timezipChatbot timezip
Chatbot timezip
 
Lead generation in confessionale con i bot
Lead generation in confessionale con i botLead generation in confessionale con i bot
Lead generation in confessionale con i bot
 
Chatbot ppt
Chatbot pptChatbot ppt
Chatbot ppt
 

Similar to Chatbot Meetup

Serverless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedServerless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedLuca Bianchi
 
Serverless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedServerless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedPaolo Montrasio
 
Building Enterprise Chat Bots
Building Enterprise Chat BotsBuilding Enterprise Chat Bots
Building Enterprise Chat BotsVasu Jain
 
Microsoft teams & bot framework - A developer's perspective
Microsoft teams & bot framework - A developer's perspectiveMicrosoft teams & bot framework - A developer's perspective
Microsoft teams & bot framework - A developer's perspectiveThomas Gölles
 
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s Perspective
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s PerspectiveESPC Teams week Microsoft Teams & Bot Framework – a Developer’s Perspective
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s PerspectiveThomas Gölles
 
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClass
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClassECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClass
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClassEuropean Collaboration Summit
 
Identifying and solving enterprise problems
Identifying and solving enterprise problems  Identifying and solving enterprise problems
Identifying and solving enterprise problems Vasu Jain
 
The new Azure App Service Architecture
The new Azure App Service ArchitectureThe new Azure App Service Architecture
The new Azure App Service ArchitectureJoão Pedro Martins
 
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptx
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptxPDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptx
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptxLuis Beltran
 
Global Azure2021 Verona.pptx
Global Azure2021 Verona.pptxGlobal Azure2021 Verona.pptx
Global Azure2021 Verona.pptxLuis Beltran
 
Introduction to development using the share point framework mv ps
Introduction to development using the share point framework mv psIntroduction to development using the share point framework mv ps
Introduction to development using the share point framework mv psUsama Wahab Khan Cloud, Data and AI
 
December OpenNTF Webinar: The Volt MX LotusScript Toolkit
December OpenNTF Webinar: The Volt MX LotusScript ToolkitDecember OpenNTF Webinar: The Volt MX LotusScript Toolkit
December OpenNTF Webinar: The Volt MX LotusScript ToolkitHoward Greenberg
 
Amazon Polly and Amazon Lex Workshop
Amazon Polly and Amazon Lex WorkshopAmazon Polly and Amazon Lex Workshop
Amazon Polly and Amazon Lex WorkshopAmazon Web Services
 
Building A Great API - Evan Cooke, Cloudstock, December 2010
Building A Great API - Evan Cooke, Cloudstock, December 2010Building A Great API - Evan Cooke, Cloudstock, December 2010
Building A Great API - Evan Cooke, Cloudstock, December 2010Twilio Inc
 
Joomla as a mobile App backend - ideas, examples and experiences
Joomla as a mobile App backend - ideas, examples and experiencesJoomla as a mobile App backend - ideas, examples and experiences
Joomla as a mobile App backend - ideas, examples and experiencesAndy_Gaskell
 
Cloud-Based App Development using SharePoint 2013, Office 365 and Azure
Cloud-Based App Development using SharePoint 2013, Office 365 and AzureCloud-Based App Development using SharePoint 2013, Office 365 and Azure
Cloud-Based App Development using SharePoint 2013, Office 365 and AzureTobias Lekman
 
Getting Started With bots
Getting Started With botsGetting Started With bots
Getting Started With botsGaurav sharma
 
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101Nikolai Blackie
 
Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Nuxeo
 

Similar to Chatbot Meetup (20)

Serverless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedServerless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speed
 
Serverless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speedServerless chatbot: from idea to production at blazing speed
Serverless chatbot: from idea to production at blazing speed
 
Building Enterprise Chat Bots
Building Enterprise Chat BotsBuilding Enterprise Chat Bots
Building Enterprise Chat Bots
 
Microsoft teams & bot framework - A developer's perspective
Microsoft teams & bot framework - A developer's perspectiveMicrosoft teams & bot framework - A developer's perspective
Microsoft teams & bot framework - A developer's perspective
 
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s Perspective
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s PerspectiveESPC Teams week Microsoft Teams & Bot Framework – a Developer’s Perspective
ESPC Teams week Microsoft Teams & Bot Framework – a Developer’s Perspective
 
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClass
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClassECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClass
ECS19 - Vesa Juvonen - SharePoint and Office 365 Development PowerClass
 
Identifying and solving enterprise problems
Identifying and solving enterprise problems  Identifying and solving enterprise problems
Identifying and solving enterprise problems
 
LUIS and Bots
LUIS and BotsLUIS and Bots
LUIS and Bots
 
The new Azure App Service Architecture
The new Azure App Service ArchitectureThe new Azure App Service Architecture
The new Azure App Service Architecture
 
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptx
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptxPDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptx
PDCConf2021 - Serverless WhatsApp Chatbot with Azure AI.pptx
 
Global Azure2021 Verona.pptx
Global Azure2021 Verona.pptxGlobal Azure2021 Verona.pptx
Global Azure2021 Verona.pptx
 
Introduction to development using the share point framework mv ps
Introduction to development using the share point framework mv psIntroduction to development using the share point framework mv ps
Introduction to development using the share point framework mv ps
 
December OpenNTF Webinar: The Volt MX LotusScript Toolkit
December OpenNTF Webinar: The Volt MX LotusScript ToolkitDecember OpenNTF Webinar: The Volt MX LotusScript Toolkit
December OpenNTF Webinar: The Volt MX LotusScript Toolkit
 
Amazon Polly and Amazon Lex Workshop
Amazon Polly and Amazon Lex WorkshopAmazon Polly and Amazon Lex Workshop
Amazon Polly and Amazon Lex Workshop
 
Building A Great API - Evan Cooke, Cloudstock, December 2010
Building A Great API - Evan Cooke, Cloudstock, December 2010Building A Great API - Evan Cooke, Cloudstock, December 2010
Building A Great API - Evan Cooke, Cloudstock, December 2010
 
Joomla as a mobile App backend - ideas, examples and experiences
Joomla as a mobile App backend - ideas, examples and experiencesJoomla as a mobile App backend - ideas, examples and experiences
Joomla as a mobile App backend - ideas, examples and experiences
 
Cloud-Based App Development using SharePoint 2013, Office 365 and Azure
Cloud-Based App Development using SharePoint 2013, Office 365 and AzureCloud-Based App Development using SharePoint 2013, Office 365 and Azure
Cloud-Based App Development using SharePoint 2013, Office 365 and Azure
 
Getting Started With bots
Getting Started With botsGetting Started With bots
Getting Started With bots
 
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101
Code Camp Auckland 2015 - DEV1 Microsoft API Approaches 101
 
Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011
 

Recently uploaded

Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptkotipi9215
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxbodapatigopi8531
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 

Recently uploaded (20)

Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.ppt
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptx
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
Exploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the ProcessExploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the Process
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 

Chatbot Meetup

  • 1. www.neosperience.com | blog.neosperience.com | info@neosperience.comServerless Usergroup November 2016 Serverless Chatbots Luca Bianchi, Chief Technology Officer @ Neosperience Janos Tolgyesi, Team Leader iOS @ Neosperience github.com/aletheia https://it.linkedin.com/in/lucabianchipavia @bianchiluca github.com/mrtj https://it.linkedin.com/in/janostolgyesi
  • 2. Who are we? Working on a lot of bleeding edge technologies. Passionate developers. Love writing code. One of us speaks Magyar very well, guess who? :-) The Neosperience Cloud • Software as a service cloud for Digital Customer Experience processes (couponing, gamification, proximity, etc.) • Completely built on AWS • Moved from VMWare, to EC2, to Elastic Beanstalk, to Lambda • Dozens of micro and nano services Neosperience The Digital Customer Experience Company, aims to change the way brands and customers interact with an approach of a software vendor targeting Digital Customer Experience as the evolution of Marketing automation.
  • 3. ✓ Functions are the unit of development and scaling ✓ No machine, VMs or containers visible in the programming model ✓ Permanent storage lives elsewhere (stateless code) ✓ Scales per request. Users cannot over or under-provision capacity ✓ Never pay for idle ✓ Implicitly fault tolerant ✓ BYOC - Bring Your Own Code ✓ Metrics and logging are an universal right The Serverless Manifesto
  • 4. The Serverless Framework (aka serverless.com) • Started less than one year ago (was named JAWS) • Fast moving (with a bi-weekly release model) • Funded by a 3M investment • Manages service deployments and provisioning • Vendor independent (in a future release) • Auto-provision of resources • Supports for micro-services • Improved plugin management system • Production ready
  • 5. Getting started • Install Serverless locally (trust me, it’s better)
 npm install serverless —save • Create a function in NodeJS (Java and Python supported too)
 serverless create —template=aws-nodejs • Deploy service
 serverless deploy done!
  • 6. Architecture Facebook Bot Messenger Platform Messenger Hook Service 1. send message 2. HTTP method call to REST 3. synch HTTP call to api.ai 4.Context and answer 5. message sent back to Facebook 6. Message Content Data Service 3.2 Textual Answer 3.1 Api.ai Webhook
  • 7. Introducing Api.ai • “Conversation UX platform” • Natural language understanding: intent recognition, entity extraction • Conversational engine • Optionally speech recognition and TTS • Predefined conversational domain (eg. “Small Talk”) • Integration with various chat platforms • Free tier http://api.ai/
  • 8. Facebook Messenger Platform • Build chat bots for Messenger • web-hook based callbacks • relatively complex setup (Page, App, verify token, etc.)
  • 9. Step 1: Create bot on api.ai • Create intents: sample phrases (utterances) • (Optional) Create entities: attributes of intent, to be extracted from user response • Enabled domains if needed (Small Talk) • api.ai webhooks: content data service • api.ai integration API: we will use this! http://api.ai/
  • 10. Step 2: Configure Messenger App • Create a Facebook Page (chat bots live inside Pages) • Create a Facebook App • Setup webhooks: Messenger will send here the messages of the user • Security considerations: verify token and page access token • Subscribe app to page events (eg. new message) • Receive messages and postbacks, and send structured response https://developers.facebook.com/docs/messenger-platform/
  • 11. What’s inside a Service? JSON Request Event JSON Response Event Request to Api.ai Response from Api.ai
  • 12. Step 3: Lambda connects the two worlds • When the webhook is called by facebook, the lambda is invoked • Parses Messenger payload and extracts user message • Assembles api.ai message requests and sends it to REST api endpoint • Parses api.ai responds including recognized intent and bot response • Assembles Messenger response and sends it back to Messenger • + administrative functions (verify token authentication, page subscription)
  • 13. Architecture Facebook Bot Messenger Platform Messenger Hook Service 1. send message 2. HTTP method call to REST 3. synch HTTP call to api.ai 4.Context and answer 5. message sent back to Facebook 6. Message Content Data Service 3.2 Textual Answer 3.1 Api.ai Webhook
  • 14. The good.. • Fast time to market (the whole project built in 8h) • Modularity by design • Functions can run locally • Everything is contained and versioned • Serverless avoids a lot of boilerplate • Incremental deployments • Supports CI • Cost-effective • Api.ai acquired by Google (now with support for Italian language)
  • 15. ..the bad • Architecture has to be enforced (your code is as good as you) • Testing is unavoidable, TDD is encouraged • Every deploy hits the cloud • Cannot test offline (no matter how you try) • Avoid Lambda cold start issue • Not everything is supported by CloudFormation • Many pieces stored in different places (maybe CloudFormation CustomResource?)
  • 16. Thank you github.com/aletheia https://it.linkedin.com/in/lucabianchipavia @bianchiluca Slides available on Slideshare
 http://bit.ly/2fZMM2Q Try our Neosperience DCX Bot
 http://m.me/neosperience github.com/mrtj https://it.linkedin.com/in/janostolgyesi