Menu

Using the browser's speech recognizer as a pronunciation judge
📰

Using the browser's speech recognizer as a pronunciation judge

DEV Community: javascript·WizMantra Academy·9 days ago
#bT85GrCU
#devtojavascript#devto#dev#test#listener
Reading 0:00
15s threshold

Pronunciation scoring APIs charge per request and want your audio on their servers. We teach spoken English to learners in India, mostly on phones, and we wanted a free test that costs us nothing to run.

So we let the browser's speech recognizer play the listener.

The idea: minimal pairs

Vest and west. Thin and tin. Ship and sheep. Each pair differs by one sound, and that's exactly the sound a lot of learners merge.

If you say "vest" and a speech model trained on thousands of speakers writes down "west", a human listener probably hears "west" too. That's the whole test.

Which pairs you get depends on your mother tongue, because the merges are predictable:

var L1 = { hindi : [ " vw " , " zj " , " tht " , " thd " , " ii " ], tamil : [ " pb " , " kg " , " fp " , " zj " , " thd " ], bengali : [ " bv " , " ssh " , " zj " , " fp " , " tht " ], // 14 languages in all };

Enter fullscreen mode

Exit fullscreen mode

A Hindi speaker gets V/W, Z/J, TH/T, TH/D and short I versus long EE.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.