Skip to content

adityaraj31/youtube_chat_ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YouTube Chat AI - Beginner Friendly Guide

How it works

This app lets you ask questions about any YouTube video. It loads the transcript, splits it into chunks, converts text to vectors, and uses an AI model to answer your questions based on the video content.

Folder Structure

  • app.py: Main Streamlit app.
  • src/: Contains all helper code, organized by feature.
    • loaders/: Loads YouTube transcripts.
    • splitters/: Splits text into chunks.
    • embeddings/: Converts text to vectors.
    • vectorstore/: Stores and loads vector data.
    • llm/: Loads the AI model.
    • chains/: Builds the question-answering logic.
    • utils/: Extra helpers (like prompts).
  • data/: Stores FAISS index files (auto-created).
  • .env: Store your API keys here (never share this file!).
  • .gitignore: Protects sensitive files and folders from being uploaded to GitHub.

Configuration

Edit src/config.py to change:

  • Where data is stored (FAISS_PATH)
  • Which embedding model is used (EMBEDDING_MODEL_NAME)
  • Which AI model is used (LLM_MODEL_NAME)

Safety

  • Your .env file and data/ folder are ignored by Git thanks to .gitignore.
  • Never share your API keys or .env file.

Getting Started

  1. Install requirements: pip install -r requirements.txt
  2. Add your API keys to .env (see example in .env)
  3. Run the app: streamlit run app.py
  4. Enter a YouTube URL, process the video, and ask questions!

About

Streamlit app that turns any YouTube video into a chat-ready Q&A bot using LangChain, Groq Llama 3.3‑70B, sentence-transformer embeddings, and FAISS for fast semantic search.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages