# Video Edit MCP Server ๐ฌ
A powerful **Model Context Protocol (MCP) server** for video editing operations using MoviePy. This server enables AI assistants to perform comprehensive video editing tasks through a standardized interface.




## ๐ Features
### Core Video Operations
- **๐ฏ Video Trimming**: Extract specific time ranges from videos
- **๐ Video Concatenation**: Join multiple videos seamlessly
- **โ๏ธ Video Splitting**: Split videos into multiple segments
- **โก Speed Control**: Speed up or slow down video playback
- **๐ Video Reversal**: Play videos backwards
- **๐ Video Rotation**: Rotate videos by any angle
### Audio Processing
- **๐ต Audio Extraction**: Extract audio tracks from videos
- **๐ Audio Replacement**: Replace video soundtracks
- **๐ข Volume Control**: Adjust audio volume levels
- **๐๏ธ Audio Synchronization**: Automatically match audio/video durations
### Advanced Features
- **๐พ In-Memory Processing**: Efficient reference-based video manipulation
- **๐ Batch Operations**: Process multiple videos simultaneously
- **๐งน Resource Management**: Automatic cleanup to prevent memory leaks
- **๐ Media Information**: Detailed video/audio metadata extraction
- **โ
Error Handling**: Comprehensive error reporting and validation
## ๐ Requirements
- Python 3.8+
- MoviePy 1.0.3
- Model Context Protocol Python SDK
- FFmpeg (for video processing)
## โ๏ธ Installation
### Quick Install (Recommended)
**Install directly with uvx for instant use** (once published to PyPI):
```bash
uvx video-edit-mcp
```
> **Note**: Package will be available on PyPI soon. For now, use manual installation.
### For MCP Client Integration
Add this to your MCP client configuration file (e.g., Claude Desktop config):
```json
{
"tools": {
"video-edit": {
"command": "uvx",
"args": [
"video-edit-mcp"
]
}
}
}
```
**For Claude Desktop users**, edit your configuration file located at:
- **Windows**: `%APPDATA%/Claude/claude_desktop_config.json`
- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
- **Linux**: `~/.config/Claude/claude_desktop_config.json`
### Manual Installation
1. **Clone the repository**:
```bash
git clone https://github.com/yourusername/video-edit-mcp.git
cd video-edit-mcp
```
2. **Install dependencies**:
```bash
pip install -r requirements.txt
```
3. **Install the package**:
```bash
pip install -e .
```
### Prerequisites
**Ensure FFmpeg is installed** (required for video processing):
```bash
# On Windows (using chocolatey)
choco install ffmpeg
# On macOS (using homebrew)
brew install ffmpeg
# On Ubuntu/Debian
sudo apt update && sudo apt install ffmpeg
```
## ๐ฏ Usage
### Running the MCP Server
The server can be integrated with any MCP-compatible client:
```python
from mcp.server.fastmcp import FastMCP
# The server is automatically configured and ready to use
# Tools are registered and available for AI assistants
```
### Available Tools
| Tool | Description | Parameters |
|------|-------------|------------|
| `get_video_info` | Get comprehensive video metadata | `video_ref` |
| `get_audio_info` | Get detailed audio information | `audio_ref` |
| `trim_video` | Extract video segments | `video_ref, start_time, end_time, save, name_of_video` |
| `concatenate_videos` | Join multiple videos | `video_refs[], save, name_of_video` |
| `split_video` | Split into multiple segments | `video_ref, timestamps[], save, name_of_video` |
| `speed_up_or_slow_down_video` | Change playback speed | `video_ref, speed_factor, save, name_of_video` |
| `reverse_video` | Play video backwards | `video_ref, save, name_of_video` |
| `rotate_video` | Rotate by degrees | `video_ref, angle, save, name_of_video` |
| `extract_audio` | Extract audio track | `video_ref, save, name_of_audio` |
| `audio_replacement` | Replace video audio | `video_ref, audio_ref, save, fps, name_of_video` |
| `volume_control` | Adjust audio volume | `video_ref, volume_factor, save, name_of_video` |
| `cleanup_resources` | Free memory resources | `video_refs[], audio_refs[]` |
### Example Workflow
```python
# 1. Get video information
info = get_video_info("path/to/video.mp4")
# 2. Trim video to 30 seconds
trimmed_ref = trim_video("path/to/video.mp4", 0, 30, save=False)
# 3. Speed up the trimmed video 2x
fast_ref = speed_up_or_slow_down_video(trimmed_ref["video_ref"], 2.0, save=False)
# 4. Save final result
final_video = speed_up_or_slow_down_video(fast_ref["video_ref"], 1.0, save=True, name_of_video="final_edit")
```
## ๐๏ธ Project Structure
```
video_edit_mcp/
โโโ main.py # Main MCP server implementation
โโโ requirements.txt # Python dependencies
โโโ pyproject.toml # Project configuration
โโโ README.md # This file
โโโ video_store/ # Output directory for processed videos
โโโ test.py # Test utilities
```
## ๐๏ธ Configuration
### Memory Management
- Videos are stored in-memory using UUID references for efficient processing
- Use `cleanup_resources()` to prevent memory leaks during batch operations
- Large videos are automatically handled with streaming where possible
### Output Settings
- Default output format: MP4 with H.264 encoding
- Custom FPS settings available for audio replacement operations
- Automatic quality optimization based on input video properties
## ๐ฎ Planned Features & Enhancements
### ๐จ Visual Effects
- [ ] **Color Correction**: Brightness, contrast, saturation adjustments
- [ ] **Filters & Effects**: Blur, sharpen, vintage, sepia effects
- [ ] **Transitions**: Fade in/out, crossfade, wipe transitions
- [ ] **Text Overlays**: Dynamic text with custom fonts and animations
- [ ] **Image Overlays**: Watermarks, logos, picture-in-picture
### ๐ต Advanced Audio
- [ ] **Audio Mixing**: Combine multiple audio tracks
- [ ] **Noise Reduction**: AI-powered audio cleanup
- [ ] **Audio Effects**: Echo, reverb, equalization
- [ ] **Voice Processing**: Pitch shifting, voice enhancement
- [ ] **Music Generation**: AI-generated background music
### ๐ง AI-Powered Features
- [ ] **Smart Cropping**: Automatic scene detection and cropping
- [ ] **Object Tracking**: Follow subjects throughout the video
- [ ] **Scene Detection**: Automatic chapter/scene identification
- [ ] **Content Analysis**: Automatic tagging and categorization
- [ ] **Quality Enhancement**: AI upscaling and noise reduction
### ๐ง Technical Improvements
- [ ] **GPU Acceleration**: CUDA/OpenCL support for faster processing
- [ ] **Streaming Support**: Handle large files without loading into memory
- [ ] **Format Support**: WebM, AVI, MOV, and more format options
- [ ] **Cloud Integration**: AWS S3, Google Cloud Storage support
- [ ] **Progress Tracking**: Real-time processing progress updates
### ๐ Integration & API
- [ ] **REST API**: HTTP endpoints for web integration
- [ ] **WebSocket Support**: Real-time communication for live editing
- [ ] **Plugin System**: Extensible architecture for custom effects
- [ ] **CLI Interface**: Command-line tools for batch processing
- [ ] **Docker Support**: Containerized deployment options
### ๐ Analytics & Monitoring
- [ ] **Performance Metrics**: Processing time and resource usage tracking
- [ ] **Quality Metrics**: Automatic video quality assessment
- [ ] **Usage Analytics**: Tool usage statistics and optimization suggestions
- [ ] **Error Reporting**: Detailed error tracking and debugging tools
## ๐ค Contributing
We welcome contributions! Here's how you can help:
1. **Fork the repository**
2. **Create a feature branch**: `git checkout -b feature/amazing-feature`
3. **Make your changes** and add tests
4. **Commit your changes**: `git commit -m 'Add amazing feature'`
5. **Push to the branch**: `git push origin feature/amazing-feature`
6. **Open a Pull Request**
### Development Setup
```bash
# Clone your fork
git clone https://github.com/yourusername/video-edit-mcp.git
cd video-edit-mcp
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install development dependencies
pip install -r requirements.txt
pip install pytest black flake8
# Install in development mode
pip install -e .
# Run tests
pytest test.py
```
### Publishing to PyPI
To make your server available via `uvx` like the OpenCV example:
```bash
# Build the package
python -m build
# Upload to PyPI (requires account and API token)
python -m twine upload dist/*
```
After publishing, users can install with:
```bash
uvx video-edit-mcp
```
## ๐ License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## ๐ Acknowledgments
- **[MoviePy](https://zulko.github.io/moviepy/)** - The amazing video editing library powering this project
- **[Model Context Protocol](https://github.com/modelcontextprotocol/python-sdk)** - For the standardized AI integration framework
- **[FFmpeg](https://ffmpeg.org/)** - The multimedia framework behind MoviePy
## ๐ Support
- ๐ **Bug Reports**: [Create an issue](https://github.com/yourusername/video-edit-mcp/issues)
- ๐ก **Feature Requests**: [Start a discussion](https://github.com/yourusername/video-edit-mcp/discussions)
- ๐ง **Email**: your.email@example.com
- ๐ฌ **Discord**: [Join our community](https://discord.gg/yourserver)
---
<div align="center">
**Made with โค๏ธ for the AI and video editing community**
[โญ Star this project](https://github.com/yourusername/video-edit-mcp) | [๐ด Fork it](https://github.com/yourusername/video-edit-mcp/fork) | [๐ข Share it](https://twitter.com/intent/tweet?text=Check%20out%20this%20amazing%20Video%20Edit%20MCP%20Server!%20https://github.com/yourusername/video-edit-mcp)
</div>
Raw data
{
"_id": null,
"home_page": null,
"name": "video-edit-mcp",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": "ai, claude, editing, mcp, moviepy, server, video, video-processing",
"author": null,
"author_email": "Video Edit MCP <contact@example.com>",
"download_url": "https://files.pythonhosted.org/packages/b2/c8/fa2e9f3d2e700bed269d5366dbffa372ac1aad1b5843342962fda7481058/video_edit_mcp-0.1.0.tar.gz",
"platform": null,
"description": "# Video Edit MCP Server \ud83c\udfac\n\nA powerful **Model Context Protocol (MCP) server** for video editing operations using MoviePy. This server enables AI assistants to perform comprehensive video editing tasks through a standardized interface.\n\n\n\n\n\n\n## \ud83d\ude80 Features\n\n### Core Video Operations\n- **\ud83c\udfaf Video Trimming**: Extract specific time ranges from videos\n- **\ud83d\udd17 Video Concatenation**: Join multiple videos seamlessly \n- **\u2702\ufe0f Video Splitting**: Split videos into multiple segments\n- **\u26a1 Speed Control**: Speed up or slow down video playback\n- **\ud83d\udd04 Video Reversal**: Play videos backwards\n- **\ud83d\udd04 Video Rotation**: Rotate videos by any angle\n\n### Audio Processing\n- **\ud83c\udfb5 Audio Extraction**: Extract audio tracks from videos\n- **\ud83d\udd0a Audio Replacement**: Replace video soundtracks\n- **\ud83d\udce2 Volume Control**: Adjust audio volume levels\n- **\ud83c\udf9a\ufe0f Audio Synchronization**: Automatically match audio/video durations\n\n### Advanced Features\n- **\ud83d\udcbe In-Memory Processing**: Efficient reference-based video manipulation\n- **\ud83d\udcc1 Batch Operations**: Process multiple videos simultaneously \n- **\ud83e\uddf9 Resource Management**: Automatic cleanup to prevent memory leaks\n- **\ud83d\udcca Media Information**: Detailed video/audio metadata extraction\n- **\u2705 Error Handling**: Comprehensive error reporting and validation\n\n## \ud83d\udccb Requirements\n\n- Python 3.8+\n- MoviePy 1.0.3\n- Model Context Protocol Python SDK\n- FFmpeg (for video processing)\n\n## \u2699\ufe0f Installation\n\n### Quick Install (Recommended)\n\n**Install directly with uvx for instant use** (once published to PyPI):\n```bash\nuvx video-edit-mcp\n```\n\n> **Note**: Package will be available on PyPI soon. For now, use manual installation.\n\n### For MCP Client Integration\n\nAdd this to your MCP client configuration file (e.g., Claude Desktop config):\n\n```json\n{\n \"tools\": {\n \"video-edit\": {\n \"command\": \"uvx\",\n \"args\": [\n \"video-edit-mcp\"\n ]\n }\n }\n}\n```\n\n**For Claude Desktop users**, edit your configuration file located at:\n- **Windows**: `%APPDATA%/Claude/claude_desktop_config.json`\n- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`\n- **Linux**: `~/.config/Claude/claude_desktop_config.json`\n\n### Manual Installation\n\n1. **Clone the repository**:\n```bash\ngit clone https://github.com/yourusername/video-edit-mcp.git\ncd video-edit-mcp\n```\n\n2. **Install dependencies**:\n```bash\npip install -r requirements.txt\n```\n\n3. **Install the package**:\n```bash\npip install -e .\n```\n\n### Prerequisites\n\n**Ensure FFmpeg is installed** (required for video processing):\n```bash\n# On Windows (using chocolatey)\nchoco install ffmpeg\n\n# On macOS (using homebrew) \nbrew install ffmpeg\n\n# On Ubuntu/Debian\nsudo apt update && sudo apt install ffmpeg\n```\n\n## \ud83c\udfaf Usage\n\n### Running the MCP Server\n\nThe server can be integrated with any MCP-compatible client:\n\n```python\nfrom mcp.server.fastmcp import FastMCP\n\n# The server is automatically configured and ready to use\n# Tools are registered and available for AI assistants\n```\n\n### Available Tools\n\n| Tool | Description | Parameters |\n|------|-------------|------------|\n| `get_video_info` | Get comprehensive video metadata | `video_ref` |\n| `get_audio_info` | Get detailed audio information | `audio_ref` |\n| `trim_video` | Extract video segments | `video_ref, start_time, end_time, save, name_of_video` |\n| `concatenate_videos` | Join multiple videos | `video_refs[], save, name_of_video` |\n| `split_video` | Split into multiple segments | `video_ref, timestamps[], save, name_of_video` |\n| `speed_up_or_slow_down_video` | Change playback speed | `video_ref, speed_factor, save, name_of_video` |\n| `reverse_video` | Play video backwards | `video_ref, save, name_of_video` |\n| `rotate_video` | Rotate by degrees | `video_ref, angle, save, name_of_video` |\n| `extract_audio` | Extract audio track | `video_ref, save, name_of_audio` |\n| `audio_replacement` | Replace video audio | `video_ref, audio_ref, save, fps, name_of_video` |\n| `volume_control` | Adjust audio volume | `video_ref, volume_factor, save, name_of_video` |\n| `cleanup_resources` | Free memory resources | `video_refs[], audio_refs[]` |\n\n### Example Workflow\n\n```python\n# 1. Get video information\ninfo = get_video_info(\"path/to/video.mp4\")\n\n# 2. Trim video to 30 seconds\ntrimmed_ref = trim_video(\"path/to/video.mp4\", 0, 30, save=False)\n\n# 3. Speed up the trimmed video 2x\nfast_ref = speed_up_or_slow_down_video(trimmed_ref[\"video_ref\"], 2.0, save=False)\n\n# 4. Save final result\nfinal_video = speed_up_or_slow_down_video(fast_ref[\"video_ref\"], 1.0, save=True, name_of_video=\"final_edit\")\n```\n\n## \ud83c\udfd7\ufe0f Project Structure\n\n```\nvideo_edit_mcp/\n\u251c\u2500\u2500 main.py # Main MCP server implementation\n\u251c\u2500\u2500 requirements.txt # Python dependencies\n\u251c\u2500\u2500 pyproject.toml # Project configuration\n\u251c\u2500\u2500 README.md # This file\n\u251c\u2500\u2500 video_store/ # Output directory for processed videos\n\u2514\u2500\u2500 test.py # Test utilities\n```\n\n## \ud83c\udf9b\ufe0f Configuration\n\n### Memory Management\n- Videos are stored in-memory using UUID references for efficient processing\n- Use `cleanup_resources()` to prevent memory leaks during batch operations\n- Large videos are automatically handled with streaming where possible\n\n### Output Settings \n- Default output format: MP4 with H.264 encoding\n- Custom FPS settings available for audio replacement operations\n- Automatic quality optimization based on input video properties\n\n## \ud83d\udd2e Planned Features & Enhancements\n\n### \ud83c\udfa8 Visual Effects\n- [ ] **Color Correction**: Brightness, contrast, saturation adjustments\n- [ ] **Filters & Effects**: Blur, sharpen, vintage, sepia effects\n- [ ] **Transitions**: Fade in/out, crossfade, wipe transitions\n- [ ] **Text Overlays**: Dynamic text with custom fonts and animations\n- [ ] **Image Overlays**: Watermarks, logos, picture-in-picture\n\n### \ud83c\udfb5 Advanced Audio\n- [ ] **Audio Mixing**: Combine multiple audio tracks\n- [ ] **Noise Reduction**: AI-powered audio cleanup\n- [ ] **Audio Effects**: Echo, reverb, equalization\n- [ ] **Voice Processing**: Pitch shifting, voice enhancement\n- [ ] **Music Generation**: AI-generated background music\n\n### \ud83e\udde0 AI-Powered Features\n- [ ] **Smart Cropping**: Automatic scene detection and cropping\n- [ ] **Object Tracking**: Follow subjects throughout the video\n- [ ] **Scene Detection**: Automatic chapter/scene identification\n- [ ] **Content Analysis**: Automatic tagging and categorization\n- [ ] **Quality Enhancement**: AI upscaling and noise reduction\n\n### \ud83d\udd27 Technical Improvements\n- [ ] **GPU Acceleration**: CUDA/OpenCL support for faster processing\n- [ ] **Streaming Support**: Handle large files without loading into memory\n- [ ] **Format Support**: WebM, AVI, MOV, and more format options\n- [ ] **Cloud Integration**: AWS S3, Google Cloud Storage support\n- [ ] **Progress Tracking**: Real-time processing progress updates\n\n### \ud83c\udf10 Integration & API\n- [ ] **REST API**: HTTP endpoints for web integration\n- [ ] **WebSocket Support**: Real-time communication for live editing\n- [ ] **Plugin System**: Extensible architecture for custom effects\n- [ ] **CLI Interface**: Command-line tools for batch processing\n- [ ] **Docker Support**: Containerized deployment options\n\n### \ud83d\udcca Analytics & Monitoring\n- [ ] **Performance Metrics**: Processing time and resource usage tracking\n- [ ] **Quality Metrics**: Automatic video quality assessment\n- [ ] **Usage Analytics**: Tool usage statistics and optimization suggestions\n- [ ] **Error Reporting**: Detailed error tracking and debugging tools\n\n## \ud83e\udd1d Contributing\n\nWe welcome contributions! Here's how you can help:\n\n1. **Fork the repository**\n2. **Create a feature branch**: `git checkout -b feature/amazing-feature`\n3. **Make your changes** and add tests\n4. **Commit your changes**: `git commit -m 'Add amazing feature'`\n5. **Push to the branch**: `git push origin feature/amazing-feature`\n6. **Open a Pull Request**\n\n### Development Setup\n\n```bash\n# Clone your fork\ngit clone https://github.com/yourusername/video-edit-mcp.git\ncd video-edit-mcp\n\n# Create virtual environment\npython -m venv venv\nsource venv/bin/activate # On Windows: venv\\Scripts\\activate\n\n# Install development dependencies\npip install -r requirements.txt\npip install pytest black flake8\n\n# Install in development mode\npip install -e .\n\n# Run tests\npytest test.py\n```\n\n### Publishing to PyPI\n\nTo make your server available via `uvx` like the OpenCV example:\n\n```bash\n# Build the package\npython -m build\n\n# Upload to PyPI (requires account and API token)\npython -m twine upload dist/*\n```\n\nAfter publishing, users can install with:\n```bash\nuvx video-edit-mcp\n```\n\n## \ud83d\udcc4 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## \ud83d\ude4f Acknowledgments\n\n- **[MoviePy](https://zulko.github.io/moviepy/)** - The amazing video editing library powering this project\n- **[Model Context Protocol](https://github.com/modelcontextprotocol/python-sdk)** - For the standardized AI integration framework\n- **[FFmpeg](https://ffmpeg.org/)** - The multimedia framework behind MoviePy\n\n## \ud83d\udcde Support\n\n- \ud83d\udc1b **Bug Reports**: [Create an issue](https://github.com/yourusername/video-edit-mcp/issues)\n- \ud83d\udca1 **Feature Requests**: [Start a discussion](https://github.com/yourusername/video-edit-mcp/discussions)\n- \ud83d\udce7 **Email**: your.email@example.com\n- \ud83d\udcac **Discord**: [Join our community](https://discord.gg/yourserver)\n\n---\n\n<div align=\"center\">\n\n**Made with \u2764\ufe0f for the AI and video editing community**\n\n[\u2b50 Star this project](https://github.com/yourusername/video-edit-mcp) | [\ud83c\udf74 Fork it](https://github.com/yourusername/video-edit-mcp/fork) | [\ud83d\udce2 Share it](https://twitter.com/intent/tweet?text=Check%20out%20this%20amazing%20Video%20Edit%20MCP%20Server!%20https://github.com/yourusername/video-edit-mcp)\n\n</div>\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A powerful Model Context Protocol server for video editing operations using MoviePy",
"version": "0.1.0",
"project_urls": {
"Bug Tracker": "https://github.com/yourusername/video-edit-mcp/issues",
"Documentation": "https://github.com/yourusername/video-edit-mcp#readme",
"Homepage": "https://github.com/yourusername/video-edit-mcp",
"Repository": "https://github.com/yourusername/video-edit-mcp.git"
},
"split_keywords": [
"ai",
" claude",
" editing",
" mcp",
" moviepy",
" server",
" video",
" video-processing"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "0f828333383ea315e65b8d445079741afa579c2e436cc917445c5ba0c6c887c4",
"md5": "4c131307368eb444113f8cc7d6e4d24d",
"sha256": "a45b00f9ebe388857a73cd8e7329a3b8d4c3d0d649b930788b29673c23b17b87"
},
"downloads": -1,
"filename": "video_edit_mcp-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "4c131307368eb444113f8cc7d6e4d24d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10",
"size": 18669,
"upload_time": "2025-07-27T05:09:20",
"upload_time_iso_8601": "2025-07-27T05:09:20.174162Z",
"url": "https://files.pythonhosted.org/packages/0f/82/8333383ea315e65b8d445079741afa579c2e436cc917445c5ba0c6c887c4/video_edit_mcp-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "b2c8fa2e9f3d2e700bed269d5366dbffa372ac1aad1b5843342962fda7481058",
"md5": "0306ea3b0a542add9f803736d79de34f",
"sha256": "4d68497685e30b4aea3538cfc14c010b6a9f7fc2f39c132f7ce96481f3d9dedf"
},
"downloads": -1,
"filename": "video_edit_mcp-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "0306ea3b0a542add9f803736d79de34f",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 17351,
"upload_time": "2025-07-27T05:09:22",
"upload_time_iso_8601": "2025-07-27T05:09:22.222025Z",
"url": "https://files.pythonhosted.org/packages/b2/c8/fa2e9f3d2e700bed269d5366dbffa372ac1aad1b5843342962fda7481058/video_edit_mcp-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-07-27 05:09:22",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "yourusername",
"github_project": "video-edit-mcp",
"github_not_found": true,
"lcname": "video-edit-mcp"
}