What does the following Debug Info for tensorflow means?
INFO:rasa_nlu.model:Starting to train component intent_classifier_tensorflow_embedding DEBUG:rasa_nlu.classifiers.embedding_intent_classifier:Check if num_neg 20 is smaller than number of intents 9, else set num_neg to the number of intents - 1
I am not familiar with the code of this algorithm yet. For me, there is no explanation from the code for the meaning of this. What and why? In my case num_neg is 20 and intents I have is 9…
so, you cannot pick 20 things if you have only 9, one of which is correct, so effectively you have 9-1=8 incorrect intents to pick from. So this resets your num_neg to 8, to avoid error during negative sampling
there is an intent for each example in the nlu training data. This one intent - is the correct intent for this example, all the other intents are therefore incorrect. 20 is a default value for how many such other incorrect intents to use during optimization. It is called “negative sampling”, for more details please read original starspace paper: https://arxiv.org/abs/1709.03856, and consequent links on the topic there