project-structure

project-structure is a cursor rule for Cursor from hhx465453939/mcp-pubmed-server. It costs 555 tokens per session, scanned A, original, Apache-2.0.

A project-structure description for an MCP server that provides PubMed, a database of biomedical research papers, to AI assistants. It documents its files, search tools, caching, rate limits, and error handling.

In plain words
What is it for?
Use it as a guide when maintaining or extending a PubMed MCP server that searches papers, retrieves details, extracts key information, or compares references.
Why use it?
It helps a developer understand how the PubMed server is organized and what its main components do.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it as a guide when maintaining or extending a PubMed MCP server that searches papers, retrieves details, extracts key information, or compares references.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/hhx465453939/mcp-pubmed-server/project-structure
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/hhx465453939/mcp-pubmed-server

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for project-structure

README.md
[![agentmods](https://agentmods.dev/badge/rules/hhx465453939/mcp-pubmed-server/project-structure/github.svg)](https://agentmods.dev/rules/hhx465453939/mcp-pubmed-server/project-structure)
Your own site
<a href="https://agentmods.dev/rules/hhx465453939/mcp-pubmed-server/project-structure"><img src="https://agentmods.dev/badge/rules/hhx465453939/mcp-pubmed-server/project-structure/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for project-structure

Your own site · 80×15
<a href="https://agentmods.dev/rules/hhx465453939/mcp-pubmed-server/project-structure"><img src="https://agentmods.dev/badge/rules/hhx465453939/mcp-pubmed-server/project-structure.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 555 This file is loaded in full into every session.
When invoked 555 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00555 $0.00555
Opus 5.5 $0.00222 $0.00222
Sonnet 5.5 $0.00111 $0.00111
Haiku 4.5 $0.00056 $0.00056

Measured 1mo ago against content hash 5bfaa83b2983, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

project-structure scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/project-structure.mdc · 52 lines

What it actually says

MCP PubMed服务器项目结构

核心架构

这是一个MCP (Model Context Protocol) 服务器,专门为LLM提供PubMed文献数据服务。

主要入口点

  • 主服务器: src/index.js - 包含完整的PubMedDataServer类
  • 配置文件: config/mcp-config.json - MCP服务器配置
  • 环境配置: .env 文件 - 包含PubMed API密钥和邮箱

项目结构

mcp-pubmed-server/
├── src/
│   └── index.js              # 主服务器代码 (1352行)
├── config/
│   ├── mcp-config.json       # MCP配置模板
│   └── claude_desktop_config.json  # Claude Desktop配置
├── .cursor/rules/            # Cursor规则目录
├── package.json              # 项目依赖配置
└── README.md                 # 详细文档

核心功能模块

1. PubMedDataServer类

  • 位置: src/index.js 第28行开始
  • 功能: 主要的MCP服务器实现
  • 特点: 包含缓存管理、速率限制、错误处理

2. 5个核心工具

  1. pubmed_search - 智能文献搜索
  2. pubmed_get_details - 详细信息获取
  3. pubmed_extract_key_info - 关键信息提取
  4. pubmed_cross_reference - 交叉引用分析
  5. pubmed_batch_query - 批量查询优化

3. 缓存系统

  • 内存缓存: Map对象,5分钟过期,LRU淘汰
  • 文件缓存: JSON文件,30天过期,持久化存储
  • 缓存目录: cache/papers/ 和 cache/index.json

开发原则

  • 极简架构: 专注数据提供,不包含复杂业务逻辑
  • LLM优化: 输出格式专门为LLM分析优化
  • 性能优先: 智能缓存、速率限制、批量处理
  • 错误处理: 完善的异常捕获和用户友好的错误信息
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 52 lines · 555 tokens per session scan A 5bfaa83b2983

Subscribe to this mod's changes

project-structure is a cursor rule published in the GitHub repository hhx465453939/mcp-pubmed-server (6 stars, last pushed 8mo ago), licensed Apache-2.0. It adds 555 tokens to every session, about $0.0022 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.