Butterfish Shell - AI Prompting for Bash and Zsh

Butterfish Shell adds AI prompting to bash and zsh with OpenAI or compatible APIs: prompt with a capital letter and the AI sees your shell history.

Best for
Asking why a command failed
Key capability
Prompt with a capital letter
Screenshot of Butterfish Shell command line interface

What is Butterfish Shell?

Butterfish Shell is an open-source command line tool that adds AI prompting to your existing shell (bash or zsh) with OpenAI or compatible APIs. You use the shell as normal and start a command with a capital letter to prompt the AI, which sees the shell history; it also autosuggests commands and offers an agent mode that runs commands toward a goal.

Screenshot of Butterfish Shell command line interface

Key features of Butterfish Shell

Butterfish wraps your bash or zsh shell: prompts start with a capital letter and include your shell history, autosuggested commands are applied with the tab key, an agent mode runs commands toward a goal, prompt wrappers are editable, and any OpenAI compatible API can be used.

Prompt with a capital letter

Start a command with a capital letter to prompt the AI, which sees your shell history.

Command autosuggest

Butterfish Shell autosuggests commands that you apply with Tab.

Goal Mode

Supports POSIX standards ensuring compatibility with many Unix-like systems and scripts.

Transparent prompts and model choice

Prompt wrappers are editable in prompts.yaml, and any server with an OpenAI compatible API can be used.

Pros and cons of Butterfish Shell

Pros

  • Open source under the MIT license
  • Works inside your existing bash or zsh shell
  • Prompts are visible and editable
  • Can point to any OpenAI compatible API, including local models

Cons

  • Requires an OpenAI API key and paid OpenAI API use without free credits
  • Goal Mode is hit or miss
  • Documentation is less extensive

Key use cases for Butterfish Shell

Asking why a command failed

The AI sees the shell history, so you can ask contextual questions about the last command.

Generating commands

Get commands suggested by the AI and apply them with Tab.

Agent tasks in the terminal

Let Goal Mode execute commands toward a goal, such as listing files or debugging a build.

Prompting from Neovim

Use the butterfish.nvim plugin to rewrite a block of code with specific instructions.

How Butterfish Shell works

  1. 1

    Install

    Install Butterfish on MacOS or Linux, for example via Homebrew on MacOS.

  2. 2

    Add an OpenAI key

    The first invocation asks you to paste in an OpenAI API secret key.

  3. 3

    Run butterfish shell

    Butterfish starts a new instance of your shell, probably bash or zsh, and intercepts its input and output.

  4. 4

    Prompt the AI

    Use the shell as normal and start a command with a capital letter to prompt the AI.

Who is using Butterfish Shell

People who work from the command line
Software engineers
Security-conscious users
Embedded systems engineers
Unix/Linux power users

Butterfish Shell pricing

Open source

Free

OpenAI API use is paid separately unless you have OpenAI free credits.

Plans and prices are as published by the vendor and can change. Check the official site before you buy. Open the pricing page (opens in a new tab)

Frequently asked questions about Butterfish Shell

It adds AI prompting to your shell (bash, zsh) with OpenAI or compatible APIs, like Github Copilot for the shell.

Butterfish works on MacOS and Linux.

Yes. The first invocation prompts you to paste in an OpenAI API secret key, and without OpenAI free credits you pay for OpenAI API use.

Yes. Butterfish is open source under the MIT license.

Goal Mode lets an agent execute commands on its own to reach a goal; starting with !! runs commands without confirmation, which is potentially dangerous.

Conclusion

Bash and zsh stay in place with Butterfish: it starts a new instance of your shell and adds AI prompting with OpenAI or compatible APIs, which its site likens to Github Copilot for shell. Commands run as usual, and any line that starts with a capital letter goes to the AI, which can see the shell history and answer questions such as why the last command failed. Tab applies its autosuggested commands, while Goal Mode hands an agent a task and lets it execute commands toward that goal.

People who work from the command line with a software engineering focus are the intended users, and a Neovim plugin brings the same prompting into the editor. Butterfish itself is open source under the MIT license and runs on MacOS and Linux. The real cost sits elsewhere: setup asks for an OpenAI API secret key, and without free credits every request is paid OpenAI API use, with autosuggest likely the most expensive feature.

Sources

Share Butterfish Shell:

No reviews yet

Be the first to share how this tool worked for you.

Featured on TiorAI

Show your visitors that your tool is listed on TiorAI.

Butterfish Shell — featured on TiorAI

For white and near-white backgrounds.

Badge style
<a href="https://tiorai.com/tools/butterfish-shell/"><img src="https://tiorai.com/wp-content/themes/tiorai/assets/images/badge/featured-on-tiorai-light.svg" alt="Butterfish Shell — featured on TiorAI" width="260" height="76" loading="lazy" style="max-width:100%;height:auto" /></a>

How to install it
  1. Pick the style that suits the background it will sit on.
  2. Copy the snippet and paste it into your footer, press page or integrations page.
  3. Nothing else is needed — the badge is a single image and requires no script on your site.

Alternative Tools

Explore similar AI tools that might fit your needs

Screenshot of the Fish Shell interface
Free

Fish Shell

Fish Shell is a modern, user-friendly command line shell that offers features like autosuggestions, syntax highlighting, and easy scripting to enhance terminal productivity.

Do you recommend this?