Skip to main content

One post tagged with "neural-sparse"

View All Tags

Neural Sparse Search in OpenSearch: Semantic Matching Without a GPU

· 5 min read
FoundryDB Team
Engineering @ FoundryDB

Dense vector search (k-NN) is powerful but requires embedding both documents and queries with a neural model at query time. Neural sparse search takes a different approach: expand tokens with learned weights at index time, store them as a rank_features field, and at query time do a fast lookup rather than a vector computation. The result is semantic search with no GPU requirement at query time. This post shows the full setup on a live OpenSearch 2.19.1 cluster managed by FoundryDB.

All commands use YOUR_OPENSEARCH_HOST and YOUR_PASSWORD as placeholders.

pgvector similarity search · query → HNSW → top-k
TOP-K vector → HNSW index → filter → nearest rows
Queryvector | textANN · HNSWcosine <=>AND filter →Top-kby distance
Query / top-kServer-side embedANN search · tableHNSW indexEquality filter (WHERE)index / predicate edge (dashed)