BigQuery’s built-in EmbeddingGemma 2 adds a token charge without an Agent Platform endpoint
The AI.EMBED preview runs inside BigQuery and costs $0.02 per million input tokens on top of query compute. Built-in processing does not guarantee query-region residency.
BigQuery now offers EmbeddingGemma 2 in preview as a built-in model for AI.EMBED. The new option takes text or code and returns a 768-dimensional vector. It runs inside BigQuery without sending the input to Gemini Enterprise Agent Platform, but it does not make embedding generation a compute-only expense. Google’s function reference and pricing page list a separate model input-token charge.
The query project pays two charges
Google lists $0.02 per million input tokens, in addition to standard BigQuery query compute under on-demand or editions pricing. Output vectors, empty strings and NULL inputs do not incur model token charges. Non-empty strings are truncated at 8,192 tokens, and tokens past that limit are not billed. The older built-in embeddinggemma-300m is documented as compute-only, so switching between the two built-in options changes the billing model even if the query still runs in BigQuery. Function billing and permissions
Built-in does not mean region-bound
The function uses model => 'embeddinggemma-2', not an endpoint argument. It requires BigQuery job and source-table permissions, but no Cloud resource connection or Agent Platform role. Google commits to US processing for US query locations and EU processing for the EU multi-region and qualifying EU regions. For other locations, explicitly including europe-west2 and europe-west6, Google makes no residency commitment and says processing may occur outside the query region. The model is not available in Assured Workloads projects. Function reference
Test the retrieval pipeline, not just the SQL call
For teams embedding table descriptions or SQL examples for an analytics agent, changing the function call is only the first step. Google warns that vectors from different models are generally incompatible. A 768-element result is not a reason to compare it with vectors already stored from another model. Build a parallel set of corpus embeddings, generate test-query vectors with the same model, and compare which tables or examples land in the top results before switching production retrieval. Check any long inputs for truncation and omit task_type for this model. Those tests are rollout recommendations, not evidence that the preview improves text-to-SQL accuracy. Function reference
sources
- Google Cloud: AI.EMBED function referencedocs.cloud.google.com
- Google Cloud: EmbeddingGemma 2 pricing on BigQuerycloud.google.com
comments · 0