Document MCP
Document MCP
ChatGPT 스타일의 챗봇과 Document MCP 서버입니다. 설정에서 폴더 경로와 로컬 LiteLLM 모델을 등록합니다. 질문은 MCP 도구와 함께 LiteLLM으로 전송되며, 서버는 pywin32 COM을 사용하여 Word/Excel/PowerPoint 파일만 읽습니다(Model Council과 동일한 Office 경로).
Chat UI → LiteLLM /v1/chat/completions (+ tools)
↑ tool_calls (search_documents, read_document, …)
MCP host → Document MCP (stdio JSON-RPC)
→ allowlisted folders
→ win32com Word / Excel / PowerPointClaude Desktop, Claude Code, Cursor는 동일한 MCP 서버와 동일한 폴더 목록에 연결됩니다.
빠른 시작
LiteLLM 프록시를 실행합니다.
start.bat을 더블 클릭합니다.http://127.0.0.1:7860을 엽니다.
설정 → LiteLLM: 기본 URL(예:
http://localhost:4000), API 키를 붙여넣고, 모델 로드 또는 모델 추가를 선택한 후 저장합니다.설정 → 폴더: Windows 폴더 경로를 붙여넣습니다.
sample_docs는 첫 실행 시 등록됩니다.해당 파일들이 답변할 수 있는 모든 것을 질문하세요.
수동
python -m venv .venv
.venv\Scripts\activate
pip install -r requirements.txt
copy .env.example .env
python -m app설정
탭 | 기능 |
LiteLLM | 기본 URL, 키, |
폴더 | MCP 루트(허용 목록). Model Council의 |
Claude MCP | Claude Desktop / Claude Code / Cursor 스니펫 복사, 또는 Claude Desktop 구성을 직접 작성 |
URL은 http://host:4000, http://host:4000/v1, 또는 .../v1/chat/completions 형식으로 붙여넣을 수 있습니다. Model Council과 같이 정규화됩니다.
LiteLLM + MCP 작동 방식
Model Council의 앱 내 MCP 루프에서 가져왔습니다:
호스트가 MCP
tools/list를 호출하고 스키마를 OpenAI 도구로 변환합니다.호스트가 해당 도구와 함께
chat/completions를 LiteLLM에 POST합니다(tool_choice: auto).모델이
tool_calls를 반환하면 호스트가 MCPtools/call(stdio)을 실행합니다.도구 JSON이
role: tool로 추가되고 일반 답변이 나올 때까지 루프가 반복됩니다.
모델은 도구를 호출하지 않는 한 파일을 볼 수 없습니다. 루트는 허용 목록에 있습니다. Office 파일은 COM을 선호하므로 Windows 잠금 해제/IRM 파일도 읽을 수 있습니다.
MCP 도구
도구 | 용도 |
| 상태, 엔진, 폴더 수 |
| 등록된 루트 |
| 루트 변경 |
| 인벤토리 |
| 이름 + 추출된 텍스트 |
| 추출(COM 우선, 라이브러리 대체) |
프롬프트: ask_documents.
Claude Desktop / Claude Code / Cursor
챗봇에서: 설정 → Claude MCP → Claude Desktop에 추가(%APPDATA%\Claude\claude_desktop_config.json에 작성). Claude를 다시 시작한 후 ping Document MCP를 요청하세요.
또는 이 형식을 복사하세요(경로는 설정에서 채워집니다):
{
"mcpServers": {
"document-mcp": {
"command": "D:\\\\AntigravityCodes\\\\Document-MCP\\\\.venv\\\\Scripts\\\\python.exe",
"args": ["-m", "document_mcp"],
"cwd": "D:\\\\AntigravityCodes\\\\Document-MCP",
"env": {
"PYTHONUTF8": "1",
"DOCUMENT_MCP_ROOTS": "D:\\\\AntigravityCodes\\\\Document-MCP\\\\data\\\\folders.json"
}
}
}
}Claude Code:
claude mcp add-json document-mcp "{...stdio server json from Settings...}"Cursor: 저장소 mcp.json, 또는 설정 → Claude MCP에서 Cursor 스니펫을 복사하세요.
HTTP (LiteLLM MCP 게이트웨이):
start_mcp_http.bat그런 다음 http://127.0.0.1:8765/mcp를 추가하세요.
pywin32 / Office
Word.Application→.doc/.docxExcel.Application→.xls/.xlsx/.xlsmPowerPoint.Application→.ppt/.pptx
대체: python-docx / openpyxl / python-pptx. PDF: PyMuPDF. 레거시 바이너리 Office는 여전히 Microsoft Office가 필요합니다.
python -m document_mcp.reader sample_docs\mena_rhq_overview.md레이아웃
app/ FastAPI chat host (MCP client + UI)
document_mcp/ FastMCP server, COM readers, Claude install helper
sample_docs/ Starter files
data/ folders.json, settings, extract cache (local)This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
OCR, transcription, file extraction, and image generation for AI agents via MCP.
Securely search and manage workspace context files for AI agents and teams.
Remote MCP for Copilot CLI switch gate MCP, structured receipts, audit logs, and reviewer-ready evid
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/MENARHQ-cloud/Document-MCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server