GPT-over-CLI is a simple, lightweight command-line interface (CLI) for interacting with OpenAI's GPT models, including GPT-3, GPT-4 and others. This tool provides a quick and easy way for developers and researchers to generate responses from OpenAI's API directly from their terminal.
- Support for multiple models: GPT-over-CLI supports a wide range of models provided by OpenAI including
davinci
,curie
,babbage
,ada
and various specialized text and code models. - Easy to use: Just provide your prompt as a command-line argument and get the model's response printed directly in your terminal.
-
Clone this repository to your local machine.
-
Install the required Python dependencies.
-
Add your OpenAI API key to your environment variables, or replace
'YOUR_API_KEY'
in the script with your actual API key. -
Use the script with the following command:
python3 gptcli.py "your prompt here"
This tool is intended for research and development purposes. Please use responsibly and be mindful of OpenAI's use case policy. Do not expose your API key publicly.
Please note, this tool is not intended to replace OpenAI's chat models for interactive conversation applications. It is designed for quick, one-off interactions with the API from the terminal.
Feel free to contribute to this project by opening issues or submitting pull requests. All contributions are welcome.