Skip to main content

An easy to use API and CLI wrapper for chatGPT and other AIGC API base on utype

Project description

uGPT

uGPT is an API and CLI wrapper for chatGPT and other AIGC API base on utype to make integration easier

  • Version: 0.1.1 [test]
  • Author: @voidZXL
  • License: MIT

Features

  • provide type-hints for OpenAI's API and enforce them at runtime using utype, increasing integration experience and reducing bugs
  • provide easy to use commands for common AIGC tasks

Installation

pip install -U ugpt

uGPT requires Python >= 3.7

CLI Usage

use a simple command to start a chat session with chatGPT

ugpt chat 

NOTICE: in the first time, you will be asked for an API key, you can get that in here

if you need to set a request proxy, you can just use

ugpt set --proxy=http://127.0.0.1:7890

or update your API key using

ugpt set --key=<YOUR-NEW-API-KEY>

Image generation

you can generate image with prompt in a single command

ugpt draw "an orca whale in the sea"

... more are coming

API Usage

uGPT provided a developer-friendly wrapper for OpenAI's API, All the API params and responses are type-hinted and enforced at runtime using utype, increasing integration experience and reduce bugs

such as image.py

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

uGPT-0.1.2.tar.gz (6.8 kB view hashes)

Uploaded Source

Built Distribution

uGPT-0.1.2-py3-none-any.whl (8.6 kB view hashes)

Uploaded Python 3

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