Rasa 2 Lookup Table file syntax

Ah gotcha! I did not realize that I should also remove the line -lookup: xxx. The warning message is gone, cheers XD

1 Like

Glad to hear it! :slight_smile:

@fkoerner you are saying, I don’t have to mention my lookups folder and file in the nlu.yml file?

I did as you mentioned above, I also add some examples in the nlu file. but still, I am not sure it is looking in my lookups/product.yml. sometimes it is recognizing sometimes it doesn’t. You know, how can I verify that it is looking in lookup files?

Thank you!

@tanyraj

sometimes it is recognizing sometimes it doesn’t

Just to check:

  • Do you have RegexEntityExtractor in your pipeline?
  • Do you have at least 2 labeled examples per entity type in your nlu file?
  • Is the lookups/product.yml file in your data folder (default is data, otherwise you can specify a different folder with --data parameter)

ok. got your point.

Answering your questions:

  • Yes, RegexEntityExtrator is in my pipeline.
  • I am a little confused about your 2nd question. In my lookups/product.yml file, there is around 15000 different product fall under product entity. so you are saying I have to give, for all 15000 products only two examples in my nlu file?
  • Yes, lookups/product.yml is in my data folder.

@fkoerner Thank you for your response!

@tanayraj You’re welcome! For the second question, you will need to have examples in your nlu file for the product entity. You will need to have at least two examples in your nlu file that use this entity, for example:

 - intent: purchase_product
   examples: |
        - I want to buy a [phone](product)
        - Could I purchase a [laptop](product)

Does that help?

Hi Fkoerner, Hope you could help us here .!

My lookup file string contains some special characters like.

  • PV7…C/D/N/W
  • DS2513…ATEX

But I wanted to extract that entity when a user enters .! So basically whatever I add in my lookup file should be treated as a normal string irrespective of any special char.! is there any way to handle it easily like if I wrap it in single quotes rasa treats it as string?

MFG, Suryakiran

Hi @suryakiran sorry, not quite sure what you’re getting at here! Do you mean you want it to be recognized even if the user types: PV!? What’s the behaviour you’re currently seeing?