-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How is a complete SSML document expected to be parsed when set once at .text property of SpeechSynthesisUtterance instance? #10
Comments
If nobody implements the SSML bits, maybe it should just be removed from the spec, rather than trying to clarify this? @andrenatal @gshires, WDYT? |
@foolip Not sure what you mean by
? SSML parsing is definitely utilized by *mazon *lexa and *olly, *BM *luemix, *oogle *ctions as a web service (for a fee or with an EUL agreement). We should be able to implement the specification without using an external web service or licensing agreement. |
@foolip There is an available patch to implement SSML parsing at Chromium by way of |
@foolip The portion of the Web Speech API specification that is difficult to navigate is trying to determine if SSML parsing is supported at the specific platform, see https://bugs.chromium.org/p/chromium/issues/detail?id=88072#c48. We know that neither Chromium nor Firefox has actually set the SSML parsing flag to "on" when initializing SSIP communication with
though the capability is available to do so. This addresses whether the string or |
So, does any browser engine (Chrome, EdgeHTML, Gecko or WebKit) try to parse the |
@foolip Have not tried Edge or Webkit, which both utilize different approaches than Chromium and Firefox. Edge has SAPI, MacOS does not parse SSML at all, though has their own form of markup. For Chromium and Firefox the bridge is The issue is that neither Chromium nor Firefox implementations actually pass the appropriate flags to the SSIP socket to turn on SSML parsing for the speech synthesizer module. |
@foolip The below code should meet the requirement of the specification using JavaScript
|
@guest271314 so this wasn't implemented yet? I'm trying to set an attribute on utterance that tells it that the input is ssml: https://stackoverflow.com/questions/49724626/google-speech-api-or-web-speech-api-support-for-ssml |
@dtturcotte SSML parsing is not implemented at Chromium by default, see https://bugs.chromium.org/p/chromium/issues/detail?id=88072, https://bugs.chromium.org/p/chromium/issues/detail?id=806592. This is a beginning of an implementation client side using JavaScript https://github.com/guest271314/SpeechSynthesisSSMLParser. It is also possible to use Native Messaging https://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extensions/docs/examples/api/nativeMessaging/host/ at Chromium/Chrome to communicate with |
I added a test for SSML in web-platform-tests/wpt#12568 to see if it's supported anywhere. |
This looks to me like a chicken-and-egg issue. If nothing in the spec says whether .text is ssml or not, I don't see how implementations would dare telling the synth that it's ssml when it's not even sure whether it is or not. The backends are ready: espeak-ng supports it, speech-dispatcher supports it, it's a one-line change in speech-dispatcher-based browser backends to support it. But if the API does not tell when it should be enabled, we can not dare enabling it. |
According to the specification
It is not clear how an entire SSML document is expected to be parsed when set at
.text
property at single instance ofSpeechSynthesisUtterance()
.See guest271314/SSMLParser#1
The text was updated successfully, but these errors were encountered: