Embeddings Google Vertex Extended
AI-generatedSummary
Generate text embeddings by calling Google Vertex AI Generative Embeddings API with specified model, output dimensions, and task type. Support processing documents in batches and returning embeddings for queries or multiple documents.
Inputs
- Project ID (required) — The Google Cloud project ID to use for API requests.
- Model Name — The name of the Vertex AI model used to generate embeddings (e.g., text-embedding-004).
- Output Dimensions — The number of dimensions for output embeddings; 0 means use the model's default dimension. Only supported by certain models like text-embedding-004.
- Batch Size — The number of documents to process per API request. This node currently enforces batchSize=1 for embedding documents, but can handle multiple asynchronously.
- Options — Additional options including Region where the model is deployed and Task Type specifying the embedding's purpose (e.g., Retrieval Document, Semantic Similarity, Classification).
Output shape
an object implementing embedQuery(string) and embedDocuments(string[]) methods that return embedding vectors for input text or documents.
Output is an AI embedding object, wrapped to log input and output data within the workflow. When embedding multiple documents, batch size controls processing method, defaulting to individual requests for each document due to API constraints. Errors during batch processing fallback to single document embedding.