VS Code extension that generates commit messages from Git diffs. It defaults to DeepSeek, supports OpenAI-compatible chat completion APIs, and handles workspaces with multiple Git repositories by generating messages per repository.
Features
- Generate a commit message for a selected repository.
- Generate commit messages for every repository in the current workspace.
- In multi-repository Source Control views, the quick-fill button scans all displayed repositories with diffs when no single repository context is available.
- Supports staged-only or staged plus unstaged diffs.
- Configurable model, API base URL, commit style, language, system prompt, reasoning effort, and diff size.
- Stores API keys in VS Code Secret Storage, with environment variable fallback.
Commands
AI Commit: 快速填入提交信息AI Commit: Configure API KeyAI Commit: Generate Message for RepositoryAI Commit: Generate Messages for All Repositories
Default DeepSeek Request Shape
The extension calls:
POST https://api.deepseek.com/chat/completions
Authorization: Bearer ${DEEPSEEK_API_KEY}
Content-Type: application/json
with defaults:
model:deepseek-v4-prothinking.type:enabledreasoning_effort:highstream:false
Configuration
Search for AI Commit in VS Code settings.
Recommended first-time setup:
- Choose
aiCommit.provider. - Keep
aiCommit.apiBaseUrlempty unless you use a proxy or private gateway. - Choose
aiCommit.modelPreset. - Run
AI Commit: Configure API Key. - Click the
AI Commitbutton in Source Control.
Common settings, in the same order as the VS Code settings page:
aiCommit.provideraiCommit.apiBaseUrlaiCommit.modelPresetaiCommit.modelaiCommit.apiKeyEnvaiCommit.commitStyleaiCommit.languageaiCommit.customStyleInstructionsaiCommit.customLanguageInstructionsaiCommit.systemPromptModeaiCommit.systemPromptExtraaiCommit.systemPromptOverrideaiCommit.diffModeaiCommit.maxDiffChars
Models
Use aiCommit.modelPreset for common models:
deepseek-v4-prodeepseek-chatdeepseek-reasonergpt-4.1gpt-4.1-minigpt-4ogpt-4o-miniqwen-plusqwen-maxqwen3-coder-plusglm-4-plusglm-4-flashsiliconflow-deepseek-v3siliconflow-deepseek-r1custom
When aiCommit.modelPreset is custom, set aiCommit.model to any OpenAI-compatible model name.
Provider defaults:
deepseek:https://api.deepseek.comopenai:https://api.openai.com/v1siliconflow:https://api.siliconflow.cn/v1dashscope:https://dashscope.aliyuncs.com/compatible-mode/v1zhipu:https://open.bigmodel.cn/api/paas/v4openai-compatible: setaiCommit.apiBaseUrlmanually
API key environment defaults:
deepseek:DEEPSEEK_API_KEYopenai:OPENAI_API_KEYsiliconflow:SILICONFLOW_API_KEYdashscope:DASHSCOPE_API_KEYzhipu:ZHIPU_API_KEYopenai-compatible:OPENAI_API_KEY
Commit Styles
conventionalconcisedetailedsemanticangulargitmojiticketmonoreporeleasecustom
Languages
autoenglishchinese-simplifiedchinese-traditionaljapanesekoreanspanishfrenchgermancustom
System Prompt
Use aiCommit.systemPromptMode:
append: keep the built-in safety and style prompt, then appendaiCommit.systemPromptExtra.override: replace the built-in prompt withaiCommit.systemPromptOverride.