Butterfish Shell: A ChatGPT Integration for Your Terminal

in

Run the command `butterfish shell` to start the wrapper that wraps your existing shell.
3. Type normal commands like ‘ls -l’ and press enter to execute them.
4. Start a command with a capital letter, for example ‘How do I recursively find local .py files?’ to send it to GPT.
5. Autosuggest will print command completions that you can fill in by pressing tab.
6. If you have questions about your previous commands or want contextual information, start a command with ! and enter Goal Mode. In this mode, GPT acts as an agent attempting to accomplish your goal by executing commands. For example, ‘!Run make in this directory and debug any problems’.
7. Start a command with !! to enter Unsafe Goal Mode where GPT will execute commands without confirmation. Use with caution.
8. To print full LLM prompts (sometimes to log file), use the –verbose flag multiple times for more verbosity, e.g., -vvv.
9. If you do not have OpenAI free credits or want to reduce spend on autosuggestion, disable it with the –autosuggest-disabled flag or increase its timeout (e.g., -t 2000).
10. Use special Butterfish commands like Help for hints about usage, Status to show current configuration, and History to print out history that would be sent in a GPT prompt.
11. If you want to use a specific shell or change the command prompt (shell PS1 variable), set –bin and –no-command-prompt flags respectively.
12. Use light color mode with the –light-color flag for terminals with white(ish) backgrounds.
13. Set max history block tokens (–max-history-block-tokens=512) to limit the number of tokens in each block of history that is sent to GPT.
Butterfish Shell provides a chat-like terminal experience by wrapping your existing shell and adding LLM prompting and autosuggestion capabilities. This allows you to type normal commands like ‘ls -l’ or start a command with a capital letter, for example ‘How do I recursively find local .py files?’ to send it to GPT. Autosuggest will print command completions that can be filled in by pressing tab. If you have questions about your previous commands or want contextual information, start a command with ! and enter Goal Mode where GPT acts as an agent attempting to accomplish your goal by executing commands. For example, ‘!Run make in this directory and debug any problems’. To print full LLM prompts (sometimes to log file), use the –verbose flag multiple times for more verbosity. If you do not have OpenAI free credits or want to reduce spend on autosuggestion, disable it with the –autosuggest-disabled flag or increase its timeout (e.g., -t 2000). Use special Butterfish commands like Help for hints about usage, Status to show current configuration, and History to print out history that would be sent in a GPT prompt. If you want to use a specific shell or change the command prompt (shell PS1 variable), set –bin and –no-command-prompt flags respectively. Use light color mode with the –light-color flag for terminals with white(ish) backgrounds. Set max history block tokens (–max-history-block-tokens=512) to limit the number of tokens in each block of history that is sent to GPT.

SICORPS