Skip to content

Add a VectorDBBench client for Infino (vector search) - #863

Open
muralikpbhat wants to merge 2 commits into
zilliztech:mainfrom
muralikpbhat:infino-client-upstream
Open

Add a VectorDBBench client for Infino (vector search)#863
muralikpbhat wants to merge 2 commits into
zilliztech:mainfrom
muralikpbhat:infino-client-upstream

Conversation

@muralikpbhat

Copy link
Copy Markdown

What

Adds a VectorDBBench client for Infino, an object-storage-native retrieval engine with a Python binding (the infino package). This PR covers vector search; FTS is a planned follow-on.

Client

  • InfinoConfig / InfinoIndexConfig — connection tuning (catalog path, disk-cache budget/dir, object-store options) and the vector case config (cosine / L2 / inner-product metric map).
  • search_mode (default hnsw_ivf) — the serving path, bridged to the engine's vector.search_mode config key rather than the binding API (so nothing goes vestigial if an engine default changes). hnsw_ivf serves a resident HNSW graph over the quantized vectors (with automatic IVF fallback); ivf serves the reclaimable IVF scan.
  • ef (default 0) — a serve-time HNSW beam, bridged to vector.hnsw_ef_search. 0 serves each query at the graph's stamped k→ef curve; a positive value fixes the beam. See "Tracing the recall/QPS curve" below.
  • Batched insertsinsert_embeddings buffers fed rows and commits them as one large append at a threshold (flushing any remainder when the load scope exits), so a load commits a handful of files regardless of the harness batch size instead of one file per fed batch. Insert speed is independent of NUM_PER_BATCH; the served index is unchanged.
  • Runner — uses the stock MultiProcessingSearchRunner. The engine memory-maps its graph and shares one physical copy across reader processes via the page cache, so process-per-worker doesn't multiply the graph in RAM (no custom runner needed).
  • _id → dataset-id map — built once per table, persisted beside the catalog, reloaded by each worker; invalidated on drop_old so a re-ingest remaps correctly.
  • Cosine cases are normalized (need_normalize_cosine). Vector-only / NonFilter.

Tracing the recall/QPS curve

Because ef is a serve-time beam, the recall/QPS curve is traced build once, sweep at serve — the same one-ingest / serve-many shape as Zilliz's level or an HNSW engine's ef_search, so no re-ingest per point:

  1. Ingest + build once (--drop-old).
  2. Re-run search-only per beam (--skip-drop-old --skip-load), varying --ef over e.g. 128 192 256 384 512 768 1024 1536 2048 — a spread of operating points, densest near the top.

A plain run with no --ef (ef=0) serves at the graph's stamped k→ef curve — a single high-recall operating point (recall@100 ≈ 0.997 on Cohere-1M) — so infino produces a strong default point even without a sweep.

Registration

DB.Infino enum + init_cls / config_cls / case_config_cls; the Infino CLI command; a leaderboard color; and an infino optional-dependency extra (infino>=0.5.6).

Testing

  • Unit tests: search_mode / ef validation, the config.yaml bridging, and insert-buffering (every fed row persisted across both the threshold flush and the final flush of a sub-threshold remainder).
  • End-to-end: insert_embeddingssearch_embedding round-trip (nearest-neighbor identity), plus a full Cohere-1M (768-dim) build-once ef sweep on hnsw_ivf tracing the recall/QPS curve.

Notes

  • On-disk nothing changes upstream; the client only adds files and small registration hooks (no changes to shared runners).
  • search_mode/ef are bridged through the engine config file because connect() currently exposes no equivalent keyword; the client writes a per-run config and points XDG_CONFIG_HOME at it before connecting.
  • A follow-up will expose search_mode/ef as run-test UI inputs (frontend/config/dbCaseConfigs.py); this PR keeps the surface to the client and its registration.

VectorDBBench feeds inserts in small batches (default 100 rows) and each
append() commits a superfile, so a large load fragmented into thousands of
tiny superfiles — slow to load and slow to optimize. Buffer fed rows and
commit them as one combined append at 100k rows, flushing any remainder when
the load's init() scope exits (the same subprocess that inserted them), so a
corpus smaller than the threshold is still fully persisted. Insert speed is
now independent of the harness batch size; the served index is unchanged.

Also fix the ef case-config test, which called index_param() without a
metric_type and raised before reaching its assertion.
@sre-ci-robot

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: muralikpbhat
To complete the pull request process, please assign xuanyang-cn after the PR has been reviewed.
You can assign the PR to them by writing /assign @xuanyang-cn in a comment when ready.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants