I'm not a good singer, but I like singing anyway. Singing apps were helping me get slightly less bad, but because of licensing they teach from their own catalogues, often re-recordings. I'd open a song expecting the original and get a cover I didn't want to sing to.
So I built OnKey, a free, open-source (MIT) Mac app. You play a song in Spotify, Apple Music, or YouTube in a browser, and sing along. The first time, you get the lyrics while OnKey listens. When the song ends, it learns the singer's melody on your Mac. From the second play, the notes scroll towards you, your pitch is drawn over them, and you get a score with a report on every line.
Listening to another app
I didn't know this was possible until I started. macOS 14.2 added process taps, which let an app hear one other app's sound, with your permission. OnKey taps the music app and the mic on the same clock, so there are no audio files to hunt for. It never saves the music either. It analyses the sound in memory as it plays.
Learning a song in a couple of minutes
When a song's first play ends, four models run locally:
- UVR's MDX-Net Karaoke model pulls out the lead vocal
- CREPE tracks the singer's pitch
- OpenVPI's GAME model turns that into one note per syllable
- wav2vec 2.0 lines up the lyrics (from LRCLIB) with the singing
Spotify doesn't always know where it is
I assumed the music app would tell me the playback position and that would be that. Spotify's reported position can be 1.5 seconds out, which is a lot when you're trying to hit a note on time. So on later plays OnKey finds its place from a fingerprint of the music itself, and CREPE "tiny" follows your voice live, a few milliseconds behind. Over speakers, an echo canceller takes the song back out of the mic.
Does the score mean anything?
I ran 20 recordings of singers, from poor to professional, that experts had already rated. OnKey's "notes hit" agreed with them at ρ 0.77 (the experts agree with each other at 0.88). It's a small set, so I treat it as a good sign rather than proof. Scoring is forgiving on purpose: within half a semitone of the singer earns full credit, an octave up or down counts, and your timing gets 80 ms of slack.
How it was made
I'd never written Rust or built a Tauri app before this. Claude Code did most of the typing, while I designed it, tested it on my own singing every day, and built the evaluation sets it's measured against. Since launching in October it's picked up 442 stars on GitHub and been translated into 19 languages, and this week it got a Tuner for practising single notes.
Where it isn't great yet
Busy mixes and harmonies can confuse which voice is the tune, and now and then a note comes out an octave off. It only scores pitch, so rap doesn't suit it. And it's Apple Silicon and macOS 14.2+ only for now (Windows can tap one app's sound too, so a port is possible, but I haven't started one).
If you sing in the shower and own a Mac, give it a go: singonkey.app. The code is at github.com/dsmurrell/onkey. Let me know where it scores you unfairly or the notes go wrong, here or in OnKey's Discord, and I'm happy to answer questions about how it hears the music.



