How in the world is that possible with 97 million+ songs in existence?
I believe their model only works for the top 50k songs in your region. Pretty rarely does my pixel not recognise music that is playing around me, that seems to be a large enough number
My Pixel is sat here charging. Billie Eilish is singing in the background, by the time she sings "I should have known..." it has recognised the music and passively displayed "No Time To Die by Billie Eilish" on the lock screen.
Google's team were building an ML model for music recognition and they realised oh - the smallest model fits on a phone. We don't need to spin this up as a cloud service we can just deliver it to the phones of people who want it as a feature. "Now your phone can tell you what that music is".
Of course down the road this awareness of context allows even cleverer agent interaction. "Which Bond was that?" you ask as Adele sings "Skyfall". "In the movie Skyfall, James Bond was played by Daniel Craig".