---
title: "Bringing FastApply Back to Cursor with MCP"
url: "https://www.morphllm.com/blog/cursor-mcps"
description: "How Morph MCP Server restores 10,500 tok/sec edits to Cursor and adds Warp-Grep for better context retrieval"
date: "2025-11-24"
author: "Tejas Bhakta"
---
# Bringing FastApply Back to Cursor with MCP

Cursor used to ship with a fast apply model. Then they pulled it. Now every edit you make runs back through the main model, and if you've felt Cursor get slower and pricier on big files lately, that's why. We built an MCP server that puts the apply model back, with FastApply at 10,500 tok/sec and a Warp-Grep search agent alongside it. In our tests edits land about 35% faster end to end than search-and-replace, with higher accuracy and lower token cost. It's one config file, and nothing about how you use Cursor changes.

## What actually broke

Once the specialized apply model was gone, a reasoning model started doing the merging. When you ask for a one-line change, the main model rewrites the entire file to make it, which is slow and burns tokens, and on a large file it starts hallucinating lines that were never there. Using Claude or GPT to merge a diff is like reaching for GPT-4 to run `git merge`. It'll work, technically, but you're paying a reasoning model to do a mechanical job it isn't built for and doesn't do well.

## Why MCP, and why FastApply

The Model Context Protocol is what makes this possible at all. It's the hook Cursor gives you for plugging in your own tools. We used it to write a server that steps in ahead of Cursor's default edit flow, ships the change off to FastApply (our 10,500 tok/sec merge model), and returns the merged file, usually inside one to three seconds.

The same server also ships Warp-Grep, a search sub-agent in the spirit of Cognition's SWE-grep but open to anyone. Cursor's built-in grep is a plain text match, and text matches keep missing context that lives one file over from where you searched. Warp-Grep sticks a small planning model in front of the search, runs it over several steps, and then sorts what came back by whether it's genuinely relevant rather than whether a string lined up by luck.

Both of those, the fast merge and the smart search, live in the same server, and both come online the moment you add it. So the only real work is the config, which is about a minute.

## Install (about 60 seconds)

Everybody knows that fiddly setup kills a tool, and almost nobody designs around it anyway. We did. There's no build and nothing to download. You add a block to `~/.cursor/mcp.json`, the config file Cursor already reads, and paste your API key from [the dashboard](https://morphllm.com/dashboard/api-keys) into the placeholder:

```json
{
  "mcpServers": {
    "filesystem-with-morph": {
      "command": "npx",
      "args": ["@morphllm/morphmcp"],
      "env": {
        "MORPH_API_KEY": "your-api-key-here",
        "ENABLED_TOOLS": "all"
      }
    }
  }
}
```

Restart Cursor and you're running.

## What the numbers look like

