• Stars
    star
    105
  • Rank 328,196 (Top 7 %)
  • Language
    Python
  • License
    MIT License
  • Created over 1 year ago
  • Updated 11 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

๐Ÿฅ A command line application to interact with OpenAI's ChatGPT API.

Actions Status Actions Status Quality Gate Status CodeQL Codacy Badge []

Prompt ๐Ÿฅ - A ChatGPT CLI

prompt is designed to provide users a command-line interface for the ChatGPT API, which uses OpenAI's GPT language model to generate text based on user input.

The application helps you start a session with ChatGPT so that the context is preserved and longer conversions with contexts are considered. The user's prompts and the responses are sent back to ChatGPT everytime.

The ChatGPT api usage depends on the number of tokens used and it is important that you use the tokens wisely. After a prompt has been answered the application will resend the last prompt and answer in the next prompt, this makes sure you can have a continued conversion with ChatGPT much like using ChatGPT in a single chat session. This makes the token count larger and larger as you continue to chat. If you are not concerned with context use the --clear flag which will save your token usage. Use the model option to add

I hope you find it useful.

Configuration

The application requires you to have an api token to query the OpenAI's ChatGPT api. You can read about and get it here https://platform.openai.com/account/api-keys .

Installation

Install the prompt python package directly from pypi.

  pip install promptcli

I would recommend using pipx instead of pip to install cli applications on you machine.

Usage

Usage: prompt [OPTIONS] COMMAND [ARGS]...

  ๐Ÿฅ A command line application to interact with OpenAI's ChatGPT.

Options:
  --version     Show the version and exit.
  --clear    ๐ŸŒŠ Clear the context each round of chat
  --model    ๐Ÿ”„ The OpenAI model type.
  --help        Show this message and exit.

Commands:
  update  ๐Ÿ” Update the OpenAI API key.

Please feel to create issues or request for features. More options and commands will be added to the application in the near future.

More Repositories

1

freshenv

๐Ÿฅ— Provision, share, manage local and cloud developer environments.
Python
169
star
2

dallecli

๐Ÿ’  Provide users with the ability to generate, edit and filter images using the DALL-E 3 API provided by OpenAI, all from the command line.
Python
59
star
3

snapsht

๐Ÿฆ“ A command line application to capture full-page screenshots with ease, every time.
Python
24
star
4

screenshot

โœ‚ A github action that takes full screen scrolling screenshots of custom or preview urls and uploads them to dropbox.
Python
13
star
5

rollback

โฎ Checkout master, back it up, and rollback to the previous commit erasing the current commit history
Shell
8
star
6

100-Tips-on-Coding-in-Python

๐Ÿ A collection of useful tips for beginners and experienced python programmers.
7
star
7

cloudflare-send-mail-custom-domain

A cloudflare worker with a custom domain and mailchannels email send
JavaScript
4
star
8

fast-text-search

โ˜„๏ธ A go package to do extremely fast concurrent text search across files and folders.
Go
2
star
9

RaiyanYahya

Raiyan Yahya's Portfolio
1
star
10

freshenv-busybox

A mimimal docker image to test freshenv
1
star
11

Natural-Selection-Simulation

A simulator of natural selection built on python
Python
1
star
12

knife

Sharp commands for sharp people
1
star
13

gitools

A cli written in golang to help you when you are stuck.
Go
1
star
14

aws-lambda-gitlab-ci-cd

A project which deploys a function to aws using the gitlab ci cd pipeline.
HTML
1
star
15

vault

a key value store written in golang
1
star
16

freshenv-flavours

A repo with freshenv flavours config
1
star
17

yacs

Yet another credential store ๐Ÿ”
Python
1
star