dev-standards-mcp

dev-standards-mcp

MCP server that provides a searchable knowledge base of internal development standards, enabling AI coding agents to consistently reference and comply with them.

Category
Visit Server

README

dev-standards-mcp

社内開発標準をAIコーディングエージェントが一貫して参照・遵守できるMCP(Model Context Protocol)サーバ。

詳細な設計方針は CLAUDE.md を参照。

セットアップ(ローカル / uv)

uv sync

起動(ローカル / uv)

uv run python main.py

デフォルトでは http://127.0.0.1:8000/mcp で待ち受ける。sample-knowledge/ の内容から起動時にオンメモリでSQLite FTS5インデックスを構築する。

起動(Docker)

イメージのビルド:

docker build -t dev-standards-mcp:local .

コンテナの起動:

docker run --rm -p 8000:8000 dev-standards-mcp:local

http://localhost:8000/mcp にMCPクライアント(Claude Code等)から接続できる。

MCPクライアントからの動作確認

コンテナ(またはローカルのuv run python main.py)を起動した状態で、以下のいずれかの方法で疎通・Tool呼び出しを確認できる。

方法A: Claude Code から接続

claude mcp add --transport http dev-standards-mcp http://localhost:8000/mcp

追加後、Claude Codeのセッション内で /mcp と入力すると接続状態(dev-standards-mcpconnected)を確認できる。開発標準に関する質問(例: 「Dockerの品質チェックで何をすればいい?」)を投げると、search_standards 等のToolが自動的に呼び出される。

不要になったら以下で削除する。

claude mcp remove dev-standards-mcp

方法B: MCP Inspector(GUIで対話的に確認)

npx @modelcontextprotocol/inspector http://localhost:8000/mcp

ブラウザが開き、search_standards / get_standard / get_applicable_standards / get_review_checklist の4 Toolを一覧・実行できる。

方法C: curlで直接JSON-RPCを叩く(ツール不要)

MCPのStreamable HTTPトランスポートはセッションIDを要求するため、initializeのレスポンスヘッダーからMcp-Session-Idを取り出して以降のリクエストに付与する。

# 1. initialize してセッションIDを取得
curl -sD /tmp/mcp_headers.txt http://localhost:8000/mcp -X POST \
  -H "Content-Type: application/json" -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"manual-check","version":"1.0"}}}'
SESSION_ID=$(grep -i "mcp-session-id" /tmp/mcp_headers.txt | awk '{print $2}' | tr -d '\r')

# 2. initialized通知を送る(レスポンスなし・202が返る)
curl -s -o /dev/null -w "HTTP %{http_code}\n" http://localhost:8000/mcp -X POST \
  -H "Content-Type: application/json" -H "Accept: application/json, text/event-stream" \
  -H "Mcp-Session-Id: $SESSION_ID" \
  -d '{"jsonrpc":"2.0","method":"notifications/initialized"}'

# 3. search_standards を呼び出す
curl -s http://localhost:8000/mcp -X POST \
  -H "Content-Type: application/json" -H "Accept: application/json, text/event-stream" \
  -H "Mcp-Session-Id: $SESSION_ID" \
  -d '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"search_standards","arguments":{"query":"docker"}}}'

standard-003(Dockerコンテナ品質チェック標準)がヒットすれば、コンテナ起動→インデックス構築→検索まで一連の動作確認が取れたことになる。

環境変数

変数名 デフォルト 説明
KNOWLEDGE_SOURCE sample 知識ソース。PoCではsampleのみ対応
KNOWLEDGE_PATH ./sample-knowledge 知識ディレクトリのパス
AUTH_ENABLED false trueにするとAzureProvider認証を有効化(AZURE_CLIENT_ID等が必須)
MCP_HOST 127.0.0.1(Dockerイメージ内では0.0.0.0 待ち受けホスト
MCP_PORT 8000 待ち受けポート

開発

uv run ruff check .
uv run mypy .
uv run pytest
uv run pip-audit

uv run pytest にはDockerイメージのbuild・run・MCPヘルスチェックを行う統合テスト(tests/test_docker_integration.py)が含まれる。Dockerが利用できない環境では自動的にスキップされる。

Dockerfileを変更した場合は、Hadolintでの静的解析も実行すること。

docker run --rm -i hadolint/hadolint < Dockerfile

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