An open API service indexing awesome lists of open source software.

https://github.com/thiviyant/chat-gpt-python-api


https://github.com/thiviyant/chat-gpt-python-api

Last synced: 2 months ago
JSON representation

Awesome Lists containing this project

README

        

🤖 Chat-GPT Python API
---

A simple script to get started with the OpenAI API to use the Chat-GPT model.

![](images/chat-gpt-api.gif)

**Here are the simple steps to get started:**
1. Download the OpenAI API:

`pip install openai`

2. Obtain your OpenAI API key from https://platform.openai.com/account/api-keys and set it as an environment variable:

`export OPENAI_API_KEY = "your_openai_api_key"`

3. Edit the system instructions in `main.py` to alter the chat-bot's behaviour.

4. Run the script:

`python main.py`