SlideShare a Scribd company logo
2018
Do You Wanna Build A Chatbot?
Paul Withers – Intec Systems Ltd
Paul Withers
ICS Developer, Intec Systems Ltd
OpenNTF Board Member
IBM Lifetime Champion
Notes Developer XPages Developer Java Developer
Microservices
Developer
Statbot
• Most chatbot conversations start with “Hi”
• There are more than 30,000 Facebook chatbots
• 63% would message online chatbot to speak to business / brand
• 37% of Americans willing to purchase through a chatbot
• 73% of Americans wouldn’t use a company’s chatbot after a bad
experience
• 75% want to know if they’re talking to a chatbot or a person
https://chatbotsmagazine.com/11-amazing-facts-you-might-not-know-about-chatbots-7764213406e0
What is Watson Assistant?
Watson Assistant (formerly Watson Conversation) is an IBM chat cloud
service that uses natural language processing and more structured
processing to build a dialog workflow that an external system can interact
with and tracking the session for a specific conversation, fronted by a
browser-based interface for development, testing and DevOps.
IBM Chat Cloud Service
• Other providers may have similar services for managing a chatbot’s flow
• Cloud only currently. Product Manager has confirmed on prem is coming
• Training doesn’t retain personal data, conversations available for a period of
time for review and training
• You can’t improve the results if you don’t know what was asked
• Obviously includes a database for storing intents, entities etc
• But no setup or management required
• Intents, entities and dialog flow can be exported / imported as JSON
• Programmatic APIs to add / modify intents etc
Natural Language Processing
INTENTS
• Phrases and variants
• Case sensitivity is irrelevant
• Grammar is irrelevant
• Will cope with some mis-typing
• Can include entities
• Training algorithms will extrapolate
More Structured Processing
ENTITIES
• Key values
• Can include fuzzy matching
• Synonyms (database, Notes, Domino, NSF)
• Regex pattern matching (e.g. email format)
• Also some system entities available, e.g. @sys-person
• System entities cannot be trained
Dialog Flow
• “Welcome” and “Anything Else” nodes
• Workflow rules to respond to intents or entities or static conditions
• Flow can define how to deal with follow-on responses
• Flow can define how to handle digressions
• Steps can set / modify state
• Steps return a JSON object containing text, images, buttons etc and
additional JSON data
External Systems
• Watson Assistant is not a User Interface
• Does not typically interact directly with external databases
• But can be directly connected to cloud functions
• Does not manage authentication
Tracking the Session
• Done via context JSON object
• Passed into and out of every interaction with Watson Assistant
• Can be updated by dialog flow
• E.g. depending on entities recognised
• Can be updated by external systems
Browser-based Tool
• Accessible from your IBM Cloud dashboard
• Managing workspaces for a conversation
• Developer panel for the intents, entities and dialog
• APIs are available for programmatically managing
• Basic testing client in sidebar allows testing / training
• DevOps area for reviewing usage and updating training
This is Watson Assistant
What Is A Chatbot?
A chatbot comprises a user interface where a person provides dialog
content which is passed with any metadata on through one or more
services and receives a fixed-format response for the application to return
for the person.
User Interface
• User interface will vary, including e.g.
• Custom interface (e.g. XPage, Java UI, JavaScript UI)
• Out-of-the-box configurable plugin (e.g. WordPress)
• Hooked service (e.g. Watson Workspace app + “Make it Cognitive”)
• Speech interface (e.g. Alexa, IBM Voice Gateway)
Dialog Content with Metadata
• Remember context JSON object
One or More Services
• Watson Assistant may be just one of the services
• Out-of-the-box plugins / hooked services will be limited
• How do you integrate with external systems / additional services?
• How many calls will it make, how to avoid abuse?
• Custom application (“orchestration layer”) provides greater flexibility,
control and ability to hook in whatever you want
• E.g. SSJS, XPages Java, LotusScript, Node-RED, JavaScript
Don’t Understate Architecture!
• Create an investment management chatbot
Fixed-format Response
• Watson Assistant returns JSON object
• UI layer handles manipulation of e.g. JSON object to user-friendly
output
This Is A Chatbot
This Is What I’m Covering
Not This
Workspaces
• Not the Notes Workspace
• Not a Watson Workspace
• One of a collection of chat “spaces” – 5 for Lite, 20 for Standard
• Avoids conflicts or misunderstanding in larger “chats”
• Has its own id, URL, username and password
• Your app / plugin will need these to interact with the
correct workspace
Intents
• Groupings for particular requests
• “buy a ticket”, “get directions”, “hotel”
• 100 for Lite, 2000 for Standard
• Examples add alternative phrasing, 25000 max
• Can be imported or exported as CSV
• Can be managed programmatically
Intents
• Phrasing may include entities
• Either explicit values or @entity-name – read Documentation!
• Intent example + entity variants + a bit of magic = training variants
Entities
• Groupings for specific nomenclature
• 25 for Lite, 1000 for Standard – system entities count too
• An entity can include different entity values
• Entity “@beer” includes “beer”, “beer_types” and “wine”
• Will identify entity as e.g. @beer:beer, @beer:wine
• Values can use synonyms up to 64 characters, entity can be enabled
for fuzzy matching
• 100,000 entity values and 100,000 synonyms max
Entities
• Values can alternative use pattern matching
• Up to 5 patterns per entity value
• Enter as regex, max 512 characters
• Synonyms or Patterns – not both!
System Entities
• Can be enabled for more generic recognitions
• E.g. @sys-date, @sys-number, @sys-person
• Cannot be trained
• What you get is what you get!
• Tend to be US-focused
• Dates are always MM/dd/yyyy, can’t be defined as dd/MM/yyyy
Dialog
• Dialog is a tree-based flow of nodes
• 25,000 for Lite, 100,000 for Standard
• “If” statements based on recognitions of intents, entities, context etc
• Customise for:
• Gathering multiple pieces of information in one go (slots)
• Define multiple responses based on sub-conditions
• Allow digressions into / out of this node
Dialog
• Steps
• Define responses, if required
• Text, Option, Pause, Image
• But does your UI handle all these response types?
• Set or modifies (optionally) context variables
• Define what to do next
Context
• Dialog is stateless
• Context is JSON object of context variables for each conversation
• Use “context editor” to manage
• Expression language methods available, e.g. <? input.text ?>, <?
@email:literal ?> etc
• Variables can be complex JSON objects and arrays
• Can be passed in and is passed out of nodes
• If it can be passed in, it can be modified externally!
External Integration
• How do you interact with third-party services from Watson Assistant?
• Code it in your orchestration layer, update context object, pass result back
• Make programmatic call from Watson Assistant node
• Client: defines programmatic name your chatbot client understands and
can interpret to return result to dialog
• E.g. JS function if chatbot is a web page
• Not all chatbot clients may support client calls
• Server: IBM Cloud Function, see video
• Runs after context variables have been updated
Cloud Functions
• Repository for “Serverless” REST APIs
• Currently beta, only in US South and Germany regions
• Cloud Functions instance uses same location as Watson Assistant instance
• Can’t call Cloud Functions web action
• Single call must complete in 5 seconds, multiple calls must complete within 7
seconds
• Up to 5 calls from a node, processed in parallel
• To call in series, use Cloud Functions sequence or multiple nodes
Testing
• Use “Try it out” panel
• “Manage Context” allows view / edit
of context variables
• Change intent recognised or mark
irrelevant
• Turn on “node tracing” to highlight
visited nodes for this response
Debugging Dialog
• Adam Newbold’s Dialog Debugger PHP app
• PHP app can be run
on IBM Cloud
• One of three utilities
also on GitHub including
utility to rename entities
Training
• Are you / your business analysts omniscient?
• No? You need to regularly review and train
• Look to update where there is weak understanding
• Review conversations for:
• Incorrect understanding
• Incorrect flows – reorder nodes
• Requirements for additional flows
• Requirements for digression handling
Best Practice
• Challenge your users:
• Is a chatbot the right approach?
• Is the chatbot in the right point of access?
• What value is the chatbot adding?
• What is the right tone for the chatbot?
• Design on paper, document on cloud
• Group nodes into folders for easier manageability
Best Practice
• More nodes = more complexity = greater risk of ambiguity
• This is why you may want multiple workspaces
• Disambiguation is only available to Premium users
• May need to handle multiple intents, see Compound Questions blog
• May need to handle multiple entities
• Use contextual entities – add annotations to intents
• RTFM to understand how to best code conditions
Resources
• Watson Assistant Documentation
• Watson Assistant Demo
• Watson Assistant GitHub Samples
• Watson Assistant YouTube channel
• SDKs for Node, Java and XPages (needs Java 8 and Java security changes)
• Watson Node-Red Nodes (automatically added when creating Node-RED starter on IBM
Cloud)
• Watson Developer Cloud Node-Red Labs
• Chatbots and Watson Assistant blog post
• Simon O’Doherty blog
• Watson Developer Community inviter on Slack
Thanks to our 2018 Sponsors
Questions?
Paul Withers
Intec Systems Ltd & OpenNTF
pwithers@intec.co.uk
@paulswithers
https://www.intec.co.uk/blog
https://paulswithers.github.io

