The grammar element is used to specify grammars, either inline or referenced using the src attribute. At least one grammar (either inline or referenced) must be specified for speech recognition. Inline grammars must be text-based grammar formats, while referenced grammars can be text-based or binary type. Multiple grammar elements may be specified, in which case each grammar element is considered in a separate namespace for the purpose of grammar compilation. All the grammars of a listen element are treated as active unless (i) explicitly deactivated, or (ii) inactive by virtue of internal content.
To enable interoperability of SALT applications, SALT browsers must support the XML form of the W3C Recommendation for Speech Recognition Grammar Specification (SRGS), http://www.w3.org/TR/speech-grammar/. A SALT browser may support any other grammar formats. (Note: at the time of writing, the W3C SRGS specification is not yet a W3C Recommendation.) In order to guarantee complete interoperability of grammars, it is expected that W3C will eventually require the use of the W3C Semantic Interpretation (SI) specification with W3C grammars (http://www.w3.org/TR/semantic-interpretation/). Until this is the case, SALT platforms which implement semantic interpretation using W3C grammar formats should also support W3C SI.
| Name | Data type | Default |
|---|---|---|
nmtoken |
implied |
|
uri |
implied |
|
content.type |
"application/srgs+xml" |
|
uri |
implied |
|
CDATA |
implied |
any
none
none
|
<salt:listen id="recoOriginCity"> |
| <html xmlns:salt="http://www.saltforum.org/2002/SALT"> |
For details on usage of this element, see the SALT Specification, Version 1.0.