paper-fetch-safe
Searches arXiv and resolves arXiv identifiers, including downloading open-access PDFs when permitted by the configured license policy.
Resolves DOI identifiers to paper metadata and open-access PDF candidates, subject to license checks.
Resolves HAL identifiers to paper records and open-access PDF candidates.
Resolves OSF identifiers to paper records and open-access PDF candidates.
Searches PubMed / Europe PMC and resolves PMID and PMCID identifiers for paper metadata and open-access PDFs.
Supports optional Semantic Scholar API access via an API key for paper metadata/provider lookups.
Resolves Zenodo identifiers to paper records and open-access PDF candidates.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
paper-fetch-mcp-safe
一个带版权与许可边界的论文检索、解析和开放 PDF 下载 MCP 服务。
搜索 OpenAlex、arXiv、PubMed / Europe PMC
解析 DOI、PMID、PMCID、arXiv、OpenReview、ACL、PMLR、HAL、Zenodo、OSF 标识符
下载前检查开放许可或 OA 依据;默认拒绝无法确认许可的候选
校验 PDF、计算 SHA-256,并生成可审计 JSON sidecar
支持单篇、按标题和最多 500 篇批量下载
默认不启用 Sci-Hub。完整版权策略与限制见 COMPLIANCE.md。
快速开始
Windows PowerShell
git clone https://github.com/yhwucn12-cell/paper-fetch-mcp-safe.git
cd paper-fetch-mcp-safe
python -m venv .venv
.venv\Scripts\python.exe -m pip install -e .
Copy-Item paper-fetch.toml.example paper-fetch.tomlmacOS / Linux
git clone https://github.com/yhwucn12-cell/paper-fetch-mcp-safe.git
cd paper-fetch-mcp-safe
python3 -m venv .venv
source .venv/bin/activate
pip install -e .
cp paper-fetch.toml.example paper-fetch.toml编辑 paper-fetch.toml,至少填写联系邮箱:
mailto = "you@example.org"
license_policy = "open"
allow_scihub = false
# download_directory = "downloads"启动服务:
.venv\Scripts\python.exe -m paper_fetch_mcp_safe.server --config paper-fetch.tomlmacOS / Linux 使用:
.venv/bin/python -m paper_fetch_mcp_safe.server --config paper-fetch.tomlRelated MCP server: paper-search-mcp
MCP 客户端配置
将下列配置加入支持 stdio MCP 的客户端,并替换为实际绝对路径:
{
"mcpServers": {
"paper-fetch-safe": {
"command": "D:/path/to/paper-fetch-mcp-safe/.venv/Scripts/python.exe",
"args": [
"-m",
"paper_fetch_mcp_safe.server",
"--config",
"D:/path/to/paper-fetch-mcp-safe/paper-fetch.toml"
]
}
}
}服务提供两个工具:
工具 | 用途 |
| 搜索、解析、单篇下载和批量下载 |
| 查看 provider、限速状态和当前许可策略 |
配置
配置项 | 默认值 | 说明 |
| 必填 | 提交给学术 API 的联系邮箱 |
| 未设置 | 默认下载目录;也可在请求中传入 |
|
|
|
|
| 启用 gray 来源;启动时会警告 |
| 空 | 可选 OpenAlex API key |
| 空 | 可选 Semantic Scholar API key |
| 空 | 可选 CORE API key;未配置时自动跳过 CORE |
|
| HTTP 超时时间 |
| 内置值 | 按主机设置请求速率 |
许可策略:
策略 | 接受范围 |
| 明确开放许可或可信开放来源;始终拒绝 gray |
| 默认;在 |
| 接受无许可证据的非 gray 候选;仅在自备合法依据时使用 |
用法
execute_paper_request 接受结构化参数。accepted=true 只表示请求已执行,实际结果位于 result。
搜索论文
{
"action": "search",
"query": "water oxidation catalyst",
"source": "auto",
"limit": 5,
"year_min": 2022
}检查开放 PDF
{
"action": "resolve",
"identifiers": ["10.1021/jacs.4c00478"],
"verbosity": "full"
}下载单篇论文
{
"action": "download",
"identifiers": ["arxiv:1706.03762"],
"directory": "D:/papers"
}也可按准确标题下载:
{
"action": "download",
"query": "A Precisely Specified Article Title",
"directory": "D:/papers"
}唯一准确匹配会直接下载;无法唯一匹配时返回 needs_review=true。
批量下载
{
"action": "batch",
"identifiers": [
"10.1021/jacs.4c00478",
"PMC10009416",
"arxiv:1706.03762"
],
"directory": "D:/papers",
"concurrency": 4
}批量请求支持 1–500 个标识符。默认返回摘要,逐项结果写入下载目录下的 batch-results-*.json。
下载结果
每个成功下载的 PDF 都会生成同名 .pdf.json sidecar,包含:
来源 provider、原始 URL 和文献标识符
原始及归一化许可、许可类别和判定依据
当前策略版本、PDF 版本、时间戳和 SHA-256
常见错误:
错误码 | 含义 |
| 未找到开放 PDF 候选 |
| 找到链接,但没有足够许可依据或被策略拒绝 |
| provider 请求失败,结论不完整 |
| provider 限流;可能包含 |
| 响应不是有效 PDF 或超过 200 MiB |
测试
.venv\Scripts\python.exe -m pytest -q
.venv\Scripts\python.exe -m pytest -q -m local_subprocess
.venv\Scripts\python.exe scripts\paper_download_test.py audit实时 provider 测试:
.venv\Scripts\python.exe -m pytest -q -m network
.venv\Scripts\python.exe scripts\paper_download_test.py search resolve download batch更多文档
许可证
代码以 MIT License 发布。第三方论文与 API 仍受各自许可和服务条款约束;本软件不构成法律意见。
This server cannot be deployed
Maintenance
Related MCP Connectors
Legitimate full-text access to scholarly articles for your AI, by DOI, with provenance.
Multi-engine scholarly research server for search, traversal, full text, and reading lists.
Federated search of books and papers, BibTeX/RIS citations, open-access retrieval and reading.
Full-text licensed and open-access research, cited to its source. Publishers are paid per use.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables scholarly search, paper metadata, citation graphs, author and venue resolution, candidate harvesting, API quota visibility, and guarded full-text downloads through the OpenAlex API.94MIT
- AlicenseAqualityDmaintenanceEnables searching scholarly literature across CrossRef, ERIC, Semantic Scholar, and OpenAlex, and retrieving open-access PDFs via Unpaywall.9MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to conduct academic research workflows such as paper discovery, literature mapping, citation chasing, author pivots, citation repair, and regulatory or species document retrieval.MIT
- AlicenseAqualityAmaintenanceEnables federated search across open-access scientific literature, legal full-text retrieval with provenance, and full-text search over papers already stored locally.141MIT