More Related Content

What's hot

CNIT 129S: Securing Web Applications Ch 1-2
CNIT 129S: Securing Web Applications Ch 1-2CNIT 129S: Securing Web Applications Ch 1-2
CNIT 129S: Securing Web Applications Ch 1-2
Sam Bowne
 
CQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architectureCQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architecture
Thomas Jaskula
 
When indexes are not enough
When indexes are not enoughWhen indexes are not enough
When indexes are not enough
Davide Mauri
 
1. Spring intro IoC
1. Spring intro IoC1. Spring intro IoC
1. Spring intro IoC
ASG
 
Mikkel Heisterberg - An introduction to developing for the Activity Stream
Mikkel Heisterberg - An introduction to developing for the Activity StreamMikkel Heisterberg - An introduction to developing for the Activity Stream
Mikkel Heisterberg - An introduction to developing for the Activity Stream
LetsConnect
 
Web Development with Smalltalk
Web Development with SmalltalkWeb Development with Smalltalk
Web Development with Smalltalk
Mariano Martínez Peck
 
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjsCodemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
Fabio Franzini
 
Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3
Wen-Tien Chang
 
WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...
Fabio Franzini
 
IBM Digital Experience Theme Customization
IBM Digital Experience Theme CustomizationIBM Digital Experience Theme Customization
IBM Digital Experience Theme Customization
Van Staub, MBA
 
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling SoftwareJAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
jazoon13
 
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
Lucidworks
 

