Enterprise only
LanceDB Enterprise separates query planning from index execution and data reads
so that search can use the memory, CPU, and caches of multiple machines. A query
node plans and coordinates a query. Executors search indexes, read table
data, and return partial results for the query node to combine.
For the service components and overall request paths, see
Architecture.
Search architecture
LanceDB Enterprise prioritizes horizontal scalability. Index execution on a single node can be limited by the memory available to cache the index for fast search and by the CPU available to execute queries. Dividing one logical index into multiple index segments lets each segment be distributed to an executor, cached independently, and searched in parallel with other segments. The two serving components have different responsibilities:
Eligible scalar index operations can also execute on executors. See scalar
indexes and
filtering for index types and query
syntax.
For example, consider a vector index with six segments served by three
executors. Each executor searches its two segments and returns its best 10
candidates. The query node compares the candidates returned by all three
executors and selects the final 10. This example assumes enough matching rows
and the default search path without additional reranking.
When a vector index has a single large segment or a few skewed segments that
would otherwise concentrate search work on one executor, eligible IVF queries
with enough probed partitions can also fan out partitions of that segment across
multiple executors. The segment’s primary executor ranks candidate centroids
once, and the query node routes the selected IVF partitions deterministically
across the segment’s executor shard pool before merging top-k candidates. Small
probe budgets and balanced multi-segment indexes continue to execute directly on
each segment’s primary executor without extra coordination.
Tiered index cache
Executors cache index structures in memory, and extend that cache onto local disk when the disk tier is enabled. See Tiered Index Cache for how the two tiers work together and how the disk tier’s budget is shared and sized; ask your deployment operator about enabling it on your cluster.Create and query an IVF-RQ index
Use the regular table API. These examples assumetable is an open Enterprise
table with a vector column and the query vector is compatible with that
column. For connection setup, see connect to
LanceDB.
You can create an index before filling a vector column, including an all-NULL
Function column on a populated table. The index definition is registered, but
training waits until enough non-NULL vectors exist (IVF_PQ also needs enough
vectors to train its codebook). Refresh the Function to populate its output;
automatic index maintenance then trains the index. Index statistics report
num_indexed_rows=0 until rows are indexed. Check this count before relying on
index coverage.
num_bits, index
creation
parameters,
and vector
search.
For the fast, normal, and accurate latency/recall modes, see tuning
approx_mode.
The Rust SDK currently exposes that query setting; the examples above use the
default mode.
Distributed full-text search
FTS work is organized by inverted index and fragment ownership. Compatible single-column operations execute together on executors over that index’s segments. Eligible compound, cross-column (Boolean and Boost), and hybrid
(indexed segments plus unindexed tail fragments) queries also execute directly
on executors over disjoint fragment ownership sets:
- The query node assigns each fragment to a single executor, preserving index segment placement and data-file page cache affinity.
- Each executor task evaluates the query over its assigned segments or owned
fragments and returns at most
limittop candidates (in global scoring mode, mask-budget chunking can split an executor’s segments into multiple tasks, each returning up tolimitcandidates). - The query node merges the bounded candidate streams with deterministic
(_score DESC, _rowid ASC)ordering and applies the final top-k.
Local and global scoring
Distributed FTS defaults to local scoring. For indexed and compound searches, each executor uses statistics from its assigned segments—or, when an eligible large or skewed multi-partition segment is split across executors by its physical postings partitions, from that executor’s assigned postings partitions—and its assigned unindexed fragments (for hybrid or partial-index queries) to calculate BM25 scores. This executes in a single search round without a statistics barrier, though document frequencies and average document lengths can differ between executors, so merging their scores can produce a different ranking from scoring with statistics across the entire index. Global scoring adds a statistics round before search so every executor scores with consistent corpus-wide BM25 statistics:- For indexed and cross-column searches, the query node gathers document counts, token counts, and query-term document frequencies per column across all committed index segments.
- For hybrid and partial-index compound searches whose unindexed residual fragments span multiple executors, the statistics round also gathers per-executor residual token statistics in parallel and seeds each executor with the combined committed and peer-residual statistics.
Distributed data search
A table can be larger than any single node’s local storage. Enterprise keeps the durable table in object storage and distributes data reads and caches across executors. An executor needs capacity for its cached working set rather than a complete local copy of the table. With fragment-based data routing, reads for a data fragment go to a serving executor. Different fragments can be served and cached on different executors. The following example shows six fragments served by three executors:NVMe data caching
The data page cache stores pages read from table fragments on local disk, including NVMe SSDs. On a cache hit, the executor reads the page from local disk; on a miss, it fetches the page from object storage and fills the cache for subsequent reads. The cache holds accessed pages, not necessarily every byte of each fragment assigned to an executor. See Data Page Cache for how it’s structured and sized.Inspect execution
Useanalyze_plan() (analyzePlan() in TypeScript) to understand how a query
executes and troubleshoot slow searches. It runs the query and returns the
execution plan with runtime metrics. Using the same table and query vector as
above: