Slide 1

Slide 1 text

Using Dialogflow to build actions for Google Assistant ‘18 Abdelrahman Omran | Rinvex | @Omranic | [email protected]

Slide 2

Slide 2 text

Be excellent to each other. Treat everyone with respect. Participate while acknowledging that everyone deserves to be here — and each of us has the right to enjoy our experience without fear of harassment, discrimination, or condescension, whether blatant or via micro-aggressions. Jokes shouldn’t demean others. Consider what you are saying and how it would feel if it were said to or about you. Practice saying "Yes and" to each other. It’s a theatre improv technique to build on each other’s ideas. We all benefit when we create together. Speak up if you see or hear something. Harassment is not tolerated, and you are empowered to politely engage when you or others are disrespected. The person making you feel uncomfortable may not be aware of what they are doing, and politely bringing their behavior to their attention is encouraged. In case you see or hear something or feel uncomfortable, reach out to [email protected] Code of Conduct

Slide 3

Slide 3 text

“ Intent Matching — Match and categorize user utterances to an intent. Entity Extraction — Identify key words and phrases spoken by the user. @

Slide 4

Slide 4 text

Why Dialogflow? Features and benefits of using Dialogflow

Slide 5

Slide 5 text

Build natural and rich conversational experiences

Slide 6

Slide 6 text

Use machine learning to understand what users are saying

Slide 7

Slide 7 text

Across devices Around the world On any platform

Slide 8

Slide 8 text

See who's using Dialogflow

Slide 9

Slide 9 text

How Dialogflow Works? A high level overview for using dialogflow

Slide 10

Slide 10 text

Hey Google, talk to __________. Hey Google, connect me with __________. Hey Google, get __________.

Slide 11

Slide 11 text

No content

Slide 12

Slide 12 text

In Dialogue Discovery: Explicit Triggering Ok Google, ask Personal Chef for a hot soup recipe Trigger Phrase App Name Developer Specified Action Preposition Action Phrase Developer Specified Working Examples: Let’s speak to Domino’s Ask Dr. Doggy if dogs can eat chocolate Ok Google, let’s talk to Personal Chef Trigger Phrase App Name Developer Specified

Slide 13

Slide 13 text

Entities: homemade cannoli “Find me a recipe for homemade cannoli” User Says Response Webhook “Find me a recipe for homemade cannoli” “Here’s the best one I can find”

Slide 14

Slide 14 text

Webhook (optional) “Ok Google, talk to personal chef” Dialogflow Invoke “personal chef” action “Well, it’s kind of cold outside, so I’d like something to …” “Sure, here’s your personal chef” “Sure, here’s personal chef. Hi, I’m your personal chef, what are you in the mood for?” “What protein would you like to use?” Speech to Text Text to Speech APP Speech to Text, NLP, Knowledge Graph, ML Ranking, User Profile, Text to Speech

Slide 15

Slide 15 text

Ok Google, talk to Personal Chef Well, it’s kind of cold outside, so I’d like... Sure, here’s Personal Chef What are you in the mood for? What protein would you like to use? Speech to Text NLP Knowledge Graph ML Ranking User Profile Speech to Text Text to Speech ... ... ... Trigger WELCOME event ... NLP: Intent Matching Entity Extraction

Slide 16

Slide 16 text

No content

Slide 17

Slide 17 text

Intent Triggered via a series of “user says” phrases or platform based events. Matched at every turn of conversation. Can collects entity values.

Slide 18

Slide 18 text

Important data you want to get from a user's request, will have a corresponding entity. It’s powerful tools used for extracting parameter values from natural language inputs. This helps to bias the speech recognizer to detect the values you are expecting. Defined synonyms will be mapped to each entity value. Entities

Slide 19

Slide 19 text

Action Dialogflow specific use of Action compared to Google Assistant Conversation Action. String passed to the webhook that indicates what action is being performed. Can share the same action name across different Intents.

Slide 20

Slide 20 text

Input and Output Contexts You can require a context to be available before an Intent is enabled. Implement flow control between some Intents. Intent can set context to enable other Intents.

Slide 21

Slide 21 text

Parameters Values that we are trying to capture from the user phrases. Can specify a parameter name and a type of value. Values can be a list of fixed values. Values can be optional.

Slide 22

Slide 22 text

Text response Spoken when the Intent is complete. Webhook can dynamically adjust this response. Embed entity values if desired, “I found a recipe for $protein and $vegetable!”

Slide 23

Slide 23 text

Specify follow up questions if a user doesn’t specify certain values Read out in random order to make it more natural Prompts

Slide 24

Slide 24 text

Fulfillment Dialogflow project interface with business logic through webhook. It’s all built in the web platform, so you can use the programming language and hosting platform of your choice, it’s just HTTP(S) callbacks.

Slide 25

Slide 25 text

Dialogflow Example Let’s take a quick Dialogflow example

Slide 26

Slide 26 text

Thank you! Abdelrahman Omran | @Omranic | [email protected]