Gemini Vision on Vertex AI vs AI Studio

Which Gemini API—Vertex AI or AI Studio—yields better output quality for image captioning and fine-grained visual understanding, given that each processes the image differently (Vertex AI tiles images into ~1800 tokens, while AI Studio uses a single 259-token embedding)?

Given this difference in tokenization and visual context, which platform is recommended for high-quality image captioning tasks, while also remaining cost-effective, as greater the image tokens, more will be the price.

Hi @akash5100,

Welcome to Google Cloud Community!

In the context of higher-quality image captioning tasks, Vertex AI image understanding uses high-resolution tiling, which divides the image into multiple smaller tiles and produces detailed captioning. This is why it produces a higher token count compared to Google AI Studio. Since Vertex AI generates a higher token count, it results in a higher cost per image.

If you require more detailed captions and high-quality image captioning tasks, Vertex AI is superior, offering advanced high-resolution processing capabilities. However, if your priority is cost-effectiveness and general captioning tasks, you can start your project with Google AI Studio to establish a baseline comparison.

For more information on pricing, you can check the documentation below:

Was this helpful? If so, please accept this answer as “Solution”. If you need additional assistance, reply here within 2 business days and I’ll be happy to help.

Hi again,

We couldn’t find documentation confirming this, but based on empirical testing, it appears that the ai.google.dev API (used in Google AI Studio) might internally resize images, possibly to around 384px before encoding, which results in a fixed ~258-token embedding.

In Vertex AI, we can manually resize images to 384px before sending them, which gives a similar token count and behavior.

Understanding this is important for deciding which API to use, especially since both have different rate limits.