CLAUDE.md
CLAUDE.mdCLAUDE.mdroot
Quality
97/100
Scores the file, not the repository.Length
518 words
18 headings · 3 code blocksRepository
89k
— · pushed 0 days agoLast changed
3 days ago
First indexed 3 days ago.1# CLAUDE.md23This file provides guidance to Claude Code when working with code in this repository.45## Project Overview67Official MCP reference server implementations. This is an npm workspaces monorepo containing 7 servers (4 TypeScript, 3 Python) under `src/`. Each server is a standalone package published to npm or PyPI.89## Monorepo Structure1011```12src/13 everything/ TS @modelcontextprotocol/server-everything (reference server, all MCP features)14 filesystem/ TS @modelcontextprotocol/server-filesystem (file operations with Roots access control)15 memory/ TS @modelcontextprotocol/server-memory (knowledge graph persistence)16 sequentialthinking/ TS @modelcontextprotocol/server-sequential-thinking (step-by-step reasoning)17 fetch/ Py mcp-server-fetch (web content fetching)18 git/ Py mcp-server-git (git repository operations)19 time/ Py mcp-server-time (timezone queries and conversion)20```2122## Build & Test Commands2324### TypeScript servers2526```bash27# Single server28cd src/<server> && npm ci && npm run build && npm test2930# All TS servers from root31npm install && npm run build32```3334- Build: `tsc` (target ES2022, module Node16, strict mode)35- Tests: **vitest** with `@vitest/coverage-v8` (required for new tests)36- Node version: **22**3738### Python servers3940```bash41cd src/<server> && uv sync --frozen --all-extras --dev4243# Run tests (if tests/ or test/ directory exists)44uv run pytest4546# Type checking47uv run pyright4849# Linting50uv run ruff check .51```5253- Build system: **hatchling** (`uv build`)54- Package manager: **uv** (not pip)55- Python version: **>= 3.10** (per-server `.python-version` file)56- Type checking: **pyright** (enforced in CI)57- Linting: **ruff**5859## Code Style6061### TypeScript6263- ES modules with `.js` extension in import paths64- Strict TypeScript typing for all functions and variables65- Zod schemas for tool input validation66- 2-space indentation, trailing commas in multi-line objects67- camelCase for variables/functions, PascalCase for types/classes, UPPER_CASE for constants68- kebab-case for file names and registered tools/prompts/resources69- Verb-first tool names (e.g., `get-file-info`, not `file-info`)70- Imports grouped: external first, then internal7172### Python7374- Type hints enforced via pyright75- Async/await patterns (especially in fetch server with pytest-asyncio)76- Follow existing module layout per server7778## Contributing Guidelines7980**Accepted:** Bug fixes, usability improvements, enhancements demonstrating MCP protocol features (Resources, Prompts, Roots -- not just Tools).8182**Selective:** New features outside a server's core purpose or highly opinionated additions.8384**Not accepted:** New server implementations (use the [MCP Server Registry](https://github.com/modelcontextprotocol/registry)), README server listing changes.8586## CI/CD Pipeline8788Both TypeScript and Python workflows use **dynamic package detection** (find + jq matrix strategy):89901. `detect-packages` -- finds all `package.json` / `pyproject.toml` under `src/`912. `test` -- runs tests per package923. `build` -- compiles and type-checks per package934. `publish` -- on release events only (npm for TS, PyPI trusted publishing for Python)9495## MCP Protocol Reference9697The repo is configured with an MCP docs server (`.mcp.json`) pointing to `https://modelcontextprotocol.io/mcp`. For schema details, reference `https://github.com/modelcontextprotocol/modelcontextprotocol/tree/main/schema` which contains versioned schemas in JSON and TypeScript formats.9899## Key Patterns100101- Each server registers capabilities via `registerTools(server)`, `registerResources(server)`, `registerPrompts(server)` functions102- Tool annotations: set `readOnlyHint`, `idempotentHint`, `destructiveHint` per MCP spec103- Transport support: stdio (default), SSE (deprecated), Streamable HTTP104- All PRs are reviewed against the [PR template](.github/pull_request_template.md) checklist -- ensure MCP docs are read, security best practices followed, and changes tested with an LLM client105
Also in modelcontextprotocol/servers
Diff this repo’s formatsOne repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| modelcontextprotocol/serverssrc/everything/AGENTS.md · 89k | AGENTS.md | buildteststyle | 80/100 | 3 days ago |
Similar configs
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| livewire/livewireCLAUDE.md · 24k | CLAUDE.md | setupbuildteststyle+4 | 100/100 | 3 days ago | |
| bagisto/bagistoCLAUDE.md · 28k | CLAUDE.md | setupbuildteststyle+5 | 100/100 | 3 days ago | |
| microsoft/playwrightCLAUDE.md · 94k | CLAUDE.md | buildtestlint-formatstyle+7 | 100/100 | 3 days ago | |
| Adit-Jain-srm/NightmareNetCLAUDE.md · 45 | CLAUDE.md | buildtestlint-formatstyle+6 | 100/100 | 3 days ago | |
| nimbalyst/nimbalystpackages/android/CLAUDE.md · 1.4k | CLAUDE.md | setupbuildstylearch+2 | 100/100 | 3 days ago | |
| filamentphp/filamentCLAUDE.md · 32k | CLAUDE.md | buildtestlint-formatstyle+7 | 100/100 | 3 days ago | |
| dotCMS/corecore-web/CLAUDE.md · 950 | CLAUDE.md | teststylearchtesting-strategy+3 | 100/100 | 3 days ago | |
| dotCMS/coreCLAUDE.md · 950 | CLAUDE.md | setupbuildteststyle+7 | 99/100 | 3 days ago |
