# lynx

A local MCP server that answers what grep cannot: who calls this, what breaks if I change it, where the code behind a behaviour lives.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 10
- Author: lorenzo-cambiaghi
- License: Apache-2.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/lorenzo-cambiaghi/LynxMCP
- Updated: 2026-09-07
- HTML: https://affpapa.org/en/nevibecode/mcp/lynx

## What it does

LynxMCP indexes your repository and hands the agent retrieval tools: hybrid BM25 plus dense search, AST-aware chunking, and an optional code knowledge graph. Ask who inherits from `Field` or what breaks when `ApplyDamage` changes, and you get `file:line` on every edge plus the tests worth re-running. Library docs and PDFs can sit in the same index as your code, so the version you actually ship is what the agent reads.

Nothing leaves the machine. Install with `pipx install lynx-mcp` or `uv tool install lynx-mcp`, then run `lynx manager init`, add a source, and build the index with `lynx build`. The first build pulls a 130 MB embedding model, and the install itself takes roughly 460 MB on disk — no PyTorch. Python 3.10+ is required.

The tool set stays fixed no matter how many sources you add. Three profiles ship: `core` with 5 tools, `standard` with 10, and `full` with 17; pick one via `tools.profile` in `config.json` or `lynx serve --profile full`. Every tool also exists as a CLI command with the same name and output, and `--json` makes it scriptable. On a small repo that already fits the agent's context, the built-in tools are enough — Lynx earns its place on large codebases and stale framework docs.

## Requirements
- Needs: Python and uv (commands run via uvx)

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add lynx -- uvx lynx-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from lynx-mcp <command>

### Codex

**Platform CLI**
```bash
codex mcp add lynx -- uvx lynx-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from lynx-mcp <command>

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "lynx": {
            "command": "uvx",
            "args": [
                "lynx-mcp"
            ]
        }
    }
}
```
uvx runs the command named after the package; if the README names another one, use uvx --from lynx-mcp <command>

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "lynx": {
            "type": "stdio",
            "command": "uvx",
            "args": [
                "lynx-mcp"
            ]
        }
    }
}
```
uvx runs the command named after the package; if the README names another one, use uvx --from lynx-mcp <command>

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add lynx uvx lynx-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from lynx-mcp <command>

## When to use it
- trace every subclass of a class through the call graph instead of grep rounds
- work out which tests to re-run after touching a function
- find code by described behaviour when nothing matches literally
- index the docs of the exact library version in use
- search only files changed against a base branch

## Example prompts
- Who calls `ApplyDamage`, and what breaks if I change its signature?
- Find where session tokens get validated — by meaning, not by name.
- Show me everything that inherits from `Field`, with file and line for each class.

## Similar
- [sqry - Semantic Code Search](https://affpapa.org/en/nevibecode/mcp/verivus-oss-sqry-semantic-code-search.md) — MCP server · ★ 31
- [grepai-mcp-tools](https://affpapa.org/en/nevibecode/skills/grepai-mcp-tools.md) — skill · 715 installs
- [grepai-languages](https://affpapa.org/en/nevibecode/skills/grepai-languages.md) — skill · 704 installs
- [tldr-code](https://affpapa.org/en/nevibecode/skills/tldr-code.md) — skill · 503 installs
- [tldr-overview](https://affpapa.org/en/nevibecode/skills/tldr-overview.md) — skill · 485 installs
- [arbor](https://affpapa.org/en/nevibecode/mcp/arbor.md) — MCP server · ★ 162

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
