MCP.so
Sign In

Overview

What is MCP Language Server?

MCP Language Server is a Model Context Protocol server that runs a language server and provides tools for communicating with it, enabling LLMs to precisely understand types, relationships, and symbol references in large codebases.

How to use MCP Language Server?

Install Go and a language server (e.g., pyright, tsserver, gopls, rust-analyzer). Fetch the server with go install github.com/isaacphi/mcp-language-server@latest. Configure your MCP client (e.g., Claude Desktop) with a JSON entry specifying the go command, --workspace, --lsp, and any language server arguments after --.

Key features of MCP Language Server

  • Retrieves complete source code definitions of any symbol.
  • Locates all usages and references of a symbol.
  • Provides diagnostic warnings and errors for files.
  • Retrieves and executes code lens hints.
  • Applies multiple text edits to files programmatically.
  • Handles workspace/applyEdit requests from the language server.

Use cases of MCP Language Server

  • Letting an LLM navigate and edit a large codebase with accurate symbol understanding.
  • Automating refactoring operations that require precise type and reference knowledge.
  • Integrating language server capabilities (diagnostics, code lens) into MCP‑based workflows.
  • Enabling LLMs to add imports, format code, or apply other LSP‑driven edits.

FAQ from MCP Language Server

Which language servers are supported?

Tested with pyright (Python), tsserver (TypeScript), gopls (Go), and rust-analyzer (Rust), but it should be compatible with many more.

What are the runtime dependencies?

Go must be installed. You also need to install a language server for your codebase (e.g., via npm, go install, or rustup).

Where does my data live?

All operations run locally on your machine; the server accesses files in your specified workspace directory and communicates with the local language server via stdio.

What are the current limitations?

The project is pre‑beta quality. Not all LSP features are implemented; missing items include hover info and code actions. Context/cancellation handling and configuration options are still being improved.

How does the server communicate with the client?

MCP Language Server uses the MCP protocol over stdio. It leverages mcp-golang for MCP communication and edited code from gopls for LSP protocol handling.

Tags

More from Other