AI-powered Git automation for VS Code. Generate smart commit messages and create Pull Requests with a single click using OpenAI or local Ollama models.
- 🚀 Smart Push: Automatically stages your changes, generates a meaningful commit message based on your code diff, commits, and pushes to your remote.
- 📝 AI Commit Messages: Uses advanced LLMs to write industry-standard commit messages following Conventional Commits.
- 🛠️ Zero Config PRs: Automatically detects your GitHub repository and opens a Pull Request flow after pushing.
- 🏠 Local & Cloud Support: Choose between OpenAI (GPT-4o) or run completely locally using Ollama.
Open VS Code Settings (Cmd+,) and search for Gai:
- Provider: Choose
openaiorollama. - Model: Set your preferred model (e.g.,
gpt-4oorllama3.2).
Run the command from the Command Palette (Cmd+Shift+P):
Gai: Set OpenAI API Key
Note: Ollama does not require an API key as it runs locally.
Go to the Source Control view in VS Code and look for the 🚀 icon in the title bar.
- Click the Rocket icon 🚀.
- Gai will analyze your changes and suggest a commit message.
- Confirm the message or choose to edit it.
- Gai will commit, push, and ask if you'd like to create a Pull Request.
- Git: Must be installed and initialized in your workspace.
- Ollama (Optional): If you want to use local models, ensure Ollama is installed and running (
ollama serve).
This extension contributes the following settings:
gai.ai.provider: Choose betweenopenaiandollama.gai.ai.model: The model to use for generation.gai.ollama.baseUrl: The base URL for your local Ollama instance (default:http://localhost:11434).gai.rules: Custom rules for commit message generation (e.g., "Mention ticket IDs", "No emojis").
This extension is licensed under the MIT License.