local-docs-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@local-docs-mcp 経費精算規程の締め日を教えて"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
local-docs-mcp
ローカルフォルダ内のドキュメントを検索・閲覧して、質問への回答を探せる MCP サーバ。
機能
DOCS_ROOT に指定したフォルダ配下の docx / pptx / xlsx / pdf / md / txt / csv / html を対象に:
ツール | 内容 |
| ドキュメント一覧(相対パス・サイズ・更新日時) |
| 全文検索。スペース区切りでAND検索。マッチ箇所の抜粋付きで返す |
| 本文をテキスト(Markdown)として読み出し。大きい文書は offset で分割読み |
回答の組み立てはMCPクライアント(Claude)側が行う。サーバは検索と本文抽出のみを担当する。 Office系ファイルは markitdown でテキスト変換し、 抽出結果はファイル更新日時ベースでキャッシュする。
Related MCP server: docx-mcp-server
セットアップ
uv が必要。依存関係は初回実行時に自動で解決される。
DOCS_ROOT=/path/to/documents uv run server.py
# エラーなく起動して待機すればOK (Ctrl+C で終了)テスト用ドキュメント
test_docs/ に、動作確認用のサンプル文書一式が入っている(架空の会社「株式会社サンプル商事」の社内文書。対応フォーマットを網羅)。
test_docs/
├── 規程/
│ ├── 経費精算規程.docx # 締め日は毎月5日、支払日は当月25日
│ ├── 出張旅費規程.pdf # 日当2,500円、宿泊上限12,000円
│ └── 在宅勤務ガイドライン.md # 週3日上限、在宅手当 月3,000円
├── 総務/
│ ├── 有給休暇FAQ.txt # 入社6か月で10日付与、繰越は翌年度まで
│ ├── 社内連絡先一覧.xlsx # 部署・担当・内線・メールの表
│ └── 備品購入申請ルール.csv # 金額別の承認者(10万円以上は稟議書)
├── 議事録/
│ └── 2026-07-01_全社定例会議事録.md # システム切替日、夏季休業日程
└── 資料/
└── 新製品発表会企画.pptx # 日程・会場・予算上限500万円各ファイルには答え合わせ可能な事実を仕込んであるので、DOCS_ROOT をこのフォルダに向けて
「経費精算の締め日はいつ?」「出張の宿泊費の上限は?」「経理部の内線番号は?」などと質問すれば、
検索 → 本文読解 → 回答の一連の流れをテストできる。
DOCS_ROOT=$(pwd)/test_docs uv run server.pyClaude Code への登録
claude mcp add local-docs \
-e DOCS_ROOT=/path/to/documents \
-- uv --directory /path/to/this/repo run server.py登録後、Claude Code で「◯◯について規程ではどうなってる?」のように聞くと、 検索 → 該当文書の読解 → 回答、が自動で行われる。
Available Tools
3 toolslist_documentsA
検索対象フォルダ (DOCS_ROOT) 配下のドキュメント一覧を返す。
Returns:
各ドキュメントの相対パス・サイズ(バイト)・更新日時のリスト。
Inputs: no named parameters. Returns: result
read_documentA
ドキュメントの本文をテキスト(Markdown)として読み出す。
Args:
path: search_documents / list_documents が返した相対パス。
offset: 読み出し開始位置(文字数)。大きい文書の続きを読むときに使う。
max_chars: 一度に返す最大文字数。
Returns:
本文テキストと、全体の文字数・続きがあるかどうか。
Inputs: path (required), offset, max_chars.
search_documentsA
DOCS_ROOT 配下のドキュメントを全文検索する。
Args:
query: 検索キーワード。スペース区切りで複数指定するとAND検索(大文字小文字は区別しない)。
max_results: 返す文書数の上限。
Returns:
マッチした文書ごとに 相対パス・マッチ回数・前後の抜粋(snippets) を、マッチ回数の多い順で返す。
本文全体が必要なら read_document を使うこと。
Inputs: query (required), max_results. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: listing all documents, reading a specific document with pagination, and full-text searching. No ambiguity or overlap.
All tool names follow a consistent verb_noun pattern in snake_case (list_documents, read_document, search_documents), making them predictable.
Three tools are well-scoped for a document server, covering the essential operations without unnecessary bloat or deficiency.
The tool set provides listing, reading with pagination, and full-text search, which is complete for a read-only document retrieval system. No obvious gaps.
Related MCP Connectors
Read and search folders on your own computer with explicit consent. Files are never uploaded.
Search, browse, and read your Dropbox files. Find documents by name or content, list folders, and…
Securely search and manage workspace context files for AI agents and teams.
Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables agents to manage and organize local documents by listing, inspecting, extracting text, searching, and renaming files, with optional Google Drive integration.-
- FlicenseAqualityDmaintenanceEnables natural language interaction with local .docx files, allowing users to find, read, search, and summarize Word documents using friendly names and location hints.53-
- AlicenseAqualityDmaintenanceProvides LLMs with secure, read-only access to local documentation by scanning directories, extracting content from PDF, DOCX, Markdown, and text files, and performing keyword searches.35 npmMIT
- FlicenseAqualityCmaintenanceEnables managing documents on the filesystem through natural language, with tools for read, create, edit, delete, and commands for summarize, format, rewrite, and convert.5-