Skip to content

Conversation

@marinacoelho
Copy link
Collaborator

This Pull Request adds new screens to the Friendly Meals app, and changes the UI to use a more modern approach, as proposed in the PRD. The new screens are:

  • Recipe list: a list of all recipes generated by every user in the app.
  • Filter screen: a screen where users can use many different filters to query the database and filter the recipes that match what they want (including filtering for their own recipes).
  • Recipe screen: previously, we were showing the recipe in the same screen as we generated it. Now we have a new screen dedicated to showing the ingredients, the instructions, the image, extra info like preparation and cooking time and servings - and allows the user to save the recipe to their Favorites, and give a rating from 1 to 5 stars.
  • Scan meal screen: this screen was created to match the iOS version, the user can take a picture of a meal and see its nutritional information.

In order to implement the above, we added a tab to the bottom of the screen so users can quickly switch screens. We also had to add Firebase Authentication and Cloud Firestore to store all the recipes. We're now using Cloud Storage to store recipe images. We modified the calls to Firebase AI Logic to return a structured output so we could display the recipe in the new UI.

Below you can see screenshots of the landing screen (where users can generate a new recipe), the recipe screen, the recipe list screen, and the filter screen:

generate-screen recipe-screen recipe-list-screen filter-screen

marinacoelho and others added 22 commits November 27, 2025 10:36
…ory and AuthDataSource, and importing Firebase Auth, Identity and Credential Manager libraries
…ep auth simple and focus on Pipelines samples
…hey share the same view model. Adjustments to the DatabaseRemoteDataSource functions
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @marinacoelho, 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 represents a substantial upgrade to the Friendly Meals Android application, transforming its user interface and backend capabilities. The changes are driven by a product requirement document (PRD) aiming for a more modern and feature-rich experience. Key improvements include dedicated screens for browsing and filtering recipes, a detailed recipe view with saving and rating functionalities, and an innovative meal scanning feature that leverages AI to provide nutritional insights. The underlying architecture has been significantly enhanced with robust Firebase integrations for authentication, data storage, and image management, ensuring scalability and a seamless user experience.

Highlights

  • Comprehensive UI/UX Overhaul: Introduced a modern UI with new screens for recipe listing, filtering, detailed recipe viewing, and meal scanning, along with a new bottom navigation bar for intuitive navigation.
  • Enhanced AI Integration: Updated Firebase AI Logic to return structured JSON output for recipes and added a new AI capability for scanning meals to provide nutritional information.
  • Firebase Backend Integration: Implemented Firebase Authentication for user management (anonymous sign-in), Cloud Firestore for storing recipes, reviews, saves, and tags, and Cloud Storage for managing recipe images.
  • Modularized Data Layer: Introduced new data sources and repositories for Auth, Database, and Storage, promoting a cleaner and more maintainable architecture.
  • Updated Android SDKs & Dependencies: Upgraded compileSdk and targetSdk to 36 and incorporated new libraries like androidx.exifinterface, coil-compose, and various Firebase SDKs.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The 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 /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize 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 .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. 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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@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 a significant overhaul of the Friendly Meals app, bringing in a modern UI, new screens, and robust backend integrations with Firebase Authentication, Cloud Firestore, and Cloud Storage. The adoption of structured AI output for recipe generation and meal scanning is a powerful enhancement. The new navigation structure with a bottom bar greatly improves user experience. Overall, the changes are well-structured and demonstrate a clear architectural approach using data sources, repositories, and Hilt for dependency injection. I've identified a few areas for potential improvement regarding error handling, efficiency, and string resource usage.

Copy link

@morganchen12 morganchen12 left a comment

Choose a reason for hiding this comment

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

Sorry for the slow review, I had a few comments in the Firestore part of the code. The rest LGTM.

val document = firestore.collection(RECIPE_COLLECTION)
.document(recipeId)
.collection(REVIEW_SUBCOLLECTION)
.document("${recipeId}_${userId}")

Choose a reason for hiding this comment

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

This documentID convention should be documented (and this query needs to be a pipeline query as well).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It's documented in the PRD. Query fixed.

Choose a reason for hiding this comment

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

I think it should be documented here for external users browsing the code, but will leave this feedback as optional.

Copy link

@morganchen12 morganchen12 left a comment

Choose a reason for hiding this comment

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

LGTM with one bit of optional feedback.

Create a detailed recipe based on these ingredients: $ingredients.
Format requirements:
- 'instructions': Provide the cooking steps as a clear. Use bold formatting on the step numbers. Use Markdown.

Choose a reason for hiding this comment

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

nit: This sentence Provide the cooking steps as a clear is incomplete. Maybe Provide the cooking steps as a clear list of instructions separated by newlines.?

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