Optional
fields: Partial<MistralAIEmbeddingsParams>The API key to use.
The maximum number of documents to embed in a single request.
The format of the output data.
The name of the model to use.
The name of the model to use.
Alias for model
.
Whether to strip new lines from the input text. This is recommended, but may not be suitable for all use cases.
Optional
endpointOverride the default endpoint.
Method to generate embeddings for an array of documents. Splits the documents into batches and makes requests to the MistralAI API to generate embeddings.
Array of documents to generate embeddings for.
Promise that resolves to a 2D array of embeddings for each document.
Class for generating embeddings using the MistralAI API.