Using NLU Only Flashcards
Whats the cli command to train nlu only?
rasa train nlu
This will look for NLU training data files in the data/ directory and saves a trained model in the models/ directory.
The name of the model will start with nlu-.
How to test the nlu model on the command line?
To try out your NLU model on the command line, use the rasa shell nlu command
This will start the rasa shell and ask you to type in a message to test. You can keep typing in as many messages as you like.
or:rasa shell -m models/nlu-20190515-144445.tar.gz
How to run the nlu server?
rasa run –enable-api -m models/nlu-20190515-144445.tar.gz
How do you request predictions form the model?
You can then request predictions from your model using the /model/parse endpoint. To do this, run:
curl localhost:5005/model/parse -d '{"text":"hello"}'
When the nlu is passed the following what will it return?
"I am looking for a Mexican restaurant in the center of town"
It will return structured data like this:
{
“intent”: “search_restaurant”,
“entities”: {
“cuisine” : “Mexican”,
“location” : “center”
}
}
~~~
~~~