Skip to content

The Delta

rishi2019194 edited this page Nov 27, 2023 · 23 revisions

We have made a significant number of enhancements over the previous version of the Burnout application and the same are listed below!!

Installation and setup

Simplified the cumbersome installation process and database seeding process to have one-shot static data loading. For instance, in the previous iteration, it wasn't mentioned which files to run to insert the data on the MongoDB (insert_food_data.py which is now insert_food_bmi_date.py) and how to get the graph functionality running (running the bootstrap file - which is now redundant as we have added dynamic date feature). Therefore, we properly documented the installation process in our README and Wiki.

Dynamic date

The initial version didn't allow users to add dates manually on the 'Enter calories' and 'Burnout' pages, the web application automatically took system dates. During our testing, we found this to be the root cause for faulty graphs generated. We fixed this to take the date from the user manually, which now fixes bugs and opens the avenue for 'updating' the database during the user session.

Burnout Image Calorie Image

Graph Functionality - Calorie Tracker

The initial version of the graph functionality was randomly picking data from MongoDB to display the calorie data for the logged-in user. Therefore, we fixed this bug by accessing the calorie consumed and intake data of the currently logged-in user. Furthermore, there was no legend signifying what the red bar meant (calories consumed) and the green bar meant (calories burnt), so we added the same.

Your Plan Image

Email Feature

The email notifier was not working earlier. image

Moreover, the format is also not very appealing.

WhatsApp Image 2023-11-25 at 16 25 35_dd78b9e2

We got the email notifier working, formatted, and beautified the email contents. Now, the email displays the summary of the last week giving the calorie intake, calories burned, and net calories. image

Chatbot

The initial chatbot was hardcoded, i.e., it gave answers from a limited pre-defined knowledge base and didn't have answers to questions beyond this. We replace this with a full-fledged intelligent chatbot powered by OpenAI which impersonates a Fitness coach, nutritionist, and customer support to solve the users' immediate problems. Moreover, our chatbot supports 95 languages from around the world.

Older version of the chatbot

Old chatbot Old chatbot

New version of the FitnessBot

FitnessBot
FitnessBot

BMI Analysis and Insights

We added a new page to allow users to check their BMI from their age, height, weight, and gender. After calculating BMI, you can also compare it with a selected country's average BMI for both sexes as well as the selected gender. To make this happen, we added a new dataset (Source: https://www.kaggle.com/datasets/arttua/who-obesity-by-country-2016/) that contains the country-wise average BMI for both sexes, male and female.

image image

Enrollment page

In the previous iteration of the code, whenever a user enrolled in a workout plan like yoga, swimming, dancing, etc, then it didn't reflect and display the plans the user was enrolled in. Thus, to support that we have added an enroll plans page which displays all the different programs the user is enrolled in to date. Furthermore, as another fitness tracking feature, we have also added a progress bar on this page - depicting the %age of the number of calories the user has been able to burn so far.

Enrolled Plans Page

Code refactoring & test suite

The test suite in the previous version had all tests commented out and a faulty code coverage badge. We performed a complete overhaul of this test suite to have a genuine 98% coverage (pass and fail) on the modularised parts on the code and delta added by us. We also fixed the code coverage badge to reflect the correct numbers.

Workflows

In the frontend, we've implemented tests using assertions, given that the front-end code is in pure JavaScript. These tests are not designed to run within workflows. Instead, they serve to verify the functionality of the user interface (UI). To inspect the results of these tests, one can navigate to the browser console where logs pertaining to any failures will be displayed. This approach allows us to maintain the integrity of the UI while providing a mechanism for troubleshooting potential issues.

Workflows
# Documentation Migrated documentation from readme file to Wiki with more enhanced depth and easier-to-understand flow. Refer to the [Wiki](https://github.com/rishi2019194/calorieApp/wiki) and the [README](https://github.com/rishi2019194/calorieApp/blob/main/README.md) of the repository.