mcp-bridge

mcp-bridge

Enables LLMs to use llama.cpp models via MCP protocol by bridging MCP requests to an OpenAI-compatible API.

Category
Visit Server

README

mcp-bridge

Docker で MCP サーバを起動し、内部で llama.cpp の OpenAI 互換 API を呼び出す構成です。

セットアップ

  1. .env.example.env にコピー
  2. MCP_API_TOKEN を 32 文字以上のランダム値に設定
    echo "MCP_API_TOKEN=$(openssl rand -hex 32)" >> .env
    
  3. 必要に応じて LLAMA_CPP_SERVER_URL をリモートの llama.cpp に向ける

起動

docker compose up -d --build

停止

docker compose down

接続先

  • MCP エンドポイント: http://localhost:8000/mcp
  • トランスポート: streamable-http

接続確認

認証が有効になっているため、Bearer トークンが必要です。 401 が返る場合は未認証、406 が返る場合は到達確認としては正常です (MCP エンドポイントは Accept ヘッダー前提のため)。

# 未認証 -> 401
curl -i http://localhost:8000/mcp

# 認証あり -> 406 (到達OK)
curl -i -H "Authorization: Bearer $MCP_API_TOKEN" http://localhost:8000/mcp

Claude Code 設定

Claude Code の MCP は ~/.claude.json で管理されます。

ローカルスコープ(特定プロジェクトのみ)で手動設定する場合は、 client-config.example.json の形式を ~/.claude.json に反映してください。

推奨: CLI で追加

claude mcp add --transport http local-agent-helper http://localhost:8000/mcp \
  --header "Authorization: Bearer $MCP_API_TOKEN"

設定確認

claude mcp list
claude mcp get local-agent-helper

補足

  • --scope user を付けると全プロジェクトで利用可能です。
  • --scope project を使うと、プロジェクト直下の .mcp.json に保存されます。

環境変数

.env.example.env にコピーして利用できます。

  • MCP_TRANSPORT (既定: streamable-http)
  • FASTMCP_HOST (既定: 0.0.0.0)
  • FASTMCP_PORT (既定: 8000)
  • LLAMA_CPP_SERVER_URL
  • LLAMA_CPP_SERVER_MODEL
  • LLAMA_CPP_SERVER_TIMEOUT
  • MCP_API_TOKEN (必須・32文字以上)
  • MAX_INPUT_CHARS (既定: 200000)

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