Database endpoints
Build an IVF-PQ index
Train a compressed IVF-PQ index from the vectors already stored in a table.
POST /v1/tenants/{tenant}/vector/{table}/create-ivf-pq-index
- Start with stored vectorsChoose the table and compression preset.
- Train the compressed indexBuild the IVF-PQ representation from those vectors.
- Check training and installationInspect whether raw vectors were retained.
Before you start
Use your database bearer token.
Provide enough compatible stored vectors to train the index. Three-value toy examples alone do not establish training readiness. Review drop_raw_vectors before discarding raw data.
Path parameters
| Field | Type | Required |
|---|---|---|
tenant | string | Required |
table | string | Required |
Headers
| Field | Type | Required | Description |
|---|---|---|---|
x-oc-db-user | string | Optional | Acting database user (role, grant and row-policy checks). Send with x-oc-db-key. |
x-oc-db-key | string | Optional | API key of the x-oc-db-user user. |
Request body
application/json
Limits and accepted values
- preset: high_recall | compressed.
- seed defaults to 0.
- drop_raw_vectors (default false) irreversibly discards the stored raw vectors table-wide, keeping only compressed codes;
- refused with 400 for the high_recall preset.
| Field | Type | Required |
|---|---|---|
drop_raw_vectors | boolean | Optional |
preset | string | Required |
seed | integer | Optional |
Read the result
trained and installed report the training outcome. Check raw_vectors_retained before relying on exact refinement later. Setting drop_raw_vectors discards the original vectors irreversibly.
Response statuses
HTTP status reference
| Status | What to do |
|---|---|
| 200 | OK |
| 400 | Correct the request before retrying. |
| 401 | Check the credential and Authorization header. |
| 402 | Check feature access or available credits. |
| 403 | Check tenant access, roles and permissions. |
| 409 | Resolve the conflict before retrying. |
| 413 | Split or reduce the request body. |
| 415 | Send the required Content-Type. |
| 422 | Correct the values or unsupported combination. |
| 429 | Honor Retry-After when present; back off. |
| 500 | Check the outcome before retrying a write. |
| 501 | Check deployment support for this operation. |
| 503 | Honor Retry-After when present; check write outcomes. |