π Chat with Your YouTube Video using LLMs π€
π Built an AI-powered app that lets you chat with YouTube videos using LLMs!
I recently developed ChatAudio, a project that allows users to interact with YouTube video content in a conversational way β powered by LangChain, OpenAI, and Streamlit.
π― Goal
Enable users to extract transcripts from YouTube videos and ask any question about the content β just like chatting with the video!
π Workflow Overview
1οΈβ£ User inputs a YouTube video URL
2οΈβ£ App fetches subtitles using YouTubeTranscriptAPI
β If subtitles are missing, you can optionally use AssemblyAI for speech-to-text
3οΈβ£ Transcript is saved and processed via LangChain:
Loaded with TextLoader
Split using CharacterTextSplitter
Embedded via OpenAIEmbeddings
Stored with FAISS for fast vector search
4οΈβ£ The query is passed to the LLM (ChatOpenAI) using a RetrievalQA chain
5οΈβ£ π¬ User receives a smart answer based on actual video content!
π§ Tech Stack
β
Streamlit β UI & interaction
β
LangChain β Document processing & RAG
β
OpenAI GPT-3.5 β Question answering
β
FAISS β Vector storage
β
YouTubeTranscriptAPI β Subtitle extraction
β
AssemblyAI (Optional) β Audio transcription fallback
β
PyTube β For downloading audio from YouTube
π Key Highlights
βοΈ Converts YouTube content into a conversational AI interface
βοΈ Real-time interaction with a smooth Streamlit frontend
βοΈ Skip the full video β just ask what you want to know
βοΈ Modular codebase with robust error handling and retrieval pipeline
βοΈ Efficient, fast, and scalable for real-world use
π³ Docker Deployment
To make it easy for anyone to run the app locally, Iβve also Dockerized the project and published it on
Docker Hub: https://lnkd.in/d-trNx98

