Example #1
0
 def submit(self, dispatcher, tracker, domain):
     """Define what the form has to do
         after all required slots are filled"""
     print("####Came here")
     # utter submit template
     # dispatcher.utter_template("utter_submit", tracker)
     # tracker.trigger_followup_action('action_ack_makereservation')
     FollowupAction('action_search_flights')
     return []
Example #2
0
def test_json_parse_followup():
    # DOCS MARKER FollowupAction
    evt = \
        {
            'event': 'followup',
            'name': 'my_action'
        }
    # DOCS END
    assert Event.from_parameters(evt) == FollowupAction("my_action")
Example #3
0
def test_json_parse_followup():
    # DOCS MARKER FollowupAction
    evt = {"event": "followup", "name": "my_action"}
    # DOCS END
    assert Event.from_parameters(evt) == FollowupAction("my_action")
Example #4
0
            }, []),
            UserUttered("/goodbye", {
                "name": "goodbye",
                "confidence": 1.0
            }, []),
        ),
        (SlotSet("my_slot", "value"), SlotSet("my__other_slot", "value")),
        (Restarted(), None),
        (AllSlotsReset(), None),
        (ConversationPaused(), None),
        (ConversationResumed(), None),
        (StoryExported(), None),
        (ActionReverted(), None),
        (UserUtteranceReverted(), None),
        (ActionExecuted("my_action"), ActionExecuted("my_other_action")),
        (FollowupAction("my_action"), FollowupAction("my_other_action")),
        (
            BotUttered("my_text", {"my_data": 1}),
            BotUttered("my_other_test", {"my_other_data": 1}),
        ),
        (
            AgentUttered("my_text", "my_data"),
            AgentUttered("my_other_test", "my_other_data"),
        ),
        (
            ReminderScheduled("my_action", datetime.now()),
            ReminderScheduled("my_other_action", datetime.now()),
        ),
    ],
)
def test_event_has_proper_implementation(one_event, another_event):
Example #5
0
def test_json_parse_followup():
    evt = {"event": "followup", "name": "my_action"}
    assert Event.from_parameters(evt) == FollowupAction("my_action")