
At the time of writing this post, Spotify has categorized 5987 distinct genres of music.
A number that has almost certainly increased by the time you’re reading this now, unless you can name all nearly 6 000 of them.
There’s a pretty good chance you’re a fan of a genre you haven’t even heard of. Perhaps you enjoy gothabili, neurostep or blackened death core. You could be a listener of baps, Bebop or Funk. But the fact of the matter is that you don’t really need to know exactly what kind of music you like, because Spotify already has you all figured out.
Every week for every user, they’re able to tailor a 30 song playlist to that person’s exact music tastes, ranging from the world’s most popular artists to the most Niche Indie Productions on the platform.

But have you ever wondered how?
I mean you probably have because that’s why you clicked on this post.
So here’s how Spotify’s recommendation system is composed of three different algorithms which makes it three times better than one algorithm because of math.
Collaborative Filtering
The first of these three actually has nothing to do with the music itself and it’s called collaborative filtering. This is basically the way that Netflix recommends new shows by writing a 6000 word end user license agreement that gives them permission to record everything you do until you die or throw your phone into a volcano.
Located in Spotify’s giant Matrix room they’ve stored a giant matrix. It’s roughly 433 million rows by 80 million columns indexing every single user and every single song on the platform and recording how often each person listens to each song. This is simplifying things a bit but this Matrix allows them to objectively determine which users are most similar.

If one row is hitting all the same columns as another row that means those two people are listening to the same songs. And if one of those rows has an active column that the other doesn’t have, then that song would theoretically be good to recommend.
Basically what I’m saying is if you want to ruin a specific person’s Spotify, all you have to do is make a new account, listen to all their favorite songs and then listen to tornado siren sound effects by Royalty-free music and sound effect factories seventy thousand times
Now Spotify can’t rely entirely on collaborative filtering. It’s not very accurate especially when it comes to people’s multi-faceted music tastes and it tends to just promote generally popular music while burning things that don’t have a ton of listening data to work with, like the same from wendover’s old-time Jamboree band even if their music is hot fire.
Natural Language Processing System
That’s where the next algorithm comes in, Spotify’s natural language processing system.
You see, one of the best ways to categorize songs is with words and it turns out that the internet has a whole bunch of them.
Spotify is constantly gathering text associated with his songs. It’ll look at text on its own platform, like song titles, playlist descriptions and lyrics but it’ll also pull data from the rest of the internet.
Spotify scrape song reviews, news articles, comment sections, you name it and all this goes into building an associated word bank for each song and artist on its platform.
Here’s one such table generated by Echo Nest the music data company that Spotify purchased in 2014 for the phrase Abba.
As you can see it has the noun phrases most commonly associated with Abba as well as the adjectives most commonly used when describing Abba.

Using this table you can into it that ABBA fans will probably like other things that are frequently described with perky non-violent and Swedish such as Greta tunberg or IKEA stuffed shark that has its own subreddit for some reason.
But at this point you’ve probably noticed something weird. All of this data that a Spotify is using, the adjectives, the song titles, the listening frequencies, none of these is gathered from the music itself.
So that raises the question. Can Spotify actually listen to its own music? And the answer interestingly is yes.
This is where our third algorithm comes in.
Spotify Sonic profiles
Here’s how they work:
For each song of the platform, Spotify generates something called a Time frequency representation which looks something like this.

This axis is time this accesses frequency and warmer colors mean louder decibel levels. So for example at exactly 12 seconds into this song, these are the frequencies that are most present.
This representation is then dumped into a neural network. The neural network isolates all of the major features of the song, stuff like it’s Ki, Tempo, Timber, loudness and time signature and compares these qualities individually against other songs you like and other songs you haven’t heard.
Then in tandem with the collaborative filtering system and natural language processing algorithm, these Sonic profiles are used to precisely hone in on songs that are acoustically similar enough to the kind of music you already listen to while also experimenting with one or two variables to avoid presenting you with anything too stale.
And there you go, that’s how to spend 11 billion dollars a year convincing people to not just listen to the same three Taylor Swift songs on read peed for the rest of their life.
Now there are a wide variety of websites for viewing Spotify stats on the Internet and the famous Spotify Wrapped is also based on the data collected by these systems.











-副本.png)
Leave a Reply