Metadata-Version: 2.5
Name: paper-radar-mcp
Version: 0.1.0
Summary: MCP server that searches arXiv, bioRxiv and PubMed together, with digests and Markdown export.
Project-URL: Homepage, https://github.com/partrita/paper-radar-mcp
Project-URL: Issues, https://github.com/partrita/paper-radar-mcp/issues
Author: Kim Taeyun
License: MIT License
        
        Copyright (c) 2026 Kim Taeyun
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Keywords: arxiv,bioinformatics,biorxiv,literature,llm,mcp,model-context-protocol,pubmed
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Requires-Python: >=3.10
Requires-Dist: httpx>=0.27
Requires-Dist: mcp[cli]>=1.2
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.5; extra == 'dev'
Description-Content-Type: text/markdown

# paper-radar-mcp

**One MCP call that searches arXiv, bioRxiv and PubMed together — de-duplicated, dated, and ready for a briefing.**

[![CI](https://github.com/partrita/paper-radar-mcp/actions/workflows/ci.yml/badge.svg)](https://github.com/partrita/paper-radar-mcp/actions/workflows/ci.yml)
[![Python](https://img.shields.io/badge/python-3.10%2B-blue)](https://www.python.org/)
[![License: MIT](https://img.shields.io/badge/license-MIT-green)](LICENSE)
[![MCP](https://img.shields.io/badge/MCP-compatible-6f42c1)](https://modelcontextprotocol.io)
<!-- PyPI badge: enable after the first release
[![PyPI](https://img.shields.io/badge/pypi-paper--radar--mcp-blue)](https://pypi.org/project/paper-radar-mcp/)
-->

A literature radar for an MCP-capable agent (Claude Desktop, Claude Code, Cursor, …):
**what is new on bioRxiv**, **what arXiv posted about protein models**, **what PubMed indexed
about a target** — in one query, without duplicates, with the abstract already shortened so
it fits in context.

No API keys, no scraping. Three free public APIs, one server.

> 한국어 요약은 [아래](#한국어-요약)에 있습니다.

---

## What it does

| | One source at a time | **paper-radar-mcp** |
| --- | --- | --- |
| Coverage | arXiv *or* bioRxiv *or* PubMed | all three in one call |
| Duplicates | the same preprint counted three times | merged by DOI, or normalised title when there is no DOI; the other source is kept in `also_in` |
| bioRxiv keyword search | its own API has no keyword search | searched through Europe PMC with `SRC:PPR` + `PUBLISHER:"bioRxiv"` |
| Dates | three different formats | `YYYY-MM-DD` everywhere, plus a `days` window per source |
| Context | full abstracts, every field | shortened abstracts, three authors + count, empty fields dropped |
| Daily briefing | build it yourself | `daily_digest` groups the last N days by keyword |

## Quick start

```bash
# Run without installing (once released)
uvx paper-radar-mcp

# or install it into a project
uv add paper-radar-mcp
```

### Claude Desktop

`~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or
`%APPDATA%\Claude\claude_desktop_config.json` (Windows):

```json
{
  "mcpServers": {
    "papers": {
      "command": "uvx",
      "args": ["paper-radar-mcp"],
      "env": {
        "NCBI_EMAIL": "you@example.com"
      }
    }
  }
}
```

`NCBI_EMAIL` is optional. NCBI asks API users to identify themselves, and Europe PMC/arXiv
are happier with a polite client; the server sends a descriptive User-Agent either way.

### Cursor

`~/.cursor/mcp.json` — same `mcpServers` block as above.

### Claude Code

```bash
claude mcp add papers -- uvx paper-radar-mcp
```

---

## Tools

### `search_papers`

```text
search_papers(query="protein language model", sources=["arxiv", "biorxiv", "pubmed"], days=120, max_results=5)
```

Free text is turned into each source's own syntax: quoted terms ANDed for arXiv, a
`(query) AND SRC:PPR AND PUBLISHER:"bioRxiv"` filter for Europe PMC, and a
`[dp]`-bounded term for PubMed. Text that already uses arXiv field syntax (`ti:`, `abs:`,
`AND`) is passed through untouched.

```json
{
  "query": "protein language model",
  "sources": ["arxiv", "biorxiv", "pubmed"],
  "days": 120,
  "found": 9,
  "count": 1,
  "results": [
    {
      "source": "arxiv",
      "id": "2612.05134",
      "title": "GROVE: Rethinking Evaluation of Function-Conditioned Protein Design",
      "authors": ["Leandro Yu Jin Liang", "Bin Feng", "Zi-Ang Ma"],
      "author_count": 5,
      "date": "2026-12-03",
      "url": "https://arxiv.org/abs/2612.05134",
      "venue": "arXiv preprint",
      "abstract": "Function-conditioned protein design maps a functional specification to a protein sequence. …",
      "category": "cs.LG"
    }
  ]
}
```

- `found` is how many unique papers the search saw; `count` is how many were returned.
- `also_in` lists the other sources a merged record also appeared in.
- PubMed search results carry no abstract (it would cost one extra request per hit); call
  `get_paper_details` when you need it.
- A source that is down or rate limiting does not sink the call: it is listed in `warnings`
  and the other sources still answer.

### `daily_digest`

```text
daily_digest(keywords=["antibody language model", "biosimilar"], days=7, per_keyword=4)
```

One dated section per keyword (max 8), newest first. A paper that matches two keywords is
shown once, under the first keyword that found it, so a briefing does not repeat itself.

The response is `generated`, `days`, `sources`, `keywords`, `total`, and `sections`. Each
section is `{keyword, count, papers}`, where every paper uses exactly the record shape from
`search_papers`. A real run over one week returned `total: 4` with two sections of two
papers each for keywords `antibody language model` and `biosimilar`.

### `get_paper_details`

```text
get_paper_details(identifier="10.64898/2026.11.30.769921")
```

Accepts an arXiv id (`2612.05134`), a DOI, a bioRxiv/Europe PMC id (`PPR…`) or a PMID. The
shape of the identifier is enough: `source="auto"` routes it to arXiv, Europe PMC or
PubMed's `efetch`, and the full abstract comes back (up to 4000 characters) with journal,
volume, pages and DOI. When a record genuinely has no abstract, the response says so
instead of leaving the field empty.

### `export_markdown`

```text
export_markdown(query="antibody developability", days=30, max_results=10)
```

Returns the same results as a Markdown brief in the `markdown` field — nothing is written
to disk, so the agent decides where it goes (a note, a Slack post, a file):

```markdown
# Paper radar — antibody developability

_2 of 6 unique hits · last 30 days · generated 2026-12-05 · sources: arXiv, bioRxiv, PubMed_

## 1. NeuroBind: de novo design of protein binders against arbitrary targets

- **Source:** bioRxiv · 2026-12-01 · [PPR1384205](https://doi.org/10.64898/2026.11.30.769921)
- **Authors:** Amani K, Amirabadi DG
- **Venue:** bioRxiv
- **DOI:** [10.64898/2026.11.30.769921](https://doi.org/10.64898/2026.11.30.769921)

> The programmable design of high-affinity protein binders remains a central challenge …
```

---

## Design notes

- **Preprints are labelled as preprints.** Every Europe PMC record from the preprint index
  carries `preprint: true`; the server's instructions tell the agent to say which source a
  claim came from.
- **A source failure is data, not an exception.** `warnings` lists the source and the
  reason; the remaining sources answer normally.
- **Dates are normalised once.** `2026-12-04T20:00:00Z`, `2026-12-02`, `2024 Jun 23` and
  `2024` all become sortable `YYYY-MM-DD`.
- **Small by default.** Three authors plus a count, a 600-character abstract in list
  responses, no empty fields. Full abstracts only on request.
- **No keys, no secrets.** Nothing to configure beyond an optional contact email.
- **Polite to the APIs.** One request per source per search, descriptive User-Agent, and
  PubMed's `esummary` batching (one call for all ids) instead of one call per paper.

## Development

```bash
git clone https://github.com/partrita/paper-radar-mcp
cd paper-radar-mcp
uv venv && source .venv/bin/activate
uv pip install -e ".[dev]"

ruff check .
pytest            # 55 tests, no network: every API body is a fixture
```

Live checks hit all three APIs and are skipped by default:

```bash
PAPER_RADAR_LIVE=1 pytest -m live
```

## 한국어 요약

arXiv·bioRxiv·PubMed를 한 번에 검색하는 MCP 서버입니다. 세 곳의 결과를 DOI(없으면 제목)로
합쳐 중복을 없애고, 날짜순으로 정리해 돌려줍니다. API 키는 필요 없습니다.

| 툴 | 하는 일 |
| --- | --- |
| `search_papers` | 세 소스를 통합 검색하고 중복을 제거해 최신순으로 반환 |
| `daily_digest` | 최근 N일 결과를 키워드별로 묶어 브리핑 형태로 반환 |
| `get_paper_details` | arXiv ID·DOI·PPR ID·PMID로 초록 전체와 메타데이터 조회 |
| `export_markdown` | 같은 결과를 붙여넣기 좋은 마크다운으로 반환 |

bioRxiv는 자체 키워드 검색 API가 없어 Europe PMC의 프리프린트 색인(`SRC:PPR`)으로
검색합니다. 한 소스가 응답하지 않아도 나머지 결과를 주고 `warnings`에 이유를 적습니다.

## License

MIT
