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/wangqiqi/cursor-ai-rules/rules-conflict-resolvergit clone --depth 1 https://github.com/wangqiqi/cursor-ai-rulesWrote 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/wangqiqi/cursor-ai-rules/rules-conflict-resolver)<a href="https://agentmods.dev/rules/wangqiqi/cursor-ai-rules/rules-conflict-resolver"><img src="https://agentmods.dev/badge/rules/wangqiqi/cursor-ai-rules/rules-conflict-resolver.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.02518 |
| Opus 5 | $0.00000 | $0.01259 |
| Sonnet 5 | $0.00000 | $0.00504 |
| Haiku 4.5 | $0.00000 | $0.00252 |
Grade A, and why
rules-conflict-resolver 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 5d 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 — 365 lines — stays where its author put it; the contents beside it link to each section on GitHub.
⚡ 规则冲突解决和监控 (Rule Conflict Resolver & Monitor)
本文档是从 @rules-router 分割出来的冲突解决和监控部分。
⚠️ 解决原则
MUST 遵循以下冲突解决准则:
- MUST 基于优先级矩阵解决规则冲突
- NEVER 随意忽略或禁用冲突的规则
- ALWAYS 记录冲突解决决策
- DO NOT 让规则冲突影响系统稳定性
- MUST 定期审查和优化冲突解决策略
- ALWAYS 提供冲突解决的透明性
优先级计算模型
interface RulePriority {
basePriority: number; // 基础优先级
contextBoost: number; // 上下文提升
userPreference: number; // 用户偏好
recencyBonus: number; // 最近使用奖励
finalPriority: number; // 最终优先级
}
class PriorityCalculator {
calculatePriorities(
rules: string[],
context: RuleActivationContext
): Record<string, RulePriority> {
const priorities: Record<string, RulePriority> = {};
for (const rule of rules) {
const basePriority = RULE_DEPENDENCIES[rule]?.priority ?? 5;
// 上下文提升
let contextBoost = 0;
if (this.isHighlyRelevant(rule, context)) {
contextBoost += 3;
} else if (this.isModeratelyRelevant(rule, context)) {
contextBoost += 1;
}
// 用户偏好
const userPreference = context.userPreferences?.rule_preferences?.[rule] ?? 0;
// 最近使用奖励 (模拟)
const recencyBonus = Math.random() * 2; // 0-2的随机值
const finalPriority = basePriority + contextBoost + userPreference + recencyBonus;
priorities[rule] = {
basePriority,
contextBoost,
userPreference,
recencyBonus,
finalPriority
};
}
return priorities;
}
private isHighlyRelevant(rule: string, context: RuleActivationContext): boolean {
const highRelevanceMap: Record<string, string[]> = {
"javascript": ["javascript", "typescript", "react", "vue", "node"],
"python": ["python", "django", "fastapi", "flask"],
"collaboration": ["team", "collaboration", "git", "merge"],
"generator": ["create", "new", "init", "generate"],
"eslint": ["lint", "quality", "check", "fix"]
};
const relevantContexts = highRelevanceMap[rule] ?? [];
return relevantContexts.some(ctx =>
context.userIntent.includes(ctx) ||
context.techStack.includes(ctx) ||
context.projectType.includes(ctx)
);
}
private isModeratelyRelevant(rule: string, context: RuleActivationContext): boolean {
// 中等相关性逻辑
return false; // 简化实现
}
}
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.
- 5d ago First seen · 365 lines · 0 tokens per session scan A 36f337f67562
rules-conflict-resolver is a cursor rule published in the GitHub repository wangqiqi/cursor-ai-rules (16 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,518 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.