distill-mcp について
distill-mcpは、ローカルの文書をLLM向けの簡潔なMarkdownに変換するMCPサーバーです。軽量モードとDockerモードでは、対応形式と変換機能が異なります。
主な機能
- 01文書からMarkdownへの変換
- 02軽量モードとDockerモード
- 03フルモードでスキャンPDFのOCR
- 04フルモードで音声変換
- 05文書のローカル処理
活用シーン
- 01オフィス文書をLLM分析用に変換
- 02フルモードでスキャンPDFを変換
- 03フルモードで音声ファイルを変換
MCP 対応
`convert_and_save`ツールを通じて、MCPクライアントに文書変換機能を提供します。元ファイルを直接読む代わりに、返されたMarkdownを利用できます。
設定
ローカルサーバーの設定はどのクライアントでも共通です。コピーしてクライアントの MCP 設定ファイルに貼り付けてください。
ツール
ローカルサーバーのツールはマシン上で起動して初めて取得できます。メンテナーはまだツール一覧を提供していません。
詳細
distill-mcp
あらゆる MCP 対応クライアントを Distill に接続する MCP サーバーです。LLM が読む前にローカルのドキュメントをクリーンでトークン効率の高い Markdown に変換します。 通常、元のドキュメントテキストと比較してトークンを 40~80%削減できるため、モデルはコンテキストウィンドウにより多くの内容を収め、より速く推論できます。
Claude Desktop、Claude Code、Cursor、Windsurf、およびツール呼び出しに対応するその他すべての MCP クライアントで動作します。
2 つのモード
| 軽量 | フル(Docker) | |
|---|---|---|
| Docker が必要 | いいえ | はい |
| DOCX、XLSX、PPTX、ネイティブ PDF、HTML | はい | はい |
| スキャン PDF(OCR) | いいえ | はい |
| 音声(MP3、WAV など) | いいえ | はい |
| 品質スコア | いいえ | はい |
| インストール時間 | 約 2 分 | 約 10 分 |
軽量モードでは Python と pip のみが必要です。フルモードでは Distill サービスを実行する Docker が必要です。詳しくはセットアップガイドをご覧ください。
クイックインストール
グローバルインストールは不要です。
npx -y distill-mcp-server
次に Claude Desktop を設定します。手順については、 軽量モードのセットアップまたは フルモードのセットアップをご覧ください。
設定
サーバーを claude_desktop_config.json に追加します。
軽量モード — macOS / Linux:
{
"mcpServers": {
"distill-mcp": {
"command": "npx",
"args": ["-y", "distill-mcp-server"],
"env": {
"DISTILL_MCP_CONFIG": "{\"mode\":\"lightweight\",\"python_path\":\"python3\"}"
}
}
}
}
軽量モード — Windows:
{
"mcpServers": {
"distill-mcp": {
"command": "npx",
"args": ["-y", "distill-mcp-server"],
"env": {
"DISTILL_MCP_CONFIG": "{\"mode\":\"lightweight\",\"python_path\":\"py\"}"
}
}
}
}
フルモード — すべてのプラットフォーム:
{
"mcpServers": {
"distill-mcp": {
"command": "npx",
"args": ["-y", "distill-mcp-server"],
"env": {
"DISTILL_MCP_CONFIG": "{\"mode\":\"full\",\"distill_url\":\"http://localhost:7860\"}"
}
}
}
}
設定キーの全リファレンスは、セットアップガイドにあります。 軽量モード | フルモード
CLAUDE.md スニペット
Claude がツールの使い方を自動的に認識できるよう、プロジェクトの CLAUDE.md に貼り付けてください。以下のブロックをそのままコピーしてください。
## Document Conversion — distill-mcp
When the user references a local file path (e.g. a PDF, DOCX, PPTX, XLSX,
HTML, or audio file), ALWAYS call the `convert_and_save` tool before reading
or reasoning about the document. Do not read the original file directly via
filesystem tools — use only the Markdown returned by `convert_and_save` as
the document content.
### Rules
1. Call `convert_and_save` with the absolute file path before doing anything
else with the document.
2. Use ONLY the Markdown output from `convert_and_save` as the document
content. Never read the original file with filesystem tools.
3. If the response includes `"overwritten": true`, tell the user that a
previous cached version was replaced before proceeding.
4. If the response includes any `warnings`, surface them to the user before
proceeding with the document content.
5. If `convert_and_save` returns an unsupported format error, tell the user
which formats are supported and suggest switching modes if applicable.
### Supported formats
| Category | Lightweight | Full (Docker) |
|---|---|---|
| Word | .docx, .doc, .odt | .docx, .doc, .odt |
| Excel | .xlsx, .xlsm, .csv | .xlsx, .xlsm, .csv |
| PowerPoint | .pptx, .ppt | .pptx, .ppt |
| PDF | .pdf (native text) | .pdf (native + scanned OCR) |
| HTML | .html, .htm | .html, .htm |
| Audio | — | .mp3, .wav, .m4a, .flac, .ogg |
| Other | — | .epub, .json, .sql, .wsdl, .wsd |
### Usage
Say "convert using distill" followed by the file path:
> Convert using distill C:\Users\me\Documents\report.pdf to markdown
このスニペットは docs/CLAUDE.md-snippet.mdにもあります。
対応フォーマット
| カテゴリ | 拡張子 | 軽量 | フル |
|---|---|---|---|
| Microsoft Word | .docx、.doc、.odt | はい | はい |
| Microsoft Excel | .xlsx、.xlsm、.csv | はい | はい |
| Microsoft PowerPoint | .pptx、.ppt | はい | はい |
| PDF(ネイティブテキスト) | .pdf | はい | はい |
| PDF(スキャン/OCR) | .pdf | いいえ | はい |
| HTML | .html、.htm | はい | はい |
| 音声 | .mp3、.wav、.m4a、.flac、.ogg | いいえ | はい |
| EPUB | .epub | いいえ | はい |
| JSON | .json | いいえ | はい |
| SQL | .sql | いいえ | はい |
| WSDL | .wsdl、.wsd | いいえ | はい |
プライバシー
すべての処理はローカルで行われます。軽量モードでは、ドキュメントはお使いのマシン上で distill-core Python ライブラリによって変換されるため、データがコンピューターの外に出ることはありません。フルモードでは、ドキュメントはお使いのマシン上でローカルに実行されている Distill Docker サービスに送信されるため、外部サービスにデータが送信されることはありません。
使用技術
Distill — ドキュメントを Markdown に変換するエンジンです。
ライセンス
MIT
コメント
AI アプリケーションが外部のツールやデータソースに統一的な方法で接続するためのオープンなプロトコルです。クライアントはモデルとの対話を担い、MCP サーバーはツール・リソース・プロンプトテンプレートを提供します。標準メッセージでやり取りするため、1 つのサーバーを複数のクライアントで再利用できます。