RIPER Modes - johnpeterman72/CursorRIPER.sigma GitHub Wiki

๐Ÿ”„ RIPER Modes Explained

The heart of CursorRIPERโ™ฆฮฃ is the RIPER modal system - five distinct operational modes that guide both you and the AI through a structured development workflow.

๐Ÿ“‹ Mode Overview

Mode Symbol Command Purpose Key Restriction
Research ๐Ÿ” ฮฉโ‚ /r Gather information Cannot write code
Innovate ๐Ÿ’ก ฮฉโ‚‚ /i Explore solutions Cannot implement
Plan ๐Ÿ“ ฮฉโ‚ƒ /p Design approach Cannot execute
Execute โš™๏ธ ฮฉโ‚„ /e Implement solution Cannot search web
Review ๐Ÿ”Ž ฮฉโ‚… /rev Validate results Cannot modify

๐Ÿง  The RIPER Philosophy

Each mode represents a distinct phase of problem-solving:

  1. Understand the problem (Research)
  2. Explore possible solutions (Innovate)
  3. Design the approach (Plan)
  4. Build the solution (Execute)
  5. Verify the results (Review)

This separation prevents common pitfalls like:

  • ๐Ÿšซ Coding before understanding requirements
  • ๐Ÿšซ Over-engineering during implementation
  • ๐Ÿšซ Changing design while coding
  • ๐Ÿšซ Missing validation steps

๐Ÿ” Research Mode (ฮฉโ‚)

Symbol Definition:

ฮฉโ‚ = ๐Ÿ”R โŸถ โ„™(ฮฉโ‚) โŸถ +๐•‹[0:3] -๐•‹[4:15]

Purpose:

Gather information, analyze existing code, understand requirements.

Permissions:

โ„™(ฮฉโ‚) = {R: โœ“, C: โœ—, U: โœ—, D: โœ—}
  • โœ… Read everything
  • โŒ Create nothing
  • โŒ Update nothing
  • โŒ Delete nothing

Allowed Operations:

  • Read files and documentation
  • Analyze code structure
  • Ask clarifying questions
  • Document findings
  • Search web for information
  • Review git history

Forbidden Operations:

  • Write any code
  • Modify files
  • Create new files
  • Make design decisions
  • Suggest implementations

Example Usage:

/research

"Analyze the current authentication system and identify potential security vulnerabilities"

!af src/auth/login.js     # Add file to context
!ad src/auth/            # Add directory
!ag feature/auth-update  # Add git branch

Memory Updates:

  • ๐Ÿ“‹ projectbrief.md - Requirements captured
  • ๐Ÿ’ป techContext.md - Technical findings
  • ๐Ÿ”ฎ activeContext.md - Research focus

Best Practices:

  1. Cast a wide net initially
  2. Document all findings
  3. Ask "why" questions
  4. Verify assumptions
  5. Check existing documentation

Common Mistakes:

  • โŒ Trying to fix issues immediately
  • โŒ Skipping to implementation ideas
  • โŒ Making design decisions
  • โŒ Narrow focus too early

๐Ÿ’ก Innovate Mode (ฮฉโ‚‚)

Symbol Definition:

ฮฉโ‚‚ = ๐Ÿ’กI โŸถ โ„™(ฮฉโ‚‚) โŸถ +๐•‹[4:6] -๐•‹[8:15]

Purpose:

Explore creative solutions, evaluate alternatives, brainstorm approaches.

Permissions:

โ„™(ฮฉโ‚‚) = {R: โœ“, C: ~, U: โœ—, D: โœ—}
  • โœ… Read for reference
  • ๐ŸŸก Create conceptually only
  • โŒ Update nothing
  • โŒ Delete nothing

Allowed Operations:

  • Suggest new approaches
  • Explore alternatives
  • Evaluate pros/cons
  • Create conceptual designs
  • Reference best practices
  • Discuss patterns

Forbidden Operations:

  • Write actual code
  • Create real files
  • Implement solutions
  • Make final decisions
  • Modify existing code

Example Usage:

/innovate

"What are modern alternatives to our session-based authentication?"

!ac AuthenticationConcepts   # Track concepts
!adoc "OAuth2 Best Practices" # Reference docs
!an "Security Ideas"         # Notepad for ideas

Memory Updates:

  • ๐Ÿ›๏ธ systemPatterns.md - Architectural ideas
  • ๐Ÿ”ฎ activeContext.md - Innovation focus
  • ๐Ÿ“Š progress.md - Explored options

