| Modifier and Type | Method and Description |
|---|---|
static VSimArgs |
count(Long count)
Creates new
VSimArgs and setting COUNT. |
static VSimArgs |
explorationFactor(Long explorationFactor)
Creates new
VSimArgs and setting EF. |
static VSimArgs |
filter(String filter)
Creates new
VSimArgs and setting FILTER. |
static VSimArgs |
filterEfficiency(Long filterEfficiency)
Creates new
VSimArgs and setting FILTER-EF. |
static VSimArgs |
noThread()
Creates new
VSimArgs and setting NOTHREAD. |
static VSimArgs |
truth()
Creates new
VSimArgs and setting TRUTH. |
public static VSimArgs count(Long count)
VSimArgs and setting COUNT.
The COUNT option limits the number of returned results to the specified value.
count - the number of results to return.VSimArgs with COUNT set.VSimArgs.count(Long)public static VSimArgs explorationFactor(Long explorationFactor)
VSimArgs and setting EF.
The EF (exploration factor) option controls the search effort. Higher values explore more nodes, improving recall at the cost of speed. Typical values range from 50 to 1000.
explorationFactor - the exploration factor for the vector search.VSimArgs with EF set.VSimArgs.explorationFactor(Long)public static VSimArgs filter(String filter)
VSimArgs and setting FILTER.
The FILTER option applies a filter expression to restrict matching elements. Filter expressions can be used to narrow down search results based on attributes.
filter - the filter expression to apply.VSimArgs with FILTER set.VSimArgs.filter(String),
Filter expressionspublic static VSimArgs filterEfficiency(Long filterEfficiency)
VSimArgs and setting FILTER-EF.
The FILTER-EF option limits the number of filtering attempts for the FILTER expression. This controls the maximum effort spent on filtering during the search process.
filterEfficiency - the maximum filtering effort to use.VSimArgs with FILTER-EF set.VSimArgs.filterEfficiency(Long),
Filter expressionspublic static VSimArgs truth()
VSimArgs and setting TRUTH.
The TRUTH option forces an exact linear scan of all elements, bypassing the HNSW graph. This is useful for benchmarking or to calculate recall. Note that this is significantly slower with a time complexity of O(N) instead of O(log(N)).
VSimArgs with TRUTH set.VSimArgs.truth()public static VSimArgs noThread()
VSimArgs and setting NOTHREAD.
The NOTHREAD option executes the search in the main thread instead of a background thread. This is useful for small vector sets or benchmarks, but may block the server during execution and increase server latency.
VSimArgs with NOTHREAD set.VSimArgs.noThread()Copyright © 2025 lettuce.io. All rights reserved.