Custom action

Hi everyone, I’ve been working with RASA for some time now, but there is still a problem I can’t figure out. the problem is that bot is not able to execute the customize action when chatting with a user and I will be very grateful if somebody can help me in fixing this problem

customize action

class HeadacheSuggest(Action): def name(self): return ‘action_ask_symptoms_and_insurance_name’

def run(self, dispatcher, tracker, domain):
    response="You said you have not been feeling fine for the last {} days, these symptoms {} means you have  headache  which can be cured with ABC drugs but you need to see a doctor, what is the name of your insurance".format(dayss,symptomss)
    return []



  • greet
  • utter_howcanhelp
  • sick_mode
  • utter_symptoms
  • headache_symptoms{“symptoms”:“Headache upon awakening, difficulty falling asleep, staying asleep, General muscle aching”}
  • utter_number_days
  • number_of_days{“days”:“5”}
  • action_ask_symptoms_and_insurance_name
  • hospital_insurance_search{“insurance”: “AB insurance”}
  • utter_AB insurance_hospital *affirm
  • utter_great
  • thank_you
  • utter_thank
  • goodbye
  • utter_goodbye.

domain of the bot

slots: symptoms: type: categorical insurance: type: categorical days: type: categorical sick: type: categorical


  • sick
  • insurance
  • days
  • symptoms


  • greet
  • affirm
  • sick_mode
  • hospital_search
  • headache_symptoms
  • hospital_insurance_search
  • number_of_days
  • thank + goodbye
  • thank_you
  • goodbye templates: utter_goodbye:
    • “goodbye :(”
    • “Bye-bye”

utter_symptoms: - “how do you feel, I mean some of the signs and symptoms of your sickness” utter_number_days: - "Since when did your sickness started, I mean how many days now " utter_howcanhelp: - “hi, how can I help you?” utter_on_it: - “am on it” utter_great: - “great” utter_thank: - “thank you and all the best” utter_AB insurance_hospital: - "with AB insurance you can visit ABC hospital "


  • utter_greet
  • utter_goodbye
  • utter_howcanhelp
  • utter_symptoms
  • utter_number_days
  • utter_great
  • utter_thank
  • utter_on_it
  • action_ask_symptoms_and_insurance_name

conversation with the bot

YOU: hi BOTT :hi, how can I help you? YOU: am not feeling fine BOTT :how do you feel, I mean some of the signs and symptoms of your sickness YOU: nausea, extreme fatigue, fainting, dizziness BOTT :Since when did your sickness started, I mean how many days now YOU: 5 YOU: AB insurance BOTT :with AB insurance you can visit ABC hospital YOU: bye

Can you please format this in a more legible way?