dialogflow

How to record microphone audio in JavaScript and submit to DialogFlow?

南笙酒味 提交于 2019-12-13 08:08:50
问题 How can I record audio from the microphone in JavaScript and submit it to DialogFlow, without going through a server? 回答1: There are two parts to this question: How to record microphone audio in a format DialogFlow will understand. How to actually submit that audio to DialogFlow, with proper authentication. Part 1 For recording microphone audio in a format DialogFlow will understand, I use opus-recorder, then convert the blob it returns using the code below: function BlobToDataURL(blob: Blob)

Dialog-flow Chat bot using MySQL

≡放荡痞女 提交于 2019-12-13 05:25:07
问题 I am developing a Chat bot using Dialog-flow which will be based on a database that I am preferring to use MySQL. The Chat bot will send the answers on the basis of DB after querying the data. I have created a basic chat bot with a small Database. What should I do to develop a communication link between MySQL and the Dialog-flow or is there any Database that I can use? Help me, please. 回答1: To communicate with your database from a Dialogflow agent, you will need to use fulfillment. Dialogflow

How can I show user input on Response section in Dialogflow

淺唱寂寞╮ 提交于 2019-12-13 05:08:47
问题 I would like to print out user input on a Response Section but for some reason I cannot seem to find how can I do this. For example: Bot: How old are you? User: 40 Bot: Your age is 40. I am also attaching a screenshot where I have a parameter but I just dont know to what to assing age. Currently I get Your age is 100 as I manually added 100 as a value to age parameter. Any idea on this? 回答1: To get the input from user you have to capture that age value in an entity. You can either use a

Unable to handle multiple fulfillment responses

末鹿安然 提交于 2019-12-13 05:07:45
问题 I am using the dialogflow enterprise edition bot,the issue is about receiving responses from rest api(node.js sdk).Recently we have shifted from dialogflow standard edition to Enterprise edition. We have referred and used the following code in this link https://www.npmjs.com/package/dialogflow We have created our own cloud function using rest Api which takes the user answer as the request and send the fulfillment text(questions in that particular intent) as the response to the user.When

Google Assistant account linking with Keycloak

荒凉一梦 提交于 2019-12-13 04:13:20
问题 I am building a Dialogflow agent and I am trying to have account linking with OAuth between my website and Google Assistant. And I am using Keycloak as my authentification server. Keycloak configuration Account Linking Result Then after I put the username and password Any Ideas why Google assistant does not sgin in? And is there a way to debug it? 来源: https://stackoverflow.com/questions/55693603/google-assistant-account-linking-with-keycloak

How to extract the parameter from INTENT in order to pass it to webhook?

孤者浪人 提交于 2019-12-13 04:12:03
问题 Suppose there is an intent in Dialogflow named " intent.direction ". This intent have some phrases like : " Direction to PLACE_NAME " or " Navigate to PLACE_NAME ",etc. Here " PLACE_NAME " is the name of any place to which user wants to go. When this intent is triggered , I want the " PLACE_NAME " i.e. name of place, to be passed to my WEBHOOK (index.js). Is there any way to do this? -------------------UPDATED RESPONSES------------------ function makeDirection(app) { if (!hasScreen) { app.ask

Keeping data between intents from WebHook in Dialogflow

孤人 提交于 2019-12-13 04:05:27
问题 I'm trying to build a movie bot, and I need to save the ID from a movie which I got via my webhook, and keep it in a place where can be access by the follow up intents in that context. Right now I'm using the payload in fulfillment to pass data to the first intent, but in the follow up intents that data is lost. 回答1: You should probably include the data you want remembered across intents in a context. You should set the lifespan to be long enough for all the intents that will need the info.

How to write this Fulfillment codes(including output)?

旧巷老猫 提交于 2019-12-13 03:51:59
问题 First of all, I tried to write how to save users input data to google sheet after developing the simple codes. It' s able to work . Thank Mr.Master for providing this tutorial(Below the link ). Reference Mr.Master: https://www.youtube.com/watch?v=huwUpJZsTok Next, I bumped into the problem below the code. I didn't know how to write it in Fulfillment. Could someone realize it to teach me? Tool: Dialogflow, Google sheet, Firebase. Theme: Order process I tried to write Forhere() there. However,

Passing Facebook Messenger bot webview data to Dialogflow and continuing the conversation

让人想犯罪 __ 提交于 2019-12-13 03:24:48
问题 I am using Dialogflow and Facebook messenger to build a interface that opens a Facebook Messenger webview to allow the user to input data. Once the user inputs the data in the webview I want to: Get this data send to Dialogflow and continue the conversation with the user and ask them a follow up question How can I do this? 回答1: Dialogflow doesn't current listen for Facebook Messenger webview events. Dialogflow supports Facebook Messenger welcome (i.e. when the user opens a chat window to

How to get user confirmation for Location and the geo-coordinates in Dialogflow?

半城伤御伤魂 提交于 2019-12-13 02:57:04
问题 I am making app for google assistant using dialog flow. My app uses a webhook function deployed on firebase. Main question is how to get user location - I need to pass the coordinates to a URL. I am able to prompt the message for location permission, but how to confirm and get coordinates. Do I need to add any intent for confirmation? I am asking for location permission in default welcome intent. The code is below: 'use strict'; process.env.DEBUG = 'actions-on-google:*'; const App = require(