- Summary
- Technologies/Project Prerequisites
- Demo
- Status
- Reflection
- References & Inspiration
This project, "INFINI∞TRACKS," is the final project for the University of Chicago's MPCS 57200: Generative AI Course for the Winter 2024 Quarter. The project leverages a LangChain ReAct agent to facilitate communication between the myself and the Spotify Web API to create personalized playlists based on my top songs, top artists, or a surprise random genre.
To run the application locally, ensure you have the following:
OPENAI_API_KEY: API key for OpenAI integration. SPOTIFY_CLIENT: Spotify Client ID for authentication. SPOTIFY_SECRET: Spotify Secret key for authentication.
- Sign up for the Spotify Web API and OpenAI to receive api keys
- Create a
.env
file and insert the api keys above - Install the requirements with
pip install -r requirements.txt
- Run the project within the directory that
app.py
is in usingstreamlit run app.py
The project is finished.
During development, several challenges were encountered, particularly due to the complexities and limitations associated with the development mode of apps in the Spotify Web API (e.g to have an app inm Extended Quota Mode for multiple user's to utilize it, Spotify Web API data cannot be used to train AI models, and more). Thus, the Spotify API restrictions prevented my original plan of integrating ChatGPT for personalized recommendations.
During the development of INFINI∞TRACKS, I gained valuable insights into integrating AI tools into Streamlit applications and learned extensively about working with the Spotify Web API. The project provided me with hands-on experience in creating personalized Spotify experience by allowing me to "speak" directly to my Spotify data with the ReAct agent through custom tools that my ReAct agent dynamically chose based on prompts within INFINI∞TRACKS.
Exploring the intersection of LangChain, Streamlit, and the Spotify Web API's recommendation AI was both challenging and rewarding. Despite the twists and turns, this project was a fascinating exploration of the uses of AI tools within LangChain and Spotify. I hope to continue developing this project well after the Generative AI course as additional functionality and tools using LangChain and Streamlit are created.
- Build your own playlist generator with Spotify’s API 🎧 (in Python!) by rob_med
- Spotify’s Authorization Code Flow For Dummies by ChrisOh431
- Make your Streamlit App Look Better by Yash Chuanhan
- LangChain: Creating an AI Agent utilizing the Spotify API Part I & II by Astropromeai
- Spotify GPT AGent by trancethehuman