Skip to main content

A barebones library to make interacting with OpenAI's ChatGPT API much simpler.

Project description

PyPI - Downloads PyPI

quickGPT is a lightweight and easy-to-use Python library that provides a simplified interface for working with the new API interface of OpenAI’s ChatGPT. With quickGPT, you can easily generate natural language responses to prompts and questions using state-of-the-art language models trained by OpenAI.

For the record, this README.md was (mostly) generated with ChatGPT. That’s why it’s a little braggy.

Installation

You can install quickGPT using pip:

pip install quickGPT

Usage

To use quickGPT, you’ll need an OpenAI API key, which you can obtain from the OpenAI website. Once you have your API key, you can create a quickGPT object and start generating responses:

from chattylib import ChattyLib
from chattylib.thread.messagetypes import *

if __name__ == "__main__":
    chat = ChattyLib()

    thread = chat.new_thread()

    thread.feed(
        System("The world is your oyster.")
    )

    while True:
        response = thread.run()
        print("Bot: %s" % response.message)

        prompt = input("You: ")

        thread.feed(
            Assistant(response.message),
            User(prompt)
        )

Try out catbot.py in the examples folder for an interactive fuzzface experience.

Documentation

There’s no documentation yet. Stay tuned.

Contributing

If you find a bug or have an idea for a new feature, please submit an issue on the GitHub repository. Pull requests are also welcome!

License

This project is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

quickgpt-0.1.1.tar.gz (4.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page