[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7132FAPBNKE2R53QD97J9Q2":3,"skill-same:01M7132FAPBNKE2R53QD97J9Q2":86},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":23,"publishedAt":44,"linkOnly":45,"markdownContent":46,"markdownBody":47,"frontMatter":48,"refName":63,"commitSha":64,"skillDirectory":65,"forksCount":66,"repositoryHtmlUrl":67,"repositoryHomepageUrl":6,"ownerHtmlUrl":68,"ownerBlogUrl":69,"ownerDescription":70,"updatedAt":71,"install":72,"resources":85},"01M7132FAPBNKE2R53QD97J9Q2","europepmc-search",null,"Europe PMC RESTful Web Service 多源文献聚合检索原子 skill。一次调用同时召回 PubMed + PMC + AGRICOLA + CABI + 预印本(bioRxiv \u002F medRxiv \u002F ChemRxiv 等)+ 灰色文献,自动按 PMID\u002FPMCID\u002FDOI 三级去重,返回完整元数据(含全文 OA 链接、citations metadata、grants 资助信息)。当任务出现 Europe PMC、多源文献聚合、广召回、RAG 检索、预印本搜索、bioRxiv、medRxiv、全文链接、DOI 检索、跨库去重、灰色文献、资助检索 等触发词时使用。**定位**:广召回 · 多源聚合 · RAG 友好(与 pubmed-eutils 互补——后者做精准官方源、Clinical Queries;本 skill 做\"撒网\"式广召回)。**不做**:NCBI E-utilities 直检(交给 pubmed-eutils)、临床试验(clinical-trials-v2)、全文 XML 抽取(bioc-fulltext-fetch)、实体识别(pubtator-entity-search)、证据分级(medical-evidence-grading)。","EthanYoQ\u002FSkill-hub","EthanYoQ","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F257484394?v=4","01M70C9QKWR1YS0S7V26DNB18H","Ethan","01M70C9QMER047R5ANZZA6KC2P",11,"MIT","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Farchives\u002Fuser-installed-skills\u002Feuropepmc-search\u002F5eec9d3036d956eb\u002Feuropepmc-search\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43],"search","europepmc search","Utilities","rag","rag-召回","europepmc","europe-pmc","bioc","pubtator","NCBI","pmc","Citations","evidence-grading","pubmed","doi","clinical","medical","grading","grants","fetch","2026-11-10 10:12:30",false,"---\nname: europepmc-search\ndescription: Europe PMC RESTful Web Service 多源文献聚合检索原子 skill。一次调用同时召回 PubMed + PMC + AGRICOLA + CABI + 预印本(bioRxiv \u002F medRxiv \u002F ChemRxiv 等)+ 灰色文献,自动按 PMID\u002FPMCID\u002FDOI 三级去重,返回完整元数据(含全文 OA 链接、citations metadata、grants 资助信息)。当任务出现 Europe PMC、多源文献聚合、广召回、RAG 检索、预印本搜索、bioRxiv、medRxiv、全文链接、DOI 检索、跨库去重、灰色文献、资助检索 等触发词时使用。**定位**:广召回 · 多源聚合 · RAG 友好(与 pubmed-eutils 互补——后者做精准官方源、Clinical Queries;本 skill 做\"撒网\"式广召回)。**不做**:NCBI E-utilities 直检(交给 pubmed-eutils)、临床试验(clinical-trials-v2)、全文 XML 抽取(bioc-fulltext-fetch)、实体识别(pubtator-entity-search)、证据分级(medical-evidence-grading)。\nkeywords:\n  - europe-pmc\n  - europepmc\n  - 多源文献聚合\n  - rag-召回\n  - 广召回\n  - 预印本\n  - biorxiv\n  - medrxiv\n  - chemrxiv\n  - 全文链接\n  - doi-检索\n  - pmcid\n  - 灰色文献\n  - grants-检索\n  - citations-metadata\n  - 跨库去重\nlicense: MIT\n---\n\n# europepmc-search\n\nEurope PMC RESTful Web Service 的薄封装。**一次请求 = 多源召回**:PubMed(MED)、PubMed Central(PMC)、AGRICOLA(AGR)、CABI(CBA)、预印本(PPR,涵盖 bioRxiv\u002FmedRxiv\u002FChemRxiv\u002FarXiv 生命科学子集)、专利(PAT)、ETHOS 论文集等。\n\n## 1. 何时使用本 skill\n\n| 场景 | 用本 skill | 不用本 skill |\n|------|-----------|------------|\n| RAG 知识库构建,需\"撒网\"式广召回 | ✅ | |\n| 同时要 PubMed + 预印本 | ✅ | |\n| 只要 PubMed 官方源 + Clinical Queries | | ❌ → pubmed-eutils |\n| 拿 DOI 反查全文 OA 链接 | ✅ | |\n| 找特定基金(NIH\u002FNSFC\u002FWellcome)资助的研究 | ✅(`grant_id` 检索) | |\n| 抽取已知 PMCID 的全文 XML | | ❌ → bioc-fulltext-fetch |\n| 临床试验注册号检索 | | ❌ → clinical-trials-v2 |\n| 实体(基因\u002F疾病\u002F化合物)关联 | | ❌ → pubtator-entity-search |\n\n**与 pubmed-eutils 的差异化(必读)**:\n\n- pubmed-eutils:PubMed **单源**、Clinical Queries 过滤、PubDate 精确范围 → 高精准\n- europepmc-search:**多源聚合** + 自动去重 + 全文链接 + citations metadata → 高召回\n- 推荐编排:RAG 知识库构建用本 skill 广召回 → 拿 PMID 列表喂给 pubmed-eutils 做精准复核\n\n## 2. 前置准备 \u002F 配置加载\n\nEurope PMC RESTful 是**完全开放 API,无需 API key**,但服务条款要求传 `email` 联系方式(礼貌请求,便于 EBI 在大流量异常时联系到使用者)。\n\n**配置加载顺序(优先级从高到低)**:\n\n1. 项目级:`.config\u002Feuropepmc.local.yaml`(可选,优先于全局)\n2. 用户级:`~\u002F.config\u002Feuropepmc.yaml`\n3. 环境变量:`EUROPEPMC_EMAIL`\n4. 都没有 → 退化为 `anonymous@example.org` 并打印 ⚠️ 警告(建议用户配置)\n\n**配置文件示例**(`~\u002F.config\u002Feuropepmc.yaml`):\n\n```yaml\nemail: your-email@example.com\ndefault_page_size: 100        # 单页条数,1-1000\ndefault_result_type: core     # lite | core | idlist\ndefault_format: json          # json | xml | dc\ntimeout_seconds: 30\nmax_retries: 3\n```\n\n## 3. API 端点速查\n\n基础 URL:`https:\u002F\u002Fwww.ebi.ac.uk\u002Feuropepmc\u002Fwebservices\u002Frest\u002F`\n\n| 端点 | 用途 | 关键参数 |\n|------|------|---------|\n| `search` | 通用检索(本 skill 主力) | `query`, `resultType`, `pageSize`, `cursorMark`, `format`, `sort` |\n| `article\u002F{source}\u002F{id}` | 单篇详情 | source∈{MED,PMC,PPR,AGR,CBA,PAT,CTX,ETH,HIR,NBK} |\n| `{source}\u002F{id}\u002FfullTextXML` | 全文 XML(仅 OA) | 仅 PMC 子集 |\n| `{source}\u002F{id}\u002Freferences` | 参考文献 | 分页 |\n| `{source}\u002F{id}\u002Fcitations` | 被引列表 | 分页 |\n| `{source}\u002F{id}\u002FsupplementaryFiles` | 补充材料 | |\n| `grant\u002Fsearch` | 资助检索 | `query=GR:\"R01...\"` |\n\n## 4. 核心检索能力(5 个原子函数)\n\n### 4.1 `search_articles(query, source_filter=None, max_results=200, sort=None)`\n\n通用多源检索,自动分页(cursorMark)拉满到 `max_results`。\n\n- `query`:Europe PMC 查询语法(支持字段限定,见 §5)\n- `source_filter`:`[\"MED\",\"PMC\",\"PPR\"]` 限定来源;`None` = 全部\n- `sort`:`\"date\"`(出版日期降序)\u002F `\"cited\"`(被引降序)\u002F `None`(默认相关性)\n\n**返回**:`List[Article]`,每条含 `pmid \u002F pmcid \u002F doi \u002F title \u002F authors \u002F journal \u002F pub_year \u002F abstract \u002F source \u002F is_preprint \u002F preprint_server \u002F has_full_text \u002F oa_status \u002F cited_by_count`。\n\n### 4.2 `get_article_details(identifier)`\n\n单篇完整元数据。`identifier` 自动识别:\n\n- 纯数字 → PMID(查 MED 源)\n- `PMC` 前缀 → PMCID(查 PMC 源)\n- `10.` 开头 → DOI(用 query=`DOI:\"...\"` 反查)\n- `PPR` 开头 → 预印本 ID(查 PPR 源)\n\n### 4.3 `get_full_text_links(pmid_or_pmcid)`\n\n返回所有可用全文链接,按类型分类:\n\n```python\n{\n  \"oa_xml\": \"https:\u002F\u002F...\u002FfullTextXML\",      # OA 子集才有\n  \"oa_pdf\": \"https:\u002F\u002Feuropepmc.org\u002F...pdf\",\n  \"publisher_html\": \"https:\u002F\u002F...\",\n  \"subscription\": [...],                     # SUBSCRIPTION 类型\n  \"text_mining\": [...],                      # TM 类型(NLM 等)\n  \"preprint_server\": \"https:\u002F\u002Fwww.biorxiv.org\u002F...\"\n}\n```\n\n### 4.4 `search_with_grants(query, grant_id=None, funder=None)`\n\n资助检索。Europe PMC 有专门的 `GRANT_ID` \u002F `FUNDER` 字段。\n\n```python\n# 找 NIH R01-CA123456 资助的所有 paper\nsearch_with_grants(query=\"cancer\", grant_id=\"R01-CA123456\")\n\n# 找 Wellcome Trust 资助的全部 cardiology paper\nsearch_with_grants(query=\"cardiology\", funder=\"Wellcome Trust\")\n```\n\n### 4.5 `find_similar_articles(pmid_or_pmcid, limit=20)`\n\n调用 Europe PMC 内置的 \"Similar Articles\" 算法(基于 MeSH + 文本相似度)。比 PubMed `elink neighbor` 召回略广,适合做 RAG \"扩展邻域\"。\n\n## 5. 查询语法核心字段\n\nEurope PMC 查询语法兼容 Lucene 风格,字段大写。常用字段:\n\n| 字段 | 含义 | 示例 |\n|------|------|------|\n| `TITLE` | 标题 | `TITLE:\"CAR-T\"` |\n| `ABSTRACT` | 摘要 | `ABSTRACT:cytokine` |\n| `AUTH` | 作者 | `AUTH:\"Smith J\"` |\n| `JOURNAL` | 期刊 | `JOURNAL:\"Nature\"` |\n| `PUB_YEAR` | 年份 | `PUB_YEAR:[2020 TO 2024]` |\n| `PUB_TYPE` | 文献类型 | `PUB_TYPE:\"Review\"` |\n| `SRC` | 来源数据库 | `SRC:MED`, `SRC:PPR`, `SRC:PMC` |\n| `HAS_FT` | 有全文 | `HAS_FT:Y` |\n| `OPEN_ACCESS` | OA | `OPEN_ACCESS:Y` |\n| `MESH` | MeSH 主题词 | `MESH:\"Hematologic Neoplasms\"` |\n| `GRANT_ID` | 资助号 | `GRANT_ID:\"R01CA12345\"` |\n| `DOI` | DOI | `DOI:\"10.1038\u002Fs41586-020-2196-x\"` |\n| `LANG` | 语种 | `LANG:eng` |\n\n**预印本筛选示例**:`(SRC:PPR) AND (TITLE:\"acute myeloid leukemia\") AND (PUB_YEAR:2024)`\n\n## 6. 多源去重逻辑(本 skill 强制内置)\n\n同一篇文章常在 MED + PMC + PPR 同时出现。去重规则按以下优先级合并:\n\n1. **第一级:PMID 相同 → 合并**,保留 MED 版本(PubMed 元数据最权威)\n2. **第二级:PMCID 相同 → 合并**,保留 PMC 版本(因含全文)\n3. **第三级:DOI 相同 → 合并**,优先 MED > PMC > PPR\n4. **预印本特殊处理**:若同一 DOI 既有预印本(PPR)又有正式发表(MED),**两条都保留**,但预印本条目标记 `superseded_by_pmid: \u003C发表版 PMID>`,下游(medical-evidence-grading)据此决定是否丢弃预印本。\n\n**返回的合并条目结构**:\n\n```python\n{\n  \"primary_id\": \"PMID:38123456\",\n  \"all_ids\": {\"pmid\": \"38123456\", \"pmcid\": \"PMC10987654\", \"doi\": \"10.1038\u002F...\"},\n  \"sources\": [\"MED\", \"PMC\"],          # 出现的所有源\n  \"is_preprint\": False,\n  \"preprint_server\": None,\n  \"superseded_by_pmid\": None,\n  ...其他元数据\n}\n```\n\n## 7. 预印本处理(医学证据特别注意)\n\n预印本 = `source == \"PPR\"`。本 skill 在每条结果中显式标注:\n\n```python\n{\n  \"source\": \"PPR\",\n  \"is_preprint\": True,\n  \"preprint_server\": \"bioRxiv\",   # 或 medRxiv \u002F ChemRxiv \u002F Research Square \u002F SSRN ...\n  \"preprint_doi\": \"10.1101\u002F2024.03.15.123456\",\n  \"posted_date\": \"2024-03-15\",\n  \"version\": 2                      # 预印本版本号\n}\n```\n\n**下游约定**:`medical-evidence-grading` skill 看到 `is_preprint=True` 会自动**降权**(GRADE 中作为 \"very low\" 起点),且若同 DOI 已有正式发表版,直接丢弃预印本。本 skill 自身**不做证据分级**,只如实标注。\n\n## 8. 分页与流量\n\n- Europe PMC 单页上限:`pageSize=1000`\n- 分页方式:**强制使用 `cursorMark`**(从 `*` 起,响应里的 `nextCursorMark` 拿来下一页);**不要用 `page=` 偏移分页**(>1000 条时官方明确不保证一致性)\n- 流量礼貌:全局并发 ≤ 5,每秒 ≤ 8 请求(自动 sleep)\n- 429 \u002F 5xx 退避:指数退避 `2^n` 秒,最多重试 `max_retries`(默认 3)\n\n## 9. 错误处理与边界情况\n\n| 状态 | 处理 |\n|------|------|\n| HTTP 200 + `hitCount=0` | 返回空列表 + warning\"无命中,建议放宽 query\" |\n| HTTP 400 | 多半是查询语法错误 → 抛 `EuropePMCQueryError`,附原始 `errMsg` |\n| HTTP 429 | 指数退避重试 |\n| HTTP 5xx | 指数退避重试 |\n| `cursorMark` 与上一次相同 | 已到末页,正常终止 |\n| 同 query 已超过 `max_results` | 截断并返回 `truncated=True` 标志 |\n\n**致命错误一律抛异常,不静默吞**(遵循全局 `coding-style.md` 错误处理原则)。\n\n## 10. 调用示例\n\n```python\nfrom europepmc_search import EuropePMCClient\n\ncli = EuropePMCClient()  # 自动加载 ~\u002F.config\u002Feuropepmc.yaml\n\n# 1) 广召回:急性髓系白血病近 5 年 PubMed + 预印本\nhits = cli.search_articles(\n    query='(TITLE:\"acute myeloid leukemia\" OR ABSTRACT:\"AML\") AND PUB_YEAR:[2020 TO 2025]',\n    source_filter=[\"MED\", \"PPR\"],\n    max_results=500,\n    sort=\"date\",\n)\nprint(f\"去重后 {len(hits)} 条,其中预印本 {sum(h['is_preprint'] for h in hits)} 条\")\n\n# 2) DOI 反查全文链接\nlinks = cli.get_full_text_links(\"10.1056\u002FNEJMoa2024850\")\n\n# 3) 找 NIH R01 资助的 CAR-T 研究\nft = cli.search_with_grants(query=\"CAR-T\", grant_id=\"R01CA255621\")\n\n# 4) 邻域扩展\nsimilar = cli.find_similar_articles(\"38123456\", limit=30)\n```\n\n## 11. 与同体系其他 skill 的协作\n\n```\n[用户问题]\n    │\n    ├─→ europepmc-search       ← 本 skill,广召回 200~1000 条\n    │       │\n    │       └─→ pubmed-eutils  ← 拿 PMID 子集精准复核 + Clinical Queries 过滤\n    │               │\n    │               └─→ bioc-fulltext-fetch  ← 对 OA PMC 取全文 XML\n    │                       │\n    │                       └─→ pubtator-entity-search  ← 实体识别\n    │                               │\n    │                               └─→ medical-evidence-grading  ← GRADE 分级\n    │                                      (在此处依据 is_preprint 自动降权)\n    │\n    └─→ clinical-trials-v2 \u002F aact-bulk-trials  ← 试验注册号另走专线\n```\n\n## 12. 输出契约(下游 skill 依赖)\n\n每篇文章返回的标准 schema(本 skill 是契约源):\n\n```python\n{\n  \"primary_id\": \"PMID:38123456\" | \"PMCID:PMC10987654\" | \"DOI:10.xxx\u002F...\",\n  \"all_ids\": {\"pmid\": str|None, \"pmcid\": str|None, \"doi\": str|None, \"ppr_id\": str|None},\n  \"title\": str,\n  \"authors\": [{\"full_name\": str, \"affiliation\": str|None, \"orcid\": str|None}],\n  \"journal\": {\"name\": str, \"iso_abbr\": str|None, \"issn\": str|None},\n  \"pub_year\": int,\n  \"pub_date\": \"YYYY-MM-DD\",\n  \"abstract\": str|None,\n  \"mesh_terms\": [str],\n  \"keywords\": [str],\n  \"source\": \"MED\" | \"PMC\" | \"PPR\" | \"AGR\" | \"CBA\" | \"PAT\",\n  \"sources_merged\": [\"MED\",\"PMC\"],   # 去重前出现的所有源\n  \"is_preprint\": bool,\n  \"preprint_server\": str|None,\n  \"preprint_doi\": str|None,\n  \"version\": int|None,\n  \"superseded_by_pmid\": str|None,\n  \"has_full_text\": bool,\n  \"oa_status\": \"OA\" | \"SUBSCRIPTION\" | \"UNKNOWN\",\n  \"full_text_links\": {\"oa_xml\": str|None, \"oa_pdf\": str|None, \"publisher_html\": str|None},\n  \"cited_by_count\": int,\n  \"grants\": [{\"grant_id\": str, \"agency\": str, \"country\": str|None}],\n  \"fetched_at\": \"ISO-8601 UTC\",\n  \"europepmc_url\": \"https:\u002F\u002Feuropepmc.org\u002Farticle\u002FMED\u002F38123456\"\n}\n```\n\n下游 skill(medical-evidence-grading \u002F bioc-fulltext-fetch \u002F pubtator-entity-search)按此契约消费,**字段缺失用 `None`,不省略 key**。\n\n## 参考链接\n\n- Europe PMC RESTful Web Service 总览:https:\u002F\u002Feuropepmc.org\u002FRestfulWebService\n- 查询语法 Help:https:\u002F\u002Feuropepmc.org\u002FHelp#SSR\n- 字段速查:https:\u002F\u002Feuropepmc.org\u002FHelp#fieldsearch\n- 服务条款:https:\u002F\u002Feuropepmc.org\u002FAbout#TermsOfUse\n- API 端点:`https:\u002F\u002Fwww.ebi.ac.uk\u002Feuropepmc\u002Fwebservices\u002Frest\u002Fsearch`\n","# europepmc-search\n\nEurope PMC RESTful Web Service 的薄封装。**一次请求 = 多源召回**:PubMed(MED)、PubMed Central(PMC)、AGRICOLA(AGR)、CABI(CBA)、预印本(PPR,涵盖 bioRxiv\u002FmedRxiv\u002FChemRxiv\u002FarXiv 生命科学子集)、专利(PAT)、ETHOS 论文集等。\n\n## 1. 何时使用本 skill\n\n| 场景 | 用本 skill | 不用本 skill |\n|------|-----------|------------|\n| RAG 知识库构建,需\"撒网\"式广召回 | ✅ | |\n| 同时要 PubMed + 预印本 | ✅ | |\n| 只要 PubMed 官方源 + Clinical Queries | | ❌ → pubmed-eutils |\n| 拿 DOI 反查全文 OA 链接 | ✅ | |\n| 找特定基金(NIH\u002FNSFC\u002FWellcome)资助的研究 | ✅(`grant_id` 检索) | |\n| 抽取已知 PMCID 的全文 XML | | ❌ → bioc-fulltext-fetch |\n| 临床试验注册号检索 | | ❌ → clinical-trials-v2 |\n| 实体(基因\u002F疾病\u002F化合物)关联 | | ❌ → pubtator-entity-search |\n\n**与 pubmed-eutils 的差异化(必读)**:\n\n- pubmed-eutils:PubMed **单源**、Clinical Queries 过滤、PubDate 精确范围 → 高精准\n- europepmc-search:**多源聚合** + 自动去重 + 全文链接 + citations metadata → 高召回\n- 推荐编排:RAG 知识库构建用本 skill 广召回 → 拿 PMID 列表喂给 pubmed-eutils 做精准复核\n\n## 2. 前置准备 \u002F 配置加载\n\nEurope PMC RESTful 是**完全开放 API,无需 API key**,但服务条款要求传 `email` 联系方式(礼貌请求,便于 EBI 在大流量异常时联系到使用者)。\n\n**配置加载顺序(优先级从高到低)**:\n\n1. 项目级:`.config\u002Feuropepmc.local.yaml`(可选,优先于全局)\n2. 用户级:`~\u002F.config\u002Feuropepmc.yaml`\n3. 环境变量:`EUROPEPMC_EMAIL`\n4. 都没有 → 退化为 `anonymous@example.org` 并打印 ⚠️ 警告(建议用户配置)\n\n**配置文件示例**(`~\u002F.config\u002Feuropepmc.yaml`):\n\n```yaml\nemail: your-email@example.com\ndefault_page_size: 100        # 单页条数,1-1000\ndefault_result_type: core     # lite | core | idlist\ndefault_format: json          # json | xml | dc\ntimeout_seconds: 30\nmax_retries: 3\n```\n\n## 3. API 端点速查\n\n基础 URL:`https:\u002F\u002Fwww.ebi.ac.uk\u002Feuropepmc\u002Fwebservices\u002Frest\u002F`\n\n| 端点 | 用途 | 关键参数 |\n|------|------|---------|\n| `search` | 通用检索(本 skill 主力) | `query`, `resultType`, `pageSize`, `cursorMark`, `format`, `sort` |\n| `article\u002F{source}\u002F{id}` | 单篇详情 | source∈{MED,PMC,PPR,AGR,CBA,PAT,CTX,ETH,HIR,NBK} |\n| `{source}\u002F{id}\u002FfullTextXML` | 全文 XML(仅 OA) | 仅 PMC 子集 |\n| `{source}\u002F{id}\u002Freferences` | 参考文献 | 分页 |\n| `{source}\u002F{id}\u002Fcitations` | 被引列表 | 分页 |\n| `{source}\u002F{id}\u002FsupplementaryFiles` | 补充材料 | |\n| `grant\u002Fsearch` | 资助检索 | `query=GR:\"R01...\"` |\n\n## 4. 核心检索能力(5 个原子函数)\n\n### 4.1 `search_articles(query, source_filter=None, max_results=200, sort=None)`\n\n通用多源检索,自动分页(cursorMark)拉满到 `max_results`。\n\n- `query`:Europe PMC 查询语法(支持字段限定,见 §5)\n- `source_filter`:`[\"MED\",\"PMC\",\"PPR\"]` 限定来源;`None` = 全部\n- `sort`:`\"date\"`(出版日期降序)\u002F `\"cited\"`(被引降序)\u002F `None`(默认相关性)\n\n**返回**:`List[Article]`,每条含 `pmid \u002F pmcid \u002F doi \u002F title \u002F authors \u002F journal \u002F pub_year \u002F abstract \u002F source \u002F is_preprint \u002F preprint_server \u002F has_full_text \u002F oa_status \u002F cited_by_count`。\n\n### 4.2 `get_article_details(identifier)`\n\n单篇完整元数据。`identifier` 自动识别:\n\n- 纯数字 → PMID(查 MED 源)\n- `PMC` 前缀 → PMCID(查 PMC 源)\n- `10.` 开头 → DOI(用 query=`DOI:\"...\"` 反查)\n- `PPR` 开头 → 预印本 ID(查 PPR 源)\n\n### 4.3 `get_full_text_links(pmid_or_pmcid)`\n\n返回所有可用全文链接,按类型分类:\n\n```python\n{\n  \"oa_xml\": \"https:\u002F\u002F...\u002FfullTextXML\",      # OA 子集才有\n  \"oa_pdf\": \"https:\u002F\u002Feuropepmc.org\u002F...pdf\",\n  \"publisher_html\": \"https:\u002F\u002F...\",\n  \"subscription\": [...],                     # SUBSCRIPTION 类型\n  \"text_mining\": [...],                      # TM 类型(NLM 等)\n  \"preprint_server\": \"https:\u002F\u002Fwww.biorxiv.org\u002F...\"\n}\n```\n\n### 4.4 `search_with_grants(query, grant_id=None, funder=None)`\n\n资助检索。Europe PMC 有专门的 `GRANT_ID` \u002F `FUNDER` 字段。\n\n```python\n# 找 NIH R01-CA123456 资助的所有 paper\nsearch_with_grants(query=\"cancer\", grant_id=\"R01-CA123456\")\n\n# 找 Wellcome Trust 资助的全部 cardiology paper\nsearch_with_grants(query=\"cardiology\", funder=\"Wellcome Trust\")\n```\n\n### 4.5 `find_similar_articles(pmid_or_pmcid, limit=20)`\n\n调用 Europe PMC 内置的 \"Similar Articles\" 算法(基于 MeSH + 文本相似度)。比 PubMed `elink neighbor` 召回略广,适合做 RAG \"扩展邻域\"。\n\n## 5. 查询语法核心字段\n\nEurope PMC 查询语法兼容 Lucene 风格,字段大写。常用字段:\n\n| 字段 | 含义 | 示例 |\n|------|------|------|\n| `TITLE` | 标题 | `TITLE:\"CAR-T\"` |\n| `ABSTRACT` | 摘要 | `ABSTRACT:cytokine` |\n| `AUTH` | 作者 | `AUTH:\"Smith J\"` |\n| `JOURNAL` | 期刊 | `JOURNAL:\"Nature\"` |\n| `PUB_YEAR` | 年份 | `PUB_YEAR:[2020 TO 2024]` |\n| `PUB_TYPE` | 文献类型 | `PUB_TYPE:\"Review\"` |\n| `SRC` | 来源数据库 | `SRC:MED`, `SRC:PPR`, `SRC:PMC` |\n| `HAS_FT` | 有全文 | `HAS_FT:Y` |\n| `OPEN_ACCESS` | OA | `OPEN_ACCESS:Y` |\n| `MESH` | MeSH 主题词 | `MESH:\"Hematologic Neoplasms\"` |\n| `GRANT_ID` | 资助号 | `GRANT_ID:\"R01CA12345\"` |\n| `DOI` | DOI | `DOI:\"10.1038\u002Fs41586-020-2196-x\"` |\n| `LANG` | 语种 | `LANG:eng` |\n\n**预印本筛选示例**:`(SRC:PPR) AND (TITLE:\"acute myeloid leukemia\") AND (PUB_YEAR:2024)`\n\n## 6. 多源去重逻辑(本 skill 强制内置)\n\n同一篇文章常在 MED + PMC + PPR 同时出现。去重规则按以下优先级合并:\n\n1. **第一级:PMID 相同 → 合并**,保留 MED 版本(PubMed 元数据最权威)\n2. **第二级:PMCID 相同 → 合并**,保留 PMC 版本(因含全文)\n3. **第三级:DOI 相同 → 合并**,优先 MED > PMC > PPR\n4. **预印本特殊处理**:若同一 DOI 既有预印本(PPR)又有正式发表(MED),**两条都保留**,但预印本条目标记 `superseded_by_pmid: \u003C发表版 PMID>`,下游(medical-evidence-grading)据此决定是否丢弃预印本。\n\n**返回的合并条目结构**:\n\n```python\n{\n  \"primary_id\": \"PMID:38123456\",\n  \"all_ids\": {\"pmid\": \"38123456\", \"pmcid\": \"PMC10987654\", \"doi\": \"10.1038\u002F...\"},\n  \"sources\": [\"MED\", \"PMC\"],          # 出现的所有源\n  \"is_preprint\": False,\n  \"preprint_server\": None,\n  \"superseded_by_pmid\": None,\n  ...其他元数据\n}\n```\n\n## 7. 预印本处理(医学证据特别注意)\n\n预印本 = `source == \"PPR\"`。本 skill 在每条结果中显式标注:\n\n```python\n{\n  \"source\": \"PPR\",\n  \"is_preprint\": True,\n  \"preprint_server\": \"bioRxiv\",   # 或 medRxiv \u002F ChemRxiv \u002F Research Square \u002F SSRN ...\n  \"preprint_doi\": \"10.1101\u002F2024.03.15.123456\",\n  \"posted_date\": \"2024-03-15\",\n  \"version\": 2                      # 预印本版本号\n}\n```\n\n**下游约定**:`medical-evidence-grading` skill 看到 `is_preprint=True` 会自动**降权**(GRADE 中作为 \"very low\" 起点),且若同 DOI 已有正式发表版,直接丢弃预印本。本 skill 自身**不做证据分级**,只如实标注。\n\n## 8. 分页与流量\n\n- Europe PMC 单页上限:`pageSize=1000`\n- 分页方式:**强制使用 `cursorMark`**(从 `*` 起,响应里的 `nextCursorMark` 拿来下一页);**不要用 `page=` 偏移分页**(>1000 条时官方明确不保证一致性)\n- 流量礼貌:全局并发 ≤ 5,每秒 ≤ 8 请求(自动 sleep)\n- 429 \u002F 5xx 退避:指数退避 `2^n` 秒,最多重试 `max_retries`(默认 3)\n\n## 9. 错误处理与边界情况\n\n| 状态 | 处理 |\n|------|------|\n| HTTP 200 + `hitCount=0` | 返回空列表 + warning\"无命中,建议放宽 query\" |\n| HTTP 400 | 多半是查询语法错误 → 抛 `EuropePMCQueryError`,附原始 `errMsg` |\n| HTTP 429 | 指数退避重试 |\n| HTTP 5xx | 指数退避重试 |\n| `cursorMark` 与上一次相同 | 已到末页,正常终止 |\n| 同 query 已超过 `max_results` | 截断并返回 `truncated=True` 标志 |\n\n**致命错误一律抛异常,不静默吞**(遵循全局 `coding-style.md` 错误处理原则)。\n\n## 10. 调用示例\n\n```python\nfrom europepmc_search import EuropePMCClient\n\ncli = EuropePMCClient()  # 自动加载 ~\u002F.config\u002Feuropepmc.yaml\n\n# 1) 广召回:急性髓系白血病近 5 年 PubMed + 预印本\nhits = cli.search_articles(\n    query='(TITLE:\"acute myeloid leukemia\" OR ABSTRACT:\"AML\") AND PUB_YEAR:[2020 TO 2025]',\n    source_filter=[\"MED\", \"PPR\"],\n    max_results=500,\n    sort=\"date\",\n)\nprint(f\"去重后 {len(hits)} 条,其中预印本 {sum(h['is_preprint'] for h in hits)} 条\")\n\n# 2) DOI 反查全文链接\nlinks = cli.get_full_text_links(\"10.1056\u002FNEJMoa2024850\")\n\n# 3) 找 NIH R01 资助的 CAR-T 研究\nft = cli.search_with_grants(query=\"CAR-T\", grant_id=\"R01CA255621\")\n\n# 4) 邻域扩展\nsimilar = cli.find_similar_articles(\"38123456\", limit=30)\n```\n\n## 11. 与同体系其他 skill 的协作\n\n```\n[用户问题]\n    │\n    ├─→ europepmc-search       ← 本 skill,广召回 200~1000 条\n    │       │\n    │       └─→ pubmed-eutils  ← 拿 PMID 子集精准复核 + Clinical Queries 过滤\n    │               │\n    │               └─→ bioc-fulltext-fetch  ← 对 OA PMC 取全文 XML\n    │                       │\n    │                       └─→ pubtator-entity-search  ← 实体识别\n    │                               │\n    │                               └─→ medical-evidence-grading  ← GRADE 分级\n    │                                      (在此处依据 is_preprint 自动降权)\n    │\n    └─→ clinical-trials-v2 \u002F aact-bulk-trials  ← 试验注册号另走专线\n```\n\n## 12. 输出契约(下游 skill 依赖)\n\n每篇文章返回的标准 schema(本 skill 是契约源):\n\n```python\n{\n  \"primary_id\": \"PMID:38123456\" | \"PMCID:PMC10987654\" | \"DOI:10.xxx\u002F...\",\n  \"all_ids\": {\"pmid\": str|None, \"pmcid\": str|None, \"doi\": str|None, \"ppr_id\": str|None},\n  \"title\": str,\n  \"authors\": [{\"full_name\": str, \"affiliation\": str|None, \"orcid\": str|None}],\n  \"journal\": {\"name\": str, \"iso_abbr\": str|None, \"issn\": str|None},\n  \"pub_year\": int,\n  \"pub_date\": \"YYYY-MM-DD\",\n  \"abstract\": str|None,\n  \"mesh_terms\": [str],\n  \"keywords\": [str],\n  \"source\": \"MED\" | \"PMC\" | \"PPR\" | \"AGR\" | \"CBA\" | \"PAT\",\n  \"sources_merged\": [\"MED\",\"PMC\"],   # 去重前出现的所有源\n  \"is_preprint\": bool,\n  \"preprint_server\": str|None,\n  \"preprint_doi\": str|None,\n  \"version\": int|None,\n  \"superseded_by_pmid\": str|None,\n  \"has_full_text\": bool,\n  \"oa_status\": \"OA\" | \"SUBSCRIPTION\" | \"UNKNOWN\",\n  \"full_text_links\": {\"oa_xml\": str|None, \"oa_pdf\": str|None, \"publisher_html\": str|None},\n  \"cited_by_count\": int,\n  \"grants\": [{\"grant_id\": str, \"agency\": str, \"country\": str|None}],\n  \"fetched_at\": \"ISO-8601 UTC\",\n  \"europepmc_url\": \"https:\u002F\u002Feuropepmc.org\u002Farticle\u002FMED\u002F38123456\"\n}\n```\n\n下游 skill(medical-evidence-grading \u002F bioc-fulltext-fetch \u002F pubtator-entity-search)按此契约消费,**字段缺失用 `None`,不省略 key**。\n\n## 参考链接\n\n- Europe PMC RESTful Web Service 总览:https:\u002F\u002Feuropepmc.org\u002FRestfulWebService\n- 查询语法 Help:https:\u002F\u002Feuropepmc.org\u002FHelp#SSR\n- 字段速查:https:\u002F\u002Feuropepmc.org\u002FHelp#fieldsearch\n- 服务条款:https:\u002F\u002Feuropepmc.org\u002FAbout#TermsOfUse\n- API 端点:`https:\u002F\u002Fwww.ebi.ac.uk\u002Feuropepmc\u002Fwebservices\u002Frest\u002Fsearch`\n",{"name":5,"license":15,"keywords":49,"description":7},[30,29,50,28,51,52,53,54,55,56,57,58,59,60,61,62],"多源文献聚合","广召回","预印本","biorxiv","medrxiv","chemrxiv","全文链接","doi-检索","pmcid","灰色文献","grants-检索","citations-metadata","跨库去重","mine","1e7390741dffd3d5041fca4ebc056071ee3ba137","archives\u002Fuser-installed-skills\u002Feuropepmc-search\u002F5eec9d3036d956eb\u002Feuropepmc-search",5,"https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub","https:\u002F\u002Fgithub.com\u002FEthanYoQ","www.orz.md","Part Marketer, Part AI Explorer.","2026-11-07 14:52:29",{"source":8,"skillName":5,"commands":73,"prompt":83,"zipAvailable":84},[74,77,80],{"tool":75,"command":76},"npx","npx skills add EthanYoQ\u002FSkill-hub --skill europepmc-search",{"tool":78,"command":79},"bunx","bunx skills add EthanYoQ\u002FSkill-hub --skill europepmc-search",{"tool":81,"command":82},"pnpm","pnpm dlx skills add EthanYoQ\u002FSkill-hub --skill europepmc-search","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Farchives\u002Fuser-installed-skills\u002Feuropepmc-search\u002F5eec9d3036d956eb\u002Feuropepmc-search\u002FSKILL.md",true,[],[87,114,145,168,186,201],{"skillNo":88,"name":89,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":91,"categories":92,"keywords":94,"publishedAt":44},"01M713CBDSYARG4PXFXK2R2NNN","xhs-pharma-social-listening","Run evidence-disciplined Xiaohongshu social listening for foreign pharma employee pain points. Use when the user asks to collect and analyze notes\u002Fcomments about pharma companies, aliases, roles, compliance, medical affairs, or AI topics, then produce a cited and scored sampled-insight report. Includes independent-evidence counting, MediaCrawler batch collection, and CAPTCHA\u002F461 fallback to Agent Reach\u002FOpenCLI.","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fxhs-pharma-social-listening\u002FSKILL.md",[93],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[95,96,97,98,40,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113],"social","xhs pharma social listening","social listening","xhs","counting","when","collection","batch","analyze","notes","run","opencli","fallback","captcha","agent reach","evidence","for","collect","produce",{"skillNo":115,"name":116,"nameZh":6,"description":117,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":126,"publishedAt":44},"01M713C8Q76ZP0WXXBRAFKS6EE","healthcare-phi-compliance","Protected Health Information (PHI) and Personally Identifiable Information (PII) compliance patterns for healthcare applications. Covers data classification, access control, audit trails, encryption, and common leak vectors. Use when code touches PHI or PII in a healthcare system, or when auditing access control, audit trails, or leak vectors.","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fhealthcare-phi-compliance\u002FSKILL.md",[120,121],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":122,"categoryName":123,"taxonomyType":124,"taxonomyTypeDesc":125},"01JBSEEDCAT000000000000037","律师与法务","PROFESSION","适用职业",[127,128,129,130,131,132,133,134,100,135,136,137,138,139,140,141,111,142,143,144],"healthcare","phi","compliance","healthcare phi compliance","pii","compliance patterns","information","access","encryption","code","common","audit","data","patterns","Access Control","system","applications","Auditing Access Control",{"skillNo":146,"name":147,"nameZh":6,"description":148,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":149,"categories":150,"keywords":152,"publishedAt":44},"01M713C5R2GE43X45T2K75TB76","healthcare-eval-harness","Patient safety evaluation harness for healthcare application deployments. Automated test suites for CDSS accuracy, PHI exposure, clinical workflow integrity, and integration compliance. Blocks deployments on safety failures. Use when a healthcare deployment must be gated on patient-safety tests for CDSS accuracy, PHI exposure, and workflow integrity.","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fhealthcare-eval-harness\u002FSKILL.md",[151],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[127,153,154,155,156,39,157,100,158,159,160,161,128,111,162,163,164,165,166,167],"eval","harness","healthcare eval harness","eval harness","patient","workflow","Evaluation","Safety","integrity","deployment","accuracy","tests","deployments","use","super",{"skillNo":169,"name":170,"nameZh":6,"description":171,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":172,"categories":173,"keywords":175,"publishedAt":44},"01M713C2J17S91VYR7A8M696VR","healthcare-emr-patterns","EMR\u002FEHR development patterns for healthcare applications. Clinical safety, encounter workflows, prescription generation, clinical decision support integration, and accessibility-first UI for medical data entry. Use when building EMR or EHR features such as encounter workflows, prescription generation, or clinical data entry UI.","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fhealthcare-emr-patterns\u002FSKILL.md",[174],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[127,176,140,177,178,40,39,179,100,180,181,182,160,139,183,184,185,111,143,166],"EMR","healthcare emr patterns","decision","workflows","support","clinical decision support","features","ui","as","development",{"skillNo":187,"name":188,"nameZh":6,"description":189,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":190,"categories":191,"keywords":193,"publishedAt":44},"01M713BZERTXV0N8X6SW9DDVWZ","healthcare-cdss-patterns","Clinical Decision Support System (CDSS) development patterns. Drug interaction checking, dose validation, clinical scoring (NEWS2, qSOFA), alert severity classification, and integration into EMR workflows. Use when building clinical decision support — drug interaction checks, dose validation, clinical scoring, or alert severity.","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fhealthcare-cdss-patterns\u002FSKILL.md",[192],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[127,140,194,178,39,176,179,100,195,196,180,181,197,185,142,198,166,199,167,200],"healthcare cdss patterns","scoring","interaction","severity","classification","alert","decision support",{"skillNo":202,"name":203,"nameZh":6,"description":204,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":205,"categories":206,"keywords":208,"publishedAt":44},"01M713BVK3PQR7V4ZKYGMWMXJD","dxy-task-clarify","用户的请求含糊、缺背景、缺资料说明、缺读者或用途时使用。先用少量带选项的追问把任务问清楚，写成任务卡，用户确认后再执行。尤其适用于医生、科研人员和药企各岗位的工作，例如「帮我分析一下这些数据」「帮我准备明天的拜访」「写个总结」「做个 PPT」「回一下这封邮件」「整理一下会议纪要」「整理一下这些文献」「帮我准备下周的讲课」「写个病例汇报」「帮我写个提示词」。用户说「先问我」「帮我理清需求」「我不知道怎么描述」「我不会问 AI」时也使用。用途、资料、读者都已说清的请求，纯翻译，以及写代码、改代码，不使用。","https:\u002F\u002Fgithub.com\u002FEthanYoQ\u002FSkill-hub\u002Fblob\u002Fmine\u002Fskills\u002F10-business-industry\u002Fdxy-task-clarify\u002FSKILL.md",[207],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},[209,210,211,212,213,214,215,216],"clarify","dxy task clarify","task","pptx","整理","翻译","数据","总结"]