<say-as>

New in VoiceXML 2.0. Speech Synthesis Markup Language element that modifies how the enclosed word or phrase is spoken.

Syntax
<say-as
      bevocal:mode="mode"
      type="typeName"|"typeName:format"
      interpret-as="typeName"|"typeName:format"
      format="string" Not implemented
      detail="string" Not Implemented
   Text
</say-as>


Description

Attribute Description
bevocal:mode

Extension; When value recorded, the output will be recorded audio. If no recorded audio is available, then TTS will be used to play out the content. Optional.

Note: Recorded prompts are not available for Spanish or French Canadian.

type

Speak enclosed text in the given style. The type attribute takes quite a few values that are listed below.

interpret-as

Same as type.

format

Not implemented.

detail

Not implemented.

sub

Deprecated; Use the <sub> element instead. This attribute was supported in an earlier release; if you use it, the interpreter throws a parse error.

The following events may be thrown during the execution of a <say-as> element:

 •  error.badfetch - In VoiceXML 1.0; the <say-as> tag is a version 2.0 element.
 •  error.badfetch - When this element contains a class attribute. The class attribute is not valid in version 2.0
 •  error.semantic - When the type attribute contains a value which is not one of those allowed in the enumerated list of values above. Note that some values have changed between version 1.0 and 2.0. For example type="phone" (from 1.0) would cause this error to be thrown.

Usage

The type attribute takes quite a few values. Some <say-as> types require a format. For others, it is optional. The values break down into 3 categories--corresponding to a built-in grammar, other standard SSML <say-as> types, and extended <say-as> types available with the BeVocal interpreter.

The sole type value that corresponds to a built-in grammar is:
Type Description
vxml

Contained text is a field's input variable. The allowed formats correspond exactly to the available built-in grammars: boolean, currency, date, digits, number, phone, and time. The format is required.

The other standard <say-as> types and their formats are:

Type

Description

acronym

Contained text is an acronym. For example, <say-as type="acronym">IBM</say-as> is spoken as "eye bee em".

spell-out

Characters in the contained text string are spoken as individual characters. For example, <say-as type="spell-out">smith</say-as> is spoken as "ess em eye tea aitch".

number

Contained text can be interpreted as a number. The allowed number formats are ordinal, cardinal, and digits. For example, <say-as type="number:ordinal">12</say-as> is spoken as "twelfth", but <say-as type="number:digits">12</say-as> is spoken as "one two".

date

Contained text is a date. The allowed date formats indicate the form of the input and are dmy, mdy, ymd, ym, my, md, y, m, and d. For example, <say-as type="date:my">12/2003</say-as> is spoken as "December, two thousand and three".

time

Contained text is a time of day. The allowed time formats indicate the form of the input and are hms, hm, and h. For example, <say-as type="time:h">3</say-as> is spoken as "3 o'clock".

duration

Contained text is a temporal duration. The allowed duration formats indicate the form of the input and are hms, hm, ms, h, m, and s. For example, <say-as type="duration:h">3</say-as> is spoken as "3 hours".

currency

Contained text is a currency amount. For example, <say-as type="currency">$3</say-as> is spoken as "3 dollars".

measure

Contained text is a measurement. For example, <say-as type="measure">3ft</say-as> is spoken as "3 feet".

telephone

Contained text is a telephone number. For example, <say-as type="telephone">5555555555</say-as> is spoken as "five five five <pause> five five five <pause> five five <pause> five five".

name

Contained text is a proper name of a person, company and so on.

net

Contained text is an internet identifier. The allowed net formats indicate the form of the input and are email and uri. For example, <say-as type="net:email">you@company.com</say-as> is spoken as "you at company dot com".

Extensions. The extended <say-as> types are:
Type Description
airport

Contained text is an airport code, such as DFW. For a list of the allowed airport codes, see Airport & Airline Codes on the Resources page of the BeVocal Café web site.

airline

Contained text is an airline codes, such as AA. For a list of the allowed airport codes, see Airport & Airline Codes.

equity

Contained text is a company symbol, such as ibm or csco

street

Contained text is a street name (with or without street number), such as bordeaux drive or 1380 bordeaux drive

city

Contained text is a city name, such as sunnyvale

state

Contained text is a state name, such as california or ca

citystate

Contained text is a city name and state name separated by a comma, such as sunnyvale, california

address

Contained text is a street, city, state, and zip code separated by commas, such as 1380 bordeaux drive, sunnyvale, california, 94089

Parents Children
<audio>
<bevocal:whisper>
<choice>
<emphasis>
<enumerate>
<p>
<paragraph>
<prompt>
<prosody>
<s>
<sentence>
<voice>
<value>

See Also

 •  SSML 1.0 Specification: <say-as>
 •  Related tags: <break>, <emphasis>, <mark>, <paragraph>, <phoneme>, <prosody>, <sentence>, <sub>, <voice>

Examples

To hear an example of each supported type, see the Say-As Types example in the VoiceXML Samples section of the BeVocal Café.


[Show Frames]   [FIRST] [PREVIOUS] [NEXT]
BeVocal, Inc. Café Home | Developer Agreement | Privacy Policy | Site Map | Terms & Conditions
Part No. 520-0001-02 | © 1999-2007, BeVocal, Inc. All rights reserved | 1.877.33.VOCAL