docs: 在 README 文件中vscode插件列表中添加了 Git Commit Genie 集成

已在所有语言版本的 README 文件中将 Git Commit Genie 添加到集成列表中。为新的集成补充了文档、图片和演示 GIF。
This commit is contained in:
Lune macos 2025-10-03 11:17:22 +10:00
parent 840e93fbf2
commit 98ab3ee09d
10 changed files with 382 additions and 0 deletions

View file

@ -817,6 +817,11 @@ The purpose is to build infrastructure in the field of large models, through the
<td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td> <td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td>
<td> AI Toolkit for Visual Studio Code is a comprehensive extension that empowers developers and AI engineers to build, test, and deploy intelligent applications using generative AI models. </td> <td> AI Toolkit for Visual Studio Code is a comprehensive extension that empowers developers and AI engineers to build, test, and deploy intelligent applications using generative AI models. </td>
</tr> </tr>
<tr>
<td> <img src="https://github.com/deepseek-ai/awesome-deepseek-integration/blob/main/docs/gitCommitGenie/Genie.png?raw=true" alt="Icon" width="64" height="auto" /> </td>
<td> <a href="https://github.com/Nouvelle-Lune/git-commit-genie/blob/main/README.md"> Git Commit Genie </a> </td>
<td> Git Commit Genie uses mainstream large language models to generate standardized commit messages, supporting custom commit message templates and multi-step reasoning. It can perform intelligent repository analysis to provide better context for commit message generation. </td>
</tr>
</table> </table>
<p style="text-align: right;"><a href="#table-of-contents">^ Back to Contents ^</a></p> <p style="text-align: right;"><a href="#table-of-contents">^ Back to Contents ^</a></p>

View file

@ -701,6 +701,12 @@
<td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td> <td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td>
<td> Visual Studio Code 的 AI Toolkit 是一个综合性扩展,为开发人员和 AI 工程师提供使用生成式 AI 模型构建、测试和部署智能应用程序的能力。 </td> <td> Visual Studio Code 的 AI Toolkit 是一个综合性扩展,为开发人员和 AI 工程师提供使用生成式 AI 模型构建、测试和部署智能应用程序的能力。 </td>
</tr> </tr>
<tr>
<td> <img src="https://github.com/deepseek-ai/awesome-deepseek-integration/blob/main/docs/gitCommitGenie/Genie.png?raw=true" alt="Icon" width="64" height="auto" /> </td>
<td> <a href="https://github.com/Nouvelle-Lune/git-commit-genie/blob/main/README.md"> Git Commit Genie </a> </td>
<td> Git Commit Genie 使用主流大模型生成标准的 commit message支持自定义提交信息模版、多步推理。能够进行仓库智能分析为提交信息生成提供更好的上下文。 </td>
</tr>
</table> </table>
<p style="text-align: right;"><a href="#目录">^ 返回目录 ^</a></p> <p style="text-align: right;"><a href="#目录">^ 返回目录 ^</a></p>

View file

