# Scholar Cli

> Agent-native CLI for research papers: arXiv search + Semantic Scholar citations, local SQLite mirror, MCP server, and a Printing Press-style Claude Code skill.

- **Type:** MCP server
- **Install:** `agentstack add mcp-saakshigupta2002-scholar-cli`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [saakshigupta2002](https://agentstack.voostack.com/s/saakshigupta2002)
- **Installs:** 0
- **Category:** [Databases](https://agentstack.voostack.com/c/databases)
- **Latest version:** 0.1.0
- **License:** Apache-2.0
- **Upstream author:** [saakshigupta2002](https://github.com/saakshigupta2002)
- **Source:** https://github.com/saakshigupta2002/scholar-cli

## Install

```sh
agentstack add mcp-saakshigupta2002-scholar-cli
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# scholar

An **agent-native CLI for research papers**. Search arXiv, read abstracts, and
trace citations from the terminal — with a local SQLite mirror for instant,
offline repeat lookups.

Built in the [Printing Press](https://printingpress.dev/) style: token-efficient
output, a local data mirror, a companion Claude Code skill, and an MCP server.
No API key required; no third-party Python dependencies.

## Install

Two interchangeable implementations live in this repo — **identical commands
and JSON output**. Pick whichever suits you.

**Go** — a single static binary (matches the Printing Press standard):

```bash
go install github.com/saakshigupta2002/scholar-cli/cmd/scholar@latest
scholar mcp   # runs the MCP server over stdio
```

**Python** — zero third-party dependencies:

```bash
pipx install "git+https://github.com/saakshigupta2002/scholar-cli"   # gives `scholar` and `scholar-mcp`
# or from a clone:            pip install -e .
# or without installing:      python3 -m scholar search "graph neural networks"
```

## Usage

```bash
scholar search "diffusion models protein design"   # search arXiv
scholar get 1706.03762                              # one paper + abstract
scholar cites 1706.03762                            # who cited it
scholar cites 1706.03762 --references               # what it cites
scholar fulltext 1706.03762                         # full text (to summarize)
scholar list                                        # cached papers (offline)
```

### Agent-friendly flags

```bash
scholar --json search "mixture of experts" --max 5         # structured output
scholar --json --select id,title search "rag" --max 10     # only the fields you need
```

| Flag | Purpose |
|------|---------|
| `--json` | Structured JSON for agents/scripts |
| `--select a,b,c` | Keep only these fields (saves tokens) |
| `--max N` | Number of results |
| `--cat cs.LG` | Limit a search to a category |
| `--sort relevance\|submitted\|updated` | Result ordering |

Exit codes: `0` ok · `2` usage · `3` not found · `4` upstream/network error.

## How it's built

| Piece | Job |
|-------|-----|
| `scholar/arxiv.py` | arXiv client (search + fetch by id) |
| `scholar/semscholar.py` | Semantic Scholar client (citations) |
| `scholar/db.py` | Local SQLite mirror (`~/.scholar/scholar.db`) |
| `scholar/output.py` | Human table vs `--json` / `--select` |
| `scholar/cli.py` | Command parsing and dispatch |
| `scholar/mcp_server.py` | MCP server (stdio) exposing the same tools |
| `cli-skills/pp-scholar/SKILL.md` | Claude Code skill that drives the CLI |

A mirror-image **Go implementation** lives in [`cmd/scholar/`](cmd/scholar/)
(same commands, same JSON, same SQLite mirror) — a single static binary for
the Printing Press library. Run its MCP server with `scholar mcp`.

## MCP

The same operations are available over MCP for agents that prefer it:

```json
{ "mcpServers": { "scholar": { "command": "scholar-mcp" } } }
```

## Data sources

- [arXiv API](https://info.arxiv.org/help/api/) — search and metadata (free, open).
- [Semantic Scholar Graph API](https://api.semanticscholar.org/api-docs/graph) — citations (free).

Please be polite to both APIs (they are free and rate-limited).

## License

Apache-2.0.

## Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [saakshigupta2002](https://github.com/saakshigupta2002)
- **Source:** [saakshigupta2002/scholar-cli](https://github.com/saakshigupta2002/scholar-cli)
- **License:** Apache-2.0

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/mcp-saakshigupta2002-scholar-cli
- Seller: https://agentstack.voostack.com/s/saakshigupta2002
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
