
hanweg/mcp-pdf-tools 是从 https://github.com/hanweg/mcp-pdf-tools. 导入的 MCP 服务器候选
概览
hanweg/mcp-pdf-tools 是从 https://github.com/hanweg/mcp-pdf-tools. 导入的 MCP 服务器候选
概述(AI 翻译)
MCP PDF 工具服务器
一个MCP(模型上下文协议)服务器,提供PDF处理工具。该服务器允许大型语言模型通过模型上下文协议执行诸如合并PDF和提取页面等操作。
特色
- 将多个PDF文件合并为一个PDF。
- 按用户指定顺序将多个PDF文件合并为单一PDF。
- 从PDF文件中提取特定页面
- 搜索PDF文件系统搜索或“全部搜索”比这个更有效
- 基于文本提取和正则表达式模式匹配,从目标输入 PDF 中查找(并合并)相关 PDF
安装
- 克隆此仓库
使用 Claude Desktop
将此添加到您的Claude桌面配置文件(claude_desktop_config.json):
PDF_TOOLS_ALLOWED_DIRS 是一个可选路径列表(使用操作系统路径分隔符),它限制所有工具的文件访问。如果未设置,服务器将限制访问其当前工作目录。
写入工具(merge-pdfs、extract-pages、merge-pdfs-ordered)拒绝覆盖已有输出文件,除非提供overwrite: true。
本页由 AI 翻译,技术细节请以原文为准。
README
WORK IN PROGRESS - USE WITH CAUTION - Windows:
MCP PDF Tools Server
An MCP (Model Context Protocol) server that provides PDF manipulation tools. This server allows LLMs to perform operations like merging PDFs and extracting pages through the Model Context Protocol.
Features
- Merge multiple PDF files into a single PDF
- Merge multiple PDF files into a single PDF in user specified order
- Extract specific pages from a PDF file
- Search PDFs filesystem search or Everything search works better than this
- Find (and merge) related PDFs based on text extraction and regex pattern matching from a target input PDF
Installation
- Clone this repository
cd mcp-pdf-tools
# Create and activate virtual environment
uv venv
.venv\Scripts\activate
# Install the package
uv pip install -e .
Usage with Claude Desktop
Add this to your Claude Desktop configuration file (claude_desktop_config.json):
{
"mcpServers": {
"pdf-tools": {
"command": "uv",
"args": [
"--directory",
"PATH_TO\\mcp-pdf-tools",
"run",
"pdf-tools"
],
"env": {
"PDF_TOOLS_ALLOWED_DIRS": "PATH_TO\\shared\\pdfs"
}
}
}
}
PDF_TOOLS_ALLOWED_DIRS is an optional path list (use your OS path separator) that restricts file access for all tools. If not set, the server limits access to its current working directory.
Write tools (merge-pdfs, extract-pages, merge-pdfs-ordered) refuse to overwrite an existing output file unless overwrite: true is provided.
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →配置
{
"mcpServers": {
"pdf-tools": {
"command": "uv",
"args": [
"--directory",
"PATH_TO\\mcp-pdf-tools",
"run",
"pdf-tools"
],
"env": {
"PDF_TOOLS_ALLOWED_DIRS": "PATH_TO\\shared\\pdfs"
}
}
}
}