Skip to main content
*EncryptedIndex exposes index settings and training status as methods. Every getter except GetIndexName takes a context.Context and calls the service’s describe or training-status endpoint. Nothing is cached, so each call returns the current value.

GetIndexName

The index’s name. Read locally, with no network call.

Dimension

Vector dimensionality. Returns 0 if the index was created without a Dimension and nothing has been upserted yet.

Metric

Distance metric: "euclidean", "squared_euclidean", or "cosine".

NLists

Number of IVF lists. 1 for an untrained index; the trained list count after Train.

MetadataSchema

The per-field indexing policy set with MetadataSchema or TextFields in CreateIndex. Never nil: an empty map when the index uses the default policy. The MetadataFieldPolicy fields are *bool; read them with GetFilterable(), GetPattern(), and GetFullText().

BM25

The index’s BM25 settings, or nil (with a nil error) when it has no full-text fields.

IsTrained

true if the index has been trained.

IsTraining

true while the service is training this index or has it queued for training. Requires the root key: with a per-user key the service returns HTTP 403 and the SDK returns *AuthenticationError.