'Need to call custom action when form is requesting for sots

am using rasa 1.9.5.

I have a form that gets activated and it will ask for the slots to fill. When it is asking for a slot to fill it's calling utter_slots_name. But my requirement is, I need to call custom action instead like action_slots_name.

I need to call custom action for all slot filling questions.

NLU:

## intent:greet
- Hi
- Hello
- I need a help
- just need help
- can you server me

## intent: greeting_with_name
- Hi I am [sharath](name), I need some services
- Hi myself [sharath](name), Need some services
- Hi this is [sharath](name), need some services

## intent: are_u_bot
- are you a bot?
- are you a human?
- am I talking to a bot?
- am I talking to a human?


## intent: my_name_is
- my name is [sharath](name)
- [sharath](name)
- I am [sharath](name)
- Myself [sharath](name)

Stories:

## bot challenge
* bot_challenge
  - utter_iamabot


## happy path
* greet
  - action_greeting
  - user_details
  - form{"name":"user_details"}
  - form{"name":null}
  - action_askfor_services

Domain:

actions:
  - action_askfor_services
  - action_slots_name
  - user_details
  - action_greeting
  
intents: 
  - greet
  - bot_challenge
  - my_name_is
  - greeting_with_name

form:
  - user_details

entities:
  - name
  - phoneNo
  - tenentId
  - language


slots:
  language:
    type: text  
  name:
    type: text
  phoneNo:
    type: text
  tenentId:
    type: text
  requested_slot:
    type: text 

responses:
  utter_iamabot:
  - text: I am a bot, powered by Rasa.
  utter_bye:
  - text: bye
  
session_config:
  carry_over_slots_to_new_session: true
  session_expiration_time: 60


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source