Skip to content

Nabeel-ashrif/Gen-AI-cooking_app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Recipe Generator

This Streamlit app allows users to generate diverse cooking recipes based on their preferences for country, vegetarian or non-vegetarian dishes, and optional specific ingredients. The recipe generation is powered by OpenAI's GPT-3.5 Turbo model.

Getting Started

To run this recipe generator locally, follow these steps:

  1. Clone the repository:

    git clone [https://github.com/Nabeel-ashrif/Gen-AI-cooking_app.git]
  2. Install the required dependencies:

    pip install openai python-dotenv streamlit
  3. Create a .env file in the project directory and add your OpenAI API key:

    OPENAI_API_KEY=your_api_key_here

    Obtain your API key by signing up at OpenAI.

  4. Run the Streamlit app:

    streamlit run app.py

    Replace app.py with the actual filename if it's different.

Usage

  1. Select a country from the dropdown menu.
  2. Choose between "Vegetarian," "Non-Vegetarian," or "No Preference" for the type of dish.
  3. Optionally, enter other rquirements in the text input.
  4. Click the "Generate Recipe" button to generate a cooking recipe based on the provided inputs.

Code Structure

  • app.py: Contains the Streamlit app code, including user interface and interaction.
  • openai.py: Wraps OpenAI's API calls for generating recipes using the GPT-3.5 Turbo model.

Environment Variables

Ensure you have a .env file in the project directory with the following content:

OPENAI_API_KEY=your_api_key_here

Dependencies

License

Feel free to contribute or report issues. Happy cooking! 🍲

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published