XVector
xvec_ivf_flat_index.hpp File Reference

C++ RAII wrapper for the XVECTOR IVF-Flat index. More...

#include <string>
#include "xvector/xvec_ivf_flat.h"
#include "xvector/xvec_types.h"
#include "xvector_cpp/xvec_error.hpp"
Include dependency graph for xvec_ivf_flat_index.hpp:

Go to the source code of this file.

Classes

class  xvec::IvfFlatIndex
 RAII wrapper for xvecIvfFlatIndexTag. More...
 

Namespaces

 xvec
 

Detailed Description

C++ RAII wrapper for the XVECTOR IVF-Flat index.

// Load from Faiss file (RAII)
auto index = xvec::IvfFlatIndex::fromFaissFile(ctx.handle(), "index.faiss");
// Use raw handle for C API interop
xvecIvfFlatSearchFineSearchOnly(ctx.handle(), index.handle(), &query, resultBuf, &timing);
// Index is automatically destroyed when out of scope
static IvfFlatIndex fromFaissFile(xvecExecutionContextTag *context, const std::string &path)
Load an IVF-Flat index from a Faiss file.
xvecStatus xvecIvfFlatSearchFineSearchOnly(xvecExecutionContextTag *context, xvecIvfFlatIndexTag *indexHandle, xvecIvfFlatFineSearchQueryFloat32 *fineSearchQuery, xvecBufferTag *resultsBufferHandle, xvecIvfFlatSearchTiming *outTiming)
Performs an IVF-Flat fine search only (skips coarse search).
C++ RAII wrapper for the XVECTOR IVF-Flat index.

Definition in file xvec_ivf_flat_index.hpp.