It's possible to create one-shoot app with Actions on Google? - dialogflow-es

I am completely new to the "Actions on Google" world, but following some tutorials (like this) i have already achieved good results.
My test
With Google Assistant and/or Google Home mini send my commands to a personal nodejs online server.
To do this:
i have created a new project on https://console.actions.google.com/
selected conversational option
selected create action / custom intent option
from Dialogflow i have personalized the Default Welcome Intent and created a new Intent with the Fulfillment option set to Enable webhook call for this intent
And obviously, from Dialogflow > Fulfillment, i have enabled the Webhook option (with the url of my nodejs app), and not the Inline editor.
This procedure works, when my app recognizes my custom intent, the answer is sent to my nodejs app online.
My problem
The procedure works, but i always have to do 2 steps before i can perform my action:
1) Hey Google, talk with "nameofmyapp"
2) Say the command
My goal
Execute my command directly without always having to do this 2 steps.

Absolutely! Google calls this "deep linking". With this, you'll be able to do something like
Hey Google, ask nameof myapp to command
See the documentation for details, but in short you'll
Make sure you have an Intent for the command in Dialogflow, with several possible phrases that can be used to trigger it.
These phrases should be what you'd say under "command" in the example above - you'd omit the "to" part.
Go to the Integrations section in Dialogflow, under the Google Assistant integration.
In the Implicit invocation section, select the Intent that you'd like to allow as a deep-linked Intent.
If the command takes action and then should quit, make sure either you have set this in Dialogflow or your fulfillment calls app.close();

Related

How can I manage suicidal intents using actions-on-google npm package

My setup:
I'm using actions-on-google to create a custom action for google assistant, every intent is a fallback in dialogflow that is then redirected to my server where I check the intent with a custom nlp engine and then respond to it, using the actions-on-google package.
The issue:
But when an intent is suicidal, for example: "I want to kill myself", google stop the action and give a response instead of letting my custom action handle it. Is there a way to avoid this?, it also happens with certain words like "Save" in that case google stop the action and ask me if I want to save an event or whatnot.
Can I override this behavior?
You're running into a "feature" that Google calls "no-match yielding". In some cases, if you're using a Fallback Intent in Dialogflow, and the Google Assistant itself can handle the question - it will do so.
To avoid this you can use regular Intents that match the #sys.any System Entity.
However, if all you're doing for everything is sending it to your NLU, then you don't need to be using Dialogflow at all. You can just use the Actions on Google v2 to send all TEXT Intents to your NLU for processing.

Doesn`t appear all the intents of the agent

I have a DialogFlow agent with the default intents and also intents "Registrar" and "explicacion-funcionamiento" but none of these appears on Actions on Google. It only shows the defaults. I put some photos.
Although I'm using the Dialogflow integration, I need Actions on Google to access the basic information of the user (I need the email).
What can I do?
This is my dialogflow agent:
This is the actions builder:
If the user is not logged in, I will redirect him to the "explicacion-funcionamiento" but if he is signed in, he can access to "registrar" intent.
That 's why i need this intent.
You don't need to use the Actions Builder to use Dialogflow with Actions on Google, or even to use Account Linking. Dialogflow's integration with Actions on Google can still be done using the Actions Console, but the Actions Builder screens aren't available.
The pages for Account Linking with Dialogflow are still available, and most previous questions in StackOverflow still reference how to do this with Dialogflow.
Keep in mind that there are tradeoffs between using Dialogflow and Actions Builder - but Account Linking is supported equally well in both.
If you do wish to switch to Actions Builder (and to get new features, you'll need to do so), there is (currently) no way to automatically convert from one to the other.

Bot was not started on DialogFlow for Telegram Integration

When I put the Telegram Token in DialogFlow, I get the error Bot was not started. I have started the bot in Telegram app. How do I solve this?
let’s say we will make the bot to give answers about programming language
steps:
create new agent
create entities
create the words contained in the entities
create intents
enter training phases (DialogFlow will recognise parts of the phases containing entities you just created. it will give different colors for different entities)
set default responses
add google assistant (if needed)
add response for Google Assistant. activate Google Assistant Response. choose basic card. add the image link (we can do this later). put the search text
https://google.com/search?q=how+to+le...
add more responses (telegram, slack, web demo, twitter, facebook messenger, etc.). you will get a token for activating the integration (in this example) i use Telegram
add response to Telegram. add card. fill in the card. don’t forget to add the search terms (you can add image url later)
at action and parameters section, set prompts for responses if needed
go to integrations. choose telegram (or whatever you chose before)
follow the instructions on how to create a bot in a telegram here: https://cloud.google.com/dialogflow/d...
copy the generated token
press start
there you go! now you have your own bot :)

Dialogflow Show welcome text without user action

I am trying to show welcome text when user initiates the chat i.e. without any action from user. How to achieve this?
I tried NPM dialog flow or #google-cloud/dialogflow to detect intent to trigger the intent using node.js. It is sending the query and showing the fullfillment text in console but not on updating the UI like when user interact with bot.
Thanks.
If you're using Actions on Google, then your welcome Intent will be called when your Action is first invoked. The user wouldn't say anything besides "talk to action name".
Using the Actions on Google test emulator, this is provided as a button.
If you're using the Dialogflow tester on the right side of Dialogflow, you need to enter one of the invocation phrases for the Welcome Intent, but these phrases aren't typically used as part of the Action itself.

Google Actions with custom webhook

I have built a small conversational bot using API.AI with Node.js as the back end. So every time a user makes a request it goes to my server and then from my server to API.Ai and it follows the same route with a response.
Now, I want to integrate it with Google Actions. But, Google Actions allows me to use API.AI as my webhook whereas I want Google Actions to talk to my server.
I have checked everywhere and can't find the correct process. Any, help will be appreciated in Integrating Actions with custom webhook instead of API.API
The normal way it would work would be to have the Google servers for the Assistant talk to API.AI, and then API.AI would call your webhook. This lets API.AI do all of the natural language processing (NLP) and not have you attempt to write this part yourself to load into the Actions console.
Your API.AI project and your Action project need to be the same - if not, you can create a new Action project using the same project as API.AI, or you can export the contents of your API.AI project and import it into a new one.
Your API.AI project also needs to have the Actions on Google Integration turned on. From the left menu, select Integrations and then the Actions on Google tile and turn it on.
However
If you want to send things through your server, and then have your server call the API.AI API yourself, you can certainly do this. You would develop against the Actions SDK and provide an actions.json file which describes the intents and webhook to use.

Resources