A command-line tool to execute natural language instructions using Google's Gemini AI. Type in plain English; get back shell commands.
- Natural Language to Shell: Converts English instructions into executable shell commands.
- OS Aware: Automatically generates commands for Windows, macOS, and Linux.
- Interactive Confirmation: Always shows you the commands and asks for approval before running.
- Safety First: Includes a safety layer to block potentially destructive commands (
rm -rf,sudo, etc.). - Shortcuts: Blazing-fast shortcuts for common commands (e.g.,
clone,code) that bypass the AI. - Command History: Keeps a log of all executed commands (
jasmine --history).
-
Clone the repository:
git clone https://github.com/your-username/jasmine.git cd jasmine -
Create a virtual environment:
python -m venv venv
-
Activate the environment:
- On Windows:
.\venv\Scripts\activate - On macOS/Linux:
source venv/bin/activate
- On Windows:
-
Install the project and its dependencies:
pip install -e .
The tool requires Google Gemini API keys to function.
-
Copy the example config:
cp config.example.json config.json
-
Edit
config.json: Open theconfig.jsonfile and replace"YOUR_API_KEY_HERE"with your actual Gemini API keys. You can get keys from Google AI Studio.{ "api_keys": [ "AIzaSy...key1", "AIzaSy...key2" ] }
Once installed and configured, you can use the jasmine command from your terminal (while the venv is active).
Normal Command:
jasmine show the current date and timeUsing a Shortcut:
jasmine clone https://github.com/some/repo.gitViewing History:
jasmine --history