Paper2MCP v2 Verified Deliverable

Standardizing spatial transcriptomic analysis for infectious diseases with STID

期刊:Cell Reports Methods (2026-10-22) · DOI:10.1016/j.crmeth.2026.101642 · 开源许可:unknown (restricted)

上游仓库:https://github.com/YulongQin/STID @ 6c6e29dc469e

Pytest: passed MCP Stdio Selftest: passed Relocated Fresh Install: passed

一、一键安装与 MCP 接入(本地 / 远程统一接口)

# 1. 解压并自动构建隔离环境 + 运行真实数据自测
unzip stid-mcp.zip && cd stid-mcp
bash install.sh
.venv/bin/python selftest.py

# 2. 接入 Claude Code / Antigravity / Cursor (Stdio MCP)
claude mcp add stid -- "$PWD/.venv/bin/python" "$PWD/server.py"

# 3. 或启动远程 Streamable HTTP MCP 服务端供团队/网页直接调用
.venv/bin/python server.py --transport http --host 0.0.0.0 --port 8000

二、已验证科学工具清单(4 个工具)

correct_pathogen_background MCP Verified ✓

Estimate pathogen-derived background from a control sample and subtract it from every sample (STID CorrectBackground); reports positive spots and pathogen counts before and after.

Selftest Summary: Background-corrected 8 pathogen genes in 3 samples with control 'ctrl'; total pathogen counts 3915 -> 2362.
Metrics: {"total_counts_before": 3915, "total_counts_after": 2362, "n_pathogen_genes": 8, "per_sample": [{"sample": "ctrl", "spots": 225, "total_before": 83, "total_after": 1, "pos_spots_before": 67, "pos_spots_after": 1}, {"sample": "inf", "spots": 225, "total_before": 1385, "total_after": 860, "pos_spots_before": 96, "pos_spots_after": 25}, {"sample": "inf2", "spots": 225, "total_before": 2447, "total_after": 1501, "pos_spots_before": 105, "pos_spots_after": 49}]}
detect_infection_niches MCP Verified ✓

Correct background, call pathogen-positive spots (STID SpotDetect_Gene) and delineate aggregated (NicheDetect_STS) or dispersed (NicheDetect_Spot) infection niches in every sample.

Selftest Summary: Detected 74 aggregated niche spots across 3 samples (pos_count>=2.0).
Metrics: {"niche_type": "aggregated", "total_niche_spots": 74, "per_sample": [{"sample": "ctrl", "spots": 225, "positive_spots": 0, "niche_spots": 0, "n_rois": 0}, {"sample": "inf", "spots": 225, "positive_spots": 25, "niche_spots": 25, "n_rois": 1}, {"sample": "inf2", "spots": 225, "positive_spots": 49, "niche_spots": 49, "n_rois": 1}]}
analyze_single_sample_niche MCP Verified ✓

Characterize one sample aggregated infection niche: cell-type composition inside versus outside the niche and niche-vs-bystander differential expression (STID CalSampComp/CalSampDEGs).

Selftest Summary: Sample inf: 25 niche vs 200 bystander spots; 8 genes up and 17 down in the niche.
Metrics: {"sample": "inf", "n_niche_spots": 25, "n_bystander_spots": 200, "n_genes_tested": 40, "n_up": 8, "n_down": 17, "top_up_genes": ["Gm023", "Gm022", "Gm024", "Gm019", "Gm018"], "plot_warning": null}
compare_multisample_niches MCP Verified ✓

Compare the infection niches of two samples from different groups: niche differential expression between the samples in STID multi-sample Comparative mode.

Selftest Summary: Compared niches of inf vs inf2: 8 genes up and 8 down.
Metrics: {"multi_id": "Comparative_2_3", "per_sample": [{"sample": "inf", "niche_spots": 25}, {"sample": "inf2", "niche_spots": 49}], "n_genes_tested": 34, "n_up": 8, "n_down": 8, "top_up_genes": ["Gm003", "Gm001", "Gm004", "Gm002", "Gm006"], "plot_warning": null}

三、实测复现结果图展示

01_background_correction.png
02_infection_niches.png
03_niche_degs_between_samples.png