two form in rasa code example
Example 1: two form in rasa
utter_cheer_up:
- text: "Here is something to cheer you up:"
image: "https://i.imgur.com/nGF1K8f.jpg"
utter_did_that_help:
- text: "Did that help you?"
utter_happy:
- text: "Great, carry on!"
Example 2: two form in rasa
class CarSearchForm(FormAction):
def name(self):
return "carSearch_form"
@staticmethod
def required_slots(tracker: Tracker) -> List[Text]:
return ['make', 'model', .......]
Example 3: two form in rasa
class BookAppointmentForm(FormAction):
def name(self):
return "bookAppointment_form"
@staticmethod
def required_slots(tracker: Tracker) -> List[Text]:
return ['name', 'phone', .......]
Example 4: two form in rasa
## survey stop
* greet
- utter_greet
* affirm
- health_form
- form{"name": "health_form"}
* out_of_scope
- utter_ask_continue
* deny
- action_deactivate_form
- form{"name": null}
- utter_goodbye
Example 5: two form in rasa
## survey continue
* greet
- utter_greet
* affirm
- health_form
- form{"name": "health_form"}
* out_of_scope
- utter_ask_continue
* affirm
- health_form
- form{"name": null}
- utter_slots_values