https://github.com/0xricksanchez/howto
openAI command-line helper tool to ask chatGPT "how to do X"
https://github.com/0xricksanchez/howto
ai howto openai openai-api
Last synced: about 1 month ago
JSON representation
openAI command-line helper tool to ask chatGPT "how to do X"
- Host: GitHub
- URL: https://github.com/0xricksanchez/howto
- Owner: 0xricksanchez
- License: mit
- Created: 2023-08-02T19:47:35.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-08-07T10:50:25.000Z (almost 3 years ago)
- Last Synced: 2025-01-16T04:12:06.588Z (over 1 year ago)
- Topics: ai, howto, openai, openai-api
- Language: Rust
- Homepage:
- Size: 38.1 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# OpenAI How-To Helper
This Rust program provides a simple CLI to interact with OpenAI's GPT* models using the OpenAI API.
## Prerequisites
- [Rust](https://www.rust-lang.org/tools/install)
- [OpenAI API Key](https://openai.com/blog/openai-api)
## Setup
First, build the binary:
```bash
cargo build --release
```
Then you can run the program with:
```bash
export OPENAI_API_KEY=your-api-key
cargo build
./target/debug/howto get closer to world peace
Promote open dialogue, empathy, and understanding between different cultures and nations. Encourage diplomacy, conflict resolution, and cooperation on global issues. Foster education, tolerance, and respect for diversity. Support organizations and initiatives dedicated to peacebuilding and non-violence.
```
### Usage
```bash
Usage: howto [OPTIONS] ...
Arguments:
...
Options:
-m, --model The openAI model to use [default: gpt-3.5-turbo]
-t, --temperature The temperature to use for the model. Higher values mean more random results. A value between 0.0 and 1.0! [default: 0.5]
-x, --max-tokens The maximum number of tokens to generate. Between 1 and 2048 [default: 2048]
-s, --stream Disable streaming the output from openAI.
-h, --help Print help
-V, --version Print version
```
## Contributing
Contributions are welcome. Please open an issue to discuss your ideas before making large changes.
## License
This project is licensed under the MIT License.