/chatterm

Use ChatGPT in terminal like a pro ⭐️.

Primary LanguageJavaScriptMIT LicenseMIT

Chatterm

PRs Welcome

✨ Use ChatGPT in Terminal like a pro ✨

中文文档

Prerequisite

you must have an openai account. you can use this link https://chat.openai.com/auth/login to sign up.

then, grab following two keys from the web UI:

export API key and organization key into environment.

export ORGANIZATION="YOUR_ORGANIZATION"
export OPENAI_API_KEY="YOUR_OPENAI_API_KEY"

Install

npm i -g chatterm
# or
yarn global add chatterm

and you are all set! just run chatterm, have fun!

chatterm

Usage

Basic

basic.mp4

Multi-Line Input

use prefix / to find all the available commands, currently only support /mode to select multi-line input.

after select multi-line mode, for mac and linux, it will use vim as default editor, so it required some basic knowledge about vim(at least know how to save and quit😏), for windows, it will use notepad as default editor.

multi-line.mp4

Under the hood

It uses the openai official APIs for it's core feature, and inquirer.js for terminal UI workflow.

Contribution

Working on your first Pull Request? You can learn how from this free series How to Contribute to an Open Source Project on GitHub.