@ -728,6 +728,11 @@ Integra la API de DeepSeek en softwares populares. Accede a la [Plataforma Abier
<td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td> <td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td>
<td> AI Toolkit para Visual Studio Code es una extensión integral que permite a desarrolladores e ingenieros de IA construir, probar y desplegar aplicaciones inteligentes utilizando modelos de IA generativa. </td> <td> AI Toolkit para Visual Studio Code es una extensión integral que permite a desarrolladores e ingenieros de IA construir, probar y desplegar aplicaciones inteligentes utilizando modelos de IA generativa. </td>
</tr> </tr>
<tr>
<td> <img src="https://github.com/deepseek-ai/awesome-deepseek-integration/blob/main/docs/gitCommitGenie/Genie.png?raw=true" alt="Icon" width="64" height="auto" /> </td>
<td> <a href="https://github.com/Nouvelle-Lune/git-commit-genie/blob/main/README.md"> Git Commit Genie </a> </td>
<td> Git Commit Genie utiliza modelos de lenguaje grandes para generar mensajes de commit estandarizados, compatible con plantillas de mensajes de commit personalizadas y razonamiento de múltiples pasos. Puede realizar análisis inteligente de repositorios para proporcionar mejor contexto para la generación de mensajes de commit. </td>
</tr>
</table> </table>
<p style="text-align: right;"><a href="#tabla-de-contenidos">^ Volver al índice ^</a></p> <p style="text-align: right;"><a href="#tabla-de-contenidos">^ Volver al índice ^</a></p>

View file

@ -609,6 +609,11 @@ DeepSeek API を人気のソフトウェアに統合します。API キーを取
<td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td> <td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td>
<td> Visual Studio Code 用 AI Toolkit は、開発者や AI エンジニアが生成 AI モデルを使用してインテリジェントなアプリケーションを構築、テスト、およびデプロイすることを可能にする包括的な拡張機能です。 </td> <td> Visual Studio Code 用 AI Toolkit は、開発者や AI エンジニアが生成 AI モデルを使用してインテリジェントなアプリケーションを構築、テスト、およびデプロイすることを可能にする包括的な拡張機能です。 </td>
</tr> </tr>
<tr>
<td> <img src="https://github.com/deepseek-ai/awesome-deepseek-integration/blob/main/docs/gitCommitGenie/Genie.png?raw=true" alt="Icon" width="64" height="auto" /> </td>
<td> <a href="https://github.com/Nouvelle-Lune/git-commit-genie/blob/main/README.md"> Git Commit Genie </a> </td>
<td> Git Commit Genie は主要な大規模言語モデルを使用して標準的なコミットメッセージを生成し、カスタムコミットメッセージテンプレートと多段階推論をサポートします。リポジトリのインテリジェント分析を実行し、コミットメッセージ生成のためのより良いコンテキストを提供できます。 </td>
</tr>
</table> </table>
<p style="text-align: right;"><a href="#目次">^ 目次に戻る ^</a></p> <p style="text-align: right;"><a href="#目次">^ 目次に戻る ^</a></p>

View file

@ -789,6 +789,11 @@
<td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td> <td> <a href="https://code.visualstudio.com/docs/intelligentapps/overview"> AI Toolkit </a> </td>
<td> Visual Studio Code 的 AI Toolkit 是一個綜合性擴展,為開發人員和 AI 工程師提供使用生成式 AI 模型構建、測試和部署智能應用程序的能力。 </td> <td> Visual Studio Code 的 AI Toolkit 是一個綜合性擴展,為開發人員和 AI 工程師提供使用生成式 AI 模型構建、測試和部署智能應用程序的能力。 </td>
</tr> </tr>
<tr>
<td> <img src="https://github.com/deepseek-ai/awesome-deepseek-integration/blob/main/docs/gitCommitGenie/Genie.png?raw=true" alt="Icon" width="64" height="auto" /> </td>
<td> <a href="https://github.com/Nouvelle-Lune/git-commit-genie/blob/main/README.md"> Git Commit Genie </a> </td>
<td> Git Commit Genie 使用主流大模型生成標準的 commit message,支持自定義提交信息模版、多步推理。能夠進行倉庫智能分析,為提交信息生成提供更好的上下文。 </td>
</tr>
</table> </table>
<p style="text-align: right;"><a href="#目錄">^ 返回目錄 ^</a></p> <p style="text-align: right;"><a href="#目錄">^ 返回目錄 ^</a></p>

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 KiB

View file

@ -0,0 +1,174 @@
<div align="center">
# Git Commit Genie
Chinese version: [中文说明](../gitCommitGenie/README.zh-CN.md)
</div>
## Overview
Git Commit Genie analyzes your staged Git diff and generates highquality Conventional Commits style messages using mainstream LLM providers (OpenAI / DeepSeek / Anthropic / Gemini). Features intelligent repository analysis that understands your project structure and tech stack to provide better context for commit generation. Supports optional multistep chain prompting and user template strategy to improve structural consistency and style alignment.
## Usage
<img src="../gitCommitGenie/demo1.gif" width="300"/>
## Format
By default, generated commit messages follow the Conventional Commits 1.0.0 specification. See the spec: https://www.conventionalcommits.org/en/v1.0.0/
Basic format:
```
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
```
## Tips
- Small or trivial commits: prefer a lightweight, fast model to speed up generation and reduce token usage.
- Large, multifile commits: consider switching to a stronger model for better analysis and structure.
- You can switch models anytime via "Git Commit Genie: Manage Models".
## Core Features
| Feature | Description |
| ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Multiprovider LLM support | Supports OpenAI, DeepSeek, Anthropic, Gemini. |
| Repository Intelligence | Automatically analyzes project structure, tech stack, and architecture to provide context for better commit messages; supports manual refresh, real-time updates, and manual editing of analysis reports. |
| Chain Prompting Mode | Optional multistep pipeline: perfile summaries → structured synthesis → validation & minimal fixups (improves accuracy & template adherence). |
| User Template Strategy | Built-in template selection and creation, supports workspace and user data directory storage, extracts strategy affecting structure, required footers, and vocabulary preferences. |
| Conventional Commit Enforcement | Header validation (type, optional scope, optional `!`, ≤ 72 chars, imperative, no trailing period). |
| Diff Awareness | Only staged changes are analyzed; intelligently classifies type (`feat`, `fix`, `docs`, `refactor`, etc.). |
| Token & Rate Safeguards | Retry with backoff; local soft limits (Gemini); parallelism control for chain mode. |
| Status Bar Integration | Shows current model and analysis status, click to access feature menu. |
| Cancellation | Cancel inprogress generation directly from the SCM title bar button. |
| Secure Secret Storage | API keys stored in VS Code secret storage (not in settings JSON). |
| Internationalization | Builtin English, Simplified Chinese, Traditional Chinese, and more. |
## How It Works
1. You stage your changes.
2. Run command: `Git Commit Genie: AI Generate` (SCM toolbar button or Command Palette).
3. If Chain Prompting is enabled:
- Generate filelevel summaries in parallel
- Synthesize & classify change type and scope.
- Apply template policy (if valid) to shape body & footers.
- Run structural + style selfcheck and minimal fixups.
4. Result is injected into the repository input box—review / tweak / commit.
If chain prompting is disabled: single prompt (lower latency, less structural & stylistic richness).
## Installation
1. Install from VS Code Marketplace (search "Git Commit Genie") or manually via packaged `.vsix`.
2. Open the Command Palette → `Git Commit Genie: Manage Models` to configure provider, API key, and model.
3. (Optional) Run “Git Commit Genie: Select/Create Template” to create or choose a template for this repo (stored in `.gitgenie/templates`) or globally (user data folder).
## Requirements
| Requirement | Notes |
| -------------- | ------------------------------------------------------ |
| VS Code | Engine `^1.103.0` or newer. |
| Git Extension | Bundled (`vscode.git`); must be enabled. |
| Network Access | Needed to call chosen LLM provider. |
| API Key | For each provider you intend to use (stored securely). |
## Configuration (Settings)
All settings are under: `Git Commit Genie`.
| Setting | Type | Default | Description |
| --------------------------------------------------- | ------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `gitCommitGenie.autoStageAllForDiff` | boolean | false | Only when the staging area is empty: temporarily stage all changes to build the diff, then restore your staging state. Use with caution—this may include unrelated changes in the prompt. |
| `gitCommitGenie.chain.enabled` | boolean | false | Enable multi-step chain prompting for commit generation (It makes the generated commit messages more detailed and accurate, and better aligns with the user's template, but it will increase latency and token consumption). |
| `gitCommitGenie.chain.maxParallel` | number | 2 | Maximum parallel LLM calls used by chain prompting across all providers. Increase carefully to avoid provider rate limits. |
| `gitCommitGenie.llm.maxRetries` | number | 2 | Max retry attempts for API request failures. |
| `gitCommitGenie.llm.temperature` | number | 0.2 | Temperature (02). Default 0.2. |
| `gitCommitGenie.repositoryAnalysis.enabled` | boolean | true | Enable repository analysis to provide better context for commit message generation. |
| `gitCommitGenie.repositoryAnalysis.excludePatterns` | array | [] | File patterns to exclude from repository analysis scanning (gitignore-style). |
| `gitCommitGenie.repositoryAnalysis.updateThreshold` | number | 10 | Number of commits after which to update the repository analysis. |
| `gitCommitGenie.repositoryAnalysis.model` | enum | general | Model used for repository analysis. Pick any supported model across providers; the provider automatically switches to match your selection. Choose “Use general provider model” to reuse your main commit message model. |
| `gitCommitGenie.commitLanguage` | string | `auto` | Target language for generated commit messages. Options: `auto`, `en`, `zh-CN`, `zh-TW`, `ja`, `ko`, `de`, `fr`, `es`, `pt`, `ru`, `it`. |
| `gitCommitGenie.typingAnimationSpeed` | number | 15 | Speed of the commit message box typing animation in milliseconds per character. Set to -1 to disable the animation. |
| `gitCommitGenie.showUsageCost` | boolean | true | When enabled, a brief notification displays the estimated total cost for the current generation. |
## Command List
| Command ID | Title | Purpose |
| -------------------------------------------- | --------------------------- | ----------------------------------------------------- |
| `git-commit-genie.generateCommitMessage` | AI Generate | Produce commit message for staged changes. |
| `git-commit-genie.cancelGeneration` | Stop | Cancel inflight generation. |
| `git-commit-genie.manageModels` | Manage Models | Select provider, enter/replace API key, choose model. |
| `git-commit-genie.toggleChainMode` | Toggle Chain Prompting | Quickly enable/disable chain mode. |
| `git-commit-genie.selectTemplate` | Select/Create Template | Pick or create a commit message template file. |
| `git-commit-genie.viewRepositoryAnalysis` | View Repository Analysis | Quick access to repository analysis report. |
| `git-commit-genie.refreshRepositoryAnalysis` | Refresh Repository Analysis | Manually refresh repository analysis. |
| `git-commit-genie.cancelRepositoryAnalysis` | Stop Repository Analysis | Cancel ongoing repository analysis. |
| `git-commit-genie.genieMenu` | Menu | Open Git Commit Genie feature menu. |
| `git-commit-genie.showRepositoryCost` | Show Repository Cost | Show estimated total usage cost for this repository. |
| `git-commit-genie.resetRepositoryCost` | Reset Repository Cost | Reset the estimated usage cost for this repository. |
SCM Title Bar: shows "Generate commit message" or "Stop generate" depending on state.
## Template Authoring
Using command `Git Commit Genie: Select/Create Template`to select or create a template file.
<img src="../gitCommitGenie/demo2.gif" width="600"/>
When present & nonempty, Genie attempts to extract a "Template Policy". Two authoring styles:
1. Natural Language bullet preferences.
2. Markdown template authoring.
Full guides: [English](./docs/user-template-guide.md) | [中文](./docs/user-template-guide.zh-CN.md)
Minimum example:
```
Minimal Template
- Always include a body with Summary and Changes.
- Use imperative, no trailing period.
- Always include a `Refs` footer (use `Refs: N/A` when missing).
- Prefer: add, fix, refactor; Avoid: update.
```
## Chain Prompting vs Single Shot
| Mode | Pros | Cons | When to Use |
| --------------- | ---------------------------------------------------------- | ---------------------------- | -------------------------------------------------------- |
| Chain Prompting | Best structure, template fidelity, classification accuracy | Higher latency & token usage | Larger multifile commits; enforce strict template style |
| Single Shot | Fast, cheaper | Less nuanced structure | Quick small fix / typo commits |
Toggle via command or enable permanently in settings.
## Security & Privacy
- API keys stored via VS Code SecretStorage (not written to disk config in plain text).
- Only staged diffs (file names & hunks) are sent; no untracked or unstaged changes.
- No analytics/telemetry are collected by this extension.
## Troubleshooting
| Symptom | Cause | Fix |
| ------------------------- | ------------------------ | -------------------------------------------- |
| "No staged changes found" | You haven't staged files | Stage with Source Control view or `git add`. |
| Empty / generic output | Template unclear | Attempt to write structured templates. |
| Frequent 429 / rate limit | Parallelism too high | Lower `chain.maxParallel`. |
| Thinking badge missing | Thinking disabled | Toggle via command or setting. |
| Asked for API key again | Secret cleared | Reenter via Manage Models. |
## License
MIT
## Acknowledgements
- [Conventional Commits](https://conventionalcommits.org/) - https://github.com/conventional-commits/conventionalcommits.org
- OpenAI / DeepSeek / Anthropic / Gemini model ecosystems.
---
Never suffer through writing commit messages again.

View file

@ -0,0 +1,182 @@
<div align="center">
# Git Commit Genie
English version: [English README](../gitCommitGenie/README.md)
</div>
## 概述
Git Commit Genie 基于已暂存的 Git diff使用主流大模型OpenAI / DeepSeek / Anthropic / Gemini自动生成高质量的 Conventional Commits 风格提交信息。内置仓库智能分析功能,自动理解项目结构和技术栈,为提交信息生成提供更好的上下文。支持可选"链式提示"模式(多步推理)与"用户模板"策略,显著提升结构一致性与团队风格统一。
优势:
- 避免在提交语句格式/措辞上反复纠结。
- 严格符合 Conventional Commits类型、scope、BREAKING CHANGE
- 通过一个简单的模板文件定义 Body / Footers / 语气 / 词汇偏好。
- 支持多模型动态切换,快速选择最适合的提供商与模型。
## Usage
<img src="../gitCommitGenie/demo1.gif" width="300"/>
## 格式
默认生成的提交信息遵循 Conventional Commits 1.0.0 规范详情见https://www.conventionalcommits.org/zh-hans/v1.0.0/
基本格式:
```
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
```
## Tips
- 少量 / 轻量级提交优先选择轻巧快速的模型生成更快、Token 消耗更低。
- 大型 / 多文件提交:再考虑切换更强的模型,以获得更好的理解与结构质量。
- 可随时通过命令面板运行 "Git Commit Genie: Manage Models" 切换模型。
## 核心特性
| 特性 | 说明 |
| ------------------------ | ---------------------------------------------------------------------------------------------------- |
| 多模型提供商 | 支持 OpenAI、DeepSeek、Anthropic、Gemini等。 |
| 仓库智能分析 | 自动分析项目结构、技术栈和架构,为提交信息生成提供上下文;支持手动刷新、实时更新和手动修改分析报告。 |
| 链式提示模式 | 多步:文件级摘要 → 结构化综合 → 校验修复,显著提升准确度与模板贴合度。 |
| 用户模板策略 | 内置模板选择和创建功能,支持工作区和用户数据目录,抽取策略影响段落顺序、必填 footers、词汇偏好等。 |
| Conventional Commit 校验 | 头行格式type(scope)!: desc长度 ≤ 72无句号。 |
| Diff 感知 | 仅读取"已暂存"更改自动推断类型feat / fix / docs / refactor 等)。 |
| Token 与速率保护 | 429 自动退避重试Gemini 软限本地节流;并发可配置。 |
| 状态栏集成 | 显示当前模型和分析状态,点击可访问功能菜单。 |
| 生成取消 | SCM 标题栏按钮可实时取消正在进行的生成。 |
| 安全存储 | API Key 使用 VS Code SecretStorage不写入明文设置。 |
| 国际化支持 | 内置英文、简体中文、繁体中文等多语言支持。 |
## 工作流程
1. 暂存Stage你的变更。
2. 执行命令:`Git Commit Genie: AI Generate`SCM 顶部按钮或命令面板)。
3. 若开启链式模式:
- 并行生成文件级摘要
- 综合分析类型与 scope
- 应用模板策略(若有效)
- 结构 + 风格自检与最小修复
4. 输出写入仓库提交框,可人工微调后提交。
未开启链式:使用单轮提示 → 更低延迟,但结构与风格细腻度稍弱。
## 安装
1. VS Code 市场搜索 “Git Commit Genie” 安装,或使用打包 `.vsix` 手动安装。
2. 命令面板运行 `Git Commit Genie: Manage Models` 选择 Provider、输入/替换 API Key、选择模型。
3. (可选)使用命令 `Git Commit Genie: Select/Create Template` 选择或创建模板文件。
## 运行要求
| 项 | 说明 |
| -------- | --------------------------- |
| VS Code | 版本需满足引擎 `^1.103.0`。 |
| Git 扩展 | 内置 `vscode.git`,需启用。 |
| 网络访问 | 调用所选 LLM 提供商。 |
| API Key | 使用的每个提供商都需要。 |
## 配置项
所有设置位于:`Git Commit Genie`
| Setting | 类型 | 默认 | 说明 |
| --------------------------------------------------- | ------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| `gitCommitGenie.autoStageAllForDiff` | boolean | false | 仅当暂存区为空时:临时将所有更改加入暂存用于生成 diff生成后会自动还原暂存状态。谨慎使用可能会把无关更改包含进提示。 |
| `gitCommitGenie.chain.enabled` | boolean | false | 启用链式多步提示生成提交信息(使得生成的提交信息更加详准确,且可以更加贴合用户模版,但将增加延迟与 Token 消耗) |
| `gitCommitGenie.chain.maxParallel` | number | 2 | 链式提示并行 LLM 调用最大数量。谨慎增大以避免触发速率限制。 |
| `gitCommitGenie.llm.maxRetries` | number | 2 | API请求失败最大重试次数。 |
| `gitCommitGenie.llm.temperature` | number | 0.2 | Temperature02默认为 0.2。 |
| `gitCommitGenie.repositoryAnalysis.enabled` | boolean | true | 启用仓库分析以提供更好的提交信息生成上下文。 |
| `gitCommitGenie.repositoryAnalysis.excludePatterns` | array | [] | 仓库分析扫描时要排除的文件模式gitignore风格。 |
| `gitCommitGenie.repositoryAnalysis.updateThreshold` | number | 10 | 更新仓库分析的提交次数阈值。 |
| `gitCommitGenie.repositoryAnalysis.model` | enum | general | 用于仓库分析的模型。可选择所有供应商支持的模型系统将自动切换到该模型所属的服务商或选择“使用与commit message生成相同的模型”以复用主模型。 |
| `gitCommitGenie.commitLanguage` | string | `auto` | 生成的提交信息目标语言。选项:`auto``en``zh-CN``zh-TW``ja``ko``de``fr``es``pt``ru``it`。 |
| `gitCommitGenie.typingAnimationSpeed` | number | 15 | 提交信息框打字动画速度,单位为每字符毫秒。设置 -1 关闭动画。 | |
| `gitCommitGenie.showUsageCost` | boolean | true | 启用后在生成文本时弹出通知,显示本次生成的估计总费用。 |
## 命令列表
| Command ID | 标题 | 作用 |
| -------------------------------------------- | --------------------------- | -------------------------------------------- |
| `git-commit-genie.generateCommitMessage` | AI Generate | 基于已暂存更改生成提交信息。 |
| `git-commit-genie.cancelGeneration` | Stop | 取消当前生成。 |
| `git-commit-genie.manageModels` | Manage Models | 选择提供商 / 输入或更换 API Key / 选择模型。 |
| `git-commit-genie.toggleChainMode` | Toggle Chain Prompting | 快速开启/关闭链式模式。 |
| `git-commit-genie.selectTemplate` | Select/Create Template | 选择或新建提交信息模板文件。 |
| `git-commit-genie.viewRepositoryAnalysis` | View Repository Analysis | 快速打开仓库分析报告。 |
| `git-commit-genie.refreshRepositoryAnalysis` | Refresh Repository Analysis | 手动刷新仓库分析。 |
| `git-commit-genie.cancelRepositoryAnalysis` | Stop Repository Analysis | 停止正在进行的仓库分析。 |
| `git-commit-genie.genieMenu` | Menu | 打开Git Commit Genie功能菜单。 |
| `git-commit-genie.showRepositoryCost` | Show Repository Cost | 显示当前工作区累计消耗估算。 |
| `git-commit-genie.resetRepositoryCost` | Reset Repository Cost | 重置当前工作区累计消耗估算。 |
SCM 标题栏根据状态显示“Generate commit message”或“Stop generate”按钮。
## 模板编写
使用命令 `Git Commit Genie: Select/Create Template` 选择或创建模板文件。
<img src="../gitCommitGenie//demo2.gif" width="600"/>
模版文件存在且非空时,系统尝试抽取“模板策略”。支持:
1. 自然语言偏好描述。
2. markdown模版编写。
完整指南: [English](./user-template-guide.md) | [中文](./user-template-guide.zh-CN.md)
最小示例:
```
Minimal Template
- Always include a body with Summary and Changes.
- Use imperative, no trailing period.
- Always include a `Refs` footer (use `Refs: N/A` when missing).
- Prefer: add, fix, refactor; Avoid: update.
```
## 链式模式 vs 单轮模式
| 模式 | 优点 | 缺点 | 适用场景 |
| ---- | -------------------------------- | -------------------- | ----------------------- |
| 链式 | 结构最佳,模板贴合度高,分类更准 | 延迟更高Token 更多 | 多文件 / 需严格风格统一 |
| 单轮 | 快速,成本低 | 结构细腻度较低 | 小变更 / 临时修复 |
通过命令或设置切换。
## 安全与隐私
- API Key 使用 SecretStorage不以明文写入 settings.json 不会以任何形式上传到互联网,仅保存在本地。
- 仅发送“已暂存 diff”中的文件名与修改上下文不包括未暂存或未跟踪文件。
- 无遥测 / 分析数据收集。
## 常见问题Troubleshooting
| 现象 | 原因 | 解决 |
| ------------------------- | ------------------- | --------------------------------------- |
| "No staged changes found" | 未暂存任何文件 | 使用 Source Control 或 `git add` 暂存。 |
| 生成内容空泛 | 模板不明确 | 尝试编写结构化的模版 |
| 频繁 429 | 并行过高 / 模板过大 | 降低 `chain.maxParallel`。 |
| 状态栏无“· Thinking” | 未启用链式 | 使用命令或设置开启。 |
| 重复要求输入 API Key | 秘钥被清除 | 重新运行 Manage Models。 |
## 许可证
MIT
## 致谢
- [Conventional Commits](https://conventionalcommits.org/) - https://github.com/conventional-commits/conventionalcommits.org
- OpenAI / DeepSeek / Anthropic / Gemini 模型生态
---
让提交信息不再痛苦。

Binary file not shown.

After

Width:  |  Height:  |  Size: 636 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 499 KiB