Repository for projects undertaken in the course ' Natural Language Processing ' at Northwestern University
- Amit Adate @amitadate
- Omkar Satpute @omkarstpt
- Mayank Malik @mayankmalik01
- Aditya Kumar @adijays17
- To run the code, clone the repo and navigate to Final_Submission folder
- Create a virtual environment if needed and activate the environment
- $ pip install -r requirements.txt
- Run main.py (to get a menu interface)
Note - In the menu, scroll up to see results displayed or use terminal in fullscreen mode
-
----> To view scraped data, Ingridients, Nutrition and Methods
-
----> Transform to Healthy
-
----> Transform to Non-Healthy
-
----> Transform to Vegetarain
-
----> Transform to Non-Vegetarian
-
----> Transform to Vegan
-
----> Transform to Chinese
-
----> Transform to Indian
-
----> Transform to Mexican
-
----> Transform to Italian
Firstly, we started with Exploratory Data Analsis of most common ingredients used in top recipes of the world. The code for this purpose can be found in Final_Submission-> PreProcessing. Using the PreProcessing statistics, we created the list of most common ingredients and their substitution found in healthy, non healthy, veg, non-veg recipes, Chinese, Indian, Mexican, and Italian recipes.
Below is the list our parser recognizes:
Ingredients - name , quantity , measurement (cup, teaspoon, pinch, etc.) , descriptors
Nutritions - Protein, Carbs, Sodium into High, low, normal
Methods: Primary cooking method (e.g. sauté, broil, boil, poach, etc.) Secondary cooking method (e.g. chop, grate, stir, shake, mince, crush, squeeze, etc.) Tools – pans, graters, whisks, etc. Steps – parse the directions into a series of steps that each consist of ingredients, tools, methods, and times
The code for this section can be found in Final_Submission-> data_extractor.py
We have given the following options to a user to choose from:
- Transform to Healthy
- Transform to Non-Healthy
- Transform to Vegetarain
- Transform to Non-Vegetarian
- Transform to Vegan
- Transform to Chinese (Includes Chinese Utensils)
- Transform to Indian (Includes Indian Utensils)
- Transform to Mexican
- Transform to Italian
The code for this section can be found in Final_Submission-> transformer.py