What's hot (12)

CNIT 129S: Securing Web Applications Ch 1-2
CNIT 129S: Securing Web Applications Ch 1-2CNIT 129S: Securing Web Applications Ch 1-2
CNIT 129S: Securing Web Applications Ch 1-2
 
CQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architectureCQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architecture
 
When indexes are not enough
When indexes are not enoughWhen indexes are not enough
When indexes are not enough
 
1. Spring intro IoC
1. Spring intro IoC1. Spring intro IoC
1. Spring intro IoC
 
Mikkel Heisterberg - An introduction to developing for the Activity Stream
Mikkel Heisterberg - An introduction to developing for the Activity StreamMikkel Heisterberg - An introduction to developing for the Activity Stream
Mikkel Heisterberg - An introduction to developing for the Activity Stream
 
Web Development with Smalltalk
Web Development with SmalltalkWeb Development with Smalltalk
Web Development with Smalltalk
 
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjsCodemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
 
Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3Service-Oriented Design and Implement with Rails3
Service-Oriented Design and Implement with Rails3
 
WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...
 
IBM Digital Experience Theme Customization
IBM Digital Experience Theme CustomizationIBM Digital Experience Theme Customization
IBM Digital Experience Theme Customization
 
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling SoftwareJAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
JAZOON'13 - Abdelmonaim Remani - The Economies of Scaling Software
 
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
Participating in the Community - Beyond Code: Presented by Cassandra Targett,...
 

Similar to ICONUK 2018 - Do You Wanna Build a Chatbot

E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
Gregor Jarisch
 
Reactive Development: Commands, Actors and Events. Oh My!!
Reactive Development: Commands, Actors and Events.  Oh My!!Reactive Development: Commands, Actors and Events.  Oh My!!
Reactive Development: Commands, Actors and Events. Oh My!!
David Hoerster
 
ChatGPT and AI for web developers - Maximiliano Firtman
ChatGPT and AI for web developers - Maximiliano FirtmanChatGPT and AI for web developers - Maximiliano Firtman
ChatGPT and AI for web developers - Maximiliano Firtman
Wey Wey Web
 
Portal and Intranets
Portal and Intranets Portal and Intranets
Portal and Intranets
Redar Ismail
 
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
Paris Open Source Summit
 
Chatbot
ChatbotChatbot
Chatbot
nikul patel
 
Chatbot Tutorial - Create your first bot with Xatkit
Chatbot Tutorial - Create your first bot with Xatkit Chatbot Tutorial - Create your first bot with Xatkit
Chatbot Tutorial - Create your first bot with Xatkit
Jordi Cabot
 
Lessons learned from building a commercial bot development platform
Lessons learned from building a commercial bot development platformLessons learned from building a commercial bot development platform
Lessons learned from building a commercial bot development platform
Jordi Cabot
 
Azure Bot Services - Malaysia
Azure Bot Services - MalaysiaAzure Bot Services - Malaysia
Azure Bot Services - Malaysia
Cheah Eng Soon
 
DITA Quick Start Webinar: Defining Your Style Sheet Requirements
DITA Quick Start Webinar: Defining Your Style Sheet RequirementsDITA Quick Start Webinar: Defining Your Style Sheet Requirements
DITA Quick Start Webinar: Defining Your Style Sheet Requirements
Suite Solutions
 
