Session-Pinned Rules: Attach specific rules to keep them active throughout a session

Feature request for product/service

Cursor IDE

Describe the request

The Problem

Cursor rules (.cursorrules or project rules) are powerful, but during longer sessions they tend to fade from the AI’s active context. The AI might follow them at first, then gradually “forget” or deprioritize them as the conversation grows.

For workflows that depend on specific rules being followed consistently (like checking schemas before writing code, using specific frameworks, or following naming conventions), this drift causes frustration and wasted time reminding the AI.

Proposed Solution: Session-Pinned Rules

Allow users to attach/pin specific rules to a session, similar to how files can be attached. This would:

  1. Rule Library - Show individual rules from .cursorrules as selectable items
  2. Session Attachment - Let users pin specific rules to the current session with a single click
  3. Persistent Refresh - Pinned rules stay in active context throughout the session
  4. Visual Indicator - Show which rules are currently pinned (like attached files show in the context bar)

Example Use Case

I have a “MindMeld” rule that requires the AI to check .cursor/schema-index.json before writing any Salesforce code. Instead of hoping the AI remembers this deep in a session, I could pin “Use MindMeld” and it would stay enforced.

Why This Matters

  • Selective Enforcement - Apply only relevant rules for the current task
  • Context Efficiency - Don’t waste context window on unneeded rules
  • Better Recall - Pinned rules stay active instead of fading
  • Workflow Consistency - Critical patterns stay enforced throughout the session

Bonus Ideas

  • Quick-pin directly from the rules file UI
  • Rule templates that can be shared across projects
  • Priority flag for rules that should auto-pin in certain project types

Would love to hear if others experience the “rule drift” problem and would find this useful! :raising_hands:

Hey, thanks for the detailed feature request.

The “rule drift” issue is known. Rules are sent at the start of a conversation, but in long sessions they can get pushed out of context when it fills up. This is discussed in a few threads:

Right now there’s no way to “pin” rules or force them to apply for the whole session. Your idea (pinning rules like files, a rule library, visual indicators) is interesting.

Current workarounds:

  • Start a new chat when the rules stop working
  • Use models with a longer context window
  • Add critical rules directly into the prompt (“Reminder: check schema-index.json”)

Good feedback. The team definitely sees this as a common issue.