I’m trying a simple hello-world in custom action but the bot don’t reply.
this is my action.py file :
from rasa_sdk.events import SlotSet
from rasa_sdk import Action
class ActionHelloWorld(Action):
def name(self):
return "action_hello_world"
def run(self, dispatcher, tracker, domain):
dispatcher.utter_message("Hello world !") # send the message back to the user
return []
I can’t run python -m rasa_sdk --actions actions in Docker container. The port 5055 is already in use…
The custom action server is already running. I can show you the log with docker logs -f [custom action container id] :
[root@wqya1726 chatbot_rasa]# docker logs -f 91e81f9ffcc
2019-11-14 15:50:29 INFO rasa_sdk.endpoint - Starting action endpoint server...
2019-11-14 15:50:29 INFO rasa_sdk.executor - Registered function for 'action_hello_world'.
2019-11-14 15:50:29 INFO rasa_sdk.endpoint - Action endpoint is up and running on http ('0.0.0.0', 5055)
And after i run docker run -it --network="chatbot_rasa_default" -v $(pwd):/app rasa/fr:latest shell -vv
But no response is returned by the bot and there is nothing in custom action server logs.
Oh, i tried your code and look at this the action server respond :
2019-11-15 09:08:28 INFO rasa_sdk.endpoint - Starting action endpoint server...
2019-11-15 09:08:28 INFO rasa_sdk.executor - Registered function for 'action_hello_world'.
2019-11-15 09:08:28 INFO rasa_sdk.endpoint - Action endpoint is up and running on http ('0.0.0.0', 5055)
2019-11-15 09:15:20 WARNING rasa_sdk.endpoint - Your versions of rasa and rasa_sdk might not be compatible. You are currently running rasa version 1.4.5 and rasa_sdk version 1.5.0a1.
To ensure compatibility use the same version for both, modulo the last number, i.e. using version A.B.x the numbers A and B should be identical for both rasa and rasa_sdk.
Hello Your Name yo
Here oim
this is tracker <rasa_sdk.interfaces.Tracker object at 0x7fa2496eaf98>
172.20.0.2 - - [2019-11-15 09:15:20] "POST /webhook HTTP/1.1" 200 283 0.001558
i executed rasa interactive and always no response :
? Your input -> yo
? Your NLU model classified 'yo' with intent 'greet' and there are no entities, is this correct? Yes
------
Chat History
# Bot You
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
1 action_listen
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
2 yo
intent: greet 0.74
------
? The bot wants to run 'action_hello_world', correct? Yes
------
Chat History
# Bot You
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
1 action_listen
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
2 yo
intent: greet 0.74
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq
3 action_hello_world 1.00
------
? The bot wants to run 'action_listen', correct? (Y/n)