grepai-mcp-cursor

yoanbernabeu/grepai-skills · updated Apr 8, 2026

MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.

$npx skills add https://github.com/yoanbernabeu/grepai-skills --skill grepai-mcp-cursor
0 commentsdiscussion
summary

This skill covers integrating GrepAI with Cursor IDE using the Model Context Protocol (MCP).

skill.md

GrepAI MCP Integration with Cursor

This skill covers integrating GrepAI with Cursor IDE using the Model Context Protocol (MCP).

When to Use This Skill

  • Setting up GrepAI in Cursor
  • Enabling semantic search for Cursor AI
  • Configuring MCP for Cursor
  • Troubleshooting Cursor integration

What is Cursor?

Cursor is an AI-powered IDE that supports MCP for external tools. GrepAI integration gives Cursor's AI:

  • Semantic code search beyond simple text matching
  • Call graph analysis for understanding dependencies
  • Index-based code navigation

Prerequisites

  1. GrepAI installed
  2. Ollama running (or other embedding provider)
  3. Project indexed (grepai watch)
  4. Cursor IDE installed

Configuration

Step 1: Create MCP Config File

Create .cursor/mcp.json in your project root:

{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve"]
    }
  }
}

Step 2: Restart Cursor

Close and reopen Cursor for the config to take effect.

Step 3: Verify

Ask Cursor's AI:

"Search the codebase for authentication"

Cursor should use the grepai_search tool.

Global Configuration

For GrepAI in all Cursor projects, use global config:

Location

  • macOS: ~/.cursor/mcp.json
  • Linux: ~/.cursor/mcp.json
  • Windows: %APPDATA%\Cursor\mcp.json

Content

{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve"]
    }
  }
}

Per-Project Configuration

For project-specific settings:

{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve"],
      "cwd": "/absolute/path/to/project"
    }
  }
}

Available Tools

Once configured, Cursor has access to:

Tool Description
grepai_search Semantic code search
grepai_trace_callers Find function callers
grepai_trace_callees Find function callees
grepai_trace_graph Build call graphs
grepai_index_status Check index health

Usage Examples

Finding Code

Ask Cursor:

"Find code that handles user login"

Cursor uses grepai_search to find semantically related code.

Understanding Dependencies

Ask Cursor:

"What functions call validateToken?"

Cursor uses grepai_trace_callers to show all callers.

Code Navigation

Ask Cursor:

"Show me the call graph for processPayment"

Cursor uses grepai_trace_graph to display dependencies.

Cursor Settings Integration

Enable MCP in Settings

  1. Open Cursor Settings (Cmd+, / Ctrl+,)
  2. Search for "MCP"
  3. Ensure MCP is enabled

Verify MCP Status

  1. Open Command Palette (Cmd+Shift+P / Ctrl+Shift+P)
  2. Search "MCP"
  3. Check connected servers

Windsurf Configuration

Windsurf uses the same MCP format as Cursor:

Location

Create .windsurf/mcp.json:

{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve"]
    }
  }
}

Multiple Projects Setup

Option 1: Separate Configs

Each project has its own .cursor/mcp.json with appropriate cwd.

Option 2: Workspaces

# Create workspace
grepai workspace create dev
grepai workspace add dev /path/to/project1
grepai workspace add dev /path/to/project2
{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve", "--workspace", "dev"]
    }
  }
}

Environment Variables

If GrepAI uses environment variables (like API keys):

{
  "mcpServers": {
    "grepai": {
      "command": "grepai",
      "args": ["mcp-serve"],
      "env": {
        "OPENAI_API_KEY": "sk-..."
      }
    }
  }
}

Better: Set environment variables in your shell profile instead.

Troubleshooting

MCP Not Recognized

Problem: Cursor doesn't see GrepAI tools

Solutions:

  1. Check file location: .cursor/mcp.json in project root
  2. Verify JSON syntax (no trailing commas)
  3. Restart Cursor completely
  4. Check grepai is in PATH

Search Returns Nothing

Problem: Empty search results

Solutions:

  1. Ensure index exists: grepai status
  2. Run grepai watch first
  3. Verify working directory

Connection Errors

Problem: MCP connection failed

Solutions:

  1. Test manually: grepai mcp-serve
  2. Check Ollama: curl http://localhost:11434/api/tags
  3. Look at Cursor's developer console for errors

Wrong Results

Problem: Results from wrong project

Solutions:

  1. Set explicit cwd in config
  2. Check you opened the right folder in Cursor
  3. Use grepai_index_status to verify

Performance Tips

  1. Background daemon: Keep grepai watch --background running
  2. Use compact mode: MCP tools use compact by default
  3. Limit results: AI will request appropriate limits
  4. Index regularly: Especially after git pull

Comparison: Cursor vs Claude Code

Feature Cursor Claude Code
Config location .cursor/mcp.json ~/.claude/mcp.json
Setup command Manual JSON claude mcp add
Project scope Per-project or global Global
IDE integration Native Terminal

Best Practices

  1. Version control: Add .cursor/mcp.json to git (without secrets)
  2. Team setup: Document MCP config in README
  3. Keep index fresh: Run watch daemon
  4. Test locally: Verify grepai mcp-serve works first
  5. Use workspaces: For multi-project setups

Removing Integration

Delete .cursor/mcp.json and restart Cursor.

Or remove just GrepAI:

{
  "mcpServers": {
    // Remove grepai entry
  }
}

