Hello RASA community,
Excited to have my first post here.
I have a problem regarding entity extraction and slot value setting in RASA nlu. I need to ask the user whether his subscription model is based on a “flat-rate” or “actual” costs and provide information based on his response. So as outlined in the docs, I created a categorical slot and an entity in the domain.yml as follows:
slots: expenseType: type: categorical values: - actual - flatrate entities: - expenseType
And in the NLU traning data, my examples for this case look like this:
## intent:provide_info - I have a travel costs [flat-rate](expenseType:flatrate) agreement - I only pay [actual](expenseType:actual) travel costs - [actual](expenseType:actual) costs - [actual](expenseType:actual) - [flat-rate](expenseType:flatrate) - [flatrate](expenseType:flatrate)
Additionally, I added synonyms there:
## synonym:flatrate - flat-rate - flat rate
I assumed that since I specified two possible categories, the value of the slot will always be one of the categories, and the provided info would be sufficient to learn the synonyms. But it makes a difference whether the user writes
flat rate or
flatrate and depending on writing style this is actually set as the slot value. For example in the case of
flat-rate I get this warning:
WARNING:rasa_core.slots:Categorical slot 'expenseType' is set to a value ('flat - rate') that is not specified in the domain. Value will be ignored and the slot will behave as if no value is set. Make sure to add all values a categorical slot should store to the domain.
Since I do a look-up based on these slot values in a custom action, these action also fails since the value is not found in the table.
What do you recommend in order to only have slot values as specified by the categories in the domain? (Is the domain.yml actually used during NLU traning?).