[英]Rasa Core - Get Latest Message, Custom Action
How do I just collect a user response in Rasa Core without extracting an entity. 如何仅在Rasa Core中收集用户响应而不提取实体。 Right now I have been able to hack it by doing the following, but I am wondering if there is a better way?
现在,我已经可以通过执行以下操作来破解它,但是我想知道是否有更好的方法?
domain.yml domain.yml
slots:
slot: animal
type: categorical
values:
- cat
- dog
stories.md storys.md
*greet
-utter_greet
*inform{"Animal":"Dog"}
- utter_hello_fido
*inform
- do_my_action
python code: python代码:
class MyAction(Action):
def name(self):
return 'do_my_action'
def run(self):
message = tracker.latest.text
operate on(message)
return []
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.