I’m working on a jupyter notebook to train, test and compare many models using Rasa, as fast as python would allow, and producing some custom reports I think can help my team choose between pipelines.
However, I always gets stuck after training the first model. Using rasa.train or rasa.model_training.train_nlu my jupyter notebook just keeps running indefinitely after saving the trained model, never returning anything.
I’m using Rasa 2.8.26, python 3.8.12 and training models with:
I don’t have any stories available right now and just want to train and compare NLU models. At the beginning of training I get the message No stories present. Just a Rasa NLU model will be trained.
At the end of rasa.train I receive the message NLU model training completed. Your Rasa model is trained and saved at [...]' but the cell keeps running indefinitely.
I am not sure, why you are using JN. I’d recommend to you rasa open source only or rasa x for running the bot. You can train and save the model in the project file. If you are thinking that while using COLab OR JN it will train fast, then I don’t think so.
It’s not the training that I hope to run faster in JN but the testing. CLI’s rasa test takes ~1h to test only one model while I can load the model and make predictions for the same dataset in 2 mins with pandas. That’s also the reason I asked about the async functions, I plan to classify the whole dataset loading the model as a rasa interpreter, applying it to a pandas dataset with the examples and then using rasa methods to produce the classification reports.
Thanks for the answer I’ll train models using !rasa train […] and try to test them using JN.
edit1: I see the link you sent also uses the CLI, what I wanted to learn is how to run the async functions from the JN and use them to produce the classification reports from a pandas dataframe with the model’s predictions. I also wanted to train many models programmatically, loading all configs in a folder and training them one by one through the night, that’s why I was looking for a non-CLI way of training and testing.
edit2: just found out I can pass variables as part of the shell commands in JN, like