0

我开始将自己投入到 aog 中。我现在只使用 SDK 和 WebSimulator。我想要实现的是更改我之前设置的提示,例如因为我有新信息可用。我尝试了以下失败:

let inputPrompt = assistant.buildInputPrompt(true, '<speak>1+1=3 Agree?</speak>',['I didn\'t hear a number', 'If you\'re still there, what\'s the number?', 'What is the number?']);
assistant.ask(inputPrompt);
let inputPrompt2 = assistant.buildInputPrompt(true, '<speak>Sorry! 1+1=2 Agree?</speak>',['I didn\'t hear a number', 'If you\'re still there, what\'s the number?', 'What is the number?']);
assistant.ask(inputPrompt2);

仅显示第一个提示,然后(仅在用户响应后)显示第二个提示。

是否有可能改变提示服务器端?如何做呢?或者是否有解决方法?

4

1 回答 1

0

assistant.ask()方法将向用户发送提示,然后等待响应

如果您尝试向用户发送内容,然后在他们回复之前发送其他内容,则您目前无法使用 Actions 执行此操作。这更像是通知或异步操作。

于 2017-01-07T17:07:58.760 回答