.rightnowrules - Personalized AI Guidelines

RightNow AI’s .rightnowrules feature provides hardware-aware, personalized AI assistance tailored to your CUDA development workflow and GPU architecture.

Overview

The .rightnowrules file contains custom AI guidelines that enhance every interaction - from chat conversations to code completions. It combines:
  • Hardware Detection: Automatic GPU architecture analysis
  • User Preferences: Your experience level and optimization focus
  • Project Context: Workspace-specific CUDA development guidelines

How It Works

Auto-Generation

Automatically creates personalized rules based on detected hardware and user preferences

AI Integration

Seamlessly integrates with chat, autocomplete, and code editing features

Creating .rightnowrules

Command Palette Method:
  1. Open Command Palette (Ctrl+Shift+P)
  2. Run: RightNow: Generate .rightnowrules File
  3. Confirm hardware detection and preferences
  4. File created in workspace root
Auto-Suggestion:
  • RightNow AI detects CUDA files (.cu, .cuh, .cuf) in your workspace
  • Shows notification when no .rightnowrules exists
  • Click “Generate” for instant setup

Hardware-Aware Generation

RightNow AI automatically detects and optimizes for your specific GPU:

Example Generated Content

# CUDA Development Guidelines  
# Auto-generated for Windows on 1/4/2025

**Hardware:** RTX 4090 (Ada Lovelace) | CUDA 12.3

**User Profile:** Intermediate developer | machine_learning focus | balanced optimization

**Key Guidelines:**
- Optimize memory coalescing and shared memory usage
- Balance occupancy with register pressure  
- Prioritize tensor operations and mixed precision when available
- Your Ada Lovelace GPU supports 3rd-gen tensor cores for AI workloads

## My Preferences
# Add your specific guidelines here:
# - Coding style (e.g., "prefer explicit memory management")
# - Performance targets (e.g., "optimize for latency < 10ms")  
# - Project constraints (e.g., "limited to 4GB GPU memory")
# - Architecture preferences (e.g., "focus on Ampere features")

Integration with AI Features

Chat Assistant

System messages include your .rightnowrules as context for all conversations

Code Completion

Autocomplete respects your guidelines and coding preferences

Quick Edit

Ctrl+K editing follows your optimization priorities and style

Multi-Workspace Support

  • Per-Workspace Rules: Each workspace folder can have its own .rightnowrules
  • Rule Combination: Multiple workspace folders combine their rules intelligently
  • Context Switching: AI automatically adapts when switching between projects

Profiling Data Persistence

RightNow AI maintains comprehensive profiling history in .rightnow/profiling/kernels.json for tracking optimization progress across sessions.

File Structure

.rightnow/
└── profiling/
    └── kernels.json  # Persistent profiling database

What Gets Stored

Example Data Structure

{
  "version": "1.0",
  "lastUpdated": "2024-01-31T10:00:00Z",
  "kernels": {
    "file:///C:/projects/matmul.cu:matrixMul:a1b2c3:L45": {
      "kernelName": "matrixMul",
      "sourceFile": "matmul.cu", 
      "lineNumber": 45,
      "sessions": [
        {
          "executionTime": 12.5,
          "smEfficiency": 85.2,
          "memoryThroughput": 450.8,
          "occupancy": 68.4,
          "l1CacheHitRate": 89.3,
          "recommendations": [
            "Consider increasing occupancy by reducing register usage",
            "Memory access pattern is well coalesced"
          ],
          "timestamp": 1706698800000,
          "performance": "fast"
        }
      ]
    }
  }
}

Benefits

Optimization Tracking

View performance improvements over time and identify regression points

Session Persistence

Profiling data survives editor restarts and code modifications

Team Collaboration

Share profiling data across team members for collaborative optimization

Smart Identification

Content-based kernel IDs preserve history through code changes

Configuration

Both features work automatically with minimal setup: User Preferences (Settings → RightNow AI):
  • cudaExperienceLevel: Beginner, Intermediate, Expert
  • cudaPrimaryUseCase: ML, Scientific, Graphics, General
  • cudaOptimizationFocus: Performance, Memory, Power, Balanced
File Management:
  • .rightnowrules: Version control recommended for team guidelines
  • .rightnow/profiling/: Add to .gitignore for personal profiling data
Pro tip: Commit .rightnowrules to share team coding guidelines, but keep .rightnow/profiling/ local for individual optimization tracking.