Suggest existent values in data base

Hello,

In my nlu examples, I rely heavily on the location of entities inside of a given sentence. Which means that, rasa extracts every entity even if it’s not present in my examples.

Let’s take the following example: Every person is referenced as following: person1, person3,…, person31 I have a text file where I have defined all the references that exist (from person1 to person31) all the numbers next to person are odd numbers. and my sentence would be: hello I am person3 Rasa would know that person3 is an entity called “reference”.

So if I gave the following sentence: Hello i am person4, I want Rasa to be able to recognize that this number does not exist in my “references_file” and suggest person3 or person5 instead. I also want it to be able to recognize the following error: hello i am berzon3, and suggest person3 instead (like a spellchecking, only with my words instead).

Now I am only using Rasa NLU (intent and entities extraction) and I know that I can use a custom component that would look up the file and add a value that suggests “closer references” to the rasa message.

But, is there any other way Rasa suggests better values for entities?

sorry, I don’t understand what do you want to achieve