hosting

POST /v1/vector/indexes

Create a vector index.

Барлық hosting соңғы нүктелері

Аутентификация

API кілтін bearer токені ретінде жіберіңіз. Кілтте vector.manage рұқсаты болуы тиіс; онсыз кілтке 404 емес, 403 қатесі қайтарылады.

Бұл соңғы нүкте ұйым идентификаторын қабылдамайды. Сіздің кілтіңіз оның қай ұйымға тиесілі екенін өзі анықтайды және жауап соған шектеледі.

Әрекет етіп көру

Бұрыштық жақшалардағы кез келген нәрсені өз мәндеріңізбен, ал кілт орналастырушысын басқару тақтасынан алынған кілтпен алмастырыңыз.

curl -X POST https://api.zinndigital.com/v1/vector/indexes \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "name": <string>, "dimension": <integer> }'

Жүйеге кіргенсіз бе? Бақылау тақтасындағы API консолі ұйымыңыздың нақты идентификаторы мен жеке кілтіңізді автоматты түрде толтырады да, нақты жауапты көре алуыңыз үшін сұрауды тікелей жұмыс істеп тұрған API арқылы орындайды. Бұл соңғы нүктені API консолінде ашыңыз

Мәліметтер

Creates an index of a fixed width and distance function. `dimension` is whatever your embedding model emits, from 1 to 3072 — it does not have to be a round number, and a width we do not store natively is held exactly rather than approximately. Above 2000 dimensions the index is stored at half precision, because pgvector's HNSW index does not accept a full-precision column wider than that. Requires `vector.manage`, and is refused if the plan's `vector_indexes` allowance is full.

Сұрау денесі

АтыTүріМіндеттіМазмұны
namestringИә
dimensionintegerИә
metricstring<cosine, l2, inner_product>Жоқ

Жауап

АтыTүріМіндеттіМазмұны
idstringИә
namestringИәLower-case, hyphenated, unique within the organisation.
dimensionintegerИәThe width your embedding model emits, and the width reads return. Fixed at creation.
metricstring<cosine, l2, inner_product>ИәThe distance function. Fixed at creation.
statusstring<ready, deleting>Иә
vectorsintegerИәHow many vectors the index holds.
storage_bytesintegerИәWhat the index counts for against `vector_index_gb`. A published formula rather than a physical table size, so it is reproducible: 96 bytes of row overhead, plus the stored widt…
created_atstringИә

Бұл соңғы нүкте қайтара алатын қателер

401 · 403 · 422 · 429