Skip to content

Six Degrees of Spotify is a web app that will find the shortest path between 2 popular artists using data from Spotify's "fans also listen to" feature and BFS

License

Notifications You must be signed in to change notification settings

RyanMcPherson7/six-degrees-of-spotify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Six Degrees of Spotify

A web app to find the shortest path between 2 popular Spotify artists using data collected from Spotify's "fans also listen to" feature and a breadth first search algorithm. You can view the live version here

app main view

🔮 How it Works

  1. Six Degrees of Spotify consists of both a React /client and a Node.js /server
  2. Users interact with the UI to send requests to the server to compute their requested artist path
  3. Upon request, the server will generate an unweighted, bidirectional graph with 19,215 vertices (artists) and 205,907 edges (connections) from a flat-file
  4. The data inside the flat-file was generated on 9/22/24 with a popularity minimum of 50 using code from /server/data-scrapping and the GET /v1/artists/{id}/related-artists endpoint from the Spotify Web API
  5. After building the graph, breadth first search is run to find the shortest path (smallest degree) between the 2 input artists
  6. Finally, the server sends the computed path to the client to be displayed

🚀 Running Locally

Prereqs

  1. Install Node.js here
  2. Clone the repo with
git clone https://github.com/RyanMcPherson7/six-degrees-of-spotify.git

Setting up the client

  1. Open a new terminal session inside /six-degrees-of-spotify
  2. Access the client directory with cd client
  3. Install dependencies with npm ci
  4. Start the client with npm run start

Setting up the server

  1. Open a new terminal session inside /six-degrees-of-spotify
  2. Access the server directory with cd server
  3. Install dependnecies with npm ci
  4. Start the server with npm run start

Viewing the app

  1. You should see the app running on localhost:3000
  2. 🎉 Congrats! The app is up and running!

🐳 Running Locally With Docker

Prereqs

  1. Install and run docker here
  2. Clone the repo with
git clone https://github.com/RyanMcPherson7/six-degrees-of-spotify.git

Building and Running the App

  1. Open a new terminal session inside /six-degrees-of-spotify
  2. Build the image with docker build . -t sixdos
  3. Start the container with docker run -p 3000:5000 sixdos

Viewing the App

  1. You should see the app running on localhost:3000
  2. 🎉 Congrats! The app is up and running!

About

Six Degrees of Spotify is a web app that will find the shortest path between 2 popular artists using data from Spotify's "fans also listen to" feature and BFS

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published