Alexa技能在某些情况下不会呼叫端点

时间:2019-01-21 10:31:23

标签: alexa

我正在开发一种Alexa技能,并在Alexa开发人员控制台中对其进行测试。我对某些问题有疑问,不会引起任何回应。在这些情况下,没有调用我的端点,或者激发了DefaultFallback意图。

我可以重现该错误,并且仅在某些问题上会发生。调试日志显示以下条目。我已经将该技能部署到设备上并获得了相同的响应(即没有响应)。该技能仍然开放,因为我可以继续问其他问题并得到答复。

如果我将“香肠”一词替换为某些单词,则不会给出任何响应,但是使用“免费”之类的单词将返回响应。

没事了...

事件:Text.TextMessage

                  Walkins.aggregate([
                        {
                            $match:{'subscriberId': subsc._id},
                        },{
                            $project:{'date':{ $toDate:'$created'} },
                        } },{
                            $project:{ 'dates': { $dateToString : { format: "%Y-%m-%d", date: "$created" } }} ,
                        },{
                            $group:{
                                _id:{'date': '$created'} ,
                                walkinsCount :{$sum: 1 }
                            }
                        }

                    ]).then((walkins)=>{    });

指令:SpeechRecognizer.RequestProcessingCompleted

{
    "event": {
        "header": {
            "namespace": "Text",
            "name": "TextMessage",
            "messageId": "messageId",
            "dialogRequestId": "ba1efffc-b29e-4cef-bcc0-3ceb418b89ec"
        },
        "payload": {
            "textMessage": "do you have any sausage samples"
        }
    },
    "context": [
        {
            "header": {
                "namespace": "System",
                "name": "SettingsState",
                "payloadVersion": "1"
            },
            "payload": {
                "settings": [
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.experiences",
                        "value": "[{\"arcMinuteWidth\":\"246\",\"arcMinuteHeight\":\"144\",\"canRotate\":\"false\",\"canResize\":\"false\"}]"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.shape",
                        "value": "RECTANGLE"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.pixelWidth",
                        "value": "1024"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.pixelHeight",
                        "value": "600"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.dpi",
                        "value": "160"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.currentPixelWidth",
                        "value": "1024"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.currentPixelHeight",
                        "value": "600"
                    },
                    {
                        "key": "com.amazon.alexa.characteristics.viewport.touch",
                        "value": "[\"SINGLE\"]"
                    }
                ]
            }
        },
        {
            "header": {
                "namespace": "SpeechSynthesizer",
                "name": "SpeechState"
            },
            "payload": {
                "token": "amzn1.as-ct.v1.ThirdPartySdkSpeechlet#ACRI#ValidatedSpeakDirective_amzn1.ask.skill.8f0abe6c-a5e8-4585-912f-4e21df999811_6bf05e00-bc3a-4b1e-8b40-9664b36c0378",
                "offsetInMilliseconds": 1000,
                "playerActivity": "FINISHED"
            }
        },
        {
            "header": {
                "namespace": "AudioPlayer",
                "name": "PlaybackState"
            },
            "payload": {
                "token": "",
                "offsetInMilliseconds": 0,
                "playerActivity": "IDLE"
            }
        },
        {
            "header": {
                "namespace": "Alerts",
                "name": "AlertsState"
            },
            "payload": {
                "activeAlerts": [],
                "allAlerts": []
            }
        },
        {
            "header": {
                "namespace": "VisualFocusManager",
                "name": "VisualFocusState"
            },
            "payload": {
                "inFocus": {
                    "component": "ListRenderer",
                    "idleTimeInMilliseconds": 0
                }
            }
        },
        {
            "header": {
                "namespace": "AudioFocusManager",
                "name": "AudioFocusState"
            },
            "payload": {
                "dialog": {
                    "component": "SpeechSynthesizer",
                    "idleTimeInMilliseconds": 0
                }
            }
        },
        {
            "header": {
                "namespace": "ListRenderer",
                "name": "RenderedListState"
            },
            "payload": {
                "listToken": "amzn1.as-lt.v1.ThirdPartySdkSpeechlet#LRID#amzn1.ask.skill.8f0abe6c-a5e8-4585-912f-4e21df999811::JTEXd",
                "itemsVisibleOnScreen": [],
                "selectedItems": [],
                "focusedItem": {},
                "renderedItemDetail": {
                    "listItemIdentifier": "amzn1.as-lt.v1.ThirdPartySdkSpeechlet#LRID#amzn1.ask.skill.8f0abe6c-a5e8-4585-912f-4e21df999811::JTEXd",
                    "ordinalNumber": 1
                },
                "highestOrdinalSeen": 1,
                "lastItemOrdinal": 1
            }
        }
    ]
}

指令:SkillDebugger.CaptureDebuggingInfo

{
    "header": {
        "namespace": "SpeechRecognizer",
        "name": "RequestProcessingCompleted",
        "messageId": "77057f6b-8f91-4fb4-aab0-c86efc934adc",
        "dialogRequestId": "ba1efffc-b29e-4cef-bcc0-3ceb418b89ec"
    },
    "payload": {}
}

编辑: 我现在认为未达到一定的置信度得分,导致该意图不触发(但随后没有调用默认的后备意图)。如果我问“标记放置模式”,则意图会正确触发,并且会得到完整的调试跟踪: enter image description here

如果我问“摆旗香肠”,那么我会得到一个小的调试跟踪以及相同的意图,但是没有答案,也没有端点调用: enter image description here

0 个答案:

没有答案