Inspiration

Our inspiration for Food for Thought is that the current nutritional apps in the market are unable to utilize the user's existing foods in their daily lives to create a customized meal plan. From our own personal experience, it is an arduous task to create a healthy meal plan that incorporates our cultural food (in our case, Indian cuisine). Food for Thought hopes to eliminate this cultural barrier so that every user can structure a meal plan according to their familiar foods.

What it does

The program takes in user information regarding age, sex, height, physical goals, and common foods they eat daily. The program reorders the input of the food by the user based on their nutritional values, into the caloric goals, and portion sizes. It also suggests other foods which would improve the efficiency of their diet and hence allow them to reach their physical goals earlier.

How we built it

The program takes in user information regarding age, sex, height, physical goals, and common foods they eat daily. The project has two aspects to it.

  1. The nutritional calculator and reorganizer for the user's existing foods.
  2. A suggest mechanism that would prompt the user to have foods similar to their existing taste.
  3. The nutritional reorganizer starts with the calculation of the caloric and nutritional requirements for the user based on their physical goals. It does this by calling our API created using Cockroach DB, which connects to the nutritional calculator and pulls back the required data.
  4. The Suggest mechanism, would take the foods the user commonly eats and then find other common foods, the user would be comfortable eating within that cuisine. In order to do this, we use the classify functionality from Cohere.ai APIs and trained the program with data on menus from different cuisines, and used cuisines as labels. Hence, during each user run of the program, their food input would be tested against the classification program and would determine the cuisine they are comfortable with. After having identified the cuisine the user is comfortable with, the cuisine label data would go into Cohere.ai's Generate API, which we train using both menu and article data on specific cuisines, and based on the cuisine, would generate a food's name for the user. After steps 1 and step 2 are completed, the program reorders the foods, input by the user based on their nutritional values, into the caloric goals, and also suggests other foods which would improve the efficiency of their diet and hence allow them to reach their physical goals earlier.

Challenges we ran into

We tried to implement two tools from our Cal Hacks sponsors: CockroachDB and Co:here. In order to calculate the macronutrient breakdown from a 3rd party website, we aimed to create a basic RESTful API with Cockroach Labs that takes in the user input of height, weight, age, and goal. An API GET request would be made to the macronutrient calculator and using the nutritional breakdown, the Food for Thought software would be able to restructure the user's given food choices into a meal plan that fits their goal.

Accomplishments that we're proud of

We are proud of how we learned to use new tools such as how to build a RESTful API with Cockroach Labs and how to classify foods into cuisines using the Co:here classify model. These tools were completely new to us and they allowed us to expand our skillset.

What we learned

We learned to build a RESTful API with Cockroach Labs and how to use the Co:here classify model.

What's next for Food for Thought

Food for Thought has many areas for expansion. We hoped to further utilize Co:here's tool for suggesting foods based on how much the user wants to deviate from their current food choices. This would utilize the temperature slider from Co:here (which allows you to choose the randomness of text selections). Furthermore, we would like to build a collaborative aspect where users can share their meals and draw inspiration from others.

Built With

  • figma
  • replit
Share this project:

Updates