Search
The Search endpoint performs semantic search across your analyzed videos using OpenAI text-embedding-3-small embeddings and Turso’s vector_distance_cos() function.
Results are module-diverse — the ranking algorithm uses round-robin interleaving across modules to prevent any single module from dominating results.
POST /search
Section titled “POST /search”Search video segments using natural language.
Auth: Required
| Body Field | Type | Required | Description |
|---|---|---|---|
query | string | Yes | Natural language search query |
job_id | string | No | Search within a specific video |
job_ids | string[] | No | Search within multiple specific videos |
modules | string[] | No | Filter by module types (e.g. ["transcription", "visualelements"]) |
limit | integer | No | Max results to return (default: 20, max: 200) |
threshold | float | No | Minimum similarity score 0.0–1.0 (default: 0.4) |
If neither job_id nor job_ids is provided, all completed videos for the user are searched.
Response: SearchResult[]
[ { "id": "42", "job_id": "a1b2c3d4-...", "module": "visualelements", "content": "Objects Detected: person, laptop, desk; Colors: blue, white; ...", "start_time": 15.0, "end_time": 18.0, "metadata": null, "similarity": 0.8234 }, { "id": "78", "job_id": "a1b2c3d4-...", "module": "transcription", "content": "Let me show you how the dashboard works on this laptop.", "start_time": 16.2, "end_time": 19.5, "metadata": null, "similarity": 0.7891 }]Results are sorted by similarity (descending). A similarity of 1.0 is a perfect match; the default threshold of 0.4 filters out weak matches.
Deduplication: Results are deduplicated per (job_id, module, 5-second window) to avoid near-duplicate segments.
curl -X POST https://api.lynxvizion.com/api/search \ -H "Authorization: $LVZ_KEY" \ -H "Content-Type: application/json" \ -d '{ "query": "person giving a presentation", "limit": 10, "threshold": 0.5 }'Search within a specific video
Section titled “Search within a specific video”curl -X POST https://api.lynxvizion.com/api/search \ -H "Authorization: $LVZ_KEY" \ -H "Content-Type: application/json" \ -d '{ "query": "brand logo visible on screen", "job_id": "a1b2c3d4-...", "modules": ["logos", "visualelements"], "limit": 20 }'