question

vandanapremkumar avatar image
vandanapremkumar asked

long number slot, what will be slot type ?

I'm using a thrid party api that has values with long number. If my slot is a long number example : "70150641234232418485". what will be the slot type ? Is there any issue with suck long number. I tried using AMAZON.NUMBER but it does not take long numbers.

Thanks, Vandana

alexa skills kitvoice-user interface
4 comments
10 |3000 characters needed characters left characters exceeded

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

any help on this will be appreciated ?

0 Likes 0 ·

Tried using literal

Tracking what is the status of {11111111111111111111|number}

Tracking what is the status of {22222222222222222222|number}

Tracking what is the status of {33333333333333333333|number}

Tracking what is the status of {44444444444444444444|number}

Tracking what is the status of {55555555555555555555|number}

Tracking what is the status of {66666666666666666666|number}

Tracking what is the status of {77777777777777777777|number}

Tracking what is the status of {88888888888888888888|number}

Tracking what is the status of {99999999999999999999|number}

got this error:

Error: There was a problem with your request: Incorrect syntax for the slot '{11111111111111111111|number}'. Each token must consist only of alphabets, white-spaces and valid punctuation marks. Valid punctuation marks are periods for abbreviations, possesive apostrophes and hyphens. Occurred in sample 'Tracking what is the status of {11111111111111111111|number}' on line 1.

0 Likes 0 ·

Rules for Sample Utterances

These rules also apply to any words specified inline in AMAZON.LITERAL slot values.

  • Numbers should be expressed as words and not digits (“five”, not “5”).

Reference: https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/alexa-skills-kit-interaction-model-reference

0 Likes 0 ·

1 Answer

Jamie Grossman avatar image
Jamie Grossman answered

Unfortunately, AMAZON.NUMBER doesn't support numbers with that many digits. You could try creating a custom slot type with the following values:

0 1 2 3 4 5 6 7 8 9 And then create multiple slots (with different names) that use that slot type. You could then create a sample utterance like:

Tracking what is the status of {SlotOne} {SlotTwo} {SlotThree} {SlotFour} {SlotFive} {SlotSix} {SlotSeven} {SlotEight} {SlotNine} {SlotTen} {SlotEleven} {SlotTwelve} {SlotThirteen} {SlotFourteen} {SlotFifteen} {SlotSixteen} {SlotSeventeen} {SlotEighteen} {SlotNineteen} {SlotTwenty} 
If the value can be a variety of lengths, then you will need to create several sample utterances that include as many slots as necessary. Unfortunately, longer utterances tend to lead to more mis-recognitions, so the above sample utterance may not be very accurate. Also, when using the LITERAL slot type, values should be written out. So instead of:
Tracking what is the status of {11111111111111111111|number} 
Use:

Tracking what is the status of {one one one one one one one one one one one one one one one one one one one one|number} 
If you wish to use LITERAL, you will need to provide as many sample utterances as possible since I assume that the value can be any combination of twenty digits.
10 |3000 characters needed characters left characters exceeded

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