Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎬 ClipGenius: AI Video Summarizer & Highlight Detector

ClipGenius is an intelligent, privacy-first Multimodal AI pipeline built to extract value from video content completely locally. The application splits video data into two parallel tracks—audio (linguistic processing) and visual (computational vision)—to generate a comprehensive text summary and detect visual highlights (like presentation slide changes or scene cuts) without relying on any paid cloud APIs.


🚀 Project Motive & Core Value

Modern video analytics rely heavily on cloud-based APIs (like OpenAI or Anthropic), which introduces significant challenges:

  1. High API Costs: Processing hours of video data quickly becomes expensive.
  2. Data Privacy Risks: Uploading proprietary, internal, or sensitive video files to external servers presents security concerns.

ClipGenius fixes this. By orchestrating highly optimized, open-source AI models entirely on your local machine, this project demonstrates a cost-effective, secure, and privacy-respecting alternative designed for modern AI engineering.


📊 System Architecture & Data Flow

The pipeline handles data sequentially across distinct subsystems:

  1. Ingestion & De-muxing: The video file is ingested via Streamlit. MoviePy extracts the raw audio track while OpenCV initializes frame-by-frame analysis.
  2. Linguistic Track (Audio): The local faster-whisper model decodes the audio track into a timestamped text transcript. This transcript is passed to a localized Hugging Face BART transformer pipeline to generate the final condensed text summary.
  3. Visual Track (Vision): OpenCV samples frames to compute and compare multi-channel color histograms (HSV space). Structural shifts exceeding the mathematical correlation threshold are flagged as "Key Moments," saving the corresponding frames locally.
  4. Presentation Layer: The data streams merge into a unified, interactive Streamlit dashboard interface.

🛠️ Tech Stack

  • Frontend Dashboard: Streamlit (for building the real-time UI)
  • Audio Track Extraction: MoviePy (efficient video-to-audio extraction)
  • Local Speech-to-Text: faster-whisper (re-engineered local Whisper engine up to 4x faster than standard libraries)
  • Computer Vision: OpenCV (for color histogram matching and scene detection thresholds)
  • Local Text Summarization: Hugging Face Transformers (utilizing the facebook/bart-large-cnn model)

📁 Repository Directory Structure

video-summarizer/
│
├── app.py                 # Core Streamlit app orchestrating the entire pipeline
├── transcriber.py         # Subsystem handling audio extraction and local Whisper processing
├── video_processor.py     # Subsystem handling OpenCV color histogram analysis & frame saving
├── summarizer.py          # Subsystem handling NLP chunking and local BART text summarization
├── requirements.txt       # Unified Python package dependencies
└── storage/               # Autogenerated directory for pipeline file handling
    ├── uploads/           # Raw video caching
    ├── audio/             # Extracted audio tracks (.mp3)
    └── frames/            # Extracted visual keyframes (.jpg)


## 💻 Installation & Local Setup
1. Prerequisites
Ensure you have Python 3.9 through Python 3.12 installed on your machine.

2. Clone the Repository
Bash
git clone [https://github.com/Surendra571/video-summarizer.git](https://github.com/Surendra571/video-summarizer.git)
cd video-summarizer

3.Install Dependencies
Install all required open-source AI libraries and tools via pip:

Bash
pip install -r requirements.txt
(Note: On the very first runtime execution, Hugging Face and Whisper will automatically download and cache their model weights locally. Subsequent runs will be completely offline).

4. Launch the Dashboard
Run the Streamlit server to open the application in your web browser:

Bash
streamlit run app.py

Default local access link: http://localhost:8501

## 💡 Usage Guide
Upload: Open the dashboard and drop an .mp4 (or other standard video formats) into the uploader panel.

Analyze: Click the Analyze Video Now button to start the multimodal pipeline. You can follow live step-by-step progress bars directly in the UI.

Insights: Review the final AI-distilled summary paragraph alongside a dynamic grid showcasing visual highlights with exact timestamp markers.


### 🎯 What to do next:
1. Save this file as `README.md` inside your project directory.
2. Replace `YOUR_USERNAME` in the clone command with your actual GitHub username.
3. Commit all your project files (`app.py`, `transcriber.py`, `video_processor.py`, `summarizer.py`, `requirements.txt`, and `README.md`) to your GitHub repository! 

This makes your project look fully production-ready and highly polished for anyone evaluating

About

ClipGenius is an intelligent, privacy-first **Multimodal AI pipeline** built to extract value from video content completely locally. The application splits video data into two parallel tracks—audio (linguistic processing) and visual (computational vision)—to generate a comprehensive text summary and detect visual highlights.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages