Reverse Video Search
Search your video library by submitting a video clip as the query. The pipeline decomposes the query video into scene-level embeddings and matches them against your indexed video collection to find visually and semantically similar content.
from mixpeek import Mixpeekclient = Mixpeek(api_key="YOUR_API_KEY", namespace="video-library")# 1. A bucket for the video library, and a collection that splits each video into scenes with a multimodal embeddingbucket = client.buckets.create(bucket_name="video-library",bucket_schema={"properties": {"video": {"type": "video",},},},)collection = client.collections.create(collection_name="video_library",source={"type": "bucket", "bucket_ids": [bucket["bucket_id"]]},feature_extractor={"feature_extractor_name": "multimodal_extractor","version": "v1","parameters": {"split_method": "scene",},},)# 2. Upload and processclient.buckets.upload(bucket["bucket_id"],blobs=[{"property": "video", "type": "video", "data": "s3://your-bucket/videos/launch-film.mp4"}],)client.collections.trigger(collection["collection_id"])# 3. A clip searched against indexed scenes, keeping the best scene per source videoretriever = client.retrievers.create(retriever_name="reverse-video-search",collection_identifiers=["video_library"],input_schema={"clip": {"type": "video","required": True,},},stages=[{"stage_name": "search","stage_id": "feature_search","parameters": {"searches": [{"feature_uri": "mixpeek://multimodal_extractor@v1/vertex_multimodal_embedding","query": {"input_mode": "content","value": "{{INPUT.clip}}",},"top_k": 100,},],"final_top_k": 100,"group_by": {"field": "source_object_id","max_per_group": 1,"limit": 20,},},},],)# 4. Searchresults = client.retrievers.execute(retriever["retriever_id"],inputs={"clip": "https://example.com/query-clip.mp4",},)for doc in results["documents"]:print(doc["source_object_id"], doc["start_time"], doc["score"])
Feature Extractors
Multimodal Extractor
Unified embeddings for video, audio, image, and text: scene/silence chunking, Whisper transcription, thumbnails, and Gemini vision.
Retriever Stages
feature search
Search and filter documents by vector similarity using feature embeddings
Frequently asked questions
How long can the query video be?
Query videos are automatically decomposed into scenes. Clips up to 10 minutes work best for targeted matching. For longer videos, consider splitting into shorter segments.
Does this detect re-encoded or cropped copies?
Yes. The embedding-based approach is robust to common transformations like re-encoding, cropping, resolution changes, and watermarking.
What video formats are supported?
MP4, MOV, AVI, WebM, MKV, and most common video containers are supported. The pipeline uses FFmpeg internally for format handling.
Related Recipes & Resources
Explore these related resources to deepen your understanding and discover more powerful features
Multimodal Extractor
Unified embeddings for video, audio, image, and text: scene/silence chunking, Whisper transcription, thumbnails, and Gemini vision.
Text Grouping
Group video segments based on unique text appearing on screen
Object Grouping
Segment and group objects across video frames
Scene Splitting
Detect and segment distinct scenes in video content
Face Grouping
Detect, track, and group faces across video frames
Video Transcription
Convert speech to text with timestamps for video content