@chinmaymk/aikit / GoogleEmbeddingOptions
Interface: GoogleEmbeddingOptions
Defined in: types.ts:282
Google Gemini-specific embedding options. Extends the base embedding options with Google-specific parameters.
Extends
Omit<EmbeddingProviderOptions,"taskType">
Properties
model?
optionalmodel:string
Defined in: types.ts:233
The specific embedding model you want to use. e.g., 'text-embedding-3-small' or 'text-embedding-004'.
Inherited from
Omit.model
dimensions?
optionaldimensions:number
Defined in: types.ts:235
The number of dimensions in the output embeddings. Only supported by some models.
Inherited from
Omit.dimensions
autoTruncate?
optionalautoTruncate:boolean
Defined in: types.ts:239
Whether to automatically truncate input text that exceeds the model's limit.
Inherited from
Omit.autoTruncate
apiKey?
optionalapiKey:string
Defined in: types.ts:248
API key for authentication with the provider.
Inherited from
Omit.apiKey
baseURL?
optionalbaseURL:string
Defined in: types.ts:250
Custom base URL for the API endpoint.
Inherited from
Omit.baseURL
timeout?
optionaltimeout:number
Defined in: types.ts:252
Request timeout in milliseconds.
Inherited from
Omit.timeout
maxRetries?
optionalmaxRetries:number
Defined in: types.ts:254
Maximum number of retry attempts for failed requests.
Inherited from
Omit.maxRetries
mutateHeaders()?
optionalmutateHeaders: (headers) =>void
Defined in: types.ts:260
A function that allows you to modify the headers before a request is sent. This is useful for adding custom headers or modifying existing ones.
Parameters
headers
Record<string, string>
The original headers object to mutate directly.
Returns
void
Inherited from
Omit.mutateHeaders
outputDtype?
optionaloutputDtype:"float"|"int8"|"uint8"|"binary"|"ubinary"
Defined in: types.ts:284
Output data type for the embeddings.
title?
optionaltitle:string
Defined in: types.ts:286
Optional title for the text when task type is 'document'.
taskType?
optionaltaskType:"RETRIEVAL_QUERY"|"RETRIEVAL_DOCUMENT"|"SEMANTIC_SIMILARITY"|"CLASSIFICATION"|"CLUSTERING"|"QUESTION_ANSWERING"|"FACT_VERIFICATION"|"CODE_RETRIEVAL_QUERY"
Defined in: types.ts:288
Task type specific to Google's API format.