A powerful Python-based video editing tool that leverages AI to process, transcribe, and enhance video content. This tool automates the video editing process by analyzing content, generating summaries, and creating engaging video segments. It also generates social media content for LinkedIn and Threads, automatically posting them as comments on Trello cards.
- 🎥 Video Processing: Extract and process video content
- 🎵 Audio Extraction: Separate audio from video files
- 🗣️ Transcription: Convert speech to text using OpenAI's Whisper
- 📝 Text Analysis: Analyze content using AI for better understanding
- ✂️ Video Editing: Automatically edit and segment videos
- 🤖 AI Integration: Leverage OpenAI's capabilities for content enhancement
- 🔄 Content Generation: Generate summaries and highlights
- 📱 Social Media: Generate optimized content for LinkedIn and Threads
- 📋 Trello Integration: Automatically post content as Trello card comments
- Python 3.8 or higher
- FFmpeg (for video processing)
- OpenAI API key
- Trello API credentials
The easiest way to get started is using the provided Makefile:
# Clone the repository
git clone https://github.com/guilherme-toti/video-editor.git
cd video-editor
# Set up the environment and install dependencies
make setupThis will:
- Create a virtual environment
- Install all dependencies
- Set up pre-commit hooks
- Create a
.envfile from the example if it doesn't exist
If you prefer to set up manually:
- Clone the repository:
git clone https://github.com/guilherme-toti/video-editor.git
cd video-editor- Create and activate a virtual environment:
python -m venv venv
source venv/bin/activate # On Windows, use: venv\Scripts\activate- Install dependencies:
pip install -r requirements.txt- Set up environment variables:
cp .env.example .env
# Edit .env with your OpenAI API key, Trello credentials, and other configurations- Create a Trello card for your video
- Use the "API Developer ID Helper (by Sensum365)" Trello Power Up to get the Card ID
- Rename your video file to include the Trello card ID (e.g., "67cc79f9b57bbf8b65d9409d.mov")
- Change the setting
is_trello_enabledvariable toFalseinsrc/config/settings.py
- Place the video file in the
data/rawdirectory - Run the video processor:
# Using make
make run
# Or directly
python main.pyThe script will:
- Process the video
- Generate social media content
- Automatically post the content as comments on the corresponding Trello card
The processed videos will be saved in the data/output directory.
The project includes several useful make commands:
make setup # Create virtual environment and install dependencies
make install # Install dependencies only
make run # Run the video processor
make lint # Run linting
make format # Auto-format code with black
make env # Create .env file from example if it doesn't exist
make help # Show all available commandsvideo-editor/
├── src/
│ ├── config/ # Configuration settings
│ ├── core/ # Core processing logic
│ ├── services/ # Service implementations
│ ├── prompts/ # AI prompt templates
│ └── utils.py # Utility functions
├── data/ # Data directories
├── main.py # Main entry point
├── requirements.txt # Project dependencies
└── .env # Environment variables
The project can be configured through the following:
.envfile: API keys and environment-specific settingssrc/config/settings.py: Application-wide settings
pytestThis project uses pre-commit hooks for code quality. Install them with:
pre-commit install- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- OpenAI for providing the Whisper model and API
- FFmpeg for video processing capabilities