Data harmony update 2021
Data harmony update 2021 Data harmony update 2021
Data harmony update 2021
Access Innovations, Inc.
 
WebDev Crash Course
WebDev Crash CourseWebDev Crash Course
WebDev Crash Course
Cesar Martinez
 
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
Marc D Anderson
 
Tips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
Tips to kick-start your Software Engineering Career - Ferdous Mahmud ShaonTips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
Tips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
Cefalo
 
Tips to Kick-start your Software Engineering Career
Tips to Kick-start your Software Engineering CareerTips to Kick-start your Software Engineering Career
Tips to Kick-start your Software Engineering Career
Ferdous Mahmud Shaon
 
Geek basics
Geek basicsGeek basics
Build an Intelligent Bot
Build an Intelligent BotBuild an Intelligent Bot
Build an Intelligent Bot
Sorin Peste
 
Graphel: A Purely Functional Approach to Digital Interaction
Graphel: A Purely Functional Approach to Digital InteractionGraphel: A Purely Functional Approach to Digital Interaction
Graphel: A Purely Functional Approach to Digital Interaction
mtrimpe
 
Wp 3hr-course
Wp 3hr-courseWp 3hr-course
Wp 3hr-course
Rich Webster
 
Vba Class Level 3
Vba Class Level 3Vba Class Level 3
Vba Class Level 3
Ben Miu CIM® FCSI A+
 

Similar to ICONUK 2018 - Do You Wanna Build a Chatbot (20)

E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
E.D.D.I - 6 Years of Chatbot Development Experience in one Open Source Chatbo...
 
Reactive Development: Commands, Actors and Events. Oh My!!
Reactive Development: Commands, Actors and Events.  Oh My!!Reactive Development: Commands, Actors and Events.  Oh My!!
Reactive Development: Commands, Actors and Events. Oh My!!
 
ChatGPT and AI for web developers - Maximiliano Firtman
ChatGPT and AI for web developers - Maximiliano FirtmanChatGPT and AI for web developers - Maximiliano Firtman
ChatGPT and AI for web developers - Maximiliano Firtman
 
Portal and Intranets
Portal and Intranets Portal and Intranets
Portal and Intranets
 
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
#OSSPARIS19 - Création facile de chatbots - Créez votre chatbot en 20 minutes...
 
Chatbot
ChatbotChatbot
Chatbot
 
Chatbot Tutorial - Create your first bot with Xatkit
Chatbot Tutorial - Create your first bot with Xatkit Chatbot Tutorial - Create your first bot with Xatkit
Chatbot Tutorial - Create your first bot with Xatkit
 
Lessons learned from building a commercial bot development platform
Lessons learned from building a commercial bot development platformLessons learned from building a commercial bot development platform
Lessons learned from building a commercial bot development platform
 
Azure Bot Services - Malaysia
Azure Bot Services - MalaysiaAzure Bot Services - Malaysia
Azure Bot Services - Malaysia
 
DITA Quick Start Webinar: Defining Your Style Sheet Requirements
DITA Quick Start Webinar: Defining Your Style Sheet RequirementsDITA Quick Start Webinar: Defining Your Style Sheet Requirements
DITA Quick Start Webinar: Defining Your Style Sheet Requirements
 
Data harmony update 2021
Data harmony update 2021 Data harmony update 2021
Data harmony update 2021
 
WebDev Crash Course
WebDev Crash CourseWebDev Crash Course
WebDev Crash Course
 
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
 
Tips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
Tips to kick-start your Software Engineering Career - Ferdous Mahmud ShaonTips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
Tips to kick-start your Software Engineering Career - Ferdous Mahmud Shaon
 
Tips to Kick-start your Software Engineering Career
Tips to Kick-start your Software Engineering CareerTips to Kick-start your Software Engineering Career
Tips to Kick-start your Software Engineering Career
 
Geek basics
Geek basicsGeek basics
Geek basics
 
Build an Intelligent Bot
Build an Intelligent BotBuild an Intelligent Bot
Build an Intelligent Bot
 
Graphel: A Purely Functional Approach to Digital Interaction
Graphel: A Purely Functional Approach to Digital InteractionGraphel: A Purely Functional Approach to Digital Interaction
Graphel: A Purely Functional Approach to Digital Interaction
 
Wp 3hr-course
Wp 3hr-courseWp 3hr-course
Wp 3hr-course
 
Vba Class Level 3
Vba Class Level 3Vba Class Level 3
Vba Class Level 3
 

More from Paul Withers

