Optional
gradientGradient AI Access Token. Provide Access Token if you do not wish to automatically pull from env.
Optional
workspaceGradient Workspace Id. Provide workspace id if you do not wish to automatically pull from env.
Method to generate embeddings for an array of documents. Splits the documents into batches and makes requests to the Gradient 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 Gradient AI's API. Extends the Embeddings class and implements GradientEmbeddingsParams and