我的谈话如下:
Alexa: Do you want to go to a movie?
User: No
Alexa : Can I help you with anything else?
User: No
Alexa: Okay, until next time.
这样的事情:
if intent_name == "AMAZON.NoIntent":
return no_response(session_attributes)
def no_response(session_attributes):
if session_attributes is None:
card_title = "NO RESPONSE"
speech_output = "Okay. Do you want me to help with anything else?"
reprompt_text = "Sorry. Can you repeat that again, please?"
should_end_session = False
session_attributes['myorder']='first'
else:
card_title = "NO RESPONSES"
speech_output = "Thankyou."
reprompt_text = "Sorry. Can you repeat that again, please?"
should_end_session = True
return build_response(session_attributes, build_speechlet_response(
card_title, speech_output, reprompt_text, should_end_session))
如何启用alexa为不同的No ??
提供不同的响应答案 0 :(得分:0)
你必须使用alexa会话属性状态并根据状态make决策树来了解如何处理它