Tracking meals, getting insights and living a healthier life never been much easier with AI-powered Nutri+.
- Authenticate with Firebase, fill up your personal assessment data and get ready to experience Nutri+.
- Easily track your meals — add them manually or scan their images using Gemini AI.
Ertan Yağmur – Medium - LinkedIn – [email protected]
Nutri+ is a native iOS application built with Swift and UIKit, designed to offer seamless meal tracking and nutritional insights.
- iOS 15.2+
- Xcode 14.0+
Nutri+ utilizes several third-party libraries for enhanced functionality. Below is a list of the libraries used:
Nutri+ follows MVVM architecture to ensure separation of concerns and better maintainability. The app utilizes Dependency Injection (DI) for modularity and scalability. By adopting Protocol-Oriented Programming, the project ensures flexibility and ease of testing.
Combine is used to bind the UI with the ViewModel, providing a reactive and efficient approach for handling updates and changes in the user interface.
Nutri+ leverages Gemini AI for food recognition and nutritional insights. Users can capture photos of their meals, which are sent to Gemini along with a specific instruction. Gemini processes the image and returns a structured JSON response containing the meal’s name, calories, and nutritional information.
In addition to meal recognition, Nutri+ integrates a chat feature with Gemini, allowing users to receive personalized health and diet advice, much like consulting a nutritionist.
Nutri+ uses Firebase Firestore for data storage, ensuring real-time updates and seamless synchronization across devices. All meal data, including user-specific nutrition information, is securely stored in the cloud.
Firebase Authentication is implemented to manage user sign-in and sign-up, providing a secure and simple way for users to access their personalized meal tracking data.
To enable Firebase functionality in Nutri+, you need to add your GoogleService-Info.plist file to the project:
- Go to the Firebase Console.
- Create a new project or select an existing project.
- Add an iOS application to your Firebase project.
- Download the GoogleService-Info.plist file and place it in the Supporting directory of the project.
To use Gemini AI for food recognition and nutritional insights, you must configure your API key:
- Create a SECRETS configuration file with your Gemini AI API key:
GEMINI_API_KEY: "YOUR_API_KEY"
- Set this file as configuration for both debug and release in the project settings.
Currently, unit tests have not been implemented for this project. Although the app follows best practices in terms of architecture and modularity, automated tests are yet to be added.
I would love you for the contribution to the project, check the LICENSE
file for more info.