gemini_image.vertex | R Documentation |
Generate text from text and image with Gemini Vertex API
gemini_image.vertex(
image = NULL,
prompt = "Explain this image",
type = "png",
tokens = NULL,
temperature = 1,
maxOutputTokens = 8192,
topK = 40,
topP = 0.95,
seed = 1234
)
image |
The image to generate text |
prompt |
A character string specifying the prompt to use with the image. Defaults to "Explain this image". |
type |
A character string specifying the image type ("png", "jpeg", "webp", "heic", "heif"). Defaults to "png". |
tokens |
A list containing the API URL and key from token.vertex() function. |
temperature |
The temperature to use. Default is 1 value should be between 0 and 2 see https://ai.google.dev/gemini-api/docs/models/generative-models#model-parameters |
maxOutputTokens |
The maximum number of tokens to generate. Default is 8192 and 100 tokens correspond to roughly 60-80 words. |
topK |
The top-k value to use. Default is 40 value should be between 0 and 100 see https://ai.google.dev/gemini-api/docs/models/generative-models#model-parameters |
topP |
The top-p value to use. Default is 0.95 value should be between 0 and 1 see https://ai.google.dev/gemini-api/docs/models/generative-models#model-parameters |
seed |
The seed to use. Default is 1234 value should be integer see https://ai.google.dev/gemini-api/docs/models/generative-models#model-parameters |
A character vector containing Gemini's description of the image.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.