Answer doesn't match with entity values

Hi All,

i have entity called size that accept values (small, medium, large).

suppose once bot ask user: what size do you want user response from one of above values.

but i want if user ask anything else of above sizes: bot response this size is not exist

i already used Form Action and create slot and using have a story in rules.yml

regards,

@taysh you means like this scenario:

bot: what size you required for pizza?
user: Medium
bot: Ok, Thanks

Or

bot: what size you required for pizza?
user: extra small
bot: Sorry, we have only small, medium and larger size pizza?
bot: what size you required for pizza?

Is this your requirement? or I misunderstood your question.

Hi @nik202 Yes that exactly what i mean

@taysh you slots are categorical?

@nik202 No its text I used forms and custom action and made the story in rules.yml I tried to make some if else statements in actions but it was not helpful

@taysh you need to check the slot type in doc: Domain check the categorical slots. Then, you need to check the form validation : Forms

OR

for more examples of form custom actions please check this repo: https://github.com/RasaHQ/rasa-2.x-form-examples

Even see this video: How to Validate Form Input in Rasa | Rasa Tutorials - YouTube and you can mention the slots with if and else. Keep your use case in mind while seeing the video.

OR

If you want to fetch the values based on entities please again check the forms in doc.

OR

you can even check this blog and see how in this stress is mention as low, medium and high. How to Build Your First Rasa Form | The Rasa Blog | Rasa

Why you don’t make this with pre-set choises i.e. buttons?

1 Like

I am having the same issue. Have we found any solution ? As per my understanding When Form is active it should expect and accept user Input as a slot value, but instead it takes it as another intent. I have one usecase where I want to take server name as an user input while Form is active and get the response via backend python APIs. There could be thousands of servers and all can’t be defined or added in NLU.yaml as ‘server name’. I don’t want to implement button based bot. I am trying to resolve this via Regex.

Any solution please suggest