How we selected the next vector database at Booking.com
Booking.com replaced its OpenSearch-backed internal Embedding Service with Weaviate after running its own production-shaped benchmark instead of trusting public comparisons. The evaluation used 100M all-MiniLM-L6-v2 embeddings built from Amazon Reviews 2023, with full and filtered approximate KNN plus a mixed workload including 20% writes, at 5 to 100 concurrent clients. Every system was tuned to about 0.99 recall and compared mainly on P99 latency. Dedicated vector databases gave lower tail latency and better scaling under concurrency, with roughly 40% lower compute and memory cost. Because clients already reached storage only through an internal service, most teams migrated with just a configuration change.
Related posts
- Under the hood of Booking.com’s search engine
Booking.com Engineering mediumAdeptBooking.com’s search engine generates personalised hotel offers at request time instead of precomputing and indexing every possible room/date/price combination, which would be combinatorially infeasible. A single request stitches per-night availability, evaluates 1,000+ declarative pricing rules in memory, ranks thousands of offers in stages, and handles group bookings as a constrained knapsack-like problem. The system runs as a custom scatter-gather database: coordinator nodes fan searches out to data nodes storing data in RocksDB, with no network calls on the hot path. The accepted tradeoffs are brief availability inconsistency for faster search, full coverage at the cost of query skew, and low latency with complex logic in exchange for running replication and cluster health themselves.
- Matryoshka embeddings: faster OpenAI vector search using Adaptive Retrieval
Supabase mediumAdeptOpenAI's text-embedding-3 models are trained with Matryoshka Representation Learning, so an embedding can be shortened by truncating trailing dimensions and renormalizing, which reproduces the API's `dimensions` output. Adaptive Retrieval exploits this with a two-pass search: a fast HNSW-indexed ANN pass on a low-dimensional prefix fetches an oversized shortlist, then exact KNN on the full 3072d vectors re-ranks it. Benchmarks on 1M dbpedia embeddings found a 512d first pass (ef_construction=400, m=32, ef_search=200, limit = top_k × 8) reached 99% accuracy against 3072d KNN at about 580 QPS. By comparison, a single pass on 1536d vectors topped out near 89%. The post finishes with a Postgres/pgvector implementation using a sub_vector SQL function.
- Run Embedding Models and Unlock Semantic Search with Docker Model Runner
Docker mediumAdeptDocker Model Runner can serve embedding models locally, so semantic search and RAG pipelines run without sending private data to a hosted API and without per-call costs. Embeddings map text and code to vectors where semantically related items cluster, and cosine similarity ranks documents against a query. Getting started takes two steps: pull a model such as ai/qwen3-embedding, then call the OpenAI-style /engines/v1/embeddings endpoint on localhost. A sketched code-search workflow chunks a codebase, embeds the chunks, stores the vectors (a file in the demo, a vector database like Milvus, Qdrant or pgvector in practice) and ranks them by cosine similarity.
- You Don't Need A Separate Vector Database
Turso easyNoviceVector search belongs in your primary database rather than a separate system like Pinecone, because syncing embeddings across multiple stores adds cost and operational complexity. Turso's libSQL fork adds a native vector datatype (F32_BLOB) and DiskANN-based indexes with options like 1-bit neighbor compression. Similarity search can then be combined with ordinary SQL filters, and data and embeddings can be updated atomically in one transaction. Dedicated vector databases still offer re-ranking, hybrid scoring and compression, but many applications don't need them. Examples include on-device AI assistants and per-agent ephemeral databases.
- pgvector 0.4.0 performance
Supabase mediumAdeptWith tuned settings, pgvector 0.4.0's IVFFlat index handles 1M OpenAI embeddings (1536 dimensions, dbpedia dataset) at about 1800 QPS with 0.91 accuracy@10 on a 64-core, 256 GB instance, or about 670 QPS at 0.98 accuracy. Using the ANN Benchmarks methodology, the tests reproduce a default-config pgvector vs Qdrant comparison. Pre-warming RAM, using inner-product distance, raising lists to 2000 and increasing probes makes pgvector competitive, and throughput scales predictably with instance size. Practical guidance: raise lists above the recommended rows/1000 for faster queries at the cost of longer index builds and more maintenance_work_mem, prefer inner product for normalized embeddings, and benchmark with real rather than random vectors before right-sizing RAM.