Howto is a terminal helper which queries LLM and inserts the result into the current terminal input.
Supports OpenAI, DeepSeek, and Gemini.
Simply press ctrl+g to call howto. Howto replaces your command with a correct command from LLM.
go install github.com/antonmedv/howto@latest
Or download prebuild binaries.
Add a key binding to .zshrc or a similar config:
| Zsh |
|---|
bindkey -s "\C-g" "\C-ahowto \C-j" |
Set one of the following API keys (provider is detected automatically):
| Variable | Provider | Default Model | Get API Key |
|---|---|---|---|
OPENAI_API_KEY |
OpenAI | gpt-4o |
platform.openai.com |
GEMINI_API_KEY |
Gemini | gemini-2.0-flash |
aistudio.google.com |
DEEPSEEK_API_KEY |
DeepSeek | deepseek-chat |
platform.deepseek.com |
All providers use OpenAI-compatible API format (OpenAI, DeepSeek, Gemini).
If multiple keys are set, priority is: OpenAI → Gemini → DeepSeek.
Optionally override the model:
export HOWTO_MODEL="gpt-4o-mini"Write a command in terminal and press ctrl+g to send current command to LLM. LLM response will be inserted into the current input. You can modify the returned command, before executing it.
Recall previous command from history and to adjust the prompt.
Use howto to list all container's hostnames:
Use howto to convert a movie to mp4:


