Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/Mr-chen-05/rules-2.1-optimizedWrote 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.
[](https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/commit)<a href="https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/commit"><img src="https://agentmods.dev/badge/rules/mr-chen-05/rules-2.1-optimized/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.
<a href="https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/commit"><img src="https://agentmods.dev/badge/rules/mr-chen-05/rules-2.1-optimized/commit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.02810 | $0.02810 |
| Opus 5.5 | $0.01124 | $0.01124 |
| Sonnet 5.5 | $0.00562 | $0.00562 |
| Haiku 4.5 | $0.00281 | $0.00281 |
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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 332 lines — stays where its author put it; the contents beside it link to each section on GitHub.
📝 Commit Unified Workflow - 统一提交工作流
一个全面、统一的提交工作流:既支持标准化提交,也支持快速提交与AI智能消息生成;集成质量门与变更日志,适配不同团队规范与项目阶段。
🚀 Commands - 智能命令(统一)
/commit- 标准提交(包含预提交检查)/commit --fast- 快速提交模式(智能暂存 + AI消息生成)/commit-fast- 快速提交别名(与/commit --fast等效)/commit --no-verify- 跳过预提交检查(紧急场景)/commit --analyze- 深度分析模式(详细变更分析与建议)/commit --template <type>- 指定模板类型(如 feat/fix/docs/refactor 等)/commit --smart-stage- 智能暂存相关文件(自动排除临时/配置文件)
说明:保留所有既有命令习惯,同时提供统一的参数化入口,便于脚本与工具集成。
🧠 AI Intelligence Core - AI智能核心
智能激活条件
自动激活场景:
- 检测到多个文件变更且需要快速提交
- 用户执行 `/commit --fast` 或 `/commit-fast`
- 超级大脑系统推荐快速提交流程
- 项目处于需要频繁提交的阶段
智能分析维度:
- 变更文件类型和数量 (30%)
- 代码变更复杂度 (25%)
- 项目当前阶段 (20%)
- 历史提交模式 (15%)
- 时间紧迫性 (10%)
✨ AI-Powered Features - AI驱动功能
🤖 智能提交信息生成
AI分析引擎:
文件变更分析:
- 自动识别变更类型(feat/fix/docs/refactor等)
- 分析变更影响范围和重要性
- 检测代码模式和最佳实践
- 识别潜在的安全和性能影响
智能消息生成:
- 基于变更内容自动生成描述性标题
- 智能选择最合适的emoji和类型
- 自动添加作用域(scope)信息
- 生成详细的变更说明(可选)
上下文感知:
- 考虑项目类型和技术栈
- 分析历史提交模式
- 集成项目管理阶段信息
- 参考团队提交规范
🔧 MCP工具自动编排(可选)
预提交自动化:
- 智能选择相关的代码检查工具
- 自动运行适当的测试套件
- 执行代码格式化和清理
- 生成或更新相关文档
质量保证:
- 自动安全扫描(如适用)
- 性能影响评估
- 依赖关系检查
- 版本兼容性验证
智能优化:
- 根据项目类型选择工具
- 基于变更范围调整检查级别
- 并行执行提升效率
- 智能缓存和增量检查
✨ Features - 功能特性
- 默认运行预提交检查(lint、build、生成文档)
- 如果没有暂存文件,自动暂存文件
- 使用约定式提交格式和描述性表情符号
- 建议为不同关注点拆分提交
补充:在快速模式下,会根据变更自动选择最合适的提交类型与模板,并支持自动生成详细说明。
📋 Commit Types - 提交类型(统一)
| 类型 | 表情符号 | 描述 | 示例 |
|---|---|---|---|
| feat | ✨ | 新功能 | ✨ feat: 添加用户认证功能 |
| fix | 🐛 | Bug修复 | 🐛 fix: 修复登录页面验证错误 |
| docs | 📝 | 文档变更 | 📝 docs: 更新API文档 |
| refactor | ♻️ | 重构代码 | ♻️ refactor: 重构用户服务层 |
| style | 🎨 | 代码格式 | 🎨 style: 格式化代码,添加缺失分号 |
| perf | ⚡️ | 性能改进 | ⚡️ perf: 优化数据库查询性能 |
| test | ✅ | 测试相关 | ✅ test: 添加用户注册单元测试 |
| chore | 🧑💻 | 工具配置 | 🧑💻 chore: 更新构建配置 |
| wip | 🚧 | 进行中的工作 | 🚧 wip: 用户权限功能开发中 |
| remove | 🔥 | 删除代码 | 🔥 remove: 删除废弃的API接口 |
| hotfix | 🚑 | 紧急修复 | 🚑 hotfix: 修复生产环境登录问题 |
| security | 🔒 | 安全改进 | 🔒 security: 加强密码加密机制 |
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.
- 1mo ago First seen · 332 lines · 2,810 tokens per session scan A 5f3d35c07ab9
commit is a cursor rule published in the GitHub repository Mr-chen-05/rules-2.1-optimized (172 stars, last pushed 11mo ago), licensed MIT. It adds 2,810 tokens to every session, about $0.0112 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.
Other cursor rules, from other repositories
git
Git workflow — commit format, push policy, and PR process.
commit-sponsors
Every git commit message must acknowledge BetterDesk supporters.
no-ai-contributors
Never add AI tools as git authors or project contributors.
git-discipline
Commit, push, and branching rules. Owns ALL git behavior; other files state only their deviations.
git-commit-standards
Enforce structured Git commit messages.
conventional-commits
Use the Conventional Commit Messages specification to generate commit messages.