It's rough, it sometimes still includes pauses and mistakes in the final video and it only works with video with dialogue in it but it can do a decent job and is a proof-of-concept that video editing with LLMs is possible. Products like http://Gling.ai obviosuly show how powerful this workflow is and will only get better as the underlying models do too. This uses Claude 3.5 Sonnet as GPT-4o wasn't handling the cuts so nicely.
Final edited video and raw clips can be seen at https://x.com/mitch_7w/status/1805579775685411150
To use:
- Download the code
- Create a .env file with your OPENAI_API_KEY and ANTHROPIC_API_KEY set inside of it.
- Run pip install -r requirements.txt
- Place the input videos you want edited into the same folder as the code and enter the filenames in the video_files array at the top of the ai_video_editor_simple.py file.
- Run and check out the ai_output.mp4 video when it's done.