Practice with Open AI Platform

An implementation of AI tools including image and essay generator, speech to text, AI chatbot via API of Open AI Platform

Table of Contents

🚀 Demo
💻 Project Overview
🛠️ Installation
☎️ Contact

💻 Project Overview

On the website, you can access four distinct functionalities:

  • AI Chatbot
  • Image Generator
  • Essay Generator
  • Speech To Text Conversion

🛠️ Installation

1. Prerequisites

Before you begin, ensure you have the following requirements in place:

  • Python: Install Python from the Python website.

  • Open AI: Have an account of Open AI.

    • If you do not have an account of Open AI, you can a three-month gift credit of $5 which is a free trial that Open AI provides for new user.
  • Cloudinary: Have an account of Cloudinary.

    • Cloudinary will serve as the platform for storing user voice inputs.

2. Clone the Repository

Clone this repository to your local machine using:

git clone https://github.com/henghuisan/practice-with-open-ai.git

3. Create a Virtual Environment

Navigate to the cloned directory:

cd practice-with-open-ai

Create a virtual environment:

  • On macOS and Linux:
python3 -m venv venv
source venv/bin/activate
  • On Windows:
python -m venv venv
venv\Scripts\activate

4. Install Dependencies

Install the required Python packages using pip:

pip install -r requirements.txt

5. Create a .env File

In the root directory of the project, create a file named .env.

6. Define Environment Variables

Inside the .env file, define the necessary environment variables using the following format:

FLASK_APP=app.py
FLASK_ENV=development
OPENAI_API_KEY=
CLOUDINARY_CLOUD_NAME=
CLOUDINARY_API_KEY=
CLOUDINARY_API_SECRET=

7. Create Open AI Key

Go to this page to create your API key and assign the key to the OPENAI_API_KEY variable in your .env file.

8. Cloudinary Setup

Go to this page to copy the snippets for your Cloudinary environment variables.

9. Run the Development Server

Start the development server and run the app:

flask run

You should now be able to access the app http://localhost:5000/

☎️ Contact

For questions or feedback, feel free to reach out: