# RASA Action server Custom action not working

**URL:** <https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981>\
**Category:** Rasa Open Source\
**Created:** [February 19, 2020, 3:48am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981 "2020-02-19T03:48:12Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aditya07](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Aditya07](https://forum.rasa.com/u/Aditya07)\
**Post date:** [February 19, 2020, 3:48am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/1 "2020-02-19T03:48:12Z")

</div>

Hello All ,

I am trying to run an action server on rasa cli using “rasa run actions”. Server is getting kicked off

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/b/b3944e66ad74ea45f670a19422cf2431720a5380.png)

However when i do interactive learning using below command

rasa interactive -m models/20200219-090917.tar.gz --endpoints endpoints.yml --skip-visualization

I get the below error while calling my custom action file

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/3/342e6ab2152b92c1510a2779b384e36774cd1981.png)

I am also attaching a sample actions file. it is very simple. normal return statement using dispatcher. **Please can anyone help what is the issue ?**

[actions.py](https://forum.rasa.com/uploads/short-url/2RL7N2wMJ5Hix4kdBBhepsQuzRX.py) (515 Bytes)

Also attaching domain and stories.md, endpoint.yml

[domain.yml](https://forum.rasa.com/uploads/short-url/hPtTZR5usccIDcrcPHrUVPmwFBS.yml) (628 Bytes) [endpoints.yml](https://forum.rasa.com/uploads/short-url/lGfGHZGYrhTfK79udlKjgxcRBfU.yml) (56 Bytes) [stories.md](https://forum.rasa.com/uploads/short-url/gBwtkGBuBg23UG6MJduJkbZcOAz.md) (255 Bytes)

---

<div class="post-metadata">

**Author:** ![koaning](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/koaning/32/6626_2.png) [@koaning](https://forum.rasa.com/u/koaning)\
**Post date:** [February 19, 2020, 8:29am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/2 "2020-02-19T08:29:30Z")

</div>

Hi Aditya,

I wouldn’t mind reproducing your steps, but in order to do that I’d also like to see your `nlu.md` file. It is fine it it only has a few examples in it but that way I can produce my own model and mimic what you are doing.

Feel free to just paste it in here with as code, for example;

```auto
## intent:greet
- hey
- hello
- hi
- good morning
- good evening
- hey there

```

Another option would be git repo.

---

<div class="post-metadata">

**Author:** ![Aditya07](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Aditya07](https://forum.rasa.com/u/Aditya07)\
**Post date:** [February 19, 2020, 8:52am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/3 "2020-02-19T08:52:17Z")

</div>

Hello ,

Stories .md file is the same file.

You can refer that please.[stories.md](https://forum.rasa.com/uploads/short-url/gBwtkGBuBg23UG6MJduJkbZcOAz.md) (255 Bytes)

---

<div class="post-metadata">

**Author:** ![koaning](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/koaning/32/6626_2.png) [@koaning](https://forum.rasa.com/u/koaning)\
**Post date:** [February 19, 2020, 9:24am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/4 "2020-02-19T09:24:27Z")

</div>

The `stories.md` file typically contains how different intents are linked together. An example portion from the rasa starter is listed below.

```auto
## happy path
* greet
  - utter_greet
* mood_great
  - utter_happy

## sad path 1
* greet
  - utter_greet
* mood_unhappy
  - utter_cheer_up
  - utter_did_that_help
* affirm
  - utter_happy

```

The `nlu.md` file contains examples of each intent so that the ML part can learn from it. An example portion from the rasa starter is listed below.

```auto
## intent:greet
- hey
- hello
- hi
- good morning
- good evening
- hey there

## intent:mood_great
- perfect
- very good
- great
- amazing
- wonderful
- I am feeling very good
- I am great
- I'm good

```

What I received from you looks like a `stories.md` file without example of each intent.

```auto
## story 01
* greet
	-utter_greet
	
## story 02
* bye
	-utter_goodbye

## story 03
* request
	-utter_ask_acc
	
## story 04
* install
	-utter_ask_app
	
## story 05
* request
	-action_helpdesk

## story 06
* install
	-action_helpdesk

```

Without the file that contains examples of the intents it would be hard to reproduce what you’ve got.

---

<div class="post-metadata">

**Author:** ![Aditya07](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Aditya07](https://forum.rasa.com/u/Aditya07)\
**Post date:** [February 19, 2020, 9:36am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/5 "2020-02-19T09:36:36Z")

</div>

[nlu\_adi.md](https://forum.rasa.com/uploads/short-url/yEwRZIuiE1L5IzDQc2cLkAN9qUt.md) (1.2 KB)

---

<div class="post-metadata">

**Author:** ![koaning](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/koaning/32/6626_2.png) [@koaning](https://forum.rasa.com/u/koaning)\
**Post date:** [February 19, 2020, 5:49pm UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/6 "2020-02-19T17:49:53Z")

</div>

Strange. On my end it seems to run just fine.

I first start the action server by running;

```bash
rasa run actions

```

Next I run;

```bash
> rasa interactive
? Your input -> install python                                                                                                                             
? Your NLU model classified 'install python' with intent 'installation' and there are no entities, is this correct? Yes                                   
------
Chat History

 # Bot You        
────────────────────────────────────────────────────────────
 1 action_listen                                         
────────────────────────────────────────────────────────────
 2 hi install 
                                         intent: greet 0.36 
────────────────────────────────────────────────────────────
 3 utter_greet 1.00                                      
      Hello! How can I help?                                
      action_listen 1.00                                    
────────────────────────────────────────────────────────────
 4 install python 
                                  intent: installation 0.98 

Current slots: 
        accessory: None, application: None

------
? The bot wants to run 'action_helpdesk', correct? Yes                                                                                                    
/Users/Vincent/Development/help-somebody/venv/lib/python3.7/site-packages/rasa/utils/common.py:351: UserWarning: Action 'action_helpdesk' set a slot type 'accessory' which it never set during the training. This can throw off the prediction. Make sure to include training examples in your stories for the different types of slots this action can return. Remember: you need to set the slots manually in the stories by adding '- slot{"accessory": None}' after the action.
------
Chat History

 # Bot You        
─────────────────────────────────────────────────────────────
 1 action_listen                                          
─────────────────────────────────────────────────────────────
 2 hi install 
                                          intent: greet 0.36 
─────────────────────────────────────────────────────────────
 3 utter_greet 1.00                                       
      Hello! How can I help?                                 
      action_listen 1.00                                     
─────────────────────────────────────────────────────────────
 4 install python 
                                   intent: installation 0.98 
─────────────────────────────────────────────────────────────
 5 action_helpdesk 0.45                                   
      Here                                                   
      slot{"accessory": null}                                

Current slots: 
        accessory: None, application: None

```

---

<div class="post-metadata">

**Author:** ![koaning](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/koaning/32/6626_2.png) [@koaning](https://forum.rasa.com/u/koaning)\
**Post date:** [February 19, 2020, 5:54pm UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/7 "2020-02-19T17:54:13Z")

</div>

It is really tricky for me to replicate what you’re seeing. If you host this as an open github project I can better reproduce the steps that you have.

One thought that comes to mind though … are you running just that one action server or many others?

---

<div class="post-metadata">

**Author:** ![Aditya07](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Aditya07](https://forum.rasa.com/u/Aditya07)\
**Post date:** [February 20, 2020, 3:51am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/8 "2020-02-20T03:51:04Z")

</div>

just one.

Why dont you try this ?

1. start with hello
2. then say " raise a request"
3. then say laptop 4 . then it should ask for a wrong utterance, just give no there and select action\_helpdesk action.

You wont see any answer and will get the error

---

<div class="post-metadata">

**Author:** ![Aditya07](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Aditya07](https://forum.rasa.com/u/Aditya07)\
**Post date:** [February 25, 2020, 3:19am UTC](https://forum.rasa.com/t/rasa-action-server-custom-action-not-working/24981/9 "2020-02-25T03:19:26Z")

</div>

Any update to this please ?
