Skip to main content
Version: 2.0

Create an encoder

POST 

/v2/encoders

Create a new encoder.

Request

Header Parameters

    Request-Timeout integer

    Possible values: >= 1

    The API will make a best effort to complete the request in the specified seconds or time out.

    Request-Timeout-Millis integer

    Possible values: >= 1

    The API will make a best effort to complete the request in the specified milliseconds or time out.

Body

    oneOf
    type string

    Default value: openai

    Specifies this is an OpenAI encoder

    name stringrequired

    The unique name of the encoder

    description stringrequired

    A description of what this encoder does

    output_dimensions int32required

    Possible values: >= 1

    The number of dimensions in the output embedding vector. If the encoder endpoint returns more dimensions than specified here, the response will be truncated to this number of dimensions.

    endpoint_url urirequired

    The URL of the OpenAI-compatible embedding endpoint

    model stringrequired

    The model name to use for embeddings

    auth object required

    Authentication configuration for an LLM

    oneOf
    type stringrequired

    Default value: bearer

    Must be "bearer" for bearer token auth

    token stringrequired

    The bearer token to use for authentication

Responses

The encoder has been created

Schema
    id string

    Possible values: Value must match regular expression enc_[0-9]+$

    The Encoder ID.

    name string

    The encoder name, boomerang-2023-q3.

    type string

    Default value: vectara

    The encoder type

    output_dimensions int32

    When this encoder is used to create an embedding, it shows the count of dimensions for the output embedding. A high dimensionality will consume more storage space, but it allows for an increase in the quality of the embedding.

    description string

    The encoder description.

    default boolean

    Indicates whether the default encoder is used when creating a corpus.

    enabled boolean

    Indicates whether the encoder is enabled.

Loading...