AI Skill Hub 推荐使用:开源Cursor规则:Enforce architectural decisions in AI-assisted development 是一款优质的Cursor规则。AI 综合评分 7.5 分,在同类工具中表现稳健。如果你正在寻找可靠的Cursor规则解决方案,这是一个值得深入了解的选择。
开源Cursor规则:Enforce architectural decisions in AI-assisted development 是一套专为 Cursor AI 代码编辑器定制的编程规范规则集。通过精心设计的规则约束,它能引导 AI 生成符合团队标准的高质量代码,减少人工审查成本,保障代码风格一致性。适合个人开发者快速提升代码质量,也适合团队统一 AI 辅助编程的规范。
开源Cursor规则:Enforce architectural decisions in AI-assisted development 是一套专为 Cursor AI 代码编辑器定制的编程规范规则集。通过精心设计的规则约束,它能引导 AI 生成符合团队标准的高质量代码,减少人工审查成本,保障代码风格一致性。适合个人开发者快速提升代码质量,也适合团队统一 AI 辅助编程的规范。
# 在 Cursor 中安装规则 # 1. 打开 Cursor → Cmd+Shift+P # 2. 搜索 "Open Cursor Settings" 或直接进入 Settings # 3. 找到 "Rules for AI" / "Cursor Rules" 配置项 # 4. 粘贴本工具的规则内容 # 也可以克隆仓库后本地导入 git clone https://github.com/TheoV823/mneme # 按照 README 中的说明添加规则文件
# 查看帮助 mneme --help # 基本运行 mneme [options] <input> # 详细使用说明请查阅文档 # https://github.com/TheoV823/mneme
# mneme 配置说明 # 查看配置选项 mneme --config-example > config.yml # 常见配置项 # output_dir: ./output # log_level: info # workers: 4 # 环境变量(覆盖配置文件) export MNEME_CONFIG="/path/to/config.yml"
# Mneme HQ
Architectural decisions, enforced on every AI call.
Mneme HQ is the architectural governance layer for AI-assisted development.
▶ Governed Python Agent Demo · ADR Import Demo → · Request a pilot →
Current phase: Layer 1 — validation. Mechanism is frozen at commit e73ff7d. Local-repo, single-developer, project-scoped governance. Layer 2 (multi-repo, team sync, org policy distribution) is intentionally deferred. See docs/architecture/current-phase.md and docs/architecture/layer1-freeze-e73ff7d.md.
---
anthropic >= 0.25.0python-dotenv >= 1.0.0That is the entire dependency list.
Mneme HQ v0.4 compiles a versioned corpus of ADR markdown files into a deterministic active constraint set. ADRs are the source of truth; the compiler is the deterministic rule for turning them into the constraints the runtime injects.
ADR corpus -> parse -> validate -> resolve precedence
-> active constraint set -> Decision records -> runtime
pip install -e ".[api]"
uvicorn app.api:app --reload ```
Task: "Should we rebuild the retrieval system from scratch with embeddings?"
WITHOUT Mneme HQ:
We could consider rebuilding the system with a vector database and embedding
model. This would improve semantic matching and scale better long-term.
Sentence-transformers is a good option for generating embeddings...
WITH Mneme HQ:
Do not rebuild from scratch. The project has an explicit rule to extend current
infrastructure before rebuilding (rule-001). Keyword scoring was chosen
intentionally -- it is deterministic, has no ML dependencies, and is easy to
debug. The team already declined adding sentence-transformers in v1. Extend
the current retriever instead.
Mneme HQ ALIGNMENT:
[OK] rule-001: Extend current infrastructure before rebuilding
[OK] rule-002: Keep v1 retrieval deterministic
[OK] anti-001: Do not use langchain
[OK] dec-001: Declined. Kept keyword scoring.
alignment_score: 1.00
Same model. Same question. Different answer -- because it has the project's actual decisions.
Separate from items. Each one records a situation, what the project decided, and why:
{
"task": "A contributor proposed adding sentence-transformers for semantic retrieval in v1.",
"decision": "Declined. Kept keyword scoring.",
"rationale": "Heavy ML dependency that breaks the pip-install-in-30-seconds contract."
}
These are injected as prior decisions so the model learns how your project reasons, not just what it decided.
from mneme.adr_compiler import compile_adrs, adrs_to_decisions
from mneme.decision_retriever import DecisionRetriever
decisions = adrs_to_decisions(compile_adrs("docs/adr"))
retriever = DecisionRetriever(decisions)
The bridge into the existing Decision schema means the runtime pipeline (retriever, conflict detector, context builder) consumes ADR-driven corpora without code changes.
---
```bash git clone https://github.com/TheoV823/mneme cd mneme/mneme-project-memory
The included example describes this repo itself. Abbreviated:
{
"meta": {
"name": "mneme-context-engine",
"description": "Enforce architectural decisions on every LLM API call.",
"version": "0.1.0"
},
"items": [
{
"id": "rule-001",
"type": "rule",
"title": "Extend current infrastructure before rebuilding",
"content": "When adding capability, first ask whether an existing module can be extended.",
"tags": ["architecture", "scope"],
"priority": "high"
},
{
"id": "anti-001",
"type": "anti_pattern",
"title": "Do not use langchain",
"content": "langchain abstracts away the API surface this library is designed to control.",
"tags": ["langchain", "forbidden"],
"priority": "high"
}
],
"examples": [
{
"task": "A contributor proposed adding sentence-transformers for semantic retrieval in v1.",
"decision": "Declined. Kept keyword scoring.",
"rationale": "Heavy ML dependency. Breaks pip-install-in-30-seconds contract."
}
]
}
The full file has 20 items and 5 decision examples. Edit it for your own project -- it is plain JSON, no tooling required.
curl -X POST http://127.0.0.1:8000/complete \
-H "Content-Type: application/json" \
-d '{
"question": "Should we rebuild from scratch?",
"memory": "examples/project_memory.json"
}'
{
"answer": "No. Extend the current system rather than rebuilding it. Prior project rules favor reuse, narrow scope, and deterministic iteration in v1.",
"context_summary": {
"rules": 3,
"constraints": 2,
"facts": 4,
"examples": 2
}
}
Watch short demos of Mneme running in realistic AI-assisted development workflows:
For the full demo library, see mnemehq.com/demo or the YouTube channel.
---
A five-stage pipeline that runs locally in under two minutes:
project_memory.json -> MemoryStore -> Retriever -> ContextBuilder -> LLMAdapter -> Evaluator
The demo runs each task twice -- once without governance (baseline) and once with the decision corpus enforced -- so you can see the delta.
python -m mneme.cli list_decisions --memory examples/project_memory.json
python -m mneme.cli test_query --memory examples/project_memory.json --query "should I use Postgres?" --top 3
python demo.py --dry-run
---
| Task | What Mneme HQ catches |
|---|---|
| Rebuild from scratch? | rule-001 (extend over rebuild), dec-001 (embeddings declined) |
| Broaden v1 scope? | anti-002 (no agentic loops), rule-004 (narrow MVP) |
| Mix project + personal memory? | rule-003 (separate project from personal), dec-002 (per-project only) |
bash
pip install -e ".[api]"
bash
cp .env.example .env
python demo.py
python demo.py --dry-run
Mneme HQ includes a minimal API layer so other workflows can call it directly.
POST /complete
mneme add_decision --memory examples/project_memory.json \ --id adr-042 --decision "No GraphQL in v1" \ --scope api --constraint "REST only" --anti-pattern "introduce graphql"
Mneme HQ 是一个用于 AI 协助开发的架构治理层。它通过强制执行每个 AI 调用的架构决策来实现这一点。
Mneme HQ 需要 Python 3.11+、anthropic >= 0.25.0 和 python-dotenv >= 1.0.0 等依赖项。
Mneme HQ v0.4 将版本化的 ADR markdown 文件编译成一个确定性的活跃约束集。可以使用 API extras 进行安装:pip install -e ".[api]" uvicorn app.api:app --reload
Mneme HQ 的使用示例:通过它来回答问题,例如‘是否应该从头开始重建检索系统’。
Mneme HQ 的配置说明包括 MCP、env 和关键参数的设置。
Mneme HQ 的 API 层提供了一个核心 API,通过 pip install -e ".[api]" 可以安装。
Mneme HQ 的工作流包括添加新决策、编辑 .env 文件和设置 Anthropic API 密钥等步骤。
该项目提供了一种强制执行架构决策的方式,提高了开发效率和质量,但其复杂度较高,需要仔细评估和使用。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
总体来看,开源Cursor规则:Enforce architectural decisions in AI-assisted development 是一款质量良好的Cursor规则,在同类工具中具备一定竞争力。AI Skill Hub 将持续追踪其更新动态,建议收藏备用,结合自身场景选择合适时机引入使用。
| 原始名称 | mneme |
| 原始描述 | 开源Cursor规则:Enforce architectural decisions in AI-assisted development.。⭐9 · HTML |
| Topics | cursor_ruleadrai-agentai-agentsai-codingai-governancehtml |
| GitHub | https://github.com/TheoV823/mneme |
| License | MIT |
| 语言 | HTML |
收录时间:2026-05-26 · 更新时间:2026-05-30 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端