Inspiration

I want to learn languages but find no motivation to do so unless it’s through immersion. On Instagram I saw a Minecraft mod that helps players do this exact thing, but I figured I could go bigger and support any program, not just Minecraft.

What it does

It’s a language learning app that prompts you to either describe the context of a game, or movie/show or to reply to your teammates in a live game chat in your target language (Ex: French, Russian, English, etc…). Pronouncing the sentence incorrectly after a number of attempts punishes you by doing things like pausing your movie, dropping your gun in game, making you spin around, etc…

How I built it

I built it using Python, the Gemini API and light-weight speech models to handle comparing your pronunciation.

Challenges I ran into

  • Latency with the Gemini API, I need the app to generate unique sentences in a target language as quick as possible, so I needed to fine-tune my prompt to be as performant as possible.
  • Race Conditions: Since the program is managing a thread for an overlay, a configuration window, and a worker, I encountered a lot of race conditions that were hard to manage, I had to really think about how I was accessing the data in the application.

Accomplishments that I'm proud of

  • Getting the pronunciation comparison logic working, I have never really worked with machine learning before so it was a real treat to do it for this project.

What I learned

  • How to create translations using an LLM.
  • Text to speech with Python.
  • Audio analysis (pronunciation checking)

What's next for Say it or lose it

  • To use a local model for improved latency when generating a sentence, but this will be optional as most users don’t have a computer to support a large parameter local llm.
  • To create more specific punishments for different games such as rocket league, csgo, etc..

Built With

Share this project:

Updates

Submission history