feat(search): hybrid semantic search (RRF) #34

Merged
cesnimda merged 1 commits from feat/hybrid-search into develop 2026-07-02 17:36:28 +02:00
Owner

Recommendation #4b — the flagship. Lexical+vector RRF fusion with graceful degradation; semantic-recall LiveDb test (zero keyword overlap) green vs real pgvector.

🤖 Generated with Claude Code

Recommendation #4b — the flagship. Lexical+vector RRF fusion with graceful degradation; semantic-recall LiveDb test (zero keyword overlap) green vs real pgvector. 🤖 Generated with Claude Code
cesnimda added 1 commit 2026-07-02 17:17:58 +02:00
feat(search): hybrid semantic search via RRF fusion (RECOMMENDATIONS #4b)
CI / backend (pull_request) Successful in 1m0s
CI / frontend (pull_request) Successful in 14s
CI / format (pull_request) Successful in 50s
CI / db-tests (pull_request) Successful in 53s
Security / secrets (pull_request) Successful in 4s
Security / dependencies (pull_request) Successful in 56s
50bf6d977a
The flagship slice (docs/discovery/05): when a free-text query runs and embeddings
are available, fuse lexical top-50 (ts_rank_cd) with vector top-50 (pgvector cosine
over the structured-filtered set) using Reciprocal Rank Fusion. Placed BEFORE the
fuzzy fallback so queries with ZERO lexical hits still get semantic recall — found
and fixed during review (the fuzzy path would otherwise swallow pure-semantic
queries). Exact lexical hits keep winning (rank in both lists); deeper pages fall
through to lexical paging; ANY failure (Ollama down, nothing embedded) silently
degrades to the lexical/fuzzy path — AI can never break search.

LiveDb test proves the recall win: a 'banana' query surfaces an email with no
keyword overlap, ranked first, against real pgvector. 5 LiveDb + full suite green;
format clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
cesnimda merged commit b7d4b87d75 into develop 2026-07-02 17:36:28 +02:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: cesnimda/Inboxintel#34