/pyGPT

Primary LanguagePythonMIT LicenseMIT

pyGPT

An unofficial Python wrapper designed to interact with OpenAI's ChatGPT API from the command line. This script allows users to have a conversation with ChatGPT, and reset the conversation when desired.

Dependencies

  • Python 3.6+
  • requests

Installation

  1. Clone the repository or download the script.
  2. Install requests library if not already installed: pip install requests

Usage

  1. Replace YOUR_API_KEY in the script with your OpenAI API key.
  2. Run the script: python chatgptpy.py
  3. Enter your message and press Enter to send it to ChatGPT.
  4. Type 'exit' to quit the script, or 'reset' to reset the conversation.

Features

  • Interactive chat with ChatGPT API.
  • Resettable chat history.
  • Hourglass animation during API call.

License

This project is licensed under the MIT License. See the LICENSE file for details.