Fast Context MCP

Fast Context MCP

Enables AI-driven semantic code search via natural language queries, integrating with MCP clients like Claude Desktop to retrieve relevant code context from any codebase.

Category
Visit Server

README

Fast Context MCP

AI-driven semantic code search via reverse-engineered Windsurf protocol (Python implementation).

Python License: MIT MCP

Overview

Fast Context MCP provides an AI-powered semantic code search tool through the Model Context Protocol (MCP). It leverages a reverse-engineered Windsurf protocol to deliver intelligent code context retrieval for LLMs and development workflows.

Features

  • AI-Powered Semantic Search: Natural language queries to find relevant code
  • MCP Server Integration: Compatible with MCP-enabled clients (Claude Desktop, etc.)
  • Protobuf Protocol: Efficient binary communication with Windsurf API
  • Tree-based Context: Includes directory structure for better code understanding
  • Multi-language Support: Works with any codebase (Python, JavaScript, Go, etc.)

Installation

From PyPI (Recommended)

pip install fast-context-mcp

From Source

git clone https://github.com/YOUR_USERNAME/fast-context-mcp-py.git
cd fast-context-mcp-py
pip install -e .

Usage

As an MCP Server

Add to your Claude Desktop configuration (claude_desktop_config.json):

{
  "mcpServers": {
    "fast-context": {
      "command": "python",
      "args": ["-m", "fast_context_mcp.server"]
    }
  }
}

Programmatic Usage

from fast_context_mcp.search import search_with_content

result = search_with_content(
    query="Find the authentication middleware",
    project_root="/path/to/your/project"
)
print(result)

Available Tools

search_code

Search for relevant code in a codebase using AI-powered semantic search.

Parameters:

  • query (string): Natural language description of what you're looking for
  • project_root (string): Absolute path to the project root directory

Returns: JSON-formatted search results with relevant file paths and line ranges.

Architecture

fast_context_mcp/
├── core.py        # Core search implementation & API communication
├── search.py      # Search orchestration and result formatting
├── server.py      # MCP server implementation
├── protobuf.py    # Protobuf encoding/decoding
├── executor.py    # Tool execution with context management
└── rg_installer.py # Ripgrep auto-installer

Protocol Details

The project implements a reverse-engineered version of Windsurf's internal protocol:

  1. Connect Frame: Binary protobuf handshake with magic bytes (0x0001)
  2. Session Management: UUID-based session tracking
  3. Tool Definitions: JSON Schema-based tool specifications
  4. Response Streaming: Chunked protobuf responses with gzip compression

Development

Setup

# Install development dependencies
pip install -e ".[dev]"

Running Tests

pytest

Linting

ruff check .
ruff format .

License

MIT License - see LICENSE file for details.

Acknowledgments

Disclaimer

This project is a reverse-engineered implementation for educational purposes. It is not affiliated with or endorsed by Codeium/Windsurf.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured