# Filling multiple slots at the same time with FormAction and dynamic buttons in template?

**URL:** <https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261>\
**Category:** Rasa Open Source\
**Created:** [March 22, 2019, 2:12pm UTC](https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261 "2019-03-22T14:12:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sdkone](https://avatars.discourse-cdn.com/v4/letter/s/ed655f/32.png) [@sdkone](https://forum.rasa.com/u/sdkone)\
**Post date:** [March 22, 2019, 2:12pm UTC](https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261/1 "2019-03-22T14:12:31Z")

</div>

For example, there are 3 slots, which is date, time, location. FormAction asks the user one by one, which is not ideal. If the user just say " next week Monday near London", can the rasa core pick them up and fill the slot in one shot if the NLU extracts the entities when inside a form action?

And is there a way to generate dynamic buttons with a template? I know there’s an utter\_button\_message, but can we insert more buttons into an existing template while in custom actions? Thank you.

---

<div class="post-metadata">

**Author:** ![RGK](https://avatars.discourse-cdn.com/v4/letter/r/a87d85/32.png) [@RGK](https://forum.rasa.com/u/RGK)\
**Post date:** [March 22, 2019, 2:22pm UTC](https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261/2 "2019-03-22T14:22:57Z")

</div>

> The `FormAction` will only requests slots which haven’t already been set. If a user says “I’d like a vegetarian Chinese restaurant for 8 people”, they won’t be asked about the `cuisine` and `num_people` slots. [https://www.rasa.com/docs/core/slotfilling/#basics](https://www.rasa.com/docs/core/slotfilling/#basics)

Make sure, that your NLU is able to recognize “next week Monday” as time and “London” as location. Declare entities in your domain. If you got slots with the same name, they are automatically filled. Also take a look at this: [https://www.rasa.com/docs/core/slotfilling/#custom-slot-mappings](https://www.rasa.com/docs/core/slotfilling/#custom-slot-mappings)

---

<div class="post-metadata">

**Author:** ![argideritzalpea](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/argideritzalpea/32/7528_2.png) [@argideritzalpea](https://forum.rasa.com/u/argideritzalpea)\
**Post date:** [April 27, 2020, 5:41pm UTC](https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261/3 "2020-04-27T17:41:22Z")

</div>

@akelad @amn41So can the Rasa form can fill multiple slots from a single utterance if they are defined in slot mappings, even though there is a single “requested\_slot”? It seems that “requested\_slot” allows only that requested slot to be filled - or could multiple slots be filled if the mappings are defined?

I would like my form to be able to recognize a multi-intent and fill slots according to the actions of its constituent intents.

I noticed that if I receive a multi-intent like `intent_inform_vehicleCount+inform_countTime`, and the requested\_slot is “vehicleCount” which is mapped in the form as `{"vehicleCount": [self.from_entity(entity="number", intent="inform_vehicleCount")`, However, it is unclear how to also allow it to fill the `countTime` slot from `+inform_countTime` if this slot is not “requested” by the form. Is there any way to add a requested\_slot according to the incoming intent, so that a dual intent could fill two slots at once?

I would be really glad to help to try to implement this feature, but I’d really benefit from discussing the problem with someone to discuss the several places in the code that would require changes to fix this

---

<div class="post-metadata">

**Author:** ![akelad](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/akelad/32/69_2.png) [@akelad](https://forum.rasa.com/u/akelad)\
**Post date:** [April 29, 2020, 12:13pm UTC](https://forum.rasa.com/t/filling-multiple-slots-at-the-same-time-with-formaction-and-dynamic-buttons-in-template/6261/4 "2020-04-29T12:13:21Z")

</div>

Yes they can, as long as the entity has the same name as the slot. For your use case i wouldn’t use two intents for that, I would just use one and distinguish based on entities.
