stephenlb / spoken

Spoken - JavaScript Text-to-Speech and Speech-to-Text for AI Artificial Intelligence Apps
https://stephenlb.github.io/spoken/
70 stars 11 forks source link

no recognition languages support - bulgarian being one of them #7

Closed blurymind closed 4 years ago

blurymind commented 4 years ago

See https://codepen.io/velvasi/pen/qIEsr

blurymind commented 4 years ago

The problem is here: https://github.com/stephenlb/spoken/blob/master/src/spoken.js#L18

we should be able to specify any language, not just the default or en-US

blurymind commented 4 years ago

Still, this does not work at all: :(

spoken.recognition.language = "bg-BG";

      spoken.listen.on.partial(ts => ($(".tooltip").title = ts));
      spoken
        .listen()
        .then(transcript => {
          self.insertTextAtCursor(transcript);
          $(".tooltip").title = "";
        })
        .catch(error => console.warn(error.message));
blurymind commented 4 years ago

ah, my bad. It was spoken.recognition.lang = "bg-BG";

closing now