use this Cursor slash command to get insights into how you use Cursor, your model usage, and advice to improve how you use Cursor.
(inspired by Claude Code's /insights command)
--------------------
# Cursor Insights
Generate a comprehensive analysis of your Cursor AI usage, projects, and workflow patterns. Present findings in a visually engaging format.
## Data Collection
Run these commands to gather metrics (run all in parallel):
### 1. AI Code Generation Stats
```bash
sqlite3 ~/.cursor/ai-tracking/ai-code-tracking.db "
SELECT
COUNT(*) as total_generations,
MIN(date(createdAt/1000, 'unixepoch')) as first_day,
MAX(date(createdAt/1000, 'unixepoch')) as last_day,
COUNT(DISTINCT date(createdAt/1000, 'unixepoch')) as active_days
FROM ai_code_hashes;
"
```
### 2. Model Usage Breakdown
```bash
sqlite3 ~/.cursor/ai-tracking/ai-code-tracking.db "
SELECT model, COUNT(*) as count
FROM ai_code_hashes
WHERE model IS NOT NULL
GROUP BY model
ORDER BY count DESC
LIMIT 10;
"
```
### 3. Source Type Stats
```bash
sqlite3 ~/.cursor/ai-tracking/ai-code-tracking.db "
SELECT source, COUNT(*) as count
FROM ai_code_hashes
GROUP BY source;
"
```
### 4. File Extension Breakdown
```bash
sqlite3 ~/.cursor/ai-tracking/ai-code-tracking.db "
SELECT fileExtension, COUNT(*) as count
FROM ai_code_hashes
WHERE fileExtension IS NOT NULL
GROUP BY fileExtension
ORDER BY count DESC
LIMIT 10;
"
```
### 5. Daily Activity (Last 14 Days)
```bash
sqlite3 ~/.cursor/ai-tracking/ai-code-tracking.db "
SELECT date(createdAt/1000, 'unixepoch') as day, COUNT(*) as generations
FROM ai_code_hashes
GROUP BY day
ORDER BY day DESC
LIMIT 14;
"
```
### 6. Project Count
```bash
ls -d ~/.cursor/projects/*/ 2>/dev/null | wc -l
```
### 7. Agent Transcript Count (All Projects)
```bash
find ~/.cursor/projects -name "*.jsonl" -path "*/agent-transcripts/*" 2>/dev/null | wc -l
```
### 8. Custom Commands Count
```bash
ls ~/.cursor/commands/*.md 2>/dev/null | wc -l
```
### 9. Active Projects (with agent transcripts)
```bash
find ~/.cursor/projects -name "*.jsonl" -path "*/agent-transcripts/*" 2>/dev/null | sed 's|.*/projects/||' | cut -d'/' -f1 | sort -u
```
## Analysis & Presentation
After gathering data, present findings in these sections:
### YOUR IMPACT
Show headline stats:
- **Total AI Generations**: [total from query 1]
- **Active Days**: [active_days] days over [date range]
- **Projects Worked On**: [project count]
- **Agent Sessions**: [transcript count]
### MODEL PREFERENCES
Analyze model usage:
- Calculate percentage of each model
- Identify primary model (highest usage)
- Note if using thinking/reasoning models (opus-thinking, sonnet-thinking)
- Identify coding-specific models (codex variants)
### TECH STACK INSIGHTS
From file extensions:
- Identify primary language (tsx/ts = TypeScript/React, py = Python, swift = iOS, etc.)
- Calculate frontend vs backend ratio if applicable
- Note any specialized files (prisma, sql = database work)
### HOW YOU WORK
Analyze patterns:
- **Source breakdown**: composer vs tab completions percentage
- **Session depth**: avg transcripts per active project
- **Custom commands**: whether you've built workflow automation
### QUICK WINS
Based on analysis, suggest 1-3 actionable improvements:
1. **If low custom command count (<5)**: "Try creating custom slash commands for repetitive tasks like `/commit`, `/review-pr`, or `/debug`"
2. **If heavy single-model usage (>80% one model)**: "Experiment with other models - try [fastest model] for quick edits, [thinking model] for complex refactors"
3. **If no thinking models used**: "For complex architectural decisions, try Claude 4.5 Opus (Thinking) for deeper reasoning"
4. **If mostly tab completions, few composer sessions**: "Shift to Composer/Agent mode for multi-file tasks - it handles context better than sequential tab completions"
5. **If many projects but few with transcripts**: "Consider using Agent mode more consistently across projects for better workflow"
### WHAT'S WORKING
Identify positive patterns:
- If using multiple models: "Model switching - matching tool to task complexity"
- If high custom command usage: "Workflow automation - your slash commands save time"
- If consistent daily activity: "Regular coding rhythm - [X] active days shows discipline"
- If high composer usage: "Agent-first approach - leveraging AI for full-context assistance"
## Output Format
Present the analysis with clear visual hierarchy using markdown headers, bullet points, and bold text for key metrics. Keep explanations brief and actionable. End with one specific, personalized suggestion for improving workflow based on the data.