wtf( )unctionsystem design, drawn
← all problemsAI EngineeringMedium

The error code that semantic search can't find

"What does ERR_CONN_4021 mean?" returns essays about connection handling and never the runbook containing that exact code. Meanwhile "what happens when the gateway can't reach upstream" works fine.

Embeddings capture meaning, and a rare identifier carries almost none. Keyword search has the opposite problem: it nails the literal token and misses every paraphrase.

Run both retrievers and place what combines their results.
Components — tap one, then tap a slot on the diagram
!Searching an exact error code returns everything except the runbook that contains it.

Outside every boundary: Keyword search (exact tokens), Reranker, Model, Vector search (meaning; FAILED: misses codes), Query, an empty slot for the merge two ranked lists Connections: Query calls Vector search (step 1) Query calls Keyword search (step 1) Vector search calls merge two ranked lists (step 2) Keyword search calls merge two ranked lists (step 2) merge two ranked lists calls Reranker (step 3) Reranker calls Model (step 4)

Keyword searchexact tokens
Reranker
Model
Vector searchmeaningmisses codes
Query