Based on xb/doc/CUSTOM_VECTOR_DB_GUIDE.md. It captures best practices for building vector-database adapters with the Custom interface.
| Concern | Recommendation |
|---|---|
| Payload schema | Define Go structs that mirror the DB JSON to avoid map juggling |
| Filter encoding | Reuse built.FilterJSON() where possible |
| Vector serialization | Accept both []float32 and pre-normalized vectors |
| Pagination | Support limit, offset, scroll_id according to backend |
NewQdrantBuilder() – official referenceNewMilvusBuilder() – include server endpoint + GRPC options (future implementation)NewWeaviateBuilder() – handles class names + where filters (future implementation)Expose variations like HighPrecision, HighRecall, or HighSpeed tuned for specific workloads.
| Builder feature | Vector DB mapping |
|---|---|
VectorSearch |
search/recommend API |
Eq/In |
filter must clauses |
Meta |
request-level metadata (trace, tenant) |
Limit, Offset |
limit, offset, scroll |
Document unsupported combinations so callers know when to fall back to raw APIs.
doc/en/QDRANT_GUIDE.mddoc/en/VECTOR_GUIDE.mddoc/en/AI_APPLICATION.md