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.
npx agentmods add rules/mr-chen-05/rules-2.1-optimized/mermaidgit 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/mermaid)<a href="https://agentmods.dev/rules/mr-chen-05/rules-2.1-optimized/mermaid"><img src="https://agentmods.dev/badge/rules/mr-chen-05/rules-2.1-optimized/mermaid.svg" alt="Measured on agentmods" 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 | $0.00000 | $0.02099 |
| Opus 5 | $0.00000 | $0.01050 |
| Sonnet 5 | $0.00000 | $0.00420 |
| Haiku 4.5 | $0.00000 | $0.00210 |
Grade A, and why
mermaid 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 4d 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 — 323 lines — stays where its author put it; the contents beside it link to each section on GitHub.
📊 Mermaid Diagrams - Mermaid图表
使用Mermaid创建各种类型的图表和可视化。
🚀 Commands - 命令
/mermaid- 创建Mermaid图表/flowchart- 创建流程图/sequence- 创建时序图/class-diagram- 创建类图/er-diagram- 创建实体关系图
📋 Diagram Types - 图表类型
1. 🔄 流程图 (Flowchart)
flowchart TD
A[开始] --> B{条件判断}
B -->|是| C[执行操作A]
B -->|否| D[执行操作B]
C --> E[结束]
D --> E
2. ⏱️ 时序图 (Sequence Diagram)
sequenceDiagram
participant U as 用户
participant F as 前端
participant B as 后端
participant D as 数据库
U->>F: 登录请求
F->>B: 验证用户
B->>D: 查询用户信息
D-->>B: 返回用户数据
B-->>F: 返回认证结果
F-->>U: 显示登录状态
3. 🏗️ 类图 (Class Diagram)
classDiagram
class User {
+String name
+String email
+login()
+logout()
}
class Admin {
+String permissions
+manageUsers()
}
User <|-- Admin
4. 🗄️ 实体关系图 (ER Diagram)
erDiagram
USER ||--o{ ORDER : places
ORDER ||--|{ ORDER_ITEM : contains
PRODUCT ||--o{ ORDER_ITEM : "ordered in"
USER {
int id PK
string name
string email
}
ORDER {
int id PK
int user_id FK
date created_at
}
5. 🌳 Git图 (Git Graph)
gitgraph
commit id: "Initial"
branch develop
checkout develop
commit id: "Feature A"
commit id: "Feature B"
checkout main
merge develop
commit id: "Release v1.0"
6. 📊 甘特图 (Gantt Chart)
gantt
title 项目开发计划
dateFormat YYYY-MM-DD
section 需求分析
需求调研 :done, des1, 2024-01-01, 2024-01-05
需求文档 :done, des2, after des1, 3d
section 开发阶段
前端开发 :active, dev1, 2024-01-08, 10d
后端开发 :dev2, 2024-01-08, 12d
section 测试阶段
单元测试 :test1, after dev1, 3d
集成测试 :test2, after dev2, 2d
7. 🍰 饼图 (Pie Chart)
pie title 技术栈分布
"Vue.js" : 35
"React" : 30
"Angular" : 15
"其他" : 20
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.
- 4d ago First seen · 323 lines · 0 tokens per session scan A 10a9861e77f5
mermaid is a cursor rule published in the GitHub repository Mr-chen-05/rules-2.1-optimized (172 stars, last pushed 10mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,099 tokens. 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
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.
dev-standard
Apache Superset development standards and guidelines for Cursor IDE.
cli-error-handling
CLI command error handling patterns.
prefer-direct-imports-over-module-mocks
Prefer extracting a testable core over vi.mock / vi.resetModules when unit tests need to reach production logic entangled with config, env, or singletons.
control-plane-descriptors
Control plane descriptor and instance implementation patterns.
family-instance-domain-actions
Family instance domain action implementation patterns.