Latency-optimized Universal Multimodal Output Studio
π¬ AI-Powered Viral Video Clip Generator for Content Creators
LUMOS is an intelligent video processing application that helps content creators automatically identify and extract viral-worthy moments from long-form videos. Using Google's Gemini AI, it analyzes videos and generates optimized clips for different social media platforms (YouTube Shorts, Instagram Reels, and TikTok) along with platform-specific captions.
- π€ AI-Powered Analysis: Uses Gemini AI to analyze videos and identify viral moments
- π± Multi-Platform Support: Generates clips optimized for YouTube Shorts, Instagram Reels, and TikTok
- βοΈ Automated Clipping: Automatically cuts video segments based on AI recommendations
- π Caption Generation: Creates engaging, platform-specific captions using AI
- π― Audience Targeting: Considers platform-specific audience preferences
- π Web Interface: User-friendly web application for easy video upload and clip preview
- Python 3.8 or higher
- FFmpeg (for video processing)
- Google Gemini API key
Ubuntu/Debian:
sudo apt-get update
sudo apt-get install ffmpegmacOS:
brew install ffmpegWindows: Download from ffmpeg.org and add to PATH
- Clone the repository:
git clone https://github.com/Bhargavi-hash/LUMOS.git
cd LUMOS- Install Python dependencies:
pip install -r backend/requirements.txt- Create environment file:
cp .env.example .env- Add your Gemini API key to
.env:
GEMINI_API_KEY=your_actual_gemini_api_key_here
FLASK_SECRET_KEY=your_secret_key_here
- Start the application (Option 1 - using launcher script):
python run.pyOr (Option 2 - run directly):
python backend/app.py- Open your browser and navigate to:
http://localhost:5000
-
Upload a video file (MP4, AVI, MOV, MKV, or WebM)
-
Wait for AI analysis and clip generation
-
View generated clips with captions for each platform
-
Video Upload: User uploads a long-form video through the web interface
-
AI Analysis: Gemini AI analyzes the video content to identify:
- Engaging moments with strong hooks
- Platform-specific viral potential
- Optimal clip timing (15-60 seconds)
-
Clip Generation: The system automatically cuts video segments using MoviePy
-
Caption Creation: Gemini AI generates platform-optimized captions:
- YouTube Shorts: Educational, SEO-friendly with hashtags
- Instagram Reels: Engaging, emoji-rich with call-to-action
- TikTok: Trend-focused, conversational style
-
Preview & Download: Users can preview all clips and their captions in the web interface
LUMOS/
βββ backend/ # Backend application
β βββ app.py # Flask application
β βββ video_analyzer.py # Gemini AI integration for video analysis
β βββ video_clipper.py # Video cutting and clip generation
β βββ requirements.txt # Python dependencies
β βββ utils/ # Utility modules (for future extensions)
β βββ uploads/ # Uploaded videos (git-ignored)
β βββ outputs/ # Generated clips (git-ignored)
βββ frontend/ # Frontend application
β βββ templates/ # HTML templates
β β βββ index.html # Web interface
β βββ static/ # Static assets
β βββ css/
β β βββ style.css # Styling
β βββ js/
β βββ app.js # Frontend logic
βββ run.py # Application launcher script
βββ .env.example # Environment variables template
βββ .gitignore # Git ignore rules
βββ LICENSE # License file
βββ README.md # This file
GET /- Main web interfacePOST /upload- Upload and process videoGET /clips/<filename>- Serve generated video clipsGET /health- Health check and API status
GEMINI_API_KEY: Your Google Gemini API key (required for AI features)FLASK_SECRET_KEY: Secret key for Flask sessions
- Maximum file size: 500MB
- Supported formats: MP4, AVI, MOV, MKV, WebM
- Focus: Educational content, tutorials, quick tips
- Duration: 15-60 seconds
- Captions: SEO-friendly with 3-5 hashtags
- Focus: Aesthetic content, lifestyle, trending audio
- Duration: 15-60 seconds
- Captions: Emoji-rich with 5-10 hashtags and call-to-action
- Focus: Trending content, high energy, humor
- Duration: 15-60 seconds
- Captions: Conversational with 3-5 hashtags
python run.pyOr:
python backend/app.pyThe application will run on http://localhost:5000 with debug mode enabled.
If the Gemini API key is not configured, the application will run in mock mode with sample data, allowing you to test the interface and clip generation without API access.
- Backend: Flask (Python web framework)
- AI: Google Gemini API (video analysis and caption generation)
- Video Processing: MoviePy (video cutting and manipulation)
- Frontend: HTML, CSS, JavaScript (vanilla)
- Storage: Local filesystem for uploads and outputs
See LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
For issues and questions, please open an issue on GitHub.