← Back to search

System overview · Retrieval pipeline

How Yaqeen Video Search works

Ask a question in plain language; get back the exact moments in Yaqeen's video library that answer it, each one a click away from playing at that second — plus a cited AI summary. Here is what happens between the question and the answer.

2,190
videos indexed
~70k
timestamped moments
<2s
to results
1
click to the exact second

A Building the library

Done once per video, ahead of time.

Every video's transcript comes from Yaqeen's transcription service already carrying sentence-level timestamps, so we never have to align text to audio — the timing is free. We cut each transcript into ~60-second windows that overlap by 15 seconds (so a thought split across a boundary is still findable), and store every window as a searchable record in GoodMem, our vector database. Each record keeps the text plus its source: video_id, title, and start/end seconds — everything needed to build a jump-to-the-moment YouTube link later.

Two collections are built: one of the ~70,000 transcript moments, and a second of the 2,190 video titles. The title collection is what lets a strong title match ("Malcolm X's Legacy") lift a whole video, not just one line of it.

B Answering a question

The live path, every search, in well under two seconds.

The question "why is there so much suffering"
Semantic · body Transcript moments Embedder finds candidates → Voyage reranker scores each for real relevance
Semantic · title Video titles Same path — how well the video is about the question
Exact · direct Keyword index Any moment containing every query word, verbatim — regardless of the model
Blend Weighted fusion — 0.6 × title relevance + 0.4 × moment relevance A strong title match boosts every moment of that video. Direct keyword hits are injected here and flagged.
relevance gate — keep if score ≥ 0.68  ·  exact matches exempt
Tidy up Merge & de-duplicate → one card per video Adjacent moments combine into a single time range; a title-driven video shows as "full video." Direct matches rank first, then by blended score.
InstantResults appear Each links to youtube…&t= the exact second
Moments laterAI summary Written only from the shown results, citing each moment

C Why it's built this way

Four decisions that carry the quality of the results.

PieceWhat it buys us
RerankerA raw vector match is fuzzy. The Voyage reranker re-reads each candidate against the actual question and returns a calibrated 0–1 relevance, which is what makes a meaningful cut-off possible at all.
Title weightingPeople often search for what a video is about, not a passing line. Weighting the title 60% surfaces the right video as a whole, then points inside it.
Keyword indexSemantic search has a blind spot: names. "Osama bin Laden" pulls the companion "Usama ibn Zayd" instead. A direct keyword match is a certainty the model shouldn't override — so it bypasses the reranker and the threshold.
Relevance gateVector search always returns something. The 0.68 floor lets the system say "we don't cover this" — an empty result — instead of showing confident-looking but off-topic cards.

D A worked example

The keyword index earning its place — a query the model alone gets wrong.

query  osama bin laden
1
The embedder + reranker return "Usama ibn Zayd (ra)" — a companion of the Prophet. Semantically the nearest match, and the wrong one.
2
The real mention — "the letter supposedly written by Osama bin Laden" — lives inside a khutbah on war & justice. It's topically distant, so it never makes the reranker's shortlist.
The keyword index finds it directly: that moment contains all of osama, bin, laden. It's injected past the gate and surfaces at 8:20 — the correct answer the model had buried.
Known limit, being honest: exact matching is literal, so a spelling variant like "usama bin laden" won't connect to "Osama". Bridging transliteration variants (usama↔osama, ibn↔bin) is a small, scoped next step.

E The stack, at a glance

LayerWhat we use
Vector storeGoodMem — holds the moments and titles, runs semantic search + reranking
EmbeddingsVoyage voyage-3-large
RerankerVoyage rerank-2.5
AI summarygpt-4.1-mini via OpenRouter — grounded only in the shown results
Chunking60-second windows, 15-second overlap
Tuningtitle 0.6 / body 0.4 · relevance floor 0.68 · exact-match override

Snapshot of the current configuration — every weight and threshold above is a single tunable value, adjusted from live query traces.