Search
Find a needle in a haystyack of video
Searching Through an Index
Search allows you to find portions of a video through natural language. Results are categorized into three types: visual embeddings, transcriptions, and optical character recognition (OCR).
To search:
Where index
is required and the index you want to search, query
is required and your search query, and num_args
is optional and number of results you want back.
Every match object is an individual result that matches the query. A list of match objects is returned for every category.
A match object has the following data:
Index | Property | Example Value |
---|---|---|
0 | Moonshine assigned video fileID name | ’FHXYU838JHDWK.mp4’ |
1 | Match Frame Start | 600 |
2 | Match Frame End | 725 |
3 | Match Timestamp Start | ’0 min, 22 sec’ |
4 | Match Timestamp End | ’0 min, 24 sec’ |
Searching With an Image
You can search through an index with an image. To search with an image:
Searching an Index Subset (Subsearch)
You can narrow your search to a specific subset of videos within an index by using the subindex
parameter. This allows you to search only through selected videos instead of the entire index.
The subindex
parameter accepts a list of video_ids as strings. All video_ids must belong to the same parent index. This is useful when you want to focus your search on specific videos rather than searching through the entire index.