1
TOPIC
Developing a
serverless
WhatsApp chatbot
Luis Beltrán
@darkicebeam
Who I am
@darkicebeam
/icebeam7
/luisantoniobeltran
Luis Beltrán
Agenda
Chatbots
LUIS
WhatsApp
Twilio APIs
Azure Functions
Demo
Q & A
Chatbots
Conversational Agents
What is a chatbot?
• AI software that simulates a
conversation with a person using
natural language.
• It is considered as an advanced
expression of interaction between
humans and machines.
How does it work?
Chatbot: What is a Chatbot? Why are Chatbots Important?
https://expertsystem.com/chatbot/
Advantages
• Chatbots are capable of combining millions of data from
different sources.
• Chatbos may be available 24/7/365.
• Chatbots can be integrated into (almost) any platform.
• Chatbots can improve the user experience and keep
human effort to a minimum.
Data
exploration /
collection
Simple and
repetitive
solutions
If it is simple and repetitive, it
can be coded. Bots can speed
up the service process
Data
exploration /
collection
Simple and
repetitive
solutions
Thank you for providing all this information. I
have John with me now who will take from here
and help you out
Hello, this is John. I understand your computer
won’t power on. Let’s take a look at some
service options
I’ve tried these steps, my
computer still won’t turn on Handoff to Human
Handoff to Human can be complete or supervised
I suggest us to request a hardware service. We can have one of
our service engineers look at your computer
Note to operator: It sounds like the user will need hardware
replacement, what next step should I take?
Apologize to
user
Suggest
hardware
service
Let me type
Sounds lovely, thank you
LUIS
Language Understandint Intelligent Service
Language Understanding Intelligent Service
• NLP: Natural Language
Processing
• A cloud-based service for
understanding text.
• Simple to use and integrate
into your software
developments.
• No prior AI experience is
required.
https://www.luis.ai/
Task-based
scenario
When does flight 234 from
Chicago to London depart?
User
query
Intent & entity
detection
Flight 234 leaves Chicago airport
at 7.00 PM local time
Departure time from flight API
WhatsApp
Instant messaging application for smartphones
What is WhatsApp?
• A free messaging application available for
smartphones (Android / iOS), web (WhatsApp
Web), and desktop (Windows / Mac).
• Capabilities:
• Sending text messages, photos, videos, documents,
voice messages and stickers,
• Making and receiving audio and video calls.
• Allows you to manage chat groups.
• Offline messages
• Two versions are available: Messenger & Business
https://www.whatsapp.com/
WhatsApp Business
• A free application particularly
designed for small and
medium-sized businesses.
• Create a catalog to display
your products and services.
• Agile communication with
clients through tools to order,
automate and respond to
messages quickly.
https://www.whatsapp.com/business
WhatsApp 2021 User Statistics: How Many
People Use WhatsApp? (backlinko.com)
WhatsApp Business API
• Boost communication with
your customers around the
world so that you can
contact them through
WhatsApp in a simple, safe
and reliable way.
• It requires contracting with a
global business solutions
provider, available on
Facebook's partner directory. https://www.whatsapp.com/business/api
https://www.facebook.com/business/partner-directory/search?platforms=whatsapp&solution_type=messaging
Twilio APIs
Communication APIs Platform
Twilio
• Twilio is a cloud Communications Platform as a Service
(CPaaS) that allows you to build applications through APIs
and SDKs available for severak languages and platforms
(PHP, Ruby, C # /. NET).
• Some features that developers can integrate into their
apps with Twilio include:
• Text messages
• Voice messages
• Video calls
• WhatsApp messages
Twilio API for WhatsApp
Access to the WhatsApp Business API.
Simple to use and implement.
Test and design your app in a sandbox
environment.
Currently in Preview version
Available on various platforms and
programming languages
https://www.twilio.com/whatsapp
https://www.twilio.com/docs/whatsapp/api
Azure Functions
Your code in the cloud
Serverless computing
Blob Storage
Cosmos DB
Event Hub
HTTP
Queues
Service Bus
Timer
Webhook
File
Table
Excel
OneDrive
Email
Mobile app
Notification
Más…
r PP
r
public static void Run(byte[] image, string filename,
Stream outputBlob, TraceWriter log)
{
log.Info($"Processing image: {filename}");
var imageBuilder = ImageResizer.ImageBuilder.Current;
imageBuilder.Build(
image, outputBlob,
new ResizeSettings(640, 400, FitMode.Max, null), false);
}
{
"bindings": [
{
"name": "image",
"type": "blobTrigger",
"direction": "in",
"path": "card-input/{filename}.jpg",
"connection": "AzureWebJobsStorage"
},
{
"type": "blob",
"name": "outputBlob",
"path": "card-output/{filename}.jpg",
"connection": "AzureWebJobsStorage",
"direction": "out"
}
]
}
DEMO
Towards a responsible AI
• Transparency
• Clarity
• Transfer to a human
• Cultural norms
• Trustworthy
• Privacy
• Data security
• Accessibility
• Responsibility
Call to Action
Developing a serverless WhatsApp chatbot
https://dev.to/icebeam7/developing-a-serverless-whatsapp-
chatbot-4o72
Enviando mensajes de WhatsApp con Xamarin y Twilio
https://www.luisbeltran.mx/2018/10/15/enviando-mensajes-
de-whatsapp-con-xamarin-y-twilio/
Thanks
Questions?
/icebeam7 @darkicebeam /luisantoniobeltran

Global Azure2021 Verona.pptx

  • 1.
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
    What is achatbot? • AI software that simulates a conversation with a person using natural language. • It is considered as an advanced expression of interaction between humans and machines.
  • 7.
    How does itwork? Chatbot: What is a Chatbot? Why are Chatbots Important? https://expertsystem.com/chatbot/
  • 8.
    Advantages • Chatbots arecapable of combining millions of data from different sources. • Chatbos may be available 24/7/365. • Chatbots can be integrated into (almost) any platform. • Chatbots can improve the user experience and keep human effort to a minimum.
  • 9.
    Data exploration / collection Simple and repetitive solutions Ifit is simple and repetitive, it can be coded. Bots can speed up the service process
  • 10.
    Data exploration / collection Simple and repetitive solutions Thankyou for providing all this information. I have John with me now who will take from here and help you out Hello, this is John. I understand your computer won’t power on. Let’s take a look at some service options I’ve tried these steps, my computer still won’t turn on Handoff to Human
  • 11.
    Handoff to Humancan be complete or supervised I suggest us to request a hardware service. We can have one of our service engineers look at your computer Note to operator: It sounds like the user will need hardware replacement, what next step should I take? Apologize to user Suggest hardware service Let me type Sounds lovely, thank you
  • 12.
  • 13.
    Language Understanding IntelligentService • NLP: Natural Language Processing • A cloud-based service for understanding text. • Simple to use and integrate into your software developments. • No prior AI experience is required. https://www.luis.ai/
  • 17.
    Task-based scenario When does flight234 from Chicago to London depart? User query Intent & entity detection Flight 234 leaves Chicago airport at 7.00 PM local time Departure time from flight API
  • 22.
  • 23.
    What is WhatsApp? •A free messaging application available for smartphones (Android / iOS), web (WhatsApp Web), and desktop (Windows / Mac). • Capabilities: • Sending text messages, photos, videos, documents, voice messages and stickers, • Making and receiving audio and video calls. • Allows you to manage chat groups. • Offline messages • Two versions are available: Messenger & Business https://www.whatsapp.com/
  • 24.
    WhatsApp Business • Afree application particularly designed for small and medium-sized businesses. • Create a catalog to display your products and services. • Agile communication with clients through tools to order, automate and respond to messages quickly. https://www.whatsapp.com/business
  • 25.
    WhatsApp 2021 UserStatistics: How Many People Use WhatsApp? (backlinko.com)
  • 26.
    WhatsApp Business API •Boost communication with your customers around the world so that you can contact them through WhatsApp in a simple, safe and reliable way. • It requires contracting with a global business solutions provider, available on Facebook's partner directory. https://www.whatsapp.com/business/api
  • 27.
  • 28.
  • 29.
    Twilio • Twilio isa cloud Communications Platform as a Service (CPaaS) that allows you to build applications through APIs and SDKs available for severak languages and platforms (PHP, Ruby, C # /. NET). • Some features that developers can integrate into their apps with Twilio include: • Text messages • Voice messages • Video calls • WhatsApp messages
  • 31.
    Twilio API forWhatsApp Access to the WhatsApp Business API. Simple to use and implement. Test and design your app in a sandbox environment. Currently in Preview version Available on various platforms and programming languages https://www.twilio.com/whatsapp https://www.twilio.com/docs/whatsapp/api
  • 35.
  • 36.
  • 38.
    Blob Storage Cosmos DB EventHub HTTP Queues Service Bus Timer Webhook File Table Excel OneDrive Email Mobile app Notification Más… r PP r
  • 39.
    public static voidRun(byte[] image, string filename, Stream outputBlob, TraceWriter log) { log.Info($"Processing image: {filename}"); var imageBuilder = ImageResizer.ImageBuilder.Current; imageBuilder.Build( image, outputBlob, new ResizeSettings(640, 400, FitMode.Max, null), false); } { "bindings": [ { "name": "image", "type": "blobTrigger", "direction": "in", "path": "card-input/{filename}.jpg", "connection": "AzureWebJobsStorage" }, { "type": "blob", "name": "outputBlob", "path": "card-output/{filename}.jpg", "connection": "AzureWebJobsStorage", "direction": "out" } ] }
  • 42.
  • 44.
    Towards a responsibleAI • Transparency • Clarity • Transfer to a human • Cultural norms • Trustworthy • Privacy • Data security • Accessibility • Responsibility
  • 45.
    Call to Action Developinga serverless WhatsApp chatbot https://dev.to/icebeam7/developing-a-serverless-whatsapp- chatbot-4o72 Enviando mensajes de WhatsApp con Xamarin y Twilio https://www.luisbeltran.mx/2018/10/15/enviando-mensajes- de-whatsapp-con-xamarin-y-twilio/
  • 46.