
Question:
I'm trying to develop an iOS app using speech-recognition for french language, but have been unsuccessful until now. I tried using the openEars framework, which worked great for english language, but doesn't support french. I used some info from this <a href="http://www.politepix.com/forums/topic/other-languages/" rel="nofollow">link</a>.
If anyone know a solution it would be awesome.
Thanks
Answer1:Openers is using <strong>English Acoustic and Language Models</strong> by default. So it works well with english, but doesn't support french.
You can download French Acoustic and Language Models from <a href="http://sourceforge.net/projects/cmusphinx/files/Acoustic%20and%20Language%20Models/" rel="nofollow">CMU Sphinx website</a>
Some good French Acoustic and Language Models are available <a href="http://sourceforge.net/projects/cmusphinx/files/Acoustic%20and%20Language%20Models/French%20Language%20Model/french3g62K.lm.dmp.bz2/download" rel="nofollow">here</a>
Download & Change your Openears Acoustic and Language Models with this one.
To do this, just replace Openears <strong>hub4wsj_sc_8k</strong> folder with the downloaded one and replace the .dic
and .languagemodel
files with the downloaded ones.
If you think , the downloaded French Acoustic and Language Models are too big, then create our own with few words using this <a href="http://cmusphinx.sourceforge.net/wiki/" rel="nofollow">documents</a>
Answer2:I ended up using this library <a href="https://github.com/todoroo/iPhone-Speech-To-Text" rel="nofollow">iPhone-Speech-To-Text</a> for my project.
It use the google voice api, sending a FLAC file of the speech and retrieving the appropriate text.
To make it work for french language, in SpeechToTextModule.m
I juste changed the URL
NSURL *url = [NSURL URLWithString:@"https://www.google.com/speech-api/v1/recognize?xjerr=1&client=chromium&lang=en-US"];
to
<blockquote>NSURL *url = [NSURL URLWithString:@"https://www.google.com/speech-api/v1/recognize?xjerr=1&client=chromium&lang=fr"];
The alternative I found is Dragon Speech SDK for Mobile. You simply need to <a href="http://dragonmobile.nuancemobiledeveloper.com/public/index.php?task=home" rel="nofollow">Register With Dragon Mobile</a> and download SDK and Samples.
It Supports English, French, German Speech Recognition. Also it is working very accurately than openEars. I have tested this for English and its working very well.
Here is screen for that sample which supports Recognition in mentioned language
<img alt="enter image description here" class="b-lazy" data-src="https://i.stack.imgur.com/bPZHH.png" data-original="https://i.stack.imgur.com/bPZHH.png" src="https://etrip.eimg.top/images/2019/05/07/timg.gif" />
<strong>Note</strong>
<a href="http://readwrite.com/2011/01/24/dragon-speech-sdk-arrives-for-android-ios" rel="nofollow">The SDK is free to download and use for 90 days, but...</a>