Hi. I’m integrating the Rasa API to backend of my website. I tried connecting the “Train Your Model” webhook. The server responds 500. My code chunk and the payload is as following: Code: modelTrainLoad = json.dumps({
{
"domain": "intents:\n - greet\n - goodbye\n - affirm\n - deny\n - mood_great\n - mood_unhappy\n\nresponses:\n utter_greet:\n - text: \"Hey! How are you?\"\n\n utter_cheer_up:\n - text: \"Here is something to cheer you up:\"\n image: \"https://i.imgur.com/nGF1K8f.jpg\"\n\n utter_did_that_help:\n - text: \"Did that help you?\"\n\n utter_happy:\n - text: \"Great carry on!\"\n\n utter_goodbye:\n - text: \"Bye\"",
"config": "language: en\npipeline: supervised_embeddings\npolicies:\n - name: MemoizationPolicy\n - name: TEDPolicy",
"nlu": "- intent: greet\n examples: |\n - hey\n - hello\n - hi\n\n- intent: goodbye\n examples: |\n - bye\n - goodbye\n - have a nice day\n - see you\n\n- intent: affirm\n examples: |\n - yes\n - indeed\n\n- intent: deny\n examples: |\n - no\n - never\n\n- intent: mood_great\n examples: |\n - perfect\n - very good\n - great\n\n- intent: mood_unhappy\n examples: |\n - sad\n - not good\n - unhappy",
"responses": "chitchat/ask_name: - text: my name is Sara, Rasa's documentation bot! chitchat/ask_weather: - text: it's always sunny where I live",
"stories": "- story: happy path\n steps:\n - intent: greet\n - action: utter_greet\n - intent: mood_great\n - action: utter_happy\n\n- story: sad path 1\n steps:\n - intent: greet\n - action: utter_greet\n - intent: mood_unhappy\n - action: utter_cheer_up\n - action: utter_did_that_help\n - intent: affirm\n - action: utter_happy\n\n- story: sad path 2\n steps:\n - intent: greet\n - action: utter_greet\n - intent: mood_unhappy\n - action: utter_cheer_up\n - action: utter_did_that_help\n - intent: deny\n - action: utter_goodbye\n\n- story: say goodbye\n steps:\n - intent: goodbye\n - action: utter_goodbye",
}
})
modelTrain = requests.post('http://localhost:5005/model/train', data=modelTrainLoad)
print('modelTrain: ' + str(modelTrain))
Following is the error on CMD: No training data given. Please provide stories and NLU data in order to train a Rasa model using the ‘–data’ argument. 2021-08-24 14:33:33 ERROR rasa.server - Ran training, but it finished without a trained model.