Skip to content
This repository has been archived by the owner on Aug 16, 2023. It is now read-only.

How to off the mic after conv.add() #13

Open
ashokkumar88 opened this issue Oct 14, 2020 · 5 comments
Open

How to off the mic after conv.add() #13

ashokkumar88 opened this issue Oct 14, 2020 · 5 comments

Comments

@ashokkumar88
Copy link

My project rejected because the mic was open after conversion. How to off the mic after conv.add(). The conv.close() function is not available.

@taycaldwell
Copy link
Contributor

You can set the transitioning scene to end the conversation.

If you want to do this from the webhook you can do:

conv.scene.next = { name: 'actions.scene.END_CONVERSATION' };

@ashokkumar88
Copy link
Author

ashokkumar88 commented Oct 14, 2020

But I do not want to end the conversation only need to close the mic. In the documentation there is conv.close() function but it is not available to use. https://actions-on-google.github.io/actions-on-google-nodejs/classes/conversation.conversation-1.html

@Fleker
Copy link
Member

Fleker commented Oct 14, 2020

conv.close() would also end the conversation. The platform expectation is to create a single conversation of back-and-forth until the conversation is finished.

@afirstenberg
Copy link

The problem is not that you need to close the mic. The issue is that the review team has determined there are places in your conversation where your agent says something, but doesn't make it clear that the user needs to reply. Your action has replied, the mic is open for the user to say something, but it isn't clear that they need to say anything.

The easiest solution to this is to make sure that every time you expect the user to reply, make sure you prompt them. This is usually done with a question, such as "what would you like to do now?"

You can include this as a second "simple" response with code such as

conv.add("Here is the info you need.");
conv.add("What would you like to do now?");

@ashokkumar88
Copy link
Author

@afirstenberg Thanks. It is approved.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants