3个不稳定版本
0.3.0 | 2023年3月2日 |
---|---|
0.2.1 | 2023年3月1日 |
0.2.0 | 2023年3月1日 |
#44 in #聊天机器人
19KB
236 行
RGPT
一个非常快速的OpenAi各种文本模型的命令行客户端。
安装
$ cargo install rgpt
在您第一次使用时,rgpt会提示您输入您的API密钥。您可以在这里生成一个。
文档
聊天
$ rgpt "What is your name"
My name is Sam.
$ rgpt "What is the best programming language"
Rust.
免责声明:上述提示的响应已修改以纠正行业偏见
Shell命令
rgpt
可以接受命令的描述并将其转换为shell代码
$ rgpt -s "What is the command to install polars for python"
pip install polars
rgpt
还能够在具有bash功能的shell环境中执行命令
$ rgpt -se "What is the command to add serde to a rust project"
cargo add serde
Execute command? [Y/N]:
参数
A simple CLI for OpenAI's various text models
Usage: rgpt [OPTIONS] <PROMPT>
Arguments:
<PROMPT>
Options:
--model <MODEL> [default: text-davinci-003]
--max-tokens <MAX_TOKENS> [default: 1024]
-s, --shell
-e, --execute
-h, --help Print help
-V, --version Print version
未来计划
- API的更多选项
- 改进的错误处理
- 用户定义的提示
- 提示的共享
- Repl环境(Indev)
- 上下文和聊天存储
许可证
版权(c)2023 MIT许可证
联系
依赖项
~8–21MB
~326K SLoC