Skip to content

lifenouveau/GPT-3-Q_and_A-Bot

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Quick-and-Dirty GPT-3 Q&A Bot

This is a simple Q&A-style chatbot illustrating how easy it is to access the power of GPT-3's API from applications written in Python.

Follow these steps to get it up and running:

  1. Create an OpenAI account: https://beta.openai.com/signup

  2. Create a new Python conda environment for your GPT-3 project

  3. Activate the new conda environment

  4. Install OpenAI's Python Library: pip install --upgrade openai

  5. Install python-dotenv: conda install -c conda-forge python-dotenv

  6. Clone this GitHub repo

  7. Create an .env file in your clone of the repo (accessing your API key from an .env file is more secure than hardcoding it within your .py file)

  8. Retrieve your API key: https://beta.openai.com/account/api-keys

  9. Add this line to your .env file: OPENAI_API_KEY = the-secret-api-key-you-just-retrieved

  10. Save the .env file

  11. Run the code in quick-and-dirty_gpt-3_q&a_bot.py

Example Usage/Output:

About

The Quick-and-Dirty GPT-3 Q&A Bot

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%