Actions On Google is not getting approved - actions-on-google

My project on Actions On Google is not getting approved and I'm struggling to find a good reason.
Let's say the name of my app is < appname>. The < appname> is a simple two word phrase and is not a duplicate of any existing app in the store.
The invocation names configured are:
Talk to < appname>
Play < appname>
Launch < appname>
Open < appname>
Speak to < appname>
While testing on Google Home Mini, all invocations worked flawlessly. However, Google review folks reverted, suggesting that other than Talk to < appname> all invocations are failing.
Thereafter, I tested on Google Assistant on iPhone. Surprisingly, although the said phrases are being interpreted properly (evident from speech-to-text) but other than Talk to < appname> it fails for other invocations.
They're suggesting to submit the only working invocation but it will limit access to my app.

Precursor
I realize this isn't exactly a code question, but I believe it belongs on Stack Overflow. There's JSON, queries, and invoking methods through voice involved. If it were about other metadata, such as the description and privacy policies, then it would be inappropriate, in my opinion.
I'll go ahead and respond to the question. Please don't hold the validity of the question against me.
Background
I've been building an Action on Google with the Actions SDK. While you're using dialogflow, some of the information I learned today should be helpful. Keep in mind I don't work on Actions on Google, so this is just a response from another user. It's also my first Action and I'm learning with you.
Solution
I think the issue with your configuration is the trigger words of your invocations. I'm still talking with one of the product managers, but it seems only certain trigger phrases are allowed. The format of an invocation is
[trigger] + [your action name] + to + [action invocation phrase]
If you look at the Language and Locales Doc, you will see
Docs: The basic verbs to trigger an app by its name are: talk, speak, and
ask. Here are some example phrases that users can say to trigger your
apps.
"let me talk to $name"
"I want to talk to $name"
"can I talk to $name"
"talk to $name"
...
Therefore some of your trigger phrases are invalid. (Mine were too and I'm going to need to fix for resubmission)
You: However, Google review folks reverted, suggesting that other than Talk
to < appname> all invocations are failing.
Talk to < appname > is working because it uses one of the three permitted English trigger phrases (talk).
I'm surprised the other invocations worked on the Google Home Mini. When I added more invocations through the Actions SDK using other triggers, they would not invoke the action. I can pass this along as a potential bug, where invalid triggers work with dialogflow on test devices, according to your report.
I'll follow up once my assumptions on trigger phrases are confirmed and will let you know if I learn anything notable.
Edit: One more note, I agree more trigger phrases are important for app discovery and I'm trying to find out if they can be added. From what I understand, some are disabled like play for media purposes, i.e. "hey google, play [some song]."

Related

How broad does an action have to be to be allowed to be published?

Imagine I own a small dog grooming business in a small town. Imagine my company is called "Happy Dog" (I'm making this up). Can I write an action that could then be published as "Happy Dog" such that when a user says "Talk to Happy Dog" it will direct users to my action to find out store hours, make bookings and learn prices?
I am not asking about the technical characteristics of such an action. I'm imagining that if I build the action and submit it to Google, they will have to enter it into their database to cause it to be triggered. I'm assuming that this will then trigger its presence "globally".
When I look at https://assistant.google.com/explore/ ... I see nothing that would seem to show small businesses and other such actions being visible. This implies to me that Google rejects such submissions. Is it easy or difficult to get a new assistant action registered with Google? Is there any reading material I should be studying to learn about publishing new actions?
That is correct, we can think of Actions being published globally (there are caveats to that - but ignoreable for your question). Despite this, Actions should be broad enough to be useful, but can certainly be of interest to only a narrow audience.
As an analogy - this is similar to how web sites are published globally. The invocation name is a rough parallel to the domain name for a web site (with the exclusion of the ".com" or whatever TLD you use). Google acts as the sole domain registrar, if we wish to extend this analogy. And while it does enforce certain rules about naming and the directory entry there is no restriction specifically about local or small businesses.
However... you do start running into naming conflicts and trademark issues. For example, you probably can't get "MacDonald's" because it is too close to a trademarked name. One word invocations aren't allowed unless you can verify you also have the corresponding domain name.
To continue the analogy using your example, if you started your "Happy Dog" grooming company, you may try to create a web site and discover that "happydog.com" was already taken. So perhaps you would go with "HappyDogGrooming.com" or "HappyDogSpringfield.com" or something else. In the same way, if "talk to Happy Dog" was already taken, you may need to register "talk to Happy Dog Grooming" or something similar.
It is not difficult to get new Actions published, although you do need to make sure you follow the rules. The review process mostly makes sure you have created a good conversational experience that actually works and does not confuse users. Sometimes there is a bit of back-and-forth with the review team to resolve issues.

Create custom Google Smart Home Action

I have a Google Nest Hub Max and I want to increase its capabilities for a custom need:
"Hey Google, add xyz to my work planning"
Then I want to make an HTTP call to my private server
The private server returns a text
The text is displayed in the Google Nest Hub Max screen + speak-out.
How can that be achieved?
Originally I thought that this will not be difficult. I've imagined a NodeJs, Java, Python or whatever framework where Google gives me the xyz text and I can do my thing and return a simple text. And obviously, Google will handle the intent matching and only call my custom code when users say the precise phrase.
I've tried to search for how to do it online, but there is a lot of documentation everywhere. This post resumes quite well the situation, but I've never found a tutorial or hello world example of such a thing.
Does anyone know how to do it?
For steps 2. and 3., I don't necessarily need to use a private server, if I can achieve what the private server does inside the Smart Home Action code, mostly some basic Python code.
First - you're on the right track! There are a few assumptions and terminology issues in your question that we need to clear up first, but your idea is fundamentally sound:
Google uses the term "Smart Home Actions" to describe controlling IoT/smart home devices such as lights, appliances, outlets, etc. Making something that you control through the Assistant, including Smart Speakers and Smart Hubs, means building a Conversational Action.
Most Conversational Actions need to be invoked by name. So you would start your action with something like "Talk to Work Planning" or "Ask Work Planning to add XYZ'. There are a limited, but growing, number of built in intents (BIIs) to cover other verticals - but don't count on them right now.
All Actions are public. They all share an invocation name namespace and anyone can access them. You can add Account Linking or other ways to ensure a limited audience, and there are ways to have more private alpha and beta testing, but there are issues with both. (Consider this an opportunity!)
You're correct that Google will help you with parsing the Intent and getting the parameter values (the XYZ in your example) and then handing this over to your server. However, the server must be at a publicly accessible address with an HTTPS endpoint. (Google refers to this as a webhook.)
There are a number of resources available, via Google, StackOverflow, and elsewhere:
On StackOverflow, look for the actions-on-google tag. Frequently, conversational actions are either built with dialogflow-es or, more recently, actions-builder which each have their own tags. (And don't forget that when you post your own questions to make sure you provide code, errors, screen shots, and as much other information as you can to help us help you overcome the issues.)
Google's documentation about how to design and build conversational actions.
Google also has codelabs and sample code illustrating how to build conversational actions. The codelabs include the "hello world" examples you are probably looking for.
Most sample code uses JavaScript with node.js, since Google provides a library for it. If you want to use python, you'll need the JSON format that the Assistant will send to your webhook and that it expects back in response.
There are articles and videos written about it. For example, this series of blog posts discussing designing and developing actions outlines the steps and shows the code. And this YouTube playlist takes you through the process step-by-step (and there are other videos covering other details if you want more).

"Okay Google, show pictures of [PARAMETER PHRASE]"

I'm creating a setup of a Google Assistant/Home that should IDEALLY respond to the phrase "Okay Google, show pictures of [PARAMETER PHRASE]" by giving me the parameter phrase. It also HAS to be able to function like a regular home ("Hey Google, how far away is the moon", "... tell me a joke", etc.), without having me reimplement all of that functionality (unmatched phrases should fallback to the Google Home).
If I use the Home, I'm afraid I won't be able to avoid "... tell [MY APP NAME] to ...", but it has a great mic and speaker built in.
I am alternatively looking into a raspberry pi solution for the added layer of control, but the Home has a fantastic mic and speaker already. And importantly, I absolutely don't want to recreate the core Google Home features (possibly able to pass off uncaught phrases to the Google Home backend?)
I can mask some non-parameterized commands with the Assistant Shortcuts ("Okay Google, cat time!", "Hey Google, show me cats") in order to simplify the call phrase, but that does not work because it's not parametrizable.
TLDR: I have a setup that needs to 1. work like a normal Google Home, but must 2. have additional functionality that I implement. I would like to 3. avoid having to state "... tell MY TARGET APP to [...]", but I need 4. parameters to be passed to my code., even if completely unparsed.
What are my options?
There are a bunch of possible approaches here, depending on the exact angle you want to tackle this. None really are perfect at this time, however, but since everything is evolving, we'll see what might develop.
It sounds like you're making an IoT picture frame or something like that? And you want to be able to talk to it? If so, you may want to look into the Assistant SDK, which lets you embed the Assistant into your IoT device. This would let you implement some voice commands yourself, but pass other things off to the Assistant to handle.
But this isn't a perfect solution, since it splits where the voice recognition works, where it is applied, and may not get you the hotword triggering.
It is also still in an early Developer Preview, so things might change, and it may evolve to be something closer to what you want... but it is difficult to tell right now.
Depending on the IoT appliance you're working on, you may be able to leverage the built-in commands by building a Smart Home Action. However, at the moment, these have a fairly limited set of appliance types they can work with. It also sounds like you're trying to deal with media control - which isn't something that Smart Home directly works with, and is (hopefully) a future Action API (there were some hints about this at I/O, with Cast compatibility promised... but no details).
If you really want to build for the Home and Assistant, you'll need to use the limitations around Actions on Google. And that does include some issues with the triggering name.
However... one good strategy is to pick a name that works well with the prefix phrases that are used. Since "Ask" is a legitimate prefix that Home handles, you could plan for a triggering name such as "awesome photo frame", and make the command "Ask awesome photo frame to show pictures of something".
More risky, since it isn't clearly documented, but it seems that some triggering names work without a prefix at all. So if your application is named "fly to the moon", it seems like you can say "Hey Google, fly to the moon" and the action will be triggered. If you can get a name like this registered, it will feel very natural for the user.
Finally, you can pick a reasonable name, but have your users set an alias or shortcut that makes sense to them. I'm not sure how this would fit in with solution (1), but being able for you to predefine shortcuts would make it pretty powerful.
You can't invoke your app without first connecting to your app using Ok Googe, talk to my app* because if it happens so, it will be like talking to the Core Assistant, not your app.
Google doesn't allow to talk an app without app invoke

Multiple language support in Conversation Action

I am planning to design a google action, which will help users to learn some phrases in another language lets say "French". Here is an Example:-
“ok google, let me talk to learn french”
LearnFrench (LF): Hi! This is learn french! Would you like to practice 20 of the most important basic phrases in speaking French?”
user: “Yes”
LF: “Great! I’ll start by telling you a word in French - and you repeat after me. Let’s start with bonjour.
user: bonjour
LF: that was good! Bonjour is the most common greeting you’ll need. Next is "bonsoir" / or let’s try that again, it didn’t quite sound like “bonjour”
user: bonsoir
LF: bonsoir is used as a in the early evening,
etc….continues through 20 or so phrases. After going through those then there could be some type of “recall” practice. LF would say the phrase in English and the user would say the phrase in French. And if the user says it incorrectly then LF “learns” the phrases that the user needs to improve on.
At the end of a session LF would say something like “I think you know the basics here - good luck on your trip”.
If after that session the user came back to LF - LF would know that the user had already come before and would ask if they want to repeat the tutorial - or ask if they want to move straight to the quiz.
Is it possible to have multiple language support?
While Google Assistant is available in other languages, the Actions on Google platform is currently only available in U.S. English and U.K. English. We’re working to make Actions on Google available in other languages, but we don’t have a formal release date. We’ll make announcements to the community with updates as they occur.
If you are already using the invocation name, it is not possible to link it to another project/app.
Thanks,
Actions on Google Support Team

Real time web page

I want to build simple web based app, where users, for example, could push the spacebar button, and then do something further, like answer a question, and while other users at the same time only sees that this question is not available any more for answer. When user submits answer, everyone see it.
All right, here is an example. I have seen TV shows, where four players have one button, if one or two of them know answer, they hit a button, and one lamp turns on and the first is allowed to answer, while other keeps their mouths shut. I want to build the same idea, but in the web.
But problem is that, I don't know where to start, what keywords I should search for help on google and so on. I see, that it might work on HTML5, maybe JavaScript and so on.
I have idea using Ajax, but request it every second to get latest actions made seems rubbish. Also I found one service called Pusher, but it has limited users in one time, which doesn't fit my needs.
I need just ideas. Thanks.
Before you read the rest, a disclaimer: I work for Realtime.co but I do believe I can help here so I'm not trying to "pitch a sale".
You can check out Realtime (www.realtime.co). It's basically a set of tools for developers to use real time technologies on their projects. It uses websockets but does fallback to whatever the user's browser supports (such as long polling, for example).
Behind Realtime you have a one-to-one/one-to-many/many-to-many messaging system that will transport your messages to and from your users.
There's also a plus which is the fact that the Realtime framework is actually cross-platform. This means that you can even have your web users communicate with iPhone users, Android, users, Windows Phone, desktop applications, server applications, etc..
You can learn about the JavaScript API here: http://docs.xrtml.org/getting_started/hello_message.html#javascript.
You only need to register at Realtime.co as a developer and start using the free license.
I really hope that helps.
Okey, I think I will go with node.js.
Writing all this previous post, made me think in right way :)