bdc-doc-mcp
BDC Doc RAG
bdc-assist のドキュメント RAG MCP
bdc_doc_mcp/config.py env-driven embeddings/LLM/Chroma (replaces utils/__init__.set_emb_llm)
bdc_doc_mcp/ingest.py .pkl/.md/.mdx/.txt/.pdf → embeddings → Chroma (replaces utils/chroma/utils.py)
bdc_doc_mcp/api.py FastAPI: /health /search
bdc_doc_mcp/mcp_server.py search_docs MCP tool for AI agents — self-contained, same search as the API
bdc_doc_mcp/preproc/ source-specific preprocessing pipeline
tests/ self-checks + API / agent notebooks
data/ preproc output (*.pkl), ingest inputセットアップ
uv sync
cp .env.example .env # then fill in keys/URLsソースリポジトリ
前処理(--sources all)のときだけ必要です。API/MCP サーバーと既存の .pkl ファイルの取り込みは、これらがなくても動作します。このリポジトリの隣にクローンしてください(または環境変数でそれらの場所を指定してください):
git clone https://github.com/stagecc/interim-bdc-website ../interim-bdc-website # BDC_WEBSITE_DIR
git clone https://github.com/stagecc/bdc-gitbook ../bdc-gitbook # BDC_GITBOOK_DIRモデル
completion には、Azure 上の OpenAI API を使用します(デフォルトは gpt-4o-mini)。
embeddings には、Sterling 上の Ollama を使用します(RENCI VPN 経由で接続)。
kubectl -n ner port-forward svc/ollama 11434:11434または、ローカル Ollama で groonga/bge-m3-Q4_K_M-GGUF モデルを使用します。
Related MCP server: okfy
取り込み
すべてのソースから完全に再ビルドする場合(ソースリポジトリ 2 つのクローンが必要です — セットアップを参照。data/*.pkl を書き込んでから読み込みます):
uv run python -m bdc_doc_mcp.preproc.pipeline --sources all --ingest --reset個別のファイルまたはディレクトリ:
uv run python -m bdc_doc_mcp.ingest ./data/docs.pkl --doc-type docs # BDC_Chatbot preproc .pkl
uv run python -m bdc_doc_mcp.ingest ../interim-bdc-website/src/pages --doc-type page --resetコレクション内で embedding モデルを交換することはできません。bge-m3 は 1024 次元、text-embedding-3-small は 1536 次元です。モデルを切り替えるには --reset と完全な再取り込みが必要です。
API
uv run uvicorn bdc_doc_mcp.api:app --port 8000 # docs at /docsエンドポイント | リクエストボディ | 戻り値 |
| — |
|
|
| ランク付けされたチャンク + メタデータ + スコア |
mode は embedding(デフォルト。セマンティックな類似度で、スコアは距離のため小さいほど良い)または keyword(リテラルな単語のあいまい一致 — 大文字小文字と句読点を無視し、小さなタイポを許容します。picsure で "PIC-SURE" が見つかります。スコアは一致回数で、大きいほど良い — 正確な名前や頭字語の検索に使用します)。
doc_type は検索するタイプの CSV です(例: page,faq)。省略時は docs、page、faq、video のみが検索対像です。fellow、update、event を検索するには明示的に指定してださい。
date_desc /date_to(YYYY-MM-DD `両を含ん)
あら.
私は質問を省き、正じつまるるる...
Let me rewrite the tail properly.
date_from/date_to(YYYY-MM-DD、両端を含む)は日付でフィルタリングします。日付を持つのは event と update のドキュメントだけなので、日付フィルターを指定すると暗にこれらのタイプに絞られます。
このサービスは設計上、検索専用です。取り込みは CLI でオフライン実行し(「取り込み」参照)、回答の生成は呼び出し側の仕事 — エージェントが自分の LLM を持ち込みます。
MCP
uv run python -m bdc_doc_mcp.mcp_server # stdio
uv run python -m bdc_doc_mcp.mcp_server --http # streamable HTTP, port MCP_PORT (default 8001)search_docs という 1 つのツールを公開します。API と同じ検索ですが、Chroma に直接問い合わせるため、API サービスの起動は不要です。取り込み済みの .chroma_db と embeddings が必要です。
Stdio クライアント(Claude Desktop/Code、Cursor)はサーバー自身を起動するので、ここで登録してください:
{"mcpServers": {"bdc-doc-mcp": {
"command": "uv",
"args": ["--directory", "/path/to/bdc-doc-mcp", "run", "python", "-m", "bdc_doc_mcp.mcp_server"]
}}}ネットワーククライアントの場合は、代わりに --http を指定して起動し、http://host:8001/mcp を指すようにします。
スモークテスト: uv run python tests/test_mcp.py
前処理
bdc_doc_mcp/preproc/ は移植された BDC_Chatbot パイプラインです:
モジュール | ソース | 移植元(BDC_Chatbot) | 備考 |
| interim-bdc-website MDX |
| fellows、events、latest-updates、pages |
| bdc-gitbook markdown |
| 見出しの階層でチャンク分割;リポジトリのクローンが必要 |
| bdcatalyst.freshdesk.com |
| ライブスクレイピング |
| Google Sheet + Drive SRT |
| タイムスタンプ付き URL の動画文字起こし |
| — | — | LLM チャンクの文脈化 + 要約 |
| — | — | オー ケスト レーター |
--no-contextualize はチャンクごと の LLM 呼出をす キップします(大 幅速で す が、検 索は 弱 くな りま す)。ソース の パ スは BDC_WEBSITE_DIR / BDC_GITBOOK_DIR か ら取 得ま す。
テスト
uv run python tests/test_ingest.py # batching + chunk-id logic, no network
uv run python tests/test_keyword.py # keyword ranking, pure function, no DB or API
uv run python tests/test_mcp.py # starts the server over stdio and exercises its tools; needs .chroma_db + embeddings各ノート ブック は 空き ポー ト で APİ を 起動 し、最 末 に 停 止 し ま す(ど ち ら も取 込 み ず み の .chroma_db が 必 要)。
tests/api_test.ipynb— 単純 な APİ の tub り:/heakth、/search、doc_typefilter。ローカル の embeddings だ け必 要。tests/агent_test.ynb— tool-callエー ジェ ント(deepагent):設定された LLM はsearch_docsを LangChain ツー ル と し て 得、い 呼 ぶ 也 判 断 す る。Completion プ ロ バ ダ に到 達 可 能 な こ と も 必 要。
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProvides semantic search over markdown documentation using RAG, allowing natural language queries and integration with MCP clients.1MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to search, read, and traverse documentation bundles in Open Knowledge Format via MCP tools.73366MIT
- AlicenseNot gradedqualityDmaintenanceProvides RAG (Retrieval Augmented Generation) access to technical documentation through MCP, enabling LLMs to search and retrieve relevant documentation on-demand.4MIT
- AlicenseNot gradedqualityAmaintenanceCrawl documentation sites, index them with hybrid search, and expose them as MCP tools so LLM agents can search and retrieve current docs.MIT
Related MCP Connectors
Agentic search over your Dewey document collections from any MCP-compatible client.
Turn a GitHub repo or docs site into agent-ready context: pack it or search it, over MCP.
Query any docs site via MCP. Submit a URL, ask questions, get cited answers.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/bdc-assist/bdc-doc-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server