Rasa nlu server is not called by rasa core

I am newbie on Rasa . I am not able to call nlu server endpoint from Core server

Following are information regarding setup Rasa Version - Rasa 1.3.3

setup : Rasa core & Action ( Python) are bundle together

        Rasa NLU app on different server .

Command 1, Running an NLU server

$ rasa run --enable-api -m models/nlu-20190515-144445.tar.gz
  1. Running Action server

    rasa run actions

  2. Running Core server to start interaction . Following model is core model trained based on stories.md

rasa shell -m ./models/core/core-20191011-104704.tar.gz --endpoints endpoints.yml -p 5006 --debug

When i start my core server shell and start giving input like Hi , Hello or another greet . My assumption was from my core server , it should go to NLU server to understand intent & entities and then executed my actions based on intent from NLU .

I haven’t seen request going to NLU server . I have mentioned my NLU url in endpoints.yml

Following are endpoint.yaml content :

action_endpoint:

url: http://localhost:5055/webhook

nlu:

url: “http://localhost:5005

===== Following log from Rasa Core =====

Bot loaded. Type a message and press enter (use ‘/stop’ to exit):

Your input → hello

2019-10-13 07:45:08 DEBUG rasa.core.tracker_store - Creating a new tracker for id ‘default’. 2019-10-13 07:45:08 DEBUG rasa.core.processor - Received user message ‘hello’ with intent ‘{‘name’: ‘hello’, ‘confidence’: 1.0}’ and entities ‘’ 2019-10-13 07:45:08 DEBUG rasa.core.processor - Logged UserUtterance - tracker now has 2 events 2019-10-13 07:45:08 DEBUG rasa.core.featurizers - Feature ‘intent_hello’ (value: ‘1.0’) could not be found in feature map. Make sure you added all intents and entities to the domain 2019-10-13 07:45:08 DEBUG rasa.core.policies.memoization - Current tracker state [None, None, None, None, {}, {‘intent_hello’: 1.0, ‘prev_action_listen’: 1.0}] 2019-10-13 07:45:08 DEBUG rasa.core.policies.memoization - There is no memorised next action 2019-10-13 07:45:08 DEBUG rasa.core.policies.form_policy - There is no active form 2019-10-13 07:45:08 DEBUG rasa.core.policies.ensemble - Predicted next action using policy_0_KerasPolicy 2019-10-13 07:45:08 DEBUG rasa.core.processor - Predicted next action ‘action_chitchat’ with confidence 0.79. 2019-10-13 07:45:08 DEBUG rasa.core.actions.action - Calling action endpoint to run action ‘action_chitchat’. 2019-10-13 07:45:08 DEBUG rasa.core.processor - Action ‘action_chitchat’ ended with events ‘’ 2019-10-13 07:45:08 DEBUG rasa.core.processor - Current slot values: facility_address: None facility_id: None facility_type: None location: None requested_slot: None 2019-10-13 07:45:08 DEBUG rasa.core.featurizers - Feature ‘intent_hello’ (value: ‘1.0’) could not be found in feature map. Make sure you added all intents and entities to the domain 2019-10-13 07:45:08 DEBUG rasa.core.featurizers - Feature ‘intent_hello’ (value: ‘1.0’) could not be found in feature map. Make sure you added all intents and entities to the domain 2019-10-13 07:45:08 DEBUG rasa.core.policies.memoization - Current tracker state [None, None, None, {}, {‘intent_hello’: 1.0, ‘prev_action_listen’: 1.0}, {‘intent_hello’: 1.0, ‘prev_action_chitchat’: 1.0}] 2019-10-13 07:45:08 DEBUG rasa.core.policies.memoization - There is no memorised next action 2019-10-13 07:45:08 DEBUG rasa.core.policies.form_policy - There is no active form 2019-10-13 07:45:08 DEBUG rasa.core.policies.ensemble - Predicted next action using policy_0_KerasPolicy 2019-10-13 07:45:08 DEBUG rasa.core.processor - Predicted next action ‘action_listen’ with confidence 0.97. 2019-10-13 07:45:08 DEBUG rasa.core.processor - Action ‘action_listen’ ended with events ‘’ 2019-10-13 07:45:08 DEBUG rasa.core.lock_store - Deleted lock for conversation ‘default’.

Thanks in advance

Hi @ashuvig,

I am not quite sure but I don’t think it’s actually possible to split NLU from Core anymore as shortly mentioned here. However, you pointed to a local server in your endpoints.yml so even if the split would be possible, you would have to make sure that there actually is a server locally running.

Can you show me where you read, that an entry “nlu” in endpoints.yml is valid?

Regards Julian

Hi Julian , Thanks for prompt reply . My nlu server is running locally without issues . This functionality might not available in current version

Documentation Link HTTP API

Here is the part of documentation

Connecting Rasa NLU

To connect Rasa Core with a NLU server, you have to add the connection details into your endpoint configuration file:

nlu: url: “http://:5000” token: # [optional] token_name: # [optional] (default: token)

Then run Rasa Core with the --endpoints <path_to_your_endpoint_config>.yml and specify the nlu model to use with the -u flag. For example:

python -m rasa_core.run -d models/current/dialogue \ -u <project_name>/<model_name> \ --endpoints endpoints.yml

Thanks Anshul

Hi @ashuvig,

okay I see - as I already thought, this is valid for the legacy version of Rasa but not for the current one. Is there an absolute need to divide the system in two parts? Aren’t you able to use Rasa as a whole?

Regards Julian

I am just thinking of separation of concern for deployment purpose .

  • rasa core server
  • rasa NLU server
  • seperate action server (NodeJs) My next task is to seperate at least action server from Rasa framework . Thanks a lot for reply .

Hi @ashuvig,

just in case that you didnt read it: separating the action server is pretty easy. If you need help with that, just ask. Regarding the deployment - a simple way to avoid goofy hacks or dealing with weird dependencies is to use Docker.

How about that in your case?

Regards Julian

Sure Julian Thanks a ton

Hi Julian Do you have any reference implementation of action server in Nodejs

Thanks in advance

Hi @ashuvig,

do you mean running an action server in NodeJS (different code base) like documented here ?

Regards

Yes , action server on NodeJs and custom actions will be on NodeJs instead of python

Thanks

Hi Julian , I am able to run action server on NodeJS (Different code base ) . I can see Rasa calling my NodeJs action server . Though it is primitive right now .At least able to move forward . Thanks