Hello,
We have the following use case: a bot to book a hotel which asks for the following information:
- amount of people (utter: for how many people?)
- amount of nights (utter: for how many nights?)
We have tried to work with entity-roles, however the slot filling goes wrong. Sometimes it overwrites the previous ‘numerical’ slot (and this is pretty random behavior): For example:
- i want a hotel
- for how many people?
- ten (slot: amount_of_people: ‘10’, slot: amount_of_nights: None)
- for how many nights?
- 2 (slot: amount_of_people: ‘2’, slot: amount_of_nights: ‘2’)
How can we prevent the slot filling to overwrite previous slots?
A part of our domain file:
entities:
- number
- amount_of:
roles:
- people
- nights
slots:
amount_of_people:
type: any
amount_of_nights:
type: any
forms:
search_form:
amount_of_people:
- type: from_entity
entity: amount_of
role: people
- type: from_entity
entity: number
amount_of_nights:
- type: from_entity
entity: amount_of
role: nights
- type: from_entity
entity: number
Some nlu data:
- intent: search_facility
examples: |
- i would like a hotel
- can you suggest a hotel for [2]{"entity":"amount_of", "role":"people"} people
- can you suggest a hotel for [three]{"entity":"amount_of", "role":"nights"} nights
- find a hotel for [one]{"entity":"amount_of", "role":"nights"} night for [eight]{"entity":"amount_of", "role":"people"} persons
- find a hotel
- want to find a hotel for [1]{"entity":"amount_of", "role":"nights"} night
- intent: inform
examples: |
- [one]{"entity":"amount_of", "role":"people"}
- [one]{"entity":"amount_of", "role":"nights"}
- [4]{"entity":"amount_of", "role":"nights"}
- [4]{"entity":"amount_of", "role":"people"}
- [3]{"entity":"amount_of", "role":"people"} persons
- [3]{"entity":"amount_of", "role":"nights"} nights
- [four]{"entity":"amount_of", "role":"nights"} nights
- [four]{"entity":"amount_of", "role":"people"} people
- we are with [five]{"entity":"amount_of", "role":"people"} people and want to stay [9]{"entity":"amount_of", "role":"nights"} nights