Skip to content

feat(firebase-ai): add inlineData support to Developer API #17600

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 6, 2025

Conversation

ryanwilson
Copy link
Member

@ryanwilson ryanwilson commented Aug 5, 2025

Description

The Developer API was missing support for inlineData parts, which was already implemented in the Vertex AI API.

This change copies the inlineData parsing logic from the Vertex AI parsePart function to the _parsePart function in the Developer API.

The existing test file, developer_api_test.dart, has been updated to include a test case for parsing inlineData parts, ensuring the functionality is working as expected.

Tested in the iOS simulator with a manual change to the sample (not included, since it likely warrants further example changes)
Simulator Screenshot - iPhone 16 Pro - 2025-08-05 at 21 37 34

Related Issues

Fixes #17449
There was a previous attempt at this but it was closed: #17451

Checklist

Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]).
This will ensure a smooth and quick review process. Updating the pubspec.yaml and changelogs is not required.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See Contributor Guide).
  • All existing and new tests are passing.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (melos run analyze) does not report any problems on my PR.
  • I read and followed the Flutter Style Guide.
  • I signed the CLA.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require plugin users to manually update their apps to accommodate your change?

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

The Developer API was missing support for  parts, which was already implemented in the Vertex AI API.

This change copies the  parsing logic from the Vertex AI  function to the  function in the Developer API.

An existing test file, , has been updated to include a test case for parsing  parts, ensuring the functionality is working as expected.
@ryanwilson ryanwilson marked this pull request as ready for review August 6, 2025 01:44
@ryanwilson ryanwilson changed the title feat(dev-api): add inlineData support to Developer API feat(firebase-ai): add inlineData support to Developer API Aug 6, 2025
@ryanwilson ryanwilson merged commit 5199edb into main Aug 6, 2025
36 checks passed
@ryanwilson ryanwilson deleted the feat/dev-api-filepart branch August 6, 2025 13:08
gspencergoog pushed a commit to gspencergoog/flutterfire that referenced this pull request Aug 14, 2025
The Developer API was missing support for  parts, which was already implemented in the Vertex AI API.

This change copies the  parsing logic from the Vertex AI  function to the  function in the Developer API.

An existing test file, , has been updated to include a test case for parsing  parts, ensuring the functionality is working as expected.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🚀 [firebase_ai] FirebaseAI.googleAI() Does not support generating images
4 participants