MCP Marketplace
BrowseHow It WorksFor CreatorsDocs
Sign inSign up
MCP Marketplace

The curated, security-first marketplace for AI tools.

Product

Browse ToolsSubmit a ToolDocumentationHow It WorksBlogFAQ

Legal

Terms of ServicePrivacy PolicyCommunity Guidelines

Connect

support@mcp-marketplace.ioTwitter / XDiscord

MCP Marketplace © 2026. All rights reserved.

Back to Browse

Lens MCP Server

by Segentic Lab
Developer ToolsModerate5.2MCP RegistryLocal
Free

Server data from the Official MCP Registry

Deterministic navigation maps over code + markdown for AI agents: 11 MCP tools (TS/JS/Python)

About

Deterministic navigation maps over code + markdown for AI agents: 11 MCP tools (TS/JS/Python)

Security Report

5.2
Moderate5.2Moderate Risk

lens-mcp is a well-architected code navigation MCP server with strong path validation, proper error handling, and no obvious security vulnerabilities. The codebase demonstrates defensive programming practices including sandboxed file access, honest truncation flags, and careful input validation. Minor code quality observations around error handling breadth do not materially impact security. Supply chain analysis found 5 known vulnerabilities in dependencies (2 critical, 3 high severity).

3 files analyzed · 9 issues found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

File System Read

Reads files on your machine. Normal for tools that analyze or process local data.

env_vars

Check that this permission is expected for this type of plugin.

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "io-github-segentic-lab-lens-mcp": {
      "args": [
        "-y",
        "lens-mcp"
      ],
      "command": "npx"
    }
  }
}

Documentation

View on GitHub

From the project's GitHub README.

lens-mcp

Deterministic navigation maps over code AND markdown — for AI agents. One MCP server, two lenses: tree-sitter for source (TypeScript / JavaScript / Python) and a markdown lens for docs. It answers "where is X and what's the shape of this project?" in one cheap call — so an agent spends context on thinking, not on browsing files.

Speaks the Model Context Protocol; works with any MCP client — Claude Code, Cursor, Codex, or your own agent.

Why

An agent orienting in an unfamiliar repo otherwise burns tokens ls-ing, grep-ing, and Reading whole files to find the one function or the right doc. lens returns the map instead of the territory:

  • function_body reads one function — often ~99% less context than Reading the file it lives in.
  • heading reads one doc section — the referenced heading and its subsections, nothing else.
  • map returns the whole project's surface — every code file's structure and every doc's outline — in a single call.

Every output is deterministic (real parsing, not a model summarizing), capped with an honest truncated flag, and framed by one contract:

lens is a navigation map. Use it to locate, then Read the real source/section before judging or modifying it. A signature is not the body; an outline is not the section.

Tools (12)

Orientation

ToolWhat it does
mapWhole-tree surface in one call: per code file → structure; per doc → title + outline. Both families, one response.
infoVersion, sandbox root, supported languages/extensions, tool list, every output cap, and the lens contract.
lens_systemInstall status, self-update (update.sh under the hood), and fetch the current AGENTS.md — lens's self-maintenance tool.

Code (tree-sitter — .ts .tsx .mts .cts .js .jsx .mjs .cjs .py)

ToolWhat it does
overviewOne file's imports, exports, classes (+ methods), top-level functions, with line ranges.
functionsEvery function incl. nested — signatures, params/types, parent scope, kind.
function_bodyVerbatim source of ONE function — the focused read.
commentsComments + TODO/FIXME/BUG/HACK/… markers (markersOnly for the debt list).
findLocate a function/method/class definition by name across a directory.

Docs (markdown — .md .markdown .mdx)

ToolWhat it does
outlineFull heading hierarchy (the TOC) with line numbers.
headingRead ONE section by heading text / slug / line number.
linksExtract inline / image / wikilink / autolink / reference links.
searchCase-insensitive full-text search across docs (heading hits ranked first).

