Speech Synthesis Markup Language (SSML) is based on XML to define the effects of synthetic speeches more accurately and specifically.
Note:
- Tencent TTS implements SSML based on Speech Synthesis Markup Language (SSML) Version 1.1.
- Currently, the SSML feature is supported only for Chinese.
The tagged text is uploaded to TTS as the value of the text
parameter. Below is the content of the request sent to TTS:
{
"Action" : "TextToVoice",
"AppId" : 12345,
"Codec" : "mp3",
"Expired" : 1603271036,
"ModelType" : 1,
"PrimaryLanguage" : 1,
"ProjectId" : 0,
"SampleRate" : 8000,
"SecretId" : "AKID****",
"SessionId" : "1234",
"Speed" : 0,
"Text" : "<speak>The mobile number is <say-as interpret-as=\"telephone\">4008110510</say-as>.</speak>",
"Timestamp" : 1603184636,
"VoiceType" : 1002,
"Volume" : 5
}
TTS supports SSML tags. Here, text in undefined <speak>
tags will not be synthesized, and an incorrect XML format may interrupt synthesizing the text in <speak>
tags.
The SSML feature of TTS supports nesting multiple <speak>
tags in the text; for example:
<speak>Her name is <say-as interpret-as="name">Ren Yingying</say-as>.
Her mobile number is <say-as interpret-as="telephone">+86-15188888888</say-as>.
She is <say-as interpret-as="cardinal">22</say-as> years old.
She has a package with the tracking number <say-as interpret-as="digits">5648234514237588</say-as>.
Her address is <say-as interpret-as="address">304, Unit 3, No. 10,000, Shennan Boulevard</say-as>.
</speak>By the way,<speak>
Her username is <say-as interpret-as="characters">b888_uαβγ</say-as>.
</speak>
The `<speak>` tag is the root node of all SSML tags to be supported but doesn't support attributes. All text for which to call SSML tags must be enclosed in `<speak></speak>`.
<speak>Text for which to call SSML tags</speak>
The <speak>
tag can contain text and the following tags: <break>
, <phoneme>
, <say-as>
, and <sub>
.
<speak>Text for which to call SSML tags.</speak>
Output speech audio: SSML-speak1.wav
This tag uses an alias to replace the text in it.
<sub alias="Alias">Text</sub>
Attribute | Type | Value | Required | Description |
---|---|---|---|---|
alias | String | New content | Yes | It is used to replace the text in the tag. |
This tag can contain text only.
<speak><sub alias="TTS">TTS</sub></speak>
Output speech audio: SSML-sub.wav
This optional tag is used to insert a pause in the text.
<break time="string"/>
Attribute | Type | Value | Required | Description |
---|---|---|---|---|
time | String | [number]s/[number]ms | Yes | You can set the pause duration in seconds or milliseconds, such as `2s` or `50ms`. [number]s: The unit is second, and the value of `[number]` must be an integer between 1 and 10. [number]ms: The unit is millisecond, and the value of `[number]` must be an integer between 50 and 10000. |
<break>
is an empty tag and cannot contain any tags.
<speak>Close your eyes and take a rest<break time="500ms"/>OK. Now open your eyes.</speak>
This optional tag is used to control the pronunciation of the text in it.
<phoneme alphabet="py" ph="Pinyin string">Text</phoneme>
Attribute | Type | Value | Required | Description |
---|---|---|---|---|
alphabet | String | py | Yes | `py` indicates pinyin. |
ph | String | Pinyin string of the text in the tag | Yes | Limits on the pinyin value: - Pinyin syllables of different characters need to be separated with spaces, and the number of pinyin syllables must be the same as the number of Chinese characters. - Each pinyin syllable consists of the pronunciation and tone. The tone is an integer between 1 and 5, where 5 indicates a neutral tone. |
The <phoneme>
tag can contain text only.
<speak>
Currently, the economic levels of different areas are <phoneme alphabet="py" ph="cen1 ci1 bu4 qi2">uneven</phoneme>. We need to bridge the <phoneme alphabet="py" ph="cha1 ju4">gap</phoneme> between the richer and poorer areas. However, the <phoneme alphabet="py" ph="chai1 shi4">job</phoneme> is not easy.
</speak>
Output speech audio: SSML-phoneme.wav
This tag is used to specify the information type of the text in it. The text will then be spoken in the default pronunciation method for the specified information type.
<say-as interpret-as="string">Text</say-as>
Attribute | Type | Value | Required | Description |
---|---|---|---|---|
interpret-as | String | cardinal/digits/telephone/name/address/ id/characters/punctuation/ date/time/currency/measure |
Yes | Information type of the text in the tag: • cardinal: Speak the text as an integral or decimal number. • digits: Speak the text as individual digits. • telephone: Speak the text in a common way of saying phone numbers. • name: Speak the text as a name. • address: Speak the text as an address. • id: Speak the text as an account name or nickname. • characters: Speak the text as individual characters. • punctuation: Speak the text as a punctuation mark. • date: Speak the text as a date. • time: Speak the text as a time. • currency: Speak the text as an amount of money. • measure: Speak the text as a number with a unit. |
Format | Example | Output | Description |
---|---|---|---|
Digit string | 1487 | One thousand four hundred and eighty-seven | Integral value range: [-18446744073709551615,18446744073709551615]. Decimal value range: The number of decimal places is unlimited but should be no more than 10 preferably. |
Minus sign + digit string | -1487 | Negative one thousand four hundred and eighty-seven | |
Digit string where every three digits are separated with a comma | 10,500 | Ten thousand five hundred | |
Minus sign + digit string where every three digits are separated with a comma | -10,500 | Negative ten thousand five hundred | |
Digit string + decimal point + two zeros | 9.00 | Nine | |
Minus sign + digit string + decimal point + two zeros | -110.00 | Negative one hundred and ten | |
Digit string + decimal point + digit string | 88.090 | Eighty-eight point zero nine | |
Minus sign + digit string + decimal point + digit string | -88.001 | Negative eighty-eight point zero nine |
Format | Example | Output | Description |
---|---|---|---|
Digit string | 356210985 | Three five six two one zero nine eight five | The length of the digit string is unlimited. We recommend you use no more than 20 digits and insert a pause after each digit if the string contains more than 10 digits. |
Format | Example | Output | Description |
---|---|---|---|
Landline number | 5605560 | Five six oh five five six oh | 7- and 8-digit landline numbers are supported. Different groups of digits can be separated with spaces or `-`. Here, a 7-digit landline number can be separated in the "3 digits-4 digits" format, and an 8-digit one can be separated in the "4 digits-4 digits" format. |
560 5560 | Five six oh five five six oh | ||
560-5560 | Five six oh five five six oh | ||
55605560 | Five five six oh five five six oh | ||
5560 5560 | Five five six oh five five six oh | ||
5560-5560 | Five five six oh five five six oh | ||
Landline number + extension | 55605560-105 | Five five six oh five five six oh extension one oh five | The extension can contain 1–4 digits. |
55605560 ext. 105 | Five five six oh five five six oh extension one oh five | ||
55605560 extension 105 | Five five six oh five five six oh extension one oh five | ||
55605560 extension 105 | Five five six oh five five six oh extension one oh five | ||
Area code + landline number | 01055605560 | Oh one oh five five six oh five five six oh | The following area codes are supported: 010, 02x, 03xx, 04xx, 05xx, 07xx, 08xx, and 09xx. |
010 55605560 | Oh one oh five five six oh five five six oh | ||
010-5560-5560 | Oh one oh five five six oh five five six oh | ||
(010)55605560 | Oh one oh five five six oh five five six oh | ||
031955605560 | Oh three one nine five five six oh five five six oh | ||
0319-55605560 | Oh three one nine five five six oh five five six oh | ||
Area code + landline number + extension | 010 33878528-1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | None |
010-33878528-1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | ||
(010)33878528-1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | ||
(010)33878528 ext. 1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | ||
(010)33878528 extension 1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | ||
(010)33878528 extension 1054 | Oh one oh three three eight seven eight five two eight extension one oh five four | ||
Country code + area code + landline number | 86-010-33878528 | Eight six oh one oh three three eight seven | Country codes in the following formats are supported: 86, (86), +86, (+86), and 0086, which are collectively spoken as "eight six". |
(86)10-33878528 | Eight six one oh three three eight seven eight five two eight | ||
+86-010-33878528 | Eight six oh one oh three three eight seven eight five two eight | ||
0086-10-33878528 | Eight six one oh three three eight seven eight five two eight | ||
(+86)-10-3387 8528 | Eight six one oh three three eight seven eight five two eight | ||
Country code + area code + landline number + extension | (86)21-33878528-1054 | Eight six two one three three eight seven eight five two eight extension one oh five four | None |
(86)021-3387-8528-1054 | Eight six oh two one three three eight seven eight five two eight extension one oh five four | ||
(86)021-33878528 ext. 1054 | Eight six oh two one three three eight seven eight five two eight extension one oh five four | ||
(86)21-3387-8528 extension 1054 | Eight six two one three three eight seven eight five two eight extension one oh five four | ||
+86-021-3387-8528 extension 1054 | Eight six oh two one three three eight seven eight five two eight extension one oh five four | ||
Mobile number | 151 8828 1075 | One five one eight eight two eight one oh seven five | 11-digit mobile numbers separated in "3-3-5" and "3-4-4" formats are supported. |
151-882-81075 | One five one eight eight two eight one oh seven five | ||
151-8828-1075 | One five one eight eight two eight one oh seven five | ||
Country code + mobile number | +86-15188281075 | Eight six one five one eight eight two eight one oh seven five | None |
(+86)-151-8828-1075 | Eight six one five one eight eight two eight one oh seven five | ||
+8615188281075 | Eight six one five one eight eight two eight one oh seven five | ||
0086-151 882 81075 | Eight six one five one eight eight two eight one oh seven five | ||
Service number | 110 | Oh oh one |
|
95566 | Nine five five six six | ||
4008110280 | Four oh oh eight one one oh two eight oh | ||
800-810-8888 | Eight oh oh eight one oh eight eight eight eight | ||
1253013520638377 | One two five three oh one three five two oh six three eight three seven seven | ||
Other | (86)(21)8832-80976-0907 | Eight six two one eight eight three two eight oh nine seven six oh nine oh seven | Digit strings separated with left and right parentheses or hyphens are supported. |
Format | Example | Output | Description |
---|---|---|---|
Common address format | 103-3, No. 1,000, Shennan Boulevard | One oh three dash three Number one oh oh oh Shennan Boulevard | Standard postal addresses in common formats are supported. |
No.1137-1128, Alley 377, Gaoxin Middle Avenue 4th Road | Number one one three seven dash one one two eight Alley three seven seven Gaoxin Middle Avenue Fourth Road | ||
3-1-3805, Phase 6, Huaruncheng | Number three dash one dash three eight oh five Phase six Huaruncheng | ||
Room 2106, Building 2, Dazu Yunfeng | Room two one oh six Building two Dazu Yunfeng | ||
No.19, Alley 151, Gaoxin Middle Avenue 3rd Road | Number one nine Alley one five one Gaoxin Middle Avenue Third Road |
Format | Example | Output | Description |
---|---|---|---|
String | dell3301 | D E L L three three oh one | It can contain letters, digits, and underscores. Spaces between two characters in the output result indicate a pause. Characters separated with spaces are spoken one by one. |
tencent_1998 | T E N C E N T underscore one nine nine eight | ||
AiDemo | A I D E M O |
Format | Example | Output | Description |
---|---|---|---|
String | ISO 1-001-095498-1 | I S O one dash oh oh one dash oh five four oh nine eight dash one | It can contain letters, digits, and certain full-width and half-width characters. Spaces between two characters in the output result indicate a pause. Characters separated with spaces are spoken one by one. If the text in the tag contains special XML symbols, they need to be escaped, commonly including: < > & " ' They represent `<`, `>`,`&`, `"`, and `'` respectively. |
x10u2385_u | X one zero U two three eight five underscore U | ||
v1.1.1 | V one dot one dot one | ||
Version 2.0 | Version two dot oh | ||
Yue B BA000 | Yue B B A oh oh oh | ||
Airbus A330 | Airbus A three three oh | ||
Models B01, B02, and B03 | Models B oh one B oh two and B oh three | ||
αβγ | Alpha beta gamma |
Format | Example | Output | Description |
---|---|---|---|
Punctuation mark | ... | Ellipsis | It supports common punctuation marks. Spaces between two characters in the output result indicate a pause. Characters separated with spaces are spoken one by one. If the text in the tag contains special XML symbols, they need to be escaped, commonly including: < > & " ' They represent `<`, `>`,`&`, `"`, and `'` respectively. |
…… | Ellipsis | ||
!"#$%& | Exclamation mark double quotation mark hash sign dollar percent sign and | ||
'()*+ | Single quotation mark left parenthesis right parenthesis asterisk plus sign | ||
,-./:; | Comma hyphen dot slash colon semicolon | ||
<=>?@ | Less-than sign equal sign greater-than sign question mark at | ||
[\]^_ | Left square bracket backslash right square bracket caret underscore |
Format | Example | Output | Description |
---|---|---|---|
xx year | 71 | Seventy-one | 2- and 4-digit years are supported.
|
08 | Oh eight | ||
20 | Twenty | ||
2020 | Twenty twenty | ||
1998 | Nineteen ninety-eight | ||
2008 | Two thousand and eight | ||
xx year xx month | 5/08 | May oh eight | For January to September, the input month number can start either with or without a "0", such as 4/1908 and 04/1908. |
04/2020 | April twenty twenty | ||
08/08 | August oh eight | ||
8/2020 | August twenty twenty | ||
xx year xx month xx day |
4/23/98 | April twenty-third ninety-eight | For the first to ninth day, the input day number can start either with or without a "0", such as "4/8/1908" and "04/08/1908". |
08/23/2020 | August twenty-third twenty twenty | ||
8/8/2020 | August eighth twenty | ||
08/08/2020 | August eighth twenty twenty | ||
xx month xx day | 8/20 | August twentieth | None |
08/08 | August eighth | ||
Numeric date (year and month) | 2020/08 | August twenty twenty | You can use "/", "-", or "_" to separate the numeric year, month, and day. |
2020-08 | August twenty twenty | ||
2020.08 | August twenty twenty | ||
Numeric date (year, month, and day) | 2020/08/09 | August ninth twenty twenty | |
2020-8-9 | August ninth twenty eighteen | ||
2020.08.09 | August ninth twenty eighteen | ||
xx year xx month xx day~xx year xx month xx day |
8/9~30/2020 | August ninth to thirtieth twenty | You can use "~" and "-" to indicate a span of time. |
08/09/2020-09/09/2020 | August ninth twenty twenty to September ninth twenty twenty | ||
xx month xx year~xx month xx year | 04/20~04/21 | April twenty to April twenty-one | |
04/2020~04/2021 | April twenty twenty to April twenty twenty-one | ||
xx month xx day~xx month xx day |
10/1~10/7 | October first to October seventh | |
10/01~10/07 | October first to October seventh | ||
xx month xx day~xx day |
10/1~7 | October first to seventh | |
10/01~07 | October first to seventh | ||
Numeric date (year, month, and day)~numeric date (year, month, and day) | 2020/03/03~2021/03/03 | March third twenty twenty to March third twenty twenty-one | You can use "/" or "." to separate the numeric year, month, and day and use "~" or "-" to indicate a span of time. |
2020.9.9~2021.9.9 | September ninth twenty twenty to September ninth twenty twenty-one | ||
Numeric date (month and day)~numeric date (month and day) | 10/20~10/31 | October twentieth to October thirty-first | |
xx~xx month or xx month~xx month | 1~10 | January to October | |
1~10 | January to October | ||
>Numeric date (month, day, and year) | 10/25/2020 | October twenty-fifth twenty twenty | Only 4-digit years in the "MM/DD/YYYY" format are supported, and only "/" can be used to separate the day, month, and year. |
Format | Example | Output | Description |
---|---|---|---|
Time | 12:00 | Twelve o'clock | Common time and time range formats are supported. |
12:00:00 | Twelve o'clock | ||
10:25 | Ten twenty-five | ||
10:25:30 | Ten twenty-five thirty | ||
09:25:14 | Nine twenty-five fourteen | ||
Time~time | 11:00~12:00 | Eleven to twelve o'clock | |
09:00-14:00 | Nine o'clock to fourteen | ||
11:00~11:30 | Eleven o'clock to eleven thirty | ||
11:00-15:18 | Eleven o'clock to fifteen eighteen | ||
10:30~11:00 | Ten thirty to eleven o'clock | ||
09:28-10:00 | Nine twenty-eight to ten o'clock | ||
10:20~11:20 | Ten twenty to eleven twenty | ||
06:00~08:00 | Six to eight o'clock | ||
10:20 am~1:30 pm | Ten twenty A M to one thirty P M | ||
Numeric time | 5:00am | Five o'clock in the early morning | If `am` is used, for 00:00–05:59, `am` is spoken as "in the early morning". If `am` is used, for 06:00–11:59, `am` is spoken as "in the morning". If `pm` is used, for 12:00–12:59, `pm` is spoken as "at noon". If `pm` is used, for 01:00–05:59, `pm` is spoken as "in the afternoon"; for 06:00–11:59, `pm` is spoken as "at night". |
5:30am | Five thirty in the early morning | ||
5:20:12am | Five thirty twelve in the early morning | ||
7:00am | Seven o'clock in the morning | ||
7:30AM | Seven thirty in the morning | ||
7:20:25a.m. | Seven twenty twenty-five in the morning | ||
07:08:12A.M. | Seven eight twelve in the morning | ||
5:00pm | Five o'clock in the afternoon | ||
5:30PM | Five thirty in the afternoon | ||
5:20:12p.m. | Five twenty twelve in the afternoon | ||
05:09:12P.M | Five nine twelve in the afternoon | ||
9:00pm | Nine o'clock at night | ||
9:30pm | Nine thirty at night | ||
9:20:12PM | Nine twenty twelve at night | ||
9:02:12P.M. | Nine two twelve at night | ||
12:00pm | Twelve o'clock at noon | ||
12:30p.m. | Twelve thirty at noon | ||
12:20:12PM | Twelve twenty twelve at noon |
Format | Example | Output | Description |
---|---|---|---|
Number + currency | 12.00USD | Twelve dollars | AUD (Australian dollar), CAD (Canadian dollar), HKD (Hong Kong dollar), JPY (Japanese yen), USD (US dollar), CHF (Swiss franc), NOK (Norwegian krone), SEK (Swedish krona), GBP (Pound sterling), RMB (Renminbi), CNY (Chinese yuan), and EUR (euro) are supported. The number can be an integer or decimal and can be separated by commas according to international standards. |
12.50USD | Twelve dollars and fifty cents | ||
15,000,000USD | Fifteen million dollars | ||
15,000,000.00USD | Fifteen million dollars | ||
12,000.35USD | Twelve thousand dollars and thirty-five cents | ||
Concurrency + number | $12 | Twelve dollars | $ (US dollar), fr (French franc), kr (Danish krone), £ (Pound sterling), ¥ (Chinese yuan), and € (Euro) are supported. The number can be an integer or decimal and can be separated by commas according to international standards. |
$12.00 | Twelve dollars | ||
$12.12 | Twelve dollars and twelve cents | ||
$12,000 | Twelve thousand dollars | ||
$12,000.00 | Twelve thousand dollars | ||
$12,000.99 | Twelve thousand dollars and ninety-nine cents | ||
Other default pronunciations | 1213 | One thousand two hundred and thirteen | None |
1213KML | One thousand two hundred and thirteen K M L | ||
1213.00KML | One thousand two hundred and thirteen K M L | ||
1213.9KML | One hundred and twenty-one point three nine K M L | ||
1,000KML | One thousand K M L | ||
1,000.00KML | One thousand K M L | ||
1,000.98KML | One thousand point nine eight K M L | ||
12,000 | Twelve thousand |
Format | Example | Output | Description |
---|---|---|---|
Number + Chinese unit | 2 sheets | Two sheets | Common Chinese units and unit abbreviations are supported. |
120 hectares | One hundred twenty hectares | ||
Over 100 milligrams | Over one hundred milligrams | ||
Over 100 meters | Over one hundred meters | ||
Over 100 people | Over one hundred people | ||
1 centimeter 20 millimeters | One centimeter twenty millimeters | ||
120.00 square kilometers | One hundred twenty square kilometers | ||
Number + unit abbreviation | 120.56cm² | One hundred and twenty point five six square centimeters | |
120m²56cm² | One hundred and twenty square meters fifty-six square centimeters | ||
100m12cm6mm | One hundred meters twelve centimeters six millimeters | ||
Range | 10~15kg | Ten to fifteen kilograms | |
10.24~789.82 mu | Ten point two four to seven hundred and eighty-nine point eight two mu | ||
10m~15m | Ten meters to fifteen meters | ||
10.24cm~19.08cm | Ten point two four centimeters to nineteen point zero eight centimeters | ||
Number + unit + "/" + unit | 10 dollars/kilogram | Ten dollars per kilogram | |
199~299 dollars/piece | One hundred and ninety-nine to two hundred and ninety-nine dollars per piece | ||
299.99 dollars/g~399.99 dollars/g | Two hundred and ninety-nine point nine nine dollars per gram to three hundred and ninety-nine point nine nine dollars per gram | ||
Other default pronunciations | 12 dozens | Twelve dozens | |
30rm | Thirty R M | ||
400 million fellow citizens | Four hundred million fellow citizens | ||
12.897 micrograms | Twelve point eight nine seven micrograms |
Special Symbol | Pronunciation |
---|---|
! | Exclamation mark |
" | Double quotation mark |
# | Hash sign |
$ | Dollar |
% | Percent sign |
& | and |
' | Single quotation mark |
( | Left parenthesis |
) | Right parenthesis |
* | Asterisk |
+ | Plus sign |
, | Comma |
- | Dash |
. | Dot |
/ | Slash |
: | Colon |
; | Semicolon |
< | Less-than sign |
= | Equal sign |
> | Greater-than sign |
? | Quotation mark |
@ | at |
[ | Left square bracket |
\ | Backslash |
] | Right square bracket |
^ | Caret |
_ | Underscore |
` | Backtick |
{ | Left curly bracket |
} | Right curly bracket |
~ | Tilde |
! | Exclamation mark |
“ | Left double quotation mark |
” | Right double quotation mark |
‘ | Left single quotation mark |
’ | Right single quotation mark |
( | Left parenthesis |
) | Right parenthesis |
, | Comma |
。 | Period |
— | Dash |
: | Colon |
; | Semicolon |
? | Quotation mark |
、 | Enumeration comma |
... | Ellipsis |
…… | Ellipsis |
《 | Left title mark |
》 | Right title mark |
¥ | Chinese yuan sign |
≥ | Greater-than-or-equal-to sign |
≤ | Less-than-or-equal-to sign |
≠ | Not-equal sign |
≈ | Approximately-equal-to sign |
± | Plus-minus sign |
× | Multiplication sign |
π | Pi |
Α | Alpha |
Β | Beta |
Γ | Gamma |
Δ | Delta |
Ε | Epsilon |
Ζ | Zeta |
Ε | Eta |
Θ | Theta |
Ι | Iota |
Κ | Kappa |
∧ | Lambda |
Μ | Mu |
Ν | Nu |
Ξ | Xi |
Ο | Omicron |
∏ | Pi |
Ρ | Rho |
∑ | Sigma |
Τ | Tau |
Υ | Upsilon |
Φ | Phi |
Χ | Chi |
Ψ | Psi |
Ω | Omega |
α | Alpha |
β | Beta |
γ | Gamma |
δ | Delta |
ε | Epsilon |
ζ | Zeta |
η | Eta |
θ | Theta |
ι | Iota |
κ | Kappa |
λ | Lambda |
μ | Mu |
ν | Nu |
ξ | Xi |
ο | Omicron |
π | Pi |
ρ | Rho |
σ | Sigma |
τ | Tau |
υ | Upsilon |
φ | Phi |
χ | Chi |
ψ | Psi |
ω | Omega |
Format | Type | Example |
---|---|---|
Abbreviation | Length | nm (nanometer), μm (micrometer), mm (millimeter), cm (centimeter), m (meter), km (kilometer), ft (foot), in (inch) |
Area | cm² (square centimeter), m² (square meter), km² (square kilometer), SqFt (square foot) | |
Volume | cm³ (cubic centimeter), m³ (cubic meter), km³ (cubic kilometer), mL (milliliter), L (liter), gal (gallon) | |
Mass | μg (microgram), mg (milligram), g (gram), kg (kilogram) | |
Time | min (minute), sec (second), ms (millisecond) | |
Electromagnetism | μA (microampere), mA (milliampere), Ω (ohm), Hz (hertz), KHz (kilohertz), MHz (megahertz), GHz (gigahertz), V (volt), kV (kilovolt), kWh (kilowatt-hour) | |
Sound | dB (decibel) | |
Atmospheric pressure | Pa (pascal), kPa (kilopascal), Mpa (megapascal) | |
Chinese unit | This type includes without limitation the Chinese units of the aforementioned units, such as "meter", "second", "dollar", and "milliliter per bottle". |
The <say-as>
tag can contain text only.
<speak>
<say-as interpret-as="cardinal">12345</say-as>
</speak>
Output speech audio: say-as-cardinal.wav
<speak>
<say-as interpret-as="digits">12345</say-as>
</speak>
Output speech audio: say-as-digits.wav
<speak>
<say-as interpret-as="telephone">12345</say-as>
</speak>
Output speech audio: say-as-telephone.wav
<speak>
Her former name is <say-as interpret-as="name">Zeng Xiaofan</say-as>.
</speak>
Output speech audio: say-as-name.wav
<speak>
<say-as interpret-as="address">304, Unit 3, Building 1, No. 10,000, Shennan Boulevard</say-as>
</speak>
Output speech audio: say-as-address.wav
<speak>
My username is <say-as interpret-as="id">tencent_8858</say-as>
</speak>
Output speech audio: say-as-id.wav
<speak>
Greek letters <say-as interpret-as="characters">αβ</say-as>
</speak>
Output speech audio: say-as-characters.wav
<speak>
The punctuation mark that I use the most frequently is <say-as interpret-as="punctuation">,</say-as>
</speak>
Output speech audio: say-as-punctuation.wav
<speak>
<say-as interpret-as="date">2020-10-10</say-as>
</speak>
Output speech audio: say-as-date.wav
<speak>
<say-as interpret-as="time">5:30am</say-as>
</speak>
Output speech audio: SSML-say-as_time.mp3
<speak>
<say-as interpret-as="currency">15,000.00RMB</say-as>
</speak>
Output speech audio: say-as-currency.wav
<speak>
<say-as interpret-as="measure">100m²15cm²</say-as>
</speak>
Output speech audio: say-as-measure.wav
Was this page helpful?