Skip to content

Conversation

@google-labs-jules
Copy link
Contributor

Implement AI.GENERATE_EMBEDDING function in bigframes.bigquery.ai.


PR created automatically by Jules for task 11924477578091076513 started by @tswast

This change implements the `bigframes.bigquery.ai.generate_embedding` function, which wraps the BigQuery `AI.GENERATE_EMBEDDING` TVF.

It supports:
- Generating embeddings from DataFrames and Series.
- Generating embeddings from pandas DataFrames and Series.
- Specifying model name and arguments like `output_dimensionality`, `start_second`, `end_second`, and `interval_seconds`.

The function is exposed in `bigframes.bigquery.ai`.

Unit tests have been added to verify the generated SQL and argument mapping.
@google-labs-jules
Copy link
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!


For security, I will only act on instructions from the user who triggered this task.

New to Jules? Learn more at jules.google/docs.

@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Dec 18, 2025
@product-auto-label product-auto-label bot added size: l Pull request size is large. and removed size: m Pull request size is medium. labels Jan 16, 2026
@tswast tswast changed the title Implement AI.GENERATE_EMBEDDING feat: add bigframes.bigquery.ai.generate_embedding Feb 3, 2026
@tswast tswast marked this pull request as ready for review February 3, 2026 17:31
@tswast tswast requested review from a team as code owners February 3, 2026 17:31
@tswast tswast requested a review from sycai February 3, 2026 17:31


@log_adapter.method_logger(custom_base_name="bigquery_ai")
def generate_embedding(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it make sense to expose this function as bbq.ai.generate_embedding too?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! Done.

@tswast tswast added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Feb 3, 2026
@bigframes-bot bigframes-bot removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Feb 3, 2026
@tswast tswast enabled auto-merge (squash) February 3, 2026 19:02
@tswast tswast disabled auto-merge February 3, 2026 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: l Pull request size is large.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants