如何在 Rasa Core 中收集用户响应而不提取实体。现在我已经能够通过执行以下操作来破解它,但我想知道是否有更好的方法?
域名.yml
slots:
slot: animal
type: categorical
values:
- cat
- dog
故事.md
*greet
-utter_greet
*inform{"Animal":"Dog"}
- utter_hello_fido
*inform
- do_my_action
Python 代码:
class MyAction(Action):
def name(self):
return 'do_my_action'
def run(self):
message = tracker.latest.text
operate on(message)
return []
最佳答案
您可以通过在 Rasa 域文件中指定忽略某些意图的实体提取(请参阅此处的 docs):
intents:
- greet:
use_entities: None
这将忽略所有提取的意图greet
实体。
关于python - Rasa Core - 获取最新消息,自定义操作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51959795/