Savor is an AI recipe-generating app, leveraging the use of Gemini AI, Firebase, and React Native to build an application that promotes eco-friendliness and prevent food waste anywhere, anytime.
Savor.mp4
- Allow access to the Backend
cd server
node app.js
- Allow access to the frontend
cd frontend
npx expo start
Firebase Authentication provided us a straightfoward and secure way to authenticate users for their credentials and managing their user identities. Our application supports Email/Password Sign-In, providing users a familiar, convenient, and safe way to access our application.
- Initialization by setting up Firebase Authentication; Setting up necessary dependencies.
- User Registration allows users to create their own accounts which is handled by Firebase in the backend process, securing and managing credentials.
- User Sign-in grants users the ability to access their accounts with their credentials whilst Firebase verifies their identity and authenticates them.
- Access Control utilizes Firebase Authentication to enforce access and resource control within our application.
Utilized Expo to simulate the User experience with our application and designed around the idea of a mobile application through React Native. Additionally, we brought out Gemini's full potential by using its insane data gathering capability to retrieve and track a multitude of item qualities:
- Calories
- Location
- Category
Through Gemini we are also able to use our User Item database to generate unique step-by-step recipes in order to prevent Food Waste.
The Backend relied on Express.js to communicate with our Firebase Database which stored our Users and their respective items. Through this process, we are able to produce API endpoints that manipulate and transform the data processed within Firebase to eventually be used by Google's Gemini AI.
- Parameters (request, response)
- Destructure title, calories, category, expiration, location, image from req.body
- Accesses User Database for list of items
- Checks for the existance of item in User Database, and creates or updates depending on status.
- Parameters (request, response)
- Implement Try & Catch for erros:
- If itemTitle does not exist in User Database: throw error
- If it does exist then deletion is followed through
- Parameters (request, response)
- Grab all items from User Database, including item qualities, and return them in an Array of json.
- Alternatively grab just an Array of strings for item titles.