Best Practices:

  1. Think outside the box
  2. Consider multiple approaches
  3. Evaluate trade-offs
  4. Reference industry standards
  5. Document all ideas

Common Mistakes:

  • โŒ Getting too detailed
  • โŒ Committing to one approach
  • โŒ Writing pseudo-code
  • โŒ Ignoring alternatives

๐Ÿ“ Plan Mode (ฮฉโ‚ƒ)

Symbol Definition:

ฮฉโ‚ƒ = ๐Ÿ“P โŸถ โ„™(ฮฉโ‚ƒ) โŸถ +๐•‹[7:9] -๐•‹[10:15]

Purpose:

Create detailed specifications, sequence steps, define success criteria.

Permissions:

โ„™(ฮฉโ‚ƒ) = {R: โœ“, C: โœ“, U: ~, D: โœ—}
  • โœ… Read for planning
  • โœ… Create specifications
  • ๐ŸŸก Update plan documents only
  • โŒ Delete nothing

Allowed Operations:

  • Create specifications
  • Design architecture
  • Sequence implementation
  • Define interfaces
  • Plan test cases
  • Identify protection needs

Forbidden Operations:

  • Write production code
  • Implement features
  • Execute the plan
  • Modify existing code

Example Usage:

/plan

"Create a detailed plan to implement JWT authentication"

# Output: Numbered checklist
1. Install dependencies (jsonwebtoken, bcrypt)
2. Create JWT utility module
3. Update user model for tokens
4. Modify login endpoint
5. Create refresh endpoint
6. Update auth middleware
7. Add tests
8. Update documentation

Memory Updates:

  • ๐Ÿ”ฎ activeContext.md - Plan details
  • ๐Ÿ“Š progress.md - Milestones set
  • ๐Ÿ›ก๏ธ protection.md - Protection planned

Best Practices:

  1. Be extremely detailed
  2. Number every step
  3. Consider edge cases
  4. Plan protection strategy
  5. Define success criteria

Common Mistakes:

  • โŒ Vague specifications
  • โŒ Missing steps
  • โŒ No success criteria
  • โŒ Forgetting tests

โš™๏ธ Execute Mode (ฮฉโ‚„)

Symbol Definition:

ฮฉโ‚„ = โš™๏ธE โŸถ โ„™(ฮฉโ‚„) โŸถ +๐•‹[10:12] -[improve,create,deviate]

Purpose:

Implement exactly according to plan, write code, create files.

Permissions:

โ„™(ฮฉโ‚„) = {R: โœ“, C: โœ“, U: โœ“, D: ~}
  • โœ… Read anything needed
  • โœ… Create new files/code
  • โœ… Update existing code
  • ๐ŸŸก Delete with caution

Allowed Operations:

  • Write code per plan
  • Create new files
  • Modify existing code
  • Run tests
  • Fix bugs
  • Add protection markers

Forbidden Operations:

  • Deviate from plan
  • Add unplanned features
  • Redesign on the fly
  • Search web (focus!)
  • Skip planned steps

Special Restriction:

๐Ÿšซ No web searches in EXECUTE mode! This maintains focus on implementation.

Example Usage:

/execute

"Implement step 2: Create JWT utility module"

# AI writes exactly what was planned
!af src/utils/jwt.js      # Track new file
!cp                       # Protect critical parts

Code Protection Example:

// !cp PROTECTED - JWT Configuration
const JWT_SECRET = process.env.JWT_SECRET;
const JWT_EXPIRES = '24h';
// !cp END-P

// !cc CRITICAL - Token Generation
export function generateToken(user) {
    return jwt.sign(
        { id: user.id, email: user.email },
        JWT_SECRET,
        { expiresIn: JWT_EXPIRES }
    );
}
// !cc END-C

Memory Updates:

  • ๐Ÿ“Š progress.md - Steps completed
  • ๐Ÿ›ก๏ธ protection.md - Protected code
  • ๐Ÿ”ฎ activeContext.md - Implementation focus

Best Practices:

  1. Follow plan exactly
  2. Protect while coding
  3. Test each step
  4. Document deviations
  5. Stay focused

Common Mistakes:

  • โŒ "Improving" the plan
  • โŒ Adding features
  • โŒ Skipping protection
  • โŒ Web searching

๐Ÿ”Ž Review Mode (ฮฉโ‚…)

Symbol Definition:

ฮฉโ‚… = ๐Ÿ”ŽRV โŸถ โ„™(ฮฉโ‚…) โŸถ +๐•‹[13:15] -[modify,improve]

