Composite entities
Use composite entities when you want to combine two different entities into one.
Last updated
Use composite entities when you want to combine two different entities into one.
Last updated
A composite entity is a combination of two or more different, yet related entities. This type of entity allows you to combine two separate entities into a single one.
To add a composite entity to your bot:
From your Entities tab, make sure that you have different entities that your composite would be made of. For this example, we created a @car_brand
match entity and will use @sys.number
.
Click on Composite entities.
Click on Add composite entity.
Fill in the Entity name.
Under Entity values, add the entities that will make the composite one.
Click on Create entity.
To route your flow based on composite entities:
Create a Collect input block where you composite entity will be detected. In this example, we detect @car_info
.
Let's say you now want to route the flow based on the year of the car. For instance:
When the year is equal to or more than 2016, the car is a green car
When the year is less than 2016, the car is not a green car.
Create a Condition block that checks the @car_brand.sys.number
variable.
Click Save.