About this project
ShellGPT is a command-line productivity tool powered by AI large language models. It is designed to streamline the generation of shell commands, code snippets, and documentation directly from the terminal, reducing the need for external searches. The tool supports Linux, macOS, and Windows, and is compatible with major shells like PowerShell, CMD, Bash, and Zsh.
Key capabilities include:
- **Shell Command Generation:** Using the `--shell` option, users can generate and execute shell commands. The tool is context-aware and tailors commands to the specific operating system and shell environment.
- **Code Generation:** The `--code` option allows users to request pure code output for specific programming tasks.
- **Chat and REPL Modes:** Users can maintain conversational context using `--chat` or interact dynamically in a Read-Eval-Print Loop (REPL) using `--repl`. Both modes support the `--shell` and `--code` options for iterative development.
- **Function Calling:** The tool supports OpenAI function calling, allowing the LLM to execute custom Python functions defined by the user. This enables complex task automation and system interaction.
- **Custom Roles:** Users can create and manage custom roles to tailor the LLM's behavior for specific tasks, such as generating JSON or applying markdown formatting.
- **Input Flexibility:** ShellGPT accepts prompts from command-line arguments, stdin, and various redirection operators, allowing integration with pipes and file inputs.
- **Caching:** It includes a request caching mechanism to provide instant results for previously queried prompts.
By default, ShellGPT uses the OpenAI API but can be configured to use local open-source models via backends like Ollama. It can be installed via pip or run using Docker.
Comments
0 Rating appears after 10 ratings
Sign in to join the discussion.