# YouTube Summarizer: AI-Powered Summaries for YouTube Videos and Playlists

This repository profile is provided by osrepos.com, an open source repository discovery platform.

Source: osrepos.com
Repository profile: https://osrepos.com/repo/jaye773-youtube-summarizer
Generated for open source discovery and AI-assisted research.

YouTube Summarizer is a Flask web application designed to generate concise, AI-powered summaries of YouTube videos and entire playlists. It leverages advanced AI models like Google Gemini and OpenAI GPT, extracts transcripts, and can even convert summaries into audio using Google's Text-to-Speech API, offering a comprehensive tool for efficient content digestion.

GitHub: https://github.com/jaye773/youtube-summarizer
OSRepos URL: https://osrepos.com/repo/jaye773-youtube-summarizer

## Summary

YouTube Summarizer is a Flask web application designed to generate concise, AI-powered summaries of YouTube videos and entire playlists. It leverages advanced AI models like Google Gemini and OpenAI GPT, extracts transcripts, and can even convert summaries into audio using Google's Text-to-Speech API, offering a comprehensive tool for efficient content digestion.

## Topics

- Python
- YouTube
- AI
- Summarization
- Flask
- Video Processing
- Text-to-Speech
- Open Source

## Repository Information

Last analyzed by OSRepos: Wed Dec 17 2025 20:00:42 GMT+0000 (Western European Standard Time)
Detail views: 0
GitHub clicks: 4

## Safety Notice

OSRepos shares public repositories for knowledge and discovery only. Review source code, dependencies, licenses, and security implications before running or installing anything.

## Content

## Introduction
The `youtube-summarizer` project is a powerful Flask web application that provides AI-powered summarization for YouTube videos and playlists. It streamlines the process of extracting key information from long-form video content by generating concise summaries using state-of-the-art AI models. Beyond just text, the application also offers the unique ability to convert these summaries into audio files, enhancing accessibility and convenience.

## Installation
The recommended way to set up and run YouTube Summarizer is using Docker. This ensures a consistent environment and simplifies dependency management.

**Prerequisites:**
*   **Google API Key**: Required for YouTube Data API v3, Google Generative AI (Gemini), and Google Cloud Text-to-Speech API.
*   **OpenAI API Key**: Optional, for utilizing OpenAI GPT models.

**Steps for Docker Installation:**
1.  **Clone the Repository:**
    bash
    git clone https://github.com/jaye773/youtube-summarizer.git
    cd youtube-summarizer
    
2.  **Set Up Environment Variables:** Create a `.env` file in the project root and add your API keys:
    
    GOOGLE_API_KEY=your_google_api_key_here
    OPENAI_API_KEY=your_openai_api_key_here  # Optional, for GPT models
    
3.  **Initialize Data Directory:** Run the initialization script to create the necessary directory structure:
    bash
    ./init_data.sh
    
4.  **Run with Docker Compose:**
    bash
    docker-compose up -d
    
    The application will be accessible at `http://localhost:5001`.

## Examples
Using the YouTube Summarizer is straightforward through its clean web interface.

1.  **Open the Web Interface:** Navigate to `http://localhost:5001` in your browser.
2.  **Login (if enabled):** If authentication is configured, enter the passcode to gain access.
3.  **Enter YouTube URLs:** Paste one or more YouTube video or playlist URLs into the input field. Multiple URLs can be entered on separate lines.
4.  **Generate Summaries:** Click the "Summarize" button to begin processing the videos.
5.  **View Results:** Summaries will appear below each video. You can also find cached summaries in the sidebar. Click the speaker icon to generate and play audio versions of the summaries.

## Why Use It
YouTube Summarizer offers a comprehensive solution for efficient video content consumption. Its key advantages include:
*   **Multi-Model AI Support:** Choose between Google Gemini and OpenAI GPT models for summarization, allowing flexibility and access to diverse AI capabilities.
*   **Playlist Support:** Effortlessly process and summarize entire YouTube playlists, saving significant time.
*   **Audio Generation:** Convert text summaries into MP3 audio files, perfect for on-the-go learning or accessibility.
*   **Smart Caching:** Minimize API calls and speed up retrieval with intelligent caching of summaries and audio files.
*   **Optional Authentication and Proxy Support:** Enhance security with passcode-based login and bypass IP restrictions using Webshare proxy integration.
*   **Clean and Responsive Interface:** A user-friendly web UI ensures a smooth and intuitive experience.

## Links
*   **GitHub Repository:** [https://github.com/jaye773/youtube-summarizer](https://github.com/jaye773/youtube-summarizer){:target="_blank"}