question

Miguel Mota avatar image
Miguel Mota asked

Slot utterances cap at 4096 lines but I have over 200K lines I need to save

I have over 200k possible sequences of colors for a skill I'm building. For example, I the user will say things like "BLUE RED ORANGE GREEN GREEN YELLOW...", where the list can be an arbitrary length (max 10 colors). The colors are predetermined. Since there is no way to have a wildcard slot, I've generated all the sequences and tried pasting them in the Alexa Skill Kit portal as a custom slot type but it caps at 4,096 lines. What do I do? Message was edited by: Miguel Mota Message was edited by: Miguel Mota
alexa skills kitvoice-user interface
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Steve A avatar image
Steve A answered
Custom slots are not constrained to just the values explicitly listed in the slot. So, it should pick up on color combinations that you haven't explicitly listed. List as many as you want. I'm not sure if you'll get any benefit with 4096 over 2000.... Steve
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Galactoise avatar image
Galactoise answered
You can solve this by changing your design a bit. Instead of describing this combinatorially, the best approach is to define each possible individual color as part of the slot, and then use multiple instances of that slot. For example, for four colors (with a max length of 4): SLOTS - {"COLORS":["RED","BLUE","GREEN","PURPLE"]} INTENTS- [ {"intentName":"OneColor","slots":[{"name":"slotOne","type":"COLORS"}]}, {"intentName":"OneColor","slots":[{"name":"slotOne","type":"COLORS"},{"name":"slotTwo","type":"COLORS"}]}, {"intentName":"OneColor","slots":[{"name":"slotOne","type":"COLORS"},{"name":"slotTwo","type":"COLORS"},{"name":"slotThree","type":"COLORS"}]}, {"intentName":"OneColor","slots":[{"name":"slotOne","type":"COLORS"},{"name":"slotTwo","type":"COLORS"},{"name":"slotThree","type":"COLORS"},{"name":"slotFour","type":"COLORS"}]} ] UTTERANCES- My color code is {slotOne} My color code is {slotOne} {slotTwo} My color code is {slotOne} {slotTwo} {slotThree} My color code is {slotOne} {slotTwo} {slotThree} {slotFour} And then expand that out to 10 possible utterances and intents.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

jjaquinta avatar image
jjaquinta answered
I strongly advise you to reconsider your design. Having more than two slots in a single intent is problematic. Especially if there is no separating text between them. It is going to be very hard to get any sort of quality input if you take the approach you have outlined. Secondly, utterance examples seem to peak around 20. You can add more, and it helps, but the returns decrease. I.e. each additional example you add improves things less and less. Remember: Alexa just kind of averages them together. It isn't a definitive list. (Using custom slots doesn't change this either.) So the more you have, the more generic you get, and Alexa will end up matching just about anything.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Miguel Mota avatar image
Miguel Mota answered
Ah, that might actually work. I'll give it a try. Thanks!
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Miguel Mota avatar image
Miguel Mota answered
Is there anyway to constrain the slot values to a specified list? If not then I'm assuming I'll need to match the values against a list of allowed words.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Miguel Mota avatar image
Miguel Mota answered
So generally speaking, there is no good way to read in a specific list of words spoken by the user?
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

jjaquinta avatar image
jjaquinta answered
>Is there anyway to constrain the slot values to a specified list? Nope. >If not then I'm assuming I'll need to match the values against a list of allowed words. Yep. But that still won't get you where you want to be. Since Alexa will reply with words that are close to the words on your list. You will want to also do a fuzzy match against words on your list. Search for the forum for DoubleMetaphone. Several of us have had reasonable success with that. But it depends on your exact problem set. >So generally speaking, there is no good way to read in a specific list of words spoken by the user? There is not.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.