Command your terminal with intelligent suggestions
Autocomplete.sh adds AI-powered command-line suggestions directly to your terminal. Just type <TAB><TAB>
and it calls an LLM (OpenAI by default) to return the top suggestions for you.
Use natural language without copying between CoPilot or ChatGPT
wget -qO- https://autocomplete.sh/install.sh | bash
- Context-Aware: Considers terminal state, recent commands, and
--help
information - Flexible: Supports various LLM models, from fast and cheap to powerful
- Secure: Enables local LLMs and sanitizes prompts for sensitive information
- Efficient: Caches recent queries for speed and convenience
- Cost-Effective: Monitors API call sizes and costs
We support OpenAI, Groq, Anthropic, and Ollama models. Configure your model with:
autocomplete model
Autocomplete.sh provides faster, more accurate suggestions by considering:
- Your machine's environment
- Recently executed commands
- Current directory contents
- Command-specific help information
View the full prompt with:
autocomplete command --dry-run "your command here"
- For command parameters:
ffmpeg # reformat video to fit youtube
then<TAB><TAB>
- For complex tasks:
# create a github repo, init a readme, and push it
then<TAB><TAB>
source autocomplete config
Update settings with:
autocomplete config set <key> <value>
autocomplete usage
- Data Engineers: Manipulate datasets efficiently
- Backend Developers: Deploy updates swiftly
- Linux Users: Navigate systems seamlessly
- Terminal Novices: Build command-line confidence
- Efficiency Seekers: Streamline repetitive tasks
- Documentation Seekers: Quickly understand commands
git clone git@github.com:closedloop-technologies/autocomplete-sh.git
ln -s $PWD/autocomplete.sh $HOME/.local/bin/autocomplete
. autocomplete.sh install
sudo apt install bats
bats tests
docker build -t autocomplete-sh .
docker run --rm -e OPENAI_API_KEY=$OPENAI_API_KEY autocomplete-sh
Currently maintained by Sean Kruzel @closedloop at Closedloop.tech
Contributions and bug fixes are welcome!
The best way to support Autocomplete.sh is to just use it!
- Just use it!
- Share it!
- Star it!
If you want to help me keep up the energy to build stuff like this, please:
See the MIT-LICENSE file for details.