Documentation Index
Fetch the complete documentation index at: https://docs.cyborg.co/llms.txt
Use this file to discover all available pages before exploring further.
Index Configuration Types
IndexIVF
Standard IVF (Inverted File) index configuration, ideal for balanced performance:| Speed | Accuracy | Memory Usage |
|---|---|---|
| Fast | Good | Medium |
IndexIVFFlat
IVFFlat index configuration, suitable for highest accuracy requirements:| Speed | Accuracy | Memory Usage |
|---|---|---|
| Medium | Highest | High |
IndexIVFPQ
IVFPQ (Product Quantization) index configuration, optimized for memory efficiency:| Speed | Accuracy | Memory Usage |
|---|---|---|
| Fast | Good | Low |
Both
pq_dim and pq_bits are required parameters for IndexIVFPQ. Unlike IndexIVF and IndexIVFFlat, these parameters must be explicitly specified.Vector Item Format
Dictionary format for upsert operations:Query Result Format
Results returned from query operations:Metadata Filtering
Thefilters parameter in query operations supports MongoDB-style operators:
Supported Operators
$eq: Equality ({"category": "research"})$ne: Not equal ({"status": {"$ne": "draft"}})$gt: Greater than ({"score": {"$gt": 0.8}})$gte: Greater than or equal ({"year": {"$gte": 2020}})$lt: Less than ({"price": {"$lt": 100}})$lte: Less than or equal ({"rating": {"$lte": 4.5}})$in: In array ({"tag": {"$in": ["ai", "ml"]}})$nin: Not in array ({"category": {"$nin": ["spam", "deleted"]}})$and: Logical AND ({"$and": [{"a": 1}, {"b": 2}]})$or: Logical OR ({"$or": [{"x": 1}, {"y": 2}]})
Filter Examples
Field Selection
Many operations support field selection through theinclude parameter:
Available Fields
vector: The vector data itselfcontents: Text or binary content associated with the vectormetadata: Structured metadata objectdistance: Similarity distance (query operations only, always included automatically)
The
id and distance fields are always included in query results regardless of the include parameter.Example Usage
Distance Metrics
Supported distance metrics for similarity calculations:cosine: Cosine similarity (recommended for normalized vectors)euclidean: Euclidean distance (L2 norm)squared_euclidean: Squared Euclidean distance (faster than euclidean)