Skip to main content

cuvs/
lib.rs

1//! Runtime-bound safe Rust integration for the scoped cuVS surface used by Algeon.
2//!
3//! Published as an Algeon implementation dependency. Applications use
4//! [`algeon-datafusion`](https://docs.rs/algeon-datafusion); workspace code
5//! uses this crate for its component contracts. See the
6//! [API documentation boundary](https://algeon.dev/design#api-documentation).
7
8mod brute_force;
9mod cagra;
10mod device;
11mod dlpack;
12mod elements;
13mod error;
14mod ivf_flat;
15mod ivf_pq;
16mod kmeans;
17mod pairwise;
18mod params_handle;
19mod pca;
20mod prepared;
21mod resources;
22mod select_k;
23
24pub use brute_force::{BruteForceIndex, DistanceMetric, KnnSearchOutput};
25pub use cagra::{CagraBuildAlgo, CagraIndex, CagraIndexParams, CagraSearchAlgo, CagraSearchParams};
26pub use device::{
27    DeviceBuffer, DeviceElement, DeviceTensor, DeviceTensorMut, MatrixLayout, OwnedMatrix, ValidatedDeviceTensor,
28};
29pub use elements::{CagraElement, IvfElement, KMeansElement, PairwiseElement};
30pub use error::{Error, ErrorKind, ErrorStatus, Result};
31pub use ivf_flat::{IvfFlatIndex, IvfFlatIndexParams, IvfFlatSearchParams};
32pub use ivf_pq::{IvfPqCodebookKind, IvfPqIndex, IvfPqIndexParams, IvfPqSearchParams};
33pub use kmeans::{KMeansFit, KMeansInit, KMeansMetric, KMeansModel, KMeansParams, KMeansPrediction};
34pub use pairwise::pairwise_distance_into;
35pub use pca::{PcaFitTransform, PcaOutputBuffers, PcaParams, PcaSolver, fit_transform_owned};
36pub use prepared::{PreparedTensorLease, PreparedValidatedTensorLease};
37pub use resources::{CuvsResources, StreamPoolCoverage};
38pub use select_k::select_k_into;