简体   繁体   English

谷歌助理接管给我的行动命令

[英]Google Assistant taking over the commands given to my action

There have been triggering problems with my action since a few days ago.从几天前开始,我的操作就出现了问题。 The queries that should have been handled by my action were routed to Google Assistant main flow.应该由我的操作处理的查询被路由到 Google Assistant 主流程。 This happens on both Android Phone, and Google Home.这发生在 Android 手机和 Google Home 上。

Steps to repro:复现步骤:

  • Speak: OK Google, talk to Tinker Doodle.发言:OK Google,与 Tinker Doodle 交谈。
  • Assistant: Welcome to Tinker Doodle, what can I do for you?助理:欢迎来到 Tinker Doodle,有什么可以为您效劳的吗?
  • Speak: Available commands.说话:可用的命令。
  • Assistant: (Abruptly end Tinker Doodle conversation, list general commands on Assistant.)助手:(突然结束 Tinker Doodle 对话,在助手上列出一般命令。)

I'd expect Assistant to stay in Tinker Doodle conversation, and feed the input to my action.我希望 Google 助理留在 Tinker Doodle 对话中,并将输入提供给我的操作。

This makes Tinker Doodle almost unusable.这使得 Tinker Doodle 几乎无法使用。 Can you help with this?你能帮忙解决这个问题吗?

I configured the NO_MATCH system intent to call my webhook, since I use my own NLP.我配置了 NO_MATCH 系统意图来调用我的 webhook,因为我使用我自己的 NLP。

This worked well on Android Phone and Google Home, until a few days ago.直到几天前,这在 Android Phone 和 Google Home 上都运行良好。 There is no problem running in simulator on Action Builder.在 Action Builder 上的模拟器中运行没有问题。

Here are the screenshots of the main scene and NO_MATCH intent from Action Builder.以下是来自 Action Builder 的主场景和 NO_MATCH 意图的屏幕截图。

在此处输入图片说明 在此处输入图片说明

Rather than using no_match, you can employ the design that the custom-nlu sample uses:您可以使用custom-nlu 示例使用的设计,而不是使用 no_match:

Have a 'Main' scene that tries to match on a user_utterance intent:有一个试图匹配user_utterance意图的“主要”场景:

在此处输入图片说明

Then the user_utterance matches on everything using the any data type:然后 user_utterance 使用any数据类型匹配所有内容:

在此处输入图片说明

When you go to the Simulator, any query should match your intent explicitly and then, as part of the sample, it will echo your response:当您转到模拟器时,任何查询都应明确匹配您的意图,然后作为示例的一部分,它将回应您的响应:

在此处输入图片说明

It isn't clear, but this sounds like it may be related to recent announcements that, in some cases, phrases that don't match a specific Intent may cause your Action to close so the Assistant can handle the phrase instead.目前尚不清楚,但这听起来可能与最近的公告有关,在某些情况下,与特定意图不匹配的短语可能会导致您的操作关闭,以便 Google 助理可以处理该短语。

Even besides this, handling things with NO_MATCH is generally undesirable, since that will only happen three times in a row before the Action is forcibly closed.除此之外,使用 NO_MATCH 处理事物通常是不可取的,因为在强制关闭 Action 之前,这种情况只会连续发生 3 次。

Instead, you should create an Intent that can handle "any" input and route that input to your handler using this method.相反,您应该创建一个可以处理“任何”输入并使用此方法将该输入路由到您的处理程序的 Intent。 That involves:这涉及:

  1. Creating a new Type (I usually call it "Any") that accepts Free form text创建一个接受自由格式文本的新类型(我通常称之为“任何”)

创建 Any 类型

  1. Creating an Intent (which I have named "matchAny") that accepts values of this type through its training phrases (or even just one phrase that accepts a value of this type)创建一个 Intent(我将其命名为“matchAny”),通过它的训练短语(或者甚至只是一个接受这种类型的值的短语)接受这种类型的值

匹配任何意图

  1. In your Scene, add this as an Intent that can be matched, and then set the handler for your webhook when it does.在您的场景中,将此添加为可以匹配的 Intent,然后在匹配时为您的 webhook 设置处理程序。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM