← all repositories
abhagsain/ai-cli

A shell that asks ChatGPT before you Google

Stop tabbing out to search "how do I tar.gz"; just ask from the terminal.

1.2k stars TypeScript Coding Assistants
ai-cli
Not currently ranked — collecting fresh signals.
star history

What it does ai-cli is a thin oclif wrapper around OpenAI’s API. You type ai ask "list processes on port 3000" and it prints a shell command back. It stores your API key locally, supports model switching, and has shell autocomplete.

The interesting bit The author did the boring plumbing so you don’t have to: key management via ai auth, model selection via ai model, and autocomplete setup via ai autocomplete. It’s essentially a well-packaged prompt with a system message, but the packaging is what makes it usable.

Key highlights

  • Built on oclif, so it gets --help, autocompletion, and update channels for free
  • Defaults to gpt-3.5-turbo; you can swap models without touching config files
  • Claims ~$0.0009 per command at current token counts
  • Hacker News #3 with 159 points, so the itch is real

Caveats

  • You bring your own OpenAI API key and billing
  • The README still says “GPT3” everywhere while defaulting to 3.5-turbo; branding drift is visible
  • No evidence of local caching or offline mode — every command hits the API

Verdict Grab it if you constantly context-switch from terminal to browser for shell syntax. Skip it if you already have a shell alias that curls OpenAI, or if you work offline.

Frequently asked

What is abhagsain/ai-cli?
Stop tabbing out to search "how do I tar.gz"; just ask from the terminal.
Is ai-cli open source?
Yes — abhagsain/ai-cli is open source, released under the GPL-3.0 license.
What language is ai-cli written in?
abhagsain/ai-cli is primarily written in TypeScript.
How popular is ai-cli?
abhagsain/ai-cli has 1.2k stars on GitHub.
Where can I find ai-cli?
abhagsain/ai-cli is on GitHub at https://github.com/abhagsain/ai-cli.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.