我的 google 操作响应有什么问题导致用户输入无法正常工作?

What's wrong with my google actions response that prevents users input from working?

所以,我正在编写一些针对 Actions SDK 的 Google Actions 代码。我能够收到请求并很好地处理它们。我也能够发送不希望用户响应良好的响应。然而,当我发送一个期望用户做出选择的响应时,google 助手只是不断地一遍又一遍地问这个问题,无论用户说什么(当然除了停止)。这是我的回复 json。有人可以帮忙吗?

我应该注意到 ActionOneIntent、ActionTwoIntent 和 ActionThreeIntent 在 action.json 文件中都已正确配置,并且在通过对我的服务的深度命令调用时可以正常工作(好的 google,请询问我的服务开启动作二)。

我只是无法得到对此数据包的响应:

{
   "conversation_token":"{REMOVED}",
   "expect_user_response":true,
   "expected_inputs":[
   {
     "input_prompt":{
        "initial_prompts":[
           {
              "ssml":"<speak><p>Hello, would you like choice one, two, or three?</p></speak>"
           }
        ]
     },
     "possible_intents":[
        {
           "intent":"AnswerOneIntent"
        },
        {
           "intent":"AnswerTwoIntent"
        },
        {
           "intent":"AnswerThreeIntent"
        }
     ]
  }

] }

在 Actions SDK 的最早版本中,您可以将 "inDialogTriggers" 定义为 Actions 包的一部分。然而,这在 12 月的某个时候被删除了,现在的想法是开发人员处理 "assistant.intent.action.TEXT" 这是用户输入的原始转录。

因此,此时您在回复中的唯一 "possible intent" 应该是 "assistant.intent.action.TEXT"。请参阅此处以供参考:https://developers.google.com/actions/reference/conversation#http-response