DEV Community

Cover image for Fun Flashcards Game for Kids using AI Speech Recognition
Daniel Chifamba
Daniel Chifamba

Posted on

4 4 2 2 3

Fun Flashcards Game for Kids using AI Speech Recognition

This is a submission for the AssemblyAI Challenge : Really Rad Real-Time.

What I Built

I made a fun math game for kids with math flashcards. Kids answer by speaking, and the game uses AI Powered Speech Recognition to check their answers.

It has three levels of difficulty and a setting to turn sound effects on or off.

Demo

Live: https://mathwave.vercel.app

screenshot 1 screenshot 2 screenshot 3
Image description Image description Image description

Journey

I had fun hacking this one out. Initially setup most of the game using the native browser Speech Recognition API. That was an eye opener as I noted:

  • The recognition was rather poor. I assumed it was my voice so I had other people try it out. They too, seemed to end up frustrated as it was failing to recognize the right answer.
  • A lot of code and handling of edge cases was required
  • Results are not consistent across browsers. (ahem...Safari ๐Ÿ˜…)

Then came AssemblyAI to the rescue ๐Ÿ›Ÿ ๐ŸŒŠ
The (HUGE) difference:

  • Very easy to setup, very few lines of code
  • Consistent experience across browser
  • Awesome speech recognition from kid's voices to adult voices, even where it was a bit noisy ๐Ÿ”ฅ

Oh...and the Docs and Cookbook were on point ๐Ÿ™‚ I found a perfect example pretty close to what I wanted to do here

I simply followed this example to come up with the code that transcribes the answers by voice

The rest of the Source Code can be found here:

Price categories

  • Really Rad Real-Time

API Trace View

How I Cut 22.3 Seconds Off an API Call with Sentry ๐Ÿ‘€

Struggling with slow API calls? Dan Mindru walks through how he used Sentry's new Trace View feature to shave off 22.3 seconds from an API call.

Get a practical walkthrough of how to identify bottlenecks, split tasks into multiple parallel tasks, identify slow AI model calls, and more.

Read more โ†’

Top comments (2)

Collapse
 
mtwn105 profile image
Amit Wani โ€ข

It looks cool

Collapse
 
dchif profile image
Daniel Chifamba โ€ข

Thank you @mtwn105 ๐Ÿ™‚

Postmark Image

Speedy emails, satisfied customers

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up