An introduction to Dialogflow (API.AI) for the class of Pervasive Systems of University of Rome - La Sapienza, Master Degree in Computer Engineering.
Demo: https://github.com/lucamaiano/pervasive-agent
1. Luca Maiano
Pervasive Systems 2017/18
Engineering in Computer Science - Sapienza
https://www.linkedin.com/in/lucamaiano/
https://github.com/lucamaiano
2. “Build natural and reach conversational
experiences”
It is powered by Google’s
machine learning and
natural language
processing techniques
Runs on Google Cloud
Platform and easily scales
to a large number of
users
Works across any device,
on many platforms and
supports more than 20
languages
4. Basics of a conversation
Invocation
In order to start the
conversation the user
needs to invoke the
agent.
Agent
It is the container of the
project and transforms a
user’s requests into
actionable data. This
transformation occurs
when a user input
matches one of the
intents inside your agent.
Fulfillment
The API sends
information to your
webhook. It parses the
data, and sends back a
response.
11. 5.1 Fulfill
You have just created your first agent that can recognize requests from users!
In order to serve the actual information the user is requesting, you'll need to setup
fulfillment. It requires deploying a service and calling an API.
Once that you have written your service, deploy it with the following command:
gcloud beta functions deploy helloHttp --stage-bucket [BUCKET_NAME] --trigger-http
“helloHttp” is the name of your project and “[BUCKET_NAME]” can be found on your
Google Cloud project and click on Cloud Storage under the Resources section.
12. 5.2 Fulfill
Make note of the httpsTrigger url:
https://[REGION]-[PROJECT_ID].cloudfunctions.net
/helloHttp
Enable Fulfillment in Intent clicking Use
Webhook.