bioc-fulltext-fetch
给定 PMID/PMCID 取结构化全文(NLM BioC XML/JSON)。封装 BioC PubMed(标题+摘要)和 BioC PMC OA(开放获取全文)端点,输出按章节切分的段落、表格上下文、RAG 友好 chunk,适合大批量入向量库。Fetches structured fulltext from…
Skill by EthanYoQ
Chalk Labs
Need help deploying bioc-fulltext-fetch?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/ethanyoq-bioc-fulltext-fetch
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: backend, ml
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/bioc-fulltext-fetch
What's inside
- Skill name
bioc-fulltext-fetch- Description
- 给定 PMID/PMCID 取结构化全文(NLM BioC XML/JSON)。封装 BioC PubMed(标题+摘要)和 BioC PMC OA(开放获取全文)端点,输出按章节切分的段落、表格上下文、RAG 友好 chunk,适合大批量入向量库。Fetches structured fulltext from NLM BioC API for PMID/PMCID, outputs section-segmented paragraphs and RAG-ready chunks. 触发词:全文抽取 / BioC / RAG 入库 / 文献全文 / PMC 开放获取 / structured fulltext / 段落抽取 / 表格抽取 / chunking / fulltext to vector store / paragraph extraction.
- License
- MIT
- Instructions
- 201 lines in SKILL.md · view on GitHub
Files (4)
- SKILL.md
- bioc-format-spec.md · references/
- chunking-strategies.md · references/
- rag-integration.md · references/
SKILL.md (first lines)
# BioC Fulltext Fetch
封装 NLM BioC API,把 PubMed / PMC 文献转成 RAG 友好的结构化全文 chunk。**只做全文抽取与切片,不做检索、不做实体标注、不做向量化。**
## 1. 何时使用
触发场景:
- "把这批 PMID 的全文取下来准备入 ChromaDB / 我有 PMCID 列表要按章节切分做 RAG"
- "提取 Methods 章节段落 / 找出表格周围的语义文本"
- "Build vector index from PMC open access papers"
- "PMC1234567 的全文段落 + 章节标签"
- "把 100 篇血液 IFI PMID 入向量库"
不要使用本 skill:
- 用户只要标题/摘要纯文本 → 用 `pubmed-eutils` efetch
- 用户要做语义检索找文献 → 用 `pubmed-search` / `europepmc-search`
- 用户要实体标注(基因/疾病/化合物)→ 用 `pubtator-entity-search`(可在本 skill 输出之上叠加,不替代)
- 用户要做证据等级评分 → 用 `medical-evidence-grading`(其内部会调用本 skill 抽 Methods 段落)
## 2. 跨 skill 协作(显式)
| 上游 / 下游 skill | 协作方式 |
|------------------|----------|
| `pubmed-eutils.elink_pubmed_to_pmc()` | **上游**,把 PMID 列表转换成 PMCID 列表,喂给本 skill |
| `europepmc-search.get_full_text_links()` | **替代源**,当 PMC OA 不可用时回退到 Europe PMC 的开放获取链接 |
| `pubtator-entity-search` | **后置叠加**,在本 skill 产的 chunk 上做实体标注,不替代本 skill |
| `medical-evidence-grading` | **下游**,调 `extract_paragraphs` 取 Methods 段落做 sample size / study design 检测 |
典型 pipeline:
```
europepmc-search ──► PMID list ──► pubmed-eutils.elink ──► PMCID list
│
▼
bioc-fulltext-fetch (本 skill)
│
├─► [可选] pubtator-entity-search 实体叠加
├─► [可选] medical-evidence-grading 证据评分
└─► LangChain / LlamaIndex 入库
```
## 3. 两个 BioC 端点
| 端点 | 输入 | 覆盖 | 内容 |
|------|------|------|------|
| **BioC PubMed** | PMID | 全 PubMed (~37M) | 标题 + 摘要 + MeSH(结构化) |
| **BioC PMC OA** | PMCID | PMC 开放获取子集(~10M,约占 PMC 25%) | 全文章节、段落、表格、图注 |
```
摘要级: https://www.ncbi.nlm.nih.gov/research/bionlp/RESTful/pubmed.cgi/BioC_json/{PMID}/unicode
全文级: https://www.ncbi.nlm.nih.gov/research/bionlp/RESTful/pmcoa.cgi/BioC_json/{PMCID}/unicode
```
格式细节、`section_type` 取值、字符 offset 一致性见 [`references/bioc-format-spec.md`](references/bioc-format-spec.md)。
## 4. 推荐工作流
```
PMID list
│
▼
[可选] elink PMID→PMCID (调 pubmed-eutils)
│
├─ PMCID 存在且 OA ──► fetch_fulltext_bioc(pmcid) ──► extract_paragraphs / extract_tables_context ──► to_rag_chunks
│
└─ 不可用/非 OA ─────► fetch_abstract_bioc(pmid) ─────────────────────────────────────────────────► to_rag_chunks
```
## 5. 核心能力(5 个函数 · 跨平台签名)
### 5.1 `fetch_abstract_bioc(pmid: str) -> BioCDocument`
取标题 + 摘要 + MeSH 的 BioC 结构化版本。
```python
doc = fetch_abstract_bioc("39523456")
# doc.passages → [{"infons": {"section_type": "TITLE"}, "text": "..."},
# {"infons": {"section_type": "ABSTRACT"}, "text": "..."}]
# doc.infons["mesh"] → ["Leukemia, Myeloid, Acute", "FLT3 Mutation", ...]
```
### 5.2 `fetch_fulltext_bioc(pmcid: str) -> BioCDocument`
取 PMC OA 全文,按章节切分(`section_type` ∈ {TITLE, ABSTRACT, INTRO, METHODS, RESULTS, DISCUSS, CONCL, REF, FIG, TABLE, ...})。
```python
doc = fetch_fulltext_bioc("PMC10234567")
# 不可用时抛 NotOpenAccessError,调用方应回退到 fetch_abstract_bioc
```
### 5.3 `extract_paragraphs(doc: BioCDocument) -> list[Paragraph]`
按 BioC `passage` 提取段落数组,保留 section 标签 + 字符 offset。
```python
paragraphs = extract_paragraphs(doc)
# [{"section_label": "METHODS", "text": "Flow cytometry was performed...",
# "offset_start": 2890, "offset_end": 3401}, ...]
```
要点:跳过 `REF` / `FIG_LABEL` 纯标签段;合并同 section 内 < 50 字符短 passage;offset 来自 BioC `passage.offset`。
### 5.4 `extract_tables_context(doc: BioCDocument, window: int = 200) -> list[TableContext]`
提取每个表格的上下文(前后 200 字),帮 RAG 给表打语义标签。
```python
tables = extract_tables_context(doc, window=200)
# [{"table_id": "T1", "caption": "Patient baseline characteristics",
# "before_context": "...", "after_context": "...", "section": "RESULTS"}, ...]
```
表格本体(cell 数据)不解析;只取 caption + 周围文本。
### 5.5 `to_rag_chunks(doc: BioCDocument, chunk_size: int = 512, overlap: int = 50) -> list[Chunk]`
把 BioC 文档切成 RAG 入库 chunk。token 单位、不跨章节、段落优先、可追溯 `chunk_id`。
```python
chunks = to_rag_chunks(doc, chunk_size=512, overlap=50)From EthanYoQ/Skill-hub, MIT.
More from EthanYoQ/Skill-hub
- 0.597score
cite-bound-content-generator
EthanYoQ
Phase 4 Turn 1 of disease-market-sizing-orchestration.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
aliyun-swas-manage
EthanYoQ
Use when managing Alibaba Cloud Simple Application Server (SWAS OpenAPI 2020-06-01) resources end-to-end, including querying instances…
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
contract-elicitor
EthanYoQ
Use FIRST when user requests any disease market sizing report (e.g.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
agent-reach
EthanYoQ
MUST USE when user wants to 调研/research/搜索/search/查/找/look up anything on the internet — e.g.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
content-verification-layer
EthanYoQ
Phase 4 Turn 2 of disease-market-sizing-orchestration (A6' upgrade).
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
agent-reach
EthanYoQ
MUST USE when user wants to 调研/research/搜索/search/查/找/look up anything on the internet — e.g.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
baoyu-image-gen
EthanYoQ
AI image generation with OpenAI GPT Image 2, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream, Replicate and Agnes APIs.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
aact-bulk-trials
EthanYoQ
使用 AACT (Aggregate Analysis of ClinicalTrials.gov) PostgreSQL 数据仓库进行批量、历史、聚合性临床试验数据挖掘。Use this skill when the user requests bulk SQL analysis over the full…
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
citation-anchor-resolver
EthanYoQ
Cite-or-Block 架构的基石原子 skill。把报告里的 citation 锚点 (例如 [guideline:CSCO-2024-NSCLC:§5.5.2] / [pmid:12345678:abstract]) 解析为源文件片段,并核对事实声明里的关键词是否在引用源原文里出现。 Foundation…
SkillBFreshness: B★ 11Claude Code +9 - 0.594score
drug-citation-verifier
EthanYoQ
Cite-or-Block 架构下的药名 cross-check 原子 skill。给定报告文本与 .cache/<slug>/sources/,扫描每个药品提及 → 找最近 citation 锚点 → 核对锚点指向的源里是否真的提到了此药(通用名 + 商品名)。无字典、无 fallback、源里没 =…
SkillBFreshness: B★ 11Claude Code +9 - 0.592score
adaptive-quality-gate
EthanYoQ
Use when work produces a deliverable, factual claim, dataset, code change, decision, publication, deployment, automation, or irreversible action whose failure…
SkillBFreshness: B★ 11Claude Code +9 - 0.592score
aact-bulk-trials
EthanYoQ
使用 AACT (Aggregate Analysis of ClinicalTrials.gov) PostgreSQL 数据库进行大批量临床试验历史分析与数据挖掘。触发场景包括:AACT 查询、临床试验批量分析、PostgreSQL 试验数据、全量 NCT 检索、试验数据挖掘、clinical trials…
SkillBFreshness: B★ 11Claude Code +9
Compare and alternatives
Featured in
Signals
- Stars
- 11
- Forks
- 4
- Open issues
- 0
- Last commit (this folder)
- Sep 19, 2026 (1 month ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/EthanYoQ/Skill-hub
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from EthanYoQ
- 0.597score
baoyu-image-gen
EthanYoQ
AI image generation with OpenAI GPT Image 2, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream, Replicate and Agnes APIs.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
citation-anchor-resolver
EthanYoQ
Cite-or-Block 架构的基石原子 skill。把报告里的 citation 锚点 (例如 [guideline:CSCO-2024-NSCLC:§5.5.2] / [pmid:12345678:abstract]) 解析为源文件片段,并核对事实声明里的关键词是否在引用源原文里出现。 Foundation…
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
aact-bulk-trials
EthanYoQ
使用 AACT (Aggregate Analysis of ClinicalTrials.gov) PostgreSQL 数据仓库进行批量、历史、聚合性临床试验数据挖掘。Use this skill when the user requests bulk SQL analysis over the full…
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
agent-reach
EthanYoQ
MUST USE when user wants to 调研/research/搜索/search/查/找/look up anything on the internet — e.g.
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
aliyun-swas-manage
EthanYoQ
Use when managing Alibaba Cloud Simple Application Server (SWAS OpenAPI 2020-06-01) resources end-to-end, including querying instances…
SkillBFreshness: B★ 11Claude Code +9 - 0.597score
cite-bound-content-generator
EthanYoQ
Phase 4 Turn 1 of disease-market-sizing-orchestration.
SkillBFreshness: B★ 11Claude Code +9
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get bioc-fulltext-fetch running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
bioc-fulltext-fetch skill. Agent Mart. https://agentmart.dev/skills/ethanyoq-bioc-fulltext-fetch (last updated 2026-10-24)