Engage 2019: Introduction to Node-Red
Engage 2019: Introduction to Node-RedEngage 2019: Introduction to Node-Red
Engage 2019: Introduction to Node-Red
Paul Withers
 
Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications
Paul Withers
 
Engage 2019: AI What Is It Good For
Engage 2019: AI What Is It Good ForEngage 2019: AI What Is It Good For
Engage 2019: AI What Is It Good For
Paul Withers
 
Social Connections 14 - ICS Integration with Node-RED and Open Source
Social Connections 14 - ICS Integration with Node-RED and Open SourceSocial Connections 14 - ICS Integration with Node-RED and Open Source
Social Connections 14 - ICS Integration with Node-RED and Open Source
Paul Withers
 
IBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClassIBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClass
Paul Withers
 
IBM Think Session 3249 Watson Work Services Java SDK
IBM Think Session 3249 Watson Work Services Java SDKIBM Think Session 3249 Watson Work Services Java SDK
IBM Think Session 3249 Watson Work Services Java SDK
Paul Withers
 
GraphQL 101
GraphQL 101GraphQL 101
GraphQL 101
Paul Withers
 
GraphQL 101
GraphQL 101GraphQL 101
GraphQL 101
Paul Withers
 
OpenNTF Domino API (ODA): Super-Charging Domino Development
OpenNTF Domino API (ODA): Super-Charging Domino DevelopmentOpenNTF Domino API (ODA): Super-Charging Domino Development
OpenNTF Domino API (ODA): Super-Charging Domino Development
Paul Withers
 
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
Paul Withers
 
Social Connections 2015 CrossWorlds and Domino
Social Connections 2015 CrossWorlds and DominoSocial Connections 2015 CrossWorlds and Domino
Social Connections 2015 CrossWorlds and Domino
Paul Withers
 
ICON UK 2015 - ODA and CrossWorlds
ICON UK 2015 - ODA and CrossWorldsICON UK 2015 - ODA and CrossWorlds
ICON UK 2015 - ODA and CrossWorlds
Paul Withers
 
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
Paul Withers
 
IBM ConnectED 2015 - MAS103 XPages Performance and Scalability
IBM ConnectED 2015 - MAS103 XPages Performance and ScalabilityIBM ConnectED 2015 - MAS103 XPages Performance and Scalability
IBM ConnectED 2015 - MAS103 XPages Performance and Scalability
Paul Withers
 
OpenNTF Domino API - Overview Introduction
OpenNTF Domino API - Overview IntroductionOpenNTF Domino API - Overview Introduction
OpenNTF Domino API - Overview Introduction
Paul Withers
 
What's New and Next in OpenNTF Domino API (ICON UK 2014)
What's New and Next in OpenNTF Domino API (ICON UK 2014)What's New and Next in OpenNTF Domino API (ICON UK 2014)
What's New and Next in OpenNTF Domino API (ICON UK 2014)
Paul Withers
 
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
Paul Withers
 
Engage 2014 OpenNTF Domino API Slides
Engage 2014 OpenNTF Domino API SlidesEngage 2014 OpenNTF Domino API Slides
Engage 2014 OpenNTF Domino API Slides
Paul Withers
 
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages HeavenIBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
Paul Withers
 
Embracing the power of the notes client
Embracing the power of the notes clientEmbracing the power of the notes client
Embracing the power of the notes client
Paul Withers
 

More from Paul Withers (20)

Engage 2019: Introduction to Node-Red
Engage 2019: Introduction to Node-RedEngage 2019: Introduction to Node-Red
Engage 2019: Introduction to Node-Red
 
Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications Engage 2019: Modernising Your Domino and XPages Applications
Engage 2019: Modernising Your Domino and XPages Applications
 
Engage 2019: AI What Is It Good For
Engage 2019: AI What Is It Good ForEngage 2019: AI What Is It Good For
Engage 2019: AI What Is It Good For
 
Social Connections 14 - ICS Integration with Node-RED and Open Source
Social Connections 14 - ICS Integration with Node-RED and Open SourceSocial Connections 14 - ICS Integration with Node-RED and Open Source
Social Connections 14 - ICS Integration with Node-RED and Open Source
 
IBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClassIBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClass
 
IBM Think Session 3249 Watson Work Services Java SDK
IBM Think Session 3249 Watson Work Services Java SDKIBM Think Session 3249 Watson Work Services Java SDK
IBM Think Session 3249 Watson Work Services Java SDK
 
GraphQL 101
GraphQL 101GraphQL 101
GraphQL 101
 
GraphQL 101
GraphQL 101GraphQL 101
GraphQL 101
 
