🚀 Intelligent video clipper powered by Gemini AI - Automatically analyze YouTube videos and create viral-worthy clips with AI-suggested timestamps.
- 🤖 AI-Powered Analysis: Gemini AI automatically identifies viral-worthy moments
- 📺 YouTube Integration: Direct download and processing from YouTube URLs
- ⚡ High Performance: Built with Rust for maximum speed and efficiency
- 🎯 Smart Clipping: Generates 3-5 optimized clips (10-30 seconds each)
- 📝 Flexible Configuration: Support both AI mode and manual JSON configuration
- 🔒 Secure: Environment-based API key management
- 🎨 User-Friendly: Beautiful progress indicators and emoji feedback
# Ubuntu/Debian
sudo apt install rustc cargo ffmpeg yt-dlp curl
# macOS
brew install rust ffmpeg yt-dlp curl
# Windows (using Chocolatey)
choco install rust ffmpeg yt-dlp curl- Clone the repository
git clone https://github.com/Hans02-Neo/clipper-rust.git
cd clipper-rust- Set up environment
cp .env.example .env
# Edit .env and add your Gemini API key- Build the project
cargo build --release./target/release/auto-clipper "https://www.youtube.com/watch?v=dQw4w9WgXcQ"./target/release/auto-clipper config.json- 📚 Full Documentation
- 🛠️ Installation Guide
- 🎯 Usage Examples
- 🔧 Configuration
- 🤝 Contributing
- 📋 API Reference
# Download and analyze a YouTube video
$ ./target/release/auto-clipper "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
🔍 Analyzing YouTube video...
📥 Downloading video...
⏱️ Video duration: 213.0s
🤖 Getting AI analysis...
📝 AI suggested clips:
{
"input_video": "video.mp4",
"clips": [
{
"start": "00:00:07",
"end": "00:00:22",
"output": "viral_clip_1.mp4"
},
// ... more clips
]
}
🎬 Processing 4 clips from video.mp4
✓ Created: viral_clip_1.mp4
✓ Created: viral_clip_2.mp4
✓ Created: viral_clip_3.mp4
✓ Created: viral_clip_4.mp4
🎉 Done!┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ YouTube URL │───▶│ yt-dlp │───▶│ Video File │
└─────────────────┘ └─────────────────┘ └─────────────────┘
│
┌─────────────────┐ ┌─────────────────┐ │
│ Gemini AI │◀───│ AI Analysis │◀────────────┘
└─────────────────┘ └─────────────────┘
│ │
▼ ▼
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ JSON Config │───▶│ FFmpeg │───▶│ Viral Clips │
└─────────────────┘ └─────────────────┘ └─────────────────┘
We welcome contributions! Please see our Contributing Guide for details.
# Clone and setup
git clone https://github.com/Hans02-Neo/clipper-rust.git
cd clipper-rust
# Install dependencies
cargo install --path .
# Run tests
cargo test
# Format code
cargo fmt
# Lint
cargo clippyThis project is licensed under the MIT License - see the LICENSE file for details.
- Gemini AI for intelligent video analysis
- FFmpeg for video processing
- yt-dlp for YouTube integration
- Rust Community for the amazing ecosystem