Output Format

Successful Cursor setup:

✅ GrepAI MCP Integration for Cursor

   Config: .cursor/mcp.json
   Server: grepai mcp-serve
   Status: Ready

   Available tools:
   - grepai_search
   - grepai_trace_callers
   - grepai_trace_callees
   - grepai_trace_graph
   - grepai_index_status

   Cursor AI can now search your code semantically!

   Test: Ask Cursor "search for authentication code"
how to use grepai-mcp-cursor

How to use grepai-mcp-cursor on Cursor

AI-first code editor with Composer

1

Prerequisites

Before installing skills in Cursor, ensure your development environment meets these requirements:

  • Cursor installed and configured on your development machine
  • Node.js version 16.0+ with npm package manager (verify with node --version)
  • Active project directory or workspace where you want to add grepai-mcp-cursor
2

Execute installation command

Execute the skills CLI command in your project's root directory to begin installation:

$npx skills add https://github.com/yoanbernabeu/grepai-skills --skill grepai-mcp-cursor

The skills CLI fetches grepai-mcp-cursor from GitHub repository yoanbernabeu/grepai-skills and configures it for Cursor.

3

Select Cursor when prompted

The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:

◆ Which agents do you want to install to?
│ ── Universal (.agents/skills) ── always included ────
│ • Amp
│ • Antigravity
│ • Cline
│ • Codex
│ ●Cursor(selected)
│ • Cursor
│ • Windsurf
4

Verify installation

Confirm successful installation by checking the skill directory location:

.cursor/skills/grepai-mcp-cursor

Reload or restart Cursor to activate grepai-mcp-cursor. Access the skill through slash commands (e.g., /grepai-mcp-cursor) or your agent's skill management interface.

Security & Verification Notice

We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.

Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.

List & Monetize Your Skill

Submit your Claude Code skill and start earning

GET_STARTED →

Use Cases

Task Automation & Efficiency

Automate repetitive workflows and reduce manual effort

Example

Generate reports, summarize documents, draft communications

Save 3-5 hours per week on routine tasks

Knowledge Enhancement

Learn new skills, understand complex topics, get expert guidance

Example

Explain concepts, provide examples, suggest learning resources

Accelerate learning and skill development by 2x

Quality Improvement

Enhance output quality through reviews, suggestions, and refinements

Example

Review drafts, suggest improvements, catch errors

Improve work quality by 30-40% with less effort

Implementation Guide

Prerequisites

  • Claude Desktop or compatible AI client with skill support
  • Clear understanding of task or problem to solve
  • Willingness to iterate and refine outputs

Time Estimate

15-45 minutes depending on use case complexity

Installation Steps

  1. 1.Install skill using provided installation command
  2. 2.Test with simple use case relevant to your work
  3. 3.Evaluate output quality and relevance
  4. 4.Iterate on prompts to improve results
  5. 5.Integrate into regular workflow if valuable

Common Pitfalls

  • Expecting perfect results without iteration
  • Not providing enough context in prompts
  • Using skill for tasks outside its intended scope
  • Accepting outputs without review and validation

Best Practices

✓ Do

  • +Start with clear, specific prompts
  • +Provide relevant context and constraints
  • +Review and refine all outputs before using
  • +Iterate to improve output quality
  • +Document successful prompt patterns

✗ Don't

  • Don't use without understanding skill limitations
  • Don't skip validation of outputs
  • Don't share sensitive information in prompts
  • Don't expect skill to replace human judgment

💡 Pro Tips

  • Be specific about desired format and style
  • Ask for multiple options to choose from
  • Request explanations to understand reasoning
  • Combine AI efficiency with human expertise

When to Use This

✓ Use When

Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.

✗ Avoid When

Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.

Learning Path

  1. 1Familiarize yourself with skill capabilities and limitations
  2. 2Start with low-risk, non-critical tasks
  3. 3Progress to more complex and valuable use cases
  4. 4Build expertise through regular use and experimentation

Discussion

Product Hunt–style comments (not star reviews)
  • No comments yet — start the thread.
general reviews

Ratings

4.528 reviews
  • Nia Martinez· Dec 20, 2024

    grepai-mcp-cursor reduced setup friction for our internal harness; good balance of opinion and flexibility.

  • Ava Okafor· Dec 16, 2024

    grepai-mcp-cursor is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Rahul Santra· Nov 15, 2024

    Useful defaults in grepai-mcp-cursor — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.

  • Kofi Martinez· Nov 11, 2024

    grepai-mcp-cursor has been reliable in day-to-day use. Documentation quality is above average for community skills.

  • Ava Park· Nov 7, 2024

    Keeps context tight: grepai-mcp-cursor is the kind of skill you can hand to a new teammate without a long onboarding doc.

  • Harper Jackson· Oct 26, 2024

    I recommend grepai-mcp-cursor for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.

  • Pratham Ware· Oct 6, 2024

    Registry listing for grepai-mcp-cursor matched our evaluation — installs cleanly and behaves as described in the markdown.

  • Kofi Zhang· Oct 2, 2024

    grepai-mcp-cursor fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Henry Wang· Sep 13, 2024

    Registry listing for grepai-mcp-cursor matched our evaluation — installs cleanly and behaves as described in the markdown.

  • Yash Thakker· Sep 9, 2024

    Keeps context tight: grepai-mcp-cursor is the kind of skill you can hand to a new teammate without a long onboarding doc.

showing 1-10 of 28

1 / 3