Purpose:

Validate implementation, verify against requirements, identify issues.

Permissions:

โ„™(ฮฉโ‚…) = {R: โœ“, C: โœ—, U: โœ—, D: โœ—}
  • โœ… Read everything
  • โŒ Create nothing
  • โŒ Update nothing
  • โŒ Delete nothing

Allowed Operations:

  • Check code quality
  • Verify against plan
  • Run tests
  • Identify issues
  • Review protection
  • Validate requirements

Forbidden Operations:

  • Fix issues found
  • Modify code
  • Improve implementation
  • Change requirements
  • Add features

Example Usage:

/review

"Review JWT implementation against security requirements"

!af src/utils/jwt.js       # Review specific file
!ac generateToken         # Check function
!ag main...feature/jwt   # Compare branches

Review Outputs:

## Review Results:
โœ… PASS: JWT secret from environment
โœ… PASS: Token expiration set
โš ๏ธ WARN: No refresh token rotation
โŒ FAIL: Missing rate limiting

Memory Updates:

  • ๐Ÿ“Š progress.md - Review results
  • ๐Ÿ”ฎ activeContext.md - Issues found
  • ๐Ÿ“‹ projectbrief.md - Requirement status

Best Practices:

  1. Be thorough
  2. Check every requirement
  3. Verify protection
  4. Test edge cases
  5. Document findings

Common Mistakes:

  • โŒ Fixing issues immediately
  • โŒ Changing requirements
  • โŒ Skipping tests
  • โŒ Partial reviews

๐Ÿ”„ Mode Transitions

Standard Flow:

Research โ†’ Innovate โ†’ Plan โ†’ Execute โ†’ Review
   ฮฉโ‚         ฮฉโ‚‚        ฮฉโ‚ƒ      ฮฉโ‚„       ฮฉโ‚…

Transition Commands:

/r or /research   โ†’ Enter Research
/i or /innovate   โ†’ Enter Innovate
/p or /plan       โ†’ Enter Plan
/e or /execute    โ†’ Enter Execute
/rev or /review   โ†’ Enter Review

Valid Transitions:

  • โœ… Any mode to any mode
  • โœ… Skip modes if needed
  • โœ… Return to earlier modes
  • โœ… Emergency transitions

Transition Process:

  1. Backup current state
  2. Verify completion
  3. Update mode
  4. Apply permissions
  5. Load context
  6. Log transition

Context Updates:

Each transition updates context:

Research: [Docs, Folders, Git]
    โ†“
Innovate: [Code, Docs, Notepads]
    โ†“
Plan: [Files, Folders, Rules]
    โ†“
Execute: [Code, Files, Pinned]
    โ†“
Review: [Code, Files, Git]

๐ŸŽฏ Mode Selection Guide

When to Use Each Mode:

Research When:

  • Starting new feature
  • Investigating bugs
  • Understanding codebase
  • Gathering requirements
  • Checking documentation

Innovate When:

  • Need creative solutions
  • Exploring alternatives
  • Evaluating approaches
  • Brainstorming ideas
  • Considering patterns

Plan When:

  • Ready to specify
  • Need detailed steps
  • Defining architecture
  • Creating test plans
  • Setting milestones

Execute When:

  • Plan is complete
  • Ready to code
  • Implementing features
  • Fixing bugs
  • Creating files

Review When:

  • Implementation done
  • Need validation
  • Checking quality
  • Verifying requirements
  • Before deployment

๐Ÿ’ก Pro Tips

1. Trust the Process

The restrictions exist for good reasons. Embrace them!

2. Complete Each Phase

Don't skip steps. Each builds on the previous.

3. Use Appropriate Detail

  • Research: Broad investigation
  • Innovate: Creative exploration
  • Plan: Extreme detail
  • Execute: Precise implementation
  • Review: Thorough validation

4. Context Switching

Use !cm to automatically set mode-appropriate context.

5. Permission Awareness

Use !ckp to check what you can do in current mode.

๐Ÿšจ Common Issues

"Cannot write code"

  • Cause: Not in EXECUTE mode
  • Fix: Switch with /e

"Cannot search web"

  • Cause: In EXECUTE mode
  • Fix: Complete task, then /r

"Cannot modify plan"

  • Cause: In EXECUTE/REVIEW
  • Fix: Switch to PLAN with /p

"Operation not permitted"

  • Cause: Mode restriction
  • Fix: Check !ckp, switch modes

๐Ÿ“š Related Topics


โ† Framework Overview | Home | Memory System โ†’