Set the
GEMINI_API_KEY environment variable before calling any factory function below.
The key is read at UDF creation time and serialized with the UDF — no cluster-level
env_vars configuration is needed.Embeddings
Embed text with optional task-type hints for retrieval, classification, and clustering scenarios. See the API reference for all parameters. Multiple embeddings tuned for different retrieval tasks:Generation
Generate text from Gemini models. Supports text, image, audio, video, and document inputs. See the API reference for all parameters. Enrich a table with sentiment, captions, and transcriptions at once:API Reference
- Gemini —
gemini_udf()parameters:column,prompt,model,mime_type, and more - Embeddings —
gemini_embedding_udf()parameters:column,model,task_type,dimensionality,normalize