Designing Natural Conversations with Dialogflow

Wassim Chegham | Developer Advocate SFEIR | @manekiekko

Remember this?

A new generation of BOTS

ML—Driven Natural Language Understanding

ML—Powered Voice Recognition

Google Developer Expert

for the Angular team

Core Team (ESM Modules)

Node.js Foundation

Do open source at manekinekko

SFEIR

Developer Advocate

for the Google Assistant team

for the GCP team

Google Developer Expert

Google Developer Expert

Tweet at @manekinekko

Blog at @wassimchegham

Let's Start Off With Some Terminologies

Can you book an Indian style restaurant for 2 people for tomorrow at 7pm near my address?

Intents

A mapping between what the user says and what action should be taken by your software.

Each action can have many intents, which will provide different experiences to the user.

Training Phrases

Triggered via a series of "user says" phrases or platform based events.

Can collect entity values.

Matched at every turn of conversation.

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 optional.

Values can be a list of fixed values.

Custom Entities* / Composite Entities

* Dialogflow can handle simple things like plurality and capitalization, but make sure to add all possible synonyms for your entries. The more you add, the better your agent can determine your entities.

System Entities (built-in)

  • Time
  • Date
  • Time Period
  • Number
  • Cardinal
  • Ordinal
  • Temperature
  • Speed
  • Volume
  • Weight
  • Age
  • Currency
  • Country
  • Location
  • Language
  • Artist
  • Music

      ...

Prompts

Specify follow up question if a user doesn't specify certain values.

Read out in random order to make it more natural.

Fulfillment

Run a remote business code to fetch the data and send the response.

Run your Cloud Function anywhere!

Dialogflow Simulator

Test your agent by entering text or voice requests.

 

Diagnostic request/response payloads.

Several

One-Click

Integrations

Agent Training

A training tool that allows you to analyze conversation logs with your agent and add annotated examples to relevant intents in bulk.

40+ Prebuilt Agents

Prebuilt agents are a collection of agents developed by the Dialogflow team. In the developer console, you can download agents to your account that fit your use case and use them as a base for building a conversational interface for your app, bot, or device.

Small Talks

Dialogflow includes an optional feature called Small Talk, which is used to provide responses to casual conversation. This feature can greatly improve a user's experience when talking to your agent.

Versions and Environments*

Versioning and Environments in Dialogflow allow you to deploy multiple versions of your agent to separate, customizable instances of environments, depending on your needs.

 

* Currently in BETA

Machine Learning

An agent “learns” both from the examples you provide in the Training Phrases section and the language models developed by Dialogflow.

 

Based on this data, the Agent builds a model (algorithm) for making decisions on which intent should be triggered by a user input and what data needs to be extracted.

 

This algorithm is unique to your agent.

 

ML settings can be disabled or tweaked.

Multi-language Support

Lets you support multiple root languages and locales within the same agent, allowing you to specify different Training Phrases and Responses for each language your agent supports.

 

Support 15 root languages

Sharing Agents

Many team members can collaborate on an agent, and the level of access granted to each team member can be controlled.

 

You can manage access using either the Dialogflow console or the GCP console.

 

Many roles: Admin, Developer, Reviewer, API...

Analytics

The analytics page gives you insight into how well your agent is performing, so you can work to further improve the user experience you’re providing.

 

  • Usage data – number of sessions and queries per session.
  • NLU data – most frequently used intents and exit percentages.

Analytics: Filtering through Sessions

Filtering the data by chosen date range (1 day, 7 days, or 30 days).

Queries Per Session

Analytics: Session flow

Dialogflow SDKs

Open source client libraries

Useful Links

Designing Natural Conversations with Dialogflow

By Wassim Chegham

Designing Natural Conversations with Dialogflow

BBL: An introduction to designing natural conversations with Dialogflow

  • 3,769