xiaozhi-client: Skill for Claude Code

.agents/skills/commit/SKILL.md

commit is a skill for Claude Code, Codex from shenjingnan/xiaozhi-client. It costs 10 tokens per session (2,823 once invoked), scanned A, original, MIT.

A tool that creates clear commit messages by examining Git changes. A commit message briefly records what changed in a code project.

In plain words
What is it for?
Reviewing staged and unstaged changes, choosing a commit type such as fix or feature, and drafting the subject and body.
Why use it?
It reduces the effort of summarising changes and helps reviewers understand the purpose of a commit.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

This is shenjingnan/xiaozhi-client's own configuration. It tells Claude Code and Codex how to work on xiaozhi-client itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything xiaozhi-client configures →

Reuse

Borrowing it

Nothing to install: this file belongs to shenjingnan/xiaozhi-client. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/shenjingnan/xiaozhi-client/main/.agents/skills/commit/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/shenjingnan/xiaozhi-client

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for commit

README.md
[![agentmods](https://agentmods.dev/badge/skills/shenjingnan/xiaozhi-client/commit/github.svg)](https://agentmods.dev/skills/shenjingnan/xiaozhi-client/commit)
Your own site
<a href="https://agentmods.dev/skills/shenjingnan/xiaozhi-client/commit"><img src="https://agentmods.dev/badge/skills/shenjingnan/xiaozhi-client/commit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for commit

Your own site · 80×15
<a href="https://agentmods.dev/skills/shenjingnan/xiaozhi-client/commit"><img src="https://agentmods.dev/badge/skills/shenjingnan/xiaozhi-client/commit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 10 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,823 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00010 $0.02823
Opus 5.5 $0.00004 $0.01129
Sonnet 5.5 $0.00002 $0.00565
Haiku 4.5 $0.00001 $0.00282

Measured 2mo ago against content hash 5c423b6c7110, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

commit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/commit/SKILL.md · 326 lines

How it starts

The opening of the file, as written. The whole thing — 326 lines — stays where its author put it; the contents beside it link to each section on GitHub.

我是 Git Commit 生成技能,专门为 xiaozhi-client 项目生成符合规范的、代码评审友好的 commit 信息,同时遵循务实开发理念。

技能使用原则

  • 真实准确,但避免过度详细:基于实际代码改动生成信息,不虚构不存在的细节
  • 评审友好优先,格式完美次之:让评审人快速理解改动比完美格式更重要
  • 简单明确优于复杂说明:优先选择清晰直接的描述方式
  • 务实开发指导:突出"为什么改"和"改了什么"两个核心问题

技能能力

1. 代码改动分析

核心能力:分析实际的代码改动,提取关键信息用于生成 commit 信息。

分析流程
# 1. 更新远程分支信息
git fetch origin

# 2. 获取主分支名称
MAIN_BRANCH=$(git symbolic-ref refs/remotes/origin/HEAD | sed 's@^refs/remotes/origin/@@')

# 3. 获取改动内容(优先检查未 add 的改动)
git diff --no-pager
git diff --cached --no-pager

# 4. 获取相对于主分支的改动
git diff --no-pager origin/$MAIN_BRANCH...HEAD
分析要点
  • 改动范围:哪些文件、模块被修改
  • 改动类型:新增功能、修复 bug、重构、文档更新等
  • 影响分析:改动对现有功能的影响
  • 验证方式:如何验证改动的正确性

2. Commit 类型判断

根据改动内容自动判断合适的 commit 类型。

Type 类型定义
  • feat:新增 feature
  • fix:修复 bug
  • docs:仅仅修改了文档,比如 README、CHANGELOG、CONTRIBUTE 等等
  • style:仅仅修改了空格、格式缩进、逗号等等,不改变代码逻辑
  • refactor:代码重构,没有加新功能或者修复 bug
  • perf:优化相关,比如提升性能、体验
  • test:测试用例,包括单元测试、集成测试等
  • chore:改变构建流程、或者增加依赖库、工具等
  • revert:回滚到上一个版本
类型判断示例
// feat 判断标准
// - 新增文件
// - 新增公共方法
// - 新增配置选项
// - 新增 API 端点

// fix 判断标准
// - 修复 bug
// - 修复内存泄漏
// - 修复崩溃问题
// - 修复类型错误

// refactor 判断标准
// - 代码结构调整
// - 变量重命名
// - 代码提取/合并
// - 类型定义优化

// test 判断标准
// - 新增测试用例
// - 修复测试用例
// - 提高测试覆盖率

3. 分支名称生成

根据改动内容生成符合规范的分支名称。

分支命名规范
  • 前缀类型:feature/、bugfix/、docs/、test/、refactor/、chore/
  • 格式要求:kebab-case 格式,简洁反映改动内容
  • 长度限制:不超过 50 字符
分支命名示例
# 功能开发
feature/add-user-auth-api
feature/implement-websocket-adapter
feature/support-modelscope-integration

# Bug 修复
bugfix/fix-memory-leak
bugfix/fix-type-error-in-mcp-service
bugfix/fix-connection-timeout-issue

# 文档更新
docs/update-readme-installation
docs/add-mcp-protocol-guide

# 测试相关
test/add-unit-tests-for-connection-manager
test-improve-test-coverage

# 重构
refactor-simplify-mcp-manager
refactor-optimize-path-alias-system

4. Commit 信息生成

生成符合代码评审友好的 commit 信息。

Commit 信息结构
<type>(<scope>): <subject>

## 改动说明
- 为什么改:<改动动机和问题背景>
- 改了什么:<具体的改动内容>
- 影响范围:<受影响的模块和兼容性>
- 验证方式:<测试方法或验证点>

Read the full file on GitHub · 326 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 326 lines · 10 tokens per session scan A 5c423b6c7110

Subscribe to this mod's changes

commit is a skill published in the GitHub repository shenjingnan/xiaozhi-client (345 stars, last pushed 1mo ago), licensed MIT. It adds 10 tokens to every session and 2,823 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.