Is there a way to execute a few custom actions when I start the Rasa server or the action endpoint server?
I have a few custom actions to read data from files and generate various buttons to be used later on.
- I need to execute these actions only at the beginning; when I start the rasa server or the action endpoint server.
- I need the variables generated from these actions; a dictionary containing some data and lists of buttons to serve various purposes, to be available in the memory for quick access whenever needed in other custom actions.
This is how I have currently implemented this: 1.Configured these actions under the greet intent in my stories 2.Whenever a user greets the bot, these actions are executed
However, these actions take a few seconds to be executed and I do not need them to be executed every time the user greets the bot, it just delays the bot’s simple response to the user’s greet. I’m looking for a way to execute these actions only when either the Rasa server or the action endpoint server is restarted and persist the variables generated (dictionary and buttons) in memory until the next restart.