How can I define Slot Priority for Slot Values in an Intent in LexV2

0

I am trying to build my Lex Bot but receiving this error message

Details Recommended action Slot ids [NumberTwo, Number] don't define a slot priority. Update the intent to add a priority to these slots. - Slot ids [Number] don't define a slot priority. Update the intent to add a priority to these slots. - Slot ids [Answer] don't define a slot priority. Update the intent to add a priority to these slots. - Slot ids [Number] don't define a slot priority. Update the intent to add a priority to these slots. -

I am using AWS SDK for Lex with Python to create the bot.

How can I update the intent to add slot priority for my slots?

Thanks

gefragt vor einem Jahr614 Aufrufe
2 Antworten
0
Akzeptierte Antwort

Hello The typical steps when creating bots via api are as follows

  1. Create bot
  2. Create bot version or use draft
  3. Create bot locale
  4. Create intents in the locale
  5. Create slots inside the intent
  6. Update the intent with the slot priority list - This is the step you are missing. Once you have the slot ids you should populate the slotPriorities list inside intent - https://docs.aws.amazon.com/lexv2/latest/APIReference/API_UpdateIntent.html#lexv2-UpdateIntent-request-slotPriorities
  7. Build the bot Let us know if this works for you.

Thanks!

AWS
Don
beantwortet vor einem Jahr
0

Thanks. Using this UpdateIntent operation was the solution.

The python AWS Lex v2 SDK method I used to add slot priorities to and Intent slot were:

  • create_intent
  • create_slot
  • update_intent
beantwortet vor einem Jahr

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen