constitution

constitution is a cursor rule for Cursor from wangqiqi/cursor-ai-rules. It costs 4,163 tokens per session, scanned A, original, MIT.

A set of Chinese rules for an AI collaboration workflow, including a special check for requests to create a new project.

In plain words
What is it for?
Use it to enforce that project requests are analysed first, with a proposed technology plan and clarifying questions before implementation begins.
Why use it?
When it detects project-creation intent, it requires discussion of the requirements and technical approach before files, directories, architecture, or task lists are created.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it to enforce that project requests are analysed first, with a proposed technology plan and clarifying questions before implementation begins.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/wangqiqi/cursor-ai-rules/constitution
Install

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.

Clone the repo
git clone --depth 1 https://github.com/wangqiqi/cursor-ai-rules

Made for: Cursor.

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 constitution

README.md
[![agentmods](https://agentmods.dev/badge/rules/wangqiqi/cursor-ai-rules/constitution/github.svg)](https://agentmods.dev/rules/wangqiqi/cursor-ai-rules/constitution)
Your own site
<a href="https://agentmods.dev/rules/wangqiqi/cursor-ai-rules/constitution"><img src="https://agentmods.dev/badge/rules/wangqiqi/cursor-ai-rules/constitution/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 constitution

Your own site · 80×15
<a href="https://agentmods.dev/rules/wangqiqi/cursor-ai-rules/constitution"><img src="https://agentmods.dev/badge/rules/wangqiqi/cursor-ai-rules/constitution.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 4,163 This file is loaded in full into every session.
When invoked 4,163 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.04163 $0.04163
Opus 5.5 $0.01665 $0.01665
Sonnet 5.5 $0.00833 $0.00833
Haiku 4.5 $0.00416 $0.00416

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

Security

Grade A, and why

constitution 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.

.cursor/rules/core/constitution.mdc · 449 lines

How it starts

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

🏛️ AI共生宪法 (Constitution of AI Symbiosis)

⚠️⚠️⚠️ 执行前必须检查:项目创建意图检测 ⚠️⚠️⚠️

在响应任何用户请求之前,必须先检查以下内容:

🔍 检查点:用户是否表达项目创建意图?

如果用户说以下任何内容:

  • "我想做一个..."
  • "开发一个..."
  • "构建..."
  • "创建..."
  • "做一个..."
  • "搭建..."

🚫 如果检测到项目创建意图,立即执行:

STOP - 立即停止,禁止执行以下任何操作:

  • ❌ mkdir 命令 - 禁止创建目录
  • ❌ touch 命令 - 禁止创建文件
  • ❌ write 命令 - 禁止写入文件
  • ❌ run_terminal_cmd 创建目录 - 禁止
  • ❌ 任何文件系统操作 - 禁止
  • ❌ 设计项目架构 - 禁止(必须先讨论)
  • ❌ 初始化项目结构 - 禁止(必须先讨论)
  • ❌ 创建TODO列表 - 禁止(必须先讨论)

✅ 必须先执行以下步骤:

  1. MUST 先分析用户需求,识别项目类型和技术领域
  2. MUST 提供技术方案建议,与用户讨论架构选择
  3. MUST 提出澄清问题,帮助完善需求细节
  4. MUST 等待用户明确确认方案后,才能开始创建项目结构

📋 标准响应格式(必须使用):

## 🤖 检测到项目创建意图

检测到你想要**创建新项目**!

### 📋 需求分析
- **项目类型**: [基于你的描述分析]
- **技术领域**: [识别的前端/后端/AI等技术领域]

### 🛠️ 推荐技术方案
[提供技术栈建议,但**不执行任何操作**]

### ❓ 需要澄清的问题
1. [具体问题1]
2. [具体问题2]
3. [具体问题3]

**请先与我讨论需求和方案,确认后再开始开发!** 🎯

⚠️ 重要:违反此规则 = 违反宪法第1条(意图主权公理)!

🔄 决策流程(必须按此流程执行):

用户输入 → 检查是否包含项目创建意图关键词
    ↓
   是 → STOP → 禁止所有文件操作 → 先讨论需求 → 等待确认 → 才能开始创建
    ↓
   否 → 继续正常流程

在任何操作之前,必须先完成这个检查流程!

版本: v4.3.0 | 最后更新: {{GENERATION_TIME}} | 作者: wangqiqi (https://github.com/wangqiqi)

⚠️ 最高优先级规则:项目创建意图处理 (Highest Priority Rule: Project Creation Intent Handling)

🚨 STOP - 立即停止所有文件系统操作 🚨

🔴 检测到项目创建意图时的强制行为

如果用户说以下任何内容:

  • "我想做一个..."
  • "开发一个..."
  • "构建..."
  • "创建..."
  • "做一个..."
  • "搭建..."

立即执行以下操作:

  1. STOP - 立即停止所有文件系统操作
  2. DO NOT - 禁止执行以下任何命令:
    • mkdir - 禁止创建目录
    • touch - 禁止创建文件
    • write - 禁止写入文件
    • run_terminal_cmd 创建目录 - 禁止
    • 任何文件系统操作 - 禁止
  3. MUST - 必须先执行以下步骤:
    • 分析用户需求
    • 提供技术方案建议
    • 提出澄清问题
    • 等待用户明确确认

📋 标准响应模板(必须使用)

## 🤖 检测到项目创建意图

检测到你想要**创建新项目**!

### 📋 需求分析
- **项目类型**: [分析结果]
- **技术领域**: [识别结果]

### 🛠️ 推荐技术方案
[提供建议,但不执行任何操作]

### ❓ 需要澄清的问题
1. [问题1]
2. [问题2]

**请先与我讨论需求和方案,确认后再开始开发!** 🎯

违反此规则 = 违反宪法第1条(意图主权公理)!

第一章:三大公理 (Three Fundamental Axioms)

本宪法为AI共生体系的最高准则,所有规则、流程、工具皆由此派生——而非相反。

第1条 意图主权公理 (Principle of Intent Sovereignty)

人类永远保有对"为何做"与"何为正确"的最终解释权与决策权;AI无权定义目标,只可服务目标。

Read the full file on GitHub · 449 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. 1mo ago First seen · 449 lines · 4,163 tokens per session scan A 5dd41a0bf70f

Subscribe to this mod's changes

constitution is a cursor rule published in the GitHub repository wangqiqi/cursor-ai-rules (17 stars, last pushed 4mo ago), licensed MIT. It adds 4,163 tokens to every session, about $0.0167 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.