Call a code tool on a .md (or a doc tool on a .ts) and it fails with a helpful pointer to the right tool — no silent confusion.

Honest by construction

  • Never silent data loss — a file with syntax errors returns hasErrors + parseErrors, still extracting what it can; unparseable files in map/find appear with an inline error, never vanish.
  • Caps everywhere — every list is bounded (see info.limits) and every cap is reported with the true total. A context-saving tool with unbounded output is self-refuting.
  • Path sandbox — only files under the server's working directory are readable; escaping symlinks are rejected. info reports the root.
  • Errors name the fix — {error, path, hint}, with isError set.

Install

One line clones, installs, and writes a ready-to-paste MCP config with this install's absolute path:

git clone https://github.com/segentic-lab/lens-mcp && cd lens-mcp && ./install.sh

No system packages and no native build — tree-sitter runs as WebAssembly, so it works anywhere Node 18+ runs (Linux, macOS, Windows via WSL/Git Bash). The installer checks Node, runs npm ci, builds (tsc → dist/), self-tests the full suite (138 tests), and generates mcp-config.json.

Register it with your client — the generated mcp-config.json looks like:

{
  "mcpServers": {
    "lens": { "command": "node", "args": ["/abs/path/lens-mcp/dist/index.js"] }
  }
}
  • Claude Code: claude mcp add lens -- node /abs/path/lens-mcp/dist/index.js (or copy mcp-config.json into a project as .mcp.json)
  • Cursor / Windsurf: merge mcp-config.json into ~/.cursor/mcp.json
  • Codex CLI: add [mcp_servers.lens] with the same command/args to ~/.codex/config.toml

lens reads files under its working directory — the project your client launches it in. Point it at a project and call map("."). Nothing outside the working directory is readable.

Update later, in place:

./update.sh          # git pull --ff-only + reinstall + self-test

Prefer to do it by hand? npm install && npm run build && npm test, then run node dist/index.js.

Lineage

lens-mcp supersedes the earlier split servers codelens-mcp (code) and docslens-mcp (docs) — same engines, one server, one pipeline. Sibling of periscope-mcp (web-app QA); built to the same standard: honest errors, caps + truncated flags everywhere, docs == behavior, tests before release.

Built by Segentic Lab. AGPL-3.0.

Reviews

No reviews yet

Be the first to review this server!

0

installs

New

no ratings yet

Is this your server?

Claim ownership to manage your listing, respond to reviews, and track installs from your dashboard.

Claim with GitHub

Sign up with the GitHub account that owns this repo

Links

Source CodeDocumentation

Details

Published July 6, 2026
Version 0.1.0
0 installs
Local Plugin

More Developer Tools MCP Servers

Fetch

Free

by Modelcontextprotocol · Developer Tools

Web content fetching and conversion for efficient LLM usage

80.0K
Stars
7
Installs
5.3
Security
No ratings yet
Local

Git

Free

by Modelcontextprotocol · Developer Tools

Read, search, and manipulate Git repositories programmatically

80.0K
Stars
6
Installs
6.5
Security
No ratings yet
Local

Toleno

Free

by Toleno · Developer Tools

Toleno Network MCP Server — Manage your Toleno mining account with Claude AI using natural language.

137
Stars
535
Installs
8.0
Security
4.8
Local

mcp-creator-python

Free

by mcp-marketplace · Developer Tools

Create, build, and publish Python MCP servers to PyPI — conversationally.

-
Stars
80
Installs
10.0
Security
4.6
Local

MarkItDown

Free

by Microsoft · Content & Media

Convert files (PDF, Word, Excel, images, audio) to Markdown for LLM consumption

156.1K
Stars
47
Installs
6.0
Security
5.0
Local

MCP Marketplace

Free

by mcp-marketplace · Developer Tools

Search and install MCP servers from inside your AI client.

-
Stars
33
Installs
10.0
Security
5.0
Remote