This project is a Streamlit-based chatbot that lets you ask questions about any YouTube video.
It uses:
- YouTube Transcript API to fetch captions
- Gemini (
models/embedding-001) for free embeddings - FAISS for vector search
- LangChain + Gemini LLM for conversational responses
- Extracts YouTube video transcripts automatically
- Splits transcripts into chunks for retrieval
- Uses Gemini embeddings (free tier available)
- Answers questions based only on the transcript content
- Simple Streamlit interface
- Deployable on Render for free hosting
- Clone this repo:
git clone https://github.com/your-username/youtube-chatbot.git cd youtube-chatbot - (Optional but recommended) Create a virtual environment & activate it:
python -m venv venv source venv/bin/activate # macOS/Linux venv\Scripts\activate # Windows
- Install dependencies:
pip install -r requirements.txt
- Set up your environment variables:
Create a .env file in the root directory and add:
GOOGLE_API_KEY=your_gemini_api_key
- Run the Streamlit app:
streamlit run app.py