feat(ai): implement Firebase JS SDK 12.15.0 portable API parity#9065
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request brings the @react-native-firebase/ai package into parity with the Firebase JS SDK 12.15.0. It introduces several key features including image generation configuration, Google Maps grounding tools, and robust session resumption capabilities for live AI interactions. These changes ensure that developers have access to the latest AI features while maintaining consistency with the core Firebase SDK. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
Add image config, Google Maps grounding, retrieval config, live session resumption, context window compression, and template tool config to match the firebase-js-sdk AI public surface for React Native.
f869e38 to
57e7dc0
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #9065 +/- ##
============================================
+ Coverage 60.90% 60.94% +0.05%
Complexity 1602 1602
============================================
Files 456 457 +1
Lines 33627 33665 +38
Branches 5411 5479 +68
============================================
+ Hits 20477 20514 +37
- Misses 11978 12019 +41
+ Partials 1172 1132 -40
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
final push was docs only - good to merge after lints |
2cf30fd to
4896f45
Compare
Description
Closes the portable AI API gaps introduced with Firebase JS SDK 12.15.0 in
@react-native-firebase/ai, aligning types and runtime behavior with the firebase-js-sdk AI public surface where React Native can support them.Changes include image generation config, Google Maps grounding types/tools, retrieval and template tool config, live session resumption (
connectionPromise,resumeSession, resumption updates inreceive()), context window compression setup, extendedFinishReasonvalues, and compare-types config updates for the newly implemented APIs. Browser-only APIs (Chrome on-device AI, audio conversation helpers, hybrid inference) remain intentionally absent.Related issues
Release Summary
AI package parity with firebase-js-sdk 12.15.0 for image config, Google Maps grounding, retrieval config, live session resumption, context window compression, and template tool config.
Checklist
AndroidiOSOther(macOS, web)e2etests added or updated inpackages/**/e2ejesttests added or updated inpackages/**/__tests__Test Plan
yarn compare:types ai— all diffs documented (28 remaining intentional gaps)yarn tests:jest packages/ai/__tests__— 322/322 passedyarn test:full— install, builds, lint, compare:types, jest, and E2E on iOS/Android/macOS all passed; AI e2e (fetch,fetch stream) green on all platformsThink
react-native-firebaseis great? Please consider supporting the project with any of the below:React Native FirebaseandInvertaseon Twitter