Instead of using
rule: tell id
steps:
- intent: ask_id
- action: action_ask_id
I want to set up a rule like this (current syntax is not correct)
rule: tell id
steps:
- text: "id"
- action: action_ask_id
This means ONLY the text id
will trigger the action action_ask_id
. How can I achieve this?
KHTee
(Isaac)
2
You can do the checking inside custom action like
class ActionAskId(Action):
def name(self) -> Text:
return "action_ask_id"
async def run(
self, dispatcher, tracker: Tracker, domain: Dict[Text, Any],
) -> List[Dict[Text, Any]]:
user_msg = tracker.latest_message["text"]
if user_msg == "id":
#do something
return []
Read more at Tracker
1 Like
This is what End-to-end Training is for.
1 Like
Can I set it as a rule instead as a story?
I’ve never tried Even never used them as stories.
But it doesn’t take much time to implement it yourself and give it a go
If it doesn’t work, then @KHTee’s answer is great!
Keep us updated on how you’re doing!