OpenNTF Domino API (ODA): Super-Charging Domino Development
OpenNTF Domino API (ODA): Super-Charging Domino DevelopmentOpenNTF Domino API (ODA): Super-Charging Domino Development
OpenNTF Domino API (ODA): Super-Charging Domino Development
 
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
AD1279 "Marty, You're Not Thinking Fourth Dimensionally" - Troubleshooting XP...
 
Social Connections 2015 CrossWorlds and Domino
Social Connections 2015 CrossWorlds and DominoSocial Connections 2015 CrossWorlds and Domino
Social Connections 2015 CrossWorlds and Domino
 
ICON UK 2015 - ODA and CrossWorlds
ICON UK 2015 - ODA and CrossWorldsICON UK 2015 - ODA and CrossWorlds
ICON UK 2015 - ODA and CrossWorlds
 
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
IBM ConnectED 2015 - BP106 From XPages Hero To OSGi Guru: Taking The Scary Ou...
 
IBM ConnectED 2015 - MAS103 XPages Performance and Scalability
IBM ConnectED 2015 - MAS103 XPages Performance and ScalabilityIBM ConnectED 2015 - MAS103 XPages Performance and Scalability
IBM ConnectED 2015 - MAS103 XPages Performance and Scalability
 
OpenNTF Domino API - Overview Introduction
OpenNTF Domino API - Overview IntroductionOpenNTF Domino API - Overview Introduction
OpenNTF Domino API - Overview Introduction
 
What's New and Next in OpenNTF Domino API (ICON UK 2014)
What's New and Next in OpenNTF Domino API (ICON UK 2014)What's New and Next in OpenNTF Domino API (ICON UK 2014)
What's New and Next in OpenNTF Domino API (ICON UK 2014)
 
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
From XPages Hero to OSGi Guru: Taking the Scary out of Building Extension Lib...
 
Engage 2014 OpenNTF Domino API Slides
Engage 2014 OpenNTF Domino API SlidesEngage 2014 OpenNTF Domino API Slides
Engage 2014 OpenNTF Domino API Slides
 
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages HeavenIBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
IBM Connect 2014 BP204: It's Not Infernal: Dante's Nine Circles of XPages Heaven
 
Embracing the power of the notes client
Embracing the power of the notes clientEmbracing the power of the notes client
Embracing the power of the notes client
 

Recently uploaded

Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
Zilliz
 
SAP S/4 HANA sourcing and procurement to Public cloud
SAP S/4 HANA sourcing and procurement to Public cloudSAP S/4 HANA sourcing and procurement to Public cloud
SAP S/4 HANA sourcing and procurement to Public cloud
maazsz111
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
innovationoecd
 
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - HiikeSystem Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
Hiike
 
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-EfficiencyFreshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
ScyllaDB
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Jeffrey Haguewood
 
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
Edge AI and Vision Alliance
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
saastr
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
Jakub Marek
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
HarisZaheer8
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
dbms calicut university B. sc Cs 4th sem.pdf
dbms  calicut university B. sc Cs 4th sem.pdfdbms  calicut university B. sc Cs 4th sem.pdf
dbms calicut university B. sc Cs 4th sem.pdf
Shinana2
 
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdfMonitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Tosin Akinosho
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
Hiroshi SHIBATA
 
JavaLand 2024: Application Development Green Masterplan
JavaLand 2024: Application Development Green MasterplanJavaLand 2024: Application Development Green Masterplan
JavaLand 2024: Application Development Green Masterplan
Miro Wengner
 
Choosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptxChoosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptx
Brandon Minnick, MBA
 
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
Alex Pruden
 

Recently uploaded (20)

Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
 
SAP S/4 HANA sourcing and procurement to Public cloud
SAP S/4 HANA sourcing and procurement to Public cloudSAP S/4 HANA sourcing and procurement to Public cloud
SAP S/4 HANA sourcing and procurement to Public cloud
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
 
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - HiikeSystem Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
 
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-EfficiencyFreshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-Efficiency
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
 
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
dbms calicut university B. sc Cs 4th sem.pdf
dbms  calicut university B. sc Cs 4th sem.pdfdbms  calicut university B. sc Cs 4th sem.pdf
dbms calicut university B. sc Cs 4th sem.pdf
 
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdfMonitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdf
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
 
JavaLand 2024: Application Development Green Masterplan
JavaLand 2024: Application Development Green MasterplanJavaLand 2024: Application Development Green Masterplan
JavaLand 2024: Application Development Green Masterplan
 
Choosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptxChoosing The Best AWS Service For Your Website + API.pptx
Choosing The Best AWS Service For Your Website + API.pptx
 
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
 

