Can from_entity inside the form, holds multiple entity values

Hi All,

I came across with one scenario, where I need to holds multiple entity values to a single slot inside the form. Please find my domain.yml code snippet below :-

slots:
  filter_criteria:
    type: list
    influence_conversation: false
	
forms:
  create_preference_form:
    filter_criteria:
      - type: from_entity
        entity: entity1, entity2, entity3, entity4, entity5

Can anyone please help me on this, How I can achieve this (entity: entity1, entity2, entity3, entity4, entity5) in RASA.

Thanks in Advanced :slightly_smiling_face:

Yes, you would add a from_entity block for each entity.

You’ll find an example in the financial-demo here.

Hi @stephens,

Thanks for the suggestions.

Actually in my scenario user will provide multiple entity values in a single message. If user provide one entity value in one message, then I can define block for each entity.

How to define entity block when user provides multiple entities in a single message.

You still define it the same.

Hi @stephens,

You mean to say, I should define the block for each entity and it should always refer to same slot.

Did I understood it correctly ?

Look this part in stephens examples

239 - 254

  search_type:
    type: any
    influence_conversation: false
    mappings:
    - intent: search_transactions
      type: from_trigger_intent
      value: spend
    - intent: check_earnings
      type: from_trigger_intent
      value: deposit
    - type: from_entity
      entity: search_type
      conditions:
      - active_loop: transaction_search_form
    - type: from_entity
      entity: search_type

Hi @itsjhonny,

I am new to RASA and not getting exactly how I can define entity block for my scenario. I tried it in many ways but unfortunately none of them worked for me.

Let me explain my scenario to you. I have to build a conversational chatbot where user is trying to create a preference using some filters and the workflow goes like this

User : I would like to create an preference

Bot : Can you please help me with the filter criteria to create a preference.

User : I want to apply HSQ, EEA, IEA, 10GE filters for my preference.

These HSQ, EEA, IEA, 10GE are the values of multiple entity and user will always provide multiple filter values in single message, so I used form to collect the user input and trying to store all the user filter values in a slot (type as list).

I want this slot to hold multiple value like this filter_criteria : [entity-name: entity-value]

How can I achieve this using slot and form in RASA ?

can I set multiple values in examples like this [yaqinlashtir]{“entity”:“instype”, “value”:“zoom_in”, “value”:“instruction”} ?