-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Labels
Description
Question
What is the reason behind requiring explicit vchordrq.probes configuration for every query session?
Docker
Version: tensorchord/vchord-postgres:pg15-v1.0.0
docker-compose
services:
pgvecto-rs:
image: tensorchord/vchord-postgres:pg15-v1.0.0
restart: always
environment:
PGUSER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: demo
PGDATA: /var/lib/postgresql/data
command: ["postgres",
"-c", "shared_preload_libraries=vchord.so",
"-c", "search_path=public,vchord",
"-c", "max_connections=35",
"-c", "logging_collector=off"]
volumes:
- ./volumes/pgvectors/data:/var/lib/postgresql/data
ports:
- "5432:5432"
healthcheck:
test: [ "CMD", "pg_isready" ]
interval: 1s
timeout: 3s
retries: 30Observation
When using vchordrq indexes with different lists configurations, queries fail unless vchordrq.probes is manually configured before each query execution:
-- Index with lists = [2000]
CREATE INDEX idx_with_lists ON table_a USING vchordrq (embedding vector_cosine_ops)
WITH (options = $$[build.internal] lists = [2000]$$);
-- Query fails without manual configuration
SELECT * FROM table_a ORDER BY embedding <=> query_vec LIMIT 5;
-- ERROR: need 1 probes, but 0 probes provided
-- Must manually set probes first
SET vchordrq.probes = 10;
SELECT * FROM table_a ORDER BY embedding <=> query_vec LIMIT 5; -- Now worksSimilarly, for indexes with lists = [], an empty string must be explicitly set:
-- Index with lists = []
CREATE INDEX idx_without_lists ON table_b USING vchordrq (embedding vector_cosine_ops)
WITH (options = $$[build.internal] lists = []$$);
-- Query fails without manual configuration
-- ERROR: need 1 probes, but 0 probes provided
-- Must explicitly set empty probes
SET vchordrq.probes = '';
SELECT * FROM table_b ORDER BY embedding <=> query_vec LIMIT 5; -- Now worksSummary of Current Behavior
Index lists Configuration |
Required Manual Setting | Error Without Setting |
|---|---|---|
lists = [] |
SET vchordrq.probes = ''; |
need 1 probes, but 0 provided |
lists = [N] (N > 0) |
SET vchordrq.probes = M; (where M ≥ 1) |
need 1 probes, but 0 provided |
Any clarification on the design philosophy and recommended workarounds would be greatly appreciated.