These come from [our benchmarks](https://morphllm.com/benchmarks) against search-and-replace on real codebases. Apply latency sits in the one-to-three-second range. End to end, edits come out roughly 35% faster, and the average across our runs lands closer to 46% faster than search-and-replace.

Round trips are where the speed comes from. Think about a file you want to change in five places. Search-and-replace treats that as five separate tool calls, plus the bookkeeping of keeping them in order and not stepping on itself. FastApply takes the same five edits in one call. You describe all of them, it merges them in a single pass, and there's simply less to coordinate, so the whole thing wraps up sooner.

Warp-Grep saves time from a different direction. What it does is put a planning step in front of ripgrep. It reads what you asked, works out a short search plan, runs a few ripgrep passes, then reranks the hits by relevance and gives you back the best few with their surrounding code. The upshot is that far less junk ends up in context, which is really what lets the agent zero in on the right code.

## How FastApply works under the hood

There are two ways people usually merge an edit, and FastApply is neither. It's not a full-file rewrite, and it's not a brittle line diff. It's a small model trained to do one thing, and the way you talk to it is you hand over the original code and the snippet describing your change:

```typescript
{
  original_code: "def calculate(x):\n    return x * 2",
  edit_snippet: "def calculate(x):\n    # Add validation\n    // ... existing code ..."
}
```

Notice the snippet doesn't spell out the whole function. It says "add validation here" and leaves the rest as a marker. FastApply fills the gap and streams the finished function back at 10,500 tok/sec:

```python
def calculate(x):
    # Add validation
    if x < 0:
        raise ValueError("x must be positive")
    return x * 2
```

The trick behind that is mostly restraint. The model treats `// ... existing code ...` as an instruction to leave a section alone, and it holds onto the structure around the edit: the indentation, the scope, the imports, a variable being renamed three lines down. None of this needs reasoning, and it doesn't do any, which is the point. It's pattern-matching against shapes it was trained on. It also decodes quickly by using the original file as a prior, guessing the next tokens straight from code it can already see.

## Warp-Grep in practice

Plain grep matches a regex and hands you every line that hit. Warp-Grep runs a small agent loop that folds grep together with an understanding of what you're actually looking for.

Ask it "where do we handle rate limiting?" and it plans a search instead of firing one regex:

```bash
1. rg "rate.?limit" --type ts
2. rg "RateLimiter|Throttle" --type ts  
3. Read top 5 files
4. Rank by: class definitions > usage > comments
5. Return top 3 with surrounding context
```

It runs $0.30 per 1M input tokens and $0.30 per 1M output.

## A few configuration notes

If you'd rather not hand it the extra filesystem access and only want the merges, flip the all-tools flag off in the env block:

```json
{
  "env": {
    "MORPH_API_KEY": "your-key",
    "ENABLED_TOOLS": "edit_file"  // Only edit_file tool
  }
}
```

The server then exposes `edit_file` and nothing else. Otherwise it runs in what I call workspace mode, where it works out your project root on its own by looking for a `.git` or a `package.json`. You never hardcode a path, and it just comes along to whatever project you open next. The only reason to override any of that is if you specifically want it locked to one directory, and for that you pass the path as a second argument after the package name.

## Where it earns its keep

The place you feel it first is a file that needs several edits in one go. FastApply takes them all in a single call, where search-and-replace would burn a round trip on each chunk. Pulling context from across a handful of files is the next one, since Warp-Grep grabs it in a single shot and you skip the grep-and-paste dance entirely.

For anyone building agents on Cursor, there's a quieter win: better apply accuracy means fewer retries, and a retry you never had to run is the cheapest speedup there is. The last one is small but I use it constantly. Because the merge model reads structure instead of matching exact strings, you can drop in a suggested change without babysitting the whitespace to make it line up.

## Against Cursor's old native apply

Cursor's native apply was Llama-3-70B under the hood. It moved at roughly 1,000 tok/sec, tapped out around 400-line files, had no API you could reach, and did no semantic search. FastApply is a much smaller model trained specifically to merge code, with speculative decoding on top, and it's better on every one of those axes. It's about ten times quicker at 10,500 tok/sec, it handles files well past 1,500 lines, you can call it over the API, and Warp-Grep rides along with it. The one place the old model wins is the bill, since it was baked into your Cursor plan and FastApply isn't. FastApply runs $0.80 per 1M input tokens and $1.20 per 1M output.

## Where it stops

A few things FastApply won't do. It won't write code from a blank file, so Claude or GPT stays your author. It won't reason or plan, because the whole job is merging and nothing else. And it needs the `// ... existing code ...` markers in a snippet to know which parts to keep untouched.

Warp-Grep's rough edges are elsewhere. The local provider expects ripgrep already installed. It does its best work on structured languages, so Python, TypeScript, and Go get more out of it than, say, a pile of shell scripts. And planning before it searches costs about 300ms per call.

One more current limit: the merge tops out at 1,500-line files today, though we're already training on 2,500-line context.

## What you walk away with

The short version is that installing Morph MCP puts a 10,500 tok/sec apply model back in Cursor, landing edits in one to three seconds and running roughly 35% faster end to end than search-and-replace. You also get Warp-Grep for semantic search, and accuracy high enough that the retry loop mostly disappears. It's the one config file, and it rides along to every Cursor project you open.

[Get API key](https://morphllm.com/dashboard/api-keys) • [Full MCP docs](https://docs.morphllm.com/guides/mcp) • [Warp-Grep docs](https://docs.morphllm.com/sdk/components/warp-grep)

Pricing is $0.80 per 1M input and $1.20 per 1M output for FastApply, and $0.30 per 1M tokens for Warp-Grep. There's a free tier of 100k tokens a month to try it.

## The point underneath it

Good coding tools keep reasoning and execution apart. Cursor's main models should decide what to change. FastApply should do the merge, fast. Warp-Grep should find the context, by meaning rather than by string. That split is how a coding agent gets both accurate and quick, and it's what you're plugging into Cursor here.
