How I Governed Cursor to Deliver a 50+ Module Enterprise App in 2 Weeks (using Meta-Rules)

Hi everyone,

I’ve been pushing Cursor to its absolute limits over the past few months. Recently, I delivered a production-grade Enterprise Security Management platform (6 business domains, 50+ modules, Spring Boot + Vue 3) from zero to acceptance in under 2 weeks.

Along the way, I realized something critical: when your codebase scales to 50+ modules, the bottleneck is no longer code generation — it’s governing Agent cognition.

Without constraints, the AI reads too many files, copies legacy patterns from old code, and drifts from the intended architecture. Here is how I solved it.


The Solution: A Generative Rule System (Meta-Rules)

I couldn’t write manual rules for every single module. Instead, I built a generative rule system in .cursor/rules/: 15 core Meta-Rules that instruct the AI on how to govern itself. These meta-rules guided the agent to automatically generate 6 domain-specific rules (asset.mdc, identity.mdc, etc.) — 21 rules total — which locked in the architecture for all 50+ modules without context decay.

My most crucial Meta-Rules include:

1. Design-is-Authority (design-is-authority.mdc)

The most impactful rule I wrote. It establishes that design documents are the sole authority for structure, naming, and logic. The agent is strictly forbidden from scanning legacy code for architecture patterns. This alone eliminated architecture drift and saved over 60% in wasted token reads.

2. Intent-Based Routing (workflow-router.mdc)

A routing table that intercepts vague natural language (“the dropdown is empty”) into deterministic document-reading pipelines.

Example AI thought process: Ontology (what should exist) → model.yaml (what’s configured) → backend registry (what’s implemented) → locate the gap.

3. Ontology-Driven Development (ontology-driven-dev.mdc)

A pipeline I created: PM Docs → AI extracts domain ontology → model.yaml (configuration) → code generation → auto-renders pages. I had a 35% field omission rate initially; with ODD, it dropped to near-zero.

4. The Self-Evolution Loop (rule-evolution.mdc)

When the Agent’s cognitive path is suboptimal, it documents the root cause, creates a before/after comparison with quantified improvement metrics, and rewrites its own rule. It’s a self-improving governance system.


Distributing the Workflows: cursor-genesis

I know many enterprise teams struggle with these same AI scaling issues. So I extracted these battle-tested patterns into open-source reusable “Atoms” and packaged them into an Enterprise Pack.

→ Repository: https://github.com/SYMlp/cursor-genesis

Three entry points depending on what you’re looking for:

  • See the full 21-rule production system (the actual .cursor/rules/ from this project, categorized and annotated): examples/source-project/

  • Use just the 4 universal Meta-Rules in your own project via Git sparse-checkout: stable/atoms/rules/enterprise/

  • Full Enterprise Pack with ODD methodology guide and setup instructions: stable/packs/enterprise/

Using Git sparse-checkout, you can inject these Meta-Rules into any new codebase in under a minute.


Would love to hear how other heavy Cursor users here are managing architecture drift at scale — and whether this kind of generative governance approach resonates with your workflow.

Cheers,
Shi Yimeng

Hi @TIm6!

This doesn’t seem to link to cursor-genesis. Did you mean to link somewhere else?

Hi @Colin !

Here’s a reply you can use: GitHub - SYMlp/cursor-genesis: cursor协作母版 · GitHub


Sorry about that! I’m new here and accidentally linked to the wrong repo. I’ve already updated the post with the correct link to cursor-genesis. Thanks for pointing it out!

Could you please help me set it back to public?

1 Like