Skip to content

Given text input of song names, it will create a playlist in Spotify based on those songs.

Notifications You must be signed in to change notification settings

ashmle/playlist

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

playlist

Given text input of song names, it will create a playlist in Spotify based on those songs. Depends on NTLK, JSON, and REQUESTS libraries.

The main method utilizes a greedy algorithm that matches ngrams (n = 5 max) to query the Spotify song titles corpora. Once matched, it proceeds to print out the matched song result. The matched ngram is taken out from the cleaned tokens, and the process is repeated recursively with a decreasing n. If no match is found, an error is printed out.

playlist.py is the file to be evaluated and can be run via command line.

playlist.ipynb was used as a scrapbook to refactor the code. Many different methods that were tried but didn't make it to the final playlist.py are included here.

About

Given text input of song names, it will create a playlist in Spotify based on those songs.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published