MCP ドキュメント サーバー
モデル コンテキスト プロトコルを介して LLM アプリケーション (Cursor、Claude Desktop、Windsurf など) とドキュメント ソース間の統合を可能にする MCP ドキュメント サーバーのカスタマイズされたバージョンです。
概要
このサーバーは、MCP ホスト アプリケーションに次の機能を提供します。
特定のドキュメント ファイル (langgraph.txt および mcp.txt) へのアクセス
ファイル内のURLからドキュメントを取得するためのツール
Related MCP server: MCP LLMS-TXT Documentation Server
サポートされているドキュメント
現在設定中:
クイックスタート
セットアップと実行
# Clone the repository
git clone https://github.com/esakrissa/mcp-doc.git
cd mcp-doc
# Create and activate a virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install the package in development mode
pip install -e .
サーバーの実行
インストールされたコマンドを使用してサーバーを実行できます。
# Run the server with the config file
mcpdoc \
--json config.json \
--transport sse \
--port 8082 \
--host localhost
または、UV を使用する場合:
# Install uv (if not already installed)
curl -LsSf https://astral.sh/uv/install.sh | sh
# Run the server with UV
uvx --from mcpdoc mcpdoc \
--json config.json \
--transport sse \
--port 8082 \
--host localhost
IDE統合
カーソル
~/.cursor/mcp.jsonに追加する
{
"mcpServers": {
"mcp-doc": {
"command": "uvx",
"args": [
"--from",
"mcpdoc",
"mcpdoc",
"--urls",
"LangGraph:https://raw.githubusercontent.com/esakrissa/mcp-doc/main/docs/langgraph.txt",
"ModelContextProtocol:https://raw.githubusercontent.com/esakrissa/mcp-doc/main/docs/mcp.txt",
"--allowed-domains",
"*",
"--transport",
"stdio"
]
}
}
}
次に、カーソルのカスタム命令に次の命令を追加します。
for ANY question about LangGraph and Model Context Protocol (MCP), use the mcp-doc server to help answer --
+ call list_doc_sources tool to get the available documentation files
+ call fetch_docs tool to read the langgraph.txt or mcp.txt file
+ reflect on the urls in langgraph.txt or mcp.txt
+ reflect on the input question
+ call fetch_docs on any urls relevant to the question
+ use this to answer the question
統合が機能しているかどうかをテストするには、Cursor に LangGraph または MCP について質問し、ドキュメント サーバー ツールを使用して情報を取得するかどうかを確認します。
セキュリティに関する注意事項
セキュリティ上の理由から、厳格なドメイン アクセス制御が実装されています。
リモートドキュメントファイル: 特定のドメインのみが自動的に許可されます
ローカルドキュメントファイル: ドメインは自動的に許可されません
--allowed-domainsを使用してドメインを明示的に追加するか、 --allowed-domains '*'使用してすべて許可します(注意して使用してください)。
参考文献
このプロジェクトは、 LangChain AI によるオリジナルの mcpdocに基づいており、LangGraph と MCP に重点を置いたドキュメント アクセスを提供するために変更されています。