I am trying to develop a chatbot using rasa nlu and rasa core. But I am not getting the link how rasa_nlu using lookup_tables for entity extraction. I had already go through (http://blog.rasa.com/improving-entity-extraction/) link but not getting it. How should lookup_table used for to extract the entity?
相关问题
- how to define constructor for Python's new Nam
- streaming md5sum of contents of a large remote tar
- How to get the background from multiple images by
- Evil ctypes hack in python
- Correctly parse PDF paragraphs with Python
Requirements:
If you want to use lookup tables, make sure:
In your training data
In order to use look up tables, you can either define them directly in the training data, e.g.:
Or you can write them in a text file:
And then include the path to the text file in your training data:
Taking an input like Could I pay in Euro?, Rasa NLU then sets the value of the slot
currency
toEuro
.How they work
The single items in a look up table are added to a regular expression (regex) which is applied to the the messages which your users send to the bot. However, look up tables don't work if your user inserts typos, e.g. a look up table entry
Pesos
would not matchPeesos
. To also match these cases you can try fuzzy matching which is described in the blog article you linked. Make sure that your look up tables don't become too large as Rasa NLU has to check every sentence whether it matches one of your look up table entries.Maybe the Rasa NLU documentation can also help you.