nabchan-mcp-server
[!WARNING] これは実験的なプロジェクトであり、改善の余地が大いにあります。
概要
Nablarchの解説書をもとにしてNablarchの情報を返すMCPサーバーです。
Getting started
Dockerを使って簡単に試せます。
graph LR
a[VSCode]
b[nabchan-mcp-server<br>(Dockerコンテナ)]
a -->|標準入出力で通信| b
VSCodeへ次の設定を追加してください。
{
"mcp": {
"inputs": [],
"servers": {
"nablarch-document": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"--network",
"none",
"-e",
"TRANSPORT=stdio",
"ghcr.io/backpaper0/nabchan-mcp-server",
]
}
}
}
}
GitHub Copilot ChatをAgentモードにしてNablarchに関する質問をしてみてください。
アーキテクチャ
とりあえずローカルのPythonだけで動作するような構成を取っています。
Whooshという全文検索ライブラリとJanomeという形態素解析ライブラリを使ってインデックスを構築しています。 解説書のHTMLから抽出したテキストを形態素解析したものが全文検索の対象フィールドとなります。 それ以外にもタイトルや概要、内容をmarkdown形式に変換したものをもっており、それらはMCPサーバーが提供するAPIで利用されます。
graph TD
h[Nablarchの解説書<br>(HTMLファイル)]
c(テキスト)
d(概要)
t(タイトル)
m(markdown)
i[Whooshのインデックス]
h -->|BeautifulSoupで<br>テキスト抽出| c
c -->|Janomeで形態素解析| i
c -->|LLMで要約| d
d --> i
h -->|BeautifulSoupで<br>タイトル抽出|t
t --> i
h -->|html2textで<br>markdown化| m
m --> i
MCPサーバーが提供しているAPIは次の通りです。
-
read_document- URLが示すNablarchのドキュメントをmarkdown形式へ変換したものを返します。
-
search_document- Nablarchのドキュメントを検索します。返される情報は次の通り
- タイトル
- URL
- 概要
- Nablarchのドキュメントを検索します。返される情報は次の通り
必要な環境
- Python 3.11
- uv
- Git
- Docker
インデックスの構築
uv run -m tools.build_index
[!NOTE] サブモジュールの中身を取得していない場合、
git submodule initとgit submodule updateを実行してください。
検索を試す
uv run -m tools.search_document -q "Nablarch"
開発時のVSCode設定例
/path/to/nabchan-mcp-serverは実際のパスに置き換えてください。
{
"mcp": {
"inputs": [],
"servers": {
"nablarch-document": {
"command": "uv",
"args": [
"--directory",
"/path/to/nabchan-mcp-server",
"run",
"-m",
"nabchan_mcp_server.main",
]
}
}
}
}
トランスポートタイプにSSEを使う場合はこちら。
{
"mcp": {
"inputs": [],
"servers": {
"nablarch-document": {
"type": "sse",
"url": "http://localhost:8000/sse"
}
}
}
}
SSEを使う場合は次のコマンドであらかじめサーバーを起動しておく必要があります。
uv run -m nabchan_mcp_server.main --transport sse --host localhost
相关推荐
I find academic articles and books for research and literature reviews.
Confidential guide on numerology and astrology, based of GG33 Public information
Advanced software engineer GPT that excels through nailing the basics.
Emulating Dr. Jordan B. Peterson's style in providing life advice and insights.
Your go-to expert in the Rust ecosystem, specializing in precise code interpretation, up-to-date crate version checking, and in-depth source code analysis. I offer accurate, context-aware insights for all your Rust programming questions.
Take an adjectivised noun, and create images making it progressively more adjective!
Découvrez la collection la plus complète et la plus à jour de serveurs MCP sur le marché. Ce référentiel sert de centre centralisé, offrant un vaste catalogue de serveurs MCP open-source et propriétaires, avec des fonctionnalités, des liens de documentation et des contributeurs.
L'application tout-en-un desktop et Docker AI avec chiffon intégré, agents AI, constructeur d'agent sans code, compatibilité MCP, etc.
Plateforme d'automatisation de workflow à code équitable avec des capacités d'IA natives. Combinez le bâtiment visuel avec du code personnalisé, de l'auto-hôte ou du cloud, 400+ intégrations.
Manipulation basée sur Micropython I2C de l'exposition GPIO de la série MCP, dérivée d'Adafruit_MCP230XX
🧑🚀 全世界最好的 LLM 资料总结 (数据处理、模型训练、模型部署、 O1 模型、 MCP 、小语言模型、视觉语言模型) | Résumé des meilleures ressources LLM du monde.
Une liste organisée des serveurs de protocole de contexte de modèle (MCP)
Reviews
user_NXK84fj9
Nabchan-mcp-server by backpaper0 is an exceptional server management tool. It provides a seamless, efficient way to manage multiple connections with great ease. The setup is straightforward and the performance is impressive. As an avid MCP application user, I highly recommend this server for its reliable and robust features. Check it out at https://github.com/backpaper0/nabchan-mcp-server.