ICONUK 2018 - Do You Wanna Build a Chatbot

  • 1. 2018 Do You Wanna Build A Chatbot? Paul Withers – Intec Systems Ltd
  • 2. Paul Withers ICS Developer, Intec Systems Ltd OpenNTF Board Member IBM Lifetime Champion Notes Developer XPages Developer Java Developer Microservices Developer
  • 3. Statbot • Most chatbot conversations start with “Hi” • There are more than 30,000 Facebook chatbots • 63% would message online chatbot to speak to business / brand • 37% of Americans willing to purchase through a chatbot • 73% of Americans wouldn’t use a company’s chatbot after a bad experience • 75% want to know if they’re talking to a chatbot or a person https://chatbotsmagazine.com/11-amazing-facts-you-might-not-know-about-chatbots-7764213406e0
  • 4. What is Watson Assistant? Watson Assistant (formerly Watson Conversation) is an IBM chat cloud service that uses natural language processing and more structured processing to build a dialog workflow that an external system can interact with and tracking the session for a specific conversation, fronted by a browser-based interface for development, testing and DevOps.
  • 5. IBM Chat Cloud Service • Other providers may have similar services for managing a chatbot’s flow • Cloud only currently. Product Manager has confirmed on prem is coming • Training doesn’t retain personal data, conversations available for a period of time for review and training • You can’t improve the results if you don’t know what was asked • Obviously includes a database for storing intents, entities etc • But no setup or management required • Intents, entities and dialog flow can be exported / imported as JSON • Programmatic APIs to add / modify intents etc
  • 6. Natural Language Processing INTENTS • Phrases and variants • Case sensitivity is irrelevant • Grammar is irrelevant • Will cope with some mis-typing • Can include entities • Training algorithms will extrapolate
  • 7. More Structured Processing ENTITIES • Key values • Can include fuzzy matching • Synonyms (database, Notes, Domino, NSF) • Regex pattern matching (e.g. email format) • Also some system entities available, e.g. @sys-person • System entities cannot be trained
  • 8. Dialog Flow • “Welcome” and “Anything Else” nodes • Workflow rules to respond to intents or entities or static conditions • Flow can define how to deal with follow-on responses • Flow can define how to handle digressions • Steps can set / modify state • Steps return a JSON object containing text, images, buttons etc and additional JSON data
  • 9. External Systems • Watson Assistant is not a User Interface • Does not typically interact directly with external databases • But can be directly connected to cloud functions • Does not manage authentication
  • 10. Tracking the Session • Done via context JSON object • Passed into and out of every interaction with Watson Assistant • Can be updated by dialog flow • E.g. depending on entities recognised • Can be updated by external systems
  • 11. Browser-based Tool • Accessible from your IBM Cloud dashboard • Managing workspaces for a conversation • Developer panel for the intents, entities and dialog • APIs are available for programmatically managing • Basic testing client in sidebar allows testing / training • DevOps area for reviewing usage and updating training
  • 12. This is Watson Assistant
  • 13. What Is A Chatbot? A chatbot comprises a user interface where a person provides dialog content which is passed with any metadata on through one or more services and receives a fixed-format response for the application to return for the person.
  • 14. User Interface • User interface will vary, including e.g. • Custom interface (e.g. XPage, Java UI, JavaScript UI) • Out-of-the-box configurable plugin (e.g. WordPress) • Hooked service (e.g. Watson Workspace app + “Make it Cognitive”) • Speech interface (e.g. Alexa, IBM Voice Gateway)
  • 15. Dialog Content with Metadata • Remember context JSON object
  • 16. One or More Services • Watson Assistant may be just one of the services • Out-of-the-box plugins / hooked services will be limited • How do you integrate with external systems / additional services? • How many calls will it make, how to avoid abuse? • Custom application (“orchestration layer”) provides greater flexibility, control and ability to hook in whatever you want • E.g. SSJS, XPages Java, LotusScript, Node-RED, JavaScript
  • 17. Don’t Understate Architecture! • Create an investment management chatbot
  • 18. Fixed-format Response • Watson Assistant returns JSON object • UI layer handles manipulation of e.g. JSON object to user-friendly output
  • 19. This Is A Chatbot
  • 20. This Is What I’m Covering
  • 22. Workspaces • Not the Notes Workspace • Not a Watson Workspace • One of a collection of chat “spaces” – 5 for Lite, 20 for Standard • Avoids conflicts or misunderstanding in larger “chats” • Has its own id, URL, username and password • Your app / plugin will need these to interact with the correct workspace
  • 23. Intents • Groupings for particular requests • “buy a ticket”, “get directions”, “hotel” • 100 for Lite, 2000 for Standard • Examples add alternative phrasing, 25000 max • Can be imported or exported as CSV • Can be managed programmatically
  • 24. Intents • Phrasing may include entities • Either explicit values or @entity-name – read Documentation! • Intent example + entity variants + a bit of magic = training variants
  • 25. Entities • Groupings for specific nomenclature • 25 for Lite, 1000 for Standard – system entities count too • An entity can include different entity values • Entity “@beer” includes “beer”, “beer_types” and “wine” • Will identify entity as e.g. @beer:beer, @beer:wine • Values can use synonyms up to 64 characters, entity can be enabled for fuzzy matching • 100,000 entity values and 100,000 synonyms max
  • 26. Entities • Values can alternative use pattern matching • Up to 5 patterns per entity value • Enter as regex, max 512 characters • Synonyms or Patterns – not both!
  • 27. System Entities • Can be enabled for more generic recognitions • E.g. @sys-date, @sys-number, @sys-person • Cannot be trained • What you get is what you get! • Tend to be US-focused • Dates are always MM/dd/yyyy, can’t be defined as dd/MM/yyyy
  • 28. Dialog • Dialog is a tree-based flow of nodes • 25,000 for Lite, 100,000 for Standard • “If” statements based on recognitions of intents, entities, context etc • Customise for: • Gathering multiple pieces of information in one go (slots) • Define multiple responses based on sub-conditions • Allow digressions into / out of this node
  • 29. Dialog • Steps • Define responses, if required • Text, Option, Pause, Image • But does your UI handle all these response types? • Set or modifies (optionally) context variables • Define what to do next
  • 30. Context • Dialog is stateless • Context is JSON object of context variables for each conversation • Use “context editor” to manage • Expression language methods available, e.g. <? input.text ?>, <? @email:literal ?> etc • Variables can be complex JSON objects and arrays • Can be passed in and is passed out of nodes • If it can be passed in, it can be modified externally!
  • 31. External Integration • How do you interact with third-party services from Watson Assistant? • Code it in your orchestration layer, update context object, pass result back • Make programmatic call from Watson Assistant node • Client: defines programmatic name your chatbot client understands and can interpret to return result to dialog • E.g. JS function if chatbot is a web page • Not all chatbot clients may support client calls • Server: IBM Cloud Function, see video • Runs after context variables have been updated
  • 32. Cloud Functions • Repository for “Serverless” REST APIs • Currently beta, only in US South and Germany regions • Cloud Functions instance uses same location as Watson Assistant instance • Can’t call Cloud Functions web action • Single call must complete in 5 seconds, multiple calls must complete within 7 seconds • Up to 5 calls from a node, processed in parallel • To call in series, use Cloud Functions sequence or multiple nodes
  • 33. Testing • Use “Try it out” panel • “Manage Context” allows view / edit of context variables • Change intent recognised or mark irrelevant • Turn on “node tracing” to highlight visited nodes for this response
  • 34. Debugging Dialog • Adam Newbold’s Dialog Debugger PHP app • PHP app can be run on IBM Cloud • One of three utilities also on GitHub including utility to rename entities
  • 35. Training • Are you / your business analysts omniscient? • No? You need to regularly review and train • Look to update where there is weak understanding • Review conversations for: • Incorrect understanding • Incorrect flows – reorder nodes • Requirements for additional flows • Requirements for digression handling
  • 36. Best Practice • Challenge your users: • Is a chatbot the right approach? • Is the chatbot in the right point of access? • What value is the chatbot adding? • What is the right tone for the chatbot? • Design on paper, document on cloud • Group nodes into folders for easier manageability
  • 37. Best Practice • More nodes = more complexity = greater risk of ambiguity • This is why you may want multiple workspaces • Disambiguation is only available to Premium users • May need to handle multiple intents, see Compound Questions blog • May need to handle multiple entities • Use contextual entities – add annotations to intents • RTFM to understand how to best code conditions
  • 38. Resources • Watson Assistant Documentation • Watson Assistant Demo • Watson Assistant GitHub Samples • Watson Assistant YouTube channel • SDKs for Node, Java and XPages (needs Java 8 and Java security changes) • Watson Node-Red Nodes (automatically added when creating Node-RED starter on IBM Cloud) • Watson Developer Cloud Node-Red Labs • Chatbots and Watson Assistant blog post • Simon O’Doherty blog • Watson Developer Community inviter on Slack
  • 39. Thanks to our 2018 Sponsors
  • 40. Questions? Paul Withers Intec Systems Ltd & OpenNTF pwithers@intec.co.uk @paulswithers https://www.intec.co.uk/blog https://paulswithers.github.io