如何使IBM Watson的意图 /对话节点与动作同时起作用
在高水平上,我试图建立一个沃森助手:
(1)遵循固定的对话结构(目前包含25个步骤)
(2)在每个步骤中,评估用户是否说任何可能被视为安全的东西发出 /“红色标志”,如果是这样,请介绍紧急信息并结束对话,否则继续
使用沃森的操作步骤以上面提到的固定顺序进行下一个对话步骤。效果很好。
我还定义了我称之为“ Redflag”的意图,到目前为止提供了5个示例(将添加更多)用户可能会触发此内容。我还有一个对话节点,该节点检测到此意图并提供紧急信息。效果很好。
我正在努力解决的问题:
a)我不确定一旦检测到了红色反弹的意图,并且助理提供了紧急信息
b)我无法获得对话操作的顺序,以与意图检测和激活相关的对话节点,基本上我的对话结构仅在没有定义的意图 /对话节点时起作用。一旦我有意图(在这种情况下为Redflag One),助手就会忽略对话操作 /步骤,而只是等待用户说出与定义意图相匹配的话。它就像一个 /或情况一样 - 我要么就没有任何意图进行对话,要么我被困在意图检测中,而固定的对话序列 /步骤都没有被激活。
从本质上讲,我试图具有固定的对话结构,同时还具有许多“等待”意图 /对话节点,这些节点可以在固定的对话步骤中的任何时候被激活,具体取决于用户所说的话。
这对我们来说是一个关键点 - 我需要保持固定的对话流程,并且只有在检测到特定意图时才中断它,然后退出(如果是Redflag意图)或激活相关对话 /的适当响应动作节点,然后返回固定序列中的下一个问题。
At a high level, I am trying to build a Watson Assistant that:
(1) Follows a fixed conversation structure (currently containing 25 steps)
(2) At each step, evaluates whether the user is saying anything that might be considered as a safety issue / 'red flag' and, if so, present emergency info and end the conversation, otherwise continue with the next conversation step in the fixed sequence referred to above
I have implemented the fixed conversation structure (item 1 above) using Watson's actions steps. Works well.
I have also defined an intent I call 'RedFlag' and provided 5 examples so far (will be adding more) of what users may say to trigger this. I also have a dialogue node which detects this intent and presents emergency info. Works well.
Issues I am struggling with:
a) I am not sure how to end the conversation once the RedFlag intent is detected and the assistant presents the emergency info
b) I am not able to get the conversation actions sequence to work in parallel with intent detection and activation of the related dialogue node, basically my conversation structure works only if there are no defined intents / dialogue nodes. As soon as I have an intent (in this case the RedFlag one) the assistant ignores the conversation actions / steps and simply waits for the user to say something that matches the defined intent. Its like an either / or situation - either I step through the conversation without any intents or I'm stuck within the intent detection and none of the fixed conversation sequence / steps get activated.
Essentially, I am trying to have a fixed conversation structure while also having a number of 'waiting' intents / dialogue nodes that can be activated at any point during the fixed conversation steps, depending on what the user says.
This is a crucial point for us - I need to keep the fixed conversation flow going and only interrupt it if a specific intent is detected, then either exit (in the case of the RedFlag intent) or activate the appropriate response from the related dialogue / action node and then return to the next question in the fixed sequence.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您应该考虑将危险信号意图添加为主题更改,或者以经典助理术语不可返回的离题。
看:
https://cloud.ibm.com/docs/ watson-Assistant?主题= watson-Assistant-Change-Topic
You should consider adding the Red Flag intent as a Topic change, or in classical Assistant terms a not returnable digression.
See:
https://cloud.ibm.com/docs/watson-assistant?topic=watson-assistant-change-topic
最简单的方法是让您的编排层(对话)或您的webhook(Actions Watson Plus)进行工作。
之后两个选项。
在代码中直接检查了危险信号。
创建一个危险信号实体,然后检查该实体是否是在您的代码中触发的。
The easiest way to do this is to have your orchestration layer (Dialog) or your pre-webhook (Actions Watson Plus) do the work.
After that two options.
Have the red flags checked directly in the code.
Create an entity of red flags and then check if the entity was triggered in your code.