This script integrates LLMs into your Linux shell, provides an explanation of a wrong command, and outputs the correct one.
Type any Linux command. If it's valid, it will be executed and the output will be printed. If not, the script will send a request to the API and return the correct command with an explanation.
You can use any API or model and customize the prompt to your needs.
Run the script by typing ./shell.sh
in the terminal or paste it in your PATH
.# ai-command-correct