Skip to main content
Glama
samsung10-gif

local-docs-mcp

local-docs-mcp

A personal MCP server that reads documents on your local PC to help with summarization and organization. It extracts text from PDF, Word, Excel, PowerPoint, Hangul (HWP), Markdown, CSV, and more, and handles saving summaries and organizing files with an approval process.

  • It does not use the network. No API key is required.

  • This server does not summarize. It extracts the original text accurately, and Claude writes the summary. (The machine_keypoints the server provides are frequency-based mechanical extraction, not a summary.)

  • It cannot read outside the allowed folders. Moving or saving files always requires approval.

Supported formats

Type

Extensions

Method

Documents

.docx .docm

Direct ZIP+XML parsing (headings, paragraphs, tables)

Hangul

.hwpx / .hwp

.hwpx is natively supported; .hwp is best-effort extraction if olefile is installed

PDF

.pdf

pypdf (per-page p.N labels)

Presentations

.pptx .pptm

Slide number order + speaker notes

Spreadsheets

.xlsx .xlsm

Per-sheet, shared string resolution

Data

.csv .tsv .json

Includes column names and row counts

Web & Mail

.html .htm .xml .eml

Tag stripping; mail includes headers + body

Text & Code

.md .txt .log .yaml .py .js etc.

UTF-8/CP949/EUC-KR auto-detection

.doc .xls .ppt (legacy binary formats) are not read; the server tells you to "save them in an x-suffixed format."

Related MCP server: Knowledge Assistant MCP

Installation

Python 3.11 or later is required.

python -m venv .venv && .venv/Scripts/pip install -e ".[formats,dev]"

On macOS and Linux, use .venv/bin/pip. [formats] installs pypdf for PDF and olefile for .hwp (binary) together; without them, the remaining formats still work.

Registering with Claude Code

<PROJECT_DIR> is the absolute path where you cloned this repository, and <HOME> is the user home folder.

claude mcp add local-docs --scope user --env DOCS_MCP_ROOTS="<HOME>/Desktop;<HOME>/Documents" --env DOCS_MCP_OUTPUT="<HOME>/Desktop/docs-mcp-out" -- <PROJECT_DIR>/.venv/Scripts/python.exe -m docs_mcp.server

To use it only within this repository, copy .mcp.json.example to .mcp.json and replace <PROJECT_DIR> and <HOME> with the actual paths. .mcp.json paths differ per machine, so it is not tracked in the repository.

Environment variables

Variable

Meaning

Default

DOCS_MCP_ROOTS

Folders allowed for reading (separated by ;)

Desktop, Documents, Downloads

DOCS_MCP_OUTPUT

Folder for saving summaries and organization logs

<HOME>/Desktop/docs-mcp-out

DOCS_MCP_MAX_FILE_MB

Maximum file size

20

DOCS_MCP_ALLOW_MOVE

If 1, allows moving originals during organization

Unset (copy only)

11 tools

Read-only (R) and write (W) tools are registered separately so the host can show different approval UIs.

Tool

What it does

R

list_roots

Check readable folders, supported formats, and limits

R

scan_documents

Scan a folder for a document list (type, size, modified date)

R

outline_document

Structure, headings, keywords, representative sentences. For judging before reading the full text

R

read_document

Extract body text. Provides section labels and a continuation cursor

R

search_documents

Search across multiple document bodies + evidence snippets

R

build_summary_bundle

Extract evenly from multiple documents within a character budget

R

preview_save_summary

Preview content and path to save + issue approval token

W

save_summary

Save the approved summary to the output folder

R

preview_organize

Create only an organization plan (no file changes) + approval token

W

apply_organize

Execute the approved plan (copy by default)

W

undo_last_organize

Revert based only on the journal record

list_roots
  → scan_documents          어떤 문서가 있는지
  → outline_document        긴 문서는 뼈대부터
  → read_document           원문을 근거로 확보 (필요하면 이어 읽기)
  → (Claude가 요약 작성)
  → preview_save_summary    저장 내용 확인
  → [사용자 승인]
  → save_summary

Organization is done separately.

preview_organize   계획만 생성 — 파일은 하나도 건드리지 않음
  → [사용자가 계획 확인·승인]
  → apply_organize (기본 copy)
  → 문제가 있으면 undo_last_organize

There are four organization criteria.

Criterion

Result folder

by_kind

01_Documents 02_PDF 03_Presentations 04_Spreadsheets

by_month

Modified month like 202608

by_kind_month

02_PDF/202608

by_keyword

Names specified in rules. Example: {"contracts": ["contract","agreement"]}

Safety mechanisms

  1. Path blocking — Every input path is resolve()d and then checked to be inside the allowed roots. .., symbolic links, and drive traversal are all blocked here.

  2. Write blocking — Saving is only possible inside the output folder. Nothing is written to the read roots.

  3. Excluded folders.git, node_modules, .venv, AppData, etc. are neither scanned nor read.

  4. Approval token — A hash of the preview content. If even one character of the content changes, the token breaks and saving/organizing is rejected. However, the token only guarantees technical integrity and does not replace user approval.

  5. Copy by default — Moving originals is only possible with DOCS_MCP_ALLOW_MOVE=1.

  6. No deletion — Undo also does not delete files; it moves them to a _trash folder.

Verification

.venv/Scripts/python.exe -m pytest -q
.venv/Scripts/python.exe scripts/smoke.py
.venv/Scripts/python.exe scripts/simulate.py
  • pytest — format-specific extraction, boundary checks, approval flow (unit tests)

  • smoke.py — verifies initialize → tools/list → tools/call over real stdio

  • simulate.pycreates a virtual document set and reproduces the entire flow over a real MCP connection. It creates 12 virtual documents (meeting minutes, contracts, quotes, presentation materials, PDFs, CP949 memos, etc.), then runs through scanning → summary saving → organization → undo, and verifies that things that should be blocked (reading outside roots, token forgery, moving originals) are actually blocked. It runs in a temporary folder and cleans up after itself. Pass a folder as an argument to keep the results.

Limitations

  • Scanned image PDFs have no text. No OCR is performed; only a warning is left.

  • Excel date cells may appear as internal serial numbers.

  • .hwp (binary) is best-effort extraction. Table and footnote order may differ from the original.

  • Text inside images is not read in any format.

License

MIT — LICENSE

Install Server
A
license - permissive license
A
quality
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    A
    maintenance
    Converts PDFs, Office files, spreadsheets, emails, audio, and more to Markdown locally, enabling AI assistants to read and process them without cloud upload.
    MIT
  • F
    license
    Not graded
    quality
    C
    maintenance
    Enables AI assistants to interact with local documents (PDF, Markdown, TXT) through tools for discovery, reading, extraction, summarization, comparison, keyword extraction, search, and analysis, ensuring privacy and offline capability.
  • F
    license
    Not graded
    quality
    C
    maintenance
    Enables local, read-only extraction of text and structure from PDF, DOCX, PPTX, SVG, and PNG files, including OCR for images, directory tree and metadata reporting, with strict path isolation and audit logging.

View all related MCP servers

Related MCP Connectors

  • Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.

  • Read PDFs and images as markdown or text, with exact costs and hard spend caps. $0.75/1k pages.

  • Vector RAG store for Word/Excel/PDF/PowerPoint. Break-even pricing, $5 per 5,700 pages.

View all MCP Connectors

Latest Blog Posts

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/samsung10-gif/file_check'

If you have feedback or need assistance with the MCP directory API, please join our Discord server