Python · Whisper · FFmpeg · OpenCV · scikit-learn
Find the moment. Check the context. Keep the highlight.
ClipIQ watches a long video for spikes in sound, motion and speech, proposes the best moments, trims them to clean start and end points and exports clips. A person approves every clip before it's used.
3signals read: loudness, on-screen motion and speech
0uploads: runs on your own computer, no cloud or API key
181automated tests, run on every push
100%of clips reviewed by a person before export
Review the proposals
This is how the review screen works, with example data from a 12-minute karting video. Click a proposal on the timeline or in the queue, adjust it, then approve or reject it.
✓ fingerprint✓ audio✓ visual✓ transcript✓ candidates● review0 of 5 reviewed
Original candidate
Proposed clip
StartEnd
How ClipIQ finds a highlight
Every stage is cached by the video's fingerprint, so a rerun skips work that is already done.
- Fingerprint and cacheHashes the source video. Stage results are saved as checksummed JSON, never pickle, and reused when nothing changed.
- Read the signalsAudio loudness with librosa, on-screen motion with OpenCV, and an optional Whisper transcript with timestamps.
- Propose and rankFinds candidate moments from peaks and activity, then ranks them. A logistic-regression model was trained on hand-labelled highlights.
- Fix the edgesMoves cuts to the end of a sentence or a quiet moment, so clips don't start or stop mid-word, and flags cuts it had to force.
- Pick a varied setSplits long events, removes near-duplicates and keeps variety, within the length you ask for.
- Export and reviewFFmpeg renders clips, optional 9:16 versions and captions. The review app saves every decision as its own file.
What you get
Every run gets its own folder, so nothing is overwritten, even when you process the same video twice.
data/processed/clipiq/ cache/ # reusable stage results latest.json # points to the last run runs/<time>_<id>/ manifest.json # settings, timings, errors transcription.json reports/ # proposals as JSON + CSV clips/ # highlight_001.mp4, .srt portrait/ # 9:16 versions reviews/ # approve / reject decisions
Built to be trusted
- Scores are relative. They rank moments within one video; they don't predict views.
- Nothing leaves your computer. The review app only listens on your own machine.
- Whisper is optional. Without it, ClipIQ still finds action moments from sound and motion.
- Clips are checked. Every export's length is verified with ffprobe; a failed run keeps its error log.
Known limits
- 9:16 versions pad the frame; they don't follow the subject yet.
- Captions follow sentence timing, not word by word.
- It can't know whether a story's payoff is complete, so it flags those clips for review.
Run it yourself
Python 3.10 or newer and FFmpeg. Tested on macOS with Python 3.12.
git clone https://github.com/gamersusshal-bit/ClipIQ.git cd ClipIQ python3 -m venv .venv && . .venv/bin/activate pip install -e . # add '.[speech]' for Whisper # process a video: 5 highlights, up to 60 seconds each PYTHONPATH=src python -m clipiq run path/to/video.mp4 --top-k 5 --max-duration 60 # open the review app at http://127.0.0.1:8765 PYTHONPATH=src python -m clipiq review --output data/processed/clipiq
PythonWhisperFFmpegOpenCVlibrosaNumPypandasSciPyscikit-learnunittestGitHub Actions