Microsoft Cognitive Speech - Text To Speech


Hello y'all,
I've created a C# project and I'm already able to do basically the same as the Bing Speech Recognition plugin does, but I also need to make my EZ-B (JD) "speaks" in another language. I've installed a Microsoft voice, but that's a pretty bad one, and the Azure platform offers two very nice voices to be used.

Right now I'm stuck with how I send the voice received from Azure to the EZ-B. Azure offers a variety of audio formats.

Has anyone tried this before? I've gone through some of the tutorials in the SDK but couldn't find one that does something like that.



HTML5 Speech Synthesis works pretty good and has a variety of voices to offer...


Thanks @Mickey666Maus, that sounds great. But my question is on how to send the audio received to the EZ-B. I guess I'd have the same problem there.



Check the UniversalBot code

Browsing the code you have information needed to send the sound data to EZB.

I've done that before, but i can't find the code.


This is related to the Microsoft Cognitive API, maybe DJ is working or will be working to support that feature too.

@DJ ?



The api you mentioned

javascript example code:


var speech = new SpeechSynthesisUtterance('Ola Brazil!');
speech.lang = 'pt-BR';

is only supported within the browser (not all) although chrome handles pretty well.

some complains:

even if you manage to launch the chrome engine (v8) like EZ-Builder does with blocky editor, you don't have a way to extract the voice sound.

Still a neat idea for the web...


@ptp the api works quiet well...and to me it is kind of a good work around to get different voices and languages going. But you are totally right, it is only working from within a browser, so I was kind of pointing to the wrong direction I guess!

This is a working example of a web based client! Which can also send data over to EZ-Builder, but cannot be called from within EZ-Builder!


To connect to the EZ-Builders server you would just have to make an XMLHttpRequest(); to call eg a ControlCommand() in EZ-Builder...

But the limitation is clearly that EZ-Builder cannot send data to the browser I guess?
At least I did not find a solution on this! Smile


I updated the plugin tutorial to include instructions on how to output audio:

I also created a plugin with complete example and source code: