ScholarMCP
An MCP server that enables coding agents to search academic papers, ingest full-text PDFs, extract structured details, and manage citations in literature research workflows.
README

ScholarMCP
ScholarMCP is an MCP server for literature research workflows in coding agents. Official documentation: https://scholar-mcp.lstudlo.com/
Early Development Notice
This project is still in early development, and rough edges or bugs may occur. If you run into a problem, please open an issue and include:
- the agent used
- screenshots, if applicable
- steps to reproduce the issue
ScholarMCP gives your agent tools to:
- search papers across multiple sources
- ingest and parse full-text PDFs
- extract structured paper details
- suggest citations and build references
- validate manuscript citations
ScholarMCP is for...
Use this if you want Claude Code, Codex, or any MCP-compatible coding agent to run research tasks directly from chat.
Quick Start
1. Prerequisites
- Node.js
>=20 npm(for install/publish)pnpm(for contributors working from source)
2. Install as an npm package (recommended)
npm install -g scholar-mcp
One-off run without global install:
npx -y scholar-mcp --transport=stdio
Install from GitHub Packages (scoped mirror package):
npm install -g @lstudlo/scholar-mcp --registry=https://npm.pkg.github.com
3. Run
Stdio mode:
scholar-mcp --transport=stdio
HTTP mode:
scholar-mcp --transport=http
Health check (HTTP mode):
curl http://127.0.0.1:3000/health
4. Run from source (contributors)
pnpm install
pnpm dev:stdio
Use with Coding Agents
ScholarMCP works best over stdio for local coding agents. The docs site has full step-by-step guides for Claude Code, OpenAI Codex, and OpenCode. Anthropic officially documents claude mcp add ... -- <command>, and OpenAI officially documents codex mcp add ...; the short forms below keep those CLI flows as the primary setup path.
Shared environment values used below:
SCHOLAR_MCP_TRANSPORT=stdio
SCHOLAR_REQUEST_DELAY_MS=350
RESEARCH_ALLOW_REMOTE_PDFS=true
RESEARCH_ALLOW_LOCAL_PDFS=true
Claude Code
Add with the Claude CLI:
claude mcp add -s user \
--transport stdio \
-e SCHOLAR_MCP_TRANSPORT=stdio \
-e SCHOLAR_REQUEST_DELAY_MS=350 \
-e RESEARCH_ALLOW_REMOTE_PDFS=true \
-e RESEARCH_ALLOW_LOCAL_PDFS=true \
scholar_mcp -- npx -y scholar-mcp --transport=stdio
Verify:
claude mcp get scholar_mcp
Manual fallback:
- add
scholar_mcpundermcpServersin~/.claude.json - use project-local
.mcp.jsonif you want the config scoped to the repo - keep the
--separator in the CLI form; Claude needs it to stop parsing flags
OpenAI Codex
Add with the Codex CLI:
codex mcp add scholar_mcp \
--env SCHOLAR_MCP_TRANSPORT=stdio \
--env SCHOLAR_REQUEST_DELAY_MS=350 \
--env RESEARCH_ALLOW_REMOTE_PDFS=true \
--env RESEARCH_ALLOW_LOCAL_PDFS=true \
-- npx -y scholar-mcp --transport=stdio
Verify:
codex mcp list
codex mcp get scholar_mcp --json
Manual fallback:
- add the server to
~/.codex/config.tomlunder[mcp_servers.scholar_mcp] - Codex CLI and the Codex app share that MCP config model
OpenCode
Add with the OpenCode CLI:
opencode mcp add
Recommended interactive values:
- name:
scholar_mcp - type:
local - command:
npx -y scholar-mcp --transport=stdio - enabled:
true - env: use the four shared variables above
Verify:
opencode mcp list
Manual fallback:
- add the server to
~/.config/opencode/opencode.json - use
"type": "local"and a command array like["npx", "-y", "scholar-mcp", "--transport=stdio"]
Run from source
If you are developing ScholarMCP locally, use this launcher instead of npx -y scholar-mcp --transport=stdio:
pnpm --filter scholar-mcp dev:stdio
Use the same environment values shown above in whichever client you register.
Generic MCP clients
stdiocommand:scholar-mcp --transport=stdio- Or:
npx -y scholar-mcp --transport=stdio
- HTTP endpoint:
- Start server with
SCHOLAR_MCP_TRANSPORT=http scholar-mcp - Connect client to
http://127.0.0.1:3000/mcp - Optional auth: set
SCHOLAR_MCP_API_KEYand send bearer auth header from your client
- Start server with
MCP Tools
| Tool | Purpose |
|---|---|
search_literature_graph |
Federated search over OpenAlex/Crossref/Semantic Scholar (+ optional scholar scrape). |
search_google_scholar_key_words |
Keyword search on Google Scholar. |
search_google_scholar_advanced |
Scholar search with author/year/phrase filters. |
get_author_info |
Resolve author profile and top publications. |
ingest_paper_fulltext |
Start async full-text ingestion from DOI/URL/PDF/local path. |
get_ingestion_status |
Poll ingestion job status and parsed summary. |
extract_granular_paper_details |
Extract methods, claims, datasets, metrics, and references. |
suggest_contextual_citations |
Suggest citations from manuscript context. |
build_reference_list |
Generate formatted bibliography and BibTeX. |
validate_manuscript_citations |
Detect missing/uncited/duplicate citation issues. |
Example Agent Prompts
- "Find 10 recent papers on retrieval-augmented generation and summarize methods and datasets."
- "Ingest full text for DOI
10.1038/s41467-024-55563-6, then extract claims and limitations." - "Given this draft section, suggest citations in IEEE style and generate BibTeX."
- "Validate my manuscript citations against this reference list and show missing citations."
Configuration
Most users only need these:
SCHOLAR_MCP_TRANSPORT:stdio|http|both(default:stdio)SCHOLAR_REQUEST_DELAY_MS: request pacing to reduce rate-limit risk (default:250)RESEARCH_ALLOW_REMOTE_PDFS: allow remote PDF downloads for ingestion (default:true)RESEARCH_ALLOW_LOCAL_PDFS: allow local PDF ingestion (default:true)SCHOLAR_MCP_API_KEY: optional bearer token for HTTP modeRESEARCH_GROBID_URL: optional GROBID endpoint
The CLI loads .env from the current working directory automatically at startup.
Advanced options exist in src/config.ts for timeouts, retries, HTTP session capacity/TTL, provider tuning, and cache behavior.
Troubleshooting
Invalid environment variable formatinclaude mcp add:- Add
--before the MCP server name (see Claude setup command above).
- Add
Unable to resolve a downloadable PDF URL from inputon DOI ingestion:- The DOI and landing page may not expose an accessible PDF URL.
- Retry with
pdf_url(direct PDF) orlocal_pdf_path.
- Too many Scholar failures or throttling:
- Increase
SCHOLAR_REQUEST_DELAY_MS(for example500to1000).
- Increase
Usage Notes
Google Scholar may throttle automated traffic. Use conservative request pacing, respect provider terms, and avoid abusive query patterns.
Publishing
Releases publish to two registries:
- npm:
scholar-mcpvia.github/workflows/publish.yml - GitHub Packages:
@lstudlo/scholar-mcpvia.github/workflows/publish-github-packages.yml
Release with a minimal command set:
- Validate release readiness:
pnpm release:check - Cut and publish a release:
pnpm release(patch),pnpm release minor, orpnpm release major - Start from a clean git working tree (no unstaged/staged/untracked files).
- The release command runs checks, bumps
packages/scholar-mcp/package.json, creates a release commit/tag, pushes branch/tag, then creates a GitHub Release. - GitHub Actions publishes to npm and GitHub Packages from that release tag.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。