Skip to content

Add Hybrid Inference #3

Merged
marinacoelho merged 4 commits intomainfrom
feature/hybrid-inference
Apr 1, 2026
Merged

Add Hybrid Inference #3
marinacoelho merged 4 commits intomainfrom
feature/hybrid-inference

Conversation

@marinacoelho
Copy link
Copy Markdown
Contributor

This PR introduces hybrid inference to extract ingredients from an image.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces hybrid AI inference capabilities by integrating Firebase AI On-Device and Firebase Performance Monitoring. Key changes include the addition of the generateIngredientsHybrid method in AIRemoteDataSource, which utilizes both cloud and on-device models based on Remote Config, and the implementation of loadOnDeviceModel to manage model downloads. Feedback focuses on optimizing resource usage by caching the GenerativeModel instance, improving error logging during model downloads, ensuring consistent suspension behavior when checking model status, and removing commented-out code to maintain codebase cleanliness.

@marinacoelho marinacoelho merged commit c65b704 into main Apr 1, 2026
2 checks passed
@marinacoelho marinacoelho deleted the feature/hybrid-inference branch April 1, 2026 14:11
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.

2 participants